[arch-commits] Commit in gnome-power-manager/trunk (PKGBUILD fix-suspend.patch)

Ionut Biru ibiru at archlinux.org
Sat Jun 4 12:33:17 UTC 2011


    Date: Saturday, June 4, 2011 @ 08:33:16
  Author: ibiru
Revision: 126303

fix suspend when g-p-m is set up to suspend after idle

Added:
  gnome-power-manager/trunk/fix-suspend.patch
Modified:
  gnome-power-manager/trunk/PKGBUILD

-------------------+
 PKGBUILD          |    9 ++++++---
 fix-suspend.patch |   31 +++++++++++++++++++++++++++++++
 2 files changed, 37 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2011-06-04 10:06:57 UTC (rev 126302)
+++ PKGBUILD	2011-06-04 12:33:16 UTC (rev 126303)
@@ -3,7 +3,7 @@
 
 pkgname=gnome-power-manager
 pkgver=3.0.2
-pkgrel=1
+pkgrel=2
 pkgdesc="Session daemon that makes it easy to manage your laptop or desktop system."
 arch=(i686 x86_64)
 url="http://www.gnome.org/projects/gnome-power-manager/"
@@ -14,11 +14,14 @@
 options=(!emptydirs)
 install=gnome-power-manager.install
 groups=(gnome)
-source=(http://ftp.gnome.org/pub/GNOME/sources/${pkgname}/${pkgver%.*}/${pkgname}-${pkgver}.tar.bz2)
-sha256sums=('d0e00fdcfbc3bfb709f9ed82a14de325c51cf0bb86eeacefcda2dd7fcf6cbc2b')
+source=(http://ftp.gnome.org/pub/GNOME/sources/${pkgname}/${pkgver%.*}/${pkgname}-${pkgver}.tar.bz2
+        fix-suspend.patch)
+sha256sums=('d0e00fdcfbc3bfb709f9ed82a14de325c51cf0bb86eeacefcda2dd7fcf6cbc2b'
+            '898454c9a22ecdf56e555687d4d41a0dfa3d590408dc2a17ef6cf4eaec83b262')
 
 build() {
   cd "${srcdir}/${pkgname}-${pkgver}"
+  patch -Np1 -i "${srcdir}/fix-suspend.patch"
   ./configure --prefix=/usr --sysconfdir=/etc \
       --localstatedir=/var \
       --libexecdir=/usr/lib/gnome-power-manager \

Added: fix-suspend.patch
===================================================================
--- fix-suspend.patch	                        (rev 0)
+++ fix-suspend.patch	2011-06-04 12:33:16 UTC (rev 126303)
@@ -0,0 +1,31 @@
+From 44503c5bca065290ce73b0d064a1a0db7de2936d Mon Sep 17 00:00:00 2001
+From: Matthias Clasen <mclasen at redhat.com>
+Date: Mon, 02 May 2011 23:18:58 +0000
+Subject: gpm-idle: manually update the status property
+
+gnome-session doesn't emit PropertyChanged since it uses dbus-glib,
+therefore we need to manually update the cached property when
+receiving a SessionChanged signal.
+
+https://bugzilla.redhat.com/show_bug.cgi?id=679083
+
+Signed-off-by: Richard Hughes <richard at hughsie.com>
+---
+diff --git a/src/gpm-idle.c b/src/gpm-idle.c
+index 04225fc..0f2f1ee 100644
+--- a/src/gpm-idle.c
++++ b/src/gpm-idle.c
+@@ -424,6 +424,11 @@ gpm_idle_dbus_signal_cb (GDBusProxy *proxy, const gchar *sender_name, const gcha
+ 		return;
+ 	}
+ 	if (g_strcmp0 (signal_name, "StatusChanged") == 0) {
++                guint status;
++
++                g_variant_get (parameters, "(u)", &status);
++                g_dbus_proxy_set_cached_property (proxy, "status",
++                                                  g_variant_new ("u", status));
+ 		g_debug ("Received gnome session status change");
+ 		gpm_idle_evaluate (idle);
+ 		return;
+--
+cgit v0.9




More information about the arch-commits mailing list