Lines 3-14
Link Here
|
3 |
# $Header: /var/cvsroot/gentoo-x86/x11-misc/redshift/redshift-1.7-r1.ebuild,v 1.5 2012/08/16 20:40:38 hasufell Exp $ |
3 |
# $Header: /var/cvsroot/gentoo-x86/x11-misc/redshift/redshift-1.7-r1.ebuild,v 1.5 2012/08/16 20:40:38 hasufell Exp $ |
4 |
|
4 |
|
5 |
EAPI=4 |
5 |
EAPI=4 |
|
|
6 |
PYTHON_COMPAT=( python{2_6,2_7} ) |
6 |
|
7 |
|
7 |
PYTHON_DEPEND="gtk? 2:2.6" |
8 |
inherit autotools eutils gnome2-utils python-r1 |
8 |
SUPPORT_PYTHON_ABIS="1" |
|
|
9 |
RESTRICT_PYTHON_ABIS="2.[45] 3.*" |
10 |
|
11 |
inherit autotools eutils gnome2-utils python |
12 |
|
9 |
|
13 |
DESCRIPTION="A screen color temperature adjusting software" |
10 |
DESCRIPTION="A screen color temperature adjusting software" |
14 |
HOMEPAGE="http://jonls.dk/redshift/" |
11 |
HOMEPAGE="http://jonls.dk/redshift/" |
Lines 24-30
COMMON_DEPEND=">=x11-libs/libX11-1.4
Link Here
|
24 |
x11-libs/libxcb |
21 |
x11-libs/libxcb |
25 |
geoclue? ( app-misc/geoclue ) |
22 |
geoclue? ( app-misc/geoclue ) |
26 |
gnome? ( dev-libs/glib:2 |
23 |
gnome? ( dev-libs/glib:2 |
27 |
>=gnome-base/gconf-2 )" |
24 |
>=gnome-base/gconf-2 ) |
|
|
25 |
gtk? ( ${PYTHON_DEPS} )" |
28 |
RDEPEND="${COMMON_DEPEND} |
26 |
RDEPEND="${COMMON_DEPEND} |
29 |
gtk? ( >=dev-python/pygtk-2 |
27 |
gtk? ( >=dev-python/pygtk-2 |
30 |
dev-python/pyxdg )" |
28 |
dev-python/pyxdg )" |
Lines 32-43
DEPEND="${COMMON_DEPEND}
Link Here
|
32 |
nls? ( sys-devel/gettext )" |
30 |
nls? ( sys-devel/gettext )" |
33 |
|
31 |
|
34 |
src_prepare() { |
32 |
src_prepare() { |
35 |
>py-compile |
|
|
36 |
epatch "${FILESDIR}"/${P}-make-conditionals.patch |
33 |
epatch "${FILESDIR}"/${P}-make-conditionals.patch |
|
|
34 |
epatch_user |
37 |
eautoreconf |
35 |
eautoreconf |
38 |
} |
36 |
} |
39 |
|
37 |
|
40 |
src_configure() { |
38 |
src_configure() { |
|
|
39 |
python_export_best |
40 |
|
41 |
econf \ |
41 |
econf \ |
42 |
--disable-silent-rules \ |
42 |
--disable-silent-rules \ |
43 |
$(use_enable nls) \ |
43 |
$(use_enable nls) \ |
Lines 53-69
src_configure() {
Link Here
|
53 |
src_install() { |
53 |
src_install() { |
54 |
default |
54 |
default |
55 |
|
55 |
|
56 |
# handle multiple python abi support |
56 |
if use gtk; then |
57 |
per_abi_install() { |
57 |
python_foreach_impl \ |
58 |
cp "${D}"/usr/bin/gtk-redshift "${D}"/usr/bin/gtk-redshift-${PYTHON_ABI} || die |
58 |
emake DESTDIR="${D}" pythondir="$(python_get_sitedir)" \ |
59 |
python_convert_shebangs ${PYTHON_ABI} "${D}"/usr/bin/gtk-redshift-${PYTHON_ABI} |
59 |
-C src/gtk-redshift install |
60 |
emake DESTDIR="${D}" pythondir="$(python_get_sitedir)" -C src/gtk-redshift install |
|
|
61 |
} |
62 |
|
60 |
|
63 |
if use gtk ; then |
61 |
python_replicate_scripts "${D}"/usr/bin/gtk-redshift |
64 |
rm -R "${D}"/usr/$(get_libdir)/python* || die |
|
|
65 |
python_execute_function per_abi_install |
66 |
python_generate_wrapper_scripts -f "${D}"/usr/bin/gtk-redshift |
67 |
fi |
62 |
fi |
68 |
} |
63 |
} |
69 |
|
64 |
|
Lines 72-80
pkg_preinst() {
Link Here
|
72 |
} |
67 |
} |
73 |
|
68 |
|
74 |
pkg_postinst() { |
69 |
pkg_postinst() { |
75 |
use gtk && { gnome2_icon_cache_update; python_mod_optimize gtk_${PN}; } |
70 |
use gtk && gnome2_icon_cache_update |
76 |
} |
71 |
} |
77 |
|
72 |
|
78 |
pkg_postrm() { |
73 |
pkg_postrm() { |
79 |
use gtk && { gnome2_icon_cache_update; python_mod_cleanup gtk_${PN}; } |
74 |
use gtk && gnome2_icon_cache_update |
80 |
} |
75 |
} |
81 |
- |
|
|