Gentoo Archives: gentoo-commits

From: Thomas Deutschmann <whissi@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-laptop/thinkfan/, app-laptop/thinkfan/files/
Date: Sat, 19 Jan 2019 05:05:07
Message-Id: 1547874159.9001858ce0bae3908a65f4090c909fb99be6c5f7.whissi@gentoo
1 commit: 9001858ce0bae3908a65f4090c909fb99be6c5f7
2 Author: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
3 AuthorDate: Sat Jan 19 05:01:39 2019 +0000
4 Commit: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
5 CommitDate: Sat Jan 19 05:02:39 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9001858c
7
8 app-laptop/thinkfan: bump to v1.0.1
9
10 - fix DOCDIR
11
12 - modernize OpenRC runscript
13
14 Package-Manager: Portage-2.3.56, Repoman-2.3.12
15 Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>
16
17 app-laptop/thinkfan/Manifest | 2 +-
18 .../files/thinkfan-1.0.1-update-runscript.patch | 39 ++++++++++++++++++++++
19 .../{thinkfan-1.0.ebuild => thinkfan-1.0.1.ebuild} | 17 +++++-----
20 3 files changed, 48 insertions(+), 10 deletions(-)
21
22 diff --git a/app-laptop/thinkfan/Manifest b/app-laptop/thinkfan/Manifest
23 index 0df01627822..444109d9dde 100644
24 --- a/app-laptop/thinkfan/Manifest
25 +++ b/app-laptop/thinkfan/Manifest
26 @@ -1,2 +1,2 @@
27 DIST thinkfan-0.9.3.tar.gz 39527 BLAKE2B e6a6d09493d94b4de9ada20dcc4b0251c5f2c148f7faa7f69c04fe2a279a9cfe253a0ea1a01fe94ed108e8731e2ba01edef5df10dfb887ea961a356dff733854 SHA512 d2a29f9cae636c22b66958f8ec50cb60a162d745c3967257bb5e20cc9e152894d4e8a66f897ffa4e49353eba4a42e3499bb9e554719974284089a46cfc6280d7
28 -DIST thinkfan-1.0.tar.gz 77575 BLAKE2B cc4dfec48d2797079b053b0be923a008b2e740179de10bda549194008a83ce9ea47fdb23e82f0050fa594be81fa07b242b548303fff751845da544f1f8fdd226 SHA512 c85c8a4f3eb2735f065bf56312823a13277b803e4762a325bd250a47f1e35e1efbc45fa63bcd3b2e24184d6f95a9f8d7ceb1b31eb82c674ca2f2f8d57ee0ea30
29 +DIST thinkfan-1.0.1.tar.gz 77587 BLAKE2B 7a2d4d77be8a9abdafe2cdb8485c92dfe9850ad2309d45d0ac32e8c0e7e6db22ef6c2e16161cccbd6e6147497accc8ec3f5d4467dbe5d2fe6d7fdfd06bb3261f SHA512 61fac9e99f5a2974c5a80e2565956d203baf670dc4b97625389e91fe3fe4d026c07847c10e7d46a4f57914a8156aeea0141570202c0ce2b497f8a1daefa47d6e
30
31 diff --git a/app-laptop/thinkfan/files/thinkfan-1.0.1-update-runscript.patch b/app-laptop/thinkfan/files/thinkfan-1.0.1-update-runscript.patch
32 new file mode 100644
33 index 00000000000..a0896af3d26
34 --- /dev/null
35 +++ b/app-laptop/thinkfan/files/thinkfan-1.0.1-update-runscript.patch
36 @@ -0,0 +1,39 @@
37 +https://github.com/vmatare/thinkfan/pull/61
38 +
39 +--- a/rcscripts/openrc/thinkfan.cmake
40 ++++ b/rcscripts/openrc/thinkfan.cmake
41 +@@ -1,26 +1,19 @@
42 + #!/sbin/openrc-run
43 +
44 ++command="@CMAKE_INSTALL_PREFIX@/sbin/thinkfan"
45 ++command_args="-q -s5 -c /etc/thinkfan.conf"
46 ++pidfile="@PID_FILE@"
47 ++
48 + extra_started_commands="reload"
49 +
50 ++required_files="/etc/thinkfan.conf"
51 ++
52 + depend() {
53 + after modules
54 + }
55 +
56 +-start() {
57 +- ebegin "Starting thinkfan"
58 +- start-stop-daemon --start --exec @CMAKE_INSTALL_PREFIX@/sbin/thinkfan -- -q -s5 -c /etc/thinkfan.conf
59 +- eend $?
60 +-}
61 +-
62 +-stop() {
63 +- ebegin "Stopping thinkfan"
64 +- start-stop-daemon --stop --exec @CMAKE_INSTALL_PREFIX@/sbin/thinkfan
65 +- eend $?
66 +-}
67 +-
68 + reload() {
69 +- PID=$(<@PID_FILE@)
70 +- ebegin "Sending SIGHUP to thinkfan($PID)"
71 +- kill -HUP $PID
72 ++ ebegin "Reloading ${SVCNAME}"
73 ++ start-stop-daemon --signal HUP --pidfile "${pidfile}"
74 + eend $?
75 + }
76
77 diff --git a/app-laptop/thinkfan/thinkfan-1.0.ebuild b/app-laptop/thinkfan/thinkfan-1.0.1.ebuild
78 similarity index 73%
79 rename from app-laptop/thinkfan/thinkfan-1.0.ebuild
80 rename to app-laptop/thinkfan/thinkfan-1.0.1.ebuild
81 index d114b72afb1..e7e7da5f821 100644
82 --- a/app-laptop/thinkfan/thinkfan-1.0.ebuild
83 +++ b/app-laptop/thinkfan/thinkfan-1.0.1.ebuild
84 @@ -1,4 +1,4 @@
85 -# Copyright 1999-2017 Gentoo Foundation
86 +# Copyright 1999-2019 Gentoo Authors
87 # Distributed under the terms of the GNU General Public License v2
88
89 EAPI=6
90 @@ -19,15 +19,16 @@ DEPEND="atasmart? ( dev-libs/libatasmart )
91 RDEPEND="${DEPEND}
92 nvidia? ( x11-drivers/nvidia-drivers )"
93
94 -src_prepare() {
95 - cmake-utils_src_prepare
96 +PATCHES=( "${FILESDIR}"/${PN}-1.0.1-update-runscript.patch )
97
98 - sed -e "s:share/doc/${PN}:share/doc/${PF}:" \
99 - -i CMakeLists.txt || die "sed failed"
100 -}
101 +DOC_CONTENTS="
102 + Please read the documentation and copy an appropriate
103 + file to /etc/thinkfan.conf.
104 +"
105
106 src_configure() {
107 local mycmakeargs+=(
108 + -DCMAKE_INSTALL_DOCDIR=/usr/share/doc/${PF}
109 -DUSE_NVML="$(usex nvidia)"
110 -DUSE_ATASMART="$(usex atasmart)"
111 -DUSE_YAML="$(usex yaml)"
112 @@ -38,8 +39,6 @@ src_configure() {
113
114 src_install() {
115 cmake-utils_src_install
116 +
117 readme.gentoo_create_doc
118 }
119 -
120 -DOC_CONTENTS="Please read the documentation and copy an
121 -appropriate file to /etc/thinkfan.conf."