This is an automated email from the ASF dual-hosted git repository.
pnoltes pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/celix.git
The following commit(s) were added to refs/heads/develop by this push:
new 62a30cd Adds find crypto library to the findOpenSSL.cmake file.
62a30cd is described below
commit 62a30cdb2e64c71c8ea9216e47e9025f35ad75cb
Author: Pepijn Noltes <[email protected]>
AuthorDate: Wed Sep 11 19:54:21 2019 +0200
Adds find crypto library to the findOpenSSL.cmake file.
---
cmake/Modules/FindOpenSSL.cmake | 11 +++++++----
libs/framework/CMakeLists.txt | 4 ++--
2 files changed, 9 insertions(+), 6 deletions(-)
diff --git a/cmake/Modules/FindOpenSSL.cmake b/cmake/Modules/FindOpenSSL.cmake
index 6787123..9b37bf4 100644
--- a/cmake/Modules/FindOpenSSL.cmake
+++ b/cmake/Modules/FindOpenSSL.cmake
@@ -32,13 +32,16 @@ find_path(OPENSSL_INCLUDE_DIR ssl.h crypto.h
find_library(OPENSSL_LIBRARY NAMES ssl
PATHS /usr/lib /usr/local/lib /usr/local/opt/openssl/lib
${OPENSSL_DIR}/lib)
-set(OPENSSL_LIBRARIES ${OPENSSL_LIBRARY} )
-set(OPENSSL_INCLUDE_DIRS ${OPENSSL_INCLUDE_DIR} )
+find_library(CRYPTO_LIBRARY NAMES crypto
+ PATHS /usr/lib /usr/local/lib /usr/local/opt/openssl/lib
${OPENSSL_DIR}/lib)
+
+set(OPENSSL_LIBRARIES ${OPENSSL_LIBRARY} ${CRYPTO_LIBRARY})
+set(OPENSSL_INCLUDE_DIRS ${OPENSSL_INCLUDE_DIR})
include(FindPackageHandleStandardArgs)
# handle the QUIETLY and REQUIRED arguments and set OPENSSL_FOUND to TRUE
# if all listed variables are TRUE
find_package_handle_standard_args(OpenSSL DEFAULT_MSG
- OPENSSL_LIBRARY OPENSSL_INCLUDE_DIR)
+ OPENSSL_LIBRARY CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR)
-mark_as_advanced(OPENSSL_INCLUDE_DIR OPENSSL_LIBRARY)
+mark_as_advanced(OPENSSL_INCLUDE_DIR OPENSSL_LIBRARY CRYPTO_LIBRARY)
diff --git a/libs/framework/CMakeLists.txt b/libs/framework/CMakeLists.txt
index 6cdb1b9..b804a8d 100644
--- a/libs/framework/CMakeLists.txt
+++ b/libs/framework/CMakeLists.txt
@@ -47,8 +47,8 @@ target_include_directories(framework PUBLIC
)
target_compile_options(framework PRIVATE -DUSE_FILE32API)
set_target_properties(framework PROPERTIES "SOVERSION" 2)
-target_link_libraries(framework PUBLIC Celix::utils ${OPENSSL_LIBRARY})
-target_link_libraries(framework PRIVATE ${UUID_LIBRARY} ${ZLIB_LIBRARY}
${CURL_LIBRARY})
+target_link_libraries(framework PUBLIC Celix::utils)
+target_link_libraries(framework PRIVATE ${UUID_LIBRARY} ${ZLIB_LIBRARY}
${CURL_LIBRARY} ${OPENSSL_LIBRARIES})
target_include_directories(framework PRIVATE ${CURL_INCLUDE_DIR}
${UUID_INCLUDE_DIRS})
install(TARGETS framework EXPORT celix DESTINATION ${CMAKE_INSTALL_LIBDIR}
COMPONENT framework)