File libgnomesu-no-gconf.patch of Package libgnomesu.1421

Index: libgnomesu-1.0.0/configure.in
===================================================================
--- libgnomesu-1.0.0.orig/configure.in
+++ libgnomesu-1.0.0/configure.in
@@ -48,7 +48,7 @@ AC_TRY_LINK(
 
 
 PKG_CHECK_MODULES(GNOMESU,[
-	gconf-2.0
+       gio-2.0 >= 2.26.0
 ])
 AC_SUBST(GNOMESU_CFLAGS)
 AC_SUBST(GNOMESU_LIBS)
@@ -68,13 +68,6 @@ AM_GLIB_GNU_GETTEXT
 AC_PROG_INTLTOOL
 
 
-AC_PATH_PROG(GCONFTOOL, gconftool-2, no)
-if test x"$GCONFTOOL" = xno; then
-	AC_MSG_ERROR([gconftool-2 executable not found in your path - should be installed with GConf])
-fi
-AM_GCONF_SOURCE_2
-
-
 # FreeBSD doesn't have a 'root' group, but it has a 'wheel' group instead
 AC_MSG_CHECKING(whether there's a 'root' group)
 AC_RUN_IFELSE([
Index: libgnomesu-1.0.0/tools/gnomesu.c
===================================================================
--- libgnomesu-1.0.0.orig/tools/gnomesu.c
+++ libgnomesu-1.0.0/tools/gnomesu.c
@@ -19,8 +19,8 @@
  */
 
 #include <glib/gi18n.h>
+#include <gio/gio.h>
 #include <gtk/gtk.h>
-#include <gconf/gconf-client.h>
 
 #include <string.h>
 #include <libintl.h>
@@ -98,16 +98,23 @@ main (int argc, char *argv[])
 		}
 
 		if (argc == 0) {
+			GSettings *settings;
 			gchar *terminal;
 
-			terminal = gconf_client_get_string (gconf_client_get_default (),
-				"/desktop/gnome/applications/terminal/exec", NULL);
-			if (!terminal)
-				terminal = "gnome-terminal";
+			settings = g_settings_new ("org.gnome.desktop.default-applications.terminal");
+			terminal = g_settings_get_string (settings, "exec");
+			g_object_unref (settings);
+
+			if (!terminal || !terminal[0])
+				terminal = g_strdup ("gnome-terminal");
 
 			/* Default action: launch a terminal */
-			if (!gnomesu_spawn_command_async (user, terminal, &pid))
+			if (!gnomesu_spawn_command_async (user, terminal, &pid)) {
+				g_free (terminal);
 				return 255;
+			}
+
+			g_free (terminal);
 
 			g_child_watch_add (pid, child_exit_cb, NULL);
 			g_main_loop_run (main_loop);
openSUSE Build Service is sponsored by