Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: gentoo-dev@l.g.o
Cc: python@g.o, "Michał Górny" <mgorny@g.o>
Subject: [gentoo-dev] [PATCH 0/5] python-r1 suite: python_gen_impl_dep() function
Date: Wed, 23 Dec 2015 16:45:13
Message-Id: 1450889080-1920-1-git-send-email-mgorny@gentoo.org
1 Hi,
2
3 Here's a quick set of patches that add python_gen_impl_dep() function
4 to python-r1 and python-single-r1 eclasses, and use them in a few
5 ebuilds.
6
7 The problem solved is that some Python packages need to depend on more
8 than one combination of USE flags on the Python interpreter. Currently,
9 we solved this through bash-substituting USE dependencies in generated
10 ${PYTHON_DEPS} -- though this was kinda ugly.
11
12 The python_gen_impl_dep() function intends to match API of other
13 functions. In particular, its usage is:
14
15 python_gen_impl_dep <req-use> [<impl-pattern>...]
16
17 where req-use defines the USE-dep for Python interpreters (alike
18 PYTHON_REQ_USE) and can optionally be an empty string, and impl-patterns
19 specify PYTHON_COMPAT patterns to match implementations that will be
20 present in the dependency. If no patterns are passed, '*' is assumed.
21
22 Examples (for PYTHON_COMPAT=( python2_7 python3_4 )):
23
24 python_gen_impl_dep 'bzip2(+)'
25
26 python_targets_python2_7? ( dev-lang/python:2.7[bzip2(+)] )
27 python_targets_python3_4? ( dev-lang/python:3.4[bzip2(+)] )
28
29 python_gen_impl_dep ''
30
31 python_targets_python2_7? ( dev-lang/python:2.7 )
32 python_targets_python3_4? ( dev-lang/python:3.4 )
33
34 python_gen_impl_dep '' python3*
35
36 python_targets_python3_4? ( dev-lang/python:3.4 )
37
38 Please review the patches sent in reply.
39
40
41 Michał Górny (5):
42 python-r1.eclass: Introduce python_gen_impl_dep
43 python-single-r1.eclass: Add python_gen_impl_dep, alike in python-r1
44 app-emulation/xen-tools: Make use of new python_gen_impl_dep function
45 dev-python/django: Make use of the new python_gen_impl_dep function
46 sys-apps/portage: Make use of the new python_gen_impl_dep function
47
48 app-emulation/xen-tools/xen-tools-4.2.5-r10.ebuild | 2 +-
49 app-emulation/xen-tools/xen-tools-4.2.5-r11.ebuild | 2 +-
50 app-emulation/xen-tools/xen-tools-4.5.2-r2.ebuild | 4 +-
51 app-emulation/xen-tools/xen-tools-4.5.2-r3.ebuild | 4 +-
52 app-emulation/xen-tools/xen-tools-4.6.0-r4.ebuild | 2 +-
53 app-emulation/xen-tools/xen-tools-4.6.0-r5.ebuild | 2 +-
54 dev-python/django/django-1.4.22.ebuild | 2 +-
55 dev-python/django/django-1.5.12.ebuild | 2 +-
56 dev-python/django/django-1.6.11.ebuild | 2 +-
57 dev-python/django/django-1.7.11.ebuild | 2 +-
58 dev-python/django/django-1.8.7.ebuild | 2 +-
59 dev-python/django/django-1.9.ebuild | 2 +-
60 dev-python/django/django-9999.ebuild | 2 +-
61 eclass/python-r1.eclass | 52 +++++++++++++++++++
62 eclass/python-single-r1.eclass | 58 ++++++++++++++++++++++
63 sys-apps/portage/portage-2.2.20.1.ebuild | 3 +-
64 sys-apps/portage/portage-2.2.23.ebuild | 3 +-
65 sys-apps/portage/portage-2.2.24.ebuild | 3 +-
66 sys-apps/portage/portage-2.2.25.ebuild | 3 +-
67 sys-apps/portage/portage-2.2.26.ebuild | 3 +-
68 sys-apps/portage/portage-9999.ebuild | 3 +-
69 21 files changed, 131 insertions(+), 27 deletions(-)
70
71 --
72 2.6.4

Replies