diff options
| author | Michele Calgaro <michele.calgaro@yahoo.it> | 2024-12-27 12:33:55 +0900 |
|---|---|---|
| committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2024-12-27 20:44:51 +0900 |
| commit | 5d649b164b64e3e9e93eb3929b4e9e37f78a44ed (patch) | |
| tree | a645d2c9bc55f2ef96e4eafac0717ee0623dc88f /ConfigureChecks.cmake | |
| parent | f386da73ff591f119184b585085e13c7624fc9f7 (diff) | |
| download | arts-5d649b16.tar.gz arts-5d649b16.zip | |
Replace pthread and dl linking with cmake-based variables
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
(cherry picked from commit 45ff2423e03a3ed3c8855c7b599a664891623ba1)
Diffstat (limited to 'ConfigureChecks.cmake')
| -rw-r--r-- | ConfigureChecks.cmake | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake index 08fe29b..9efdde7 100644 --- a/ConfigureChecks.cmake +++ b/ConfigureChecks.cmake @@ -50,22 +50,13 @@ check_include_file( "pthread.h" HAVE_LIBPTHREAD ) ##### check for system libraries ################ -set( DL_LIBRARIES dl ) -check_library_exists( ${DL_LIBRARIES} dlopen /lib HAVE_LIBDL ) -if( NOT HAVE_LIBDL ) - unset( DL_LIBRARIES ) - check_function_exists( dlopen HAVE_DLOPEN ) - if( HAVE_DLOPEN ) - set( HAVE_LIBDL 1 ) - endif( HAVE_DLOPEN ) -endif( NOT HAVE_LIBDL ) - find_package( Threads ) ##### check for functions ####################### -tde_save_and_set( CMAKE_REQUIRED_LIBRARIES ${DL_LIBRARIES} ) +tde_save_and_set( CMAKE_REQUIRED_LIBRARIES ${CMAKE_DL_LIBS} ) +check_function_exists( dlopen HAVE_LIBDL ) check_function_exists( dlerror HAVE_DLERROR ) check_function_exists( strcmp HAVE_STRCMP ) check_function_exists( strchr HAVE_STRCHR ) |
