changeset 4369:39bc2fb4657b

look for openssl in DownloadOrthancFramework.cmake
author Sebastien Jodogne <s.jodogne@gmail.com>
date Sat, 12 Dec 2020 19:41:56 +0100
parents 189e48f4a92a
children e980d584434a
files OrthancFramework/Resources/CMake/DownloadOrthancFramework.cmake
diffstat 1 files changed, 10 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/OrthancFramework/Resources/CMake/DownloadOrthancFramework.cmake	Thu Dec 10 18:36:57 2020 +0100
+++ b/OrthancFramework/Resources/CMake/DownloadOrthancFramework.cmake	Sat Dec 12 19:41:56 2020 +0100
@@ -529,6 +529,16 @@
       include_directories(${DCMTK_INCLUDE_DIRS})
       link_libraries(${DCMTK_LIBRARIES})
     endif()
+
+    # Optional component - OpenSSL
+    if (ENABLE_SSL)
+      include(FindOpenSSL)
+      if (NOT ${OPENSSL_FOUND})
+        message(FATAL_ERROR "Unable to find OpenSSL")
+      endif()
+      include_directories(${OPENSSL_INCLUDE_DIR})
+      link_libraries(${OPENSSL_LIBRARIES})
+    endif()
   endif()
 
   # Look for Orthanc framework shared library