Line 0
Link Here
|
0 |
- |
1 |
# Copyright 1999-2015 Gentoo Foundation |
|
|
2 |
# Distributed under the terms of the GNU General Public License v2 |
3 |
|
4 |
EAPI=6 |
5 |
|
6 |
PYTHON_COMPAT=( python2_7 ) |
7 |
inherit distutils-r1 linux-info systemd |
8 |
|
9 |
MY_P="${PN}-${PN}-25dbdaf40529c9d3efdc6d5773ae6a8e714e3aec" |
10 |
|
11 |
DESCRIPTION="Computes ambient brightness and sets screen's correct backlight using a webcam" |
12 |
HOMEPAGE="http://calise.sourceforge.net/" |
13 |
SRC_URI="https://sourceforge.net/code-snapshots/git/c/ca/${PN}/${PN}.git/${MY_P}.zip" |
14 |
|
15 |
LICENSE="GPL-3" |
16 |
SLOT="0" |
17 |
KEYWORDS="~amd64 ~x86" |
18 |
IUSE="" |
19 |
|
20 |
RDEPEND="dev-python/pyxdg[${PYTHON_USEDEP}] |
21 |
dev-python/dbus-python[${PYTHON_USEDEP}] |
22 |
dev-python/pygobject:2[${PYTHON_USEDEP}] |
23 |
sci-astronomy/pyephem[${PYTHON_USEDEP}]" |
24 |
DEPEND="${RDEPEND} |
25 |
dev-python/python-distutils-extra[${PYTHON_USEDEP}] |
26 |
dev-util/intltool |
27 |
sys-kernel/linux-headers |
28 |
x11-libs/libX11" |
29 |
|
30 |
CONFIG_CHECK="~BACKLIGHT_CLASS_DEVICE" |
31 |
|
32 |
S="${WORKDIR}/${MY_P}" |
33 |
|
34 |
src_prepare() { |
35 |
default |
36 |
|
37 |
# Add missing trailing ; to desktop file. |
38 |
sed -i 's/^\(Categories=Utility\)$/\1;/' \ |
39 |
share/applications/calise.desktop.in || die |
40 |
|
41 |
# Fix up bashisms. |
42 |
sed -i 's:&>/dev/null:2>\&1 >/dev/null:' \ |
43 |
other/init_scripts/init.d/${PN}d || die |
44 |
} |
45 |
|
46 |
src_install() { |
47 |
distutils-r1_src_install |
48 |
|
49 |
doconfd other/init_scripts/conf.d/${PN}d |
50 |
doinitd other/init_scripts/init.d/${PN}d |
51 |
systemd_dounit other/systemd_scripts/${PN}d.service |
52 |
|
53 |
install -D -m755 other/pm-utils_scripts/53${PN}d "${D}"/usr/lib/pm-utils/sleep.d/53${PN}d |
54 |
} |
55 |
|
56 |
pkg_postinst() { |
57 |
einfo "Optional runtime dependency: dev-python/PyQt4 for GUI" |
58 |
} |