Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: gentoo-dev@l.g.o, Zac Medico <zmedico@g.o>
Cc: python@g.o
Subject: Re: [gentoo-dev] Re: [PATCH] python-utils-r1.eclass: support PYTHON_IMPLS_NO_STRICT variable
Date: Fri, 05 May 2017 05:29:46
Message-Id: C361C6CE-A7FB-43E7-8E3B-E50E98659AB8@gentoo.org
In Reply to: [gentoo-dev] Re: [PATCH] python-utils-r1.eclass: support PYTHON_IMPLS_NO_STRICT variable by Zac Medico
1 Dnia 4 maja 2017 22:34:56 CEST, Zac Medico <zmedico@g.o> napisał(a):
2 >On Tue, May 2, 2017 at 2:48 PM, Zac Medico <zmedico@g.o> wrote:
3 >
4 >> This is intended to be set by the user when using ebuilds that may
5 >> have unknown implementations in PYTHON_COMPAT. The assumption is
6 >> that the ebuilds are intended to be used within multiple contexts
7 >> which can involve revisions of this eclass that support different
8 >> python implementations.
9 >> ---
10 >> eclass/python-utils-r1.eclass | 16 ++++++++++++++++
11 >> 1 file changed, 16 insertions(+)
12 >>
13 >> diff --git a/eclass/python-utils-r1.eclass
14 >b/eclass/python-utils-r1.eclass
15 >> index 66a359e..1846da3 100644
16 >> --- a/eclass/python-utils-r1.eclass
17 >> +++ b/eclass/python-utils-r1.eclass
18 >> @@ -47,6 +47,21 @@ _PYTHON_ALL_IMPLS=(
19 >> )
20 >> readonly _PYTHON_ALL_IMPLS
21 >>
22 >> +# @ECLASS-VARIABLE: PYTHON_IMPLS_NO_STRICT
23 >> +# @DESCRIPTION:
24 >> +# Tolerate unknown implementations in PYTHON_COMPAT.
25 >> +#
26 >> +# This is intended to be set by the user when using ebuilds that may
27 >> +# have unknown implementations in PYTHON_COMPAT. The assumption is
28 >> +# that the ebuilds are intended to be used within multiple contexts
29 >> +# which can involve revisions of this eclass that support different
30 >> +# python implementations.
31 >> +#
32 >> +# Example:
33 >> +# @CODE
34 >> +# PYTHON_IMPLS_NO_STRICT=1
35 >> +# @CODE
36 >> +
37 >> # @FUNCTION: _python_impl_supported
38 >> # @USAGE: <impl>
39 >> # @INTERNAL
40 >> @@ -79,6 +94,7 @@ _python_impl_supported() {
41 >> fi
42 >> ;;
43 >> *)
44 >> + [[ -n ${PYTHON_IMPLS_NO_STRICT} ]] && return
45 >1
46 >> die "Invalid implementation in PYTHON_COMPAT:
47 >> ${impl}"
48 >> esac
49 >> }
50 >> --
51 >> 2.10.2
52 >>
53 >>
54 >If nobody objects, I'd like to merge this sometime next week.
55
56 If there's no explicit hurry, I'd like to commit it along with other python patch I'll be writing soon, to avoid multiple cache regens.
57
58
59 --
60 Best regards,
61 Michał Górny (by phone)

Replies