PKG_CHECK_MODULES(LIBVIEW, gtk+-2.0 >= $GTK_REQUIRED gthread-2.0 gio-2.0 >= $GLIB_REQUIRED)
PKG_CHECK_MODULES(BACKEND, gtk+-2.0 >= $GTK_REQUIRED)
PKG_CHECK_MODULES(FRONTEND_CORE, gtk+-2.0 >= $GTK_REQUIRED gthread-2.0 gio-2.0 >= $GLIB_REQUIRED)
-PKG_CHECK_MODULES(SHELL_CORE, libxml-2.0 >= $LIBXML_REQUIRED gtk+-2.0 >= $GTK_REQUIRED gtk+-unix-print-2.0 >= $GTK_REQUIRED gio-2.0 >= $GLIB_REQUIRED gnome-icon-theme >= $GNOME_ICON_THEME_REQUIRED gthread-2.0 gconf-2.0)
+PKG_CHECK_MODULES(SHELL_CORE, libxml-2.0 >= $LIBXML_REQUIRED gtk+-2.0 >= $GTK_REQUIRED gtk+-unix-print-2.0 >= $GTK_REQUIRED gio-2.0 >= $GLIB_REQUIRED gnome-icon-theme >= $GNOME_ICON_THEME_REQUIRED gthread-2.0)
PKG_CHECK_MODULES(SMCLIENT, gtk+-2.0 gthread-2.0)
AC_SUBST(SMCLIENT_CFLAGS)
AC_CHECK_FUNCS(cairo_format_stride_for_width)
LIBS=$evince_save_LIBS
+dnl ========= Check for Keyring
AC_ARG_WITH(keyring,
AC_HELP_STRING([--without-keyring],[disable the use of gnome-keyring]),
[case "${withval}" in
AM_CONDITIONAL([ENABLE_DBUS], [test "x$enable_dbus" = "xyes"])
AM_CONDITIONAL([DBUS_TOOL_NO_PREFIX], [test "x$DBUS_VERSION" = "x33"])
+dnl ========= Check for GConf
+AC_ARG_WITH(gconf,
+ AC_HELP_STRING([--without-gconf],[disable the use of gconf]),
+ [case "${withval}" in
+ yes) WITH_GCONF=yes ;;
+ no) WITH_GCONF=no ;;
+ *) AC_MSG_ERROR(bad value ${withval} for --with-gconf) ;;
+ esac],
+ [WITH_GCONF=yes]) dnl Default value
+AM_CONDITIONAL(WITH_GCONF, test x$WITH_GCONF = "xyes")
+
+if test x$WITH_GCONF = "xyes"; then
+ PKG_CHECK_MODULES(GCONF, gconf-2.0)
+ AC_DEFINE([WITH_GCONF],[1],[Define if GConf support is enabled])
+fi
+
dnl Debug mode
AC_ARG_ENABLE([debug],
AC_HELP_STRING([--enable-debug],
AC_SUBST(BACKEND_CFLAGS)
AC_SUBST(BACKEND_LIBS)
-SHELL_CFLAGS="$SHELL_CORE_CFLAGS $DBUS_CFLAGS $KEYRING_CFLAGS -DGDK_MULTIHEAD_SAFE -DGTK_MULTIHEAD_SAFE $DEBUG_FLAGS"
-SHELL_LIBS="$SHELL_CORE_LIBS $DBUS_LIBS $KEYRING_LIBS -lz"
+SHELL_CFLAGS="$SHELL_CORE_CFLAGS $DBUS_CFLAGS $KEYRING_CFLAGS $GCONF_CFLAGS -DGDK_MULTIHEAD_SAFE -DGTK_MULTIHEAD_SAFE $DEBUG_FLAGS"
+SHELL_LIBS="$SHELL_CORE_LIBS $DBUS_LIBS $KEYRING_LIBS $GCONF_LIBS -lz"
AC_SUBST(SHELL_CFLAGS)
AC_SUBST(SHELL_LIBS)
echo "
Configure summary:
+ GConf Support......: $WITH_GCONF
Keyring Support....: $WITH_KEYRING
DBUS Support.......: $enable_dbus
Nautilus Plugin....: $HAVE_NAUTILUS
#else
#include <gtk/gtkprintunixdialog.h>
#endif
+#ifdef WITH_GCONF
#include <gconf/gconf-client.h>
+#endif
#include "egg-editable-toolbar.h"
#include "egg-toolbar-editor.h"
gboolean can_get_text = FALSE;
gboolean has_pages = FALSE;
gboolean can_find = FALSE;
-
+#ifdef WITH_GCONF
GConfClient *client;
+#endif
if (document) {
has_document = TRUE;
can_find = TRUE;
}
+#ifdef WITH_GCONF
client = gconf_client_get_default ();
override_restrictions = gconf_client_get_bool (client,
GCONF_OVERRIDE_RESTRICTIONS,
NULL);
+#endif
if (!override_restrictions && info && info->fields_mask & EV_DOCUMENT_INFO_PERMISSIONS) {
ok_to_print = (info->permissions & EV_DOCUMENT_PERMISSIONS_OK_TO_PRINT);
ok_to_copy = (info->permissions & EV_DOCUMENT_PERMISSIONS_OK_TO_COPY);
if (has_document && !EV_IS_FILE_EXPORTER(document))
ok_to_print = FALSE;
-
+#ifdef WITH_GCONF
if (gconf_client_get_bool (client, GCONF_LOCKDOWN_SAVE, NULL)) {
ok_to_copy = FALSE;
}
}
g_object_unref (client);
+#endif
/* File menu */
ev_window_set_action_sensitive (ev_window, "FileOpenCopy", has_document);