summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt6
1 files changed, 5 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4ff7728e1..2b07ee20b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -32,7 +32,7 @@ include(CheckFunctionExists)
include(CheckStructHasMember)
include(GNUInstallDirs)
include(TestBigEndian)
-find_package(Threads REQUIRED)
+find_package(Threads)
find_package(LFS REQUIRED)
find_package(Iconv REQUIRED)
@@ -152,6 +152,10 @@ test_big_endian(WORDS_BIGENDIAN)
# FreeBSD
add_definitions(-D_WITH_GETLINE=1)
+if (CMAKE_USE_PTHREADS_INIT)
+ set(HAVE_PTHREAD 1)
+endif()
+
CHECK_INCLUDE_FILES(machine/endian.h HAVE_MACHINE_ENDIAN_H)
CHECK_INCLUDE_FILES(sys/endian.h HAVE_SYS_ENDIAN_H)
CHECK_INCLUDE_FILES(endian.h HAVE_ENDIAN_H)