diff --git a/configure b/configure index 714b42dcb..f81ed1e86 100755 --- a/configure +++ b/configure @@ -18634,6 +18634,7 @@ fi if test "x$enable_systemd" != xno; then : + pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD" >&5 $as_echo_n "checking for SYSTEMD... " >&6; } @@ -18796,6 +18797,7 @@ $as_echo "#define HAVE_SYSTEMD 1" >>confdefs.h ;; esac + fi if test "x$have_systemd" = xyes; then USE_SYSTEMD_TRUE= diff --git a/doc/Changelog b/doc/Changelog index f8fe42b3e..a149dff79 100644 --- a/doc/Changelog +++ b/doc/Changelog @@ -1,3 +1,6 @@ +13 February 2017: Wouter + - Fix autoconf of systemd check for lack of pkg-config. + 10 February 2017: Wouter - Fix pythonmod for typedef changes. - Fix dnstap for warning of set but not used. diff --git a/systemd.m4 b/systemd.m4 index 553822418..e5d4e27f6 100644 --- a/systemd.m4 +++ b/systemd.m4 @@ -6,6 +6,7 @@ AC_ARG_ENABLE([systemd], [], [enable_systemd=no]) have_systemd=no AS_IF([test "x$enable_systemd" != xno], [ + ifdef([PKG_CHECK_MODULES], [ dnl systemd v209 or newer PKG_CHECK_MODULES([SYSTEMD], [libsystemd], [have_systemd=yes], [have_systemd=no]) dnl old systemd library @@ -23,5 +24,8 @@ AS_IF([test "x$enable_systemd" != xno], [ LIBS="$LIBS $SYSTEMD_LIBS" ] ) + ], [ + AC_MSG_ERROR([systemd enabled but need pkg-config to configure for it]) + ]) ]) AM_CONDITIONAL([USE_SYSTEMD], [test "x$have_systemd" = xyes])