Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <mpg@redhat.com>2005-07-05 18:39:09 (GMT)
committer Marco Pesenti Gritti <marco@src.gnome.org>2005-07-05 18:39:09 (GMT)
commitd2a41c2645e69a002c95a20cb69fe3fbd6f002c5 (patch)
treea69691178cb2c2c1b6e7936743fb54eef3b78884 /configure.ac
parente688147c85543bb01a7c28a4c18548762ab9d98e (diff)
Enable dbus when available, do not require a configure option.
2005-07-05 Marco Pesenti Gritti <mpg@redhat.com> * configure.ac: Enable dbus when available, do not require a configure option.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac12
1 files changed, 4 insertions, 8 deletions
diff --git a/configure.ac b/configure.ac
index ac18288..a6ee3d7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -50,18 +50,14 @@ PKG_CHECK_MODULES(POPPLER_GLIB, poppler-glib >= $POPPLER_REQUIRED)
GLIB_GENMARSHAL=`$PKG_CONFIG --variable=glib_genmarshal glib-2.0`
AC_SUBST(GLIB_GENMARSHAL)
-AC_ARG_ENABLE([dbus],
- AS_HELP_STRING([--enable-dbus],[Enable DBUS (default=no)]),
- [enable_dbus=$enableval],
- [enable_dbus=no])
+PKG_CHECK_EXISTS([dbus-glib-1 >= $DBUS_GLIB_REQUIRED], [enable_dbus=yes],
+ [AC_MSG_WARN("DBUS support is disabled since dbus 0.33 or higher was not found")
+ enable_dbus=no])
-AC_MSG_RESULT([$enable_dbus])
-
-DBUS_VERSION=
if test "x$enable_dbus" = "xyes" ; then
+ PKG_CHECK_MODULES([DBUS], [dbus-glib-1 >= $DBUS_GLIB_REQUIRED])
AC_DEFINE([ENABLE_DBUS],[1],[Define if DBUS support is enabled])
AC_DEFINE([ENABLE_METADATA],[1],[Define if metadata support is enabled])
- PKG_CHECK_MODULES([DBUS], [dbus-glib-1 >= $DBUS_GLIB_REQUIRED])
DBUS_VERSION=`$PKG_CONFIG --modversion dbus-glib-1 | sed 's/0.\([[0-9]]*\)/\1/'`
AC_DEFINE_UNQUOTED(DBUS_VERSION, $DBUS_VERSION, [DBUS version.])