summaryrefslogtreecommitdiff
path: root/m4/fp_check_pthreads.m4
diff options
context:
space:
mode:
Diffstat (limited to 'm4/fp_check_pthreads.m4')
-rw-r--r--m4/fp_check_pthreads.m44
1 files changed, 4 insertions, 0 deletions
diff --git a/m4/fp_check_pthreads.m4 b/m4/fp_check_pthreads.m4
index 68f17177c3..a93496f614 100644
--- a/m4/fp_check_pthreads.m4
+++ b/m4/fp_check_pthreads.m4
@@ -27,6 +27,10 @@ AC_DEFUN([FP_CHECK_PTHREADS],
])
AC_DEFINE_UNQUOTED([NEED_PTHREAD_LIB], [$need_lpthread],
[Define 1 if we need to link code using pthreads with -lpthread])
+ AS_IF([test x"$need_lpthread" = 1],
+ [PTHREAD_LIB=pthread],
+ [PTHREAD_LIB=''])
+ AC_SUBST([PTHREAD_LIB])
dnl Setting thread names
dnl ~~~~~~~~~~~~~~~~~~~~