aboutsummaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorOscar Fuentes <ofv@wanadoo.es>2009-11-05 18:57:56 +0000
committerOscar Fuentes <ofv@wanadoo.es>2009-11-05 18:57:56 +0000
commit20f17149a8b158690c9ac72c03014b0d269da49c (patch)
tree4b3df1dbdf5524c84245491c08b85d97ae5c9f63 /cmake
parentc5600c89d61e25f0662847a81af8afbf264caee4 (diff)
downloadexternal_llvm-20f17149a8b158690c9ac72c03014b0d269da49c.zip
external_llvm-20f17149a8b158690c9ac72c03014b0d269da49c.tar.gz
external_llvm-20f17149a8b158690c9ac72c03014b0d269da49c.tar.bz2
CMake: do not test for pthread and dl libraries on Windows (except
Cygwin). Fixes PR 5368. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86152 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'cmake')
-rwxr-xr-xcmake/config-ix.cmake18
1 files changed, 12 insertions, 6 deletions
diff --git a/cmake/config-ix.cmake b/cmake/config-ix.cmake
index acf3a2e..9351f26 100755
--- a/cmake/config-ix.cmake
+++ b/cmake/config-ix.cmake
@@ -39,7 +39,9 @@ check_include_file(malloc.h HAVE_MALLOC_H)
check_include_file(malloc/malloc.h HAVE_MALLOC_MALLOC_H)
check_include_file(memory.h HAVE_MEMORY_H)
check_include_file(ndir.h HAVE_NDIR_H)
-check_include_file(pthread.h HAVE_PTHREAD_H)
+if( NOT LLVM_ON_WIN32 )
+ check_include_file(pthread.h HAVE_PTHREAD_H)
+endif()
check_include_file(setjmp.h HAVE_SETJMP_H)
check_include_file(signal.h HAVE_SIGNAL_H)
check_include_file(stdint.h HAVE_STDINT_H)
@@ -63,10 +65,12 @@ check_include_file(utime.h HAVE_UTIME_H)
check_include_file(windows.h HAVE_WINDOWS_H)
# library checks
-check_library_exists(pthread pthread_create "" HAVE_LIBPTHREAD)
-check_library_exists(pthread pthread_getspecific "" HAVE_PTHREAD_GETSPECIFIC)
-check_library_exists(pthread pthread_rwlock_init "" HAVE_PTHREAD_RWLOCK_INIT)
-check_library_exists(dl dlopen "" HAVE_LIBDL)
+if( NOT LLVM_ON_WIN32 )
+ check_library_exists(pthread pthread_create "" HAVE_LIBPTHREAD)
+ check_library_exists(pthread pthread_getspecific "" HAVE_PTHREAD_GETSPECIFIC)
+ check_library_exists(pthread pthread_rwlock_init "" HAVE_PTHREAD_RWLOCK_INIT)
+ check_library_exists(dl dlopen "" HAVE_LIBDL)
+endif()
# function checks
check_symbol_exists(getpagesize unistd.h HAVE_GETPAGESIZE)
@@ -86,7 +90,9 @@ check_symbol_exists(malloc_zone_statistics malloc/malloc.h
check_symbol_exists(mkdtemp "stdlib.h;unistd.h" HAVE_MKDTEMP)
check_symbol_exists(mkstemp "stdlib.h;unistd.h" HAVE_MKSTEMP)
check_symbol_exists(mktemp "stdlib.h;unistd.h" HAVE_MKTEMP)
-check_symbol_exists(pthread_mutex_lock pthread.h HAVE_PTHREAD_MUTEX_LOCK)
+if( NOT LLVM_ON_WIN32 )
+ check_symbol_exists(pthread_mutex_lock pthread.h HAVE_PTHREAD_MUTEX_LOCK)
+endif()
check_symbol_exists(sbrk unistd.h HAVE_SBRK)
check_symbol_exists(strtoll stdlib.h HAVE_STRTOLL)
check_symbol_exists(strerror string.h HAVE_STRERROR)