[arch-commits] CVS update of extra/gnome/gnome-applets (PKGBUILD bgo427562.patch)
Jan de Groot
jgc at archlinux.org
Wed May 30 09:51:11 UTC 2007
Date: Wednesday, May 30, 2007 @ 05:51:11
Author: jgc
Path: /home/cvs-extra/extra/gnome/gnome-applets
Added: bgo427562.patch (1.1)
Modified: PKGBUILD (1.37 -> 1.38)
upgpkg: gnome-applets 2.18.0-3
Fix battery applet ACPI method on 2.6.21
-----------------+
PKGBUILD | 13 +++++++++----
bgo427562.patch | 40 ++++++++++++++++++++++++++++++++++++++++
2 files changed, 49 insertions(+), 4 deletions(-)
Index: extra/gnome/gnome-applets/PKGBUILD
diff -u extra/gnome/gnome-applets/PKGBUILD:1.37 extra/gnome/gnome-applets/PKGBUILD:1.38
--- extra/gnome/gnome-applets/PKGBUILD:1.37 Sun Apr 22 12:21:58 2007
+++ extra/gnome/gnome-applets/PKGBUILD Wed May 30 05:51:11 2007
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD,v 1.37 2007/04/22 16:21:58 jgc Exp $
+# $Id: PKGBUILD,v 1.38 2007/05/30 09:51:11 jgc Exp $
# Maintainer: Jan de Groot <jgc at archlinux.org>
pkgname=gnome-applets
pkgver=2.18.0
-pkgrel=2
+pkgrel=3
pkgdesc="GNOME Applets"
arch=(i686 x86_64)
license=('GPL')
@@ -13,14 +13,19 @@
groups=(gnome)
install=gnome-applets.install
source=(http://ftp.gnome.org/pub/gnome/sources/${pkgname}/2.18/${pkgname}-${pkgver}.tar.bz2
- disable-invest.patch)
-md5sums=('db3ef99c00335798f30fc0a9162c0257' '454a74cf70b30bd748304119ee24907f')
+ disable-invest.patch
+ bgo427562.patch)
+md5sums=('db3ef99c00335798f30fc0a9162c0257' '454a74cf70b30bd748304119ee24907f'
+ '2afb42b45e66bc75bd40bc05e83f042a')
build() {
cd ${startdir}/src/${pkgname}-${pkgver}
# Disable invest applet, it depends on gnome-python-desktop.
patch -Np0 -i ${startdir}/src/disable-invest.patch || return 1
+ # Fix battery applet for linux 2.6.21 ACPI
+ patch -Np0 -i ${startdir}/src/bgo427562.patch || return 1
+
aclocal -I m4 || return 1
autoconf || return 1
automake || return 1
Index: extra/gnome/gnome-applets/bgo427562.patch
diff -u /dev/null extra/gnome/gnome-applets/bgo427562.patch:1.1
--- /dev/null Wed May 30 05:51:10 2007
+++ extra/gnome/gnome-applets/bgo427562.patch Wed May 30 05:51:11 2007
@@ -0,0 +1,40 @@
+Index: battstat/acpi-linux.c
+===================================================================
+--- battstat/acpi-linux.c (revision 10240)
++++ battstat/acpi-linux.c (working copy)
+@@ -200,22 +200,21 @@
+ acpiinfo->max_capacity = 0;
+ acpiinfo->low_capacity = 0;
+ acpiinfo->critical_capacity = 0;
++ acpiinfo->ac_state_state = "state";
++ acpiinfo->batt_state_state = "state";
++ acpiinfo->charging_state = "charging state";
+
+ hash = read_file ("/proc/acpi/info", buf, sizeof (buf));
+- if (!hash)
+- return FALSE;
+-
+- acpi_ver = read_ulong (hash, "version");
+- g_hash_table_destroy (hash);
+-
+- if (acpi_ver < (gulong)20020208) {
+- acpiinfo->ac_state_state = "status";
+- acpiinfo->batt_state_state = "status";
+- acpiinfo->charging_state = "state";
+- } else {
+- acpiinfo->ac_state_state = "state";
+- acpiinfo->batt_state_state = "state";
+- acpiinfo->charging_state = "charging state";
++ if (hash)
++ {
++ acpi_ver = read_ulong (hash, "version");
++ g_hash_table_destroy (hash);
++
++ if (acpi_ver < (gulong)20020208) {
++ acpiinfo->ac_state_state = "status";
++ acpiinfo->batt_state_state = "status";
++ acpiinfo->charging_state = "state";
++ }
+ }
+
+ procdir=opendir("/proc/acpi/battery/");
More information about the arch-commits
mailing list