This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
ACATS script generation problem
- From: Georg Bauhaus <bauhaus at futureapps dot de>
- To: gcc at gcc dot gnu dot org
- Date: Mon, 21 Nov 2005 01:07:38 +0100
- Subject: ACATS script generation problem
Running make check stops in the Ada ACATS part,
where it doesn't find the newly created binaries
after a successful make bootstrap. (And after turning
the computer off, going to sleep, turning it on and
*not* again adding the different GNAT installation to
PATH that was used for bootstrapping.)
I think this is caused by where variables are set in
run_acats, as outlined below.
(Or has some PATH setting gone from the Makefiles?)
Effects of $ make check[-ada] are these:
$ make check
...
=== gcc Summary ===
# of expected passes 37837
# of unexpected failures 1
# of expected failures 97
# of untested testcases 28
# of unsupported tests 234
/werkstatt/georg/build/gcc/xgcc version 4.2.0 20051120 (experimental)
...
.../src/gcc/gcc/testsuite/ada/acats/run_acats: line 11:
type: gnatmake: not found
...
=== acats support ===
Generating support files...
.../build/gcc/testsuite/ada/acats/host_gnatmake: line 5:
exec: -q: invalid option
exec: usage: exec [-cl] [-a name] file [redirection ...]
**** Failed to compile macrosub
make: *** [check-gnat] Error 1
$
This happens when running either $ make check from the top
level build directory, or $make check-ada from the gcc
directory below the top level.
The shell script .../run_acats sets two variables,
host_gnatchop=`type gnatchop | awk '{print $3}'`
host_gnatmake=`type gnatmake | awk '{print $3}'`
However, the programs gnatchop and gnatmake cannot
be not found in $PATH yet because only later the script
modifies PATH to include the new binaries.
(Or else, the gnatchop and gnatmake programs
will be from a different installation, if some full GNAT
is still in $PATH ...)
The script goes on to create two more scripts in the testsuite
directories: host_gnatchop and host_gnatmake. It's using echo
like this:
echo PATH=`dirname $host_gnatmake`:'$PATH' >> host_gnatmake
But $host_gnatmake is empty here, as per the above! Therefore,
echo export PATH >> host_gnatmake
echo exec $host_gnatmake '"$@"' >> host_gnatmake
will result in the quoted error messages when run. Exec will only
have an option (-q) to execute, so to speak.
I thought a solution could then be to add the new GCC's GNAT binaries
directory to $PATH before run_acats employs "type" to find them.
However, this does not work. One effect is that system.ads is not
found. I have the script print out the new settings:
ROOT: /werkstatt/georg/build/gcc/testsuite/ada/acats
PATH: /werkstatt/georg/build/gcc:\
/werkstatt/georg/build/gcc/testsuite/ada/acats:\
/usr/local/bin: etc as usual, no other gnatmake
BASE: /werkstatt/georg/build/gcc
=== acats configuration ===
target gcc is /werkstatt/georg/build/gcc/xgcc
-B/werkstatt/georg/build/gcc/
Reading specs from /werkstatt/georg/build/gcc/specs Target:
i686-pc-linux-gnu Configured with: ../src/gcc/configure
--prefix=/opt/GCC/42 --disable-nls --enable-languages=ada,c,c++,fortran
Thread model: posix gcc version 4.2.0 20051120 (experimental)
host=i486-linux-gnu
target=i686-pc-linux-gnu
gnatmake is /werkstatt/georg/build/gcc/gnatmake
=== acats support ===
Generating support files...fatal error, run-time library not
installed correctly
cannot locate file system.ads
gnatmake: *** make failed.
**** Failed to compile macrosub
make: *** [check-gnat] Error 1
The system.ads is right there I think,
$ head ada/rts/system.ads | cut -b-70
----------------------------------------------------------------------
--
-- GNAT RUN-TIME COMPONENTS
--
-- S Y S T E M
--
-- S p e c
-- (GNU-Linux/x86 Version)
--
-- Copyright (C) 1992-2005, Free Software Foundation, Inc.
What's going on? Am I doing anything wrong?
Linux sonnenregen 2.6.12-9-686-smp #1 SMP Mon Oct 10
Georg