Gentoo Archives: gentoo-dev

From: Mike Gilbert <floppym@g.o>
To: "Michał Górny" <mgorny@g.o>
Cc: Gentoo Dev <gentoo-dev@l.g.o>
Subject: Re: [gentoo-dev] [PATCH 1/3] meson.eclass: use python eselect module in _meson_env_array
Date: Thu, 17 Dec 2020 21:50:27
Message-Id: CAJ0EP41+LNFLjE6X3t2cr9kyJ4qi1PpPda5N4zQW1Ct7m7ANMw@mail.gmail.com
In Reply to: Re: [gentoo-dev] [PATCH 1/3] meson.eclass: use python eselect module in _meson_env_array by "Michał Górny"
1 On Thu, Dec 17, 2020 at 4:44 PM Michał Górny <mgorny@g.o> wrote:
2 >
3 > On Thu, 2020-12-17 at 16:30 -0500, Mike Gilbert wrote:
4 > > Closes: https://bugs.gentoo.org/759433
5 > > Signed-off-by: Mike Gilbert <floppym@g.o>
6 > > ---
7 > > eclass/meson.eclass | 3 ++-
8 > > 1 file changed, 2 insertions(+), 1 deletion(-)
9 > >
10 > > diff --git a/eclass/meson.eclass b/eclass/meson.eclass
11 > > index 21338280df33..6296f1dd26e5 100644
12 > > --- a/eclass/meson.eclass
13 > > +++ b/eclass/meson.eclass
14 > > @@ -126,7 +126,8 @@ EOF
15 > > # '--unicode-16=𐐷', '--unicode-32=𐤅']
16 > > #
17 > > _meson_env_array() {
18 > > - python -c "${__MESON_ARRAY_PARSER}" "$@"
19 > > + local python="$(eselect python show)"
20 > > + ${python} -c "${__MESON_ARRAY_PARSER}" "$@"
21 > > }
22 > >
23 > > # @FUNCTION: _meson_get_machine_info
24 >
25 > You're missing a BDEPEND on app-eselect/eselect-python.
26 >
27 > Also, I really don't like these workarounds. It takes a lot of effort
28 > to figure out how to break stuff, so people stop doing awful things.
29 > It's disrespectful to my time when you invent new hacks. Now I'll have
30 > to figure out how to change eselect-python to break it.
31
32 Why is this such an awful thing to do?
33
34 The code should be able to execute with any version of python
35 currently supported by Gentoo.
36
37 Please don't assume that I'm trying to avoid a proper solution here.
38 Please suggest a better alternative if you have one.

Replies