add a configure flag to control systemd support

This way people can easily disable systemd support locally.
merge-requests/1/head
Christopher Brannon 2015-07-08 06:37:14 -04:00 zatwierdzone przez m. allan noah
rodzic 5337625f3a
commit c4ae327be5
1 zmienionych plików z 18 dodań i 11 usunięć

Wyświetl plik

@ -343,17 +343,24 @@ dnl $as_echo "in order to autodetect network scanners in kodakaio."
dnl with_cups="no"
dnl fi
dnl added by llagendijk 12/7/2012 to detect systemd for saned
$as_echo_n "Checking for systemd..."
if test -e /usr/include/systemd/sd-daemon.h ; then
AC_DEFINE(HAVE_SYSTEMD, 1, [Is /usr/include/systemd/sd-daemon.h available?])
with_systemd="yes"
SYSTEMD_LIBS=" -lsystemd-daemon"
AC_SUBST(SYSTEMD_LIBS)
$as_echo "yes"
else
with_systemd="no"
$as_echo "no"
AC_ARG_WITH(systemd,
AC_HELP_STRING([--with-systemd], [enable systemd support @<:@default=yes@:>@]))
if test "x$with_systemd" != xno ; then
dnl added by llagendijk 12/7/2012 to detect systemd for saned
$as_echo_n "Checking for systemd..."
if test -e /usr/include/systemd/sd-daemon.h ; then
AC_DEFINE(HAVE_SYSTEMD, 1, [Is /usr/include/systemd/sd-daemon.h available?])
have_systemd="yes"
SYSTEMD_LIBS=" -lsystemd-daemon"
AC_SUBST(SYSTEMD_LIBS)
$as_echo "yes"
else
have_systemd="no"
$as_echo "no"
if test "x$with_systemd" = xyes; then
AC_MSG_ERROR([Systemd support was requested but systemd was not found])
fi
fi
fi
dnl ***********