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.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 8F2EE158089 for ; Wed, 13 Sep 2023 06:15:09 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 3FB2C2BC152; Wed, 13 Sep 2023 06:15:06 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id E25632BC014 for ; Wed, 13 Sep 2023 06:15:05 +0000 (UTC) Date: Wed, 13 Sep 2023 08:15:00 +0200 From: Fabian Groffen To: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] New bootstrap-prefix global USE-flag and patch to llvm.eclass Message-ID: Mail-Followup-To: gentoo-dev@lists.gentoo.org References: <270a8b9b-e455-099d-1eda-2cf73d31bb10@asokolov.org> 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 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="652TwZsxEqRh+iTu" Content-Disposition: inline In-Reply-To: <270a8b9b-e455-099d-1eda-2cf73d31bb10@asokolov.org> User-Agent: Mutt/2.2.12 (Darwin 22.6.0, VIM - Vi IMproved 9.0) Organization: Gentoo Foundation, Inc. X-Archives-Salt: fdab67e1-285d-4b04-92bb-6c47af6827fa X-Archives-Hash: f2af53a1ea27bac25c3e0c81a6308f0b --652TwZsxEqRh+iTu Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 12-09-2023 20:32:19 +0100, Alexey Sokolov wrote: > Bug: https://bugs.gentoo.org/758167 > Full PR is at https://github.com/gentoo/gentoo/pull/32730 >=20 > Several LLVM packages require this early return, otherwise they fail to= =20 > build on Darwin. I'll also need this USE-flag for=20 > sys-devel/clang-common, to distinguish between stage2 and stage3 of=20 > bootstrap-prefix.sh to configure clang differently. >=20 > --=20 > Best regards, > Alexey "DarthGandalf" Sokolov > From de2bd1abc3e5c7607413633d132c604c6a801802 Mon Sep 17 00:00:00 2001 > From: Alexey Sokolov > Date: Mon, 11 Sep 2023 23:26:49 +0100 > Subject: [PATCH] llvm.eclass: add global USE flag bootstrap-prefix >=20 > Mask it everywhere except for prefix profiles >=20 > Without this, stage2's LLVM packages fail to build. >=20 > Bug: https://bugs.gentoo.org/758167 > Signed-off-by: Alexey Sokolov > --- > eclass/llvm.eclass | 7 +++++++ > profiles/base/use.mask | 4 ++++ > profiles/features/prefix/use.mask | 4 ++++ > profiles/use.desc | 1 + > 4 files changed, 16 insertions(+) >=20 > diff --git a/eclass/llvm.eclass b/eclass/llvm.eclass > index 8198650aad9a7..87c2cedb3a376 100644 > --- a/eclass/llvm.eclass > +++ b/eclass/llvm.eclass > @@ -64,6 +64,8 @@ esac > if [[ ! ${_LLVM_ECLASS} ]]; then > _LLVM_ECLASS=3D1 > =20 > +IUSE=3D"bootstrap-prefix" > + > # make sure that the versions installing straight into /usr/bin > # are uninstalled > DEPEND=3D"!!sys-devel/llvm:0" > @@ -242,6 +244,11 @@ llvm_fix_tool_path() { > llvm_pkg_setup() { > debug-print-function ${FUNCNAME} "${@}" > =20 > + if use bootstrap-prefix; then > + # AppleClang has unparseable version numbers, but it's irrelevant anyw= ay > + return > + fi > + I might misunderstand this, but is this USE-flag supposed to be set only during bootstrap, e.g. when host-provided Clang is used? If so, would it be possible to use has_version or something instead? Thanks, Fabian > if [[ ${MERGE_TYPE} !=3D binary ]]; then > LLVM_SLOT=3D$(get_llvm_slot "${LLVM_MAX_SLOT}") > =20 > diff --git a/profiles/base/use.mask b/profiles/base/use.mask > index 1d4f5b92865df..cc86fde21097a 100644 > --- a/profiles/base/use.mask > +++ b/profiles/base/use.mask > @@ -8,6 +8,10 @@ > # eudev is masked for removal > eudev > =20 > +# Alexey Sokolov (2023-09-11) > +# Only needed during bootstrap of prefix > +bootstrap-prefix > + > # David Seifert (2023-09-09) > # EOL upstream in 2 months, causes major headaches for OpenSSL 1.1 > # masking. Removal on 2023-10-09. > diff --git a/profiles/features/prefix/use.mask b/profiles/features/prefix= /use.mask > index 482ce57f04485..1f43ca23fd101 100644 > --- a/profiles/features/prefix/use.mask > +++ b/profiles/features/prefix/use.mask > @@ -4,6 +4,10 @@ > # prefix USE flag should always be unmasked in prefix profiles > -prefix > =20 > +# Alexey Sokolov (2023-09-11) > +# Allow bootstrapping the prefix > +-bootstrap-prefix > + > # USE flags inherited by the base/use.defaults file that shouldn't be in= Prefix > gpm > =20 > diff --git a/profiles/use.desc b/profiles/use.desc > index 6034f3bf6fc31..37c64f43759da 100644 > --- a/profiles/use.desc > +++ b/profiles/use.desc > @@ -29,6 +29,7 @@ big-endian - Big-endian toolchain support > bindist - Flag to enable or disable options for prebuilt (GRP) packages = (eg. due to licensing issues) > blas - Add support for the virtual/blas numerical library > bluetooth - Enable Bluetooth Support > +bootstrap-prefix - !!internal use only!! DO NOT SET THIS FLAG YOURSELF!,= used for bootstrapping Gentoo Prefix > branding - Enable Gentoo specific branding > build - !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used for c= reating build images and the first half of bootstrapping [make stage1] > bzip2 - Use the bzlib compression library --=20 Fabian Groffen Gentoo on a different level --652TwZsxEqRh+iTu Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEELUvHd/Gtp7LaU1vuzpXahU5EQpMFAmUBU2QACgkQzpXahU5E QpNp+wgApCp8hW5m4X5SUVnfzTkk8w27MoC6Ew2frXWl4RFIm+QBH+L9ytp2AYWn Q8P1bBBULXgNAlHtEiT9uyx7oSIZGjFucUxyR/e8aCMUDUwsjBpeumoZ5RhGE1cb gOpjVWVzTUPgNgcAljl5B+A/C/OdoPSqj78uJZMGDzEgMxbEm5k0zmO+hclKtjaU o4XPPvitm1EhBm2UeyUxUDOhXITmp947Ngi4GfMBoXDgILPF6kbcxHXWTsO9vQLf Fu926x6uGc8lQs9mLx5fOLVUSe23ncAzwpdaZD2TMdyaw889nu0S87A7HnTh+WMl JXVP8Spm2jWY1jfCrNc5q0kizwTOXg== =PI9J -----END PGP SIGNATURE----- --652TwZsxEqRh+iTu--