Gentoo Archives: gentoo-dev

From: Arfrever Frehtes Taifersar Arahesis <Arfrever@g.o>
To: Gentoo Development <gentoo-dev@l.g.o>
Subject: Re: [gentoo-dev] PYTHON_DEPEND - Suggested replacement for NEED_PYTHON
Date: Sun, 10 Jan 2010 22:15:43
Message-Id: 201001102250.45410.Arfrever@gentoo.org
In Reply to: Re: [gentoo-dev] PYTHON_DEPEND - Suggested replacement for NEED_PYTHON by Sebastian Pipping
1 2010-01-10 19:41:55 Sebastian Pipping napisaƂ(a):
2 > On 01/10/10 09:29, Arfrever Frehtes Taifersar Arahesis wrote:
3 > > I would like to suggest introduction of support for PYTHON_DEPEND variable, which
4 > > would be a better replacement for NEED_PYTHON variable. NEED_PYTHON variable
5 > > does not allow to specify that e.g. only versions of Python 2 are accepted.
6 > > (Eventually PYTHON_DEPEND variable will have to be set only in ebuilds of packages
7 > > not supporting installation for multiple versions of Python.)
8 > >
9 > > Suggested syntax:
10 > > PYTHON_DEPEND="[USE_flag?] <X[:[Y][:[Z]]]> [X[:[Y][:[Z]]]]"
11 > > <required_component>, [optional_component]
12 > > X - Major version of Python ('2' or '3') or '*'.
13 > > Y - Minimal version of Python in the form of ${major_version}.${minor_version}.
14 > > Z - Maximal version of Python in the form of ${major_version}.${minor_version}.
15 > > It will be probably very rarely used.
16 > >
17 > > Examples:
18 > > PYTHON_DEPEND="2"
19 > > Dependency on any version of Python 2.
20 > >
21 > > PYTHON_DEPEND="2:2.5"
22 > > Dependency on Python 2.7, 2.6 or 2.5.
23 > >
24 > > PYTHON_DEPEND="*:2.6"
25 > > Dependency on Python 3.2, 3.1, 3.0, 2.7 or 2.6.
26 > >
27 > > PYTHON_DEPEND="2:2.7 3:3.1"
28 > > Dependency on Python 3.2, 3.1 or 2.7.
29 > >
30 > > PYTHON_DEPEND="2:2.5:2.6"
31 > > Dependency on Python 2.6 or 2.5.
32 > >
33 > > PYTHON_DEPEND="2::2.6"
34 > > Dependency on Python 2.6, 2.5 or 2.4.
35 > >
36 > > PYTHON_DEPEND="python? 2"
37 > > Dependency on any version of Python 2 when "python" USE flag is enabled.
38 > >
39 >
40 > While I don't object improvements or changes on that front at all:
41 >
42 > - How are SUPPORT_PYTHON_ABIS and RESTRICT_PYTHON_ABIS affected
43 > by NEED_PYTHON now and by PYTHON_DEPEND in the future?
44
45 They aren't and won't be. PYTHON_DEPEND is designed mainly for packages
46 not supporting installation for multiple Python versions.
47
48 > - The proposed approach doesn't look intuitive to me from a quick
49 > view, sorry: Neither the examples nor the grammar. I didn't give
50 > it that much time to be fair, though.
51
52 IMHO it's sufficiently intuitive :) .
53
54 --
55 Arfrever Frehtes Taifersar Arahesis

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies

Subject Author
Re: [gentoo-dev] PYTHON_DEPEND - Suggested replacement for NEED_PYTHON Sebastian Pipping <sping@g.o>