From 4311f439e07a7c6f4823b2b6b9f7028f23775103 Mon Sep 17 00:00:00 2001 From: Gulin7 Date: Thu, 28 Nov 2024 23:16:06 +0200 Subject: [PATCH] Modified test CMakeList --- test/CMakeLists.txt | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 5ff1031e..e5f96c12 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -139,8 +139,15 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") /we4906 # string literal cast to 'LPWSTR' /we4928 # illegal copy-initialization; more than one user-defined conversion has been implicitly applied /we5038 # data member 'member1' will be initialized after data member 'member2' - /Zc:__cplusplus - /MD) + /Zc:__cplusplus) + target_compile_options(${test_target} + PRIVATE + $<$:/DMSVC_RUNTIME_LIBRARY=MultiThreadedDLL> + ) + target_compile_options(${test_target_catch2} + PRIVATE + $<$:/DMSVC_RUNTIME_LIBRARY=MultiThreadedDLL> + ) elseif(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang") set(compiles_options -Wall # reasonable and standard @@ -214,10 +221,6 @@ target_compile_options(${test_target_catch2} target_link_options(${test_target_catch2} PRIVATE $<$:${SANITIZER_LINK_OPTIONS}>) -target_compile_definitions(${test_target_catch2} - PRIVATE - _ITERATOR_DEBUG_LEVEL=0 -) # We do not use non-standard C++ set_target_properties(${test_target_catch2} PROPERTIES CMAKE_CXX_EXTENSIONS OFF) target_compile_features(${test_target_catch2} PRIVATE cxx_std_20)