Add patch to fix error messages (#109421).
authorGregorio Guidi <greg_g@gentoo.org>
Wed, 19 Oct 2005 14:35:25 +0000 (14:35 +0000)
committerGregorio Guidi <greg_g@gentoo.org>
Wed, 19 Oct 2005 14:35:25 +0000 (14:35 +0000)
Package-Manager: portage-2.0.51.22-r3

kde-base/klaptopdaemon/files/digest-klaptopdaemon-3.4.3-r1 [new file with mode: 0644]
kde-base/klaptopdaemon/files/kdeutils-3.4.3-klaptopdaemon.patch [new file with mode: 0644]
kde-base/klaptopdaemon/klaptopdaemon-3.4.3-r1.ebuild [new file with mode: 0644]
kde-base/klaptopdaemon/klaptopdaemon-3.5.0_beta2.ebuild

diff --git a/kde-base/klaptopdaemon/files/digest-klaptopdaemon-3.4.3-r1 b/kde-base/klaptopdaemon/files/digest-klaptopdaemon-3.4.3-r1
new file mode 100644 (file)
index 0000000..0b8cb3d
--- /dev/null
@@ -0,0 +1 @@
+MD5 d467284b523bb1268da776cd016ede4d kdeutils-3.4.3.tar.bz2 2257060
diff --git a/kde-base/klaptopdaemon/files/kdeutils-3.4.3-klaptopdaemon.patch b/kde-base/klaptopdaemon/files/kdeutils-3.4.3-klaptopdaemon.patch
new file mode 100644 (file)
index 0000000..2834421
--- /dev/null
@@ -0,0 +1,49 @@
+diff -Nur kdeutils-3.4.3.orig/klaptopdaemon/laptop_daemon.cpp kdeutils-3.4.3/klaptopdaemon/laptop_daemon.cpp
+--- kdeutils-3.4.3.orig/klaptopdaemon/laptop_daemon.cpp        2005-10-05 15:26:42.000000000 +0200
++++ kdeutils-3.4.3/klaptopdaemon/laptop_daemon.cpp     2005-10-18 15:38:21.000000000 +0200
+@@ -919,7 +919,7 @@
+       // the lid button turns stuff on when it's down and back off again when it's raised
+       //      (kind of like the fridge door light)
+       //
+-      if (lid_state != laptop_portable::get_button(laptop_portable::LidButton)) {
++      if (s.enable_lid_button && (lid_state != laptop_portable::get_button(laptop_portable::LidButton))) {
+               lid_state = !lid_state;
+               if (lid_state) {
+                       if (s.button_lid_bright_enabled) {
+@@ -982,7 +982,7 @@
+       //
+       // the power button on the other hand is an off/on switch for non-suspend type ops
+       //
+-      if (power_state != laptop_portable::get_button(laptop_portable::PowerButton)) {
++      if (s.enable_power_button && (power_state != laptop_portable::get_button(laptop_portable::PowerButton))) {
+               power_state = !power_state;
+               if (power_state) {
+                       if (power_button_off) {
+diff -Nur kdeutils-3.4.3.orig/klaptopdaemon/portable.cpp kdeutils-3.4.3/klaptopdaemon/portable.cpp
+--- kdeutils-3.4.3.orig/klaptopdaemon/portable.cpp     2005-10-05 15:26:42.000000000 +0200
++++ kdeutils-3.4.3/klaptopdaemon/portable.cpp  2005-10-18 15:38:21.000000000 +0200
+@@ -1937,19 +1937,19 @@
+ laptop_portable::get_button(LaptopButton l)   // true if a button is pressed
+ {
+       if (::has_acpi()) {
+-              QString *name=0;
++              QString name;
+               switch (l) {
+               case LidButton:
+-                      name = &acpi_lid_name;
++                      name = acpi_lid_name;
+                       break;
+               case PowerButton:
+-                      name = &acpi_power_name;
++                      name = acpi_power_name;
+                       break;
+               default:
+                       break;
+               }
+-              if (name) {
+-                      QFile f(*name);
++              if (!name.isNull()) {
++                      QFile f(name);
+                       if (f.open(IO_ReadOnly)) {
+                               while (!f.atEnd()) {
+                                       QString l;
diff --git a/kde-base/klaptopdaemon/klaptopdaemon-3.4.3-r1.ebuild b/kde-base/klaptopdaemon/klaptopdaemon-3.4.3-r1.ebuild
new file mode 100644 (file)
index 0000000..70dc541
--- /dev/null
@@ -0,0 +1,15 @@
+# Copyright 1999-2005 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/kde-base/klaptopdaemon/klaptopdaemon-3.4.3-r1.ebuild,v 1.1 2005/10/19 14:35:25 greg_g Exp $
+
+KMNAME=kdeutils
+MAXKDEVER=$PV
+KM_DEPRANGE="$PV $MAXKDEVER"
+inherit kde-meta eutils
+
+DESCRIPTION="klaptopdaemon - KDE battery monitoring and management for laptops"
+KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE=""
+
+# Fix output of klaptopdaemon (kde bug 103437).
+PATCHES="${FILESDIR}/kdeutils-3.4.3-klaptopdaemon.patch"
index 987dba80a9bd39f48bc851dea8e3353910a1c29f..632de21db04d6aa80a0fdbb2fef5adc0bb4fa295 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2005 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/kde-base/klaptopdaemon/klaptopdaemon-3.5.0_beta2.ebuild,v 1.1 2005/10/14 18:41:55 danarmak Exp $
+# $Header: /var/cvsroot/gentoo-x86/kde-base/klaptopdaemon/klaptopdaemon-3.5.0_beta2.ebuild,v 1.2 2005/10/19 14:35:25 greg_g Exp $
 
 KMNAME=kdeutils
 MAXKDEVER=$PV
@@ -11,3 +11,5 @@ DESCRIPTION="klaptopdaemon - KDE battery monitoring and management for laptops"
 KEYWORDS="~amd64"
 IUSE=""
 
+# Fix output of klaptopdaemon (kde bug 103437).
+PATCHES="${FILESDIR}/kdeutils-3.4.3-klaptopdaemon.patch"