I tried to build gnat compiler from gcc-11.2.0 with following script
./configure --prefix="/root/gcc-11" --enable-languages="c,c++,ada" --enable-libada
then I get a gnat compiler but without ada standard library and found that the library's build script libada.gpr in gcc-11.2/gcc/ada/libgnat/ can be standalone.
GPR tools tells that it needs libgnarl.lst to continue when tried to use gprbuild -Plibada to build libada.
Here's my questions:
libgnarl contains the tasking elements of the runtime, libgnat contains the rest. They’re split so that a program that doesn’t do tasking can be smaller than it would otherwise need to be.
The GCC installation instructions contain, in the Configuration section,
First, we highly recommend that GCC be built into a separate directory from the sources which does not reside within the source tree. This is how we generally build GCC; building where srcdir == objdir should still work, but doesn’t get extensive testing; building where objdir is a subdirectory of srcdir is unsupported.
My experience building GCC like that is that the runtime gets properly built. (This may not be the case for less common OSs; what’s yours?).
After such a build, I found these files lurking amongst many others in $build/gcc/ada/rts/:
libada.gpr
libgnarl.gpr
libgnarl.lst
libgnat.gpr
libgnat.lst
libgnat_common.gpr
and I get the strong impression (from libada.gpr, particularly) that these are intended to rebuild the runtime for a specific purpose.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With