This is in preparation for the installation of the ACATS 4.2 testsuite.
Tested on x86-64/Linux, applied on the mainline.
2025-05-24 Eric Botcazou <ebotca...@adacore.com>
ada/
* gcc-interface/Make-lang.in (ACATSDIR): Use acats-2 directory.
testsuite/
* ada/acats/*: Rename into ada/acats-2/*.
* ada/acats-2/run_all.sh: Adjust to above renaming.
* ada/acats-2/support/impdefc.a: New file.
--
Eric Botcazou
commit ba3b42807e70f381e3a4e3e47662a22e7634f3a6
Author: Eric Botcazou <ebotca...@adacore.com>
Date: Sat May 24 12:04:19 2025 +0200
Ada: move ACATS 2.6 testsuite to acats-2 directory
This is in preparation for the installation of the ACATS 4.2 testsuite.
gcc/ada/
* gcc-interface/Make-lang.in (ACATSDIR): Use acats-2 directory.
gcc/testsuite/
* ada/acats/*: Rename into ada/acats-2/*.
* ada/acats-2/run_all.sh: Adjust to above renaming.
* ada/acats-2/support/impdefc.a: New file.
diff --git a/gcc/ada/gcc-interface/Make-lang.in b/gcc/ada/gcc-interface/Make-lang.in
index 964cae83c55..2158bb68cce 100644
--- a/gcc/ada/gcc-interface/Make-lang.in
+++ b/gcc/ada/gcc-interface/Make-lang.in
@@ -1108,7 +1108,7 @@ check-ada-subtargets: check-acats-subtargets check-gnat-subtargets
# No ada-specific selftests
selftest-ada:
-ACATSDIR = $(TESTSUITEDIR)/ada/acats
+ACATSDIR = $(TESTSUITEDIR)/ada/acats-2
ACATSCMD = run_acats.sh
check_acats_numbers0:=1 2 3 4 5 6 7 8 9
diff --git a/gcc/testsuite/ada/acats/run_all.sh b/gcc/testsuite/ada/acats-2/run_all.sh
similarity index 97%
rename from gcc/testsuite/ada/acats/run_all.sh
rename to gcc/testsuite/ada/acats-2/run_all.sh
index 2f737854c60..a57e3831abb 100755
--- a/gcc/testsuite/ada/acats/run_all.sh
+++ b/gcc/testsuite/ada/acats-2/run_all.sh
@@ -103,14 +103,14 @@ gnatls -v >> $dir/acats.log
display ""
if [ -n "$GCC_RUNTEST_PARALLELIZE_DIR" ]; then
- dir_support=$dir/../acats/support
+ dir_support=$dir/../acats-2/support
rm -rf $dir/run
mv $dir/tests $dir/tests.$$ 2> /dev/null
rm -rf $dir/tests.$$ &
mkdir -p $dir/run
- cp -pr $dir/../acats/tests $dir/
+ cp -pr $dir/../acats-2/tests $dir/
else
dir_support=$dir/support
@@ -336,7 +336,9 @@ for chapter in $chapters; do
echo "BUILD $main" >> $dir/acats.log
EXTERNAL_OBJECTS=""
case $i in
- cxb30*) EXTERNAL_OBJECTS="$dir_support/cxb30040.o $dir_support/cxb30060.o $dir_support/cxb30130.o $dir_support/cxb30131.o";;
+ cxb3004) EXTERNAL_OBJECTS="$dir_support/cxb30040.o";;
+ cxb3006) EXTERNAL_OBJECTS="$dir_support/cxb30060.o";;
+ cxb3013) EXTERNAL_OBJECTS="$dir_support/cxb30130.o $dir_support/cxb30131.o";;
ca1020e) rm -f ca1020e_func1.adb ca1020e_func2.adb ca1020e_proc1.adb ca1020e_proc2.adb > /dev/null 2>&1;;
ca14028) rm -f ca14028_func2.ads ca14028_func3.ads ca14028_proc1.ads ca14028_proc3.ads > /dev/null 2>&1;;
esac
diff --git a/gcc/testsuite/ada/acats-2/support/impdefc.a b/gcc/testsuite/ada/acats-2/support/impdefc.a
new file mode 100644
index 00000000000..6a27a06714d
--- /dev/null
+++ b/gcc/testsuite/ada/acats-2/support/impdefc.a
@@ -0,0 +1,140 @@
+-- IMPDEFC.A
+--
+-- Grant of Unlimited Rights
+--
+-- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687,
+-- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained
+-- unlimited rights in the software and documentation contained herein.
+-- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making
+-- this public release, the Government intends to confer upon all
+-- recipients unlimited rights equal to those held by the Government.
+-- These rights include rights to use, duplicate, release or disclose the
+-- released technical data and computer software in whole or in part, in
+-- any manner and for any purpose whatsoever, and to have or permit others
+-- to do so.
+--
+-- DISCLAIMER
+--
+-- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR
+-- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED
+-- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE
+-- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE
+-- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A
+-- PARTICULAR PURPOSE OF SAID MATERIAL.
+--*
+--
+-- DESCRIPTION:
+-- This package provides tailorable entities for a particular
+-- implementation. Each entity may be modified to suit the needs
+-- of the implementation. Default values are provided to act as
+-- a guide.
+--
+-- The entities in this package are those which are used exclusively
+-- in tests for Annex C (Systems Programming).
+--
+-- APPLICABILITY CRITERIA:
+-- This package is only required for implementations validating the
+-- Systems Programming Annex.
+--
+-- CHANGE HISTORY:
+-- 29 Jan 96 SAIC Initial version for ACVC 2.1.
+--
+--!
+
+with Ada.Interrupts.Names;
+
+package ImpDef.Annex_C is
+
+--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
+
+ -- Interrupt_To_Generate should identify a non-reserved interrupt
+ -- that can be predictably generated within a reasonable time interval
+ -- (as specified by the constant Wait_For_Interrupt) during testing.
+
+ Interrupt_To_Generate: constant Ada.Interrupts.Interrupt_ID :=
+ Ada.Interrupts.Interrupt_ID'First; -- to allow trivial compilation
+ -- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ --- MODIFY HERE AS NEEDED
+
+--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
+
+ -- Wait_For_Interrupt should specify the reasonable time interval during
+ -- which the interrupt identified by Interrupt_To_Generate can be
+ -- expected to be generated.
+
+ Wait_For_Interrupt : constant := 10.0;
+ -- ^^^^ --- MODIFY HERE AS NEEDED
+
+--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
+
+ -- The procedure Enable_Interrupts should enable interrupts, if this
+ -- is required by the implementation. [See additional notes on this
+ -- procedure in the package body.]
+
+ procedure Enable_Interrupts;
+
+--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
+
+ -- The procedure Generate_Interrupt should generate the interrupt
+ -- identified by Interrupt_To_Generate within the time interval
+ -- specified by Wait_For_Interrupt. [See additional notes on this
+ -- procedure in the package body.]
+
+ procedure Generate_Interrupt;
+
+--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
+
+end ImpDef.Annex_C;
+
+
+ --==================================================================--
+
+
+package body ImpDef.Annex_C is
+
+ -- NOTE: These are example bodies. It is expected that implementors
+ -- will write their own versions of these routines.
+
+--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
+
+ -- The procedure Enable_Interrupts should enable interrupts, if this
+ -- is required by the implementation.
+ --
+ -- The default body is null, since it is expected that most implementations
+ -- will not need to perform this step.
+ --
+ -- Note that Enable_Interrupts will be called only once per test.
+
+ procedure Enable_Interrupts is
+ begin
+ null;
+
+ -- ^^^^^^^^^^^^^^^^^^^^ MODIFY THIS BODY AS NEEDED ^^^^^^^^^^^^^^^^^^^^
+
+ end Enable_Interrupts;
+
+--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
+
+ -- The procedure Generate_Interrupt should generate the interrupt
+ -- identified by Interrupt_To_Generate within the time interval
+ -- specified by Wait_For_Interrupt.
+ --
+ -- The default body assumes that an interrupt will be generated by some
+ -- physical act during testing. While this approach is acceptable, the
+ -- interrupt should ideally be generated by appropriate code in the
+ -- procedure body.
+ --
+ -- Note that Generate_Interrupt may be called multiple times by a single
+ -- test. The code used to implement this procedure should account for this
+ -- possibility.
+
+ procedure Generate_Interrupt is
+ begin
+ Report.Comment (". >>>>> GENERATE THE INTERRUPT NOW <<<<< ");
+
+ -- ^^^^^^^^^^^^^^^^^^^^ MODIFY THIS BODY AS NEEDED ^^^^^^^^^^^^^^^^^^^^
+
+ end Generate_Interrupt;
+
+--=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====-=====--
+
+end ImpDef.Annex_C;