mirror of
https://github.com/fmtlib/fmt.git
synced 2024-09-03 21:49:01 +00:00
Don't use pthreads if they are not available
This commit is contained in:
parent
0332284ce3
commit
7859f81233
@ -119,7 +119,11 @@ add_library(gmock STATIC
|
|||||||
gmock/gmock-gtest-all.cc gmock/gmock/gmock.h
|
gmock/gmock-gtest-all.cc gmock/gmock/gmock.h
|
||||||
gmock/gtest/gtest.h gmock/gtest/gtest-spi.h)
|
gmock/gtest/gtest.h gmock/gtest/gtest-spi.h)
|
||||||
find_package(Threads)
|
find_package(Threads)
|
||||||
target_link_libraries(gmock ${CMAKE_THREAD_LIBS_INIT})
|
if (Threads_FOUND)
|
||||||
|
target_link_libraries(gmock ${CMAKE_THREAD_LIBS_INIT})
|
||||||
|
else ()
|
||||||
|
target_compile_definitions(gmock PUBLIC GTEST_HAS_PTHREAD=0)
|
||||||
|
endif ()
|
||||||
|
|
||||||
# Check if variadic templates are working and not affected by GCC bug 39653:
|
# Check if variadic templates are working and not affected by GCC bug 39653:
|
||||||
# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=39653
|
# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=39653
|
||||||
|
Loading…
Reference in New Issue
Block a user