X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=macros%2Fnetatalk.m4;h=c190405fae301f1b6e717f55c4c5d2d4a5591bd3;hb=793ceb303ae22266e55f8b681ab21f00aebd35e9;hp=55c6d9e48da1554b0676c1aca5342751c3e36d33;hpb=dfae8b42d7696b7a845ae9ac8198656d288f05f3;p=netatalk.git diff --git a/macros/netatalk.m4 b/macros/netatalk.m4 index 55c6d9e4..c190405f 100644 --- a/macros/netatalk.m4 +++ b/macros/netatalk.m4 @@ -35,22 +35,29 @@ AC_DEFUN([AC_NETATALK_DTRACE], [ dnl Check for dbus-glib, for AFP stats AC_DEFUN([AC_NETATALK_DBUS_GLIB], [ + atalk_cv_with_dbus=no PKG_CHECK_MODULES(DBUS, dbus-1 >= 1.1, have_dbus=yes, have_dbus=no) - PKG_CHECK_MODULES(DBUS_GLIB, gobject-2.0 >= 2.6, have_dbus_glib=yes, have_dbus_glib=no) + PKG_CHECK_MODULES(DBUS_GLIB, dbus-glib-1, have_dbus_glib=yes, have_dbus_glib=no) + PKG_CHECK_MODULES(DBUS_GTHREAD, gthread-2.0, have_dbus_gthread=yes, have_dbus_gthread=no) AC_SUBST(DBUS_CFLAGS) AC_SUBST(DBUS_LIBS) AC_SUBST(DBUS_GLIB_CFLAGS) AC_SUBST(DBUS_GLIB_LIBS) - AM_CONDITIONAL(HAVE_DBUS_GLIB, test x$have_dbus_glib = xyes -a x$have_dbus = xyes) + AC_SUBST(DBUS_GTHREAD_CFLAGS) + AC_SUBST(DBUS_GTHREAD_LIBS) + if test x$have_dbus_glib = xyes -a x$have_dbus = xyes -a x$have_dbus_gthread = xyes ; then + atalk_cv_with_dbus=yes + fi + AM_CONDITIONAL(HAVE_DBUS_GLIB, test x$atalk_cv_with_dbus = xyes) AC_ARG_WITH( dbus-sysconf-dir, - [AS_HELP_STRING([--with-dbus-sysconf-dir],[Path to dbus system bus security configuration directory (default: ${sysconfdir}/dbus-1/system.d/)])], + [AS_HELP_STRING([--with-dbus-sysconf-dir=PATH],[Path to dbus system bus security configuration directory (default: ${sysconfdir}/dbus-1/system.d/)])], ac_cv_dbus_sysdir=$withval, ac_cv_dbus_sysdir='${sysconfdir}/dbus-1/system.d' ) - if test x$have_dbus_glib = xyes -a x$have_dbus = xyes ; then + if test x$atalk_cv_with_dbus = xyes ; then AC_DEFINE(HAVE_DBUS_GLIB, 1, [Define if support for dbus-glib was found]) DBUS_SYS_DIR="$ac_cv_dbus_sysdir" AC_SUBST(DBUS_SYS_DIR)