diff options
Diffstat (limited to 'app-laptop')
105 files changed, 3458 insertions, 0 deletions
diff --git a/app-laptop/batti/Manifest b/app-laptop/batti/Manifest new file mode 100644 index 000000000000..5eb9ea69117d --- /dev/null +++ b/app-laptop/batti/Manifest @@ -0,0 +1,7 @@ +AUX batti-0.3.8-upower-0.99.patch 1248 SHA256 38309062cb0111df2c96c49e0b468a120fd3d145c3960b669f71cc020fbc2e5f SHA512 172036b2d5f63c37d26a9542e9348b469c2df4e1380fa3ff4c13883e3a295963c569230b32a36eba14f70e37f87dfc2fcfe03e98406a335749f2d0234c5d30be WHIRLPOOL 2950fcf9b7ef984c0d1fbeed3ed8cd2db9f0d19af8bf2f2399eda0d791f48fb0d23763856cb4c38631ca7fea28b5e11701889d4bde015630ba5010897f7e933e +AUX batti-0.3.8-upower-capital.patch 1409 SHA256 bfaab9a945decbce2efa0a516cf373af0349ee2855560323489b263312c22224 SHA512 6b0f0fafe7443338b9af69156476fdbe231054010ec1ac17dada5c9f68c23477f50bc32d450cf7b3af5c2d012d3264aff4a74630ea2543e500c1f5c95534f1b6 WHIRLPOOL 89c621369f05616f0848f7ea725549a89ab2e5d859456ab52cdbdb58b6f9a5eec01a8c8d3919d340851adb2637ec3a97a72939b3e444580a6961d3a5041d9a95 +DIST batti-0.3.8.tar.gz 59783 SHA256 a63f99bc63dad743abef18ac666e11247011cf9136a11286b131467d9f484d1c SHA512 39e0085a13847359eb555eff80c3f3b166775558fba3c76ecb4315786e2ce4307d21dcac5fab38da4ee3cc2035356906eb1354ced56a1f007735029e0484a4de WHIRLPOOL 93f9dcc1b7a42968859eb79db593e0be694b6a31a14152e589cd1866172185a296b67b4e2131923d369ee21b3f36f80f42d8b7eb4aa91edad5d6ef96a5d2038c +EBUILD batti-0.3.8-r4.ebuild 966 SHA256 698ebf99b6438aec9d5076565128136e1070118bb3f9e1423ec042af0c300129 SHA512 149e6aedf94fd886c93b1b31d4d52098d655d9b6566477de28f9c0d06b5269080caf74939f6cae7cf927d7ada6516b6d06e69ab90d644f27336b74e1ec6e87b5 WHIRLPOOL d01b9afd4aee1437a69cd3fca8c3532cff51eadba9f98e9631b997779556208e4df2d50f9ba9b6e22608c9f18b4b85a4b4a6af00323a30b926a4d7ffd0926278 +MISC ChangeLog 3120 SHA256 ac4d01c74a4bb08f4c52583b3f0423e9de81d0212e895157fa68c23174086265 SHA512 df2545bcbfa5fdeba7a9ae6e3bbbc8fe2a79117181cfa9ecc89cb43fadbcec9fa30d6e52c1c70220b03565389ae7f2d1764e1d2d882d7a543eba19e8a7a34bb1 WHIRLPOOL 2b346211d3e5a3fe422081603c09dd8b459b2ae05f91601225311f8d5686924b4e2c8c4b56c2bcd234fa74aa7356ff4570731dea15b503a49508197c72c7ef7e +MISC ChangeLog-2015 4155 SHA256 100bc147aaa555ce7b05791ecec74d63f51a0f99ef8ff7ca63e9deb260a16970 SHA512 35cf3c76918bffc9d2479ce6daabc790f2a1e57af63b414b6eeabb0896ce0f95e71ab40a8216d698b525f6bfb5a9f3f9c8c8a032e0ad35f43f30a4ab324d080b WHIRLPOOL 7b12099818e8edfc46a937931f620a43ef9a7b6e6fe14ee01d65c4d32ff2d89238b5b4bb00d3f24240cad0504a0a375bab9429e7281d94847e51cdabcb15af49 +MISC metadata.xml 323 SHA256 9cc9000c687169d57161da084a9005e2699702d1f9445cfaea0746a05879193e SHA512 7b3c4c3895e87916db14eb4d611dea5be29d2d1846ee9ec47f56abba20b31091c834f3d5562a57b4fb828e2866f9c6e64ba9f57d25bcf7a2195bca2f7363c5aa WHIRLPOOL e5ee5a5f4e6cfcf1e5c97af079c2b78e46a96e3468c265ec7874fb55788b731fa4f5564caff92d8a5f1f73a68b817f9a7c6b3d9f323066fbc44a5de036cae362 diff --git a/app-laptop/batti/batti-0.3.8-r4.ebuild b/app-laptop/batti/batti-0.3.8-r4.ebuild new file mode 100644 index 000000000000..f4824578587d --- /dev/null +++ b/app-laptop/batti/batti-0.3.8-r4.ebuild @@ -0,0 +1,45 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 +PYTHON_COMPAT=( python2_7 ) + +inherit distutils-r1 gnome2-utils + +DESCRIPTION="A upower based battery monitor for the system tray, similar to batterymon" +HOMEPAGE="https://code.google.com/p/batti-gtk/" +SRC_URI="https://batti-gtk.googlecode.com/files/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 x86" +IUSE="libnotify" + +RDEPEND=" + dev-python/pygtk:2[${PYTHON_USEDEP}] + dev-python/dbus-python[${PYTHON_USEDEP}] + || ( sys-power/upower sys-power/upower-pm-utils ) + x11-themes/hicolor-icon-theme + libnotify? ( x11-libs/libnotify ) +" +DEPEND="" + +src_prepare() { + default + if has_version ">=sys-power/upower-0.99"; then + eapply "${FILESDIR}/${P}-upower-0.99.patch" + eapply "${FILESDIR}/${P}-upower-capital.patch" + fi +} + +pkg_preinst() { + gnome2_icon_savelist +} + +pkg_postinst() { + gnome2_icon_cache_update +} + +pkg_postrm() { + gnome2_icon_cache_update +} diff --git a/app-laptop/batti/files/batti-0.3.8-upower-0.99.patch b/app-laptop/batti/files/batti-0.3.8-upower-0.99.patch new file mode 100644 index 000000000000..6f313a594c94 --- /dev/null +++ b/app-laptop/batti/files/batti-0.3.8-upower-0.99.patch @@ -0,0 +1,34 @@ +diff -Naur batti-0.3.8.orig/src/PowerBackend.py batti-0.3.8/src/PowerBackend.py +--- batti-0.3.8.orig/src/PowerBackend.py 2014-04-15 19:30:34.123260000 +0200 ++++ batti-0.3.8/src/PowerBackend.py 2014-04-15 19:32:11.859168509 +0200 +@@ -180,17 +180,6 @@ + + properties = dbus.Interface(iface, 'org.freedesktop.DBus.Properties') + +- if properties.Get(self.dbus_interface, 'CanSuspend'): +- self.__can_suspend = True +- else: +- self.__can_suspend = False +- +- if properties.Get(self.dbus_interface, 'CanHibernate'): +- self.__can_hibernate = True +- else: +- self.__can_hibernate = False +- +- + def __get_interface(self): + dkit_obj = self.__bus.get_object(self.dbus_service, self.dbus_object) + return dbus.Interface(dkit_obj, self.dbus_interface) +@@ -201,12 +190,6 @@ + self.__mc_action(widget, event, data) + + +- def can_suspend(self): +- return self.__can_suspend and self.__get_interface().SuspendAllowed() +- +- def can_hibernate(self): +- return self.__can_hibernate and self.__get_interface().HibernateAllowed() +- + def suspend(self): + self.__get_interface().Suspend() + diff --git a/app-laptop/batti/files/batti-0.3.8-upower-capital.patch b/app-laptop/batti/files/batti-0.3.8-upower-capital.patch new file mode 100644 index 000000000000..e7f62761661c --- /dev/null +++ b/app-laptop/batti/files/batti-0.3.8-upower-capital.patch @@ -0,0 +1,32 @@ +From 1e0fe57a93ed3996bad295e20eeda81f6af483af Mon Sep 17 00:00:00 2001 +From: Christian Ruppert <idl0r@gentoo.org> +Date: Wed, 20 Jul 2016 20:14:32 +0200 +Subject: [PATCH] The type property (in recent UPower at least) needs to have a + capital T - "Type" + +--- + src/PowerBackend.py | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/src/PowerBackend.py b/src/PowerBackend.py +index e020b98..56bcb61 100644 +--- a/src/PowerBackend.py ++++ b/src/PowerBackend.py +@@ -165,7 +165,7 @@ def __init__(self): + self.__batteries = {} + for dev in devices: + (prop_iface, dev_iface) = self.__get_battery(dev) +- type = prop_iface.Get(self.device_interface, 'type') ++ type = prop_iface.Get(self.device_interface, 'Type') + if type == self.bat_type: + power_bat = UPowerBattery(prop_iface, dev_iface) + self.__batteries[dev] = power_bat +@@ -228,7 +228,7 @@ def set_right_popup_menu_action(self, action): + def __device_added(self, udi): + (prop_iface, dev_iface) = self.__get_battery(udi) + try: +- type = prop_iface.Get(self.device_interface, 'type') ++ type = prop_iface.Get(self.device_interface, 'Type') + if type == self.bat_type: + power_bat = UPowerBattery(prop_iface, dev_iface) + power_bat.set_left_popup_menu_action(self.__mc_action) diff --git a/app-laptop/batti/metadata.xml b/app-laptop/batti/metadata.xml new file mode 100644 index 000000000000..c26d102ee702 --- /dev/null +++ b/app-laptop/batti/metadata.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>naota@gentoo.org</email> + <name>Naohiro Aota</name> + </maintainer> + <upstream> + <remote-id type="google-code">batti-gtk</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/dispad/Manifest b/app-laptop/dispad/Manifest new file mode 100644 index 000000000000..b0b63614caca --- /dev/null +++ b/app-laptop/dispad/Manifest @@ -0,0 +1,5 @@ +DIST dispad-0.3.1.tar.gz 97952 SHA256 507ec8ab213db38dcef81df9df776b8dad1ec9e8aa5ea52cff1cd2c29a32c647 SHA512 fa9666e79de31f79f3567ae3b529c6df3cf56c134c1fe30d62b7d863d623c89abd6b1153de972507a3795c20001f11caf1e49926a402d145a048014aa97cd400 WHIRLPOOL 8cdc48bd58db72d49a1e794bd858b74cfac88867f0a2612ba7a1d8c85d443f177425c32752babbbae4fd8517d621d66bd0bd2dec9c449ff8f170c345bab559f6 +EBUILD dispad-0.3.1.ebuild 535 SHA256 72452e39d3d67be6ad8401ea47ac796a07f0a38a9e340b6c79de0ddbdc55121f SHA512 07fd3f15382a0724cd94833a6a94095453f98212cf410f8de4c50c036498d6ee82dc77446b4f8b09df00066b3cb2349b38df7b96cfc031dbe732ace6acf025d5 WHIRLPOOL 88e8b1fbf2801079df3f325ba67b2c28dfb006d32efef674ffbda1ba3d54a7e5183bd04802b104846d56d24a867cd52ed54f1abdcd19d082ce58c1bbe9be8570 +MISC ChangeLog 2338 SHA256 cd6fa8b86a46cd73d5688f92f8cb9781afecffe0a48417010fb34d0064caaf21 SHA512 503f9a591bfec63a42907c5c04205f7a8d6303b5af90419c6353e98598d41460a8c3ad00a1eb4d1d236f7641995be799b625b89955bb515a5e96818f79fc6884 WHIRLPOOL c334eb904120065f1f5cce03ecfca5115b42d1a77fbc7de08f6a9a022f7720d598fff8143b6fdd7e5e9c5b2d46969a8bf23c09ef01a778f07e455fb3201d85da +MISC ChangeLog-2015 573 SHA256 ecb33502e69bad3939f115aecb31f65432d2b70b0d64df630a35c38fbebffab4 SHA512 6522e23b879db95ac1620fa4518beb0f6b90b4b681481caccfd08090e5c2190ba3cf9b5b876f3dc55a75eff90aecf6440f9907ca18980a8b85202abc8b562224 WHIRLPOOL ff2febe3ce20a01225ab9398838a0cf019ac3a71f0671f59a757f12c460ff9e1056d4206f4a063e437504ede4d9412c87e389367405211f01e622369dade39ff +MISC metadata.xml 311 SHA256 a8fdf0675e3578b74fdb5e22a6102ae009fb52bd2b1fe4cfa948779b610ae717 SHA512 7a28487c5bcdd8518abf28120e0f060c7b1c12d25c98759dd0d7254ae6c10ba0e7276cd240627aac07b5e462fa29ba2b8681f4cdb78cf8a465c6c928961293f1 WHIRLPOOL 83e9041804c31ec4b7228a7142b239d2c8b4550f073ad2efb5e86d169666e5db0f6085d05f06dbff8d20caabf8887df0139b1ca24fc0e65c8cd58e6e5aad0090 diff --git a/app-laptop/dispad/dispad-0.3.1.ebuild b/app-laptop/dispad/dispad-0.3.1.ebuild new file mode 100644 index 000000000000..ea39e4aed2b1 --- /dev/null +++ b/app-laptop/dispad/dispad-0.3.1.ebuild @@ -0,0 +1,25 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=4 +inherit autotools + +DESCRIPTION="Daemon to disable trackpads while typing" +HOMEPAGE="https://github.com/BlueDragonX/dispad" +SRC_URI="https://github.com/BlueDragonX/dispad/tarball/v${PV/_/-} -> ${P}.tar.gz" + +S="${WORKDIR}/BlueDragonX-dispad-dbb9be3" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~x86 ~amd64" +IUSE="" + +DEPEND="x11-libs/libX11 + x11-libs/libXi + dev-libs/confuse" +RDEPEND="${DEPEND}" + +src_prepare() { + eautoreconf -i +} diff --git a/app-laptop/dispad/metadata.xml b/app-laptop/dispad/metadata.xml new file mode 100644 index 000000000000..9e74a51079ce --- /dev/null +++ b/app-laptop/dispad/metadata.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>jsbronder@gentoo.org</email> + </maintainer> + <upstream> + <remote-id type="github">BlueDragonX/dispad</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/hdaps-gl/Manifest b/app-laptop/hdaps-gl/Manifest new file mode 100644 index 000000000000..40ad8cc591ea --- /dev/null +++ b/app-laptop/hdaps-gl/Manifest @@ -0,0 +1,6 @@ +AUX hdaps-gl-0.0.5-as-needed.diff 346 SHA256 daa97477fa732fc326b9b497b36eddd953e90aaabbad9721df0a1538f2a4c21a SHA512 6128fb53c82485a7141d7bff95aea3ab6d20593a9c535bee841c22bcba9504bdf3913eff07fab0de3b58225cab60b3a41638b250d37f1a0f4f67d03c02a29716 WHIRLPOOL 9ff15a66a990d581a6717855ea4d75b3afe890326dcee4ebdf4195db96817b3f2a74b3dd87912f42b6b777f1da5160803e03ca3ad46717035d0754ff4ab3a392 +DIST hdaps-gl-0.0.5.tar.gz 2495 SHA256 d7696a42be66b09d492345c3a05b7c3b45f5e8e33464d3a74844b78182c73c64 SHA512 6ebef6324fcdfaf5c2ec6cc8382d376c711e5d957a4ffdd4ee150317649ea0a47552e421f8008a3498ac49487657dca2f49b1a50169d7ab02ee5bef856625d19 WHIRLPOOL 1e8182f8d6e7c378204c2b91c4bb9d8a7574b3d636485e1349b037c82feee06985ee9d4e9e7cc155d5c67b2bb81739a6ff9350a29e87ac5f7d16efedec1ad1fa +EBUILD hdaps-gl-0.0.5.ebuild 604 SHA256 e6e12cead21105e8e89eb3214429b48347112161fc1c9b24a2cce398101d547b SHA512 3338f31513e579b73e7ae97eacdcf906076745db0ad01e297114d4db78dcfa8f83a41dec409d77d8cb5d9de84c23b8af282ae62e64bcef0c14b3cf9d1db2c6b4 WHIRLPOOL 67ea0e8fd9f4f2b65e317b0c86697fa3fd79800d80702a8b82e8e2cbafc86adec5ed6008f62017eb3bdeba2a7a3d8b3a79a2e1a59bd3f6902957777cb7a6a2f5 +MISC ChangeLog 2565 SHA256 c0a77bd3a72d3ea832a3df506caf6dd34880ccec0ff6a3b5c010031c6e9e4330 SHA512 65fe12e70ec3598bc10a616582cd0f1329a0b5c78908b29e30f59e2df79828426166f8baee8b7a0f76a7e64333955e1f346e8844202740abaeb4e144c693fb74 WHIRLPOOL 5b5bf6aae4183a704e0a7326c5db83c5d7e98ce227cf0e0679ae57790a014927ee19619c455bcd7d14eb0d6aa46dd38678baa3c2e2a9d32ade822d8ed806c977 +MISC ChangeLog-2015 1250 SHA256 d80c0ce14e73fbc8133dcaf052545339012e2c60293321dc51ea97b66cddb0ce SHA512 65b592720f8593bee14ff74a10588af15e97639a3c7e3eaa7f001590b390c030607a39c228459bd763d18abb3e27505bf6ec816f1af13b62a6882b404c6d98fa WHIRLPOOL a667ac62863781cba3643bcd243d11a1ee8c38126b89b0c0c3c2feda6cb7426b596e376747c25dc30bd1d2cbbd8c89c3d8f56ec74ecbb9dfdc4783ba68247e8a +MISC metadata.xml 242 SHA256 0261e0885f6d691d9259efe92bba1e12ab12a3ca43c1118142c0635c05ce2012 SHA512 8376434ff91f5848064ea6c4e040d35ada37f295c0120b65ee9418f6d140ca98a8fb442bdb1e03b292cecc404f323cb9b28ed83da353e5e4dd5eb7f842f2df18 WHIRLPOOL 1165d6f0496ee7bc00affd3fc293e51cf3e15e276c60f18a6cbb7f8517b408762c44b69ff7c68e716704ca337fd3afbe6288db69e5212d88a7d92afbd5d463bf diff --git a/app-laptop/hdaps-gl/files/hdaps-gl-0.0.5-as-needed.diff b/app-laptop/hdaps-gl/files/hdaps-gl-0.0.5-as-needed.diff new file mode 100644 index 000000000000..0d0214033252 --- /dev/null +++ b/app-laptop/hdaps-gl/files/hdaps-gl-0.0.5-as-needed.diff @@ -0,0 +1,11 @@ +--- hdaps-gl-0.0.5/Makefile 2005-08-30 20:06:53.000000000 +0200 ++++ hdaps-gl-0.0.5-1/Makefile 2008-09-22 22:55:57.000000000 +0200 +@@ -10,7 +10,7 @@ + all: hdaps-gl + + hdaps-gl: hdaps-gl.c +- $(CC) $(CFLAGS) $(LIBDIR) $(LIBRARIES) -o hdaps-gl hdaps-gl.c ++ $(CC) $(CFLAGS) $(LIBDIR) -o hdaps-gl hdaps-gl.c $(LIBRARIES) + + clean: + rm -f hdaps-gl *.o diff --git a/app-laptop/hdaps-gl/hdaps-gl-0.0.5.ebuild b/app-laptop/hdaps-gl/hdaps-gl-0.0.5.ebuild new file mode 100644 index 000000000000..7bc369635dc7 --- /dev/null +++ b/app-laptop/hdaps-gl/hdaps-gl-0.0.5.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=4 + +inherit eutils toolchain-funcs + +DESCRIPTION="OpenGL visualization for HDAPS data" +HOMEPAGE="http://hdaps.sourceforge.net" +SRC_URI="mirror://sourceforge/hdaps/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 x86" +IUSE="" + +DEPEND="virtual/opengl + media-libs/freeglut" +RDEPEND="${DEPEND}" + +src_prepare() { + epatch "${FILESDIR}/${P}-as-needed.diff" +} + +src_compile() { + emake CC="$(tc-getCC)" \ + CFLAGS="${CFLAGS} ${LDFLAGS}" \ + || die "emake failed" +} + +src_install() { + dobin ${PN} +} diff --git a/app-laptop/hdaps-gl/metadata.xml b/app-laptop/hdaps-gl/metadata.xml new file mode 100644 index 000000000000..4d89b7be7780 --- /dev/null +++ b/app-laptop/hdaps-gl/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <!-- maintainer-needed --> + <upstream> + <remote-id type="sourceforge">hdaps</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/hdapsd/Manifest b/app-laptop/hdapsd/Manifest new file mode 100644 index 000000000000..19517237ada7 --- /dev/null +++ b/app-laptop/hdapsd/Manifest @@ -0,0 +1,7 @@ +AUX hdapsd.conf-20141024 739 SHA256 dd37f05c2d2e76e9e12f7b5398a1b4a64b765ecf97c48320a7d278411e808e33 SHA512 e03c7f02af2789a784284f10eed10e10edb82e2ad16d3794299cc9622c00a047f30df7f7d553ef572e265815684d1e783932e0f3b219cca44f0e1f74dc045944 WHIRLPOOL fadc681435c884bbd56115989ce9ee461bd81c8f4aa6b77a607464ee48bf11389b6659401bccd509b1ce057cef28ff08a98b87b9b6a2ae70a746c4afc4ef0ec8 +AUX hdapsd.init-20141024 2177 SHA256 2e58c8c24a5fd12e2e265a243de4813c49066683aac55de92e84089448d63243 SHA512 e45b7e6fafd047c6fe7b172ad552c23b0000b90099a9a12e5a09133258e90d5f121bfa5e8a638f1dcd35110e54fc1da2462cdd501ebb65878286f623c7baa6dc WHIRLPOOL 859dfad31b5bacdd60f531d94e269713a77d790cfdf951db901b312fd3a8da11128622dfd0af657bffabc092746e779a4876eb0fbdfd4fc49836794123b12d0b +DIST hdapsd-20141203.tar.gz 128818 SHA256 6650db6b2251b9774bdfba34dd58f712de4c761e6c78eb61ea3b82b694cbef5e SHA512 19c1a8b362f15864b71f4fb221c0993b43b3b2d965d5826af06fb9f6b0e345e5da99181493e13e230c7fe77060ae5b373027e8ec90a511566a6ccaef43998178 WHIRLPOOL befbcbbdcfc5ae9a844f0a96703a7c9a7d43bf4c5d6d9735412efc136d9e20aff6a4dc3e5755cfa9837122b4f7890b00be53a21237838b078271ba7c9650589c +EBUILD hdapsd-20141203.ebuild 2159 SHA256 3f72bd336ab1ae9463ec9f6edc125def5cb76db4b4c64758367e8ff751164e00 SHA512 f2386ff6d0d1d6a4f09f0c314649b5e0fb93f888da3a0dba6f11c1c436e1997d3a97bc43f138c0369bf9f2e8dd7d4901b3932ed3846999930d6a85486e384275 WHIRLPOOL 049a6455907702250acb62ee29ccec2a08770691c4bffeaa16d5d72f63ec3b6fb70e55952b6b14266661c7a46b8e19969601b13af00a0bdaed7257895c925446 +MISC ChangeLog 3361 SHA256 d890b6ae2d37ff01e03b2e4f0fda7f7b460d36026ea025964f84814e46de2ae9 SHA512 7e209236f1a936b073e74408c13d304247130b6cb050265075a5a45d5d625e9ac9d5aed247a6d1a1e9733ba825aafa6e2038411eaeac22769fcac3f4c52bfbf6 WHIRLPOOL 4f17e6209bd2b6044f51c89e95b6cb2d8c713fd22373b84d50d06ab181586e35f1569441420d5f88a443bcbf4e70037f5731fac66d575089498150d1212c7590 +MISC ChangeLog-2015 4661 SHA256 c23f212d56bf87fc5600108de8a40819a53dac913cfc4f2b9be124f7ae27790c SHA512 6c9bec1d033b1d020786d89d314b0cfb27b9c21dc83ccca5acd5204e1adb394545d75d1ec72ab87af5fb748831a51adc24b0cabc1f6cedb5ac1e4bd54fa8620a WHIRLPOOL 569378bf73475bbf44a96b8a39c74bc221f918c6339bec626a809b2c5a2b181a68e1f51047af1ca711df3f8a932f1bd103ea2cba4f06a0fd24b1e203625b23d7 +MISC metadata.xml 673 SHA256 8957ea0e7a7539477181e3bba248c4e379d90be96c3d3eeb964e9f0e163b0043 SHA512 296b864ed6a816faa8dd2e65471cb74a0b8a99b29dcf315bc4d31cb81f77a1c7982cc1f1929b2331ae57d0bef3a73273793b0b8da04142d0df13d364c3ab6545 WHIRLPOOL 28dc758c3ff134e99ad148d5fd20bc0cd7f96d41d8e7a3bb2d375c68ac30e66ee8bd3d9274bee3386e28daecc24d16d167b0e98021fe4240b9cfc0c4f44d3d27 diff --git a/app-laptop/hdapsd/files/hdapsd.conf-20141024 b/app-laptop/hdapsd/files/hdapsd.conf-20141024 new file mode 100644 index 000000000000..a83d8bb181ac --- /dev/null +++ b/app-laptop/hdapsd/files/hdapsd.conf-20141024 @@ -0,0 +1,24 @@ +# Configuration for the HDAPS daemon (hdapsd). All settings here are +# optional and will override those set in /etc/hdapsd.conf (if hdapsd +# was built with libconfig support). + +# The list of the disk devices that hdapsd should monitor. Usually +# this is "hda", "sda", or "hda sda". The hdaps daemon will attempt to +# auto-detect your drive if this is left empty. Empty by default. +# +#DISKLIST="sda" + +# Hdapsd sensitivity. The lower the threshold, the earlier the heads +# are parked when movement is detected. The default is determined by +# hdapsd, and is currently 15. +# +#THRESHOLD="10" + +# Log to syslog? Disabled by default. +# +#SYSLOG="true" + +# Set any extra options here, like -a for "adaptive mode". Empty by +# default. +# +#OPTIONS="-a" diff --git a/app-laptop/hdapsd/files/hdapsd.init-20141024 b/app-laptop/hdapsd/files/hdapsd.init-20141024 new file mode 100644 index 000000000000..6113b60b7d7c --- /dev/null +++ b/app-laptop/hdapsd/files/hdapsd.init-20141024 @@ -0,0 +1,76 @@ +#!/sbin/openrc-run +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License, v2 + +description="Hard Drive Active Protection System daemon" +command="/usr/sbin/hdapsd" +pidfile="/run/hdapsd.pid" + +# Always daemonize when started by OpenRC, and don't make the pidfile +# configurable. Even if the user sets something dumb for the pidfile +# in /etc/hdapsd.conf, we want it to work! Fortunately the settings +# passed on the command-line override the config file. +command_args="--background --pidfile=${pidfile}" + + +depend() { + need localmount +} + +checkconfig() { + # An empty DISKLIST is allowed because the disk will be + # auto-detected. + for DISK in ${DISKLIST}; do + if [ ! -b /dev/${DISK} ]; then + eerror "Could not find disk /dev/${DISK}!" + eerror "Adjust the DISK setting in /etc/conf.d/hdapsd" + return 1 + fi + + if [ ! -e /sys/block/${DISK}/queue/protect ] && \ + [ ! -e /sys/block/${DISK}/device/unload_heads ] ; then + eerror "No protect entry for ${DISK}!" + eerror "Make sure your kernel is patched with the blk_freeze patch" + return 1 + fi + done + + # Load the tp_smapi module first. This is not a requirement, but + # it helps hdapsd's adaptive mode. + if [ ! -e /sys/devices/platform/smapi ] ; then + modprobe tp_smapi 2>/dev/null + fi + + if [ ! -d /sys/devices/platform/hdaps ] ; then + ebegin "Loading hdaps module" + modprobe hdaps + eend $? || return 1 + fi +} + +start() { + checkconfig || return 1 + + for DISK in ${DISKLIST}; do + command_args="${command_args} -d ${DISK}" + done + + # Since all of these settings are now optional, we append them + # only if we need to. + if [ ! -z "${THRESHOLD}" ] ; then + command_args="${command_args} --sensitivity ${THRESHOLD}" + fi + + if [ ! -z "${SYSLOG}" ] ; then + command_args="${command_args} --syslog" + fi + + if [ ! -z "${OPTIONS}" ] ; then + command_args="${command_args} ${OPTIONS}" + fi + + ebegin "Starting the ${description}" + start-stop-daemon --start --exec "${command}" --pidfile "${pidfile}" \ + -- ${command_args} + eend $? +} diff --git a/app-laptop/hdapsd/hdapsd-20141203.ebuild b/app-laptop/hdapsd/hdapsd-20141203.ebuild new file mode 100644 index 000000000000..6edd851d9605 --- /dev/null +++ b/app-laptop/hdapsd/hdapsd-20141203.ebuild @@ -0,0 +1,72 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 +inherit linux-info readme.gentoo systemd + +DESCRIPTION="IBM ThinkPad Hard Drive Active Protection System (HDAPS) daemon" +HOMEPAGE="https://github.com/evgeni/${PN}/" +SRC_URI="https://github.com/evgeni/${PN}/releases/download/${PV}/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 x86" +IUSE="libconfig" + +DEPEND="libconfig? ( dev-libs/libconfig )" +RDEPEND="${DEPEND}" + +pkg_setup() { + # We require the hdaps module which can either come from either the + # kernel itself (CONFIG_SENSORS_HDAPS) or from the tp_smapi package. + if ! has_version app-laptop/tp_smapi[hdaps]; then + CONFIG_CHECK="~SENSORS_HDAPS" + ERROR_SENSORS_HDAPS="${P} requires app-laptop/tp_smapi[hdaps] or " + ERROR_SENSORS_HDAPS+="kernel support for CONFIG_SENSORS_HDAPS enabled" + linux-info_pkg_setup + fi +} + +src_configure(){ + econf \ + $(use_enable libconfig) \ + --with-systemdsystemunitdir=$(systemd_get_unitdir) \ + --docdir="/usr/share/doc/${PF}" +} + +src_install() { + default + newconfd "${FILESDIR}/hdapsd.conf-20141024" hdapsd + newinitd "${FILESDIR}/hdapsd.init-20141024" hdapsd + readme.gentoo_create_doc +} + +pkg_postinst(){ + [[ -z $(ls "${ROOT}"sys/block/*/queue/protect 2>/dev/null) ]] && \ + [[ -z $(ls "${ROOT}"sys/block/*/device/unload_heads 2>/dev/null) ]] && \ + ewarn "Your kernel does NOT support shock protection." + + readme.gentoo_print_elog +} + +DISABLE_AUTOFORMATTING=1 +DOC_CONTENTS=" +${PN} requires a kernel module to function properly. The recommended +approach is to install app-laptop/tp_smapi[hdaps], but the in-tree +module provided by CONFIG_SENSORS_HDAPS may work as well. + +Common daemon parameters can be set in ${EROOT}etc/conf.d/${PN}. If the +package was installed with USE=libconfig, then the parameters can also +be set in ${EROOT}etc/${PN}.conf, although the former will take +precedence over the latter if both are used. + +You can change the default sampling rate by modifing + + /sys/devices/platform/hdaps/sampling_rate + +and you may need to enable shock protection manually by running + + # echo -1 > /sys/block/<disk>/device/unload_heads + +as root. +" diff --git a/app-laptop/hdapsd/metadata.xml b/app-laptop/hdapsd/metadata.xml new file mode 100644 index 000000000000..ab39df1369a0 --- /dev/null +++ b/app-laptop/hdapsd/metadata.xml @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>junghans@gentoo.org</email> + <name>Christoph Junghans</name> + </maintainer> + <maintainer type="person"> + <email>mjo@gentoo.org</email> + <name>Michael Orlitzky</name> + </maintainer> + <use> + <flag name="libconfig"> + Require <pkg>dev-libs/libconfig</pkg> to allow the daemon to + read a configuration file at startup + </flag> + </use> + <upstream> + <remote-id type="github">evgeni/hdapsd</remote-id> + <remote-id type="sourceforge">hdaps</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/i8kutils/Manifest b/app-laptop/i8kutils/Manifest new file mode 100644 index 000000000000..d7e43f75bc66 --- /dev/null +++ b/app-laptop/i8kutils/Manifest @@ -0,0 +1,12 @@ +AUX i8k.conf 891 SHA256 7e867dd900bcf393326d350017b29980452b38a30a1cd4581b786091b4571bca SHA512 bc262f0014237abfc87efc60dabbb37e86c459077831b68c07ea13608d1174bd32cb695e74ca4597839f7b128cfc1b4860874cce0c6f511972569e5f0948526d WHIRLPOOL ae5166212cdd0aa5d94c73698e5fc2cbdc6e467b1bad6ee96ffc074108d925251d1139036451cf213d19080724312ce3cccdea0022d4e521faff418eea873ea4 +AUX i8k.init-r1 1216 SHA256 7ee5282e7ba1e666cc6f8c50d558b4dd861ead8b8906805ec17a2b2349a732fe SHA512 39282605172dac48c12819e5adeb080d3c73257d775fb8e53d2bdcf26e0510dd10055d8a51e17043f2a5d49da3ffb73f28a767fbfb44c0bb77feb621e25867cb WHIRLPOOL 414d1569063f7c4f58949f31d5dc20aba97909bb5f7d4205b62e41468df17305d4b0a4dc8fb2e1b344a669a7b3aef22f537305745ad998bfccf839b927f278a6 +AUX i8kmon.service 158 SHA256 a1b941e0779071b9dd1be9e6167e4efb1b4f917a59df4730bf8fa094020d3df5 SHA512 77cbed13d4c1982a491faafe7e45da7a4fc06ea94e6b126405211f54a4bb5b4c794d94f6ca56d6d16ad0e0e62d8311bf90e0e6c60c74147ea12963c530c69529 WHIRLPOOL 3e7f74574d3a98237311e4d135d8b78c913cf793e26168ee734b5735dbd98c552578fca9f3348812f870e57b5f83133ca6dab015e6eaef33a5090e1d29ebb139 +AUX i8kutils-1.42-Makefile.patch 1296 SHA256 d781baa765eb942b9aa4bf447844f2dbc672dc5ef76abee463ee2013de3c3bdd SHA512 3dd548cff896d3b14df0e55059f842cf3e04c0a9057f2c16eea7fb160882ceab4dc91782012d2243a4a78f9271c2effdb09109ffe889c27149a65940b69785d9 WHIRLPOOL f65e38c5c725014e8f5f1cbf03775f1b97c254244db5bfdc8796af7e13ed27b13c51cff1e4610f2712affe3ffe747daa43fbdf7335709dc1b7ca2243aabf37e3 +AUX i8kutils-gcc5.patch 1161 SHA256 ac97c19c3060889d23b6fdcd129e6b06b079345ccbc156a8722ab3fe2c955e02 SHA512 c789ef70244c59041308c5ff692c2bec6cf4fa5e673deeea9ec59cd1b6036e60f6ca4036dea04eaaa1b8172e3388b2f5e02227311e032c9c552e04ac50276616 WHIRLPOOL 88b8e0ffbfe4999e5bfe9af6df4ae531cfef71b88398f97d783163c2660d619a114056eb841eb2b61a924c74457dfdface26e89dde422755ae437510d73c81ed +DIST i8kutils_1.33.tar.gz 50378 SHA256 ebdd39a2be8b5742bd7b24a5dbcbef36ab3b9980330ad07eea471e68b800ecd7 SHA512 a7b9277b8c9bc2642a65122dda31cfa7cc0c4fa780ba980364c0a4e0e4599502c6557871464ff256c5911370d98944826d0e29d4d3621605d5e8c1c8a23e5578 WHIRLPOOL 162cec2b48c1573a8b49d7966db312357754bc4445a9247d6fd0ca43bfabf1ccbe155bdc19c66fcc654f1dd6ff7499e82829e62a726f602a846b01b4a0189eb2 +DIST i8kutils_1.42.tar.xz 37544 SHA256 8764ee6d78e646965fbf1ba653cbfa6e05627eb9922389c132866431d7c3d802 SHA512 148e8788c50cbaa22f1dd3b72867839f5bc2d91cda70aee74f7c9a3d8542386a44652c5eb8dd9eba0e30400fc6bb72855d3cc7f2dc4284c2529b9cba2eac485b WHIRLPOOL da39e9312bf9c224dd2f6272e33361e6230421703170a8ba76965cc1b6994eab69423a824b505f6cead9c45b7288019bc0f663b925e8278b0ddb2b73061f5b36 +EBUILD i8kutils-1.33-r1.ebuild 1063 SHA256 5ac6f88bc9b05abe6b1b5cc90e861cc35715b9abe2c3b33ed6b0f9336bcbcc3c SHA512 62664f2355a3e6603cb462e38d5e5503af27e746e16fcddffa9b60671039fce01edefe433f2af044b65580a4b6bfcbe974ecab53394428e39071bd1002d48d31 WHIRLPOOL 78e7d02dfbc7065bdd053d04b1cdca8bda7d7ddd6749e00747da2f15d0e68971410a7412a0c3a79d1a5b0263b4c9af06c0ebe8623d3290c41b4772991a77ae78 +EBUILD i8kutils-1.42.ebuild 1027 SHA256 3bf076a0cfd4c31b95051d891028c8f0eed224d7e14690d3b3aef959b116e120 SHA512 40edad83ee0c8f0b348a0a0117b2a1476a095b992744e9edba15cf85b0dd603be0f1848228b8b166652e0b3248a2bf72d3ab7535fdd73126f8d26c9a4bc40399 WHIRLPOOL dd3dc1657aea66ebd360eb1b40656f0b3cf729fa339fc3dd74533d211ccb7f7b107300ce1cbd48eef48c1e6ad324c921f3c32c2cccdb236d361189d4c14abb63 +MISC ChangeLog 3705 SHA256 fada92b9b1aee975354b0b6ce13a241efa95b61c265d842ecb8ece2f28ac0003 SHA512 57e330f9a4e02fcce459c18cd2df89bcf81f79961bf9a6e638f23f5c60443287e7d2b6c9430217d3d9f8583a181a3c82b2bd5f7a4bea4e003906f4c9750fb37c WHIRLPOOL 59dca2672173cf0277b7b14eaf55aadd9c562b35e50d1c317786630c65d7add3cf42df4ee9ddffe4c090c3e20a68c08c3a2026de3f8931110016fb62e1911fda +MISC ChangeLog-2015 3717 SHA256 d94e2772edec3585397c340db4116c6d54f2c200a423e5345c067a6f9ed5c1cf SHA512 47d331aaf4d1480278be5a676dfad508d6944981f766846cef6db5f778f23d5365a5a20e41132fba2aeb21d618dc59fcc95cfd2c256f6c77979cfda4e48a1212 WHIRLPOOL 74c6feb1b7723461487517d11d9ec86fd315fceef3cc45b2c8109d628245e236edf78165aa8a6f4ddc212a51e198d97c3702cd39c77b1a31bb081fbc73131cfc +MISC metadata.xml 509 SHA256 75735734ae065f685e92da466605dc0555b6cf6787adb5aa3748554df46db662 SHA512 6c37e778397f104687a4aa86baba9b45e89aa2aa43d0fbff8d2b22f32ff385d5ab3fd4c2c325f033ffa7e0dc375bf4f18082a6907fe19e54c5fce5801484a434 WHIRLPOOL 7947b82cf48bd54c4eb54d67884f2cfbdd187d09b6ac65630f5893c1309de9e4d2599d9bf063cfc326c1df7d033af6577d69d67310f146785b890957c6137e3c diff --git a/app-laptop/i8kutils/files/i8k.conf b/app-laptop/i8kutils/files/i8k.conf new file mode 100644 index 000000000000..c5bd389b294a --- /dev/null +++ b/app-laptop/i8kutils/files/i8k.conf @@ -0,0 +1,31 @@ +# Config file for /etc/init.d/i8k + +# Parameters: +# +# i8kbuttons Parameters +# ===================== +# VOLUME_UP : command for i8kbuttons to run on volume up key +# VOLUME_DOWN : command for i8kbuttons to run on volume down key +# VOLUME_MUTE : command for i8kbuttons to run on mute key +# BUTTON_REPEAT : repeat rate, in milliseconds, for i8kbuttons keypresses +# +# If VOLUME_* commands are not defined, i8kbuttons will not be started +# +# i8kmon Parameters +# ================= +# NOMON : if set, i8kmon will not be started +# NOAUTO : if set, i8kmon will not control the fans +# TIMEOUT : timeout, in seconds, at which i8kmon will check/update status +# (default is 2) + +# for ALSA +MIXER="/usr/bin/amixer -q set Master" +VOLUME_UP="$MIXER 1+" +VOLUME_DOWN="$MIXER 1-" +VOLUME_MUTE="$MIXER toggle" + +# for aumix (no mute support) +#VOLUME_UP="aumix -v +4" +#VOLUME_DOWN="aumix -v -4" + +BUTTON_REPEAT=100 diff --git a/app-laptop/i8kutils/files/i8k.init-r1 b/app-laptop/i8kutils/files/i8k.init-r1 new file mode 100644 index 000000000000..1e1cb7ca0c94 --- /dev/null +++ b/app-laptop/i8kutils/files/i8k.init-r1 @@ -0,0 +1,50 @@ +#!/sbin/openrc-run + +depend() { + after alsasound + after modules +} + +checkconfig() { + if [ ! -e /proc/i8k ] ; then + eerror "The i8k driver is not installed" + return 1 + fi +} + +start() { + checkconfig || return 1 + if [ -n "$VOLUME_UP$VOLUME_DOWN$VOLUME_MUTE" ] ; then + ebegin "Starting i8kbuttons" + start-stop-daemon --start --quiet --pidfile /var/run/i8kbuttons.pid \ + --make-pidfile --exec /usr/bin/i8kbuttons --background \ + -- ${VOLUME_UP:+-u "${VOLUME_UP}"} \ + ${VOLUME_DOWN:+-d "$VOLUME_DOWN"} \ + ${VOLUME_MUTE:+-m "$VOLUME_MUTE"} \ + ${BUTTON_REPEAT:+-r "$BUTTON_REPEAT"} + eend $? + fi + if [ ! -n "$NOMON" ]; then + ebegin "Starting i8kmon" + start-stop-daemon --start -b --quiet \ + --pidfile /var/run/i8kmon.pid \ + --make-pidfile \ + --exec /usr/bin/i8kmon --background \ + --name "tclsh /usr/bin/i8kmon" \ + -- -d ${NOAUTO:+-na} ${TIMEOUT:+-t $TIMEOUT} + eend $? + fi +} + +stop() { + if [ -n "$VOLUME_UP$VOLUME_DOWN$VOLUME_MUTE" ] ; then + ebegin "Stopping i8kbuttons" + start-stop-daemon --stop --quiet --pidfile /var/run/i8kbuttons.pid + eend $? + fi + if [ ! -n "$NOMON" ]; then + ebegin "Stopping i8kmon" + start-stop-daemon --stop --quiet --pidfile /var/run/i8kmon.pid + eend $? + fi +} diff --git a/app-laptop/i8kutils/files/i8kmon.service b/app-laptop/i8kutils/files/i8kmon.service new file mode 100644 index 000000000000..3b80f46334af --- /dev/null +++ b/app-laptop/i8kutils/files/i8kmon.service @@ -0,0 +1,9 @@ +[Unit] +Description=Dell laptop thermal monitoring +ConditionPathExists=/proc/i8k + +[Service] +ExecStart=/usr/bin/i8kmon -d + +[Install] +WantedBy=multi-user.target diff --git a/app-laptop/i8kutils/files/i8kutils-1.42-Makefile.patch b/app-laptop/i8kutils/files/i8kutils-1.42-Makefile.patch new file mode 100644 index 000000000000..7dc56d91aa3e --- /dev/null +++ b/app-laptop/i8kutils/files/i8kutils-1.42-Makefile.patch @@ -0,0 +1,34 @@ +Fix a race condition causing parallel builds to sometimes fail. + +Both probe_i8k_calls_time and i8kctl contain a main() function, though +i8kctl's is omitted when built with -DLIB so they can link without a +conflict. i8kctl is also a standalone exe so it is built twice, with +and without -DLIB. When building in parallel you can get into a +situation where the object file created by the probe_i8k_calls_time +target gets overwritten with the one from i8kctl and bad things happen. +Nothing actually uses the i8kctl.o that has main() so we can just not +build it. + +Also move CFLAGS, CC, LDFLAGS respect out of the ebuild. + +--- a/Makefile ++++ b/Makefile +@@ -17,13 +17,13 @@ ccflags-y = -Wall + + all: i8kctl probe_i8k_calls_time + +-i8kctl: i8kctl.c i8kctl.o +- gcc -Wall i8kctl.c -o i8kctl ++i8kctl: i8kctl.c ++ $(CC) -Wall ${CFLAGS} -o i8kctl i8kctl.c + + probe_i8k_calls_time: probe_i8k_calls_time.c +- gcc -Wall -c -g -DLIB i8kctl.c +- gcc -Wall -c -g -DLIB probe_i8k_calls_time.c +- gcc -o probe_i8k_calls_time i8kctl.o probe_i8k_calls_time.o ++ $(CC) -Wall ${CFLAGS} -c -DLIB i8kctl.c ++ $(CC) -Wall ${CFLAGS} -c -DLIB probe_i8k_calls_time.c ++ $(CC) -Wall ${CFLAGS} ${LDFLAGS} -o probe_i8k_calls_time i8kctl.o probe_i8k_calls_time.o + + i8k: + make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules diff --git a/app-laptop/i8kutils/files/i8kutils-gcc5.patch b/app-laptop/i8kutils/files/i8kutils-gcc5.patch new file mode 100644 index 000000000000..258b95f595f6 --- /dev/null +++ b/app-laptop/i8kutils/files/i8kutils-gcc5.patch @@ -0,0 +1,28 @@ +Fix build with GCC 5. + +x86_64-pc-linux-gnu-gcc -O2 -march=native -g -pipe -c -o i8kctl.o i8kctl.c +gcc -Wall -c -Wl,--hash-style=gnu -Wl,-O1 -Wl,--as-needed -DLIB i8kctl.c +gcc -Wall -c -Wl,--hash-style=gnu -Wl,-O1 -Wl,--as-needed -DLIB probe_i8k_calls_time.c +gcc -o probe_i8k_calls_time i8kctl.o probe_i8k_calls_time.o +probe_i8k_calls_time.o: In function `main': +probe_i8k_calls_time.c:(.text+0x62): undefined reference to `timestamp' +probe_i8k_calls_time.c:(.text+0x82): undefined reference to `timestamp' +probe_i8k_calls_time.c:(.text+0xa2): undefined reference to `timestamp' +probe_i8k_calls_time.c:(.text+0xbf): undefined reference to `timestamp' +probe_i8k_calls_time.c:(.text+0xdc): undefined reference to `timestamp' +probe_i8k_calls_time.o:probe_i8k_calls_time.c:(.text+0xf9): more undefined references to `timestamp' follow +collect2: error: ld returned 1 exit status +Makefile:24: recipe for target 'probe_i8k_calls_time' failed + + +--- a/probe_i8k_calls_time.c ++++ b/probe_i8k_calls_time.c +@@ -13,7 +13,7 @@ double t; + + struct timespec tmst; + +-inline double timestamp() ++double timestamp() + { + clock_gettime(CLOCK_REALTIME, &tmst); + t = tmst.tv_nsec; diff --git a/app-laptop/i8kutils/i8kutils-1.33-r1.ebuild b/app-laptop/i8kutils/i8kutils-1.33-r1.ebuild new file mode 100644 index 000000000000..cf870ed7fd3b --- /dev/null +++ b/app-laptop/i8kutils/i8kutils-1.33-r1.ebuild @@ -0,0 +1,54 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=4 + +inherit systemd toolchain-funcs + +DESCRIPTION="Dell Inspiron and Latitude utilities" +HOMEPAGE="http://packages.debian.org/sid/i8kutils" +SRC_URI="mirror://debian/pool/main/i/${PN}/${P/-/_}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="-* amd64 x86" +IUSE="examples tk" + +DEPEND="tk? ( dev-lang/tk )" +RDEPEND="${DEPEND}" + +DOCS=( README.i8kutils ) + +src_prepare() { + sed \ + -e '/^CC/d' \ + -e '/^CFLAGS/d' \ + -e 's: -g : $(LDFLAGS) :g' \ + -i Makefile || die + + tc-export CC +} + +src_install() { + dobin i8kbuttons i8kctl + doman i8kbuttons.1 i8kctl.1 + dosym /usr/bin/i8kctl /usr/bin/i8kfan + + use examples && dodoc -r examples + + newinitd "${FILESDIR}"/i8k.init-r1 i8k + newconfd "${FILESDIR}"/i8k.conf i8k + + if use tk; then + dobin i8kmon + doman i8kmon.1 + dodoc i8kmon.conf + systemd_dounit "${FILESDIR}"/i8kmon.service + else + cat >> "${ED}"/etc/conf.d/i8k <<- EOF + # i8kmon disabled because the package was installed without USE=tk + NOMON=1 + EOF + fi + +} diff --git a/app-laptop/i8kutils/i8kutils-1.42.ebuild b/app-laptop/i8kutils/i8kutils-1.42.ebuild new file mode 100644 index 000000000000..a02cb3a89a8a --- /dev/null +++ b/app-laptop/i8kutils/i8kutils-1.42.ebuild @@ -0,0 +1,52 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +inherit eutils systemd toolchain-funcs + +DESCRIPTION="Dell Inspiron and Latitude utilities" +HOMEPAGE="https://launchpad.net/i8kutils" +SRC_URI="https://launchpad.net/i8kutils/trunk/${PV}/+download/${P/-/_}.tar.xz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="tk" + +DEPEND="tk? ( dev-lang/tk:0 )" +RDEPEND="${DEPEND} + sys-power/acpi" + +S="${WORKDIR}/${PN}" + +DOCS=( README.i8kutils ) + +src_prepare() { + epatch "${FILESDIR}/${PN}-gcc5.patch" + epatch "${FILESDIR}/${P}-Makefile.patch" + + tc-export CC +} + +src_install() { + dobin i8kctl i8kfan + doman i8kctl.1 + dodoc README.i8kutils + + newinitd "${FILESDIR}"/i8k.init-r1 i8k + newconfd "${FILESDIR}"/i8k.conf i8k + + if use tk; then + dobin i8kmon + doman i8kmon.1 + dodoc i8kmon.conf + systemd_dounit "${FILESDIR}"/i8kmon.service + else + cat >> "${ED}"/etc/conf.d/i8k <<- EOF + + # i8kmon disabled because the package was installed without USE=tk + NOMON=1 + EOF + fi +} diff --git a/app-laptop/i8kutils/metadata.xml b/app-laptop/i8kutils/metadata.xml new file mode 100644 index 000000000000..9891d819025c --- /dev/null +++ b/app-laptop/i8kutils/metadata.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>adi@adirat.com</email> + <name>Ioan-Adrian Ratiu</name> + <description>Proxied maintainer. Assign bugs to him.</description> + </maintainer> + <maintainer type="project"> + <email>proxy-maint@gentoo.org</email> + <name>Proxy Maintainers</name> + </maintainer> + <upstream> + <remote-id type="launchpad">i8kutils</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/ibam/Manifest b/app-laptop/ibam/Manifest new file mode 100644 index 000000000000..721948df1756 --- /dev/null +++ b/app-laptop/ibam/Manifest @@ -0,0 +1,7 @@ +AUX ibam-0.5.2-build.patch 1317 SHA256 595b70cd26b48a4bc0d6693b2d30e54153b5003ecd8f733cad5684b345d3cfdb SHA512 7675b497b516f750d74604072d138876ee84684d8f12f1d8be3bcf0173f321a63fc0f3def0c519091506275e55027bf13fedb1c328983ac8016f6c78210b95f4 WHIRLPOOL fc3d82f623e456e660141fe1c380949be191f5f1bb9654418ac7979b4408a33fcefe469fb656a8d4a874536f074a8e8945d28a24350379b3f6f43acb21add6cf +DIST ibam-0.5.2.tar.gz 22149 SHA256 d668f23088e48be537dbf3ab63f1a8f6f9acb32031b1f6ba6fb185e9e6079d91 SHA512 c70d728a2f1250ed291e663bd9f4e9ba01308fce14edf1ffd1902057de7e5527548bd06e2e3caaaeabc064d0ee123f536a626fd50b84092f6fc9201fc6bdba58 WHIRLPOOL 027878ed946ba0c828c7786ede9f01a7ba8745f44cbb68bb49613da3edab367d17976319c8f32f14dfc0337709b6895afe86bd5700a8d02628bc88d0834ad342 +DIST ibam_0.5.2-2.diff.gz 5914 SHA256 8986814e13e8014bac3daf15a10c446d045e11c0468fff442fab437956a16890 SHA512 baad1e6bdc416de6d82181e55ba5a8c9871dcdaf756172558d093384cd2f4d0fe89d37f1266407e2bea784d18e429eeab5fde0a304b63bce97c73ba9391e7556 WHIRLPOOL b997021897aa68816d370867c241a59ba19f59e30943adc62cec6c9da2442101fa5b83c0cfd72faa38658111e12e2dbfd1664d64293488febdb72ee556f37dd7 +EBUILD ibam-0.5.2-r3.ebuild 1141 SHA256 f96cb6d937cfb9333c339e02e12e0f13ddce95b0c93b3cdb8239a1257a82ce80 SHA512 d77950a8d21151dc20a81168516b2f3b58d21dc96ea97563f3f413969c80d5d8f3bd27c3e6e93f4d1f091ec54d9668ce4081f8958bc340d5aafb05cd7939aeb8 WHIRLPOOL 850941ffdea641c58c71530a7e3395dba2f18dfe0ff5f56319f0ba7b4a0aa20eb369dbc264eebdc0316b2558504f32d1caef63fb4b71183a120da18b4b790772 +MISC ChangeLog 2552 SHA256 dac4bc5d2feb1acf58d597294c05963c59902b2a2bb9f2deb448829e3e687429 SHA512 f22b12959fa11b86ee9f038980cc7265af703f8b660819ad03802d1711e1fbdc7de7d2521b4b1f1335a49e291b5d9177808464d024940f5b87cd50b9f2877496 WHIRLPOOL 6798c9ebba1ac7c6e32d57d88c295dd27a96e9037511dc81a2e6ae9c6a69c53597142b2625b8c7e2ee5b8380e4215bafe594e9799077f8eafc98d119dc3310f6 +MISC ChangeLog-2015 2242 SHA256 5afe00cb69b1439c9a6146f406215a37b13a481c7deb7e5d9e748d9c250a10f4 SHA512 7fbaa5dd8b455a52479c88f3dec5bc3bbacc474be56061d3eda8da1dc1fd8e16b5a81038a60c4f243983a90f7f955df8272b3a1f0de649f924ad7987584c2bbb WHIRLPOOL 06a453f191bad6d83bede764464698d183714649f07ccd2f234797f6ae824ca2f724e69379d6f930c18ec8bf7fda197948dee85aa595767231809425a4f86553 +MISC metadata.xml 330 SHA256 c839422aea86d666443e1a0d2a6aaa30406e29746e9652e9d9e21f8d7ca32c77 SHA512 bc1e4eee7bc08f8e90b37ca0401fd7ad68645a6c50d22d22816ea944c50e47b1b00bc7da95eea38bd0e77f7c1c8baaea0a63c26cfbc9b6941a96612f145a9059 WHIRLPOOL 8b37525b361d25accbaadddda62d1a4964b8f680a34eb9953ee1b5adbb0a03ed769b0a17720da5bcb3994df6593ff30fa842675ba1281c5d2c49956cf98c3251 diff --git a/app-laptop/ibam/files/ibam-0.5.2-build.patch b/app-laptop/ibam/files/ibam-0.5.2-build.patch new file mode 100644 index 000000000000..77854b5f3d5a --- /dev/null +++ b/app-laptop/ibam/files/ibam-0.5.2-build.patch @@ -0,0 +1,42 @@ +--- Makefile ++++ Makefile +@@ -17,8 +17,8 @@ + # + IBAM_VERSION=0.5.2 + +-CC=g++ +-CFLAGS=-O3 -DIBAM_VERSION=\"$(IBAM_VERSION)\" -Wall ++CXX?=g++ ++CXXFLAGS+=-DIBAM_VERSION=\"$(IBAM_VERSION)\" -Wall + + PREFIX=/usr + +@@ -30,23 +30,23 @@ + all: ibam + + ibam: ibam.cpp ibam.inl ibam.hpp +- $(CC) $(CFLAGS) ibam.cpp -o ibam ++ $(CXX) $(LDFLAGS) $(CXXFLAGS) ibam.cpp -o ibam + + krell: ibam-krell.so + + ibam-krell.so: ibam-krell.o +- $(CC) $(CFLAGS) -fPIC -shared -Wl -o ibam-krell.so ibam-krell.o ++ $(CXX) $(LDFLAGS) $(CXXFLAGS) -fPIC -shared -Wl -o ibam-krell.so ibam-krell.o + + ibam-krell.o: ibam-krell.cpp ibam.hpp ibam.inl +- $(CC) $(CFLAGS) -fPIC `pkg-config gtk+-2.0 --cflags` `gdk-pixbuf-config --cflags` -c ibam-krell.cpp ++ $(CXX) $(CXXFLAGS) -fPIC `pkg-config gtk+-2.0 --cflags` `gdk-pixbuf-config --cflags` -c ibam-krell.cpp + + krell1: ibam-krell1.so + + ibam-krell1.so: ibam-krell1.o +- $(CC) $(CFLAGS) -shared -Wl -o ibam-krell1.so ibam-krell1.o ++ $(CXX) $(LDFLAGS) $(CXXFLAGS) -shared -Wl -o ibam-krell1.so ibam-krell1.o + + ibam-krell1.o: ibam-krell1.cpp ibam.hpp ibam.inl +- $(CC) $(CFLAGS) -fPIC `gtk-config --cflags` `imlib-config --cflags-gdk` -c ibam-krell1.cpp ++ $(CXX) $(CXXFLAGS) -fPIC `gtk-config --cflags` `imlib-config --cflags-gdk` -c ibam-krell1.cpp + + install: ibam + $(INSTALL) ./ibam $(PREFIX)/local/bin/ diff --git a/app-laptop/ibam/ibam-0.5.2-r3.ebuild b/app-laptop/ibam/ibam-0.5.2-r3.ebuild new file mode 100644 index 000000000000..2cd5cf10f92e --- /dev/null +++ b/app-laptop/ibam/ibam-0.5.2-r3.ebuild @@ -0,0 +1,62 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=4 + +PATCH_LEVEL=2 + +inherit eutils multilib toolchain-funcs + +DESCRIPTION="Intelligent Battery Monitor" +HOMEPAGE="http://ibam.sourceforge.net/" +SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz + mirror://debian/pool/main/${PN:0:1}/${PN}/${PN}_${PV}-${PATCH_LEVEL}.diff.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="gkrellm" + +RDEPEND=" + gkrellm? ( + app-admin/gkrellm + x11-libs/gdk-pixbuf + x11-libs/gtk+:2 + )" +DEPEND=" + ${RDEPEND} + gkrellm? ( virtual/pkgconfig )" + +src_prepare() { + epatch \ + "${FILESDIR}"/${P}-build.patch \ + "${WORKDIR}"/${PN}_${PV}-${PATCH_LEVEL}.diff + + local f + for f in $(find . -name '*.dpatch'); do + epatch "${f}" + done +} + +src_compile() { + tc-export CXX + emake + use gkrellm && emake krell +} + +src_install() { + dobin ibam + dodoc CHANGES README REPORT + + if use gkrellm; then + insinto /usr/$(get_libdir)/gkrellm2/plugins + doins ibam-krell.so + fi +} + +pkg_postinst() { + elog + elog "You will need to install sci-visualization/gnuplot if you wish to use" + elog "the --plot argument to ibam." + elog +} diff --git a/app-laptop/ibam/metadata.xml b/app-laptop/ibam/metadata.xml new file mode 100644 index 000000000000..af7ac1137229 --- /dev/null +++ b/app-laptop/ibam/metadata.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <!-- maintainer-needed --> + <use> + <flag name="gkrellm">Enable building of app-admin/gkrellm module</flag> + </use> + <upstream> + <remote-id type="sourceforge">ibam</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/laptop-mode-tools/Manifest b/app-laptop/laptop-mode-tools/Manifest new file mode 100644 index 000000000000..6a8810d0520f --- /dev/null +++ b/app-laptop/laptop-mode-tools/Manifest @@ -0,0 +1,8 @@ +AUX laptop_mode.init-1.4 1059 SHA256 6bb07bd94b50ad559c3cd23b57dbb928ff0449d356d973ba281baa232435d9c6 SHA512 4242cda1df6b55cd0bee66dfb9137b6f63118bc31c5f703ed44c42738f47dc794d7f1ed6dd9ba5696b606c4bf624428e8f21e1683cb698d8dda249833a4c5f68 WHIRLPOOL 60044854fbf2d9e9a972e73d4d527444b463f194c0e01f5d6a561111fc3f35b44a69430625238e53b228b575a89f202171a3bf950020c59a444dabe2fefba8e3 +DIST laptop-mode-tools_1.70.tar.gz 116624 SHA256 12cde7dbec8c35201efab96187be75ec84e0a2424494852413f21be1b7bc6a11 SHA512 755e2d94b63bb2a6e5362365f11181374c5fe159b508076f5def91c4df93983fa3e2553bbd94ae0b5bb4690aa7fb0881eafe3f4dcc7c8e77a8b72de23f6a21c5 WHIRLPOOL a70b0e3353877ffedd87ed3f72f1239addd34e8fecfd0e54b98c328a1f4a48a87a2f278fa4afa227452eb5f874bd58912a1ddf8ae2f385636c6bb3a552ce7b3a +DIST laptop-mode-tools_1.71.tar.gz 118833 SHA256 3aa122f876ef191e2501f550363724e30d20646637cff0de7147124c867166f9 SHA512 67ef4ed4c80f3a64ab9f0f9003d415f9e8759fd0ee1c7a82837d423a0e7aeb03ab95724afd89ae223f954ae0baec5830c8fa600bd6e2e351aead83a656f9b665 WHIRLPOOL 9c26c546f75f45b46b9b9e34a5ac435f58952e4d70b8db02c86170b4026b00112fb4044e41130dbc4f74326e22b39e0b78eeee2ba935179150441e9b5d41c884 +EBUILD laptop-mode-tools-1.70.ebuild 2623 SHA256 aac444cbde8d16e3913f3a3bc60cd37a5354c557ae24cc24f27fa47a1c43da3c SHA512 78188704549597533ceb667af7cf2970846020a0f2e1bc4a5133063a4e7a7d6774b03628d9d35917235716ba90b3b0f565e6043195b08b1c0da8409d4dae3ea4 WHIRLPOOL d0d33392d8475db04274e96f133d0a54c8bfa9c2fda48b96334c5fe8eb24593d067cfcdc0ecad3140d1d272038dae6dbc2cbcb2b5607122b38ee1ccc54de3bd3 +EBUILD laptop-mode-tools-1.71.ebuild 2625 SHA256 78d4ed7f6cc957db81c1b1e9e90070e0e23d9dd7281dcf56aa70782f86509b9f SHA512 9013e470da4dac9c1999f26b8db077ebff84ede3e9c47e44955a6b70b643749b438985ccaa178209d163b76971076c0c3662c2ce438493f88d766f2ff45e873c WHIRLPOOL acfc41703555fc13a9e62a71854e41d292c601385cf4e5803d5a70e2838f22b831db7a090d9e31adf12643415af32752ea5d46726c442868dc92e28e0b82745c +MISC ChangeLog 4267 SHA256 31664ca1d19caa8611bbd78d2516ca7549e3060629d6ae54670bd5d88e08df67 SHA512 60e04444b3ed47353fc5ac9c609169bf092859a1ca7546fe622fb5f9366299922adcf94ba58a6e578840a6cedb6e6fab84527d0a63b28fe4c2608201b8a58017 WHIRLPOOL cd20166e391b9626022c91df8c4e621ecb32396fcd876689b5308da830256f3f5e551817773810631485a56dfa243981a46c755c1601855702b911aa41567641 +MISC ChangeLog-2015 20290 SHA256 4374d8d676d332d3d936c1458572438e8ec440d8d71f56870cd7d70c89de9e91 SHA512 61c4a0421786bcc17d4a3dc695eb7b043a6eb6b50eaedcd2972129f41a1bab6e89a5e0208408299d736de8bef3ce7aca4cecd1be1b7ccd3a737f38674a03e842 WHIRLPOOL 9f0b7344e6316c53cef43364e4eec170306ef40b0704726d54bb87e8a2e92c2b8c8a854e103c4918b9f5f4981d038dab546de2c2174085f7e9d3030b62fedc3c +MISC metadata.xml 537 SHA256 2bf80794bbc877b42a3c8e45834d3dd92713eba9464855e1a3b93010ac9db725 SHA512 7231612300dd7c106a48422f444edf3208807653e9f55675008c693f7d053e7f6e8f3ea3df2642f221c34509a70d1adf59db14163466f18fd3a6fc714b45bd4e WHIRLPOOL fcb248d2d55f374212084c652892bb3a2a4939ede51cc5063056467208118aef83a0de774a55a5410cd5ba49a215c287c3c66624f40e462a3e2f83ecb1d57615 diff --git a/app-laptop/laptop-mode-tools/files/laptop_mode.init-1.4 b/app-laptop/laptop-mode-tools/files/laptop_mode.init-1.4 new file mode 100644 index 000000000000..eef819913cc6 --- /dev/null +++ b/app-laptop/laptop-mode-tools/files/laptop_mode.init-1.4 @@ -0,0 +1,52 @@ +#!/sbin/openrc-run +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +extra_started_commands="reload" + +depend() { + need localmount + use acpid hald + after bootmisc +} + +checkconfig() { + if [ ! -f /proc/sys/vm/laptop_mode ] ; then + eerror "Kernel does not support laptop_mode" + return 1 + fi +} + +start() { + checkconfig || return 1 + + ebegin "Starting laptop_mode" + # bug #342049 fix + # check if dir exists and creates if it doesn't + checkpath -q -d -m 755 /var/run/laptop-mode-tools + touch /var/run/laptop-mode-tools/enabled + /usr/sbin/laptop_mode auto >/dev/null + eend $? +} + +stop() { + ebegin "Stopping laptop_mode" + rm -f /var/run/laptop-mode-tools/enabled + /usr/sbin/laptop_mode stop >/dev/null + eend $? +} + +reload() { + if ! service_started "${SVCNAME}" ; then + eerror "${SVCNAME} has not yet been started" + return 1 + fi + + ebegin "Reloading laptop_mode" + /usr/sbin/laptop_mode stop >/dev/null + rm -f /var/run/laptop-mode-tools/* + /usr/sbin/laptop_mode auto force >/dev/null + eend $? +} + +# vim: set ts=4 : diff --git a/app-laptop/laptop-mode-tools/laptop-mode-tools-1.70.ebuild b/app-laptop/laptop-mode-tools/laptop-mode-tools-1.70.ebuild new file mode 100644 index 000000000000..76f2e8092a24 --- /dev/null +++ b/app-laptop/laptop-mode-tools/laptop-mode-tools-1.70.ebuild @@ -0,0 +1,94 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit multilib systemd udev + +MY_P="${PN}_${PV}" + +DESCRIPTION="Linux kernel laptop_mode user-space utilities" +HOMEPAGE="https://github.com/rickysarraf/laptop-mode-tools/wiki" +SRC_URI="https://github.com/rickysarraf/${PN}/releases/download/${PV}/${MY_P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 ppc x86" +IUSE="+acpi apm bluetooth scsi" + +RDEPEND="net-wireless/wireless-tools + sys-apps/iproute2 + sys-apps/ethtool + sys-apps/hdparm + sys-apps/which + acpi? ( sys-power/acpid ) + apm? ( sys-apps/apmd ) + bluetooth? ( net-wireless/bluez:= ) + scsi? ( sys-apps/sdparm )" +DEPEND="" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + default + # This should avoid conflict with pm-powersave wrt #327443 and #396703 + cat <<-EOF > "${T}"/${PN} + HOOK_BLACKLIST="00powersave" + EOF +} + +src_compile() { :; } + +src_install() { + DESTDIR="${D}" \ + INIT_D="none" \ + MAN_D="/usr/share/man" \ + LIB_D="/usr/$(get_libdir)" \ + UDEV_D="$(get_udevdir)" \ + SYSTEMD_UNIT_D="$(systemd_get_systemunitdir)" \ + TMPFILES_D="/usr/lib/tmpfiles.d" \ + ACPI="$(use acpi && echo force || echo disabled)" \ + PMU="$(false && echo force || echo disabled)" \ + APM="$(use apm && echo force || echo disabled)" \ + SYSTEMD=yes \ + sh ./install.sh || die + + dodoc Documentation/*.txt README.md + newinitd "${FILESDIR}"/laptop_mode.init-1.4 laptop_mode + + # See src_prepare() + insinto /etc/pm/config.d + doins "${T}"/${PN} +} + +pkg_postinst() { + if use acpi || use apm; then + if use acpi; then + daemon_name="acpid" + elif use apm; then + deamon_name="apmd" + fi + if [ "$(rc-config list default | grep laptop_mode)" = "" ] || [ "$(rc-config list default | grep ${daemon_name} )" = "" ]; then + ewarn "To enable automatic power state event handling," + ewarn "e.g. enabling laptop_mode after unplugging the battery," + ewarn "both laptop_mode and the ${daemon_name} daemon must be" + ewarn "added to default runlevel:" + if [ "$(rc-config list default | grep laptop_mode)" = "" ]; then + ewarn "# rc-update add laptop_mode default" + fi + if [ "$(rc-config list default | grep ${daemon_name} )" = "" ]; then + ewarn "# rc-update add ${daemon_name} default" + fi + fi + else + ewarn "Without USE=\"acpi\" or USE=\"apm\" ${PN} can not" + ewarn "automatically disable laptop_mode on low battery." + ewarn + ewarn "This means you can lose up to 10 minutes of work if running" + ewarn "out of battery while laptop_mode is enabled." + ewarn + ewarn "Please see laptop-mode.txt in /usr/share/doc/${PF} for further" + ewarn "information." + ewarn + fi +} diff --git a/app-laptop/laptop-mode-tools/laptop-mode-tools-1.71.ebuild b/app-laptop/laptop-mode-tools/laptop-mode-tools-1.71.ebuild new file mode 100644 index 000000000000..2837bf0d93bb --- /dev/null +++ b/app-laptop/laptop-mode-tools/laptop-mode-tools-1.71.ebuild @@ -0,0 +1,94 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit multilib systemd udev + +MY_P="${PN}_${PV}" + +DESCRIPTION="Linux kernel laptop_mode user-space utilities" +HOMEPAGE="https://github.com/rickysarraf/laptop-mode-tools/wiki" +SRC_URI="https://github.com/rickysarraf/${PN}/releases/download/${PV}/${MY_P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 ~ppc ~x86" +IUSE="+acpi apm bluetooth scsi" + +RDEPEND="net-wireless/wireless-tools + sys-apps/iproute2 + sys-apps/ethtool + sys-apps/hdparm + sys-apps/which + acpi? ( sys-power/acpid ) + apm? ( sys-apps/apmd ) + bluetooth? ( net-wireless/bluez:= ) + scsi? ( sys-apps/sdparm )" +DEPEND="" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + default + # This should avoid conflict with pm-powersave wrt #327443 and #396703 + cat <<-EOF > "${T}"/${PN} + HOOK_BLACKLIST="00powersave" + EOF +} + +src_compile() { :; } + +src_install() { + DESTDIR="${D}" \ + INIT_D="none" \ + MAN_D="/usr/share/man" \ + LIB_D="/usr/$(get_libdir)" \ + UDEV_D="$(get_udevdir)" \ + SYSTEMD_UNIT_D="$(systemd_get_systemunitdir)" \ + TMPFILES_D="/usr/lib/tmpfiles.d" \ + ACPI="$(use acpi && echo force || echo disabled)" \ + PMU="$(false && echo force || echo disabled)" \ + APM="$(use apm && echo force || echo disabled)" \ + SYSTEMD=yes \ + sh ./install.sh || die + + dodoc Documentation/*.txt README.md + newinitd "${FILESDIR}"/laptop_mode.init-1.4 laptop_mode + + # See src_prepare() + insinto /etc/pm/config.d + doins "${T}"/${PN} +} + +pkg_postinst() { + if use acpi || use apm; then + if use acpi; then + daemon_name="acpid" + elif use apm; then + deamon_name="apmd" + fi + if [ "$(rc-config list default | grep laptop_mode)" = "" ] || [ "$(rc-config list default | grep ${daemon_name} )" = "" ]; then + ewarn "To enable automatic power state event handling," + ewarn "e.g. enabling laptop_mode after unplugging the battery," + ewarn "both laptop_mode and the ${daemon_name} daemon must be" + ewarn "added to default runlevel:" + if [ "$(rc-config list default | grep laptop_mode)" = "" ]; then + ewarn "# rc-update add laptop_mode default" + fi + if [ "$(rc-config list default | grep ${daemon_name} )" = "" ]; then + ewarn "# rc-update add ${daemon_name} default" + fi + fi + else + ewarn "Without USE=\"acpi\" or USE=\"apm\" ${PN} can not" + ewarn "automatically disable laptop_mode on low battery." + ewarn + ewarn "This means you can lose up to 10 minutes of work if running" + ewarn "out of battery while laptop_mode is enabled." + ewarn + ewarn "Please see laptop-mode.txt in /usr/share/doc/${PF} for further" + ewarn "information." + ewarn + fi +} diff --git a/app-laptop/laptop-mode-tools/metadata.xml b/app-laptop/laptop-mode-tools/metadata.xml new file mode 100644 index 000000000000..6301d44bddec --- /dev/null +++ b/app-laptop/laptop-mode-tools/metadata.xml @@ -0,0 +1,17 @@ +<?xml version='1.0' encoding='UTF-8'?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>alonbl@gentoo.org</email> + </maintainer> + <upstream> + <maintainer status="active"> + <email>gentoo-lmt@researchut.com</email> + <name>Ritesh Raj Sarraf</name> + </maintainer> + <remote-id type="github">rickysarraf/laptop-mode-tools</remote-id> + </upstream> + <use> + <flag name="scsi">Adds dependency on sdparm to control non-SATA SCSI drivers</flag> + </use> +</pkgmetadata> diff --git a/app-laptop/lphdisk/Manifest b/app-laptop/lphdisk/Manifest new file mode 100644 index 000000000000..05a5b3749c0c --- /dev/null +++ b/app-laptop/lphdisk/Manifest @@ -0,0 +1,6 @@ +AUX lphdisk-0.9.1-gentoo.patch 8029 SHA256 345302ed64ee7f1c56928968f512d11095bf89963a8220febb36988814c0afea SHA512 13617d95617e0a89a0f76a992247d2b9c4db104e8a409b0f23e51867789969f375596b082f75ad4c0a15dcef0ae809bf7938c5c150441c3165d1f1a612c17d81 WHIRLPOOL e06009849f389adf259016922b1f31947ddd61ab6e4846f2ec48ef54e1c8a608f68a1b7d2b80eb2e6375de154f5cdd3f05f5d9f41468c07e88da70f8da1d9430 +DIST lphdisk-0.9.1.tar.bz2 26343 SHA256 42a6df491db3bd581fad5bfd2af09008cd604d7767a7f3984c1a77f69d571249 SHA512 28bd93acd854e79009722e83f063c3704333ae97d7fadff194101f24bd9fdc81c98464a3c0e7bbaf6097a56bed19fc7798e108ec7872cc85f3e327fbfb942521 WHIRLPOOL d68cc00c76d2c7dab8178d99734fd299207270a37fe5674850f64a16bae069cc907e6164c75acdd2253ff6cc92ec38d555d7ebabd66898e2551bfeacec8b5883 +EBUILD lphdisk-0.9.1-r2.ebuild 576 SHA256 1bf4b3e434c8dd42ed577db033cf2f85b56cc0ce22d0e78cecca8e45e4dedb3f SHA512 1d7aa55d29399ea715e46e43990fd8917ec69da752dfcf2e47c3deee02e2f57dd6caf3e2a301bd16fc627f2540672a528db12aa4fd7410acba818339eeafab7f WHIRLPOOL db45760276ff35324be696c6007d03407f5ba718269de9c4bc59d15fedf1aa243e0917bf8407d1825adc215ce1254d8465ccc80be61760096d7af3d293a6850f +MISC ChangeLog 2565 SHA256 955a3b8e8fbaf0123cb1f733901cbbcb8e8c7b639be00ee865929fa574818db7 SHA512 44cabe84193517a12d0525ae4a9a95e3072c4dcf56c6e07dc86b8ea661dbcc72eac529cef5f176f3eb74c2d6d28ab3d90fb469753462d026e6c62dab0dc30a75 WHIRLPOOL 8937b779d4efac40be8f31c4bfdf0d2c71efd1f0a55d1da7e46f71cfd366df5b3333c0cf250885c88ce349bc539b25dfd7bbc07ad4e62aa33aca13e2c469f892 +MISC ChangeLog-2015 2106 SHA256 8ed7c68ff5ef88987350a5723a09959446ce77bc6f29658676611a021a6300d0 SHA512 ca8cdf444a326378f12d76c5882232af6d59e21f9f64ec5ef9da81eb6b306426297ed634e82380205bda85732c44ecc99fd355817bd792d4af2b8dfd95820b10 WHIRLPOOL 47c3d5dd4acc796dd2a51ee5190bf1315d68a9d40b6a843dc40f5daa1484107188a21fe38be8c84a037f4d411741936a55837acd026e0ecc7e389be5cc96ee26 +MISC metadata.xml 166 SHA256 2caff447f5bd2701d8456ada5cc633c41ef4373fa4bfeabeb73599d40bcc941b SHA512 a56648c974a1d14dd4c18237532773c72057a13ab90c58b5da04f185e3c12a8bd8d5c21fb06053507f31766291a82dc7d87b34cd65fd94cfe2af7295c813ef84 WHIRLPOOL 1ff70497eca6531f0e0614c72a19f4b8e5ff486a58d369f4f0b36308d1d6b01168f9da887740e3b9f536236be251d3fe05f904d27a9233a7cf613416ba882968 diff --git a/app-laptop/lphdisk/files/lphdisk-0.9.1-gentoo.patch b/app-laptop/lphdisk/files/lphdisk-0.9.1-gentoo.patch new file mode 100644 index 000000000000..73e1b5a715f4 --- /dev/null +++ b/app-laptop/lphdisk/files/lphdisk-0.9.1-gentoo.patch @@ -0,0 +1,252 @@ +diff -ur lphdisk-0.9.1.orig/lphdisk.c lphdisk-0.9.1/lphdisk.c +--- lphdisk-0.9.1.orig/lphdisk.c 2002-02-12 13:04:27.000000000 +0200 ++++ lphdisk-0.9.1/lphdisk.c 2008-12-08 12:21:29.000000000 +0200 +@@ -19,8 +19,10 @@ + Be careful! + */ + ++#define _LARGEFILE64_SOURCE + #include <stdio.h> + #include <stdlib.h> ++#include <sys/types.h> + #include <unistd.h> + #include <string.h> + #include <stdarg.h> +@@ -29,8 +31,8 @@ + #include <fcntl.h> + #include <sys/stat.h> + #include <sys/io.h> +-#include "lrmi.h" +-#include "vbe.h" ++#include <lrmi.h> ++#include <vbe.h> + + /* General Program Defines: */ + +@@ -100,58 +102,6 @@ + /* General Purpose Utility Routines */ + /*****************************************************************************/ + +-/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +-/* The following is a hack to take advantage of the ext2 "_llseek" system */ +-/* call to do seeks to "long long" offsets under linux (this is needed to */ +-/* seek to sectors beyond 4194303 (2GB)). This isn't directly supported by */ +-/* glibc, so we need to make our own interface function for it. We should */ +-/* be able to get the _NR__llseek define from linux/unistd.h. From this we */ +-/* can construct a wrapper to perform the right system call. */ +- +-#include <linux/unistd.h> /* for __NR__llseek */ +- +-typedef long long lloff_t; +- +-#ifdef __NR__llseek +- +-static _syscall5(int,_llseek, unsigned int,fd, unsigned long,offset_high, +- unsigned long,offset_low, lloff_t *,result, +- unsigned int,origin) +- +-lloff_t llseek (unsigned int fd, lloff_t offset, unsigned int origin) { +- lloff_t result; +- int retval; +- +- retval = _llseek (fd, ((unsigned long long) offset) >> 32, +- ((unsigned long long) offset) & 0xffffffff, +- &result, origin); +- return (retval == -1 ? (lloff_t) retval : result); +-} +- +-#else /* __NR__llseek */ +- +-/* Somehow, __NR__llseek wasn't in linux/unistd.h. This shouldn't ever */ +-/* happen, but better safe than sorry.. The best we can do is emulate it */ +-/* with lseek, and hope we don't get an offset that's too large (throw an */ +-/* error if we do) */ +- +-lloff_t llseek (unsigned int fd, lloff_t offset, unsigned int origin) { +- off_t offt_offset = (off_t) offset; +- +- if ((lloff_t)offt_offset != offset) { +- /* converting to off_t and back yields different result, indicating an */ +- /* overflow.. */ +- errno = EINVAL; +- return -1; +- } else { +- return lseek(fd, offt_offset, origin); +- } +-} +- +-#endif /* __NR__llseek */ +- +-/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +- + #define get16(p) get_int_le(p,2) + #define get32(p) get_int_le(p,4) + +@@ -189,9 +139,9 @@ + /* success, nonzero on error. */ + + int seek_sector (int fd, size_t secno) { +- lloff_t offset = (lloff_t) secno * SECTOR_SIZE; ++ off64_t offset = (off64_t) secno * SECTOR_SIZE; + +- if (llseek(fd, offset, SEEK_SET) == (lloff_t) -1) ++ if (lseek64(fd, offset, SEEK_SET) == (off64_t) -1) + return -1; + + return 0; +@@ -556,25 +506,29 @@ + + int meminfo_physmem(void) { + FILE *f; +- unsigned int size; ++ unsigned int size = 0; + int ramsize; ++ char s[128]; + + if (!(f = fopen(meminfo_filename, "r"))) { + debug("Unable to open %s: %s\n", meminfo_filename, strerror(errno)); + return 0; + } +- fscanf(f, "%*[^\n]\n"); /* Read the header line and discard it */ + +- if (fscanf(f, "Mem: %u", &size) != 1) { ++ while (fgets(s, sizeof(s), f)) { ++ if (sscanf(s, "MemTotal: %u", &size) == 1) { ++ break; ++ } ++ } ++ if (size == 0) { + debug("Parse of %s failed.\n", meminfo_filename); + return 0; + } + fclose(f); + +- /* convert to KB and then round up to the next power of 2 (since RAM */ ++ /* size is in KB and then round up to the next power of 2 (since RAM */ + /* sizes don't come in anything else, so this should correct for the */ + /* kernel size, etc) */ +- size >>= 10; + debug("%s reports memory size of %d KB", meminfo_filename, size); + for (ramsize = 1; size; size >>= 1) ramsize <<= 1; + +@@ -718,22 +672,22 @@ + {"force", 0, 0, 'f'}, + {0,0,0,0}}; + +-const char usage_string[] = "\ +-Usage: %1$s [options] [device] +-Prepare a hibernation partition for APM suspend-to-disk. +- +-options: +- -h, --help Display brief usage and option information (this screen) +- -p, --probeonly Only calculate and display required size, do not format +- -q, --quiet Turn off informational messages, useful for scripts +- -d, --debug Turn on (verbose) debugging messages +- -n, --nowrite Do not actually write to the disk +- -f, --force **DANGEROUS** Format without regard to potential problems +- +-'device' should be a raw disk device (not a partition). The default device +-is /dev/hda. +- +-(%2$s)\n\n"; ++const char usage_string[] = "" ++"Usage: %1$s [options] [device]\n" ++"Prepare a hibernation partition for APM suspend-to-disk.\n" ++"\n" ++"options:\n" ++" -h, --help Display brief usage and option information (this screen)\n" ++" -p, --probeonly Only calculate and display required size, do not format\n" ++" -q, --quiet Turn off informational messages, useful for scripts\n" ++" -d, --debug Turn on (verbose) debugging messages\n" ++" -n, --nowrite Do not actually write to the disk\n" ++" -f, --force **DANGEROUS** Format without regard to potential problems\n" ++"\n" ++"'device' should be a raw disk device (not a partition). The default device\n" ++"is /dev/hda.\n" ++"\n" ++"(%2$s)\n\n"; + + void print_usage (void) { + char *progname = rindex(argv0, '/'); +@@ -750,7 +704,7 @@ + dev_t dev; + int partition; + int ramsize, vramsize, required_size; +- size_t required_sectors; ++ size_t required_sectors = 0; + + argv0 = argv[0]; + +@@ -821,9 +775,9 @@ + } + + if (!required_size) { +- if (!quiet_flag) printf("Reccomended partition size is unknown.\n"); ++ if (!quiet_flag) printf("Recommended partition size is unknown.\n"); + } else { +- if (!quiet_flag) printf("Reccomended partition size is %d MB" ++ if (!quiet_flag) printf("Recommended partition size is %d MB" + " (%d sectors)\n", ((required_size+1023) >> 10), + required_sectors); + } +@@ -923,7 +877,7 @@ + + if ((pi[partition-1].size < required_sectors) && !quiet_flag) { + fprintf(stderr, "Warning: hibernate partition size (%d) is smaller than" +- " reccomended size (%d).\n", pi[partition-1].size, ++ " recommended size (%d).\n", pi[partition-1].size, + required_sectors); + } + +diff -ur lphdisk-0.9.1.orig/Makefile lphdisk-0.9.1/Makefile +--- lphdisk-0.9.1.orig/Makefile 2002-02-12 11:06:46.000000000 +0200 ++++ lphdisk-0.9.1/Makefile 2008-12-08 12:26:49.000000000 +0200 +@@ -4,37 +4,28 @@ + # lphdisk 0.9.1 + # + +-INSTALL_PREFIX = /usr/local ++INSTALL_PREFIX = /usr + +-CFLAGS = -g -Wall +-LIBS = +- +-LRMIDIR = lrmi-0.6m ++CFLAGS += -Wall ++LIBS = -llrmi + + all: lphdisk + +-lphdisk: lphdisk.o lrmi.o +- $(CC) $(CFLAGS) -o lphdisk lphdisk.o lrmi.o $(LIBS) +- +-lphdisk.o: lphdisk.c lrmi.h vbe.h +- +-lrmi.o: +- cd $(LRMIDIR) && $(MAKE) $@ +- cp $(LRMIDIR)/lrmi.o . ++lphdisk: lphdisk.o ++ $(CC) $(LDFLAGS) $(CFLAGS) -o lphdisk lphdisk.o $(LIBS) + +-%.h: $(LRMIDIR)/%.h +- cp $^ $@ ++lphdisk.o: lphdisk.c + + install: all +- install -m 755 lphdisk $(INSTALL_PREFIX)/sbin +- install -m 644 lphdisk.8 $(INSTALL_PREFIX)/man/man8 ++ mkdir -p $(DESTDIR)$(INSTALL_PREFIX)/sbin ++ install -m 755 lphdisk $(DESTDIR)$(INSTALL_PREFIX)/sbin ++ mkdir -p $(DESTDIR)$(INSTALL_PREFIX)/share/man/man8 ++ install -m 644 lphdisk.8 $(DESTDIR)$(INSTALL_PREFIX)/share/man/man8 + + clean: +- cd $(LRMIDIR) && $(MAKE) $@ +- rm -f *.o lrmi.h vbe.h ++ rm -f *.o + + distclean: clean +- cd $(LRMIDIR) && $(MAKE) $@ + rm -f lphdisk + + .PHONY: all install clean distclean diff --git a/app-laptop/lphdisk/lphdisk-0.9.1-r2.ebuild b/app-laptop/lphdisk/lphdisk-0.9.1-r2.ebuild new file mode 100644 index 000000000000..9139bb49d669 --- /dev/null +++ b/app-laptop/lphdisk/lphdisk-0.9.1-r2.ebuild @@ -0,0 +1,29 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=2 +inherit eutils toolchain-funcs + +DESCRIPTION="utility for preparing a hibernation partition for APM Suspend-To-Disk" +HOMEPAGE="http://www.procyon.com/~pda/lphdisk/" +SRC_URI="http://www.procyon.com/~pda/lphdisk/${P}.tar.bz2" + +LICENSE="Artistic" +SLOT="0" +KEYWORDS="x86" +IUSE="" + +DEPEND="sys-libs/lrmi" + +src_prepare() { + epatch "${FILESDIR}"/${P}-gentoo.patch +} + +src_compile() { + tc-export CC + emake || die +} + +src_install() { + emake DESTDIR="${D}" install || die +} diff --git a/app-laptop/lphdisk/metadata.xml b/app-laptop/lphdisk/metadata.xml new file mode 100644 index 000000000000..6f49eba8f496 --- /dev/null +++ b/app-laptop/lphdisk/metadata.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<!-- maintainer-needed --> +</pkgmetadata> diff --git a/app-laptop/mbpfan/Manifest b/app-laptop/mbpfan/Manifest new file mode 100644 index 000000000000..2498323ad37e --- /dev/null +++ b/app-laptop/mbpfan/Manifest @@ -0,0 +1,9 @@ +DIST mbpfan-1.9.1.tar.gz 24393 SHA256 a7cf850a393ebfce21427b992436b84cc4b20e1cb8d673d45d2c8b991c69e68c SHA512 04f1f70697ccd182c329588623c6664979e1cc25db8a39a2ea9f6d1ec49f3914172c3ada392fabc9ac51a811f36087dc600426c34c201d02a5d7b791b04f0f3b WHIRLPOOL a97cc5eb8ebb25353e5fe7b86854daf52bfa99b6ad3a490ef3006fdd9162b8c96840692d1939071e4404438535e4f44f0a5b41cc5cb43b115046fe4b3fd89a8a +DIST mbpfan-2.0.0.tar.gz 37912 SHA256 4e8874c7302b8d237faa8bf706acf5bf0ea8ec4ebff2debfc9717bca7d9ea15b SHA512 9a7f930afe0a151fe50bf3ef1a06a5cecaced0c47f7088a83b91e25dff85d4b0d53494eac5eb1b624bde6ff1d3307a0d9fe6ba392fdacbe58e241d93d11cda6d WHIRLPOOL 051406f3dafc0aecfc0d1afac1e10d9f2a0d9b2a8ddde12282b767b007e1211b88f8e5d48f03d7b46bd5e6b0a9d17088c7011364d16f0b3f09bbafd1bbe552c9 +DIST mbpfan-2.0.1.tar.gz 37805 SHA256 72bc27fc3dfb4c01c1c476ae74084fc66c7a1039057a7c73441606981adfa311 SHA512 8fd2e37b9b81720ff7efa490d285da5980ef5dcc858fef4b0c24166a8f0df46aa230ea18fca5775b222271918e5ca6df1bfbbdced068182c20eeb86192ed2019 WHIRLPOOL dd7c98f7cf6fe84d40c4c070d3daa1640641c971659632bd3778eed24b319f30aa308728b8ee1026a03d8a6f8f9de01eabd8182727263da10779cc097e68cbcc +EBUILD mbpfan-1.9.1.ebuild 766 SHA256 20826403d2d3d7fddfceab00577e428236c10ddc72a6bd0f7822b764206b6270 SHA512 e805289f5db3b918a975028a2d16e3eef35f48ccb3db18c9f3cc12b51b4871e5420f8d90c2729e90b6b607a12aac95e88b45ed7ebf3de2e6c2818e7383d2c18b WHIRLPOOL 1696c23e14b0ddd38fcb7a46b1c2893eda2a370ca78b07e662620ced4e0e2b82c45a06022e8bc6c808ee844ad7b0a468e8fe4807fcbd0fd3993521e9901fdba2 +EBUILD mbpfan-2.0.0.ebuild 1239 SHA256 ba8668272f488836037f25595ed582ced6635377927ef335708e8d3064aa55c3 SHA512 84a5ff0e5f7bd141a13177760baf22d6e5c0f156aff187600b9b1c803d6616d6d9528c61303b40792d59b9a8f905c2d214b2e568b62c7da120b8e3b86cd298bb WHIRLPOOL 196f264a0abd38d15f6de3ebd8dd60f61d7650a6a17c3715d68175c5403a67c28e5336fdaaee1e3b8666c4a590e88f2694c6fafd83e4c71138a97f0b0fc54d6f +EBUILD mbpfan-2.0.1.ebuild 1175 SHA256 7053601f4ff2e3f6cc97dbf3cd5fdf82e1154918b9ee28949766054666946b63 SHA512 82368d46789134ec2b7c86d671096c9a5e64db7956075dd599b858400d069a2ca07db94b41c89152493b577409aa5f458abd5caf502df472ac4c82a6fc6514a9 WHIRLPOOL 7f138d2ab8e27b928a6aee1e10fe3c22f5ec4a3f625c4ed525d9936a0404a2b0a534fe8eb1cd034e7a878b87b4a82ffb8eadb543ae983920252e9c25d99ef62b +EBUILD mbpfan-9999.ebuild 1175 SHA256 7053601f4ff2e3f6cc97dbf3cd5fdf82e1154918b9ee28949766054666946b63 SHA512 82368d46789134ec2b7c86d671096c9a5e64db7956075dd599b858400d069a2ca07db94b41c89152493b577409aa5f458abd5caf502df472ac4c82a6fc6514a9 WHIRLPOOL 7f138d2ab8e27b928a6aee1e10fe3c22f5ec4a3f625c4ed525d9936a0404a2b0a534fe8eb1cd034e7a878b87b4a82ffb8eadb543ae983920252e9c25d99ef62b +MISC ChangeLog 566 SHA256 49a7587368e59ed39b40535f86b8c1c6c5da09307d12b940df6796f3d4cfd980 SHA512 01901815f097981fa26d6cf77a456decaead48c738df6a4c871aa298b6a2b8230a005b2b57a1e78a438b89d8a71f10274319261ab1e4bf842bdc6913b744232a WHIRLPOOL 21dd2b1fef797f6bb0411c58d57df3b4bdbf41d5a47c742fa29fcd12bec97d9b702d0a632cb19a018077e4e6cb6c8182d7cb83bfa418490af9eebd188ef767de +MISC metadata.xml 689 SHA256 3c89e11296987ff47694b78b21853707501dc5433a24c47702451706e9310afc SHA512 8edd05f68f3781e684706e61cc28a1d8d5877746c7022ed5a247bb5e686de7f75cbcca2253962b51ccfc06d47445d553399e90b465a9ae466d45cd47d7d05c36 WHIRLPOOL a40bc0c8def8d2f58d8c7522cd8f222469407bac5586f05ea503e9c8dd2a2ca0e3346c2e3237b97847bdb05b330467ae0bb69565add2fc73adf424bacc76e6fc diff --git a/app-laptop/mbpfan/mbpfan-1.9.1.ebuild b/app-laptop/mbpfan/mbpfan-1.9.1.ebuild new file mode 100644 index 000000000000..58ae75eb0cb0 --- /dev/null +++ b/app-laptop/mbpfan/mbpfan-1.9.1.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit linux-info systemd toolchain-funcs + +DESCRIPTION="A simple daemon to control fan speed on all Macbook/Macbook Pros" +HOMEPAGE="https://github.com/dgraziotin/mbpfan" +SRC_URI="https://github.com/dgraziotin/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" +LICENSE="GPL-3+" +SLOT="0" +KEYWORDS="~amd64" +RESTRICT="test" # will fail if the hardware is unavailable, not useful + +CONFIG_CHECK="~SENSORS_APPLESMC ~SENSORS_CORETEMP" + +src_prepare() { + sed -i -e "s:g++:$(tc-getCXX):g" Makefile || die + default +} + +src_install() { + dosbin bin/mbpfan + + insinto /etc + doins ${PN}.conf + + newinitd ${PN}.init.gentoo ${PN} + systemd_dounit ${PN}.service + + einstalldocs +} diff --git a/app-laptop/mbpfan/mbpfan-2.0.0.ebuild b/app-laptop/mbpfan/mbpfan-2.0.0.ebuild new file mode 100644 index 000000000000..fb1fc7c3f9dc --- /dev/null +++ b/app-laptop/mbpfan/mbpfan-2.0.0.ebuild @@ -0,0 +1,45 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit linux-info systemd toolchain-funcs + +DESCRIPTION="A simple daemon to control fan speed on all Macbook/Macbook Pros" +HOMEPAGE="https://github.com/dgraziotin/mbpfan" +LICENSE="GPL-3+" +SLOT="0" +RESTRICT="test" # will fail if the hardware is unavailable, not useful + +if [[ "${PV}" = 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/dgraziotin/${PN}.git" + KEYWORDS="" +else + SRC_URI="https://github.com/dgraziotin/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi + +CONFIG_CHECK="~SENSORS_APPLESMC ~SENSORS_CORETEMP" + +src_compile() { + emake CC="$(tc-getCC)" +} + +src_install() { + # There's a double linking problem in install + emake DESTDIR="${ED}" CC="$(tc-getCC)" install + + # Remove the empty systemd unit directory + # It doesn't actually install the unit file + rmdir --ignore-fail-on-non-empty -p "${ED%/}/lib/systemd/system" || die + # Actually install the sytstemd unit file + systemd_dounit ${PN}.service + # Install openrc init file + newinitd ${PN}.init.gentoo ${PN} + + # make install doesn't install the docs in the right place + rm -rf "${ED%/}/usr/share/doc/${PN}" || die + + einstalldocs +} diff --git a/app-laptop/mbpfan/mbpfan-2.0.1.ebuild b/app-laptop/mbpfan/mbpfan-2.0.1.ebuild new file mode 100644 index 000000000000..357bf95cf287 --- /dev/null +++ b/app-laptop/mbpfan/mbpfan-2.0.1.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit linux-info systemd toolchain-funcs + +DESCRIPTION="A simple daemon to control fan speed on all Macbook/Macbook Pros" +HOMEPAGE="https://github.com/dgraziotin/mbpfan" +LICENSE="GPL-3+" +SLOT="0" +RESTRICT="test" # will fail if the hardware is unavailable, not useful + +if [[ "${PV}" = 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/dgraziotin/${PN}.git" + KEYWORDS="" +else + SRC_URI="https://github.com/dgraziotin/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi + +CONFIG_CHECK="~SENSORS_APPLESMC ~SENSORS_CORETEMP" + +src_compile() { + emake CC="$(tc-getCC)" +} + +src_install() { + emake DESTDIR="${ED}" install + + # Remove the empty systemd unit directory + # It doesn't actually install the unit file + rmdir --ignore-fail-on-non-empty -p "${ED%/}/lib/systemd/system" || die + # Actually install the sytstemd unit file + systemd_dounit ${PN}.service + # Install openrc init file + newinitd ${PN}.init.gentoo ${PN} + + # make install doesn't install the docs in the right place + rm -rf "${ED%/}/usr/share/doc/${PN}" || die + + einstalldocs +} diff --git a/app-laptop/mbpfan/mbpfan-9999.ebuild b/app-laptop/mbpfan/mbpfan-9999.ebuild new file mode 100644 index 000000000000..357bf95cf287 --- /dev/null +++ b/app-laptop/mbpfan/mbpfan-9999.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit linux-info systemd toolchain-funcs + +DESCRIPTION="A simple daemon to control fan speed on all Macbook/Macbook Pros" +HOMEPAGE="https://github.com/dgraziotin/mbpfan" +LICENSE="GPL-3+" +SLOT="0" +RESTRICT="test" # will fail if the hardware is unavailable, not useful + +if [[ "${PV}" = 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/dgraziotin/${PN}.git" + KEYWORDS="" +else + SRC_URI="https://github.com/dgraziotin/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi + +CONFIG_CHECK="~SENSORS_APPLESMC ~SENSORS_CORETEMP" + +src_compile() { + emake CC="$(tc-getCC)" +} + +src_install() { + emake DESTDIR="${ED}" install + + # Remove the empty systemd unit directory + # It doesn't actually install the unit file + rmdir --ignore-fail-on-non-empty -p "${ED%/}/lib/systemd/system" || die + # Actually install the sytstemd unit file + systemd_dounit ${PN}.service + # Install openrc init file + newinitd ${PN}.init.gentoo ${PN} + + # make install doesn't install the docs in the right place + rm -rf "${ED%/}/usr/share/doc/${PN}" || die + + einstalldocs +} diff --git a/app-laptop/mbpfan/metadata.xml b/app-laptop/mbpfan/metadata.xml new file mode 100644 index 000000000000..95aa53e5c65e --- /dev/null +++ b/app-laptop/mbpfan/metadata.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>gokturk@gentoo.org</email> + <name>Göktürk Yüksek</name> + </maintainer> + <longdescription> + mbpfan is a daemon that uses input from coretemp module and sets + the fan speed using the applesmc module. This is an enhanced + version of Allan McRae mbpfan. This enhanced version assumes any + number of processors and fans. + </longdescription> + <upstream> + <bugs-to>https://github.com/dgraziotin/mbpfan/issues</bugs-to> + <remote-id type="github">dgraziotin/mbpfan</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/metadata.xml b/app-laptop/metadata.xml new file mode 100644 index 000000000000..bee35931772d --- /dev/null +++ b/app-laptop/metadata.xml @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE catmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<catmetadata> + <longdescription lang="en"> + The app-laptop category contains packages which are designed to work + with certain kinds of laptop or notebook computer. + </longdescription> + <longdescription lang="de"> + Die Kategorie app-laptop enthält Pakete für das Arbeiten mit verschiedenen + Notebook- und Laptop-Modellen. + </longdescription> + <longdescription lang="es"> + La categoría app-laptop contiene paquetes diseñados para trabajar + con ciertas clases de laptops ó computadoras portátiles. + </longdescription> + <longdescription lang="ja"> + app-laptopカテゴリには様々なラップトップとノートブックコンピュータで + 使うパッケージが含まれます。 + </longdescription> + <longdescription lang="nl"> + De app-laptop categorie bevat applicaties voor laptopgebruikers. + </longdescription> + <longdescription lang="vi"> + Nhóm app-laptop chứa các gói danh cho các loại máy + tính laptop và notebook. + </longdescription> + <longdescription lang="it"> + La categoria app-laptop contiene pacchetti progettaati per lavorare con alcuni + tipi di laptop o notebook. + </longdescription> + <longdescription lang="pt"> + A categoria app-laptop contém pacotes que são desenhados para + trabalhar com certos tipos de laptops e notebooks. + </longdescription> + <longdescription lang="pl"> + Kategoria app-laptop zawiera pakiety ściśle związane z pracą na + laptopach i notebookach. + </longdescription> +</catmetadata> + diff --git a/app-laptop/nvidiabl/Manifest b/app-laptop/nvidiabl/Manifest new file mode 100644 index 000000000000..be1eb6f2c1ae --- /dev/null +++ b/app-laptop/nvidiabl/Manifest @@ -0,0 +1,8 @@ +AUX nvidiabl-0.87-linux-4.0.patch 904 SHA256 f1a429e7a28e806624556b2951266434ace9370822bfa3e4671c0e96249b299f SHA512 85860cdd66605c88b1d806e8c6962d70c246dd34e463e9c990156b8a023bb7d47585e95a0444ca63827f64fc4a95064c9d12cdec29264b5d4a439dbcb33958ed WHIRLPOOL c01c1ef2091d274e5085e05041226acdc56debafb6675ab6a2409583004ebc68fd60c9d39193dd66832c161187a7a14f6ab6579176d566d0c74781a2b8a28bcd +DIST nvidiabl-0.83.tar.gz 448594 SHA256 0ea79770c02ae297fb6d660ee28ecf7a7acc346de0a55e3231ce499d4184db0f SHA512 cbf4f042acb9005c25d8d008973220f4d42fe890bfd86a34b72c0e56129dfcdcad2383acacf048e5e9da33aaf759053cdadeddac9e0946ae49a8a29ed03447dd WHIRLPOOL 4d1e13ffe1bed36ffee1c498c6384a9ff3fcc561e3aa443c15106baa9711523b8798f0283e42d6365afa57f8d7b4a394835bbea2eb8c6d41a8910c38d661012b +DIST nvidiabl-0.87.tar.gz 36563463 SHA256 a5a035520cce17ef1b6b2f98eb6ad10ef7d4d3e55dd2f12b6b961fabc05c5e35 SHA512 778f8b9e7d6d8e9ecbeef745bf3602e56b38757791d7b49ebf3326758117487f7494e232aaa9354b91fd17ee3578c80278e0e60175b274b1a1a93e952dc0dfe5 WHIRLPOOL 3ebca47463ccc1059a3d7dd109479ee9c9bce4332da8ac25aaf14fd8630b72b6620e8941a69fd7e2e734739f894362efff75ace05692a3c402a8981601dd3c36 +EBUILD nvidiabl-0.83.ebuild 886 SHA256 6973541a128da1280f0ec8c0b1d7e048c744eaeb848df0ada0c32d0f203c375c SHA512 f6c9be10669d2c4df5f7131b3f0407ed103a27fa10c802717a59efd19ee78d21a73b1695fa060f4465d965a3b286122ad8d2d042f8b8b22d61596e732cdb81db WHIRLPOOL a94f655b7bf2930902627f4cce882a946acdf2b7d4b4460c669981902f11043b4100cb3f5350b5e177bfd2f78f221aa1019644ff22a79978e807d10a5612786a +EBUILD nvidiabl-0.87.ebuild 910 SHA256 d44a7556c386b4c9e60c2853fdf521710c28dcd2dd6726f71b2d08d075ced824 SHA512 ab316b3421500eca4a562593075a0c79bbc7e0efc327c43109d0340be8ced1e2905a3069d0c10d780e5a6031dd687c655d20fe59a547cadb14b3fd577fec2613 WHIRLPOOL 06f5b059e4773912da01b2a1e739381af92a964050fc45b9aa704c5dcefc9d3a2df5493bce570d873374d324afbeb0935f1053da6035f7a89b504036c8242515 +MISC ChangeLog 3195 SHA256 96c63c1a0b739e0eeca1181b8418dafd6dd7cb447e0e36e80a138cbc6bff9c1a SHA512 f8887928733c3373c268c3b17d3497e793c9890b3a387478eb0f39497c617d8cdd4483d502e34cd5252c266674ad0c7847b6b62313ae770a24bdc1dbca2b7527 WHIRLPOOL 51776b51a366f15a93db053e5dbfdd52235ea392d211f4d67a424b1186f916cbd4daa0a8b5e60785c4ff30e26c0be0b9f73ce988860edce01379dbbd4f0b3cd1 +MISC ChangeLog-2015 3490 SHA256 c9d4f6d8287dde4f50d86b38343df6409d42e32347ecbea68c4b4a6727bf0ca1 SHA512 a702034e7176cb82754db504f9bce16de33e903dbe059601955295b7d200fc2ddd910e9b696688fc03fd1c6c09148f18f6a0eb81bbcd0028deba9be83d565daf WHIRLPOOL 100168454ef9110b1092af216907fff87e0f623676e065fc184af062aab740947f4dfb35cdbb8e70ecf5fc9a666fd70f75f1fbd0c1073b9e707ffa958387aa55 +MISC metadata.xml 533 SHA256 8d6cb4ef976d99356fedf1268bf304bb923d61e29e390a7dba495e0e9a7e3c78 SHA512 2990b5e49b2a74d1a0b5dd21df5d65c14f7be7edf938bd7f90db61ae45f6ce69ae12420d144c5964e50b943e65862bdd3b312db5d11dea787391b6447d761820 WHIRLPOOL 439503c07a6c5c64c3512bbbb7498b20e5a262f3c15a9aa7c8da2b4c627a1a2de035fdd6e5b6224c0a0e14a081840348d82b757bac88c0776de169848a2a16c7 diff --git a/app-laptop/nvidiabl/files/nvidiabl-0.87-linux-4.0.patch b/app-laptop/nvidiabl/files/nvidiabl-0.87-linux-4.0.patch new file mode 100644 index 000000000000..b466bcb620c9 --- /dev/null +++ b/app-laptop/nvidiabl/files/nvidiabl-0.87-linux-4.0.patch @@ -0,0 +1,23 @@ +From dee67fbf8eeec1651dbee3c2045ce6a93da949dc Mon Sep 17 00:00:00 2001 +From: Thomas Wucher <mail@thomaswucher.de> +Date: Tue, 14 Apr 2015 08:41:09 +0200 +Subject: [PATCH] Replace strnicmp by stncasecmp to fix build on Linux 4.0 + +--- + nvidiabl-module.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/nvidiabl-module.c b/nvidiabl-module.c +index b789ea4..b306579 100644 +--- a/nvidiabl-module.c ++++ b/nvidiabl-module.c +@@ -214,7 +214,7 @@ static int __init nvidiabl_init(void) + #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39) + + for (iii = 0 ; iii < sizeof(backlight_type_ids) ; iii++) { +- if (strnicmp(bl_type, backlight_type_ids[iii].id, sizeof(bl_type)) == 0) { ++ if (strncasecmp(bl_type, backlight_type_ids[iii].id, sizeof(bl_type)) == 0) { + props.type = backlight_type_ids[iii].type; + printk(KERN_INFO "nvidiabl: backlight type is %s\n", backlight_type_ids[iii].id); + } + diff --git a/app-laptop/nvidiabl/metadata.xml b/app-laptop/nvidiabl/metadata.xml new file mode 100644 index 000000000000..906ca943dc9c --- /dev/null +++ b/app-laptop/nvidiabl/metadata.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>gentoobugzilla@jeltef.nl</email> + <name>Jelte Fennema</name> + <description>Proxied maintainer; set to assignee in all bugs</description> + </maintainer> + <maintainer type="project"> + <email>proxy-maint@gentoo.org</email> + <name>Proxy Maintainers</name> + </maintainer> + <upstream> + <remote-id type="github">guillaumezin/nvidiabl</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/nvidiabl/nvidiabl-0.83.ebuild b/app-laptop/nvidiabl/nvidiabl-0.83.ebuild new file mode 100644 index 000000000000..60f196c88ea6 --- /dev/null +++ b/app-laptop/nvidiabl/nvidiabl-0.83.ebuild @@ -0,0 +1,37 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 +inherit linux-mod + +DESCRIPTION="Linux driver for setting the backlight brightness on laptops using +NVIDIA GPU" +HOMEPAGE="https://github.com/guillaumezin/nvidiabl" +SRC_URI="https://github.com/guillaumezin/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 x86" +IUSE="" + +DEPEND="" +RDEPEND="" + +RESTRICT="test" + +BUILD_TARGETS="modules" +MODULE_NAMES="nvidiabl()" + +pkg_pretend() { + CONFIG_CHECK="FB_BACKLIGHT" + ERROR_FB_BACKLIGHT="Your kernel does not support FB_BACKLIGHT. To enable you +it you can enable any frame buffer with backlight control or nouveau. +Note that you cannot use FB_NVIDIA with nvidia's proprietary driver" + linux-mod_pkg_setup +} + +src_compile() { + BUILD_PARAMS="KVER=${KV_FULL}" + MAKEOPTS+=" V=1" + linux-mod_src_compile +} diff --git a/app-laptop/nvidiabl/nvidiabl-0.87.ebuild b/app-laptop/nvidiabl/nvidiabl-0.87.ebuild new file mode 100644 index 000000000000..e4179351b278 --- /dev/null +++ b/app-laptop/nvidiabl/nvidiabl-0.87.ebuild @@ -0,0 +1,34 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 +inherit linux-mod eutils + +DESCRIPTION="Linux driver for setting the backlight brightness on laptops using NVIDIA GPU" +HOMEPAGE="https://github.com/guillaumezin/nvidiabl" +SRC_URI="https://github.com/guillaumezin/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +pkg_setup() { + CONFIG_CHECK="FB_BACKLIGHT" + ERROR_FB_BACKLIGHT="Your kernel does not support FB_BACKLIGHT. To enable you +it you can enable any frame buffer with backlight control or nouveau. +Note that you cannot use FB_NVIDIA with nvidia's proprietary driver" + linux-mod_pkg_setup +} + +src_prepare() { + epatch "${FILESDIR}"/${P}-linux-4.0.patch +} + +src_compile() { + BUILD_PARAMS="KVER=${KV_FULL}" + BUILD_TARGETS="modules" + MODULE_NAMES="nvidiabl()" + + MAKEOPTS+=" V=1" + linux-mod_src_compile +} diff --git a/app-laptop/pbbuttonsd/Manifest b/app-laptop/pbbuttonsd/Manifest new file mode 100644 index 000000000000..71fb6e29dd7d --- /dev/null +++ b/app-laptop/pbbuttonsd/Manifest @@ -0,0 +1,17 @@ +AUX pbbuttonsd-0.8.1-cpufreq.patch 757 SHA256 a5cfb505f6124e1d7ab9da24e89b74c5f23c9e264d714ebae4ec13a15a460647 SHA512 b458ddbcbe8e20fdb316d436f3c3f6c7668ce02cabd2d25d7ed731ad14b431a3f1eb67185d3d5bec26921db1343d5996541c248b7bfeaf1117d469aa4f2a7bad WHIRLPOOL ef6f0b78e8dae02e8956e1915a553fc1d601910af71894ebf5d706ce5898986afdfada1b888d1507ae2813f8625e918a68d966f568ecd065ff509b873515ced0 +AUX pbbuttonsd-0.8.1-fnmode.patch 850 SHA256 3ade78844d061de5055730c4f40df2a7d7097185fbb00ac47ee5193b708cfe8d SHA512 00ed4dd0c0e9e7e92078275fc9fb71c5dd1afd78796cf644f091e32d8d97d7e6f2dce31cf01664f40c51e8ecbfcfe200b09c626c898dfb002426bc2e59ef1609 WHIRLPOOL fd31a4964a75967edd450e84b469688be76925dce158bc129cd9288280b065a7a33c8230922ceaee6d17e0270f19f19fa2f63234180a2ed4118b0e16e9cbb9f8 +AUX pbbuttonsd-0.8.1-g++.patch 431 SHA256 5c87958dd621265686e4f7dec9529b939ce1fcd507f5ff892dd9db1cbadf6270 SHA512 01597510267ea52816bbe7e90e6ac1f872265b77f689387557b8263e5631e1ebfba09af2fc27a1034f2cde7164801c284e1b565064675dd598cc0aa82bd64073 WHIRLPOOL 75e9564773f8817db5bbb6a3dcba6949169b929c798caf537a2331a49e70e4cf8eedbe560e1776f86d459f74586c4a43bd9aa18d41621721d0683ba108d060a4 +AUX pbbuttonsd-0.8.1-laptopmode.sh.patch 827 SHA256 88c41e21229e608e776d899c1a6e34888c0fb1b4a73e8b7ce36c0ef9372fcf93 SHA512 3ab0e2ce5b3fa050d7cc27c7e9d90fb3e7fdca46ba2de8e34cfd0a6338b5ba27dcb07204827ccaa8b228f37ae5941e5829b3cfe1a9c4aa3cc50754c7fcedc307 WHIRLPOOL 2ad579a122c6edcdb9a41f58439e77221d7b1cf734fc647a3882e0df50af132bf6ad5a4c3ecfcf3b2f02c299b5c870db57998bca1a651e2eaf97dfdcb2fd4f04 +AUX pbbuttonsd-0.8.1-lm.patch 419 SHA256 3af258a7611165a56eed47c83ed64ae2a1dc0aeb73a5a4322f724c0e15bf8e55 SHA512 1ce79d85f9119d0d94b789557f8dc41ddcd8ca030c8b03c2399035e21115e2ff3bfb7c4284750450733ac5ad305fa2513041e65feeecd7dca81db4a23ae53e34 WHIRLPOOL e2490d90312aa0ba3f0ed7b1f59d3e24180091827023dc6c991eca4378192608a5fc35f5f56cb9d3636feb2f8c15e51f2db2b80176af63e23a6241f15186bf6a +AUX pbbuttonsd-0.8.1-lz.patch 920 SHA256 638af170879e623f4e3ec2dc275b7ac0beb2f90084a6c179a2be8a6f028a7563 SHA512 17546f9b7e8b488a2ace5cab29da3738ff59c708aeaae1ef58e6240dba0876254f83f5df358d76af271c636d64c512d7d9fa550e377d4e57d92851a720441dea WHIRLPOOL 9584970f21e87e6920a534465070533a794064e4104ab4c494fc23346237d3c321fc8c4d84866e06b0e8b48407a3d8d2cc6969799bd1b2f46aa975d059802d8b +AUX pbbuttonsd-0.8.1-pmcs.patch 692 SHA256 e3f422422145da76d958a70f882eaa888ed8bb79bbbe08f569978c7ed3dc4ab9 SHA512 ae8e9c695d80fa775c07b64968f13b3092858e14b37b1ce725e10ea06b897304e9f5079339633163b02e565d9dbb96db321d628394fcfefe528c7a1d36c66b31 WHIRLPOOL a687e120a44f25990f8bd336705e2e2e84425510b1c24fc43a59935f9a2a427353fc8e1d6a860af7415b2b024d88d49c35abd652dda0bfff31157ec51dddcc53 +AUX pbbuttonsd.rc6 355 SHA256 3562146513caaeae7cf4d24b82c6e4500ec0e68aba1f1d71aa9b486232f1aef0 SHA512 93165ce1d1c757e58b407656bf86084bb3fcfe0c55897fbb382f107ff9b3d69559255a11ac3017cf5741eb2923d753f5cc3f1b495e31e16b18b16757accfbdfb WHIRLPOOL 4817d545d85a17392867fe6a90e98e3ff25a8179745cca7beb4c9bb92caa8cca50709486d56b3de7f659f04ca2cd961120c4a990cd15a7c1e83615fb06d39340 +AUX wireless 235 SHA256 0bc03fac1b17933200a3e6d3f50a1d2d2717857006aa06ddaf5d6650c902a978 SHA512 58cbfb80ec32ba6868fea500bcf58bf649a0f468a017ec8c200fe0edd0fd7f1fe17efaafca3e67c20df9fc5a6c80b2941237a375f6e73349a83593dcfacf2816 WHIRLPOOL 6c201feba4cd33677bfadf6305146693fef9dc49b14fc43e407179f0c35cb92653c24e92b7270bf5389e75d790ed6e665864c1941efd435a91c99f5e6bee06d9 +DIST pbbuttonsd-0.8.1.tar.gz 589630 SHA256 b391fd98ed263f355d7e7addc6566959e986627c87dcfdaa1da15310ad70bffa SHA512 856f8533c1f6489986c232baa8b8002a01d009ed3728ee35bc723aece91ba626ce961119c0d424f40c2f9289827f317c56d70fe8f0e035cbd9f08d7701316ac3 WHIRLPOOL 21a18a9f6a204156beb7373f89c6477c68ef90d8d9fe15cb7322b811b15856fd38bca7705860584716b00cd29378b85d0f2ac7624f00fe50ec44ac83033c073b +DIST pbbuttonsd-0.8.1a.tar.gz 589747 SHA256 254cc391bcb0a4a58a62224b4cca2b29fdf9ca174c1dc18ab0784f1a86465ed1 SHA512 4aaf674872982925f7aa8e06a363f50830f13d9491f4a3b850c1852a8a6d4b2c72164f839c482eed059703dd25d900fe3bb774f78e7039ac2464ea7a1837bf99 WHIRLPOOL ee17f8ff9c39c84b40aa39a6652b18de2c1a183972f4d0cb2585b46ddf6f0d34d9b8af2b7460f84fa0ee19d99497cbe6240996e3f58eb6b83f8053fdc7616165 +EBUILD pbbuttonsd-0.8.1-r3.ebuild 3424 SHA256 4a2abda0060221a00ed798a1c89580501a526a1754733318143e80cc31cbaa4e SHA512 14d1f926a6bb7114984ea4cc90f6b4d23a69ca487b5e6b0f8967a494353b147cbc57ea83f7d92870062976d783c741c36f67b92c69a6942a2be564e79c6d0cbf WHIRLPOOL c1b44184fb7d656ad29a7560dfca1a6422bac78ddad0fd4cb5f7c171d39167d160c46123138de5231a575dc5a67aab9a5f9344f9aeb66f68a9565d5c83cea069 +EBUILD pbbuttonsd-0.8.1-r4.ebuild 3572 SHA256 47d6677d94b89992d35ba7593639351a8056273d5b2f6dca644cbf9371915b93 SHA512 f8b1a365634a3c4103c96bec1d360b1f25a116e7896c78b5c3fdbf66904c1753b66f1bfde7e497c6758529a2ad4ef2a8eeab986bbbd90d5cfadd1b771af5e7d2 WHIRLPOOL 51e331b0b7b43b0f82f9746a220e4a4fbb3dc53a73acf341635b9c935bc550ea7204b6c6ba8da8f97f8571326610399c52ea09ab8a379a8a614eff1599f9f9fd +EBUILD pbbuttonsd-0.8.1a.ebuild 3251 SHA256 93447a5dd3d1ffb8eded599b482fd7134e358a1f5626afbf5a4419e47663665b SHA512 05df1091b4f54a8797a756d87549a4a88075993a5f8f4027127041209b3f65956f457fa9e682b914b6565c47ba19994af1adb81a76ca8f5944e7317cfe161cb1 WHIRLPOOL 9b56599efce2148ce92d95c09fda67e3537f43cb7718f5899e2334a5f51a8be3ac6176f3e9c4189e58a719608603af0a9d703fa7c26ff2e18bce0ef299fc3d52 +MISC ChangeLog 2827 SHA256 43314e474de9c34aee3f0c58a00cbaa3870d07315101a0a6d26dc7748ce8fbfd SHA512 92288d57099e2f2c87a41621df0507e6dcf549d3f698ed2074acbe67a2f6e04197defda7ac9d31a93cef74918743346edd727e359c2c86478b82fb7b249522e3 WHIRLPOOL 8f94b95964bd405d81fd036337740043704cf646a9b322eded61569574fbf156c5ee5b9f8a499b51bc3a96ae35dbf5f9bb7ee5716c359c0c7570beac9d61d66e +MISC ChangeLog-2015 17205 SHA256 2b5bd8c0b6a873c919cae7d7c0ad693177fea467c0ab2b7144cc981e0b6fd791 SHA512 b5307d94ae26ced2ae218fa865ea827c0a7501a3c6b8cee0943e28cfeaf1030036b5a6111c894d2d0a9b763bd988d77357e176eea58ba1275a190955468b5221 WHIRLPOOL 8f1bf04099b108c6581b6e10093a4ad85846b39ca7af658db1903aa8abfed0c551918c6df6043f02f3a67e77dc4c644fed4c0ccdec45a85dfb369e64f77ac048 +MISC metadata.xml 511 SHA256 37aa68e489334ad3bd1dee7a1d938759124c100782c9cd430f2ed96f5669d103 SHA512 5a56b1fe175cd76fa23d90e4499f0a6bacfacdb9cb2fd647dbabec42030021c0b4f27eb04b523b9ae7bc44706ee9404abdf5ff16aa92655fab5d00ac187eca5b WHIRLPOOL f86d8c330fbda23c91b424e08e2cb93fbd9964d6d62e2f3fac5fdee4e8757a23c4256ef9099db11f4cdcf7132eb4c2b664c3d83de1508ea4ab2cd2a285d12071 diff --git a/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-cpufreq.patch b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-cpufreq.patch new file mode 100644 index 000000000000..89ab72a8947f --- /dev/null +++ b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-cpufreq.patch @@ -0,0 +1,20 @@ +--- a/scripts/scripts.d/cpufreq ++++ b/scripts/scripts.d/cpufreq +@@ -18,7 +18,7 @@ + case "$1" in + powersave|custom) + case "$KVER" in +- 2.6.*) ++ "2.6."*|"3."*) + if [ -d /sys ]; then + echo -n "userspace" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor + cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_min_freq > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq +@@ -41,7 +41,7 @@ + ;; + performance) + case "$KVER" in +- 2.6.*) ++ "2.6."*|"3."*) + if [ -d /sys ]; then + echo -n "userspace" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor + cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_min_freq > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq diff --git a/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-fnmode.patch b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-fnmode.patch new file mode 100644 index 000000000000..3c4ed71cb367 --- /dev/null +++ b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-fnmode.patch @@ -0,0 +1,23 @@ +--- a/src/module_pmac.c ++++ b/src/module_pmac.c +@@ -990,7 +990,9 @@ + } + } else { + if ((fd = open ("/sys/module/usbhid/parameters/pb_fnmode", O_RDONLY)) < 0) +- fd = open ("/sys/module/hid/parameters/pb_fnmode", O_RDONLY); ++ if ((fd = open ("/sys/module/hid/parameters/pb_fnmode", O_RDONLY)) < 0) ++ fd = open("/sys/module/hid_apple/parameters/fnmode", O_RDONLY); ++ + + if (fd >= 0) { + if ((n = read (fd, ADBBuffer, ADB_BUFSIZE-1)) > 0) { +@@ -1025,7 +1027,8 @@ + } + } else { + if ((fd = open ("/sys/module/usbhid/parameters/pb_fnmode", O_WRONLY)) < 0) +- fd = open ("/sys/module/hid/parameters/pb_fnmode", O_WRONLY); ++ if ((fd = open ("/sys/module/hid/parameters/pb_fnmode", O_WRONLY)) < 0) ++ fd = open ("/sys/module/hid_apple/parameters/fnmode", O_WRONLY); + + if (fd >= 0) { + sprintf ((char*)ADBBuffer, "%d", config); diff --git a/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-g++.patch b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-g++.patch new file mode 100644 index 000000000000..de43b800128f --- /dev/null +++ b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-g++.patch @@ -0,0 +1,11 @@ +--- a/src/Makefile.in ++++ b/src/Makefile.in +@@ -319,7 +319,7 @@ + -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) + pbbuttonsd$(EXEEXT): $(pbbuttonsd_OBJECTS) $(pbbuttonsd_DEPENDENCIES) + @rm -f pbbuttonsd$(EXEEXT) +- $(CXXLINK) $(pbbuttonsd_LDFLAGS) $(pbbuttonsd_OBJECTS) $(pbbuttonsd_LDADD) $(LIBS) ++ $(LINK) $(pbbuttonsd_LDFLAGS) $(pbbuttonsd_OBJECTS) $(pbbuttonsd_LDADD) $(LIBS) + + mostlyclean-compile: + -rm -f *.$(OBJEXT) diff --git a/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-laptopmode.sh.patch b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-laptopmode.sh.patch new file mode 100644 index 000000000000..c29efe3122ac --- /dev/null +++ b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-laptopmode.sh.patch @@ -0,0 +1,29 @@ +--- a/scripts/scripts.d/laptopmode.sh ++++ b/scripts/scripts.d/laptopmode.sh +@@ -122,7 +122,7 @@ + ) + ) + case "$KLEVEL" in +- "2.4"|"2.6") ++ "2.4"|"2.6"|"3."*) + true + ;; + *) +@@ -222,7 +222,7 @@ + echo "1" > /proc/sys/vm/laptop_mode + echo "30 500 0 0 $AGE $AGE 60 20 0" > /proc/sys/vm/bdflush + ;; +- "2.6") ++ "2.6"|"3."*) + echo "5" > /proc/sys/vm/laptop_mode + echo "$AGE" > /proc/sys/vm/dirty_writeback_centisecs + echo "$AGE" > /proc/sys/vm/dirty_expire_centisecs +@@ -268,7 +268,7 @@ + "2.4") + echo "30 500 0 0 $U_AGE $B_AGE 60 20 0" > /proc/sys/vm/bdflush + ;; +- "2.6") ++ "2.6"|"3."*) + echo "$U_AGE" > /proc/sys/vm/dirty_writeback_centisecs + echo "$B_AGE" > /proc/sys/vm/dirty_expire_centisecs + echo "$DEF_DIRTY_RATIO" > /proc/sys/vm/dirty_ratio diff --git a/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-lm.patch b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-lm.patch new file mode 100644 index 000000000000..794de96244cb --- /dev/null +++ b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-lm.patch @@ -0,0 +1,11 @@ +--- a/src/Makefile.in ++++ b/src/Makefile.in +@@ -255,7 +255,7 @@ + module_peep.c module_peep.h debug.h \ + tcp.c tcp.h + +-pbbuttonsd_LDADD = -lpbb $(INTLLIBS) $(PB_OBJECTS) $(PB_LIBS) @PACKAGE_LIBS@ ++pbbuttonsd_LDADD = -lpbb -lm $(INTLLIBS) $(PB_OBJECTS) $(PB_LIBS) @PACKAGE_LIBS@ + pbbuttonsd_LDFLAGS = -L$(top_srcdir)/libpbbipc + pbbuttonsd_DEPENDENCIES = $(PB_OBJECTS) + @DEBUG_TRUE@AM_CFLAGS1 = -DDEBUG diff --git a/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-lz.patch b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-lz.patch new file mode 100644 index 000000000000..93cebe1d5c6e --- /dev/null +++ b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-lz.patch @@ -0,0 +1,25 @@ +--- a/configure.in ++++ b/configure.in +@@ -33,6 +33,9 @@ + PB_OBJECTS= + PB_LIBS= + ++### Setup PKG_CONFIG ++PKG_PROG_PKG_CONFIG ++ + if test "x$laptop" != "x"; then + ac_laptop=$laptop + elif test "x$LAPTOP" != "x"; then +@@ -59,10 +62,9 @@ + AC_CHECK_HEADERS([smbios/SystemInfo.h], + AC_DEFINE_UNQUOTED(WITH_SMBIOS, 1, [SMBIOS available]), + AC_MSG_ERROR([SMBios library not available. Please install development files for libsmbios.]), [/* dummy */]) +- AC_CHECK_HEADERS([pci/pci.h sys/io.h], ac_macbook=yes, +- AC_MSG_ERROR([Please install development files for libpci and direct I/O.]), [/* dummy */]) ++ PKG_CHECK_MODULES(LIBPCI, libpci) + PB_OBJECTS+=" driver_backlight_x1600.$OBJEXT driver_backlight_gma950.$OBJEXT module_acpi.$OBJEXT module_imac.$OBJEXT" +- PB_LIBS+=" -lpci -lsmbios" ++ PB_LIBS+=" -lsmbios $LIBPCI_LIBS" + LCD_FADINGSPEED="448" + LCD_AUTOADJMODE="linear" + LCD_AUTOADJPARMBAT="0,10,80,30" diff --git a/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-pmcs.patch b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-pmcs.patch new file mode 100644 index 000000000000..2ed3bf329e28 --- /dev/null +++ b/app-laptop/pbbuttonsd/files/pbbuttonsd-0.8.1-pmcs.patch @@ -0,0 +1,21 @@ +--- a/scripts/pmcs-config ++++ b/scripts/pmcs-config +@@ -11,15 +11,15 @@ + + # Section for power policy 'performance' + performance_HDTimeOff=0 # hdsetup - timeout in seconds +-performance_HDOptions="-p" # hdsetup ++performance_HDOptions="" # hdsetup + performance_LaptopMode="stop" # bdflush + + # Section for power policy 'custom' + custom_HDTimeOff=60 # hdsetup - timeout in seconds +-custom_HDOptions="-p" # hdsetup ++custom_HDOptions="" # hdsetup + custom_LaptopMode="start" # bdflush + + # Section for power policy 'powersave' + powersave_HDTimeOff=60 # hdsetup - timeout in seconds +-powersave_HDOptions="-p" # hdsetup ++powersave_HDOptions="" # hdsetup + powersave_LaptopMode="start" # bdflush diff --git a/app-laptop/pbbuttonsd/files/pbbuttonsd.rc6 b/app-laptop/pbbuttonsd/files/pbbuttonsd.rc6 new file mode 100644 index 000000000000..ba5e167790d0 --- /dev/null +++ b/app-laptop/pbbuttonsd/files/pbbuttonsd.rc6 @@ -0,0 +1,19 @@ +#!/sbin/openrc-run +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +depend() { + use alsasound +} + +start() { + ebegin "Starting pbbuttonsd" + /usr/bin/pbbuttonsd -d > /dev/null + eend $? +} + +stop() { + ebegin "Stopping pbbuttonsd" + start-stop-daemon --stop --quiet --exec /usr/bin/pbbuttonsd + eend $? +} diff --git a/app-laptop/pbbuttonsd/files/wireless b/app-laptop/pbbuttonsd/files/wireless new file mode 100644 index 000000000000..b110b3819a68 --- /dev/null +++ b/app-laptop/pbbuttonsd/files/wireless @@ -0,0 +1,7 @@ +#!/bin/sh +### Restart the wireless device on Gentoo +### Useful for bcm43xx/b43 which doesn't reconnect on resume + +### Uncomment the line below and properly set the device variable +WIRELESS="net.wlan0" +# /etc/init.d/${WIRELESS} restart diff --git a/app-laptop/pbbuttonsd/metadata.xml b/app-laptop/pbbuttonsd/metadata.xml new file mode 100644 index 000000000000..c123825ee27e --- /dev/null +++ b/app-laptop/pbbuttonsd/metadata.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>ppc@gentoo.org</email> + <name>Gentoo Linux PowerPC Development</name> + </maintainer> + <use> + <flag name="ibam">Enable support for Intelligent Battery Monitoring</flag> + <flag name="macbook">Enable support for the Macbook and Macbook Pro</flag> + </use> + <upstream> + <remote-id type="sourceforge">pbbuttons</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/pbbuttonsd/pbbuttonsd-0.8.1-r3.ebuild b/app-laptop/pbbuttonsd/pbbuttonsd-0.8.1-r3.ebuild new file mode 100644 index 000000000000..21c530b0a04b --- /dev/null +++ b/app-laptop/pbbuttonsd/pbbuttonsd-0.8.1-r3.ebuild @@ -0,0 +1,124 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +inherit autotools flag-o-matic eutils + +DESCRIPTION="Handles power management and special keys on laptops" +HOMEPAGE="http://pbbuttons.berlios.de" +SRC_URI="mirror://sourceforge/pbbuttons/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ppc ~x86" +IUSE="acpi alsa debug doc ibam macbook oss" + +DEPEND="macbook? ( + sys-libs/libsmbios + sys-apps/pciutils + ) + >=dev-libs/glib-2.6 + doc? ( app-doc/doxygen )" +RDEPEND="alsa? ( >=media-libs/alsa-lib-1.0 ) + >=dev-libs/glib-2.6" + +src_unpack() { + unpack ${A} + cd "${S}" + + epatch "${FILESDIR}/${PN}-0.8.1-pmcs.patch" + ### Don't link with g++ if we don't use ibam + if ! use ibam; then + epatch "${FILESDIR}/${PN}-0.8.1-g++.patch" + fi + ### Fix macbook -lz issue + epatch "${FILESDIR}/${PN}-0.8.1-lz.patch" + epatch "${FILESDIR}/${PN}-0.8.1-lm.patch" + ### Fix new apple hid fnmode issue + epatch "${FILESDIR}/${PN}-0.8.1-fnmode.patch" + eautoconf +} + +src_compile() { + # Fix crash bug on some systems + replace-flags -O? -O1 + + if use macbook; then + laptop=macbook + elif use x86 || use amd64; then + if use acpi; then + laptop=acpi + else + laptop=i386 + fi + # Default to PowerBook + else + laptop=powerbook + fi + + econf laptop=$laptop \ + $(use_enable debug) \ + $(use_with doc doxygen_docs) \ + $(use_with alsa) \ + $(use_with oss) \ + $(use_with ibam) \ + || die "Sorry, failed to configure pbbuttonsd" + + # Thanks to Stefan Bruda for this workaround + # Using -j1 fixes a parallel build issue with the docs + if use doc; then + emake -j1 || die "Sorry, failed to compile pbbuttonsd" + else + emake || die "Sorry, failed to compile pbbuttonsd" + fi +} + +src_install() { + dodir /etc/power + use ibam && dodir /var/lib/ibam + make DESTDIR="${D}" install || die "failed to install" + newinitd "${FILESDIR}/pbbuttonsd.rc6" pbbuttonsd + dodoc README + use doc && dohtml -r doc/* + + dodir /etc/power/resume.d + dodir /etc/power/suspend.d + dodir /etc/power/scripts.d + exeinto "/etc/power/scripts.d" + doexe "${FILESDIR}/wireless" + ln -s "${D}/etc/power/scripts.d/wireless" "${D}/etc/power/resume.d/wireless" +} + +pkg_postinst() { + if [ -e /etc/pbbuttonsd.conf ]; then + ewarn "The pbbuttonsd.cnf file replaces /etc/pbuttonsd.conf with a new" + ewarn "file (/etc/pbbuttonsd.conf) and a new format. Please check the" + ewarn "manual page with 'man pbbuttonsd.cnf' for details." + ewarn + fi + + if use macbook; then + ewarn "Macbook and Macbook Pro users should make sure to have applesmc" + ewarn "loaded before starting pbbuttonsdm otherwise auto-adjustments" + ewarn "will not work and pbbuttonsd may segfault." + fi + + ewarn "Ensure that the evdev kernel module is loaded otherwise" + ewarn "pbbuttonsd won't work. SysV IPC is also required." + ewarn + ewarn "If you need extra security, you can tell pbbuttonsd to only accept" + ewarn "input from one user. You can set the userallowed option in" + ewarn "/etc/pbbuttonsd.cnf to limit access." + ewarn + + if use ibam; then + elog "To properly initialize the IBaM battery database, you will" + elog "need to perform a full discharge/charge cycle. For more" + elog "details, please see the pbbuttonsd man page." + elog + fi + + elog "A script is now available to reset your wirless connection on resume." + elog "Simply uncomment the commented command and set the correct device to" + elog "use it. You can find the script in /etc/power/resume.d/wireless" + +} diff --git a/app-laptop/pbbuttonsd/pbbuttonsd-0.8.1-r4.ebuild b/app-laptop/pbbuttonsd/pbbuttonsd-0.8.1-r4.ebuild new file mode 100644 index 000000000000..03c5674bc6d6 --- /dev/null +++ b/app-laptop/pbbuttonsd/pbbuttonsd-0.8.1-r4.ebuild @@ -0,0 +1,128 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +inherit autotools flag-o-matic eutils + +DESCRIPTION="Handles power management and special keys on laptops" +HOMEPAGE="http://pbbuttons.berlios.de" +SRC_URI="mirror://sourceforge/pbbuttons/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86" +IUSE="acpi alsa debug doc ibam macbook oss" + +DEPEND="macbook? ( + sys-libs/libsmbios + sys-apps/pciutils + ) + >=dev-libs/glib-2.6 + doc? ( app-doc/doxygen )" +RDEPEND="alsa? ( >=media-libs/alsa-lib-1.0 ) + >=dev-libs/glib-2.6" + +src_unpack() { + unpack ${A} + cd "${S}" + + epatch "${FILESDIR}/${PN}-0.8.1-pmcs.patch" + ### Don't link with g++ if we don't use ibam + if ! use ibam; then + epatch "${FILESDIR}/${PN}-0.8.1-g++.patch" + fi + ### Fix macbook -lz issue + epatch "${FILESDIR}/${PN}-0.8.1-lz.patch" + epatch "${FILESDIR}/${PN}-0.8.1-lm.patch" + ### Fix new apple hid fnmode issue + epatch "${FILESDIR}/${PN}-0.8.1-fnmode.patch" + ### Add kernel 2.6.x stuff for 3.x as well + epatch "${FILESDIR}/${PN}-0.8.1-laptopmode.sh.patch" + epatch "${FILESDIR}/${PN}-0.8.1-cpufreq.patch" + + eautoconf +} + +src_compile() { + # Fix crash bug on some systems + replace-flags -O? -O1 + + if use macbook; then + laptop=macbook + elif use x86 || use amd64; then + if use acpi; then + laptop=acpi + else + laptop=i386 + fi + # Default to PowerBook + else + laptop=powerbook + fi + + econf laptop=$laptop \ + $(use_enable debug) \ + $(use_with doc doxygen_docs) \ + $(use_with alsa) \ + $(use_with oss) \ + $(use_with ibam) \ + || die "Sorry, failed to configure pbbuttonsd" + + # Thanks to Stefan Bruda for this workaround + # Using -j1 fixes a parallel build issue with the docs + if use doc; then + emake -j1 || die "Sorry, failed to compile pbbuttonsd" + else + emake || die "Sorry, failed to compile pbbuttonsd" + fi +} + +src_install() { + dodir /etc/power + use ibam && dodir /var/lib/ibam + make DESTDIR="${D}" install || die "failed to install" + newinitd "${FILESDIR}/pbbuttonsd.rc6" pbbuttonsd + dodoc README + use doc && dohtml -r doc/* + + dodir /etc/power/resume.d + dodir /etc/power/suspend.d + dodir /etc/power/scripts.d + exeinto "/etc/power/scripts.d" + doexe "${FILESDIR}/wireless" + ln -s "${D}/etc/power/scripts.d/wireless" "${D}/etc/power/resume.d/wireless" +} + +pkg_postinst() { + if [ -e /etc/pbbuttonsd.conf ]; then + ewarn "The pbbuttonsd.cnf file replaces /etc/pbuttonsd.conf with a new" + ewarn "file (/etc/pbbuttonsd.conf) and a new format. Please check the" + ewarn "manual page with 'man pbbuttonsd.cnf' for details." + ewarn + fi + + if use macbook; then + ewarn "Macbook and Macbook Pro users should make sure to have applesmc" + ewarn "loaded before starting pbbuttonsdm otherwise auto-adjustments" + ewarn "will not work and pbbuttonsd may segfault." + fi + + ewarn "Ensure that the evdev kernel module is loaded otherwise" + ewarn "pbbuttonsd won't work. SysV IPC is also required." + ewarn + ewarn "If you need extra security, you can tell pbbuttonsd to only accept" + ewarn "input from one user. You can set the userallowed option in" + ewarn "/etc/pbbuttonsd.cnf to limit access." + ewarn + + if use ibam; then + elog "To properly initialize the IBaM battery database, you will" + elog "need to perform a full discharge/charge cycle. For more" + elog "details, please see the pbbuttonsd man page." + elog + fi + + elog "A script is now available to reset your wirless connection on resume." + elog "Simply uncomment the commented command and set the correct device to" + elog "use it. You can find the script in /etc/power/resume.d/wireless" + +} diff --git a/app-laptop/pbbuttonsd/pbbuttonsd-0.8.1a.ebuild b/app-laptop/pbbuttonsd/pbbuttonsd-0.8.1a.ebuild new file mode 100644 index 000000000000..8a17130c0544 --- /dev/null +++ b/app-laptop/pbbuttonsd/pbbuttonsd-0.8.1a.ebuild @@ -0,0 +1,137 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 +inherit autotools flag-o-matic + +DESCRIPTION="Handles power management and special keys on laptops" +HOMEPAGE="http://pbbuttons.berlios.de" +SRC_URI="mirror://sourceforge/pbbuttons/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ppc ~x86" +IUSE="acpi alsa doc ibam macbook oss static-libs" + +RDEPEND=" + >=dev-libs/glib-2.6 + alsa? ( >=media-libs/alsa-lib-1.0 ) + macbook? ( + sys-apps/pciutils + sys-libs/libsmbios + ) +" +DEPEND=" + ${RDEPEND} + doc? ( app-doc/doxygen ) +" +PATCHES=( + "${FILESDIR}/${PN}-0.8.1-cpufreq.patch" + "${FILESDIR}/${PN}-0.8.1-fnmode.patch" + "${FILESDIR}/${PN}-0.8.1-laptopmode.sh.patch" + "${FILESDIR}/${PN}-0.8.1-lm.patch" + "${FILESDIR}/${PN}-0.8.1-lz.patch" +) + +src_prepare() { + ### Don't link with g++ if we don't use ibam + if ! use ibam; then + eapply "${FILESDIR}/${PN}-0.8.1-g++.patch" + fi + + default + + eautoconf +} + +src_configure() { + # Fix crash bug on some systems + replace-flags -O? -O1 + + if use macbook; then + laptop=macbook + elif use x86 || use amd64; then + if use acpi; then + laptop=acpi + else + laptop=i386 + fi + # Default to PowerBook + else + laptop=powerbook + fi + + laptop=$laptop \ + econf \ + $(use_with alsa) \ + $(use_with doc doxygen_docs) \ + $(use_with ibam) \ + $(use_with oss) + +} + +src_compile() { + # Thanks to Stefan Bruda for this workaround + # Using -j1 fixes a parallel build issue with the docs + if use doc; then + emake -j1 + else + emake + fi +} + +src_install() { + dodir /etc/power + use ibam && dodir /var/lib/ibam + + default + + use static-libs || rm "${D}"/usr/$(get_libdir)/libpbb.a + + newinitd "${FILESDIR}/pbbuttonsd.rc6" pbbuttonsd + dodoc README + use doc && dodoc -r doc/ + + dodir /etc/power/resume.d + dodir /etc/power/suspend.d + dodir /etc/power/scripts.d + exeinto /etc/power/scripts.d + doexe "${FILESDIR}"/wireless + ln -s "${D}"/etc/power/scripts.d/wireless "${D}"/etc/power/resume.d/wireless +} + +pkg_postinst() { + if [ -e /etc/pbbuttonsd.conf ]; then + ewarn "The pbbuttonsd.cnf file replaces /etc/pbuttonsd.conf with a new" + ewarn "file (/etc/pbbuttonsd.conf) and a new format. Please check the" + ewarn "manual page with 'man pbbuttonsd.cnf' for details." + ewarn + fi + + if use macbook; then + ewarn "Macbook and Macbook Pro users should make sure to have applesmc" + ewarn "loaded before starting pbbuttonsdm otherwise auto-adjustments" + ewarn "will not work and pbbuttonsd may segfault." + ewarn + fi + + ewarn "Ensure that the evdev kernel module is loaded otherwise" + ewarn "pbbuttonsd won't work. SysV IPC is also required." + ewarn + ewarn "If you need extra security, you can tell pbbuttonsd to only accept" + ewarn "input from one user. You can set the userallowed option in" + ewarn "/etc/pbbuttonsd.cnf to limit access." + ewarn + + if use ibam; then + elog "To properly initialize the IBaM battery database, you will" + elog "need to perform a full discharge/charge cycle. For more" + elog "details, please see the pbbuttonsd man page." + elog + fi + + elog "A script is now available to reset your wirless connection on resume." + elog "Simply uncomment the commented command and set the correct device to" + elog "use it. You can find the script in /etc/power/resume.d/wireless" + +} diff --git a/app-laptop/pommed/Manifest b/app-laptop/pommed/Manifest new file mode 100644 index 000000000000..006daec385a9 --- /dev/null +++ b/app-laptop/pommed/Manifest @@ -0,0 +1,8 @@ +AUX pommed-1.39.patch 3024 SHA256 04a19e476daa7bdaeddd4527065c10872eb7add2a30e7ba9e966f542c068586a SHA512 c048643afe0de01a161515963fc11fa330b39cd6304f139ab831032f51e2722d30c7e9b93e1de7d1150283bef570e44772e226f8c13e512d66b1ebe08a7892be WHIRLPOOL 099ae3a39f58db7c71a4968f4e5e54b2c036754d3b07215e4a27cb5742a2ca331ba716b0770fd938b115ed78fcab487646e130d840b15e47c9c90b0171d44269 +AUX pommed.rc 383 SHA256 70453fcc86b854ba415c777261279c33ec2f36e7179d54cdcaa41b02d8f15dc9 SHA512 54c3ee9242ab68f7a162e5892f4b5ee1064328f4b23c9da05f75acdb5c8c93245533af1320b6fa20f026f62060b5a0558eab1215c9c8491086545b7733c6c87b WHIRLPOOL 44b0a8df193d4c6c947eb4ffecc8a98993db7170cad69b76f1fff0a383d57a4d80a5f9d3549ca9d06ba1f835fb016adf1b69e73f71b7af469e8fc70e6cadb6b0 +AUX pommed.service 155 SHA256 251847c346b4802df7a4f2299201e9a2929c1f5e87f3d3ac2ba39363ed392b15 SHA512 00cfd3417ec09cef62e478ac7b5483b1857de2061106c8ae368dbaf0ff5c7b06e974ea85bba411601e76e5bbef53e4ab5b743aa7366c9d717d865a7fd3cd604d WHIRLPOOL 3ac5e6141e7d3b2b3429d20c8565ed4ed04107885cf0b6ec54b68703eb1fe031bfe24baf6bc3460ccfc5815b08027b977eab14bfff2bbe5b2f0d861958a9a49b +DIST pommed-1.39.tar.gz 995020 SHA256 d715cf1f85525a62bb18a3f9ebd229a2f586906ab8c9306fc9d2aa192bf79da2 SHA512 26568e359d8ef853710b1d86f397981e87245a84b2ff006964035ea8643e97df44fe52b01841d085eb8dd1aee586e1c8b60c44089f463e2a64b2b95c010a9d10 WHIRLPOOL cdb214162f87e24f8add4023d126a8a0fe2db0714a29dc43ec844dc4eb8b02edecc6866ba41555fea13881c30e6fb5439c99b452ee5f2240db9969e9504ab298 +EBUILD pommed-1.39-r1.ebuild 2306 SHA256 e99173c475c4888fb6fa4eb1cf1af34972c08d372fc765c7dd46bac6b67d9ac7 SHA512 451d30a5c7b18c5f035cd1d3009d55ff5575616c9195e6977b15ba5762786af10c6dd0081fd36ae887f7320a60ee578d54832da7b8deaea877914aa7a8912a15 WHIRLPOOL 4dab649a1ecadc27dcb15519ce77664c53a799b0f3176a96797a480bba3b070de2d4f92e201d2c191163c0a2caef4466672a428ed1bacc8b2b8398a69d249040 +MISC ChangeLog 2796 SHA256 2b3ca09160a3705188f88bc8aa5488d9815a41e37e6596c4aa6d6b3fcd6abb33 SHA512 13c9210dc60081e4ccbabed7862557d7489b288e0360e1725b52ea20f0136e95ead86c35ac377133e6725897b5e914de7cbe1f805d6d56f41f645f6db824a6d2 WHIRLPOOL d210ecf0fe087fcf21bd7991ec077e7198f94bd6b904034db9acdcefabbb8916c111a24dbbbf8b0f56da36dfa7347c1d0f1e5a179ee5afe069309fce7a00d76c +MISC ChangeLog-2015 9508 SHA256 739c7d6e37ccececebbca61e2c0aafd224ac58da154e34f06d051c55207e6fe2 SHA512 725cb77047e49f55fbe2185ce0b962c2f4ba89097547310ae0a86dcdb233266c2252fe8240844b2207c81634d42db6889cf0b991cb483022f10fccb95ba51218 WHIRLPOOL 0f2766017cd172bdb51a7af8216d9bed6fdadbc39f674c0d7633dc8da20d84be7375abb2b848c450fb6a75ddf7773d6e7eff93b8371ac6dcac064e75faae147a +MISC metadata.xml 644 SHA256 43a9d91f0029aa98b248c65aa6786854c9062a7605f4b664e0843c199ea46318 SHA512 3e31c0588847153aa548d8b09eb5a896f372f6c2c70deb5ac5efbd0f6401877fcf38fb8d04d5cfc718ec228157da86229eefb8101be5bdca0c6e5e540e48aa01 WHIRLPOOL 24e8b792e4c3bb984f6d3a7eed2499dfaf3ff569b283b80ca91b47d8496398d443635ba903be83d1ffaf044ac5c1ac7d08e8a5414517622f0d702cee6966fcef diff --git a/app-laptop/pommed/files/pommed-1.39.patch b/app-laptop/pommed/files/pommed-1.39.patch new file mode 100644 index 000000000000..1215606c35cb --- /dev/null +++ b/app-laptop/pommed/files/pommed-1.39.patch @@ -0,0 +1,89 @@ +diff --git a/gpomme/Makefile b/gpomme/Makefile +index 0874b48..a3ab64a 100644 +--- a/gpomme/Makefile ++++ b/gpomme/Makefile +@@ -1,5 +1,3 @@ +-CC = gcc +- + GTK_CFLAGS = $(shell pkg-config --cflags gtk+-2.0) + GTK_LIBS = $(shell pkg-config --libs gtk+-2.0) + +@@ -14,7 +12,7 @@ CONFUSE_LIBS = $(shell pkg-config libconfuse --libs) + + INOTIFY_CFLAGS = $(shell test -e /usr/include/sys/inotify.h || echo -DNO_SYS_INOTIFY_H) + +-CFLAGS = -g -O2 -Wall $(DBUS_CFLAGS) $(DBUSGLIB_CFLAGS) $(GTK_CFLAGS) $(CONFUSE_CFLAGS) $(INOTIFY_CFLAGS) ++CFLAGS += -Wall $(DBUS_CFLAGS) $(DBUSGLIB_CFLAGS) $(GTK_CFLAGS) $(CONFUSE_CFLAGS) $(INOTIFY_CFLAGS) + LDLIBS = -lpthread -lX11 $(DBUS_LIBS) $(DBUSGLIB_LIBS) $(GTK_LIBS) $(CONFUSE_LIBS) + + SOURCES = gpomme.c theme.c conffile.c \ +@@ -30,6 +28,7 @@ all: gpomme mo + mo: $(MOFILES) + + gpomme: $(OBJS) ++ ${CC} -o $@ ${OBJS} ${LDLIBS} ${LDFLAGS} + + gpomme.o: gpomme.c gpomme.h theme.h ../client-common/dbus-client.h ../client-common/video-client.h + +diff --git a/pommed/Makefile b/pommed/Makefile +index 5f3cbf9..3425a2a 100644 +--- a/pommed/Makefile ++++ b/pommed/Makefile +@@ -1,7 +1,5 @@ + ARCH ?= $(shell uname -m) + +-CC = gcc +- + DBUS_CFLAGS = $(shell pkg-config dbus-1 --cflags) -DDBUS_API_SUBJECT_TO_CHANGE + DBUS_LIBS = $(shell pkg-config dbus-1 --libs) + +@@ -18,7 +16,7 @@ INOTIFY_CFLAGS = $(shell test -e /usr/include/sys/inotify.h || echo -DNO_SYS_INO + + TIMERFD_CFLAGS = $(shell test -e /usr/include/sys/timerfd.h || echo -DNO_SYS_TIMERFD_H) + +-CFLAGS = -g -O2 -Wall $(DBUS_CFLAGS) $(ALSA_CFLAGS) $(AUDIOFILE_CFLAGS) $(CONFUSE_CFLAGS) $(INOTIFY_CFLAGS) $(TIMERFD_CFLAGS) ++CFLAGS += -Wall $(DBUS_CFLAGS) $(ALSA_CFLAGS) $(AUDIOFILE_CFLAGS) $(CONFUSE_CFLAGS) $(INOTIFY_CFLAGS) $(TIMERFD_CFLAGS) + + LDLIBS = -pthread -lrt $(DBUS_LIBS) $(ALSA_LIBS) $(AUDIOFILE_LIBS) $(CONFUSE_LIBS) + +@@ -54,6 +52,7 @@ ifeq ($(LIBPCI_SHARED), true) + + CFLAGS += $(LIBPCI_CFLAGS) + LDLIBS += $(LIBPCI_LIBS) ++ LIBS = $(LIBPCI_LIBS) + else + LIB_OBJS += /usr/lib/libpci.a + LDLIBS += -lz +@@ -73,6 +72,7 @@ OBJS = $(SOURCES:%.c=%.o) + + + pommed: $(OBJS) $(LIB_OBJS) ++ ${CC} -o $@ ${OBJS} ${LDLIBS} ${LDFLAGS} + + pommed.o: pommed.c pommed.h evloop.h kbd_backlight.h lcd_backlight.h cd_eject.h evdev.h conffile.h audio.h dbus.h beep.h + +diff --git a/wmpomme/Makefile b/wmpomme/Makefile +index cc7a438..6c4bee1 100644 +--- a/wmpomme/Makefile ++++ b/wmpomme/Makefile +@@ -1,11 +1,9 @@ +-CC = gcc +- + DBUS_CFLAGS = $(shell pkg-config dbus-1 --cflags) -DDBUS_API_SUBJECT_TO_CHANGE + DBUS_LIBS = $(shell pkg-config dbus-1 --libs) + + TIMERFD_CFLAGS = $(shell test -e /usr/include/sys/timerfd.h || echo -DNO_SYS_TIMERFD_H) + +-CFLAGS = -g -O2 -Wall $(DBUS_CFLAGS) $(TIMERFD_CFLAGS) ++CFLAGS += -Wall $(DBUS_CFLAGS) $(TIMERFD_CFLAGS) + LDLIBS = -lrt -lXpm -lXext -lX11 $(DBUS_LIBS) + + SOURCES = wmgeneral.c wmpomme.c \ +@@ -15,6 +13,7 @@ SOURCES = wmgeneral.c wmpomme.c \ + OBJS = $(SOURCES:%.c=%.o) + + wmpomme: $(OBJS) ++ ${CC} -o $@ ${OBJS} ${LDLIBS} ${LDFLAGS} + + wmpomme.o: wmpomme.c wmgeneral.h wmpomme-master.xpm ../client-common/dbus-client.h + diff --git a/app-laptop/pommed/files/pommed.rc b/app-laptop/pommed/files/pommed.rc new file mode 100644 index 000000000000..23904fc7d3a0 --- /dev/null +++ b/app-laptop/pommed/files/pommed.rc @@ -0,0 +1,19 @@ +#!/sbin/openrc-run +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +depend() { + need dbus alsasound +} + +start() { + ebegin "Running pommed daemon" + start-stop-daemon --start --quiet --exec /usr/bin/pommed + eend $? +} + +stop() { + ebegin "Stopping pommed daemon" + start-stop-daemon --stop --pidfile /var/run/pommed.pid + eend $? +} diff --git a/app-laptop/pommed/files/pommed.service b/app-laptop/pommed/files/pommed.service new file mode 100644 index 000000000000..8407c1db9550 --- /dev/null +++ b/app-laptop/pommed/files/pommed.service @@ -0,0 +1,10 @@ +[Unit] +Description=MacBook Hotkey Event Handler + +[Service] +Type=dbus +BusName=org.pommed +ExecStart=/usr/bin/pommed -f + +[Install] +WantedBy=multi-user.target diff --git a/app-laptop/pommed/metadata.xml b/app-laptop/pommed/metadata.xml new file mode 100644 index 000000000000..03eedeaa5399 --- /dev/null +++ b/app-laptop/pommed/metadata.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<maintainer type="person"> + <email>naota@gentoo.org</email> +</maintainer> +<longdescription> pommed handles the hotkeys found on the Apple MacBook Pro, +MacBook and PowerBook laptops and adjusts the LCD backlight, sound volume, +keyboard backlight or ejects the CD-ROM drive accordingly. +pommed also monitors the ambient light sensors to automatically light up the +keyboard backlight on the MacBook Pro and the latest PowerBook. +Optional support for the Apple Remote control is available.</longdescription> +</pkgmetadata> diff --git a/app-laptop/pommed/pommed-1.39-r1.ebuild b/app-laptop/pommed/pommed-1.39-r1.ebuild new file mode 100644 index 000000000000..e915f399b70d --- /dev/null +++ b/app-laptop/pommed/pommed-1.39-r1.ebuild @@ -0,0 +1,107 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 +inherit eutils toolchain-funcs linux-info systemd + +DESCRIPTION="Manage screen and keyboard backlight on Apple MacBook Pro/PowerBook" +HOMEPAGE="http://technologeek.org/projects/pommed/index.html" +ALIOTH_NUMBER="3583" +SRC_URI="http://alioth.debian.org/frs/download.php/${ALIOTH_NUMBER}/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 ppc x86" +IUSE="gtk X" + +COMMON_DEPEND="media-libs/alsa-lib + x86? ( sys-apps/pciutils ) + amd64? ( sys-apps/pciutils ) + dev-libs/confuse + >=sys-apps/dbus-1.1 + dev-libs/dbus-glib + sys-libs/zlib + media-libs/audiofile + gtk? ( x11-libs/gtk+:2 ) + X? ( x11-libs/libX11 + x11-libs/libXext + x11-libs/libXpm )" +DEPEND="${COMMON_DEPEND} + virtual/pkgconfig" +RDEPEND="${COMMON_DEPEND} + media-sound/alsa-utils + virtual/eject" + +pkg_setup() { + if ! use ppc; then + linux-info_pkg_setup + + CONFIG_CHECK="~DMIID" + check_extra_config + fi +} + +src_prepare() { + epatch "${FILESDIR}/${P}.patch" +} + +src_compile() { + cd "${S}"/pommed + emake CC="$(tc-getCC)" OFLIB=1 || die "emake pommed failed" + + if use gtk; then + cd "${S}"/gpomme + local POFILES="" + for LANG in ${LINGUAS}; do + if [ -f po/${LANG}.po ]; then + POFILES="${POFILES} po/${LANG}.po" + fi + done + emake CC="$(tc-getCC)" POFILES="${POFILES}" || die "emake gpomme failed" + fi + if use X; then + cd "${S}"/wmpomme + emake CC="$(tc-getCC)" || die "emake wmpomme failed" + fi +} + +src_install() { + insinto /etc + if use x86 || use amd64; then + newins pommed.conf.mactel pommed.conf + elif use ppc; then + newins pommed.conf.pmac pommed.conf + fi + + insinto /etc/dbus-1/system.d + newins dbus-policy.conf pommed.conf + + insinto /usr/share/pommed + doins pommed/data/*.wav + + dobin pommed/pommed + + newinitd "${FILESDIR}"/pommed.rc pommed + systemd_dounit "${FILESDIR}"/${PN}.service + + dodoc AUTHORS ChangeLog README TODO + + if use gtk ; then + dobin gpomme/gpomme + for LANG in ${LINGUAS}; do + if [ -f gpomme/po/${LANG}.mo ]; then + einfo "Installing lang ${LANG}" + insinto /usr/share/locale/${LANG}/LC_MESSAGES/ + doins gpomme/po/${LANG}.mo + fi + done + + domenu gpomme/gpomme.desktop gpomme/gpomme-c.desktop + insinto /usr/share/gpomme/ + doins -r gpomme/themes + fi + + if use X ; then + dobin wmpomme/wmpomme + fi +} diff --git a/app-laptop/powerprefs/Manifest b/app-laptop/powerprefs/Manifest new file mode 100644 index 000000000000..1f241da9d293 --- /dev/null +++ b/app-laptop/powerprefs/Manifest @@ -0,0 +1,5 @@ +DIST powerprefs-0.8.0.tar.gz 400749 SHA256 d6c236b933655e5a66a6cbec0db1d7294d0d5a195a0b020dbbf43a121b04fd3a SHA512 79f30fffd9cda707084e7acebd5dca0849dc9ba368ba03d4553c518e2d8d0265c8f5cc4849a8d8d5c8bd8c973320a00bd3d635f36fb94b3373391ceef802ca99 WHIRLPOOL f0a9ec65cf47ee0104e660d8907252328ee0dee4790f0aa781b4e7baeeffccf2d92e769a71dc4668fdf85522705852302ffef033c14e12f0ee39d4bb69af7b9c +EBUILD powerprefs-0.8.0.ebuild 471 SHA256 c410c605cfee9c0b4664b423f89e9932ec56922d07277c9c6e8380c8dc47c3b3 SHA512 6dfe53347b2e3988b33bd7d562a1115ee2b64754f1a693fa59d68ab7624583758d9c0fe4d2fa7731426c38bb12cf8576941cfb7a37f6ba6865c31b976b474ed8 WHIRLPOOL c13c6cc9025ac828398e0392fddcea2c4c0ff54b2e2123471897301aad09d8757d3f689309c3cf5c3152c98a0da766b25facee9934d0cd5a3e49b12648cd1b7c +MISC ChangeLog 2438 SHA256 81aba3203fae7b2a34fae6abe371774ffa59032f9a629b95d9650573c82eee6a SHA512 bcf2bd60e2182d8c367de2c9862c8d3174aff2bd2af9a788e7cb731cebbccf7a3f00583a94b3e14cc9ed7a34631f1b5ce317bfb37ea8053ca3f418f8addd9131 WHIRLPOOL a1097e1764a6f4aec5a159889374559497253f907ee1ec2afeaf1b0fdb11a23a6697ff6016d9b0eea495a377c475d9924fddfb107cbb9c9460eda3970bd02a39 +MISC ChangeLog-2015 4458 SHA256 88b62f187e5cf3d3df88e6ac0b64c6a502d6ff8b9a4d0f0e4f9039b82ea11b32 SHA512 2b508eb42ad640ea3baac6032dcb440b3e86b28c0ca7abd69602d85c853bc67f8cfd67f9e629757e42d0929567ce04bcf6ec75596cc182eea04cd314dbae3572 WHIRLPOOL ed691dde58ccb5b85b76c0ea0ba1a3bdadc493da8bf357d33f60de6ce65f46710f1c38fc9de90985c15293e4fd0bb07f59c36bb374f341e8db37546db9b62081 +MISC metadata.xml 342 SHA256 66f4e1cdfe3b8770b24becb2ab2f75f01a8954f404cac7a06534aac640f0583d SHA512 f9360d2de95be9585a4d28c0fa987ac14ef0db2b81711751e1b31ae5c09cfe66ffdc9e1b65f7656b783ef81e438d30149e8c5b7a8ec5b525509f8c0b2cdbc006 WHIRLPOOL 73892910c1a59caa98b07e20f7b0b0eedb76bafbbb6e851b9197653da6699607c88fb3e0a875e80970b1a88e509cd59c4122892223594ffe7530a909de2b009a diff --git a/app-laptop/powerprefs/metadata.xml b/app-laptop/powerprefs/metadata.xml new file mode 100644 index 000000000000..b2aae2fa3f96 --- /dev/null +++ b/app-laptop/powerprefs/metadata.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>ppc@gentoo.org</email> + <name>Gentoo Linux PowerPC Development</name> + </maintainer> + <upstream> + <remote-id type="sourceforge">pbbuttons</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/powerprefs/powerprefs-0.8.0.ebuild b/app-laptop/powerprefs/powerprefs-0.8.0.ebuild new file mode 100644 index 000000000000..2aa4bb369d7d --- /dev/null +++ b/app-laptop/powerprefs/powerprefs-0.8.0.ebuild @@ -0,0 +1,21 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=2 + +DESCRIPTION="program to interface with pbbuttonsd (Powerbook/iBook) keys" +HOMEPAGE="http://pbbuttons.sf.net" +SRC_URI="mirror://sourceforge/pbbuttons/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ppc ~x86" +IUSE="" + +DEPEND=">=x11-libs/gtk+-2.4:2 + >=app-laptop/pbbuttonsd-0.8.0" + +src_install() { + make DESTDIR="${D}" install || die + dodoc README +} diff --git a/app-laptop/radeontool/Manifest b/app-laptop/radeontool/Manifest new file mode 100644 index 000000000000..74782f921d49 --- /dev/null +++ b/app-laptop/radeontool/Manifest @@ -0,0 +1,5 @@ +DIST radeontool-1.6.3.tar.bz2 367487 SHA256 f73d1ec1a962822e681c2eefa77d9843a02ee0c63196ba0c1181cc1da016a76c SHA512 937ddf3e2b7dc35b9bc872d770b184303ac9e8199c0de6c17d187acfc5c398abc0cec2071c1af5ad16b0df2976418e06db8b1f90775fe59a8a80bdb3f8e2dca6 WHIRLPOOL 59a2542dbe865fa6e834eff2fbab9a05ef768849d575c260add0fc7b374cb084638f471a6df7d7be3c16c4d9223ee775b2eb47e286bf58c8d3ecf1b91e833ab8 +EBUILD radeontool-1.6.3.ebuild 559 SHA256 53f6d9d13aa70ac037a463f1e0edbf59c18b7633f77ddfe831de4932677bb4b0 SHA512 5a3e1d3c3f299032d8df4214cdce746e9e06e212322f44f8368877069c18b005cc88cbd434e1e1414aec967df2339966245b62efe15f95b269560dca2d918e44 WHIRLPOOL 7b6a5e571c66ca5e4b48ee954b47f0b47feb3221b0306f4de115b72cd829a94e55313569f6998ec93a793fe590366730ad1596290f32ef02e550f2c522317865 +MISC ChangeLog 3325 SHA256 3364eb716417bcd0d6007ff3b77d0a7a4e8f12e691328899502174456357e8e6 SHA512 8c312f742e8bfe880fc1993f15ac6e8dd7202b343a6c151ac08cc18d8045ccb463d856b3b54aae9aea8e798f4a581090086caabff4bb9ed93d73cebe0810e45d WHIRLPOOL a55904adcbc93f97ab6a27ad6b7367f28244c4fe5e50ded3684ff2fdbf29d7b527c42cc590f75a4dd07c69971be25735261f976ad07f0442de76aa411458262c +MISC ChangeLog-2015 4559 SHA256 675a9fd937c1d42b293d48affd182cf4ee38e949de1e2f535c6c91371e31ed20 SHA512 027beae329680e5676145a6e12bedf4205568f6ab38c1b2e5266a8bcde8715107f88bc18b38d77c20cb7e70629f386ffbe954340b6018fbf52dd9ccdfe6a7b8c WHIRLPOOL 0ce0122f3017f22df52fdcc4be97ba7376292cc50d3d5b62e18206c0a00f970b491f3ed5f7de013e905bda6eed3d253ccd9f71b8c9cc221c69706505c2a1a04a +MISC metadata.xml 166 SHA256 2caff447f5bd2701d8456ada5cc633c41ef4373fa4bfeabeb73599d40bcc941b SHA512 a56648c974a1d14dd4c18237532773c72057a13ab90c58b5da04f185e3c12a8bd8d5c21fb06053507f31766291a82dc7d87b34cd65fd94cfe2af7295c813ef84 WHIRLPOOL 1ff70497eca6531f0e0614c72a19f4b8e5ff486a58d369f4f0b36308d1d6b01168f9da887740e3b9f536236be251d3fe05f904d27a9233a7cf613416ba882968 diff --git a/app-laptop/radeontool/metadata.xml b/app-laptop/radeontool/metadata.xml new file mode 100644 index 000000000000..6f49eba8f496 --- /dev/null +++ b/app-laptop/radeontool/metadata.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<!-- maintainer-needed --> +</pkgmetadata> diff --git a/app-laptop/radeontool/radeontool-1.6.3.ebuild b/app-laptop/radeontool/radeontool-1.6.3.ebuild new file mode 100644 index 000000000000..edd777f7ac49 --- /dev/null +++ b/app-laptop/radeontool/radeontool-1.6.3.ebuild @@ -0,0 +1,24 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 +inherit eutils toolchain-funcs + +DESCRIPTION="Manage the backlight, external video output and registers of ATI Radeon cards" + +HOMEPAGE="https://cgit.freedesktop.org/~airlied/radeontool/" +SRC_URI="https://people.freedesktop.org/~airlied/${PN}/${P}.tar.bz2" + +LICENSE="ZLIB" +SLOT="0" +KEYWORDS="amd64 ppc x86" + +IUSE="" + +RDEPEND=">=x11-libs/libpciaccess-0.12.0" +DEPEND="${RDEPEND} + virtual/pkgconfig" + +src_install() { + emake install DESTDIR="${D}" +} diff --git a/app-laptop/spicctrl/Manifest b/app-laptop/spicctrl/Manifest new file mode 100644 index 000000000000..a7bd39e1d15c --- /dev/null +++ b/app-laptop/spicctrl/Manifest @@ -0,0 +1,6 @@ +AUX spicctrl-1.9-makefile.patch 284 SHA256 8802a44d110e14e5c6ff9d13d53f14d83c536527fc7072e09ed9580fb6f3080d SHA512 65a4dc464660cb7b157f3fd6c17dbd1ef9a1976525e68b3bbab72fbb389cc1ff98da43a7e332be360727852ffa86bd237ef633f8253cb1a731efa91a99e93913 WHIRLPOOL 36679d30386cd90072a818e3d8d852e78c7febe26db5a059a38dcff074ab177510c598770bcf6ca9debc9452dd25bc0d736a594e0b404990a6da47a460cc7f5b +DIST spicctrl-1.9.tar.bz2 10917 SHA256 88d9795bf51af3496fdce2fec263363ff90929e0e7036f9c117fb2b829353b6b SHA512 7b1d7862a51dd3321fe84cc5921d71a8f0b978755cbd7c31e54a59ad1c9d3f781d649436bd9b7fba71446a593ad7e925470731f5bd135350942fb0c03fbd4d3e WHIRLPOOL 7d852723784dc9797b6f4f58b8d2aba54e2cd4ae70000e3482ed29354a0e2f8165ffc070721a60572d480b17bc4845906e09a4b2161f0b4977dae9322f053f5f +EBUILD spicctrl-1.9-r1.ebuild 538 SHA256 1db06c0010c83d93a5cd82e748e5afc8863e5ef6d29b4331ab15306278b250ed SHA512 346ce1707c6c8baeabcbd89415ad8ce395a501fc5fb3ffe9c5c87b128da7737f9d0d6da28d2f2441142e1b340d693c8a8fc3f52b412caadc6d5149d18f4d5da5 WHIRLPOOL 00ea9aa4286abead9b3b59981a0b31ccb69c194a6e6aa444bf17a20a7795bbbbb0ac492791e017fc3d60a99f41eb615f1e53d6db54143ff8b59ed210dd3d72cf +MISC ChangeLog 2565 SHA256 d423f4d02967950736b528d979c1b01105c1ffe3e74aa0ad237fc461eb15222d SHA512 eb20443c77943a9743818c983122fc42d0ebc93d9a1fbcfc49d2d6032a93a8061731d88809f56a5e625e2b1d962cf9436d39ab18a8bd729846b38e68fb7ed17a WHIRLPOOL fcf37bfe94e398a1b8f072fc583179b93fe62ca5619938dd0b1b2e73ba3a4dff93e60c841312b483c09889c8f6150ebf919e50f9f850cecb942f336a133a2e7c +MISC ChangeLog-2015 2510 SHA256 595fe99e2aa1d79dd41ef0ad6bfe419ffca5f3a93a99a212643981d461e15a62 SHA512 1daf65013386f970e713c51a737ca862352fb8d6a12dce60edd15aba10c9c9e67d9531b6583907c805b0b58a4f2c7b8938b6adf8aaea111d0a00b20e116f9528 WHIRLPOOL e0825820b32db39edd8183964dd96b160fafc64a0fbd1e014b8b76c0a4fcb9566baf5dc923b8f3e3a40b1688c2387abfe926388980a4f2abead942fe446721b8 +MISC metadata.xml 166 SHA256 2caff447f5bd2701d8456ada5cc633c41ef4373fa4bfeabeb73599d40bcc941b SHA512 a56648c974a1d14dd4c18237532773c72057a13ab90c58b5da04f185e3c12a8bd8d5c21fb06053507f31766291a82dc7d87b34cd65fd94cfe2af7295c813ef84 WHIRLPOOL 1ff70497eca6531f0e0614c72a19f4b8e5ff486a58d369f4f0b36308d1d6b01168f9da887740e3b9f536236be251d3fe05f904d27a9233a7cf613416ba882968 diff --git a/app-laptop/spicctrl/files/spicctrl-1.9-makefile.patch b/app-laptop/spicctrl/files/spicctrl-1.9-makefile.patch new file mode 100644 index 000000000000..a49a29c30fb5 --- /dev/null +++ b/app-laptop/spicctrl/files/spicctrl-1.9-makefile.patch @@ -0,0 +1,11 @@ +--- Makefile.orig 2012-11-20 12:38:41.528871594 +0400 ++++ Makefile 2012-11-20 12:39:42.630871103 +0400 +@@ -14,7 +14,7 @@ + all: spicctrl + + spicctrl: $(OBJ) +- $(CC) -o spicctrl $(OBJ) $(LIBS) ++ $(CC) $(CFLAGS) $(LDFLAGS) -o spicctrl $(OBJ) $(LIBS) + + clean: + rm -f $(OBJ) spicctrl *~ diff --git a/app-laptop/spicctrl/metadata.xml b/app-laptop/spicctrl/metadata.xml new file mode 100644 index 000000000000..6f49eba8f496 --- /dev/null +++ b/app-laptop/spicctrl/metadata.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<!-- maintainer-needed --> +</pkgmetadata> diff --git a/app-laptop/spicctrl/spicctrl-1.9-r1.ebuild b/app-laptop/spicctrl/spicctrl-1.9-r1.ebuild new file mode 100644 index 000000000000..d1aceef29615 --- /dev/null +++ b/app-laptop/spicctrl/spicctrl-1.9-r1.ebuild @@ -0,0 +1,28 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=4 + +inherit base toolchain-funcs + +DESCRIPTION="tool for the sonypi-Device (found in Sony Vaio Notebooks)" +HOMEPAGE="http://www.popies.net/sonypi/" +SRC_URI="http://www.popies.net/sonypi/${P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 -ppc x86" +IUSE="" + +DEPEND="" +RDEPEND="" + +PATCHES=( "${FILESDIR}/${P}-makefile.patch" ) + +src_compile() { + emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" +} + +src_install() { + dobin spicctrl +} diff --git a/app-laptop/thinkfan/Manifest b/app-laptop/thinkfan/Manifest new file mode 100644 index 000000000000..07019940e8c5 --- /dev/null +++ b/app-laptop/thinkfan/Manifest @@ -0,0 +1,5 @@ +DIST thinkfan-0.9.3.tar.gz 39527 SHA256 b61c634996c450445d7e440bf41f7adcda86506063f832afa40d44e01061e45b SHA512 d2a29f9cae636c22b66958f8ec50cb60a162d745c3967257bb5e20cc9e152894d4e8a66f897ffa4e49353eba4a42e3499bb9e554719974284089a46cfc6280d7 WHIRLPOOL 3bdbc0ca3731fef85e385b3259cc9ce6bf4c3b15195138caf5b192847bbba411068d00df8e5673600796e15d4d965c116b73745e787bea9f5a68dbbb5ee118db +EBUILD thinkfan-0.9.3.ebuild 1069 SHA256 f9238b914ecbac0d486032c86543acf9f020fb6de726f5e9a21b791096fac266 SHA512 ffec534bfe1c1eb08c1de3858347781d6f0dc349d7f3de39196a47166e65142d649e0e889141e9c90ce193f0f984ac386ce39cc45f6e70ff971278c3b6560247 WHIRLPOOL 57a42743f3766be96f827e2ca1669f180ce3c87f0f67b99f3a705fb7f4e587409934662191551ee874f32e17bc4e14f89134a9927c4da95e568d545074ad9b2e +MISC ChangeLog 2439 SHA256 dfacbf4f5d3244b1da82a1710e0cc4f6298ce5a09988b8b4cf2e604fb001524f SHA512 d98148ecc47beda46bae3d2f97616d942fbdd1413e8d7f6f59bd6c4e6462fbcc4a7e658fc8e404b09f31ba44f8d408af0c68290091466ee25fb2c6c7fbd819dc WHIRLPOOL 81bb797d4bd6748b65318c35bfdc96286cdd5c0059e065c406174a6f6b355fd10b60883c1724b7e122713891907556b2c30df209c882c3a650052580fa08c7f6 +MISC ChangeLog-2015 3245 SHA256 6b2a006ebbfe768467b7d11e3cd2658af8e3a98214bbad18c4e42f4feb6ed201 SHA512 f8d328fcc757a86a238d1385cb7a843e3a673d9e687682e9ee9bacf2acaec468a6e6c0c48402b096bb3106228f67a2d7272f476fce3ca0604b0d296bbcbe34dd WHIRLPOOL ce55dd8cb3a7eb02f5f64d78f0fa9130dbee99b3bd47320aceba5182204075223af80c195f94144875953ee3180010c8479021bd02e4a1721d2e1b4d3d254704 +MISC metadata.xml 419 SHA256 d41324138271055ecfb54118b8235ca745d64b20db567cdd8b4c9d5bb707f598 SHA512 c0979a5886be1a527d7eb45176316320b6c116181f83ade62c6b900a01e6fb6538d738eb081e99dc6f3fd03589e34ac45f5c5da8eebbd33f13d04baa7fd913c8 WHIRLPOOL 0adf12d083fb3ae520cb7a1a121188e56678316cd46ff6e92894a501eaf3960e80a4f96758a497f68e7ff18a1a421a9fc20f9a24fb12ea257f71bfacbb5ef43e diff --git a/app-laptop/thinkfan/metadata.xml b/app-laptop/thinkfan/metadata.xml new file mode 100644 index 000000000000..79dc72426bd0 --- /dev/null +++ b/app-laptop/thinkfan/metadata.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>xmw@gentoo.org</email> + <name>Michael Weber</name> + </maintainer> + <use> + <flag name="atasmart">include libatasmart support to get disc temperature</flag> + </use> + <upstream> + <remote-id type="sourceforge">thinkfan</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/thinkfan/thinkfan-0.9.3.ebuild b/app-laptop/thinkfan/thinkfan-0.9.3.ebuild new file mode 100644 index 000000000000..ca8dc1c15153 --- /dev/null +++ b/app-laptop/thinkfan/thinkfan-0.9.3.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit cmake-utils readme.gentoo-r1 systemd + +DESCRIPTION="simple fan control program for thinkpads" +HOMEPAGE="http://thinkfan.sourceforge.net" +SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="amd64 x86" +IUSE="atasmart" + +DEPEND="atasmart? ( dev-libs/libatasmart )" +RDEPEND="${DEPEND}" + +src_prepare() { + cmake-utils_src_prepare + + sed -e "s:#!/sbin/runscript:#!/sbin/openrc-run:" \ + -i rcscripts/thinkfan.gentoo + + sed -e "s:share/doc/${PN}:share/doc/${PF}:" \ + -e "s:thinkfan.1:src/thinkfan.1:" \ + -i CMakeLists.txt +} + +src_configure() { + local mycmakeargs+=( + "-DCMAKE_BUILD_TYPE:STRING=Debug" + "-DUSE_ATASMART=$(usex atasmart)" + ) + + cmake-utils_src_configure +} + +src_install() { + cmake-utils_src_install + + newinitd rcscripts/${PN}.gentoo ${PN} + systemd_dounit rcscripts/${PN}.service + + readme.gentoo_create_doc +} + +DOC_CONTENTS="Please read the documentation and copy an +appropriate file to /etc/thinkfan.conf." diff --git a/app-laptop/tp_smapi/Manifest b/app-laptop/tp_smapi/Manifest new file mode 100644 index 000000000000..dbeeaa6120dd --- /dev/null +++ b/app-laptop/tp_smapi/Manifest @@ -0,0 +1,7 @@ +AUX tp_smapi-0.40-confd 785 SHA256 3996b08957adea6f14e5a0e394212026dc73e6802a8dcd5aa9a3b413530c3fdb SHA512 a08f0b15ea37f79e1a8b41b3a3a59421dcf26e482d2eaa269e7c3f728c142e68e8c130c8a53f4c14829436a20e1354318464de780d9fbe10777d7929d7944dca WHIRLPOOL 817e851732b828c7e208eabb1371695c787934fa57f1b30ddf9660a4d8b368575eb17775551a9f63144d20d68b23626e96eeab98c9de0b73105d33dbd351f593 +AUX tp_smapi-0.40-initd 1851 SHA256 3feb039b6aa7d4c8589e3d31919c0e465b1ae897cd0d43a7e6eabb89c1ac5dc3 SHA512 ebf8ac628e00979f21e266fb6d187f02bfeeafc9482a0c5bed4fd4f092c7a27158747ccf629c802969ad2a8f13124276ef889927b3f1f01a7ce44fdcde103698 WHIRLPOOL 4be17b42f053af68e95c4fe938f9bee29ab82f980e747e6b6d78deb56296f1a58462f66a6011806b78afca508946dcecacd9d9c37ce7b02e465ea9ad9bd3aec7 +DIST tp_smapi-0.42.tgz 39867 SHA256 7b8d9f488c3859805f1f292bf4d518cc5b32ebb69b0ebe96367d0852dd792d27 SHA512 1004b7ef961a9908c2144b26ea60b6dddabd83d60c11421a03e3b810f5b635415ef52656d6980915512d68f809f7bc3d662328f25d111537bd7e175d252cf83b WHIRLPOOL 7d03aaf2bb4de3aabbc38fba62f126e6f2976ea1964d85da2fffbbcd63bb4c3884a152851cae116438b859c13d59fd4e41be126683f660f9b8322d7fc40ddc28 +EBUILD tp_smapi-0.42-r1.ebuild 1947 SHA256 59ba0f223b524e495531920c14f25f59d810d9f7e0fd7955ed5f3730bbf2f273 SHA512 d09fe01652350951baaaf67af7ce32036515a1535cb9f774d2e0e2f92b0f79163babc3c19c554a37a15b5ddde3bf5a4904e95dfaa74274783911d2c5335fbbef WHIRLPOOL 7f5c20b43ddde11e4c21f23efa668cfd8ae33748baec8e994e6cca5704b99a251bd3ed82e2335db233f1114428ebf884705fbe92c33500bc8c7e0d437acb53a5 +MISC ChangeLog 5140 SHA256 de26e7c672edc9ff7a963b4c725b4be6922212a6f86d4b14fcea3afc960567e5 SHA512 a303fac2b38fe12a22d20d0e5fbeaee8f60b701935a50c649ed7c9ca4a15d277c31f1ed0ebe9d37a040d1baf18ad55960297a4c422fa075c6e85d206bcb03ab9 WHIRLPOOL dad90eb58e2cff369d49867dd3f1a51564a5457960ece752730ec60bf5abaa5faf61dc10f3ee9e56e8dd97b38b05d611530d4ce5be5fbd4a7f781a36d8edd492 +MISC ChangeLog-2015 6791 SHA256 20bf113d3b2f121be58c4b075e8b2316587e2e812c7885c005fcc696de264250 SHA512 38956dab021c8ba903bd11ac9cb4a2edf94363f296b60e134b06cdf4a1edccc9c09d20a23dcde948be5b128bb0f8cebf9f34b5ea6eaa0c587f40d40cea947aa4 WHIRLPOOL ff26b6d6a2deb69cc378ff16fcc8b32592de6ba6589c927b3ffe7a46e48bf97e40f7b5eff0ece35838dac3da6e9617be63b57fae905b4f6156d975383d146b54 +MISC metadata.xml 473 SHA256 4ad788e24f6504854e58ba6efa562fd2235fee205213ddd57424e357e649d73d SHA512 21ce54c4cd204ddea9f1170f8e1b66e636bb2b541856ff541371bd572403519a09cf2367f5642a596684d66145bc9ab92396b102ef51086f2d22f96fc6c0b7af WHIRLPOOL 854979d7994ec70cdb0fe7aa186ba57201f3d0a9e9648f432d67c42515d900cebfe8f970e48bdad74a0f64c308f61e59cdbfae0c8d3ec56fb62c4a6b1de00446 diff --git a/app-laptop/tp_smapi/files/tp_smapi-0.40-confd b/app-laptop/tp_smapi/files/tp_smapi-0.40-confd new file mode 100644 index 000000000000..7c80f35e390b --- /dev/null +++ b/app-laptop/tp_smapi/files/tp_smapi-0.40-confd @@ -0,0 +1,20 @@ +# /etc/conf.d/smapi: config file for /etc/init.d/smapi + +# use '/etc/init.d/smapi info' at any time to check the thresholds +# currently used by the driver +# Note that the kernel does some sanity checking on the values and +# will not accept any combination of values you may try to set up. +# (i.e. stop value lower than start) So if the output of info does +# not match what you wanted the driver probably did not like your +# configuration. + +# default thresholds for '/etc/init.d/smapi start' +SMAPI_THRESH_START="30" +SMAPI_THRESH_STOP="85" +# values to be used for '/etc/init.d/smapi low' +SMAPI_LOW_THRESH_START="${SMAPI_THRESH_START}" +SMAPI_LOW_THRESH_STOP="${SMAPI_THRESH_STOP}" + +# values to be used for '/etc/init.d/smapi high' +SMAPI_HIGH_THRESH_START="95" +SMAPI_HIGH_THRESH_STOP="100" diff --git a/app-laptop/tp_smapi/files/tp_smapi-0.40-initd b/app-laptop/tp_smapi/files/tp_smapi-0.40-initd new file mode 100644 index 000000000000..3b8c10d9274a --- /dev/null +++ b/app-laptop/tp_smapi/files/tp_smapi-0.40-initd @@ -0,0 +1,92 @@ +#!/sbin/openrc-run +# Copyright (C) 2011 Henning Schild <henning@wh9.tu-dresden.de> +# Copyright (C) 2011 Sebastian Pipping <sebastian@pipping.org> +# +# Distributed under the terms of the GNU General Public License, v2 or later + +extra_started_commands="low high info" + +SMAPI_SYSFS="/sys/devices/platform/smapi" +BATS="BAT0 BAT1" + +depend() { + after modules +} + +start() { + local state1 + local state2 + + ebegin "Making sure that module 'tp_smapi' is loaded" + modprobe tp_smapi + state1=$? + eend ${state1} + + ebegin "Checking for \"${SMAPI_SYSFS}\"" + test -d "${SMAPI_SYSFS}" + state2=$? + eend ${state2} + + if [ "${state1}" -ne "0" ] || [ "${state2}" -ne "0" ]; then + return 1 + fi + + ebegin "Starting ${SVCNAME}" + set_all ${SMAPI_THRESH_START} ${SMAPI_THRESH_STOP} + eend $? +} + +stop() { + einfo "Nothing required to be done to stop ${SVCNAME}" +} + +require_started() { + if ! service_started; then + "${RC_SERVICE}" start || return $? + fi +} + +high() { + require_started + + einfo "Switching ${SVCNAME} to high thesholds" + set_all ${SMAPI_HIGH_THRESH_START} ${SMAPI_HIGH_THRESH_STOP} +} + +low() { + require_started + + einfo "Switching ${SVCNAME} to low thesholds" + set_all ${SMAPI_LOW_THRESH_START} ${SMAPI_LOW_THRESH_STOP} +} + +set_all() { + local tstart=$1 + local tstop=$2 + local bat + + for bat in ${BATS}; do + ebegin " setting thresholds for ${bat}: $tstart $tstop" + echo ${tstart} > ${SMAPI_SYSFS}/${bat}/start_charge_thresh + echo ${tstop} > ${SMAPI_SYSFS}/${bat}/stop_charge_thresh + eend $? + done +} + +info() { + local presence + local tstart + local tstop + local bat + + require_started + + for bat in ${BATS}; do + tstart=$(cat ${SMAPI_SYSFS}/${bat}/start_charge_thresh) + tstop=$(cat ${SMAPI_SYSFS}/${bat}/stop_charge_thresh) + if [ "$(cat ${SMAPI_SYSFS}/${bat}/installed)" -eq "1" ]; then + presence=" [installed]" + fi + einfo "${bat}: ${tstart} ${tstop}${presence}" + done +} diff --git a/app-laptop/tp_smapi/metadata.xml b/app-laptop/tp_smapi/metadata.xml new file mode 100644 index 000000000000..2f944f633c24 --- /dev/null +++ b/app-laptop/tp_smapi/metadata.xml @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + + <maintainer type="person"> + <email>mjo@gentoo.org</email> + <name>Michael Orlitzky</name> + </maintainer> + + <use> + <flag name="hdaps">Install a compatible HDAPS module</flag> + </use> + + <upstream> + <remote-id type="github">evgeni/tp_smapi</remote-id> + <remote-id type="sourceforge">tpctl</remote-id> + </upstream> + +</pkgmetadata> diff --git a/app-laptop/tp_smapi/tp_smapi-0.42-r1.ebuild b/app-laptop/tp_smapi/tp_smapi-0.42-r1.ebuild new file mode 100644 index 000000000000..a7aa31518d52 --- /dev/null +++ b/app-laptop/tp_smapi/tp_smapi-0.42-r1.ebuild @@ -0,0 +1,74 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit flag-o-matic linux-mod + +DESCRIPTION="IBM ThinkPad SMAPI BIOS driver" +HOMEPAGE="https://github.com/evgeni/${PN}" +SRC_URI="${HOMEPAGE}/releases/download/tp-smapi/${PV}/${P}.tgz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 x86" + +IUSE="hdaps" + +# We need dmideode if the kernel does not support +# DMI_DEV_TYPE_OEM_STRING in dmi.h. +DEPEND="sys-apps/dmidecode" +RDEPEND="${DEPEND}" + +# This code is factored out of both pkg_pretend() and pkg_setup() +# because the PMS states that ebuilds may not call phase functions +# directly (see the "List of functions" section). This was bug #596616 +# and #596622. +tp_smapi_pkg_pretend() { + linux-mod_pkg_setup + + MODULE_NAMES="thinkpad_ec(extra:) tp_smapi(extra:)" + BUILD_PARAMS="KSRC=${KV_DIR} KBUILD=${KV_OUT_DIR}" + BUILD_TARGETS="default" + + if use hdaps; then + CONFIG_CHECK="~INPUT_UINPUT" + WARNING_INPUT_UINPUT="Your kernel needs uinput for the hdaps module to perform better" + # Why call this twice? + linux-info_pkg_setup + + MODULE_NAMES="${MODULE_NAMES} hdaps(extra:)" + BUILD_PARAMS="${BUILD_PARAMS} HDAPS=1" + + CONFIG_CHECK="~!SENSORS_HDAPS" + ERROR_SENSORS_HDAPS="${P} with USE=hdaps conflicts with in-kernel HDAPS (CONFIG_SENSORS_HDAPS)" + linux-info_pkg_setup + fi +} + +pkg_pretend() { + tp_smapi_pkg_pretend +} + +pkg_setup() { + # run again as pkg_pretend is not var safe + tp_smapi_pkg_pretend +} + +src_compile() { + # Kernel Makefiles may pull in -mpreferred-stack-boundary=3 + # which requires that SSE disabled or compilation will fail. + # So we need to ensure that appended user CLAGS do not re-enable SSE + # https://bugs.gentoo.org/show_bug.cgi?id=492964 + replace-flags '-msse*' '' + replace-flags '-mssse3' '' + + linux-mod_src_compile +} + +src_install() { + linux-mod_src_install + einstalldocs + newinitd "${FILESDIR}/${PN}-0.40-initd" smapi + newconfd "${FILESDIR}/${PN}-0.40-confd" smapi +} diff --git a/app-laptop/tpacpi-bat/Manifest b/app-laptop/tpacpi-bat/Manifest new file mode 100644 index 000000000000..4a4865de211c --- /dev/null +++ b/app-laptop/tpacpi-bat/Manifest @@ -0,0 +1,15 @@ +AUX tpacpi-bat.confd.0 587 SHA256 ff7d489d67ea2a2d95850d53ddb8ecbc846dcc3ae6d5b8e2784aa05c15d79eef SHA512 a2131a32123e649cd5958aea67d4c96a9bd35ba19bc2c5eef794be7f7e386085e0eb825517783999d6da7abd025b004e357daa024f39d71ea6f653b4ed934271 WHIRLPOOL a42d7de2f4a86303663de2c602546e5e6422cb14aae13630fbfec664a476af61eff9b55d1e9857ec65e1e3230cc12433c031a3188098109af4a48985a47ce4e4 +AUX tpacpi-bat.confd.1 668 SHA256 23fbfd271bb0a30c621b620307222efc4eb51f74904f7bae75a9942fe9e899e5 SHA512 570824184f85e9f4b687e67131165671389b836d94f15edbd4bd14c77b0c6546c2991da25bc0172ccdee03cc8c0ad82c378e982e147334e9cb83334d0382038b WHIRLPOOL 7db522f8d08c99f68ba61d46144948b24db889882adf7bea8ccfadc14c1b21b8ce9d6a526a4c611df25e184dee28f3686ecf2eee70ac746916a0c137e7045d04 +AUX tpacpi-bat.initd.1 1498 SHA256 1479b2feb497c3ecbfb29108ac87f90f54852e35fef414d85937ed64defd4ec9 SHA512 1e06d2f4c4356f97c40752d532ea448db9ca39186028bddbe58125fce0e236ed3abd262621c16152b8c44ff24a160c62a51097a37c02dba191403ec71ee005ac WHIRLPOOL 1ca4668c75965029cd9b5b8d1e200a58453259d76916e0e8a2a739d61c090a8cc45023a6f8365b4250957bf0e3bd25141351c71385e758f2a65a124cbee53c5a +AUX tpacpi-bat.initd.2 1488 SHA256 6340632c02ca80a8ab9200decaaa3bdccc81c4641a496c7007d08c2692252c0f SHA512 ccd84bc4cd44ed8a3b2c101501ae220d8add3b189f172e4ba5fe9532ba5a64a188b90054696cc60b7bc1b3d72f636649e4678c020c789933d0b4d25f6ffd386d WHIRLPOOL c9f5eaea7692b4cce06af82e8064b01afe8647e1cae30ba4c75fd877568e6abcd966a500e2bb99410c929bf7c5f03b8cf9b6adcccf3e1659a8d35c4b8a6c3d68 +DIST tpacpi-bat-1.1.tar.gz 17781 SHA256 99bfeae60c672d981ea70a98470b8c2a1a9da52da0fce7f669270f216d2230a3 SHA512 7b8838e6db7f98cd5bb674a99dbb880ba6574529de68d97ce704bf225ba416183971aae3c2dd623bc8750767c54a2a52cd0b525bce70640ecf0b307fdba03821 WHIRLPOOL 3a057e57da77f997ed27f679c2503a139d760949027c02aa5dd5bef71579d525acc866655e0008b59ef6ae8b0c567f7de627838baac5c7ed2969523a7355a879 +DIST tpacpi-bat-2.1.tar.gz 17753 SHA256 0a4b273215ef814a1932b0c8ff1571c6e45eecb3b28d8462deab460f0bcdc337 SHA512 7ed4974d84c3f1ddc9fd5cd6d7f103a11e2f808a223692749e3ae0ec2e888b62083d577214e27634cd76e9b616a6b8d5cb5474ddb64f73972d08641051c5c6f8 WHIRLPOOL 303c28a287b657514e985227b8f4c9c3d044fdf46a7dca0e52ce3ab7b6852a65aa46a8805cf6a945b3936432d3c3e43855d0d88c7549b05e95d271e8c605b1b7 +DIST tpacpi-bat-3.0.tar.gz 18137 SHA256 f9aa8be181df6a7d41eac6224abb6dadf1d147022449e9159c4aa09397b7a485 SHA512 2beab3e5495f028b53d673a4243a2128f4ff85e19e18ac7d53663a1d62e20b271442d6c2c8f19cb41d618ddf7ebb4d9b8390f7f185f77bdca33c69bb19463128 WHIRLPOOL 9329ea83fdd0913cc47446895e6ab385f09ca42e7a19533b5c7fa44cb62bebd07ba24f89b0deacc89d6b3aff3ff826f2a53f8d2e918f137d0f6215aa6eaa9198 +EBUILD tpacpi-bat-1.1-r1.ebuild 795 SHA256 5c5eba430d47eb0ebd06dda2067b866a860d048c6a8ab87077802ca16358db04 SHA512 a0e8169ed9db5d7949ca9a0f8a9076b65fafd20f290dcb93a236fbd25e58a64fcf866dd29a570a2e9662dbc38fe89d2abd1cbf4638e8e21cacf4e940fed06aef WHIRLPOOL fc46a86a5b99091071b7408c7262256569e1c9c636b7cbd030e5bcf8295ff401101fb22fa767ddafdae978c1612a00ca4bde617f5140e2aaf6788d233a46afa9 +EBUILD tpacpi-bat-2.1.ebuild 795 SHA256 5c5eba430d47eb0ebd06dda2067b866a860d048c6a8ab87077802ca16358db04 SHA512 a0e8169ed9db5d7949ca9a0f8a9076b65fafd20f290dcb93a236fbd25e58a64fcf866dd29a570a2e9662dbc38fe89d2abd1cbf4638e8e21cacf4e940fed06aef WHIRLPOOL fc46a86a5b99091071b7408c7262256569e1c9c636b7cbd030e5bcf8295ff401101fb22fa767ddafdae978c1612a00ca4bde617f5140e2aaf6788d233a46afa9 +EBUILD tpacpi-bat-3.0-r1.ebuild 788 SHA256 0706024a5d7b3a76f861d97a9ea28eb311a758bfb5820e22baf7539d4be67715 SHA512 615131330143d13acf30e82552f3addf2a596626be89dfda1bc25afca3c56df48741c501ccc9b40ff4493c24e009c139288dd415e20a0dd82b49c5e6f187f14d WHIRLPOOL 293075d20c4a088dfd35dbfaf756c3ab03e2e1437621acf981f3e89c49bc49bd6874c87b36faf841c276954093bbaa983ca58f8138e7b57dca9bae3550694e37 +EBUILD tpacpi-bat-3.0.ebuild 795 SHA256 5c5eba430d47eb0ebd06dda2067b866a860d048c6a8ab87077802ca16358db04 SHA512 a0e8169ed9db5d7949ca9a0f8a9076b65fafd20f290dcb93a236fbd25e58a64fcf866dd29a570a2e9662dbc38fe89d2abd1cbf4638e8e21cacf4e940fed06aef WHIRLPOOL fc46a86a5b99091071b7408c7262256569e1c9c636b7cbd030e5bcf8295ff401101fb22fa767ddafdae978c1612a00ca4bde617f5140e2aaf6788d233a46afa9 +EBUILD tpacpi-bat-9999.ebuild 789 SHA256 41c10a5388c594406e09d50568dfe83dbcbe6a76cd834dfe19e6a53e24a82a1c SHA512 c9dd392897b43155a1fc58a7a11f69e50856dd23b7810575ab21a6620cc6efc9bfbfeeda2a0d8ba05126ed18655eca4866b8296e696cd39ab7fdc82971f9ccd3 WHIRLPOOL 4a131a0004d390aaddb4fef4408854e07925d26132b9c9453a03dca03232c8a7f0a72f9292f8438c86e81b39b1305c839c82b41b7ae742edd564e58bcf5adc1c +MISC ChangeLog 3555 SHA256 6192dbc1086269f73945754994044dddfd814f285b6be0d3e37f42bfb9caf803 SHA512 e8d37ce3698e5e1c507dedd69769054190f7f13bb4c44107525468604a5adafa97da156941c08a04bb9ecf6ea483b721e01073b9f2eb724e6ab21edca589d045 WHIRLPOOL 17be141073142c530264ccf832426c2eac6588ac8dcb6126ac48631f0252ab14757617e713a19bf5f1393790e77c7f91c0db0c54658a51673471cde0842eb1d1 +MISC ChangeLog-2015 1593 SHA256 f88474311ca487892f3c087caf697007a8e9ad3927b15e1ef4a6ed8b75de3fe0 SHA512 fd577eca1681add680549dece50fb6b8731c84b1e9b9cc107b0447ae53e2484069a573ad2bd0754e838a64f707faf92dc918fd0e0f3293bad6861585468dda11 WHIRLPOOL 9df590046fdb80bff8c50d5efd9fe86260b5be0e8be8cd0ec0df383e7d8094eb85e71342f5f9f15e56058b7cd0766607cf1f39bb119e03ed614bf38f441b1e7b +MISC metadata.xml 338 SHA256 81a7de6a48debfe0ff7eca8e154378672e80098758e8c726f785309c2779107b SHA512 e6cb10546e9a71a1c5fbcea24b4ca97c5eed95e4553d3cd4bbedbf1180da9533a0e570fa674ccf12574825cb369d6197e51969361945958f4322d6cb91e25714 WHIRLPOOL 24da06fd1a79253203d9e0d1dd532b21c738bfc60d9617a5a7075453bfd9996044e5d8707a4d440a4b6d1e66d8fc5afe71dcd16f4561a8ccd627a94782673ffb diff --git a/app-laptop/tpacpi-bat/files/tpacpi-bat.confd.0 b/app-laptop/tpacpi-bat/files/tpacpi-bat.confd.0 new file mode 100644 index 000000000000..94da0a3eb12a --- /dev/null +++ b/app-laptop/tpacpi-bat/files/tpacpi-bat.confd.0 @@ -0,0 +1,15 @@ +# /etc/conf.d/tpacpi-bat: config file for /etc/init.d/tpacpi-bat + +# use '/etc/init.d/tpacpi-bat info' at any time to check the thresholds +# currently used by the driver + +# default thresholds for '/etc/init.d/tpacpi-bat start' +TPACPI_BAT_THRESH_START="30" +TPACPI_BAT_THRESH_STOP="85" +# values to be used for '/etc/init.d/tpacpi-bat low' +TPACPI_BAT_LOW_THRESH_START="${TPACPI_BAT_THRESH_START}" +TPACPI_BAT_LOW_THRESH_STOP="${TPACPI_BAT_THRESH_STOP}" + +# values to be used for '/etc/init.d/tpacpi-bat high' +TPACPI_BAT_HIGH_THRESH_START="95" +TPACPI_BAT_HIGH_THRESH_STOP="99" #see bug #485526 diff --git a/app-laptop/tpacpi-bat/files/tpacpi-bat.confd.1 b/app-laptop/tpacpi-bat/files/tpacpi-bat.confd.1 new file mode 100644 index 000000000000..f1faf1d7fd47 --- /dev/null +++ b/app-laptop/tpacpi-bat/files/tpacpi-bat.confd.1 @@ -0,0 +1,19 @@ +# /etc/conf.d/tpacpi-bat: config file for /etc/init.d/tpacpi-bat + +# use '/etc/init.d/tpacpi-bat info' at any time to check the thresholds +# currently used by the driver + +# list of batteries the script should manage +# for example: BATS="1 2" +BATS="1" + +# default thresholds for '/etc/init.d/tpacpi-bat start' +TPACPI_BAT_THRESH_START="30" +TPACPI_BAT_THRESH_STOP="85" +# values to be used for '/etc/init.d/tpacpi-bat low' +TPACPI_BAT_LOW_THRESH_START="${TPACPI_BAT_THRESH_START}" +TPACPI_BAT_LOW_THRESH_STOP="${TPACPI_BAT_THRESH_STOP}" + +# values to be used for '/etc/init.d/tpacpi-bat high' +TPACPI_BAT_HIGH_THRESH_START="95" +TPACPI_BAT_HIGH_THRESH_STOP="99" #see bug #485526 diff --git a/app-laptop/tpacpi-bat/files/tpacpi-bat.initd.1 b/app-laptop/tpacpi-bat/files/tpacpi-bat.initd.1 new file mode 100644 index 000000000000..d9f5de7fb3dd --- /dev/null +++ b/app-laptop/tpacpi-bat/files/tpacpi-bat.initd.1 @@ -0,0 +1,78 @@ +#!/sbin/openrc-run +# Copyright (C) 2012-2016 Christoph Junghans <junghans@gentoo.org> +# +# Distributed under the terms of the GNU General Public License, v2 or later + +extra_started_commands="low high info" + +BATS="1" + +depend() { + after modules +} + +start() { + local state1 + + ebegin "Making sure that module 'acpi_call' is loaded" + modprobe acpi_call + state1=$? + eend ${state1} + + [ "${state1}" -ne "0" ] && return 1 + + ebegin "Starting ${SVCNAME}" + set_all ${TPACPI_BAT_THRESH_START} ${TPACPI_BAT_THRESH_STOP} + eend $? +} + +stop() { + einfo "Nothing required to be done to stop ${SVCNAME}" +} + +require_started() { + if ! service_started; then + "${RC_SERVICE}" start || return $? + fi +} + +high() { + require_started + + einfo "Switching ${SVCNAME} to high thesholds" + set_all ${TPACPI_BAT_HIGH_THRESH_START} ${TPACPI_BAT_HIGH_THRESH_STOP} +} + +low() { + require_started + + einfo "Switching ${SVCNAME} to low thesholds" + set_all ${TPACPI_BAT_LOW_THRESH_START} ${TPACPI_BAT_LOW_THRESH_STOP} +} + +set_all() { + local tstart=$1 + local tstop=$2 + local bat + + for bat in ${BATS}; do + ebegin " setting thresholds for ${bat}: $tstart $tstop" + /usr/bin/tpacpi-bat -s startThreshold ${bat} ${tstart} + /usr/bin/tpacpi-bat -s stopThreshold ${bat} ${tstop} + eend $? + done +} + +info() { + local tstart + local tstop + local bat + + require_started + + for bat in ${BATS}; do + tstart=$(/usr/bin/tpacpi-bat -g startThreshold ${bat}) + tstop=$(/usr/bin/tpacpi-bat -g stopThreshold ${bat}) + einfo "Battery ${bat}: ${tstart} ${tstop}" + done +} diff --git a/app-laptop/tpacpi-bat/files/tpacpi-bat.initd.2 b/app-laptop/tpacpi-bat/files/tpacpi-bat.initd.2 new file mode 100644 index 000000000000..7c92b739193d --- /dev/null +++ b/app-laptop/tpacpi-bat/files/tpacpi-bat.initd.2 @@ -0,0 +1,76 @@ +#!/sbin/openrc-run +# Copyright (C) 2012-2016 Christoph Junghans <junghans@gentoo.org> +# +# Distributed under the terms of the GNU General Public License, v2 or later + +extra_started_commands="low high info" + +depend() { + after modules +} + +start() { + local state1 + + ebegin "Making sure that module 'acpi_call' is loaded" + modprobe acpi_call + state1=$? + eend ${state1} + + [ "${state1}" -ne "0" ] && return 1 + + ebegin "Starting ${SVCNAME}" + set_all ${TPACPI_BAT_THRESH_START} ${TPACPI_BAT_THRESH_STOP} + eend $? +} + +stop() { + einfo "Nothing required to be done to stop ${SVCNAME}" +} + +require_started() { + if ! service_started; then + "${RC_SERVICE}" start || return $? + fi +} + +high() { + require_started + + einfo "Switching ${SVCNAME} to high thesholds" + set_all ${TPACPI_BAT_HIGH_THRESH_START} ${TPACPI_BAT_HIGH_THRESH_STOP} +} + +low() { + require_started + + einfo "Switching ${SVCNAME} to low thesholds" + set_all ${TPACPI_BAT_LOW_THRESH_START} ${TPACPI_BAT_LOW_THRESH_STOP} +} + +set_all() { + local tstart=$1 + local tstop=$2 + local bat + + for bat in ${BATS}; do + ebegin " setting thresholds for ${bat}: $tstart $tstop" + /usr/bin/tpacpi-bat -s startThreshold ${bat} ${tstart} + /usr/bin/tpacpi-bat -s stopThreshold ${bat} ${tstop} + eend $? + done +} + +info() { + local tstart + local tstop + local bat + + require_started + + for bat in ${BATS}; do + tstart=$(/usr/bin/tpacpi-bat -g startThreshold ${bat}) + tstop=$(/usr/bin/tpacpi-bat -g stopThreshold ${bat}) + einfo "Battery ${bat}: ${tstart} ${tstop}" + done +} diff --git a/app-laptop/tpacpi-bat/metadata.xml b/app-laptop/tpacpi-bat/metadata.xml new file mode 100644 index 000000000000..a50d8d26b076 --- /dev/null +++ b/app-laptop/tpacpi-bat/metadata.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>junghans@gentoo.org</email> + <name>Christoph Junghans</name> + </maintainer> + <upstream> + <remote-id type="github">teleshoes/tpacpi-bat</remote-id> + </upstream> +</pkgmetadata> diff --git a/app-laptop/tpacpi-bat/tpacpi-bat-1.1-r1.ebuild b/app-laptop/tpacpi-bat/tpacpi-bat-1.1-r1.ebuild new file mode 100644 index 000000000000..1560013b9e10 --- /dev/null +++ b/app-laptop/tpacpi-bat/tpacpi-bat-1.1-r1.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +inherit eutils systemd + +if [ "${PV}" = "9999" ]; then + inherit git-2 + EGIT_REPO_URI="https://github.com/teleshoes/tpacpi-bat.git" + KEYWORDS="" +else + SRC_URI="https://github.com/teleshoes/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi +DESCRIPTION="Control battery thresholds of recent ThinkPads, not supported by tp_smapi" +HOMEPAGE="https://github.com/teleshoes/tpacpi-bat" + +LICENSE="GPL-3" +SLOT="0" +IUSE="" + +DEPEND="" +RDEPEND="sys-power/acpi_call + dev-lang/perl" + +src_install() { + dodoc README battery_asl + dobin tpacpi-bat + newinitd "${FILESDIR}"/${PN}.initd.1 ${PN} + newconfd "${FILESDIR}"/${PN}.confd.0 ${PN} + systemd_newunit tpacpi.service ${PN}.service +} diff --git a/app-laptop/tpacpi-bat/tpacpi-bat-2.1.ebuild b/app-laptop/tpacpi-bat/tpacpi-bat-2.1.ebuild new file mode 100644 index 000000000000..1560013b9e10 --- /dev/null +++ b/app-laptop/tpacpi-bat/tpacpi-bat-2.1.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +inherit eutils systemd + +if [ "${PV}" = "9999" ]; then + inherit git-2 + EGIT_REPO_URI="https://github.com/teleshoes/tpacpi-bat.git" + KEYWORDS="" +else + SRC_URI="https://github.com/teleshoes/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi +DESCRIPTION="Control battery thresholds of recent ThinkPads, not supported by tp_smapi" +HOMEPAGE="https://github.com/teleshoes/tpacpi-bat" + +LICENSE="GPL-3" +SLOT="0" +IUSE="" + +DEPEND="" +RDEPEND="sys-power/acpi_call + dev-lang/perl" + +src_install() { + dodoc README battery_asl + dobin tpacpi-bat + newinitd "${FILESDIR}"/${PN}.initd.1 ${PN} + newconfd "${FILESDIR}"/${PN}.confd.0 ${PN} + systemd_newunit tpacpi.service ${PN}.service +} diff --git a/app-laptop/tpacpi-bat/tpacpi-bat-3.0-r1.ebuild b/app-laptop/tpacpi-bat/tpacpi-bat-3.0-r1.ebuild new file mode 100644 index 000000000000..4a1fac9d20b9 --- /dev/null +++ b/app-laptop/tpacpi-bat/tpacpi-bat-3.0-r1.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit systemd + +if [ "${PV}" = "9999" ]; then + inherit git-2 + EGIT_REPO_URI="https://github.com/teleshoes/tpacpi-bat.git" + KEYWORDS="" +else + SRC_URI="https://github.com/teleshoes/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi +DESCRIPTION="Control battery thresholds of recent ThinkPads, not supported by tp_smapi" +HOMEPAGE="https://github.com/teleshoes/tpacpi-bat" + +LICENSE="GPL-3" +SLOT="0" +IUSE="" + +DEPEND="" +RDEPEND="sys-power/acpi_call + dev-lang/perl" + +src_install() { + dodoc README battery_asl + dobin tpacpi-bat + newinitd "${FILESDIR}"/${PN}.initd.2 ${PN} + newconfd "${FILESDIR}"/${PN}.confd.1 ${PN} + systemd_newunit tpacpi.service ${PN}.service +} diff --git a/app-laptop/tpacpi-bat/tpacpi-bat-3.0.ebuild b/app-laptop/tpacpi-bat/tpacpi-bat-3.0.ebuild new file mode 100644 index 000000000000..1560013b9e10 --- /dev/null +++ b/app-laptop/tpacpi-bat/tpacpi-bat-3.0.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +inherit eutils systemd + +if [ "${PV}" = "9999" ]; then + inherit git-2 + EGIT_REPO_URI="https://github.com/teleshoes/tpacpi-bat.git" + KEYWORDS="" +else + SRC_URI="https://github.com/teleshoes/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi +DESCRIPTION="Control battery thresholds of recent ThinkPads, not supported by tp_smapi" +HOMEPAGE="https://github.com/teleshoes/tpacpi-bat" + +LICENSE="GPL-3" +SLOT="0" +IUSE="" + +DEPEND="" +RDEPEND="sys-power/acpi_call + dev-lang/perl" + +src_install() { + dodoc README battery_asl + dobin tpacpi-bat + newinitd "${FILESDIR}"/${PN}.initd.1 ${PN} + newconfd "${FILESDIR}"/${PN}.confd.0 ${PN} + systemd_newunit tpacpi.service ${PN}.service +} diff --git a/app-laptop/tpacpi-bat/tpacpi-bat-9999.ebuild b/app-laptop/tpacpi-bat/tpacpi-bat-9999.ebuild new file mode 100644 index 000000000000..c3feb204bff7 --- /dev/null +++ b/app-laptop/tpacpi-bat/tpacpi-bat-9999.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit systemd + +if [ "${PV}" = "9999" ]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/teleshoes/tpacpi-bat.git" + KEYWORDS="" +else + SRC_URI="https://github.com/teleshoes/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi +DESCRIPTION="Control battery thresholds of recent ThinkPads, not supported by tp_smapi" +HOMEPAGE="https://github.com/teleshoes/tpacpi-bat" + +LICENSE="GPL-3" +SLOT="0" +IUSE="" + +DEPEND="" +RDEPEND="sys-power/acpi_call + dev-lang/perl" + +src_install() { + dodoc README battery_asl + dobin tpacpi-bat + newinitd "${FILESDIR}"/${PN}.initd.2 ${PN} + newconfd "${FILESDIR}"/${PN}.confd.1 ${PN} + systemd_newunit tpacpi.service ${PN}.service +} diff --git a/app-laptop/tpb/Manifest b/app-laptop/tpb/Manifest new file mode 100644 index 000000000000..83fb8396a1ac --- /dev/null +++ b/app-laptop/tpb/Manifest @@ -0,0 +1,7 @@ +AUX tpb-0.6.4-nvram.patch 2321 SHA256 1979ed13e446db8f6cfe3e7af60fe51fd60481888fd73420f53fdd3f4dd82085 SHA512 0e59e3c01805c608738b6539e4cab78d7377b0550c08636b51f4df0ed02d3adb2d391d5e76bdf043a835fb523492dea8c0c7293915f0dc60df357dec4d759457 WHIRLPOOL ddee2555060017d017460a66132b1153f22188b1ceab4e7692a8bcae3aa19db64b70e03d0f3eea4fd3bccbfbb24d571abefa0a4e38d80943cdd5c1b8b10576c7 +AUX tpb-configure-fix.diff 478 SHA256 53baa3169b178737ffc59f108853cf79f78e8bf5ed0612ea3d95fe556cb4a0aa SHA512 461088eb82e66976a6bf591e4bb0de43e76c8aa9e404448d862535a27acb2857fcf3b5830edc6ece650857eb0e1ed24e7366c83d77d2e91b427f96f68928b32a WHIRLPOOL ca675b1025bc6cfda2ac4c9553c90de356d7eb24a2a331dc7fa740eb3bfce9ac77a403efed9f304e9ae814cf0e0e2be5f4f37ad1a1dc630614616ce1c9cd3c85 +DIST tpb-0.6.4.tar.gz 280316 SHA256 9ce4599ff4cb7397a3f49f747ff0225ef32bc6152778e55419f15aaf4cbff32a SHA512 1a12f4231b86bc3da2867670d5800f8f99f347743cf40b229c92485b6fe52e12b0222356d95d071ec26162ac778d2fe40867b4e635701620bc52236dbdb7b76a WHIRLPOOL 3b9fba89561d3c02cb2b36a266d52cba3d08f8305bcc2863b900ca3b8a2c8e5f1705bb1ffd20c03f8d28f531092ac26e2caaac634ad599f4601b9c6171652dfc +EBUILD tpb-0.6.4-r1.ebuild 806 SHA256 79a4099253922c64a17dd41a5f62f48c6c9a64c959ea6ec081d94d2d1b436e03 SHA512 ee233ff77a410ae38578e36787e462580c3fca7d6273c1965cf3da5cc09d84afe1f5f252863de79155235125f5440d6b1b482e632161255b93b0cb23ff848a55 WHIRLPOOL c29b6304c55dc8311dde6281f84abfce881e44dd87802155c1b921aadf90d0bde3dd6f3cfb650c8641c2e483b7b0b0bacfbf80b90d877beb75f7b84f9e85d45d +MISC ChangeLog 2686 SHA256 f27f27d81bd7b58296d8540f27e2eacad54fea6faa77a9319f78ad1241c08cb2 SHA512 5b0f279a9e75b179f249a07c283807a00682bb6856acf8ec067dcb05dbc7470875b893e2d1e6f9a09592a0288d03b7466be3dc0c03fb4daaf1ebe6b1d473f3c9 WHIRLPOOL 8a7c11cac2d04511a2da21547717d88e38aca27c3390150bd3b95f8efff67aa8846f1e3d40d242e4218f44026dd23b517c906ec1b9728212fc2901209d05081a +MISC ChangeLog-2015 3601 SHA256 af99c07d8826e8537d1ac41b74b38f13c5a42de14dec2a60e6d802c8e9d0ee6d SHA512 13fe25e15abb6985036cfbc7a77154349e44507e8324a497ff04194a3f7af5e191434d1c770b074abcc25c76fca229909bedd03b0e18ad3ad1646f6a26ee4786 WHIRLPOOL 10c68ee1b0ac17af40b4027804643b80050ae60e2c7fe1f7d2579d01c60903167095d1c2e42122d4734ba8b0e9bef296c48b690752d5b2f1e1fd36c5e8114d79 +MISC metadata.xml 166 SHA256 2caff447f5bd2701d8456ada5cc633c41ef4373fa4bfeabeb73599d40bcc941b SHA512 a56648c974a1d14dd4c18237532773c72057a13ab90c58b5da04f185e3c12a8bd8d5c21fb06053507f31766291a82dc7d87b34cd65fd94cfe2af7295c813ef84 WHIRLPOOL 1ff70497eca6531f0e0614c72a19f4b8e5ff486a58d369f4f0b36308d1d6b01168f9da887740e3b9f536236be251d3fe05f904d27a9233a7cf613416ba882968 diff --git a/app-laptop/tpb/files/tpb-0.6.4-nvram.patch b/app-laptop/tpb/files/tpb-0.6.4-nvram.patch new file mode 100644 index 000000000000..1ead9cbe5929 --- /dev/null +++ b/app-laptop/tpb/files/tpb-0.6.4-nvram.patch @@ -0,0 +1,34 @@ +diff -Naur tpb-0.6.4-org/src/tpb.c tpb-0.6.4/src/tpb.c +--- tpb-0.6.4-org/src/tpb.c 2005-07-18 16:15:59.000000000 +0200 ++++ tpb-0.6.4/src/tpb.c 2008-05-13 15:15:34.000000000 +0200 +@@ -523,10 +523,10 @@ + /* determine the state of the brightness buttons {{{ */ + if(thinkpad_state.brightness_level != last_thinkpad_state.brightness_level) { + if(cfg.verbose == STATE_ON) { +- printf(_("Brightness changed: Level %d\n"), thinkpad_state.brightness_level * 100 / 7); ++ printf(_("Brightness changed: Level %d\n"), thinkpad_state.brightness_level * 100 / 15); + } + if(cfg.callback != NULL) { +- snprintf(callback_cmd, sizeof(callback_cmd), "%s brightness %d", cfg.callback, thinkpad_state.brightness_level * 100 / 7); ++ snprintf(callback_cmd, sizeof(callback_cmd), "%s brightness %d", cfg.callback, thinkpad_state.brightness_level * 100 / 15); + if(fork_app(callback_cmd) != 0) { + _exit(0); + } +@@ -537,7 +537,7 @@ + if(osd_ptr != NULL && + ((cfg.osd == STATE_OFF && cfg.osdbrightness == STATE_ON) || (cfg.osd == STATE_ON && cfg.osdbrightness != STATE_OFF))) { + xosd_display(osd_ptr, 0, XOSD_string, _("Brightness")); +- xosd_display(osd_ptr, 1, XOSD_percentage, thinkpad_state.brightness_level * 100 / 7); ++ xosd_display(osd_ptr, 1, XOSD_percentage, thinkpad_state.brightness_level * 100 / 15); + } + } + #endif /* HAVE_LIBXOSD */ /* }}} */ +@@ -1031,7 +1031,7 @@ + thinkpad_state->hibernate_toggle = (thinkpad_state->hibernate_toggle & ~0x01) | (( buffer[0x58] & 0x01) ); + thinkpad_state->display_state = (( buffer[0x59] & 0x03) ); + thinkpad_state->expand_toggle = (thinkpad_state->expand_toggle & ~0x01) | (( buffer[0x59] & 0x10) >> 4); +- thinkpad_state->brightness_level = (( buffer[0x5E] & 0x07) ); ++ thinkpad_state->brightness_level = (( buffer[0x5E] & 0x0F) ); + thinkpad_state->brightness_toggle = (thinkpad_state->brightness_toggle & ~0x01) | (( buffer[0x5E] & 0x20) >> 5); + thinkpad_state->volume_level = (( buffer[0x60] & 0x0f) ); + thinkpad_state->volume_toggle = (thinkpad_state->volume_toggle & ~0x01) | (( buffer[0x60] & 0x80) >> 7); diff --git a/app-laptop/tpb/files/tpb-configure-fix.diff b/app-laptop/tpb/files/tpb-configure-fix.diff new file mode 100644 index 000000000000..7dc4683d158b --- /dev/null +++ b/app-laptop/tpb/files/tpb-configure-fix.diff @@ -0,0 +1,16 @@ +diff -aur tpb-0.5.1/configure tpb-0.5.1-patched/configure +--- tpb-0.5.1/configure 2003-04-10 04:06:26.000000000 -0400 ++++ tpb-0.5.1-patched/configure 2003-06-30 12:06:41.000000000 -0400 +@@ -790,10 +790,10 @@ + + # additional options + # Check whether --enable-xosd or --disable-xosd was given. +-if test "${enable_xosd+set}" = set; then +- enableval="$enable_xosd" ++if test "x${enable_xosd}" = xno; then + enable_xosd=no + else ++ enableval="$enable_xosd" + enable_xosd=yes + fi + diff --git a/app-laptop/tpb/metadata.xml b/app-laptop/tpb/metadata.xml new file mode 100644 index 000000000000..6f49eba8f496 --- /dev/null +++ b/app-laptop/tpb/metadata.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<!-- maintainer-needed --> +</pkgmetadata> diff --git a/app-laptop/tpb/tpb-0.6.4-r1.ebuild b/app-laptop/tpb/tpb-0.6.4-r1.ebuild new file mode 100644 index 000000000000..f8bff7aa3280 --- /dev/null +++ b/app-laptop/tpb/tpb-0.6.4-r1.ebuild @@ -0,0 +1,38 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 +inherit linux-info eutils + +DESCRIPTION="IBM ThinkPad buttons utility" +HOMEPAGE="https://savannah.nongnu.org/projects/tpb/" +SRC_URI="https://savannah.nongnu.org/download/tpb/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 -ppc x86" +IUSE="nls xosd" + +RDEPEND="x11-libs/libXt + x11-libs/libXext + xosd? ( >=x11-libs/xosd-2.2.0 )" +DEPEND="${RDEPEND}" + +CONFIG_CHECK="~NVRAM" +ERROR_NVRAM="${P} requires /dev/nvram support (CONFIG_NVRAM)" + +src_prepare() { + epatch "${FILESDIR}"/${PN}-configure-fix.diff + epatch "${FILESDIR}"/${P}-nvram.patch +} + +src_configure() { + econf \ + $(use_enable nls) \ + $(use_enable xosd) +} + +src_install() { + default + dodoc doc/{callback_example.sh,nvram.txt,tpbrc} +} |