mirror of
https://github.com/google/googletest.git
synced 2026-09-25 04:09:59 +03:00
Merge pull request #5053 from zmajeedforks:zmajeed_fix_msvc_crt_override
PiperOrigin-RevId: 961026014 Change-Id: I91e5a221e335372a9c5fef9082ab05800f5b2081
This commit is contained in:
@@ -71,7 +71,8 @@ macro(config_compiler_and_linker)
|
||||
# as static libraries, as we don't have to rely on CRT DLLs being available.
|
||||
# CMake always defaults to using shared CRT libraries, so we override that
|
||||
# default here.
|
||||
if (NOT BUILD_SHARED_LIBS AND NOT gtest_force_shared_crt AND NOT DEFINED CMAKE_MSVC_RUNTIME_LIBRARY)
|
||||
if (NOT BUILD_SHARED_LIBS AND NOT gtest_force_shared_crt AND NOT DEFINED CMAKE_MSVC_RUNTIME_LIBRARY
|
||||
AND CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
|
||||
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>")
|
||||
endif()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user