diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/configure.ac b/configure.ac index 920a12f4bd..efeea0658e 100644 --- a/configure.ac +++ b/configure.ac @@ -133,13 +133,23 @@ else [libsystemd-daemon], have_systemd=yes, have_systemd=no) + if test x$have_systemd=xno; then + AC_MSG_NOTICE([Okay, checking for systemd a different way...]) + PKG_CHECK_MODULES(SYSTEMD, + [libsystemd], + have_systemd=yes, + have_systemd=no) + fi fi if test x$have_systemd = xyes; then AC_DEFINE(HAVE_SYSTEMD,1,[Have systemd]) - CFLAGS="${CFLAGS} ${SYSTEMD_CFLAGS}" + TOR_SYSTEMD_CFLAGS="${SYSTEMD_CFLAGS}" TOR_SYSTEMD_LIBS="${SYSTEMD_LIBS}" + PKG_CHECK_MODULES(SYSTEMD209, [systemd >= 209], + [AC_DEFINE(HAVE_SYSTEMD_209,1,[Have systemd v209 or more])], []) fi +AC_SUBST(TOR_SYSTEMD_CFLAGS) AC_SUBST(TOR_SYSTEMD_LIBS) if test x$enable_systemd = xyes -a x$have_systemd != xyes ; then @@ -161,10 +171,6 @@ cpu workers lock up here, so I will disable threads.]) esac fi -ifdef([HAVE_SYSTEMD], [ -AC_SEARCH_LIBS([sd_watchdog_enabled], [systemd-daemon], - [AC_DEFINE(HAVE_SYSTEMD_209,1,[Have systemd v209 or more])], []) -]) case $host in *-*-solaris* ) @@ -1550,7 +1556,7 @@ fi if test "$GCC" = yes; then # Disable GCC's strict aliasing checks. They are an hours-to-debug # accident waiting to happen. - CFLAGS="$CFLAGS -Wall -fno-strict-aliasing -g -O2" + CFLAGS="$CFLAGS -Wall -fno-strict-aliasing" else # Override optimization level for non-gcc compilers CFLAGS="$CFLAGS -O" |