Set gtest_force_shared_crt, take 2.

This commit is contained in:
Victor Zverovich 2012-12-12 10:37:27 -08:00
parent a2a8741348
commit 771746bd7e

View File

@ -21,7 +21,10 @@ endif ()
# pre-compiled copy of Google Test (for example, into /usr/local)?" # pre-compiled copy of Google Test (for example, into /usr/local)?"
# at http://code.google.com/p/googletest/wiki/FAQ for more details. # at http://code.google.com/p/googletest/wiki/FAQ for more details.
if (EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/gtest/CMakeLists.txt) if (EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/gtest/CMakeLists.txt)
set(gtest_force_shared_crt ON) option(
gtest_force_shared_crt
"Use shared (DLL) run-time lib even when Google Test is built as static lib."
ON)
add_subdirectory(gtest) add_subdirectory(gtest)
include_directories(gtest/include) include_directories(gtest/include)
link_directories(${CMAKE_CURRENT_BINARY_DIR}/gtest) link_directories(${CMAKE_CURRENT_BINARY_DIR}/gtest)