summaryrefslogtreecommitdiff
path: root/build/configure.ac.system
diff options
context:
space:
mode:
Diffstat (limited to 'build/configure.ac.system')
-rw-r--r--build/configure.ac.system12
1 files changed, 12 insertions, 0 deletions
diff --git a/build/configure.ac.system b/build/configure.ac.system
index 3f6ab7e2..5194fe07 100644
--- a/build/configure.ac.system
+++ b/build/configure.ac.system
@@ -162,3 +162,15 @@ dnl Test for the tools required for building one big test binary
dnl
AC_CHECK_FUNCS(fork waitpid raise)
+
+dnl ===========================================================================
+
+have_real_pthread=no
+real_pthread_REQUIRES="pthread"
+PKG_CHECK_MODULES(real_pthread, $real_pthread_REQUIRES,
+ [have_real_pthread=yes],
+ [AC_CHECK_HEADERS([pthread.h],
+ [CAIRO_CC_TRY_FLAG("-pthread",, real_pthread_CFLAGS="-pthread", real_pthread_CFLAGS="")
+ real_pthread_LIBS="-lpthread"],
+ [have_real_pthread="no (requires $real_pthread_REQUIRES)"])])
+AM_CONDITIONAL(HAVE_REAL_PTHREAD, test "x$have_real_pthread" = "xyes")