# HG changeset patch # User Sebastien Jodogne # Date 1703237369 -3600 # Node ID 723251b2b71eb293a063900ff38bd19e69d0caec # Parent e7a04f878704715e1e4d77921d0a3a00107f8cdc# Parent f7ac06300f862f173c9d777dd9de184552870002 merge diff -r f7ac06300f86 -r 723251b2b71e OrthancFramework/Resources/CMake/Compiler.cmake --- a/OrthancFramework/Resources/CMake/Compiler.cmake Thu Dec 21 16:12:09 2023 +0100 +++ b/OrthancFramework/Resources/CMake/Compiler.cmake Fri Dec 22 10:29:29 2023 +0100 @@ -43,6 +43,13 @@ # use by "ExternalProject" in CMake SET(CMAKE_LSB_CC $ENV{LSB_CC} CACHE STRING "") SET(CMAKE_LSB_CXX $ENV{LSB_CXX} CACHE STRING "") + + # This is necessary to build "Orthanc mainline - Framework LSB + # Release" on "buildbot-worker-debian11" + set(LSB_PTHREAD_NONSHARED "${LSB_PATH}/lib64-${LSB_TARGET_VERSION}/libpthread_nonshared.a") + if (EXISTS ${LSB_PTHREAD_NONSHARED}) + set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${LSB_PTHREAD_NONSHARED}") + endif() endif() @@ -130,9 +137,11 @@ # The "--no-undefined" linker flag makes the shared libraries # (plugins ModalityWorklists and ServeFolders) fail to compile on # OpenBSD, and make the PostgreSQL plugin complain about missing - # "environ" global variable in FreeBSD. Furthermore, on Linux - # Standard Base running on Debian 12, the "-Wl,--no-undefined" - # breaks the compilation (added after Orthanc 1.12.2). + # "environ" global variable in FreeBSD. + # + # TODO - Furthermore, on Linux Standard Base running on Debian 12, + # the "-Wl,--no-undefined" seems to break the compilation (added + # after Orthanc 1.12.2). This is disabled for now. set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,--no-undefined") set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--no-undefined") endif()