From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id C28211382C5 for ; Sun, 20 Dec 2020 21:54:39 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id CF2F3E0871; Sun, 20 Dec 2020 21:54:35 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 97607E083E for ; Sun, 20 Dec 2020 21:54:35 +0000 (UTC) Received: by mail-il1-f181.google.com with SMTP id t9so7237052ilf.2 for ; Sun, 20 Dec 2020 13:54:34 -0800 (PST) X-Gm-Message-State: AOAM530tIhwHGw0yGNSlfQb3hPRCpR/puG5UIoGXMjKKh3WiAhBv8c0d F57SAmVHl1r8ofokoS9qZlq3AHloe1HvclgbpgE= X-Google-Smtp-Source: ABdhPJxsSdXvWvzYk7fu6ncC3PluDGcV62mEB382fTfGpokWhvL+WcR5jWaSsN2EHHwp0U5Exo9setb5Hyos9phxJ/s= X-Received: by 2002:a92:a043:: with SMTP id b3mr13990266ilm.272.1608501272411; Sun, 20 Dec 2020 13:54:32 -0800 (PST) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 References: <20201217213008.1831469-1-floppym@gentoo.org> <650b003aa06d3062438f25e94ab6f45108f2147d.camel@gentoo.org> <2a1a4c2427bec93eaf7d7f5d8de7098a5f029a3d.camel@gentoo.org> In-Reply-To: From: Mike Gilbert Date: Sun, 20 Dec 2020 16:54:21 -0500 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [gentoo-dev] [PATCH 1/3] meson.eclass: use python eselect module in _meson_env_array To: Gentoo Dev Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Archives-Salt: 47648f07-da13-4b75-b47b-8be6b4cbe31b X-Archives-Hash: ec16e3c9f5249e77afcdb42d75b3202b On Sun, Dec 20, 2020 at 2:13 PM William Hubbs wrote: > > On Thu, Dec 17, 2020 at 10:58:23PM +0100, Micha=C5=82 G=C3=B3rny wrote: > > On Thu, 2020-12-17 at 16:50 -0500, Mike Gilbert wrote: > > > On Thu, Dec 17, 2020 at 4:44 PM Micha=C5=82 G=C3=B3rny > > > wrote: > > > > > > > > On Thu, 2020-12-17 at 16:30 -0500, Mike Gilbert wrote: > > > > > Closes: https://bugs.gentoo.org/759433 > > > > > Signed-off-by: Mike Gilbert > > > > > --- > > > > > eclass/meson.eclass | 3 ++- > > > > > 1 file changed, 2 insertions(+), 1 deletion(-) > > > > > > > > > > diff --git a/eclass/meson.eclass b/eclass/meson.eclass > > > > > index 21338280df33..6296f1dd26e5 100644 > > > > > --- a/eclass/meson.eclass > > > > > +++ b/eclass/meson.eclass > > > > > @@ -126,7 +126,8 @@ EOF > > > > > # '--unicode-16=3D=F0=90=90=B7', '--unicode-32=3D=F0=90= =A4=85'] > > > > > # > > > > > _meson_env_array() { > > > > > - python -c "${__MESON_ARRAY_PARSER}" "$@" > > > > > + local python=3D"$(eselect python show)" > > > > > + ${python} -c "${__MESON_ARRAY_PARSER}" "$@" > > > > > } > > > > > > > > > > # @FUNCTION: _meson_get_machine_info > > > > > > > > You're missing a BDEPEND on app-eselect/eselect-python. > > > > > > > > Also, I really don't like these workarounds. It takes a lot of > > > > effort > > > > to figure out how to break stuff, so people stop doing awful > > > > things. > > > > It's disrespectful to my time when you invent new hacks. Now I'll > > > > have > > > > to figure out how to change eselect-python to break it. > > > > > > Why is this such an awful thing to do? > > > > > > The code should be able to execute with any version of python > > > currently supported by Gentoo. > > > > > > Please don't assume that I'm trying to avoid a proper solution here. > > > Please suggest a better alternative if you have one. > > > > I actually liked installing the script to the system. > > If we are going to install it to the system, that should not be done by > dev-util/meson; it is a gentoo-specific script, so we should probably > create a separate package for it. Also, it is debatable whether that > script should be installed in a directory that is on the path. I don't really want to create a separate package to install a single file. dev-util/meson is just a convenient place to install it. I think it is ok to install it in PATH, so long as it is unlikely to conflict with other program names. > I have major concerns about the native-symlinks use flag for python-exec. > It looks like turning this flag off would result in /usr/bin/python not b= eing > installed which will cause massive breakage. This is similar to removing > /bin/sh., so I am strongly against the idea of this use flag unless > upstream python is recommending it. If they are not installing > /usr/bin/python in their native builds any longer, I'll be quiet. > Otherwise, imo this is a really bad idea for a use flag. The native-symlinks flag exists to break things intentionally. https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3D5bd5d2f9ea331119ea68= 1e52ccaff1bce172ac98