Skip to content

Commit

Permalink
Added default option to avoid installing googletest.
Browse files Browse the repository at this point in the history
  • Loading branch information
LTLA committed Nov 25, 2024
1 parent 1eb0f88 commit 1432392
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,13 @@ FetchContent_Declare(
googletest
URL https://github.com/google/googletest/archive/d144031940543e15423a25ae5a8a74141044862f.zip
)
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE) # For Windows: Prevent overriding the parent project's compiler/linker settings

# For Windows: Prevent overriding the parent project's compiler/linker settings
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE)

# Avoid installing GoogleTest when installing this project.
option(INSTALL_GTEST "Enable installation of googletest." OFF)

FetchContent_MakeAvailable(googletest)
target_link_libraries(tatami_test INTERFACE gtest_main)

Expand Down

0 comments on commit 1432392

Please sign in to comment.