blob: ae16f20aee498a1d8f85ac545423aead83cd9a81 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
EAPI=5
inherit 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="examples tk"
DEPEND="tk? ( dev-lang/tk:0 )"
RDEPEND="${DEPEND}
sys-power/acpi"
S="${WORKDIR}/${PN}"
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 i8kctl i8kfan
doman i8kctl.1
use examples && dodoc -r examples
newinitd "${FILESDIR}"/i8k.init-r1 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
}
|