Gentoo Archives: gentoo-python

From: "Michał Górny" <mgorny@g.o>
To: gentoo-python@l.g.o
Cc: python@g.o, "Michał Górny" <mgorny@g.o>
Subject: [gentoo-python] [PATCH 10/10 updated] Replace static EPYTHON setting with python-any-r1.
Date: Thu, 29 Nov 2012 19:48:08
Message-Id: 1354218268-14064-1-git-send-email-mgorny@gentoo.org
In Reply to: [gentoo-python] python2.7 ebuild patches, split up by "Michał Górny"
1 This way, the ebuild will check for the best installed Python version
2 satisfying the dep and use it if necessary.
3 ---
4 gx86/dev-lang/python/python-2.7.3-r3.ebuild | 10 ++++++++--
5 1 file changed, 8 insertions(+), 2 deletions(-)
6
7 diff --git a/gx86/dev-lang/python/python-2.7.3-r3.ebuild b/gx86/dev-lang/python/python-2.7.3-r3.ebuild
8 index 2182837..b6349a2 100644
9 --- a/gx86/dev-lang/python/python-2.7.3-r3.ebuild
10 +++ b/gx86/dev-lang/python/python-2.7.3-r3.ebuild
11 @@ -6,7 +6,10 @@ EAPI="2"
12 WANT_AUTOMAKE="none"
13 WANT_LIBTOOL="none"
14
15 -inherit autotools eutils flag-o-matic multilib pax-utils python-utils-r1 toolchain-funcs
16 +# Bootstrapping Python requires Python 2.
17 +PYTHON_COMPAT=( python{2_5,2_6,2_7} pypy{1_8,1_9} )
18 +
19 +inherit autotools eutils flag-o-matic multilib pax-utils python-any-r1 toolchain-funcs
20
21 MY_P="Python-${PV}"
22 PATCHSET_REVISION="1"
23 @@ -50,6 +53,7 @@ RDEPEND="app-arch/bzip2
24 )
25 !!<sys-apps/portage-2.1.9"
26 DEPEND="${RDEPEND}
27 + ${PYTHON_DEPS}
28 virtual/pkgconfig
29 >=sys-devel/autoconf-2.65
30 !sys-devel/gcc[libffi]"
31 @@ -73,6 +77,8 @@ pkg_setup() {
32 ewarn "You might need to migrate your databases."
33 fi
34 fi
35 +
36 + python-any-r1_pkg_setup
37 }
38
39 src_prepare() {
40 @@ -197,7 +203,7 @@ src_configure() {
41 }
42
43 src_compile() {
44 - emake EPYTHON="python${PV%%.*}" || die "emake failed"
45 + default
46
47 # Work around bug 329499. See also bug 413751.
48 pax-mark m python
49 --
50 1.8.0

Replies