diff options
author | Jon Turney <[email protected]> | 2016-06-07 14:22:31 +0000 |
---|---|---|
committer | Jon Turney <[email protected]> | 2016-07-15 19:46:54 +0100 |
commit | 7d8edbaee72969355dc3519b91671ff930e01b2e (patch) | |
tree | 4e484bff7c2d81e5a1b5c489e2cf428eea0824da /configure.ac | |
parent | 5d303867f57578fcbe0c2fb30a9646b1f4fd6b46 (diff) |
configure: Don't require pthread-stubs on Cygwin
Commit 1f4869a2 unconditionally requires pthread-stubs. Unfortunately, the
cleverness that pthread-stubs is doesn't work with PE/COFF, and historically
Cygwin doesn't have a pthread-stubs.pc.
Don't require pthread-stubs on Cygwin.
Signed-off-by: Jon Turney <[email protected]>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac index c1de4d8226c..54416b472bb 100644 --- a/configure.ac +++ b/configure.ac @@ -822,9 +822,21 @@ dnl to -pthread, which causes problems if we need -lpthread to appear in dnl pkgconfig files. test -z "$PTHREAD_LIBS" && PTHREAD_LIBS="-lpthread" -PKG_CHECK_MODULES(PTHREADSTUBS, pthread-stubs) -AC_SUBST(PTHREADSTUBS_CFLAGS) -AC_SUBST(PTHREADSTUBS_LIBS) +dnl pthread-stubs is mandatory on targets where it exists +case "$host_os" in +cygwin* ) + pthread_stubs_possible="no" + ;; +* ) + pthread_stubs_possible="yes" + ;; +esac + +if test "x$pthread_stubs_possible" = xyes; then + PKG_CHECK_MODULES(PTHREADSTUBS, pthread-stubs) + AC_SUBST(PTHREADSTUBS_CFLAGS) + AC_SUBST(PTHREADSTUBS_LIBS) +fi dnl SELinux awareness. AC_ARG_ENABLE([selinux], |