# HG changeset patch # User Sebastien Jodogne # Date 1625040638 -7200 # Node ID adb5e86645a6044c9b8a221bb0879be2c6def210 # Parent a6b5a9e915ef5692d44cf3344a3c2ed2c87d2e0d fix lsb build on the continuous integration server in release mode diff -r a6b5a9e915ef -r adb5e86645a6 MySQL/CMakeLists.txt --- a/MySQL/CMakeLists.txt Wed Jun 30 09:12:02 2021 +0200 +++ b/MySQL/CMakeLists.txt Wed Jun 30 10:10:38 2021 +0200 @@ -132,3 +132,13 @@ set_target_properties(UnitTests PROPERTIES COMPILE_FLAGS -DORTHANC_ENABLE_LOGGING_PLUGIN=0 ) + +if ("${CMAKE_SYSTEM_VERSION}" STREQUAL "LinuxStandardBase") + # Explicitly adding "-lstdc++" during linking for LSB had to be + # introduced on the BuildBot server for LSB Release builds between + # "OrthancMySQL-4.0" and "OrthancMySQL-4.1", for unclear + # reasons. Without this option, many symbols are left undefined + # while linking "UnitTests" in release mode. Similar to: + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14001 + target_link_libraries(UnitTests stdc++) +endif()