diff options
Diffstat (limited to 'src/Native/System.Private.CoreLib.Native/configure.cmake')
-rw-r--r-- | src/Native/System.Private.CoreLib.Native/configure.cmake | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/src/Native/System.Private.CoreLib.Native/configure.cmake b/src/Native/System.Private.CoreLib.Native/configure.cmake index c84bf8971..1fbbf9c5e 100644 --- a/src/Native/System.Private.CoreLib.Native/configure.cmake +++ b/src/Native/System.Private.CoreLib.Native/configure.cmake @@ -1,18 +1,10 @@ include(CheckCXXSourceCompiles) include(CheckCXXSourceRuns) include(CheckLibraryExists) +include(CheckFunctionExists) check_library_exists(pthread pthread_condattr_setclock "" HAVE_PTHREAD_CONDATTR_SETCLOCK) -check_include_files(uuid/uuid.h HAVE_LIBUUID_H) - -if(NOT CMAKE_SYSTEM_NAME STREQUAL Darwin) - set(CMAKE_REQUIRED_LIBRARIES uuid) -endif() -check_function_exists(uuid_generate_random HAVE_UUID_GENERATE_RANDOM) -check_function_exists(uuid_generate HAVE_UUID_GENERATE) -set(CMAKE_REQUIRED_LIBRARIES) - check_cxx_source_runs(" #include <stdlib.h> #include <time.h> @@ -69,10 +61,9 @@ int main(void) }" HAVE_SCHED_GETCPU) set(CMAKE_REQUIRED_LIBRARIES) -if(NOT HAVE_LIBUUID_H) - unset(HAVE_LIBUUID_H CACHE) - message(FATAL_ERROR "Cannot find libuuid. Try installing uuid-dev or the appropriate packages for your platform") -endif() +check_include_files(gnu/lib-names.h HAVE_GNU_LIBNAMES_H) + +check_function_exists(_NSGetEnviron HAVE__NSGETENVIRON) configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/config.h.in |