The recent work for Ada makes things easier here because you don't
have to try juggle both GNAT and GDC at the same time.
Anyway, let's do something similar: iterate over installed GCCs
and try to use the best GDC available for bootstrapping, so users
don't have to manually select it with `gcc-config`. More mangling
may be needed than setting GDC down the line.
Bug: https://bugs.gentoo.org/868228
Signed-off-by: Sam James <sam@gentoo.org>
Alexander Zubkov (1):
net: iproute2: fix missing quotes in test
Sam James (1):
Makefile.inc: prepare for netifrc-0.7.12
Closes: https://bugs.gentoo.org/940443
Signed-off-by: Sam James <sam@gentoo.org>
Look hard for an existing GNAT for use for bootstrapping without requiring
users to run `gcc-config` / switch their system copy of GCC, which is both
brittle in that it requires manual intervention, and also unclean.
Started looking at this after https://public-inbox.gentoo.org/gentoo-dev/2a700166-f01a-4807-bd76-7b0cce72af0b@archeia.com/
although the approach is different. I did use it as a base although not
much of it remains.
We take the following approach:
* Iterate over installed GCC slots (preferring ${SLOT}, then iterating
from the latest version installed down to GCC 10) to find a copy of
GNAT;
* Create wrappers for gnat* to redirect calls when building GCC to
our found bootstrap copy of GNAT;
* Use an extracted spec file to redirect gnat1 calls to that bootstrap
copy too, as the build system doesn't allow saying "just use this copy
of gnat" (it always wants $(CC) to support it).
The real nasty part here is that GCC's build system doesn't seem to have
a way to point to 'ADACC' or similar (it looks like it did have 'ADAC' years ago).
Remaining bits to be done:
* Adapting/replacing/supplementing dev-lang/gnat-gpl with a version that
can be installed in parallel to sys-devel/gcc:10 so it can be pulled
in transparently for bootstrapping;
* Build our own, or source some other copy (e.g. from Alire), of a newer
bootstrap GNAT. https://github.com/alire-project/GNAT-FSF-builds is
a likely candidate.
I also hope that we can ultimately do the same for D.
Bug: https://gcc.gnu.org/PR864
Bug: https://gcc.gnu.org/PR108909
Bug: https://bugs.gentoo.org/137268
Bug: https://bugs.gentoo.org/547358
Bug: https://bugs.gentoo.org/919667
Closes: https://bugs.gentoo.org/937774
Link: https://lists.fedorahosted.org/archives/list/epel-devel@lists.fedoraproject.org/thread/CVQ3JIOZI5ODYDZU2DZLA37JWSLMCIN7/
Signed-off-by: Sam James <sam@gentoo.org>
This was added in d6d640106d but it's not
clear to me why.
Noticed because it causes loads of Ada test failures as UNRESOLVED,
failing with:
```
gnatmake: RTS path "/var/tmp/portage/sys-devel/gcc-15.0.9999/work/build/x86_64-pc-linux-gnu/./libada" not valid: missing adainclude and adalib directories
compiler exited with status 1
```
Fixes: d6d640106d
Signed-off-by: Sam James <sam@gentoo.org>
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>