diff options
-rw-r--r-- | Changelog | 1 | ||||
-rw-r--r-- | configure.in | 29 |
2 files changed, 15 insertions, 15 deletions
@@ -1,4 +1,5 @@ Changes in quota-tools from 3.16 to 3.17 +* use PKG_CHECK_MODULES to check for DBUS (Ladislav Michnovic) * Implement setting of charset for emails sent by warnquota (Michael Meskes) * Added quota_nld to the list of installed programs (Jan Kara) * some typos fixes (Matthew Boyle) diff --git a/configure.in b/configure.in index e228d2a..b862db4 100644 --- a/configure.in +++ b/configure.in @@ -96,23 +96,25 @@ if test "x$enable_ext2direct" != "xno"; then fi AC_SUBST(EXT2LIBS) -AC_ARG_WITH(dbus_include, - [ --with-dbus_include=path Path to directory with dbus include directory [default=/usr/include/dbus-1.0/]], - DBUS_INCLUDE="$with_dbus_include", - DBUS_INCLUDE="/usr/include/dbus-1.0/") -AC_ARG_WITH(dbus_arch_include, - [ --with-dbus_arch_include=path Path to directory with dbus arch-dependent include directory [default=/usr/lib/dbus-1.0/include/]], - DBUS_ARCH_INCLUDE="$with_dbus_arch_include", - DBUS_ARCH_INCLUDE="/usr/lib/dbus-1.0/include/") +#AC_ARG_WITH(dbus_include, +# [ --with-dbus_include=path Path to directory with dbus include directory [default=/usr/include/dbus-1.0/]], +# DBUS_INCLUDE="$with_dbus_include", +# DBUS_INCLUDE="/usr/include/dbus-1.0/") +#AC_ARG_WITH(dbus_arch_include, +# [ --with-dbus_arch_include=path Path to directory with dbus arch-dependent include directory [default=/usr/lib/dbus-1.0/include/]], +# DBUS_ARCH_INCLUDE="$with_dbus_arch_include", +# DBUS_ARCH_INCLUDE="/usr/lib/dbus-1.0/include/") AC_ARG_ENABLE(netlink, [ --enable-netlink=[yes/no/try] Compile daemon receiving quota messages via netlink [default=no].], , enable_netlink="no") if test "x$enable_netlink" != "xno"; then + PKG_CHECK_MODULES([DBUS], [dbus-1]) + NETLINKLIBS="$DBUS_LIBS" + AC_CHECK_LIB(nl, genl_register, NETLINKLIBS="-lnl $NETLINKLIBS") - AC_CHECK_LIB(dbus-1, dbus_bus_get, NETLINKLIBS="-ldbus-1 $NETLINKLIBS") - if test "${ac_cv_lib_nl_genl_register}" != "yes" -o "${ac_cv_lib_dbus_1_dbus_bus_get}" != "yes"; then + if test -z "$NETLINKLIBS" -o -z "$DBUS_LIBS"; then if test "x$enable_netlink" = "xyes"; then AC_MSG_ERROR([Required libraries for quota netlink daemon not found.]) else @@ -121,16 +123,13 @@ if test "x$enable_netlink" != "xno"; then enable_netlink="no" NETLINKLIBS="" else - oldCPPFLAGS="$CPPFLAGS" - CPPFLAGS="-I $DBUS_INCLUDE -I $DBUS_ARCH_INCLUDE $CPPFLAGS" - AC_CHECK_HEADERS(dbus/dbus.h, have_dbus="yes") - if test "x$have_dbus" != "xyes"; then + CPPFLAGS="$DBUS_CFLAGS $CPPFLAGS" + if test -z "$DBUS_LIBS"; then if test "x$enable_netlink" = "xyes"; then AC_MSG_ERROR([Required headers for quota netlink daemon not found.]) else AC_MSG_WARN([Quota netlink daemon won't be compiled. Required headers not found.]) fi - CPPFLAGS="$oldCPPFLAGS" NETLINKLIBS="" enable_netlink="no" else |