aboutsummaryrefslogtreecommitdiff
path: root/libssh/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'libssh/CMakeLists.txt')
-rw-r--r--libssh/CMakeLists.txt29
1 files changed, 25 insertions, 4 deletions
diff --git a/libssh/CMakeLists.txt b/libssh/CMakeLists.txt
index a3e5e210..62bf4b92 100644
--- a/libssh/CMakeLists.txt
+++ b/libssh/CMakeLists.txt
@@ -9,8 +9,6 @@ set(LIBSSH_PUBLIC_INCLUDE_DIRS
set(LIBSSH_PRIVATE_INCLUDE_DIRS
${CMAKE_BINARY_DIR}
- ${OPENSSL_INCLUDE_DIRS}
- ${GCRYPT_INCLUDE_DIRS}
${ZLIB_INCLUDE_DIRS}
)
@@ -21,11 +19,32 @@ set(LIBSSH_LIBRARY
set(LIBSSH_LINK_LIBRARIES
${LIBSSH_LIBRARY}
- ${CRYPTO_LIBRARY}
- ${GCRYPT_LIBRARY}
${ZLIB_LIBRARIES}
)
+if (CRYPTO_LIBRARY)
+ set(LIBSSH_PRIVATE_INCLUDE_DIRS
+ ${LIBSSH_PRIVATE_INCLUDE_DIRS}
+ ${OPENSSL_INCLUDE_DIRS}
+ )
+ set(LIBSSH_LINK_LIBRARIES
+ ${LIBSSH_LINK_LIBRARIES}
+ ${CRYPTO_LIBRARY}
+ )
+endif (CRYPTO_LIBRARY)
+
+if (GCRYPT_LIBRARY)
+ set(LIBSSH_PRIVATE_INCLUDE_DIRS
+ ${LIBSSH_PRIVATE_INCLUDE_DIRS}
+ ${GCRYPT_INCLUDE_DIRS}
+ )
+ set(LIBSSH_LINK_LIBRARIES
+ ${LIBSSH_LINK_LIBRARIES}
+ ${GCRYPT_LIBRARY}
+ )
+endif (GCRYPT_LIBRARY)
+
+
set(libssh_SRCS
agent.c
auth1.c
@@ -87,5 +106,7 @@ install(
${LIBSSH_LIBRARY}
DESTINATION
${LIB_INSTALL_DIR}
+ COMPONENT
+ libraries
)