summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2007-11-30 12:53:16 +0000
committerRainer Gerhards <rgerhards@adiscon.com>2007-11-30 12:53:16 +0000
commit6ff91dbe9bd4a9f01775429df22261ed5de0422a (patch)
treed95b7337ff623d546ecc79cc6e7419a76743a9e8
parent872ace99523068355ec8c9f55d0dd30150e7c096 (diff)
downloadrsyslog-6ff91dbe9bd4a9f01775429df22261ed5de0422a.tar.gz
rsyslog-6ff91dbe9bd4a9f01775429df22261ed5de0422a.tar.xz
rsyslog-6ff91dbe9bd4a9f01775429df22261ed5de0422a.zip
Michael Biebl helped do the -pthread compiler switch right in autotools. So
here I am applying his patch. Thanks, Michael!
-rw-r--r--Makefile.am2
-rw-r--r--configure.ac6
2 files changed, 5 insertions, 3 deletions
diff --git a/Makefile.am b/Makefile.am
index e9373843..b296a06a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -60,7 +60,7 @@ rsyslogd_SOURCES = \
action.c \
action.h
-rsyslogd_CPPFLAGS = -D_PATH_MODDIR=\"$(pkglibdir)/\"
+rsyslogd_CPPFLAGS = -D_PATH_MODDIR=\"$(pkglibdir)/\" $(pthreads_cflags)
rsyslogd_LDADD = $(zlib_libs) $(pthreads_libs) -ldl
rsyslogd_LDFLAGS = -export-dynamic
diff --git a/configure.ac b/configure.ac
index e2fa4878..754f63c3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -143,8 +143,10 @@ if test "x$enable_pthreads" != "xno"; then
[pthread_create],
[
AC_DEFINE([USE_PTHREADS], [1], [Multithreading support enabled.])
- CFLAGS="$CFLAGS -pthread"
- AC_SUBST(pthreads_libs)
+ pthreads_libs="-lpthread"
+ pthreads_cflags="-pthread"
+ AC_SUBST(pthreads_libs)
+ AC_SUBST(pthreads_cflags)
],
[AC_MSG_FAILURE([pthread is missing])],
[-lpthread]