Git-Url:
http://git.frugalware.org/gitweb/gitweb.cgi?p=bouleetbilgnome224.git;a=commitdiff;h=d7b4af2eac921f4734d8f015536695cf1255ef02
commit d7b4af2eac921f4734d8f015536695cf1255ef02
Author: bouleetbil <[EMAIL PROTECTED]>
Date: Mon Oct 6 21:53:24 2008 +0200
gnome-session-2.24.0-5-i686
*added patch for shutdown/restart
*added rodepends consolekit
diff --git a/source/gnome/gnome-session/FrugalBuild
b/source/gnome/gnome-session/FrugalBuild
index 1ac4395..d543f56 100644
--- a/source/gnome/gnome-session/FrugalBuild
+++ b/source/gnome/gnome-session/FrugalBuild
@@ -5,26 +5,30 @@
pkgname=gnome-session
pkgver=2.24.0
-pkgrel=3
+pkgrel=5
pkgdesc="GNOME session manager"
depends=('libgnomeui>=2.24.0' 'gnome-desktop>=2.24.0' \
'dbus-glib>=0.76' 'gnome-control-center>=2.24.0.1' 'gnome-vfs>=2.24.0'
'libnotify' 'gnome-keyring>=2.24.0')
makedepends=('intltool')
+rodepends=('consolekit')
groups=('gnome' 'gnome-minimal')
archs=('i686' 'x86_64' 'ppc')
_F_gnome_schemas=('/etc/gconf/schemas/gnome-session.schemas')
_F_gnome_iconcache="y"
_F_gnome_desktop="y"
Finclude gnome gnome-scriptlet
-source=([EMAIL PROTECTED] enable_splash.diff \
+source=([EMAIL PROTECTED] enable_splash.diff gnome-session-HEAD-shutdown.patch
gnome-session-2.23.5-polkit-automagic.patch\
$pkgname
http://ftp.frugalware.org/pub/other/artwork/gnome-theme/GNOME-Splash-1.0.png )
sha1sums=('5a4b329db62ae3518029982ae86fb1b138500c3e' \
'5a63c81ad2ecd0d29aa33c73d2717dcd1774333e' \
+ 'aaa28556a4e3d0a0cc102b5d9ae90ded6f6da862' \
+ '942a4a41abc28596f8baac7ff41c03a677ac64db' \
'047ac00bb24d52986aac94e232b4b40fa122f582' \
'222c9a2fd01872acc2fb69c17e9771cde2e1e5a2')
build() {
Fpatchall
+ Fautoreconf
Fmake --disable-schemas-install
Fmakeinstall GCONF_DISABLE_SCHEMA_INSTALL=1
Fbuild_gnome_scriptlet
diff --git
a/source/gnome/gnome-session/gnome-session-2.23.5-polkit-automagic.patch
b/source/gnome/gnome-session/gnome-session-2.23.5-polkit-automagic.patch
new file mode 100644
index 0000000..c92e474
--- /dev/null
+++ b/source/gnome/gnome-session/gnome-session-2.23.5-polkit-automagic.patch
@@ -0,0 +1,30 @@
+---
+ From bheelinkg, fix automagic dependency on policykit
+
+ configure.in | 13 +++++++++++--
+ 1 file changed, 11 insertions(+), 2 deletions(-)
+
+diff -Naur gnome-session-2.23.5/configure.in
gnome-session-2.23.5.new/configure.in
+--- gnome-session-2.23.5/configure.in 2008-07-23 03:08:03.000000000 +0530
++++ gnome-session-2.23.5.new/configure.in 2008-08-09 11:34:35.000000000
+0530
+@@ -77,9 +77,18 @@
+ PKG_CHECK_MODULES(EGG_SMCLIENT, gtk+-2.0)
+ PKG_CHECK_MODULES(EGG_LIBGNOMEUI, libgnomeui-2.0)
+
+-PKG_CHECK_MODULES(POLKIT_GNOME, polkit-gnome >= $POLKIT_GNOME_REQUIRED,
have_polkit=yes, have_polkit=no)
++AC_ARG_ENABLE([polkit],
++ AC_HELP_STRING([--enable-polkit], [Enable PolicyKit support (default
auto)]),
++ enable_polkit=$enableval,
++ enable_polkit=auto)
++if test "x$enable_polkit" != "xno"; then
++ PKG_CHECK_MODULES(POLKIT_GNOME, polkit-gnome >= $POLKIT_GNOME_REQUIRED,
have_polkit=yes, have_polkit=no)
++ if test "x$enable_polkit" = "xyes" -a "x$have_polkit" = "xno"; then
++ AC_MSG_ERROR([PolicyKit support explicitly requested but dependencies not
found])
++ fi
++fi
+
+-if test "$have_polkit" = "yes"; then
++if test "x$have_polkit" = "xyes"; then
+ AC_DEFINE(HAVE_POLKIT_GNOME, [1], [whether PolKit GNOME was found])
+ fi
+
diff --git a/source/gnome/gnome-session/gnome-session-HEAD-shutdown.patch
b/source/gnome/gnome-session/gnome-session-HEAD-shutdown.patch
new file mode 100644
index 0000000..9529a61
--- /dev/null
+++ b/source/gnome/gnome-session/gnome-session-HEAD-shutdown.patch
@@ -0,0 +1,73 @@
+---
+ Straight forward fix to allow shutdown on systems not using policykit.
+
+ If the system really don't have policykit, it will make things work
+ as in 2.22.
+
+ If pk is in gsm but not in ck, it'll still work as in 2.22.
+
+ If pk is present in both, you just have to fix the logic to make
+ gsm ask pk if the user has the permission to shutdown _before_ showing
+ buttons and in case this is not possible, just damn fix pk.
+
+ gnome-session/gsm-consolekit.c | 14 ++------------
+ 1 file changed, 2 insertions(+), 12 deletions(-)
+
+Index: b/gnome-session/gsm-consolekit.c
+===================================================================
+--- a/gnome-session/gsm-consolekit.c
++++ b/gnome-session/gsm-consolekit.c
+@@ -528,7 +528,7 @@ request_restart_priv (GsmConsolekit *man
+ g_free (error_message);
+ }
+ #else
+- g_assert_not_reached ();
++ g_warning ("Failed to restart and Policykit support not enabled");
+ #endif /* HAVE POLKIT */
+ }
+
+@@ -568,7 +568,7 @@ request_stop_priv (GsmConsolekit *manage
+ }
+ }
+ #else
+- g_assert_not_reached ();
++ g_warning ("Failed to shutdown and Policykit support not enabled");
+ #endif /* HAVE POLKIT */
+ }
+
+@@ -828,7 +828,6 @@ gsm_consolekit_can_switch_user (GsmConso
+ gboolean
+ gsm_consolekit_can_restart (GsmConsolekit *manager)
+ {
+-#ifdef HAVE_POLKIT_GNOME
+ gboolean res;
+ GError *error;
+ error = NULL;
+@@ -839,16 +838,11 @@ gsm_consolekit_can_restart (GsmConsoleki
+ g_error_free (error);
+ }
+ return res;
+-#else
+- g_debug ("GsmConsolekit: built without PolicyKit-gnome support -
cannot restart system");
+- return FALSE;
+-#endif
+ }
+
+ gboolean
+ gsm_consolekit_can_stop (GsmConsolekit *manager)
+ {
+-#ifdef HAVE_POLKIT_GNOME
+ gboolean res;
+ GError *error;
+ error = NULL;
+@@ -859,10 +853,6 @@ gsm_consolekit_can_stop (GsmConsolekit *
+ g_error_free (error);
+ }
+ return res;
+-#else
+- g_debug ("GsmConsolekit: built without PolicyKit-gnome support -
cannot stop system");
+- return FALSE;
+-#endif
+ }
+
+ GsmConsolekit *
_______________________________________________
Frugalware-git mailing list
[email protected]
http://frugalware.org/mailman/listinfo/frugalware-git