dev-lang/gnat-gpl: rename USE=bootstrap -> USE=system-bootstrap, invert meaning

USE=bootstrap has/had a special meaning in <EAPI 5 and it also ends up
stable-masked apparently too.

It was dropped from use.desc in af748c0468
and dropped from sys-devel/gcc a while ago too (bug #440224).

To facilitate automatically using gnat-gpl in sys-devel/gcc, do two things:
* Rename USE=bootstrap -> USE=system-bootstrap
* Make USE=system-bootstrap mean "I need a working Ada compiler to build this"
  (i.e. invert its meaning) to match dev-java/openjdk and dev-lang/rust.

Bug: https://bugs.gentoo.org/137268
Bug: https://bugs.gentoo.org/440224
Bug: https://bugs.gentoo.org/547358
Bug: https://bugs.gentoo.org/919667
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Sam James
2024-09-29 00:00:54 +01:00
parent cc8b2ca86e
commit f210bb3d73
2 changed files with 7 additions and 7 deletions

View File

@@ -24,7 +24,7 @@ GCC_TARBALL_SRC_URI="
-> ${MYP}.tar.gz
${BASE_URI}/8ace7d06e469d36d726cc8badb0ed78411e727f3?filename=${INTFDIR}.tar.gz
-> ${INTFDIR}.tar.gz
bootstrap? (
!system-bootstrap? (
amd64? (
${BASE_URI}/6eb6eef6bb897e4c743a519bfebe0b1d6fc409c6?filename=${BTSTRP_AMD64}.tar.gz&rand=1193
-> ${BTSTRP_AMD64}.tar.gz
@@ -42,7 +42,7 @@ HOMEPAGE="http://libre.adacore.com/"
LICENSE+=" GPL-2 GPL-3"
KEYWORDS="amd64 x86"
IUSE="+ada +bootstrap"
IUSE="+ada system-bootstrap"
RESTRICT="test"
RDEPEND="!=sys-devel/gcc-${TOOLCHAIN_GCC_PV}*"
@@ -64,7 +64,7 @@ src_prepare() {
BTSTRP=${BTSTRP_X86}
fi
if use bootstrap; then
if ! use system-bootstrap; then
GCC="${WORKDIR}"/${BTSTRP}/bin/gcc
else
GCC=${ADA:-$(tc-getCC)}
@@ -78,10 +78,10 @@ src_prepare() {
GNATMAKE="${gnatpath}/${GNATMAKE}"
fi
if ! use bootstrap && [[ -z "$(type ${GNATMAKE} 2>/dev/null)" ]] ; then
if use system-bootstrap && [[ -z "$(type ${GNATMAKE} 2>/dev/null)" ]] ; then
eerror "You need a gcc compiler that provides the Ada Compiler:"
eerror "1) use gcc-config to select the right compiler or"
eerror "2) set the bootstrap use flag or"
eerror "2) disable the system-bootstrap use flag or"
eerror "3) set ADA to a working gcc ada compiler"
die "ada compiler not available"
fi
@@ -89,7 +89,7 @@ src_prepare() {
local bundledchost=""
use amd64 && local bundledchost="x86_64"
use x86 && local bundledchost="i686"
if use bootstrap; then
if ! use system-bootstrap; then
rm "${WORKDIR}"/${BTSTRP}/libexec/gcc/${bundledchost}-pc-linux-gnu/4.7.4/ld \
|| die
ln -s /usr/bin/$CHOST-ld \

View File

@@ -6,7 +6,6 @@
</maintainer>
<use>
<flag name="ada">Build the ADA language (GNAT) frontend</flag>
<flag name="bootstrap">Used to bootstrap gnat-gpl</flag>
<flag name="cet" restrict="&gt;=dev-lang/gnat-gpl-2021">Enable support for Intel Control Flow Enforcement Technology (CET)</flag>
<flag name="d">Enable support for the D programming language</flag>
<flag name="default-stack-clash-protection">Build packages with stack clash protection on by default</flag>
@@ -29,6 +28,7 @@
<flag name="pgo">Build GCC using Profile Guided Optimization (PGO)</flag>
<flag name="rust">Build support for the Rust language, installs gccrs.</flag>
<flag name="sanitize">Build support for various sanitizer functions (ASAN/TSAN/etc...)</flag>
<flag name="system-bootstrap">Bootstrap using installed Ada compiler</flag>
<flag name="systemtap">enable systemtap static probe points</flag>
<flag name="ssp">Build packages with stack smashing protector on by default</flag>
<flag name="vtv">Build support for virtual table verification (a C++ hardening feature)</flag>