diff options
author | Nikias Bassen | 2019-02-04 03:23:20 +0100 |
---|---|---|
committer | Nikias Bassen | 2019-02-04 03:23:20 +0100 |
commit | 640165088dcdfd6ac1587df09eaeecfffabdd5df (patch) | |
tree | 0215789fbcc342fb7cf0dff23094d2264e337173 /configure.ac | |
parent | 620a6b7a84946f12f471a81918da81fc3d104de6 (diff) | |
download | idevicerestore-640165088dcdfd6ac1587df09eaeecfffabdd5df.tar.gz idevicerestore-640165088dcdfd6ac1587df09eaeecfffabdd5df.tar.bz2 |
build: Check for pthread properly (non-win32)
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 29 |
1 files changed, 18 insertions, 11 deletions
diff --git a/configure.ac b/configure.ac index 6191c89..ea8ed08 100644 --- a/configure.ac +++ b/configure.ac @@ -46,18 +46,25 @@ PKG_CHECK_MODULES(zlib, zlib) GLOBAL_CFLAGS="" AC_LDADD="" AC_LDFLAGS="" -case "$host_os" in - darwin*) - ;; - linux*) - ;; - mingw*) - GLOBAL_CFLAGS+="-DWIN32 -D__LITTLE_ENDIAN__=1" - AC_LDFLAGS+="-static-libgcc" - ;; - *) - ;; +AC_MSG_CHECKING([whether we need platform-specific build settings]) +case ${host_os} in + *mingw32*|*cygwin*) + AC_MSG_RESULT([yes]) + AC_DEFINE(WINVER, 0x0501, [minimum Windows version]) + win32=true + GLOBAL_CFLAGS+="-DWIN32 -D__LITTLE_ENDIAN__=1" + AC_LDFLAGS+="-static-libgcc" + ;; + darwin*) + AC_MSG_RESULT([no]) + AX_PTHREAD([], [AC_MSG_ERROR([pthread is required to build $PACKAGE])]) + ;; + *) + AC_MSG_RESULT([yes]) + AX_PTHREAD([], [AC_MSG_ERROR([pthread is required to build $PACKAGE])]) + ;; esac +AM_CONDITIONAL(WIN32, test x$win32 = xtrue) AC_CHECK_FUNCS([strsep strcspn mkstemp]) if test x$ac_cv_func_strsep != xyes; then |