diff --git a/3rdparty/gtest/CMakeLists.txt b/3rdparty/gtest/CMakeLists.txt index 77f0b58..d529d90 100644 --- a/3rdparty/gtest/CMakeLists.txt +++ b/3rdparty/gtest/CMakeLists.txt @@ -13,7 +13,7 @@ option( gtest_force_shared_crt "Use shared (DLL) run-time lib even when Google Test is built as static lib." - ON) + OFF) option(gtest_build_tests "Build all of gtest's own tests." OFF) @@ -59,6 +59,10 @@ if (POLICY CMP0063) # Visibility cmake_policy(SET CMP0063 NEW) endif (POLICY CMP0063) +if (POLICY CMP0077) # Visibility + cmake_policy(SET CMP0077 NEW) +endif (POLICY CMP0077) + if (COMMAND set_up_hermetic_build) set_up_hermetic_build() endif() diff --git a/CMakeLists.txt b/CMakeLists.txt index 72bea61..08d6c15 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -4,7 +4,7 @@ project(cpp-ipc) option(LIBIPC_BUILD_TESTS "Build all of libipc's own tests." OFF) option(LIBIPC_BUILD_DEMOS "Build all of libipc's own demos." OFF) option(LIBIPC_BUILD_SHARED_LIBS "Build shared libraries (DLLs)." OFF) -option(LIBIPC_USE_STATIC_CRT "Set to ON to build with static CRT on Windows (/MT)." ON ) +option(LIBIPC_USE_STATIC_CRT "Set to ON to build with static CRT on Windows (/MT)." OFF) set(CMAKE_POSITION_INDEPENDENT_CODE ON) set(CMAKE_CXX_STANDARD 17) @@ -38,7 +38,6 @@ add_subdirectory(src) if (LIBIPC_BUILD_TESTS) set(GOOGLETEST_VERSION 1.10.0) - set(CMAKE_POLICY_DEFAULT_CMP0077 NEW) set(gtest_force_shared_crt $>) add_subdirectory(3rdparty/gtest) add_subdirectory(test)