Skip to content

Commit

Permalink
COMP: Disable GTest using threads
Browse files Browse the repository at this point in the history
Removes Threads::Threads form exported libraries dependencies, to
simply exports.

Addresses InsightSoftwareConsortium#1502.
  • Loading branch information
blowekamp committed Dec 19, 2019
1 parent d4ff96b commit ed712c2
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Modules/ThirdParty/GoogleTest/src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@
# settings on Windows
set(gtest_force_shared_crt ON CACHE INTERNAL "")

# google test does not properly use pthreads on mingw
if (MINGW)
set(gtest_disable_pthreads ON CACHE INTERNAL "")
endif()
# - google test does not properly use pthreads on mingw
# - google test uses CMake modern "Threads::Threads" alias which is
# not properly exported easily while ITK uses the old library
# variable style
set(gtest_disable_pthreads ON CACHE INTERNAL "")


set(BUILD_GTEST ON CACHE INTERNAL "")
set(BUILD_GMOCK OFF CACHE INTERNAL "")
Expand Down

0 comments on commit ed712c2

Please sign in to comment.