Do not force static runtime for boost unless building for win32
authoruser <balthazar@yandex.ru>
Sun, 26 Dec 2021 09:23:31 +0000 (12:23 +0300)
committeruser <balthazar@yandex.ru>
Sun, 26 Dec 2021 09:23:31 +0000 (12:23 +0300)
CMakeLists.txt
src/CMakeLists.txt

index dd80480..41f91db 100644 (file)
@@ -51,7 +51,9 @@ set(CMAKE_CXX_FLAGS "/O2 /GR /EHsc")
 endif()
 
 set(Boost_USE_STATIC_LIBS   ON)
+if(WIN32)
 set(Boost_USE_STATIC_RUNTIME ON)
+endif()
 find_package(Boost REQUIRED COMPONENTS atomic chrono filesystem program_options system thread)
 set(OPENSSL_USE_STATIC_LIBS ON)
 find_package(OpenSSL REQUIRED)
index 7d8f3c5..1940f5f 100644 (file)
@@ -39,7 +39,9 @@ endif()
 set(CMAKE_CXX_EXTENSIONS OFF)
 
 set(Boost_USE_STATIC_LIBS   ON)
+if(WIN32)
 set(Boost_USE_STATIC_RUNTIME ON)
+endif()
 find_package(Boost REQUIRED COMPONENTS atomic chrono filesystem program_options system thread)
 set(OPENSSL_USE_STATIC_LIBS ON)
 find_package(OpenSSL REQUIRED)