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_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
+ saved_CFLAGS=$CFLAGS
+ saved_LIBS=$LIBS
+ CFLAGS="$CFLAGS $DBUS_GLIB_CFLAGS"
+ LIBS="$LIBS $DBUS_GLIB_LIBS"
+ AC_CHECK_FUNC([dbus_g_bus_get_private], [atalk_cv_with_dbus=yes], [atalk_cv_with_dbus=no])
+ CFLAGS="$saved_CFLAGS"
+ LIBS="$saved_LIBS"
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'
)
AC_DEFINE(HAVE_TRACKER_SPARQL, 1, [Define if Tracker SPARQL is available])
ac_cv_tracker_prefix=`pkg-config --variable=prefix $ac_cv_tracker_pkg`
AC_DEFINE_UNQUOTED(TRACKER_PREFIX, ["$ac_cv_tracker_prefix"], [Path to Tracker])
+ AC_DEFINE([DBUS_DAEMON_PATH], ["/bin/dbus-daemon"], [Path to dbus-daemon])
fi
ac_cv_tracker_miner_pkg_default=tracker-miner-0.12
AC_SUBST(TRACKER_MINER_LIBS)
fi
- dnl Test for Tracker 0.6 on Solaris and derived platforms
- if test x"$this_os" = x"solaris" ; then
+ dnl Test for Tracker 0.6 on Solaris and derived platforms, and FreeBSD
+ if test x"$this_os" = x"solaris" -o x"$this_os" = x"freebsd" ; then
PKG_CHECK_MODULES([TRACKER], [tracker >= 0.6], [ac_cv_have_tracker_rdf=yes], [ac_cv_have_tracker_rdf=no])
if test x"$ac_cv_have_tracker_rdf" = x"yes" ; then
AC_DEFINE(HAVE_TRACKER, 1, [Define if Tracker is available])
AC_DEFINE(HAVE_TRACKER_RDF, 1, [Define if Tracker 0.6 with support for RDF queries is available])
- ac_cv_tracker_prefix=`pkg-config --variable=prefix tracker`
- AC_DEFINE_UNQUOTED(TRACKER_RDF_PREFIX, ["$ac_cv_tracker_prefix"], [Path to Tracker])
+ case "$this_os" in
+ *solaris*)
+ AC_DEFINE([DBUS_DAEMON_PATH], ["/usr/lib/dbus-daemon"], [Path to dbus-daemon])
+ AC_DEFINE([TRACKERD_PATH], ["/bin/trackerd"], [Path to trackerd])
+ ;;
+ *freebsd*)
+ AC_DEFINE([DBUS_DAEMON_PATH], ["/usr/local/bin/dbus-daemon"], [Path to dbus-daemon])
+ AC_DEFINE([TRACKERD_PATH], ["/usr/local/libexec/trackerd"], [Path to trackerd])
+ ;;
+ esac
fi
fi
AC_MSG_ERROR([--with-libevent requires a path])
fi
AC_MSG_RESULT([$use_bundled_libevent])
- AC_CONFIG_SUBDIRS([libevent])
+ if test x"$use_bundled_libevent" = x"yes" ; then
+ AC_CONFIG_SUBDIRS([libevent])
+ fi
AC_SUBST(LIBEVENT_CFLAGS)
AC_SUBST(LIBEVENT_LDFLAGS)
AM_CONDITIONAL(USE_BUILTIN_LIBEVENT, test x"$use_bundled_libevent" = x"yes")
)
])
-dnl Check for optional sysv initscript install
+dnl Check for optional initscript install
AC_DEFUN([AC_NETATALK_INIT_STYLE], [
AC_ARG_WITH(init-style,
[ --with-init-style use OS specific init config [[redhat-sysv|redhat-systemd|suse-sysv|suse-systemd|gentoo|netbsd|debian|solaris|systemd]]],
;;
"redhat-sysv")
AC_MSG_RESULT([enabling redhat-style sysv initscript support])
+ ac_cv_init_dir="/etc/rc.d/init.d"
;;
"redhat-systemd")
AC_MSG_RESULT([enabling redhat-style systemd support])
+ ac_cv_init_dir="/lib/systemd/system"
;;
"suse")
AC_MSG_ERROR([--with-init-style=suse is obsoleted. Use suse-sysv or suse-systemd.])
;;
"suse-sysv")
AC_MSG_RESULT([enabling suse-style sysv initscript support])
+ ac_cv_init_dir="/etc/init.d"
;;
"suse-systemd")
AC_MSG_RESULT([enabling suse-style systemd support (>=openSUSE12.1)])
+ ac_cv_init_dir="/lib/systemd/system"
;;
"gentoo")
AC_MSG_RESULT([enabling gentoo-style initscript support])
+ ac_cv_init_dir="/etc/init.d"
;;
"netbsd")
AC_MSG_RESULT([enabling netbsd-style initscript support])
+ ac_cv_init_dir="/etc/rc.d"
;;
"debian")
AC_MSG_RESULT([enabling debian-style initscript support])
+ ac_cv_init_dir="/etc/init.d"
;;
"solaris")
AC_MSG_RESULT([enabling solaris-style SMF support])
+ ac_cv_init_dir="/lib/svc/manifest/network/"
;;
"systemd")
AC_MSG_RESULT([enabling general systemd support])
+ ac_cv_init_dir="/lib/systemd/system"
;;
"none")
AC_MSG_RESULT([disabling init-style support])
+ ac_cv_init_dir="none"
;;
*)
AC_MSG_ERROR([illegal init-style])
AM_CONDITIONAL(USE_SYSTEMD, test x$init_style = xsystemd || test x$init_style = xredhat-systemd || test x$init_style = xsuse-systemd)
AM_CONDITIONAL(USE_UNDEF, test x$init_style = xnone)
+ AC_ARG_WITH(init-dir,
+ [ --with-init-dir=PATH path to OS specific init directory],
+ ac_cv_init_dir="$withval", ac_cv_init_dir="$ac_cv_init_dir"
+ )
+ INIT_DIR="$ac_cv_init_dir"
+ AC_SUBST(INIT_DIR, ["$ac_cv_init_dir"])
])
dnl OS specific configuration