--- config_office/configure.in.1	2006-06-22 16:51:27.000000000 +0200
+++ config_office/configure.in	2006-06-22 16:50:25.000000000 +0200
@@ -4386,11 +4386,22 @@ dnl ====================================
 
 GTK_CFLAGS=""
 GTK_LIBS=""
+ENABLE_DBUS=""
+DBUS_PACKAGE=""
 if test  "$test_gtk" = "yes"; then
 
     if test "$ENABLE_GTK" = "TRUE" ; then
         PKG_CHECK_MODULES(GTK, gtk+-2.0 >= 2.4)
         PKG_CHECK_MODULES(GDKPIXBUF, gdk-pixbuf-xlib-2.0 >= 2.2)
+        AC_MSG_CHECKING([whether to enable D-BUS Support])
+        if test "$enable_dbus" != "no"; then
+           AC_MSG_RESULT([yes])
+           PKG_CHECK_MODULES(DBUS, dbus-glib-1 >= 0.60)
+	    ENABLE_DBUS="YES"
+	    DBUS_PACKAGE="dbus-glib-1"
+        else
+           AC_MSG_RESULT([no])
+	 fi
         GTK_CFLAGS="$GTK_CFLAGS $GDKPIXBUF_CFLAGS"
         GTK_LIBS="$GTK_LIBS $GDKPIXBUF_LIBS"
 	BUILD_TYPE="$BUILD_TYPE GTK"
@@ -4399,6 +4405,8 @@ if test  "$test_gtk" = "yes"; then
 fi
 AC_SUBST(GTK_CFLAGS)
 AC_SUBST(GTK_LIBS)
+AC_SUBST(ENABLE_DBUS)
+AC_SUBST(DBUS_PACKAGE)
 
 dnl ===================================================================
 dnl Check whether the Cairo libraries are available.
--- config_office/set_soenv.in.1	2006-06-22 17:53:57.000000000 +0200
+++ config_office/set_soenv.in	2006-06-22 17:54:51.000000000 +0200
@@ -1497,6 +1497,8 @@ ToFile( "ENABLE_GTK",        "@ENABLE_GT
 ToFile( "GTK_CFLAGS",        "@GTK_CFLAGS@",       "e" );
 ToFile( "GTK_LIBS",          "@GTK_LIBS@",         "e" );
 ToFile( "ENABLE_STATIC_GTK", "@ENABLE_STATIC_GTK@", "e" );
+ToFile( "ENABLE_DBUS",       "@ENABLE_DBUS@",      "e" );
+ToFile( "DBUS_PACKAGE",      "@DBUS_PACKAGE@",     "e" );
 ToFile( "ENABLE_CAIRO",      "@ENABLE_CAIRO@",     "e" );
 ToFile( "ENABLE_GNOMEVFS",   "@ENABLE_GNOMEVFS@",  "e" );
 ToFile( "ENABLE_KDE",        "@ENABLE_KDE@",       "e" );
