# HG changeset patch # User Sebastien Jodogne # Date 1504091497 -7200 # Node ID a88c3ea0c96dfd1ee293de1c1737940755b03a3d # Parent 233d6eeef799bac7796cb85ff5329beb877db315 getting rid of the OpenSSL static library diff -r 233d6eeef799 -r a88c3ea0c96d CMakeLists.txt --- a/CMakeLists.txt Wed Aug 30 12:29:48 2017 +0200 +++ b/CMakeLists.txt Wed Aug 30 13:11:37 2017 +0200 @@ -272,18 +272,13 @@ ## Build the core of Orthanc ##################################################################### -list(LENGTH OPENSSL_SOURCES OPENSSL_SOURCES_LENGTH) -if (${OPENSSL_SOURCES_LENGTH} GREATER 0) - add_library(OpenSSL STATIC ${OPENSSL_SOURCES}) -endif() - - # "CoreLibrary" contains all the third-party dependencies and the -# content of the "Core" folder, but not OpenSSL, nor DCMTK. +# content of the "Core" folder add_library(CoreLibrary STATIC ${ORTHANC_CORE_PCH} ${ORTHANC_CORE_SOURCES} + ${ORTHANC_DICOM_SOURCES} ${AUTOGENERATED_SOURCES} ) @@ -292,17 +287,12 @@ ## Build the Orthanc server ##################################################################### -# "ServerLibrary" contains DCMTK add_library(ServerLibrary STATIC ${ORTHANC_SERVER_PCH} ${ORTHANC_SERVER_SOURCES} - ${ORTHANC_DICOM_SOURCES} ) -# Ensure autogenerated code is built before building ServerLibrary -add_dependencies(ServerLibrary CoreLibrary) - add_executable(Orthanc OrthancServer/main.cpp ${ORTHANC_RESOURCES} @@ -310,17 +300,12 @@ target_link_libraries(Orthanc ServerLibrary CoreLibrary ${DCMTK_LIBRARIES}) -if (${OPENSSL_SOURCES_LENGTH} GREATER 0) - target_link_libraries(Orthanc OpenSSL) -endif() - install( TARGETS Orthanc RUNTIME DESTINATION sbin ) - ##################################################################### ## Build the unit tests ##################################################################### @@ -333,10 +318,6 @@ target_link_libraries(UnitTests ServerLibrary CoreLibrary ${DCMTK_LIBRARIES}) -if (${OPENSSL_SOURCES_LENGTH} GREATER 0) - target_link_libraries(UnitTests OpenSSL) -endif() - ##################################################################### diff -r 233d6eeef799 -r a88c3ea0c96d Resources/CMake/OrthancFrameworkConfiguration.cmake --- a/Resources/CMake/OrthancFrameworkConfiguration.cmake Wed Aug 30 12:29:48 2017 +0200 +++ b/Resources/CMake/OrthancFrameworkConfiguration.cmake Wed Aug 30 13:11:37 2017 +0200 @@ -116,7 +116,7 @@ include(${CMAKE_CURRENT_LIST_DIR}/LibP11Configuration.cmake) add_definitions(-DORTHANC_ENABLE_PKCS11=1) - list(APPEND ORTHANC_CORE_SOURCES + list(APPEND ORTHANC_CORE_SOURCES_INTERNAL ${ORTHANC_ROOT}/Core/Pkcs11.cpp ) else() @@ -400,6 +400,14 @@ ## Gathering of all the source code ##################################################################### +# The "xxx_INTERNAL" variables list the source code that belongs to +# the Orthanc project. It can be used to configure precompiled headers +# if using Microsoft Visual Studio. + +# The "xxx_DEPENDENCIES" variables list the source code coming from +# third-party dependencies. + + set(ORTHANC_CORE_SOURCES_DEPENDENCIES ${BOOST_SOURCES} ${CIVETWEB_SOURCES}