diff options
author | Thilo Bangert <bangert@gentoo.org> | 2009-10-16 11:44:53 +0000 |
---|---|---|
committer | Thilo Bangert <bangert@gentoo.org> | 2009-10-16 11:44:53 +0000 |
commit | 2495e711020f45e649c4c5fbf8b1a6276edb1639 (patch) | |
tree | 83779f045077d2554d8908481b5e099ee71202de /app-laptop | |
parent | remove old (diff) | |
download | gentoo-2-2495e711020f45e649c4c5fbf8b1a6276edb1639.tar.gz gentoo-2-2495e711020f45e649c4c5fbf8b1a6276edb1639.tar.bz2 gentoo-2-2495e711020f45e649c4c5fbf8b1a6276edb1639.zip |
make it work for newer kernels (bug #254322) - eapi 2 - add IUSE
(Portage version: 2.2_rc42/cvs/Linux i686)
Diffstat (limited to 'app-laptop')
4 files changed, 55 insertions, 4 deletions
diff --git a/app-laptop/khdapsmonitor/ChangeLog b/app-laptop/khdapsmonitor/ChangeLog index 346e0296668a..15b659cbb35b 100644 --- a/app-laptop/khdapsmonitor/ChangeLog +++ b/app-laptop/khdapsmonitor/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for app-laptop/khdapsmonitor -# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/app-laptop/khdapsmonitor/ChangeLog,v 1.3 2008/11/22 18:08:23 maekke Exp $ +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/app-laptop/khdapsmonitor/ChangeLog,v 1.4 2009/10/16 11:44:52 bangert Exp $ + +*khdapsmonitor-0.1-r1 (16 Oct 2009) + + 16 Oct 2009; Thilo Bangert <bangert@gentoo.org> khdapsmonitor-0.1.ebuild, + +khdapsmonitor-0.1-r1.ebuild, + +files/khdapsmonitor-0.1-support-kernels-after-2.6.27.patch: + make it work for newer kernels (bug #254322) - eapi 2 - add IUSE 22 Nov 2008; Markus Meier <maekke@gentoo.org> khdapsmonitor-0.1.ebuild: add ~amd64, bug #243056 diff --git a/app-laptop/khdapsmonitor/files/khdapsmonitor-0.1-support-kernels-after-2.6.27.patch b/app-laptop/khdapsmonitor/files/khdapsmonitor-0.1-support-kernels-after-2.6.27.patch new file mode 100644 index 000000000000..920345ef4b62 --- /dev/null +++ b/app-laptop/khdapsmonitor/files/khdapsmonitor-0.1-support-kernels-after-2.6.27.patch @@ -0,0 +1,22 @@ +--- khdapsmonitor-0.1/src/sysfs.cpp.old 2006-06-29 20:16:10.000000000 +0100 ++++ khdapsmonitor-0.1/src/sysfs.cpp 2009-01-09 14:58:26.133559012 +0000 +@@ -63,6 +63,9 @@ + { + if(QFile("/sys/block/" + deviceList[i] + "/queue/protect").exists()) + i++; ++ // newer kernels provide a different interface ++ else if (QFile("/sys/block/" + deviceList[i] + "/device/unload_heads").exists()) ++ i++; + else + deviceList.remove(deviceList.at(i)); + } +@@ -71,5 +74,9 @@ + + bool SysFS::queueProtected(QString device) + { ++ // newer kernels provide a different interface ++ if (QFile("/sys/block/" + device + "/device/unload_heads").exists()) ++ return fileBool("/sys/block/" + device + "/device/unload_heads"); ++ else + return fileBool("/sys/block/" + device + "/queue/protect"); + } diff --git a/app-laptop/khdapsmonitor/khdapsmonitor-0.1-r1.ebuild b/app-laptop/khdapsmonitor/khdapsmonitor-0.1-r1.ebuild new file mode 100644 index 000000000000..5e989c83552d --- /dev/null +++ b/app-laptop/khdapsmonitor/khdapsmonitor-0.1-r1.ebuild @@ -0,0 +1,21 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-laptop/khdapsmonitor/khdapsmonitor-0.1-r1.ebuild,v 1.1 2009/10/16 11:44:52 bangert Exp $ + +EAPI="2" +ARTS_REQUIRED="never" +inherit kde + +DESCRIPTION="KDE monitor for the Hard Drive Active Protection System" +HOMEPAGE="http://roy.marples.name/projects/khdaps/wiki" +SRC_URI="http://roy.marples.name/files/${P}.tar.bz2" + +LICENSE="GPL-2" +KEYWORDS="~amd64 ~x86" +IUSE="" + +need-kde 3.5 + +PATCHES=( + "${FILESDIR}/khdapsmonitor-0.1-support-kernels-after-2.6.27.patch" +) diff --git a/app-laptop/khdapsmonitor/khdapsmonitor-0.1.ebuild b/app-laptop/khdapsmonitor/khdapsmonitor-0.1.ebuild index d72b86fe6da6..ae4d87f2140f 100644 --- a/app-laptop/khdapsmonitor/khdapsmonitor-0.1.ebuild +++ b/app-laptop/khdapsmonitor/khdapsmonitor-0.1.ebuild @@ -1,6 +1,6 @@ -# Copyright 1999-2008 Gentoo Foundation +# Copyright 1999-2009 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/app-laptop/khdapsmonitor/khdapsmonitor-0.1.ebuild,v 1.2 2008/11/22 18:08:23 maekke Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-laptop/khdapsmonitor/khdapsmonitor-0.1.ebuild,v 1.3 2009/10/16 11:44:52 bangert Exp $ inherit kde @@ -10,5 +10,6 @@ SRC_URI="http://roy.marples.name/files/${P}.tar.bz2" LICENSE="GPL-2" KEYWORDS="~amd64 ~x86" +IUSE="" need-kde 3.5 |