fetch same gtest version
This commit is contained in:
@@ -73,14 +73,16 @@ endif()
|
|||||||
if (OPENMESH_BUILD_UNIT_TESTS)
|
if (OPENMESH_BUILD_UNIT_TESTS)
|
||||||
# Fetch Gtest from github
|
# Fetch Gtest from github
|
||||||
include(FetchContent)
|
include(FetchContent)
|
||||||
|
|
||||||
FetchContent_Declare(
|
FetchContent_Declare(
|
||||||
googletest
|
googletest
|
||||||
GIT_REPOSITORY https://github.com/google/googletest.git
|
GIT_REPOSITORY https://github.com/google/googletest.git
|
||||||
GIT_TAG f8d7d77c06936315286eb55f8de22cd23c188571 # v1.14.0
|
GIT_TAG release-1.10.0
|
||||||
#FIND_PACKAGE_ARGS NAMES GTest
|
|
||||||
)
|
)
|
||||||
# For Windows: Prevent overriding the parent project's compiler/linker settings
|
if(WIN32)
|
||||||
|
# avoid linking errors, cf https://stackoverflow.com/questions/12540970/how-to-make-gtest-build-mdd-instead-of-mtd-by-default-using-cmake
|
||||||
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE)
|
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE)
|
||||||
|
endif()
|
||||||
FetchContent_MakeAvailable(googletest)
|
FetchContent_MakeAvailable(googletest)
|
||||||
|
|
||||||
enable_testing()
|
enable_testing()
|
||||||
|
|||||||
Reference in New Issue
Block a user