Lines 3-13
Link Here
|
3 |
# $Header: /var/cvsroot/gentoo-x86/sys-libs/libcap-ng/libcap-ng-0.7.3.ebuild,v 1.4 2013/02/20 23:32:06 zmedico Exp $ |
3 |
# $Header: /var/cvsroot/gentoo-x86/sys-libs/libcap-ng/libcap-ng-0.7.3.ebuild,v 1.4 2013/02/20 23:32:06 zmedico Exp $ |
4 |
|
4 |
|
5 |
EAPI=5 |
5 |
EAPI=5 |
|
|
6 |
PYTHON_COMPAT=( python{2_5,2_6,2_7,3_1,3_2,3_3} ) |
6 |
|
7 |
|
7 |
SUPPORT_PYTHON_ABIS="1" |
8 |
inherit autotools eutils flag-o-matic python-r1 |
8 |
RESTRICT_PYTHON_ABIS="*-jython *-pypy-*" |
|
|
9 |
|
10 |
inherit autotools flag-o-matic python |
11 |
|
9 |
|
12 |
DESCRIPTION="POSIX 1003.1e capabilities" |
10 |
DESCRIPTION="POSIX 1003.1e capabilities" |
13 |
HOMEPAGE="http://people.redhat.com/sgrubb/libcap-ng/" |
11 |
HOMEPAGE="http://people.redhat.com/sgrubb/libcap-ng/" |
Lines 18-34
SLOT="0"
Link Here
|
18 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~arm-linux ~x86-linux" |
16 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~arm-linux ~x86-linux" |
19 |
IUSE="python static-libs" |
17 |
IUSE="python static-libs" |
20 |
|
18 |
|
21 |
RDEPEND="python? ( dev-lang/python )" |
19 |
RDEPEND="python? ( ${PYTHON_DEPS} )" |
22 |
DEPEND="${RDEPEND} |
20 |
DEPEND="${RDEPEND} |
23 |
sys-kernel/linux-headers |
21 |
sys-kernel/linux-headers |
24 |
python? ( >=dev-lang/swig-2 )" |
22 |
python? ( >=dev-lang/swig-2 )" |
25 |
|
23 |
|
26 |
PYTHON_CFLAGS=("2.* + -fno-strict-aliasing") |
|
|
27 |
|
28 |
pkg_setup() { |
29 |
use python && python_pkg_setup |
30 |
} |
31 |
|
32 |
src_prepare() { |
24 |
src_prepare() { |
33 |
# Disable byte-compilation of Python modules. |
25 |
# Disable byte-compilation of Python modules. |
34 |
>py-compile |
26 |
>py-compile |
Lines 52-67
src_compile() {
Link Here
|
52 |
default |
44 |
default |
53 |
|
45 |
|
54 |
if use python; then |
46 |
if use python; then |
55 |
python_copy_sources bindings/python |
47 |
S=bindings/python python_copy_sources |
56 |
|
48 |
|
57 |
building() { |
49 |
building() { |
|
|
50 |
if [[ ${EPYTHON} = python2.* ]]; then |
51 |
local CFLAGS="${CFLAGS}" |
52 |
append-cflags -fno-strict-aliasing |
53 |
fi |
58 |
emake \ |
54 |
emake \ |
59 |
CFLAGS="${CFLAGS}" \ |
55 |
CFLAGS="${CFLAGS}" \ |
60 |
PYTHON_VERSION="$(python_get_version)" \ |
56 |
PYTHON="${PYTHON}" \ |
|
|
57 |
PYTHON_VERSION="${EPYTHON#python}" \ |
61 |
pyexecdir="$(python_get_sitedir)" \ |
58 |
pyexecdir="$(python_get_sitedir)" \ |
62 |
pythondir="$(python_get_sitedir)" |
59 |
pythondir="$(python_get_sitedir)" |
63 |
} |
60 |
} |
64 |
python_execute_function -s --source-dir bindings/python building |
61 |
BUILD_DIR=bindings/python \ |
|
|
62 |
python_parallel_foreach_impl run_in_build_dir building |
65 |
fi |
63 |
fi |
66 |
} |
64 |
} |
67 |
|
65 |
|
Lines 76-88
src_test() {
Link Here
|
76 |
if use python; then |
74 |
if use python; then |
77 |
testing() { |
75 |
testing() { |
78 |
emake \ |
76 |
emake \ |
79 |
PYTHON_VERSION="$(python_get_version)" \ |
77 |
PYTHON="${PYTHON}" \ |
|
|
78 |
PYTHON_VERSION="${EPYTHON#python}" \ |
80 |
pyexecdir="$(python_get_sitedir)" \ |
79 |
pyexecdir="$(python_get_sitedir)" \ |
81 |
pythondir="$(python_get_sitedir)" \ |
80 |
pythondir="$(python_get_sitedir)" \ |
82 |
TESTS_ENVIRONMENT="PYTHONPATH=..:../.libs" \ |
81 |
TESTS_ENVIRONMENT="PYTHONPATH=..:../.libs" \ |
83 |
check |
82 |
check |
84 |
} |
83 |
} |
85 |
python_execute_function -s --source-dir bindings/python testing |
84 |
BUILD_DIR=bindings/python \ |
|
|
85 |
python_parallel_foreach_impl run_in_build_dir testing |
86 |
fi |
86 |
fi |
87 |
} |
87 |
} |
88 |
|
88 |
|
Lines 93-115
src_install() {
Link Here
|
93 |
installation() { |
93 |
installation() { |
94 |
emake \ |
94 |
emake \ |
95 |
DESTDIR="${D}" \ |
95 |
DESTDIR="${D}" \ |
96 |
PYTHON_VERSION="$(python_get_version)" \ |
96 |
PYTHON="${PYTHON}" \ |
|
|
97 |
PYTHON_VERSION="${EPYTHON#python}" \ |
97 |
pyexecdir="$(python_get_sitedir)" \ |
98 |
pyexecdir="$(python_get_sitedir)" \ |
98 |
pythondir="$(python_get_sitedir)" \ |
99 |
pythondir="$(python_get_sitedir)" \ |
99 |
install |
100 |
install |
|
|
101 |
python_optimize |
100 |
} |
102 |
} |
101 |
python_execute_function -s --source-dir bindings/python installation |
103 |
BUILD_DIR=bindings/python \ |
102 |
|
104 |
python_parallel_foreach_impl run_in_build_dir installation |
103 |
python_clean_installation_image |
|
|
104 |
fi |
105 |
fi |
105 |
|
106 |
|
106 |
rm -f "${ED}"/usr/lib*/${PN}.la |
107 |
prune_libtool_files --modules |
107 |
} |
|
|
108 |
|
109 |
pkg_postinst() { |
110 |
use python && python_mod_optimize capng.py |
111 |
} |
112 |
|
113 |
pkg_postrm() { |
114 |
use python && python_mod_cleanup capng.py |
115 |
} |
108 |
} |