summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Turner <[email protected]>2012-09-27 15:49:52 -0700
committerMatt Turner <[email protected]>2012-10-01 15:20:50 -0700
commitdd4fde8f674f5e3efa19e929f97de4ecfd82391b (patch)
tree1994a7221b1f1336f9e4270d382464788b27f429
parent00d80b3a6f0937a69d23b4956e26f3ffc924d3d6 (diff)
build: Set PTHREAD_LIBS for pkgconfig files if empty
-rw-r--r--configure.ac4
1 files changed, 4 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 770df2f1a29..dc2720da088 100644
--- a/configure.ac
+++ b/configure.ac
@@ -509,6 +509,10 @@ AC_CHECK_DECLS([signbit],[],
dnl Check for pthreads
AX_PTHREAD
+dnl AX_PTHREADS leaves PTHREAD_LIBS empty for gcc and sets PTHREAD_CFLAGS
+dnl to -pthread, which causes problems if we need -lpthread to appear in
+dnl pkgconfig files.
+test -z "$PTHREAD_LIBS" && PTHREAD_LIBS="-lpthread"
dnl SELinux awareness.
AC_ARG_ENABLE([selinux],