Skip to content
Snippets Groups Projects
Commit 80417507 authored by Atkins, Charles Vernon's avatar Atkins, Charles Vernon
Browse files

Fix pthread linkage for googletest

parent 3bac4a3b
No related branches found
No related tags found
1 merge request!95Add read validation to engine tests
......@@ -2,8 +2,3 @@ set(BUILD_GTEST ON)
set(BUILD_GMOCK OFF)
add_subdirectory(googletest)
# Fix missing usage requirements
target_include_directories(gtest
INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}/googletest/googletest/include
)
......@@ -96,6 +96,9 @@ cxx_library(gtest "${cxx_strict}" src/gtest-all.cc)
cxx_library(gtest_main "${cxx_strict}" src/gtest_main.cc)
target_link_libraries(gtest_main gtest)
find_package(Threads REQUIRED)
target_link_libraries(gtest ${CMAKE_THREAD_LIBS_INIT})
# If the CMake version supports it, attach header directory information
# to the targets for when we are part of a parent build (ie being pulled
# in via add_subdirectory() rather than being a standalone build).
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment