diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /app-laptop/i8kutils |
reinit the tree, so we can have metadata
Diffstat (limited to 'app-laptop/i8kutils')
-rw-r--r-- | app-laptop/i8kutils/Manifest | 12 | ||||
-rw-r--r-- | app-laptop/i8kutils/files/i8k.conf | 31 | ||||
-rw-r--r-- | app-laptop/i8kutils/files/i8k.init-r1 | 50 | ||||
-rw-r--r-- | app-laptop/i8kutils/files/i8kmon.service | 9 | ||||
-rw-r--r-- | app-laptop/i8kutils/files/i8kutils-1.42-Makefile.patch | 34 | ||||
-rw-r--r-- | app-laptop/i8kutils/files/i8kutils-gcc5.patch | 28 | ||||
-rw-r--r-- | app-laptop/i8kutils/i8kutils-1.33-r1.ebuild | 54 | ||||
-rw-r--r-- | app-laptop/i8kutils/i8kutils-1.42.ebuild | 52 | ||||
-rw-r--r-- | app-laptop/i8kutils/metadata.xml | 16 |
9 files changed, 286 insertions, 0 deletions
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> |