# HG changeset patch # User Sebastien Jodogne # Date 1681315464 -7200 # Node ID cdeb7f027c1b7945c886e36fdc8a0cc161bc270c # Parent a856daf7174523f46421496192da43e13864ec73# Parent 043bf0958614d816b65cde310aa508bc8510620b integration mainline->db-protobuf diff -r a856daf71745 -r cdeb7f027c1b OrthancServer/CMakeLists.txt --- a/OrthancServer/CMakeLists.txt Wed Apr 12 17:56:13 2023 +0200 +++ b/OrthancServer/CMakeLists.txt Wed Apr 12 18:04:24 2023 +0200 @@ -337,6 +337,8 @@ # headers might get broken! if (MSVC) + add_definitions(-DORTHANC_USE_PRECOMPILED_HEADERS=1) + set(TMP ${ORTHANC_CORE_SOURCES_INTERNAL} ${ORTHANC_DICOM_SOURCES_INTERNAL} @@ -376,13 +378,6 @@ ${AUTOGENERATED_SOURCES} ) -if (MSVC) - set_target_properties( - CoreLibrary - PROPERTIES COMPILE_DEFINITIONS "ORTHANC_USE_PRECOMPILED_HEADERS=1" - ) -endif() - add_dependencies(CoreLibrary AutogeneratedTarget) if (LIBICU_LIBRARIES) @@ -424,13 +419,6 @@ ${ORTHANC_SERVER_SOURCES} ) -if (MSVC) - set_target_properties( - ServerLibrary - PROPERTIES COMPILE_DEFINITIONS "ORTHANC_USE_PRECOMPILED_HEADERS=1" - ) -endif() - # Ensure autogenerated code is built before building ServerLibrary add_dependencies(ServerLibrary CoreLibrary OrthancDatabaseProtobuf) @@ -469,13 +457,6 @@ ${BOOST_EXTENDED_SOURCES} ) -if (MSVC) - set_target_properties( - UnitTests - PROPERTIES COMPILE_DEFINITIONS "ORTHANC_USE_PRECOMPILED_HEADERS=1" - ) -endif() - target_link_libraries(UnitTests ServerLibrary CoreLibrary