diff -Nru libgksu-2.0.13~pre1/debian/changelog libgksu-2.0.13~pre1/debian/changelog --- libgksu-2.0.13~pre1/debian/changelog 2014-09-06 23:08:49.000000000 +0200 +++ libgksu-2.0.13~pre1/debian/changelog 2016-01-19 12:37:39.000000000 +0100 @@ -1,3 +1,56 @@ +libgksu (2.0.13~pre1-8ubuntu1) xenial; urgency=low + + * Merge from Debian unstable (LP: #1535686). Remaining changes: + - debian/libgksu2-0.postinst: + + make sudo the default + + Remove call to update-gconf-defaults and use dpkg-trigger + to set sudo-mode (lp 1173013) + - 09_multihead.patch: + + dim all heads + - 11_no_save_to_keyring.patch + + don't save to gnome-keyring by default (Ubuntu-specific) + - 12_no_password_dialog.patch + + don't display dialog if no password was needed (Ubuntu-specific) + - 13_startup_notification.diff + + make startup-notification work more reliable + - 14_polish_startup.diff: + + improve startup notification message (sent upstream) + - 15_extra_paranoia_for_gconf.diff.patch + + if no value for sudo-mode is found in gconf, default to sudo-mode + (Ubuntu-specific) + - 17_composited_fade.patch: + + nice fadeout on composited display (sent upstream) + - 18_g_markup_escape_text_for_command.patch: + + fix missing g_markup_escape when commands are displayed (sent + upstream) + - 20_better_usleep.patch: + + add small usleep() to avoid race condition when the hostname can not + be resolved (sent upstream) + - 21_composited_rgba_addition.patch: + + bling (sent upstream) + - 22_sudo_keep_env.patch: + + if gksudo -k is used, pass the -E option to sudo to preserve the + environment if we're allowed to do so (sent upstream) + - 25_fix_g_str_has_prefix_assert.patch: + + fix assert failure when not running in forkpty mode. + - 26_restore_stderr_output.patch: + + output stderr from the sudo child (as pre-lucid versions did). + - 27_sudo_wrong_pwd_check.patch: Be more careful when checking the + "wrong password" output, there might be a new prompt before. + - 28_ld_no_as_needed.patch: fix build failures with binutils-gold. + - 29_check_newline.patch: + + Check if buffer is really a single newline before discarding it. + - 30_automake_errors.patch: + + prefer this patch instead of the Debian 04_automake.patch, + better patch. + - debian/{control,control.in,rules}: use dh-autoreconf + - debian/rules: + + Remove invalid --enable-gnome-keyring configure option + - debian/libgksu2-0.install: fix gksu-run-helper installation path + - update symbols file. + + -- Gianfranco Costamagna Tue, 19 Jan 2016 11:08:40 +0100 + libgksu (2.0.13~pre1-8) unstable; urgency=medium * Adding myself to uploaders @@ -29,6 +82,98 @@ -- Emilio Pozuelo Monfort Sat, 03 May 2014 12:00:56 +0200 +libgksu (2.0.13~pre1-6ubuntu8) xenial; urgency=medium + + * No-change rebuild against new gnome libraries + + -- Iain Lane Mon, 02 Nov 2015 15:39:24 +0000 + +libgksu (2.0.13~pre1-6ubuntu7) utopic; urgency=medium + + * Actually do a no change rebuild against new libgtop + + -- Robert Ancell Wed, 20 Aug 2014 15:29:06 +1200 + +libgksu (2.0.13~pre1-6ubuntu6) utopic; urgency=medium + + * debian/rules: + - Remove invalid --enable-gnome-keyring configure option + * debian/patches/30_automake_errors.patch: + - Fix incorrect use of spaces instad of tabs in install-data-local + + -- Robert Ancell Tue, 19 Aug 2014 14:08:04 +1200 + +libgksu (2.0.13~pre1-6ubuntu5) utopic; urgency=medium + + * No change rebuild against new libgtop + + -- Robert Ancell Tue, 19 Aug 2014 13:41:18 +1200 + +libgksu (2.0.13~pre1-6ubuntu4) trusty; urgency=medium + + * Use dh-autoreconf to update libtool macros for new ports. This requires + fixing various errors from current automake. + + -- Colin Watson Fri, 03 Jan 2014 11:59:24 +0000 + +libgksu (2.0.13~pre1-6ubuntu3) saucy; urgency=low + + * debian/libgksu2-0.postinst: Remove call to update-gconf-defaults and use + dpkg-trigger to set sudo-mode (LP: #1173013) + + -- Brian Murray Mon, 19 Aug 2013 14:20:16 -0700 + +libgksu (2.0.13~pre1-6ubuntu2) raring; urgency=low + + * debian/patches/28_ld_no_as_needed.patch: updated to list -lm, needed by + 21_composited_rgba_addition.patch (Ubuntu specific) + + -- Sebastien Bacher Tue, 02 Apr 2013 15:18:48 +0200 + +libgksu (2.0.13~pre1-6ubuntu1) raring; urgency=low + + * Merge with Debian; remaining Ubuntu changes: + - debian/libgksu2-0.postinst: + + make sudo the default + - 09_multihead.patch: + + dim all heads + - 11_no_save_to_keyring.patch + + don't save to gnome-keyring by default (Ubuntu-specific) + - 12_no_password_dialog.patch + + don't display dialog if no password was needed (Ubuntu-specific) + - 13_startup_notification.diff + + make startup-notification work more reliable + - 14_polish_startup.diff: + + improve startup notification message (sent upstream) + - 15_extra_paranoia_for_gconf.diff.patch + + if no value for sudo-mode is found in gconf, default to sudo-mode + (Ubuntu-specific) + - 17_composited_fade.patch: + + nice fadeout on composited display (sent upstream) + - 18_g_markup_escape_text_for_command.patch: + + fix missing g_markup_escape when commands are displayed (sent + upstream) + - 20_add_usleep.patch: + + add small usleep() to avoid race condition when the hostname can not + be resolved (sent upstream) + - 21_composited_rgba_addition.patch: + + bling (sent upstream) + - 22_sudo_keep_env.patch: + + if gksudo -k is used, pass the -E option to sudo to preserve the + environment if we're allowed to do so (sent upstream) + - 23_correct_colormap_get.patch: + + change by Cody Russell to fix a rgba segfault. + - 27_sudo_wrong_pwd_check.patch: Be more careful when checking the + "wrong password" output, there might be a new prompt before. + - 26_restore_stderr_output.patch: + + output stderr from the sudo child (as pre-lucid versions did). + - 25_fix_g_str_has_prefix_assert.patch: + + fix assert failure when not running in forkpty mode. + - 29_check_newline.patch: + - Check if buffer is really a single newline before discarding it. + + -- Sebastien Bacher Thu, 29 Nov 2012 13:06:29 +0100 + libgksu (2.0.13~pre1-6) unstable; urgency=low * debian/control.in: Fix Vcs-* URL. diff -Nru libgksu-2.0.13~pre1/debian/control libgksu-2.0.13~pre1/debian/control --- libgksu-2.0.13~pre1/debian/control 2014-09-06 22:44:25.000000000 +0200 +++ libgksu-2.0.13~pre1/debian/control 2016-01-19 11:36:36.000000000 +0100 @@ -6,7 +6,8 @@ Source: libgksu Section: admin Priority: optional -Maintainer: Gustavo Noronha Silva +Maintainer: Ubuntu Developers +XSBC-Original-Maintainer: Gustavo Noronha Silva Uploaders: Debian GNOME Maintainers , Emilio Pozuelo Monfort , Josselin Mouette , Martin Pitt , Michael Biebl , Balint Reczey Build-Depends: debhelper (>= 8), dh-autoreconf, @@ -15,7 +16,7 @@ libstartup-notification0-dev, libgnome-keyring-dev, gettext, - autotools-dev, + dh-autoreconf, gtk-doc-tools, gnome-pkg-tools (>= 0.10), libgtop2-dev, diff -Nru libgksu-2.0.13~pre1/debian/control.in libgksu-2.0.13~pre1/debian/control.in --- libgksu-2.0.13~pre1/debian/control.in 2014-09-06 22:44:25.000000000 +0200 +++ libgksu-2.0.13~pre1/debian/control.in 2016-01-19 10:27:06.000000000 +0100 @@ -1,7 +1,8 @@ Source: libgksu Section: admin Priority: optional -Maintainer: Gustavo Noronha Silva +Maintainer: Ubuntu Developers +XSBC-Original-Maintainer: Gustavo Noronha Silva Uploaders: @GNOME_TEAM@, Balint Reczey Build-Depends: debhelper (>= 8), dh-autoreconf, @@ -10,7 +11,7 @@ libstartup-notification0-dev, libgnome-keyring-dev, gettext, - autotools-dev, + dh-autoreconf, gtk-doc-tools, gnome-pkg-tools (>= 0.10), libgtop2-dev, @@ -18,8 +19,8 @@ intltool Standards-Version: 3.9.2 Homepage: http://www.nongnu.org/gksu -Vcs-Browser: http://anonscm.debian.org/viewvc/pkg-gnome/attic/libgksu/ -Vcs-Svn: svn://anonscm.debian.org/pkg-gnome/attic/libgksu/ +XS-Debian-Vcs-Browser: http://anonscm.debian.org/viewvc/pkg-gnome/attic/libgksu/ +XS-Debian-Vcs-Svn: svn://anonscm.debian.org/pkg-gnome/attic/libgksu/ Package: libgksu2-0 Section: libs diff -Nru libgksu-2.0.13~pre1/debian/libgksu2-0.install libgksu-2.0.13~pre1/debian/libgksu2-0.install --- libgksu-2.0.13~pre1/debian/libgksu2-0.install 2014-09-06 23:08:49.000000000 +0200 +++ libgksu-2.0.13~pre1/debian/libgksu2-0.install 2016-01-19 12:35:29.000000000 +0100 @@ -1,5 +1,5 @@ usr/lib/libgksu2.so.* -usr/lib/libgksu/libgksu usr/lib/ +usr/lib/libgksu/gksu-run-helper usr/lib/ usr/share/locale/ usr/share/pixmaps/ usr/bin/ diff -Nru libgksu-2.0.13~pre1/debian/libgksu2-0.postinst libgksu-2.0.13~pre1/debian/libgksu2-0.postinst --- libgksu-2.0.13~pre1/debian/libgksu2-0.postinst 2006-09-03 23:44:34.000000000 +0200 +++ libgksu-2.0.13~pre1/debian/libgksu2-0.postinst 2015-11-07 04:14:15.000000000 +0100 @@ -6,7 +6,7 @@ update-alternatives --install /usr/share/gconf/defaults/10_libgksu \ libgksu-gconf-defaults /usr/share/libgksu/debian/gconf-defaults.libgksu-sudo \ - 10 + 30 update-alternatives --install /usr/share/gconf/defaults/10_libgksu \ libgksu-gconf-defaults /usr/share/libgksu/debian/gconf-defaults.libgksu-su \ @@ -18,6 +18,4 @@ ln -fs /etc/alternatives/libgksu-gconf-defaults /usr/share/gconf/defaults/10_libgksu fi -if which update-gconf-defaults >/dev/null 2>&1; then - update-gconf-defaults -fi +dpkg-trigger /usr/share/gconf/defaults diff -Nru libgksu-2.0.13~pre1/debian/libgksu2-0.symbols libgksu-2.0.13~pre1/debian/libgksu2-0.symbols --- libgksu-2.0.13~pre1/debian/libgksu2-0.symbols 2009-02-22 23:14:13.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/libgksu2-0.symbols 2016-01-19 12:36:53.000000000 +0100 @@ -1,6 +1,9 @@ libgksu2.so.0 libgksu2-0 #MINVER# HIDDEN@HIDDEN 1.9.6 LIBGKSU_2@LIBGKSU_2 1.9.6 + _kernel_1d_delete@LIBGKSU_2 2.0.13~pre1-8ubuntu1 + _kernel_1d_new@LIBGKSU_2 2.0.13~pre1-8ubuntu1 + _round_rect@LIBGKSU_2 2.0.13~pre1-8ubuntu1 fade_data@LIBGKSU_2 1.9.6 get_configuration_options@LIBGKSU_2 1.9.6 gksu_ask_password@LIBGKSU_2 1.9.6 @@ -55,6 +58,7 @@ gksuui_dialog_set_message@LIBGKSU_2 1.9.6 gksuui_dialog_set_prompt@LIBGKSU_2 1.9.6 grab_keyboard_and_mouse@LIBGKSU_2 1.9.6 + gsm_foreach_screen@LIBGKSU_2 2.0.13~pre1-8ubuntu1 gsm_screen_get_height@LIBGKSU_2 1.9.6 gsm_screen_get_width@LIBGKSU_2 1.9.6 gsm_screen_get_x@LIBGKSU_2 1.9.6 diff -Nru libgksu-2.0.13~pre1/debian/patches/09_multihead.patch libgksu-2.0.13~pre1/debian/patches/09_multihead.patch --- libgksu-2.0.13~pre1/debian/patches/09_multihead.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/09_multihead.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,133 @@ +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -178,6 +178,7 @@ + } FadeoutData; + + FadeoutData *fade_data = NULL; ++static GList *fade_data_l = NULL; + static GList *fadeout_windows = NULL; + + #define FADE_DURATION 500.0 +@@ -226,6 +227,30 @@ + return geometry.y; + } + ++typedef void (*GsmScreenForeachFunc) (GdkScreen *screen, ++ int monitor); ++ ++void ++gsm_foreach_screen (GsmScreenForeachFunc callback) ++{ ++ GdkDisplay *display; ++ int n_screens, i; ++ ++ display = gdk_display_get_default (); ++ ++ n_screens = gdk_display_get_n_screens (display); ++ for (i = 0; i < n_screens; i++) { ++ GdkScreen *screen; ++ int n_monitors, j; ++ ++ screen = gdk_display_get_screen (display, i); ++ ++ n_monitors = gdk_screen_get_n_monitors (screen); ++ for (j = 0; j < n_monitors; j++) ++ callback (screen, j); ++ } ++} ++ + static void + get_current_frame (FadeoutData *fadeout, + double sat) +@@ -471,9 +496,51 @@ + g_get_current_time (&fadeout->start_time); + g_idle_add ((GSourceFunc) fadeout_callback, fadeout); + +- fade_data = fadeout; ++ fade_data_l = g_list_prepend (fade_data, fadeout); + } + ++static void ++fadein (void) ++{ ++ GList *l; ++ GList *next; ++ ++ /* set start_time for all screens */ ++ for (l = fade_data_l; l; l = l->next) ++ { ++ FadeoutData *fd; ++ fd = (FadeoutData*)l->data; ++ g_get_current_time (&fd->start_time); ++ } ++ ++ /* iterate through all screens and call the fadein_callback ++ * until all of them return FALSE */ ++ next = fade_data_l; ++ while (next != NULL) ++ { ++ l = next; ++ next = l->next; ++ ++ /* remove from list when finished fading */ ++ if (fadein_callback ((FadeoutData*)l->data) == FALSE) ++ { ++ fade_data_l = g_list_remove(fade_data, l->data); ++ } ++ ++ /* this wrapping around needs to be delayed because fade_data_l could ++ * have changed above */ ++ if (next == NULL) ++ { ++ next = fade_data_l; ++ } ++ } ++ ++ /* free the list. The FadeoutData structs are being free'd from ++ * within the fadein_callback's */ ++ g_list_free (fade_data_l); ++ fade_data_l = NULL; ++} ++ + /* End of 'stolen' code */ + + #define GRAB_TRIES 16 +@@ -557,7 +624,7 @@ + g_free (fname); + + gdk_threads_enter (); +- fadeout_screen (gdk_screen_get_default (), 0); ++ gsm_foreach_screen (fadeout_screen); + gtk_widget_show_all (dialog); + + /* reset cursor */ +@@ -573,8 +640,7 @@ + if (++grab_tries > GRAB_TRIES) + { + gtk_widget_hide (dialog); +- g_get_current_time (&fade_data->start_time); +- while (fadein_callback (fade_data) != FALSE); ++ fadein(); + report_failed_grab (FAILED_GRAB_MOUSE); + exit (1); + break; +@@ -593,8 +659,7 @@ + if (++grab_tries > GRAB_TRIES) + { + gtk_widget_hide (dialog); +- g_get_current_time (&fade_data->start_time); +- while (fadein_callback (fade_data) != FALSE); ++ fadein(); + report_failed_grab (FAILED_GRAB_KEYBOARD); + exit (1); + break; +@@ -621,8 +686,7 @@ + gdk_keyboard_ungrab(GDK_CURRENT_TIME); + gdk_flush(); + +- g_get_current_time (&fade_data->start_time); +- while (fadein_callback (fade_data) != FALSE); ++ fadein(); + gdk_threads_leave(); + + close(lock); diff -Nru libgksu-2.0.13~pre1/debian/patches/11_no_save_to_keyring.patch libgksu-2.0.13~pre1/debian/patches/11_no_save_to_keyring.patch --- libgksu-2.0.13~pre1/debian/patches/11_no_save_to_keyring.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/11_no_save_to_keyring.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,12 @@ +diff -Nur libgksu-1.9.4/gksu.schemas.in libgksu-1.9.4.new/gksu.schemas.in +--- libgksu-1.9.4/gksu.schemas.in 2006-08-01 10:51:39.000000000 +0200 ++++ libgksu-1.9.4.new/gksu.schemas.in 2006-08-01 10:52:01.000000000 +0200 +@@ -86,7 +86,7 @@ + /apps/gksu/save-to-keyring + gksu + bool +- true ++ false + + Save password to gnome-keyring + diff -Nru libgksu-2.0.13~pre1/debian/patches/12_no_password_dialog.patch libgksu-2.0.13~pre1/debian/patches/12_no_password_dialog.patch --- libgksu-2.0.13~pre1/debian/patches/12_no_password_dialog.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/12_no_password_dialog.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,12 @@ +diff -Nur libgksu-1.9.4/gksu.schemas.in libgksu-1.9.4.new/gksu.schemas.in +--- libgksu-1.9.4/gksu.schemas.in 2006-07-04 15:56:59.000000000 +0200 ++++ libgksu-1.9.4.new/gksu.schemas.in 2006-07-04 15:57:46.000000000 +0200 +@@ -70,7 +70,7 @@ + /apps/gksu/display-no-pass-info + gksu + bool +- true ++ false + + Display information message when no password is needed + diff -Nru libgksu-2.0.13~pre1/debian/patches/13_startup_notification.diff libgksu-2.0.13~pre1/debian/patches/13_startup_notification.diff --- libgksu-2.0.13~pre1/debian/patches/13_startup_notification.diff 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/13_startup_notification.diff 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,21 @@ +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -1789,7 +1789,17 @@ + gksu_context_launch_initiate (GksuContext *context) + { + gchar *sid = NULL; +- guint32 launch_time = gdk_x11_display_get_user_time (gdk_display_get_default ()); ++ // guint32 launch_time = gdk_x11_display_get_user_time(GDK_DISPLAY()); ++ // ^---- does not work reliable and reports absurdly large launch times ++ // for me ++ // *cry* we create a fake-window, realize it to get the ++ // current server time. there must be a simpler way, ++ // but I don't know it! ++ GtkWidget *win = gtk_window_new(GTK_WINDOW_TOPLEVEL); ++ gtk_widget_realize(win); ++ gtk_widget_add_events (GTK_WIDGET (win), GDK_PROPERTY_CHANGE_MASK); ++ guint32 launch_time = gdk_x11_get_server_time(win->window); ++ + static gboolean initiated = FALSE; + + if (!initiated) diff -Nru libgksu-2.0.13~pre1/debian/patches/14_polish_startup.diff libgksu-2.0.13~pre1/debian/patches/14_polish_startup.diff --- libgksu-2.0.13~pre1/debian/patches/14_polish_startup.diff 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/14_polish_startup.diff 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,17 @@ +=== modified file 'libgksu/libgksu.c' +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -1385,6 +1385,13 @@ + NULL, NULL); + context->sn_context = sn_launcher_context_new (sn_display, gdk_screen_get_number (gdk_display_get_default_screen (gdk_display_get_default ()))); + sn_launcher_context_set_description (context->sn_context, _("Granting Rights")); ++ if (context->sudo_mode) ++ { ++ sn_launcher_context_set_description (context->sn_context, ++ _("Starting Administrative Application")); ++ sn_launcher_context_set_icon_name (context->sn_context, ++ "applications-system"); ++ } + sn_launcher_context_set_name (context->sn_context, g_get_prgname ()); + } + diff -Nru libgksu-2.0.13~pre1/debian/patches/15_extra_paranoia_for_gconf.diff.patch libgksu-2.0.13~pre1/debian/patches/15_extra_paranoia_for_gconf.diff.patch --- libgksu-2.0.13~pre1/debian/patches/15_extra_paranoia_for_gconf.diff.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/15_extra_paranoia_for_gconf.diff.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,19 @@ +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -884,7 +884,15 @@ + context->grab = TRUE; + + context->sudo_mode = gconf_client_get_bool (gconf_client, BASE_PATH "sudo-mode", +- NULL); ++ NULL); ++ // UBUNTU specific - if the sudo mode is not set, check if we actualy have ++ // a registered schema for it, upgrades sometimes blew it away (lp: #59079) ++ if(context->sudo_mode == FALSE) { ++ GConfValue* v = gconf_client_get_default_from_schema(gconf_client, BASE_PATH "sudo-mode", NULL); ++ if(!v) ++ context->sudo_mode = TRUE; ++ gconf_value_free(v); ++ } + } + + /** diff -Nru libgksu-2.0.13~pre1/debian/patches/17_composited_fade.patch libgksu-2.0.13~pre1/debian/patches/17_composited_fade.patch --- libgksu-2.0.13~pre1/debian/patches/17_composited_fade.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/17_composited_fade.patch 2014-08-19 04:14:58.000000000 +0200 @@ -0,0 +1,216 @@ +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -175,13 +175,14 @@ + guchar *start_p, *end_p, *frame_p; + GTimeVal start_time; + GdkGC *gc; ++ gboolean composited; + } FadeoutData; + + FadeoutData *fade_data = NULL; + static GList *fade_data_l = NULL; + static GList *fadeout_windows = NULL; + +-#define FADE_DURATION 500.0 ++#define FADE_DURATION 300.0 + + int + gsm_screen_get_width (GdkScreen *screen, +@@ -318,33 +319,47 @@ + elapsed = G_MAXDOUBLE; + } + +- if (elapsed > FADE_DURATION) ++ if (elapsed > FADE_DURATION ) + { +- gdk_draw_pixbuf (fadeout->draw_window, +- fadeout->gc, +- fadeout->end_pb, +- 0, 0, +- 0, 0, +- fadeout->area.width, +- fadeout->area.height, +- GDK_RGB_DITHER_NONE, +- 0, 0); ++ if (fadeout->composited) ++ { ++ gdk_window_set_opacity (fadeout->draw_window, 0.5); ++ } ++ else ++ { ++ gdk_draw_pixbuf (fadeout->draw_window, ++ fadeout->gc, ++ fadeout->end_pb, ++ 0, 0, ++ 0, 0, ++ fadeout->area.width, ++ fadeout->area.height, ++ GDK_RGB_DITHER_NONE, ++ 0, 0); ++ } + + return FALSE; + } + + percent = elapsed / FADE_DURATION; + +- get_current_frame (fadeout, 1.0 - percent); +- gdk_draw_pixbuf (fadeout->draw_window, +- fadeout->gc, +- fadeout->frame, +- 0, 0, +- 0, 0, +- fadeout->area.width, +- fadeout->area.height, +- GDK_RGB_DITHER_NONE, +- 0, 0); ++ if (fadeout->composited) ++ { ++ gdk_window_set_opacity (fadeout->draw_window, percent/2); ++ } ++ else ++ { ++ get_current_frame (fadeout, 1.0 - percent); ++ gdk_draw_pixbuf (fadeout->draw_window, ++ fadeout->gc, ++ fadeout->frame, ++ 0, 0, ++ 0, 0, ++ fadeout->area.width, ++ fadeout->area.height, ++ GDK_RGB_DITHER_NONE, ++ 0, 0); ++ } + + gdk_flush (); + +@@ -384,15 +399,23 @@ + + if (elapsed > FADE_DURATION) + { +- gdk_draw_pixbuf (fadeout->draw_window, +- fadeout->gc, +- fadeout->end_pb, +- 0, 0, +- 0, 0, +- fadeout->area.width, +- fadeout->area.height, +- GDK_RGB_DITHER_NONE, +- 0, 0); ++ if (fadeout->composited) ++ { ++ gdk_window_set_opacity (fadeout->draw_window, 0.0); ++ gdk_window_resize (fadeout->draw_window, 4, 4); ++ } ++ else ++ { ++ gdk_draw_pixbuf (fadeout->draw_window, ++ fadeout->gc, ++ fadeout->end_pb, ++ 0, 0, ++ 0, 0, ++ fadeout->area.width, ++ fadeout->area.height, ++ GDK_RGB_DITHER_NONE, ++ 0, 0); ++ } + + g_object_unref (fadeout->gc); + g_object_unref (fadeout->start_pb); +@@ -408,16 +431,23 @@ + + percent = elapsed / FADE_DURATION; + +- get_current_frame (fadeout, percent); +- gdk_draw_pixbuf (fadeout->draw_window, +- fadeout->gc, +- fadeout->frame, +- 0, 0, +- 0, 0, +- fadeout->area.width, +- fadeout->area.height, +- GDK_RGB_DITHER_NONE, +- 0, 0); ++ if (fadeout->composited) ++ { ++ gdk_window_set_opacity (fadeout->draw_window, 0.5 - percent/2); ++ } ++ else ++ { ++ get_current_frame (fadeout, percent); ++ gdk_draw_pixbuf (fadeout->draw_window, ++ fadeout->gc, ++ fadeout->frame, ++ 0, 0, ++ 0, 0, ++ fadeout->area.width, ++ fadeout->area.height, ++ GDK_RGB_DITHER_NONE, ++ 0, 0); ++ } + + gdk_flush (); + +@@ -437,6 +467,7 @@ + + fadeout->screen = screen; + fadeout->monitor = monitor; ++ fadeout->composited = gdk_screen_is_composited (screen); + + fadeout->area.x = gsm_screen_get_x (screen, monitor); + fadeout->area.y = gsm_screen_get_y (screen, monitor); +@@ -444,11 +475,11 @@ + fadeout->area.height = gsm_screen_get_height (screen, monitor); + + fadeout->root_window = gdk_screen_get_root_window (screen); +- attr.window_type = GDK_WINDOW_CHILD; ++ attr.window_type = GDK_WINDOW_TOPLEVEL; + attr.x = fadeout->area.x; + attr.y = fadeout->area.y; +- attr.width = fadeout->area.width; +- attr.height = fadeout->area.height; ++ attr.width = 4; ++ attr.height = 4; + attr.wclass = GDK_INPUT_OUTPUT; + attr.visual = gdk_screen_get_system_visual (fadeout->screen); + attr.colormap = gdk_screen_get_default_colormap (fadeout->screen); +@@ -481,17 +512,29 @@ + + fadeout->gc = gdk_gc_new_with_values (fadeout->root_window, &values, GDK_GC_SUBWINDOW); + +- gdk_window_set_back_pixmap (fadeout->draw_window, NULL, FALSE); ++ if (fadeout->composited) ++ { ++ gdk_window_set_opacity (fadeout->draw_window, 0.0); ++ } ++ else ++ { ++ gdk_window_set_back_pixmap (fadeout->draw_window, NULL, FALSE); ++ gdk_draw_pixbuf (fadeout->draw_window, ++ fadeout->gc, ++ fadeout->frame, ++ 0, 0, ++ 0, 0, ++ fadeout->area.width, ++ fadeout->area.height, ++ GDK_RGB_DITHER_NONE, ++ 0, 0); ++ } ++ + gdk_window_show (fadeout->draw_window); +- gdk_draw_pixbuf (fadeout->draw_window, +- fadeout->gc, +- fadeout->frame, +- 0, 0, +- 0, 0, +- fadeout->area.width, +- fadeout->area.height, +- GDK_RGB_DITHER_NONE, +- 0, 0); ++ gdk_window_clear (fadeout->draw_window); ++ gdk_window_resize (fadeout->draw_window, ++ fadeout->area.width, ++ fadeout->area.height); + + g_get_current_time (&fadeout->start_time); + g_idle_add ((GSourceFunc) fadeout_callback, fadeout); diff -Nru libgksu-2.0.13~pre1/debian/patches/18_g_markup_escape_text_for_command.patch libgksu-2.0.13~pre1/debian/patches/18_g_markup_escape_text_for_command.patch --- libgksu-2.0.13~pre1/debian/patches/18_g_markup_escape_text_for_command.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/18_g_markup_escape_text_for_command.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,18 @@ +=== modified file 'libgksu/libgksu.c' +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -994,12 +994,12 @@ + "The application '%s' lets you " + "modify essential parts of your " + "system."), +- command); ++ g_markup_escape_text(command, -1)); + else + msg = g_strdup_printf (_("Enter your password to run " + "the application '%s' as user %s" + ""), +- command, context->user); ++ g_markup_escape_text(command, -1), context->user); + } + else + { diff -Nru libgksu-2.0.13~pre1/debian/patches/20_better_usleep.patch libgksu-2.0.13~pre1/debian/patches/20_better_usleep.patch --- libgksu-2.0.13~pre1/debian/patches/20_better_usleep.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/20_better_usleep.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,30 @@ +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -2906,9 +2906,13 @@ + /* Try hard to find the prompt; it may happen that we're + * seeing sudo's lecture, or that some pam module is spitting + * debugging stuff at the screen ++ * ++ * we wait up to 5sec for the prompt to appear, but we also ++ * break once the process_name changed + */ +- for (counter = 0; counter < 50; counter++) ++ for (counter = 0; counter < 1000; counter++) + { ++ char *procname; + if (strncmp (buffer, "GNOME_SUDO_PASS", 15) == 0) + break; + +@@ -2921,7 +2925,11 @@ + if (context->debug) + fprintf (stderr, "buffer: -%s-\n", buffer); + +- usleep(1000); ++ // we wait here bit but break when the process name changes ++ usleep(5000); ++ procname = get_process_name (pid); ++ if(!g_str_has_suffix(procname,"sudo")) ++ break; + } + + if (context->debug) diff -Nru libgksu-2.0.13~pre1/debian/patches/21_composited_rgba_addition.patch libgksu-2.0.13~pre1/debian/patches/21_composited_rgba_addition.patch --- libgksu-2.0.13~pre1/debian/patches/21_composited_rgba_addition.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/21_composited_rgba_addition.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,489 @@ +diff -Nur -x '*.orig' -x '*~' libgksu-2.0.7/libgksuui/gksuui-dialog.c libgksu-2.0.7.new/libgksuui/gksuui-dialog.c +--- libgksu-2.0.7/libgksuui/gksuui-dialog.c 2008-05-09 19:39:54.000000000 +0200 ++++ libgksu-2.0.7.new/libgksuui/gksuui-dialog.c 2008-10-17 14:15:36.000000000 +0200 +@@ -19,6 +19,7 @@ + */ + + #include ++#include + + #include + #include +@@ -259,11 +260,416 @@ + return TRUE; + } + ++void ++_round_rect (cairo_t* cr, ++ gdouble aspect, ++ gdouble x, ++ gdouble y, ++ gdouble corner, ++ gdouble width, ++ gdouble height) ++{ ++ gdouble radius = corner / aspect; ++ ++ /* top-left, right of the corner */ ++ cairo_move_to (cr, x + radius, y); ++ ++ /* top-right, left of the corner */ ++ cairo_line_to (cr, ++ x + width - radius, ++ y); ++ ++ /* top-right, below the corner */ ++ cairo_arc (cr, ++ x + width - radius, ++ y + radius, ++ radius, ++ -90.0f * G_PI / 180.0f, ++ 0.0f * G_PI / 180.0f); ++ ++ /* bottom-right, above the corner */ ++ cairo_line_to (cr, ++ x + width, ++ y + height - radius); ++ ++ /* bottom-right, left of the corner */ ++ cairo_arc (cr, ++ x + width - radius, ++ y + height - radius, ++ radius, ++ 0.0f * G_PI / 180.0f, ++ 90.0f * G_PI / 180.0f); ++ ++ /* bottom-left, right of the corner */ ++ cairo_line_to (cr, ++ x + radius, ++ y + height); ++ ++ /* bottom-left, above the corner */ ++ cairo_arc (cr, ++ x + radius, ++ y + height - radius, ++ radius, ++ 90.0f * G_PI / 180.0f, ++ 180.0f * G_PI / 180.0f); ++ ++ /* top-left, below the corner */ ++ cairo_line_to (cr, ++ x, ++ y + radius); ++ ++ /* top-left, right of the corner */ ++ cairo_arc (cr, ++ x + radius, ++ y + radius, ++ radius, ++ 180.0f * G_PI / 180.0f, ++ 270.0f * G_PI / 180.0f); ++} ++ ++gdouble* ++_kernel_1d_new (gint radius, ++ gdouble deviation /* pass 0.0f to calculate automatically */) ++{ ++ gdouble* kernel = NULL; ++ gdouble sum = 0.0f; ++ gdouble value = 0.0f; ++ gint i; ++ gint size = 2 * radius + 1; ++ gdouble radiusf; ++ ++ /* sanity check */ ++ if (radius <= 0) ++ return NULL; ++ ++ /* get memory-chunk to hold blur-kernel */ ++ kernel = (gdouble*) g_malloc0 ((size + 1) * sizeof (gdouble)); ++ if (!kernel) ++ return NULL; ++ ++ /* determine deviation */ ++ radiusf = fabs (radius) + 1.0f; ++ if (deviation == 0.0f) ++ deviation = sqrt (-(radiusf * radiusf) / (2.0f * log (1.0f / 255.0f))); ++ ++ /* fill blur-kernel */ ++ kernel[0] = size; ++ value = (gdouble) -radius; ++ for (i = 0; i < size; i++) ++ { ++ kernel[1 + i] = 1.0f / (2.506628275f * deviation) * ++ expf (-((value * value) / ++ (2.0f * deviation * deviation))); ++ sum += kernel[1 + i]; ++ value += 1.0f; ++ } ++ ++ /* normalize values */ ++ for (i = 0; i < size; i++) ++ kernel[1 + i] /= sum; ++ ++ return kernel; ++} ++ ++void ++_kernel_1d_delete (gdouble* kernel) ++{ ++ g_assert (kernel != NULL); ++ g_free ((gpointer) kernel); ++} ++ ++static void ++_image_surface_blur (cairo_surface_t* surface, ++ gint horz_radius, ++ gint vert_radius) ++{ ++ gint iX; ++ gint iY; ++ gint i; ++ gint x; ++ gint y; ++ gint stride; ++ gint offset; ++ gint base_offset; ++ gdouble* horz_blur; ++ gdouble* vert_blur; ++ gdouble* horz_kernel; ++ gdouble* vert_kernel; ++ guchar* src; ++ gint width; ++ gint height; ++ gint channels; ++ ++ /* sanity checks */ ++ if (!surface || horz_radius == 0 || vert_radius == 0) ++ return; ++ ++ if (cairo_surface_get_type (surface) != CAIRO_SURFACE_TYPE_IMAGE) ++ return; ++ ++ cairo_surface_flush (surface); ++ ++ src = cairo_image_surface_get_data (surface); ++ width = cairo_image_surface_get_width (surface); ++ height = cairo_image_surface_get_height (surface); ++ ++ /* only handle RGB- or RGBA-surfaces */ ++ if (cairo_image_surface_get_format (surface) != CAIRO_FORMAT_ARGB32 && ++ cairo_image_surface_get_format (surface) != CAIRO_FORMAT_RGB24) ++ return; ++ ++ channels = 4; ++ stride = width * channels; ++ ++ /* create buffers to hold the blur-passes */ ++ horz_blur = (gdouble*) g_malloc0 (height * stride * sizeof (gdouble)); ++ vert_blur = (gdouble*) g_malloc0 (height * stride * sizeof (gdouble)); ++ if (!horz_blur || !vert_blur) ++ { ++ if (horz_blur) ++ g_free ((gpointer) horz_blur); ++ ++ if (vert_blur) ++ g_free ((gpointer) vert_blur); ++ ++ return; ++ } ++ ++ horz_kernel = _kernel_1d_new (horz_radius, 0.0f); ++ vert_kernel = _kernel_1d_new (vert_radius, 0.0f); ++ ++ if (!horz_kernel || !vert_kernel) ++ { ++ ++ g_free ((gpointer) horz_blur); ++ g_free ((gpointer) vert_blur); ++ ++ if (horz_kernel) ++ _kernel_1d_delete (horz_kernel); ++ ++ if (vert_kernel) ++ _kernel_1d_delete (vert_kernel); ++ ++ return; ++ } ++ ++ /* horizontal pass */ ++ for (iY = 0; iY < height; iY++) ++ { ++ for (iX = 0; iX < width; iX++) ++ { ++ gdouble red = 0.0f; ++ gdouble green = 0.0f; ++ gdouble blue = 0.0f; ++ gdouble alpha = 0.0f; ++ ++ offset = ((gint) horz_kernel[0]) / -2; ++ for (i = 0; i < (gint) horz_kernel[0]; i++) ++ { ++ x = iX + offset; ++ if (x >= 0 && x < width) ++ { ++ base_offset = iY * stride + x * channels; ++ ++ if (channels == 4) ++ alpha += (horz_kernel[1+i] * (gdouble) src[base_offset + 3]); ++ ++ red += (horz_kernel[1+i] * (gdouble) src[base_offset + 2]); ++ green += (horz_kernel[1+i] * (gdouble) src[base_offset + 1]); ++ blue += (horz_kernel[1+i] * (gdouble) src[base_offset + 0]); ++ } ++ ++ offset++; ++ } ++ ++ base_offset = iY * stride + iX * channels; ++ ++ if (channels == 4) ++ horz_blur[base_offset + 3] = alpha; ++ ++ horz_blur[base_offset + 2] = red; ++ horz_blur[base_offset + 1] = green; ++ horz_blur[base_offset + 0] = blue; ++ } ++ } ++ ++ /* vertical pass */ ++ for (iY = 0; iY < height; iY++) ++ { ++ for (iX = 0; iX < width; iX++) ++ { ++ gdouble red = 0.0f; ++ gdouble green = 0.0f; ++ gdouble blue = 0.0f; ++ gdouble alpha = 0.0f; ++ ++ offset = ((gint) vert_kernel[0]) / -2; ++ for (i = 0; i < (gint) vert_kernel[0]; i++) ++ { ++ y = iY + offset; ++ if (y >= 0 && y < height) ++ { ++ base_offset = y * stride + iX * channels; ++ ++ if (channels == 4) ++ alpha += (vert_kernel[1+i] * horz_blur[base_offset + 3]); ++ ++ red += (vert_kernel[1+i] * horz_blur[base_offset + 2]); ++ green += (vert_kernel[1+i] * horz_blur[base_offset + 1]); ++ blue += (vert_kernel[1+i] * horz_blur[base_offset + 0]); ++ } ++ ++ offset++; ++ } ++ ++ base_offset = iY * stride + iX * channels; ++ ++ if (channels == 4) ++ vert_blur[base_offset + 3] = alpha; ++ ++ vert_blur[base_offset + 2] = red; ++ vert_blur[base_offset + 1] = green; ++ vert_blur[base_offset + 0] = blue; ++ } ++ } ++ ++ _kernel_1d_delete (horz_kernel); ++ _kernel_1d_delete (vert_kernel); ++ ++ for (iY = 0; iY < height; iY++) ++ { ++ for (iX = 0; iX < width; iX++) ++ { ++ offset = iY * stride + iX * channels; ++ ++ if (channels == 4) ++ src[offset + 3] = (guchar) vert_blur[offset + 3]; ++ ++ src[offset + 2] = (guchar) vert_blur[offset + 2]; ++ src[offset + 1] = (guchar) vert_blur[offset + 1]; ++ src[offset + 0] = (guchar) vert_blur[offset + 0]; ++ } ++ } ++ ++ cairo_surface_mark_dirty (surface); ++ ++ g_free ((gpointer) horz_blur); ++ g_free ((gpointer) vert_blur); ++} ++ ++static cairo_surface_t* ++_create_shadow_surface (gint width, ++ gint height, ++ gdouble corner_radius, ++ gint blur_radius) ++{ ++ cairo_surface_t* surface; ++ cairo_t* cr; ++ ++ /* create image-surface and context */ ++ surface = cairo_image_surface_create (CAIRO_FORMAT_ARGB32, width, height); ++ cr = cairo_create (surface); ++ ++ /* clear context */ ++ cairo_set_operator (cr, CAIRO_OPERATOR_CLEAR); ++ cairo_paint (cr); ++ ++ /* draw semi-transparent black rectangle with rounded corners */ ++ cairo_set_source_rgba (cr, 0.0f, 0.0f, 0.0f, 0.65f); ++ cairo_set_operator (cr, CAIRO_OPERATOR_OVER); ++ _round_rect (cr, ++ 1.0f, ++ (gdouble) blur_radius, ++ (gdouble) blur_radius, ++ corner_radius, ++ (gdouble) width - 2 * blur_radius, ++ (gdouble) height - 2 * blur_radius); ++ cairo_fill (cr); ++ ++ /* blur twice with half the blur-radius, looks nicer */ ++ _image_surface_blur (surface, blur_radius / 2, blur_radius / 2); ++ _image_surface_blur (surface, blur_radius / 2, blur_radius / 2); ++ ++ /* clean up */ ++ cairo_destroy (cr); ++ ++ return surface; ++} ++ ++static gboolean ++_transparent_clear_cb (GtkWidget *widget, ++ GdkEventExpose *event, ++ GksuuiDialog *gksuui_dialog) ++{ ++ cairo_t *cr; ++ GtkStyle *style; ++ gdouble opacity = 0.85f; ++ gdouble corner_radius = 3.75f; ++ ++ /* create context */ ++ cr = gdk_cairo_create (widget->window); ++ ++ /* clear the background */ ++ cairo_set_operator (cr, CAIRO_OPERATOR_CLEAR); ++ cairo_paint (cr); ++ ++ /* draw shadow */ ++ if (cairo_surface_status (gksuui_dialog->shadow) == CAIRO_STATUS_SUCCESS) ++ { ++ cairo_set_operator (cr, CAIRO_OPERATOR_OVER); ++ cairo_set_source_surface (cr, gksuui_dialog->shadow, 0, 0); ++ cairo_paint (cr); ++ } ++ ++ /* create linear gradient from themes normal background-color */ ++ style = gtk_widget_get_style (widget); ++ cairo_set_source_rgba ( ++ cr, ++ (gdouble) style->bg[GTK_STATE_NORMAL].red / (gdouble) 0xFFFF, ++ (gdouble) style->bg[GTK_STATE_NORMAL].green / (gdouble) 0xFFFF, ++ (gdouble) style->bg[GTK_STATE_NORMAL].blue / (gdouble) 0xFFFF, ++ opacity); ++ ++ /* draw a filled rounded rectangle */ ++ cairo_set_operator (cr, CAIRO_OPERATOR_OVER); ++ _round_rect (cr, ++ 1.0f, ++ (gdouble) widget->allocation.x + 13.0f, ++ (gdouble) widget->allocation.y + 13.0f, ++ corner_radius, ++ (gdouble) widget->allocation.width - 30.0f, ++ (gdouble) widget->allocation.height - 30.0f); ++ cairo_fill (cr); ++ ++ /* clean up afterwards */ ++ cairo_destroy (cr); ++ ++ return FALSE; ++} ++ ++static void ++_unrealize_cb (GtkWidget *widget, ++ GksuuiDialog *gksuui_dialog) ++{ ++ cairo_surface_destroy (gksuui_dialog->shadow); ++} ++ ++static void ++_realize_cb (GtkWidget *widget, ++ GksuuiDialog *gksuui_dialog) ++{ ++ gksuui_dialog->shadow = _create_shadow_surface (widget->allocation.width, ++ widget->allocation.height, ++ 3.75f, ++ 15); ++} ++ + static void + gksuui_dialog_init (GksuuiDialog *gksuui_dialog) + { + GtkDialog *dialog; + GtkWidget *hbox; /* aditional hbox for 'password: entry' label */ ++ gint border_width = 6; + + /* + make sure we're using UTF-8 and getting our locale files +@@ -272,6 +678,37 @@ + bindtextdomain(PACKAGE_NAME, LOCALEDIR); + bind_textdomain_codeset (PACKAGE_NAME, "UTF-8"); + ++ gksuui_dialog->composited = gdk_screen_is_composited ( ++ gtk_widget_get_screen ( ++ GTK_WIDGET (gksuui_dialog))); ++ ++ if (gksuui_dialog->composited) ++ { ++ GdkColormap *colormap; ++ GtkWidget *main_dialog = GTK_WIDGET (gksuui_dialog); ++ ++ colormap = gdk_screen_get_rgba_colormap ( ++ gtk_widget_get_screen (main_dialog)); ++ if (colormap) ++ { ++ gtk_widget_set_colormap (main_dialog, colormap); ++ gtk_widget_set_app_paintable (main_dialog, TRUE); ++ g_signal_connect (G_OBJECT (main_dialog), ++ "expose-event", ++ G_CALLBACK (_transparent_clear_cb), ++ (gpointer) gksuui_dialog); ++ g_signal_connect (G_OBJECT (main_dialog), ++ "realize", ++ G_CALLBACK (_realize_cb), ++ (gpointer) gksuui_dialog); ++ g_signal_connect (G_OBJECT (main_dialog), ++ "unrealize", ++ G_CALLBACK (_unrealize_cb), ++ (gpointer) gksuui_dialog); ++ border_width = 20; ++ } ++ } ++ + gtk_widget_push_composite_child (); + + /* dialog window */ +@@ -285,7 +722,7 @@ + + gtk_window_set_title (GTK_WINDOW(gksuui_dialog), ""); + gtk_dialog_set_has_separator (GTK_DIALOG(gksuui_dialog), FALSE); +- gtk_container_set_border_width (GTK_CONTAINER(gksuui_dialog), 6); ++ gtk_container_set_border_width (GTK_CONTAINER(gksuui_dialog), border_width); + gtk_box_set_spacing (GTK_BOX(gksuui_dialog->main_vbox), 12); + gtk_window_set_resizable (GTK_WINDOW(gksuui_dialog), FALSE); + +diff -Nur -x '*.orig' -x '*~' libgksu-2.0.7/libgksuui/gksuui-dialog.h libgksu-2.0.7.new/libgksuui/gksuui-dialog.h +--- libgksu-2.0.7/libgksuui/gksuui-dialog.h 2008-05-09 19:39:54.000000000 +0200 ++++ libgksu-2.0.7.new/libgksuui/gksuui-dialog.h 2008-10-17 14:07:57.000000000 +0200 +@@ -72,7 +72,9 @@ + GtkWidget *prompt_label; + + /* private */ +- gboolean sudo_mode; ++ gboolean sudo_mode; ++ gboolean composited; ++ cairo_surface_t *shadow; + }; + + GType diff -Nru libgksu-2.0.13~pre1/debian/patches/22_sudo_keep_env.patch libgksu-2.0.13~pre1/debian/patches/22_sudo_keep_env.patch --- libgksu-2.0.13~pre1/debian/patches/22_sudo_keep_env.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/22_sudo_keep_env.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,15 @@ +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -2704,6 +2704,12 @@ + cmd[argcount] = g_strdup("-H"); + argcount++; + } ++ else ++ { ++ /* Preserve the environment, if sudo will let us */ ++ cmd[argcount] = g_strdup("-E"); ++ argcount++; ++ } + + /* Make sudo read from stdin */ + cmd[argcount] = g_strdup("-S"); diff -Nru libgksu-2.0.13~pre1/debian/patches/23_correct_colormap_get.patch libgksu-2.0.13~pre1/debian/patches/23_correct_colormap_get.patch --- libgksu-2.0.13~pre1/debian/patches/23_correct_colormap_get.patch 2014-09-06 21:52:27.000000000 +0200 +++ libgksu-2.0.13~pre1/debian/patches/23_correct_colormap_get.patch 2016-01-19 10:19:09.000000000 +0100 @@ -1,8 +1,8 @@ === modified file 'libgksu/libgksu.c' --- a/libgksu/libgksu.c +++ b/libgksu/libgksu.c -@@ -426,7 +426,7 @@ - attr.height = fadeout->area.height; +@@ -482,7 +482,7 @@ + attr.height = 4; attr.wclass = GDK_INPUT_OUTPUT; attr.visual = gdk_screen_get_system_visual (fadeout->screen); - attr.colormap = gdk_screen_get_default_colormap (fadeout->screen); diff -Nru libgksu-2.0.13~pre1/debian/patches/25_fix_g_str_has_prefix_assert.patch libgksu-2.0.13~pre1/debian/patches/25_fix_g_str_has_prefix_assert.patch --- libgksu-2.0.13~pre1/debian/patches/25_fix_g_str_has_prefix_assert.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/25_fix_g_str_has_prefix_assert.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,11 @@ +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -3097,7 +3097,7 @@ + + if (WEXITSTATUS(status)) + { +- if (g_str_has_prefix(child_stderr, "Sorry, user ")) ++ if (child_stderr && g_str_has_prefix(child_stderr, "Sorry, user ")) + { + g_set_error (error, gksu_quark, GKSU_ERROR_NOT_ALLOWED, + _("The underlying authorization mechanism (sudo) " diff -Nru libgksu-2.0.13~pre1/debian/patches/26_restore_stderr_output.patch libgksu-2.0.13~pre1/debian/patches/26_restore_stderr_output.patch --- libgksu-2.0.13~pre1/debian/patches/26_restore_stderr_output.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/26_restore_stderr_output.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,25 @@ +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -3046,9 +3046,6 @@ + #ifdef SUDO_FORKPTY + if (error) + close(fdpty); +-#else +- if (error) +- fclose(infile); + #endif + + cmdline = g_strdup("sudo"); +@@ -3067,6 +3064,12 @@ + if (context->sn_context) + gksu_context_launch_complete (context); + ++ while (read (parent_pipe[0], buffer, 255) > 0) ++ { ++ fprintf (stderr, "%s", buffer); ++ bzero(buffer, 256); ++ } ++ + /* if the process is still active waitpid() on it */ + if (pid_exited != pid) + waitpid(pid, &status, 0); diff -Nru libgksu-2.0.13~pre1/debian/patches/27_sudo_wrong_pwd_check.patch libgksu-2.0.13~pre1/debian/patches/27_sudo_wrong_pwd_check.patch --- libgksu-2.0.13~pre1/debian/patches/27_sudo_wrong_pwd_check.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/27_sudo_wrong_pwd_check.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,15 @@ +Description: Be more careful when checking the "wrong password" output, there might be a new prompt before. +Author: Martin Pitt +Bug-Ubuntu: https://launchpad.net/bugs/298217 + +--- a/libgksu/libgksu.c ++++ b/libgksu/libgksu.c +@@ -3022,7 +3022,7 @@ + fprintf (stderr, "%s", buffer); + } + +- if (g_str_has_prefix (buffer, "Sorry, try again.")) ++ if (g_str_has_prefix (buffer, "Sorry, try again.") || g_str_has_prefix (buffer, "GNOME_SUDO_PASSSorry, try again.")) + g_set_error (error, gksu_quark, GKSU_ERROR_WRONGPASS, + _("Wrong password.")); + else diff -Nru libgksu-2.0.13~pre1/debian/patches/28_ld_no_as_needed.patch libgksu-2.0.13~pre1/debian/patches/28_ld_no_as_needed.patch --- libgksu-2.0.13~pre1/debian/patches/28_ld_no_as_needed.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/28_ld_no_as_needed.patch 2014-08-19 04:14:58.000000000 +0200 @@ -0,0 +1,56 @@ +Description: Fix build failures with binutils-gold +Author: Matthias Klose +Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=555180 +Index: libgksu-2.0.12/libgksuui/Makefile.am +=================================================================== +--- libgksu-2.0.12.orig/libgksuui/Makefile.am 2008-05-09 19:39:54.000000000 +0200 ++++ libgksu-2.0.12/libgksuui/Makefile.am 2011-10-24 02:14:08.139984529 +0200 +@@ -4,12 +4,13 @@ + + noinst_LTLIBRARIES = libgksuui1.0.la + libgksuui1_0_la_SOURCES = gksuui-dialog.c +-libgksuui1_0_la_LDFLAGS = -Wl,-O1 `pkg-config --libs gtk+-2.0 gconf-2.0` ++libgksuui1_0_la_LDFLAGS = -Wl,-O1 ++libgksuui1_0_la_LIBADD = `pkg-config --libs gtk+-2.0 gconf-2.0 x11` -lm + + noinst_HEADERS = defines.h gksuui.h gksuui-dialog.h + includedir = ${prefix}/include/$(PACKAGE) + + noinst_PROGRAMS = test-gksuui + test_gksuui_SOURCES = test-gksuui.c +-test_gksuui_LDADD = libgksuui1.0.la +-test_gksuui_LDFLAGS = `pkg-config --libs glib-2.0` ++test_gksuui_LDADD = libgksuui1.0.la `pkg-config --libs glib-2.0 x11` -lm ++test_gksuui_LDFLAGS = +Index: libgksu-2.0.12/libgksu/Makefile.am +=================================================================== +--- libgksu-2.0.12.orig/libgksu/Makefile.am 2009-08-16 23:20:16.000000000 +0200 ++++ libgksu-2.0.12/libgksu/Makefile.am 2011-10-24 02:14:08.155984327 +0200 +@@ -12,8 +12,8 @@ + # major -> breaks backward compatibility (changes to existing ABI) + # minor -> keeps compatibility (additions to the API) + # micro -> no change to the API/ABI +-libgksu2_la_LIBADD = ../libgksuui/libgksuui1.0.la +-libgksu2_la_LDFLAGS = -version-info 0:2:0 -Wl,-O1 -lutil ${LIBGKSU_LIBS} ++libgksu2_la_LIBADD = ../libgksuui/libgksuui1.0.la -lutil ${LIBGKSU_LIBS} ++libgksu2_la_LDFLAGS = -version-info 0:2:0 -Wl,-O1 + if USE_VERSION_SCRIPT + libgksu2_la_LDFLAGS += -Wl,--version-script=libgksu.ver + endif +@@ -28,12 +28,13 @@ + + pkglibdir = ${libdir}/${PACKAGE} + pkglib_PROGRAMS = gksu-run-helper +-gksu_run_helper_LDFLAGS = `pkg-config --libs glib-2.0` ++gksu_run_helper_LDFLAGS = ++gksu_run_helper_LDADD = `pkg-config --libs glib-2.0` + gksu_run_helper_SOURCES = gksu-run-helper.c + + noinst_PROGRAMS = test-gksu + test_gksu_SOURCES = test-gksu.c +-test_gksu_LDADD = libgksu2.la +-test_gksu_LDFLAGS = `pkg-config --libs glib-2.0` ++test_gksu_LDADD = libgksu2.la `pkg-config --libs gtk+-2.0` ++test_gksu_LDFLAGS = + + EXTRA_DIST = libgksu.ver diff -Nru libgksu-2.0.13~pre1/debian/patches/29_check_newline.patch libgksu-2.0.13~pre1/debian/patches/29_check_newline.patch --- libgksu-2.0.13~pre1/debian/patches/29_check_newline.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/29_check_newline.patch 2014-08-19 04:14:59.000000000 +0200 @@ -0,0 +1,33 @@ +## Description: Checks if buffer contains only newline before discarding it +## Origin/Author: Torsten Spindler (Canonical) +## Bug: http://pad.lv/298217 +diff -Nur -x '*.orig' -x '*~' libgksu-2.0.13~pre1//libgksu/libgksu.c libgksu-2.0.13~pre1.new//libgksu/libgksu.c +--- libgksu-2.0.13~pre1//libgksu/libgksu.c 2011-09-13 09:43:51.723178003 +0200 ++++ libgksu-2.0.13~pre1.new//libgksu/libgksu.c 2011-09-13 09:46:16.603182354 +0200 +@@ -2980,16 +2980,22 @@ + /* ignore the first newline that comes right after sudo receives + the password */ + fgets (buffer, 255, fdfile); +- /* this is the status we are interested in */ +- fgets (buffer, 255, fdfile); ++ if (!strcmp (buffer, "\n")) ++ { ++ /* this is the status we are interested in */ ++ fgets (buffer, 255, fdfile); ++ } + #else + fcntl(parent_pipe[0], F_SETFL, fcntl(parent_pipe[0], F_GETFL) & ~O_NONBLOCK); + + /* ignore the first newline that comes right after sudo receives + the password */ + fgets (buffer, 255, infile); +- /* this is the status we are interested in */ +- fgets (buffer, 255, infile); ++ if (!strcmp (buffer, "\n")) ++ { ++ /* this is the status we are interested in */ ++ fgets (buffer, 255, infile); ++ } + #endif + } + else diff -Nru libgksu-2.0.13~pre1/debian/patches/30_automake_errors.patch libgksu-2.0.13~pre1/debian/patches/30_automake_errors.patch --- libgksu-2.0.13~pre1/debian/patches/30_automake_errors.patch 1970-01-01 01:00:00.000000000 +0100 +++ libgksu-2.0.13~pre1/debian/patches/30_automake_errors.patch 2016-01-19 10:42:55.000000000 +0100 @@ -0,0 +1,65 @@ +Description: Fix various errors with current automake +Author: Colin Watson +Forwarded: no +Last-Update: 2014-01-03 + +Index: b/configure.ac +=================================================================== +--- a/configure.ac ++++ b/configure.ac +@@ -40,8 +40,12 @@ AM_CONDITIONAL(USE_VERSION_SCRIPT, test + AC_PATH_PROG(GCONFTOOL, gconftool-2) + AM_GCONF_SOURCE_2 + ++PKG_CHECK_MODULES(GLIB, [glib-2.0]) ++PKG_CHECK_MODULES(GTK, [gtk+-2.0]) + PKG_CHECK_MODULES(LIBGKSU, [gtk+-2.0 >= 2.4.0, gconf-2.0, libstartup-notification-1.0, gnome-keyring-1, libgtop-2.0]) + PKG_CHECK_MODULES(GKSU_PROPERTIES, [gtk+-2.0 >= 2.12, gconf-2.0]) ++PKG_CHECK_MODULES(LIBGKSUUI, [gtk+-2.0, gconf-2.0, x11]) ++PKG_CHECK_MODULES(TEST_GKSUUI, [glib-2.0, x11]) + + # Checks for library functions. + ALL_LINGUAS="ca cs da de es eu fr hu it ja ko lt pl pt_BR ro ru sk sv nb nl th zh_CN" +Index: b/libgksu/Makefile.am +=================================================================== +--- a/libgksu/Makefile.am ++++ b/libgksu/Makefile.am +@@ -26,15 +26,15 @@ includedir = ${prefix}/include/${PACKAGE + pkgconfigdir = ${libdir}/pkgconfig + pkgconfig_DATA = libgksu2.pc + +-pkglibdir = ${libdir}/${PACKAGE} +-pkglib_PROGRAMS = gksu-run-helper ++pkglibexecdir = ${libdir}/${PACKAGE} ++pkglibexec_PROGRAMS = gksu-run-helper + gksu_run_helper_LDFLAGS = +-gksu_run_helper_LDADD = `pkg-config --libs glib-2.0` ++gksu_run_helper_LDADD = $(GLIB_LIBS) + gksu_run_helper_SOURCES = gksu-run-helper.c + + noinst_PROGRAMS = test-gksu + test_gksu_SOURCES = test-gksu.c +-test_gksu_LDADD = libgksu2.la `pkg-config --libs gtk+-2.0` ++test_gksu_LDADD = libgksu2.la $(GTK_LIBS) + test_gksu_LDFLAGS = + + EXTRA_DIST = libgksu.ver +Index: b/libgksuui/Makefile.am +=================================================================== +--- a/libgksuui/Makefile.am ++++ b/libgksuui/Makefile.am +@@ -5,12 +5,12 @@ AM_CPPFLAGS = -DLOCALEDIR=\"$(datadir)/l + noinst_LTLIBRARIES = libgksuui1.0.la + libgksuui1_0_la_SOURCES = gksuui-dialog.c + libgksuui1_0_la_LDFLAGS = -Wl,-O1 +-libgksuui1_0_la_LIBADD = `pkg-config --libs gtk+-2.0 gconf-2.0 x11` -lm ++libgksuui1_0_la_LIBADD = $(LIBGKSUUI_LIBS) -lm + + noinst_HEADERS = defines.h gksuui.h gksuui-dialog.h + includedir = ${prefix}/include/$(PACKAGE) + + noinst_PROGRAMS = test-gksuui + test_gksuui_SOURCES = test-gksuui.c +-test_gksuui_LDADD = libgksuui1.0.la `pkg-config --libs glib-2.0 x11` -lm ++test_gksuui_LDADD = libgksuui1.0.la $(TEST_GKSUUI) -lm + test_gksuui_LDFLAGS = diff -Nru libgksu-2.0.13~pre1/debian/patches/series libgksu-2.0.13~pre1/debian/patches/series --- libgksu-2.0.13~pre1/debian/patches/series 2014-09-06 22:31:11.000000000 +0200 +++ libgksu-2.0.13~pre1/debian/patches/series 2016-01-19 10:38:10.000000000 +0100 @@ -1,8 +1,24 @@ 01_tcdrain_kfreebsd.patch 02_format-security.patch 03_makefile_spaces.patch -04_automake.patch +#04_automake.patch 05_ja.patch 06_unguarded_child_stderr.patch +09_multihead.patch +11_no_save_to_keyring.patch +12_no_password_dialog.patch +13_startup_notification.diff +14_polish_startup.diff +15_extra_paranoia_for_gconf.diff.patch +17_composited_fade.patch +18_g_markup_escape_text_for_command.patch +20_better_usleep.patch +21_composited_rgba_addition.patch +22_sudo_keep_env.patch 23_correct_colormap_get.patch +26_restore_stderr_output.patch +27_sudo_wrong_pwd_check.patch +28_ld_no_as_needed.patch +29_check_newline.patch +30_automake_errors.patch 99_intltool.patch diff -Nru libgksu-2.0.13~pre1/debian/rules libgksu-2.0.13~pre1/debian/rules --- libgksu-2.0.13~pre1/debian/rules 2014-09-06 23:08:49.000000000 +0200 +++ libgksu-2.0.13~pre1/debian/rules 2016-01-19 11:11:02.000000000 +0100 @@ -1,6 +1,6 @@ #!/usr/bin/make -f -DEB_CONFIGURE_EXTRA_FLAGS := --disable-gtk-doc --enable-gnome-keyring +DEB_CONFIGURE_EXTRA_FLAGS := --disable-gtk-doc #DEB_CONFIGURE_LIBEXECDIR = "\$${prefix}/lib" %: