diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index 907884293e..32c5f703e6 100644 --- a/configure.ac +++ b/configure.ac @@ -1924,7 +1924,8 @@ AC_CHECK_FUNC([ffs], [AC_DEFINE([HAS_FFS])]) AC_CHECK_FUNC([_BitScanForward], [AC_DEFINE([HAS_BITSCANFORWARD])]) ## pthread_getaffinity_np, args differ from GNU and BSD -AC_COMPILE_IFELSE( +AC_MSG_CHECKING([arguments for pthread_getaffinity_np]) +AC_LINK_IFELSE( [AC_LANG_PROGRAM( [[#define _GNU_SOURCE #include <sched.h> @@ -1933,8 +1934,9 @@ AC_COMPILE_IFELSE( CPU_ZERO(&cs); CPU_COUNT(&cs); pthread_getaffinity_np(pthread_self(), sizeof(cs), &cs);]])], - [AC_DEFINE([HAS_GNU_GETAFFINITY_NP])], - [AC_COMPILE_IFELSE( + [AC_MSG_RESULT([gnu]) + AC_DEFINE([HAS_GNU_GETAFFINITY_NP])], + [AC_LINK_IFELSE( [AC_LANG_PROGRAM( [[#include <pthread.h> #include <pthread_np.h> @@ -1944,7 +1946,9 @@ AC_COMPILE_IFELSE( CPU_ZERO(&cs); CPU_COUNT(&cs); pthread_getaffinity_np(pthread_self(), sizeof(cs), &cs);]])], - [AC_DEFINE([HAS_BSD_GETAFFINITY_NP])])]) + [AC_MSG_RESULT([BSD]) + AC_DEFINE([HAS_BSD_GETAFFINITY_NP])], + [AC_MSG_RESULT([pthread_getaffinity_np not found])])]) ## ZSTD compression library |