The warnings are:
warning: "g-htable.adb" should be recompiled
warning: ("/usr/lib64/gcc/x86_64-suse-linux/7/adalib/g-htable.ali" is obsolete
and read-only)
warning: "g-byorma.adb" should be recompiled
warning: ("/usr/lib64/gcc/x86_64-suse-linux/7/adalib/g-byorma.ali" is obsolete
and read-only)
warning: "g-speche.adb" should be recompiled
warning: ("/usr/lib64/gcc/x86_64-suse-linux/7/adalib/g-speche.ali" is obsolete
and read-only)
warning: "g-spchge.adb" should be recompiled
warning: ("/usr/lib64/gcc/x86_64-suse-linux/7/adalib/g-spchge.ali" is obsolete
and read-only)
warning: "g-u3spch.adb" should be recompiled
warning: ("/usr/lib64/gcc/x86_64-suse-linux/7/adalib/g-u3spch.ali" is obsolete
and read-only)
but would be hard errors if a kluge was not used (passing -t to gnatbind).
This fixes the warnings, as well as tentatively removes the kludge. Tested on
x86-64/Linux, applied on the mainline.
2025-12-30 Eric Botcazou <[email protected]>
* gcc-interface/Make-lang.in (GNATBIND_FLAGS): Delete.
(GNAT_ADA_OBJS): Move g-byorma.o, g-htable.o, g-spchge.o,
g-speche.o and g-u3spch.o to STAGE1 list.
(GNATBIND_OBJS): Move g-byorma.o, g-hesora.o and g-htable.o
to STAGE1 list.
(ada/b_gnat1.adb): Do not pass GNATBIND_FLAGS to gnatbind.
(ada/b_gnatb.adb): Likewise.
(ADA_GENERATED_FILES): Add g-byorma.ad[sb], g-hesora.ad[sb],
g-htable.ad[sb], g-spchge.ad[sb], g-speche.ad[sb], g-u3spch.ad[sb]
and alphabetize.
* libgnat/g-byorma.ads: Add note to head comment.
* libgnat/g-hesora.ads: Likewise.
* libgnat/g-htable.ads: Likewise.
* libgnat/g-spchge.ads: Likewise.
* libgnat/g-speche.ads: Likewise.
* libgnat/g-u3spch.ads: Likewise.
--
Eric Botcazoudiff --git a/gcc/ada/gcc-interface/Make-lang.in b/gcc/ada/gcc-interface/Make-lang.in
index e768ef60ddf..b1628bfb97b 100644
--- a/gcc/ada/gcc-interface/Make-lang.in
+++ b/gcc/ada/gcc-interface/Make-lang.in
@@ -57,7 +57,6 @@ WARN_ADAFLAGS= -W -Wall
# checks fully active.
STAGE1=False
-GNATBIND_FLAGS=
GNATLIB=
ifeq ($(CROSS),)
@@ -65,7 +64,6 @@ ifeq ($(CROSS),)
ifeq ($(if $(wildcard ../stage_current),$(shell cat ../stage_current),stage1),stage1)
STAGE1=True
- GNATBIND_FLAGS=-t
endif
else
ADAFLAGS=$(COMMON_ADAFLAGS)
@@ -478,10 +476,15 @@ GNAT_ADA_OBJS = \
ada/warnsw.o \
ada/widechar.o \
ada/gnat.o \
+ ada/g-byorma.o \
ada/g-dynhta.o \
ada/g-graphs.o \
+ ada/g-htable.o \
ada/g-lists.o \
ada/g-sets.o \
+ ada/g-spchge.o \
+ ada/g-speche.o \
+ ada/g-u3spch.o \
ada/s-pehage.o \
ada/s-utf_32.o
@@ -514,14 +517,9 @@ GNAT_ADA_OBJS+= \
ada/libgnat/a-nubinu.o \
ada/libgnat/a-numeri.o \
ada/libgnat/ada.o \
- ada/libgnat/g-byorma.o \
ada/libgnat/g-cstyin.o \
ada/libgnat/g-heasor.o \
- ada/libgnat/g-htable.o \
- ada/libgnat/g-spchge.o \
- ada/libgnat/g-speche.o \
ada/libgnat/g-table.o \
- ada/libgnat/g-u3spch.o \
ada/libgnat/i-c.o \
ada/libgnat/i-cstrin.o \
ada/libgnat/interfac.o \
@@ -659,15 +657,18 @@ GNATBIND_OBJS = \
ada/uintp.o \
ada/uname.o \
ada/urealp.o \
+ ada/version.o \
ada/warnsw.o \
ada/widechar.o \
ada/gnat.o \
+ ada/g-byorma.o \
ada/g-dynhta.o \
- ada/g-lists.o \
ada/g-graphs.o \
+ ada/g-hesora.o \
+ ada/g-htable.o \
+ ada/g-lists.o \
ada/g-sets.o \
ada/s-resfil.o \
- ada/version.o \
ada/s-utf_32.o
ifeq ($(STAGE1),False)
@@ -686,10 +687,7 @@ GNATBIND_OBJS += \
ada/libgnat/a-nubinu.o \
ada/libgnat/a-numeri.o \
ada/libgnat/ada.o \
- ada/libgnat/g-byorma.o \
ada/libgnat/g-cstyin.o \
- ada/libgnat/g-hesora.o \
- ada/libgnat/g-htable.o \
ada/libgnat/i-c.o \
ada/libgnat/i-cstrin.o \
ada/libgnat/interfac.o \
@@ -1167,7 +1165,7 @@ $(check_acats_targets): check-acats%:
ada/b_gnat1.adb : $(GNAT1_ADA_OBJS)
# Old gnatbind do not allow a path for -o.
- $(GNATBIND) $(GNATBIND_FLAGS) $(ADA_INCLUDES) -o b_gnat1.adb -n ada/gnat1drv.ali
+ $(GNATBIND) $(ADA_INCLUDES) -o b_gnat1.adb -n ada/gnat1drv.ali
$(MV) b_gnat1.adb b_gnat1.ads ada/
ada/b_gnat1.o : ada/b_gnat1.adb
@@ -1178,7 +1176,7 @@ ada/b_gnat1.o : ada/b_gnat1.adb
ada/b_gnatb.adb : $(GNATBIND_OBJS) ada/gnatbind.o
# Old gnatbind do not allow a path for -o.
- $(GNATBIND) $(GNATBIND_FLAGS) $(ADA_INCLUDES) -o b_gnatb.adb ada/gnatbind.ali
+ $(GNATBIND) $(ADA_INCLUDES) -o b_gnatb.adb ada/gnatbind.ali
$(MV) b_gnatb.adb b_gnatb.ads ada/
ada/b_gnatb.o : ada/b_gnatb.adb
@@ -1249,11 +1247,22 @@ ADA_GENERATED_FILES = \
ada/seinfo.ads ada/seinfo_tables.ads ada/seinfo_tables.adb \
ada/sinfo-nodes.ads ada/sinfo-nodes.adb \
ada/einfo-entities.ads ada/einfo-entities.adb \
- ada/gnat.ads ada/g-dynhta.ads ada/g-dynhta.adb \
- ada/g-dyntab.ads ada/g-dyntab.adb ada/g-graphs.ads ada/g-graphs.adb \
- ada/g-lists.ads ada/g-lists.adb ada/g-sets.ads ada/g-sets.adb \
- ada/s-rident.ads ada/s-pehage.ads ada/s-pehage.adb \
- ada/s-resfil.ads ada/s-resfil.adb ada/s-utf_32.ads ada/s-utf_32.adb
+ ada/gnat.ads \
+ ada/g-byorma.ads ada/g-byorma.adb \
+ ada/g-dynhta.ads ada/g-dynhta.adb \
+ ada/g-dyntab.ads ada/g-dyntab.adb \
+ ada/g-graphs.ads ada/g-graphs.adb \
+ ada/g-hesora.ads ada/g-hesora.adb \
+ ada/g-htable.ads ada/g-htable.adb \
+ ada/g-lists.ads ada/g-lists.adb \
+ ada/g-sets.ads ada/g-sets.adb \
+ ada/g-spchge.ads ada/g-spchge.adb \
+ ada/g-speche.ads ada/g-speche.adb \
+ ada/g-u3spch.ads ada/g-u3spch.adb \
+ ada/s-pehage.ads ada/s-pehage.adb \
+ ada/s-resfil.ads ada/s-resfil.adb \
+ ada/s-rident.ads \
+ ada/s-utf_32.ads ada/s-utf_32.adb
# Only used to manually trigger the creation of the generated files.
.PHONY:
diff --git a/gcc/ada/libgnat/g-byorma.ads b/gcc/ada/libgnat/g-byorma.ads
index fa9e40b9dcc..400faa51540 100644
--- a/gcc/ada/libgnat/g-byorma.ads
+++ b/gcc/ada/libgnat/g-byorma.ads
@@ -61,6 +61,9 @@
-- cases depend on the first character of the XML file being < so that the
-- encoding of this character can be recognized.
+-- Note: this unit is used during bootstrap, see ADA_GENERATED_FILES in
+-- gcc-interface/Make-lang.in for details on the constraints.
+
package GNAT.Byte_Order_Mark is
type BOM_Kind is
diff --git a/gcc/ada/libgnat/g-hesora.ads b/gcc/ada/libgnat/g-hesora.ads
index 73b94343563..036353486b0 100644
--- a/gcc/ada/libgnat/g-hesora.ads
+++ b/gcc/ada/libgnat/g-hesora.ads
@@ -40,6 +40,9 @@
-- worst case and is in place with no additional storage required. See
-- the body for exact details of the algorithm used.
+-- Note: this unit is used during bootstrap, see ADA_GENERATED_FILES in
+-- gcc-interface/Make-lang.in for details on the constraints.
+
package GNAT.Heap_Sort_A is
pragma Preelaborate;
diff --git a/gcc/ada/libgnat/g-htable.ads b/gcc/ada/libgnat/g-htable.ads
index 22e236c0bb7..aaa35f0558a 100644
--- a/gcc/ada/libgnat/g-htable.ads
+++ b/gcc/ada/libgnat/g-htable.ads
@@ -39,6 +39,9 @@
-- See file s-htable.ads for full documentation of the interface
+-- Note: this unit is used during bootstrap, see ADA_GENERATED_FILES in
+-- gcc-interface/Make-lang.in for details on the constraints.
+
with System.HTable;
package GNAT.HTable is
diff --git a/gcc/ada/libgnat/g-spchge.ads b/gcc/ada/libgnat/g-spchge.ads
index 7c8ec7db54d..d139c95893d 100644
--- a/gcc/ada/libgnat/g-spchge.ads
+++ b/gcc/ada/libgnat/g-spchge.ads
@@ -37,6 +37,9 @@
-- codes for ASCII characters in the range 16#20#..16#7F# have their normal
-- expected encoding values (e.g. the Pos value 16#31# must be digit 1).
+-- Note: this unit is used during bootstrap, see ADA_GENERATED_FILES in
+-- gcc-interface/Make-lang.in for details on the constraints.
+
package GNAT.Spelling_Checker_Generic is
pragma Pure;
diff --git a/gcc/ada/libgnat/g-speche.ads b/gcc/ada/libgnat/g-speche.ads
index 493ae5febc9..90a40b63833 100644
--- a/gcc/ada/libgnat/g-speche.ads
+++ b/gcc/ada/libgnat/g-speche.ads
@@ -34,6 +34,9 @@
-- This package provides a utility routine for checking for bad spellings
-- for the case of String arguments.
+-- Note: this unit is used during bootstrap, see ADA_GENERATED_FILES in
+-- gcc-interface/Make-lang.in for details on the constraints.
+
package GNAT.Spelling_Checker is
pragma Pure;
diff --git a/gcc/ada/libgnat/g-u3spch.ads b/gcc/ada/libgnat/g-u3spch.ads
index df0af938dcf..2108fe00f6a 100644
--- a/gcc/ada/libgnat/g-u3spch.ads
+++ b/gcc/ada/libgnat/g-u3spch.ads
@@ -34,6 +34,9 @@
-- This package provides a utility routine for checking for bad spellings
-- for the case of System.WCh_Cnv.UTF_32_String arguments.
+-- Note: this unit is used during bootstrap, see ADA_GENERATED_FILES in
+-- gcc-interface/Make-lang.in for details on the constraints.
+
with System.WCh_Cnv;
package GNAT.UTF_32_Spelling_Checker is