diff options
author | Nikias Bassen | 2016-12-31 02:59:36 +0100 |
---|---|---|
committer | Nikias Bassen | 2016-12-31 02:59:36 +0100 |
commit | 038bb5902fcc4e981fb349fbba629eab2bdf93ff (patch) | |
tree | 7e30ed15205d6d2ea76507066aad60d1fb92aa51 /configure.ac | |
parent | a80ba9363b4dc0ea1bcdad152cf2cdc974636ad6 (diff) | |
download | libimobiledevice-038bb5902fcc4e981fb349fbba629eab2bdf93ff.tar.gz libimobiledevice-038bb5902fcc4e981fb349fbba629eab2bdf93ff.tar.bz2 |
Add ax_pthread.m4 for proper pthread cflags/ldflags
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/configure.ac b/configure.ac index 26fe819..e41baa3 100644 --- a/configure.ac +++ b/configure.ac @@ -66,25 +66,23 @@ if test "x$ac_cv_have_endian_h" = "xno"; then fi # Check for operating system -AC_MSG_CHECKING([whether to enable WIN32 build settings]) +AC_MSG_CHECKING([whether we need platform-specific build settings]) case ${host_os} in *mingw32*|*cygwin*) - win32=true AC_MSG_RESULT([yes]) - AC_CHECK_TOOL([WINDRES], [windres], AC_MSG_ERROR([windres not found])) - AC_SUBST(WINDRES) + win32=true ;; - *) - win32=false + darwin*) AC_MSG_RESULT([no]) ;; + *) + AC_MSG_RESULT([yes]) + AX_PTHREAD([], [AC_MSG_ERROR([pthread is required to build $PACKAGE_NAME])]) + AC_CHECK_LIB(pthread, [pthread_once], [], [AC_MSG_ERROR([pthread with pthread_once required to build $PACKAGE_NAME])]) + ;; esac AM_CONDITIONAL(WIN32, test x$win32 = xtrue) -if test "x$win32" != xtrue; then - AC_CHECK_LIB(pthread, [pthread_create, pthread_mutex_lock], [AC_SUBST(libpthread_LIBS,[-lpthread])], [AC_MSG_ERROR([libpthread is required to build libimobiledevice])]) -fi - # Cython Python Bindings AC_ARG_WITH([cython], [AS_HELP_STRING([--without-cython], |