public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/users/marxin/heads/fix-ada-version)] Fix missing version_string in Ada.
@ 2021-05-10 18:52 Martin Liska
0 siblings, 0 replies; 3+ messages in thread
From: Martin Liska @ 2021-05-10 18:52 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:c0fc7147d91d3ea6771d5bf6cf62ff019f6fbf51
commit c0fc7147d91d3ea6771d5bf6cf62ff019f6fbf51
Author: Martin Liska <mliska@suse.cz>
Date: Mon May 10 10:22:43 2021 +0200
Fix missing version_string in Ada.
gcc/ada/ChangeLog:
PR bootstrap/100506
* Make-generated.in: Replace version.c with ada/version.c.
* gcc-interface/Make-lang.in: Add version.o to GNAT1_C_OBJS.
Add version.o to GNAT_ADA_OBJS and GNATBIND_OBJS.
* gcc-interface/Makefile.in: Add version.o to TOOLS_LIBS.
* gnatvsn.adb: Start using a new C symbol gnat_version_string.
* version.c: New file.
Diff:
---
gcc/ada/Make-generated.in | 2 +-
gcc/ada/gcc-interface/Make-lang.in | 5 ++++-
gcc/ada/gcc-interface/Makefile.in | 4 ++--
gcc/ada/gnatvsn.adb | 2 +-
gcc/ada/version.c | 34 ++++++++++++++++++++++++++++++++++
5 files changed, 42 insertions(+), 5 deletions(-)
diff --git a/gcc/ada/Make-generated.in b/gcc/ada/Make-generated.in
index 237444c7a26..3a65da9b962 100644
--- a/gcc/ada/Make-generated.in
+++ b/gcc/ada/Make-generated.in
@@ -87,7 +87,7 @@ ada/stamp-snames : ada/snames.ads-tmpl ada/snames.adb-tmpl ada/snames.h-tmpl ada
touch ada/stamp-snames
ada/sdefault.adb: ada/stamp-sdefault ; @true
-ada/stamp-sdefault : $(srcdir)/version.c Makefile
+ada/stamp-sdefault : $(srcdir)/ada/version.c Makefile
$(ECHO) "pragma Style_Checks (Off);" >tmp-sdefault.adb
$(ECHO) "with Osint; use Osint;" >>tmp-sdefault.adb
$(ECHO) "package body Sdefault is" >>tmp-sdefault.adb
diff --git a/gcc/ada/gcc-interface/Make-lang.in b/gcc/ada/gcc-interface/Make-lang.in
index 969022e21a7..319bb421ce0 100644
--- a/gcc/ada/gcc-interface/Make-lang.in
+++ b/gcc/ada/gcc-interface/Make-lang.in
@@ -247,7 +247,8 @@ GNAT1_C_OBJS = ada/adadecode.o ada/adaint.o ada/argv.o ada/cio.o \
ada/cstreams.o ada/env.o ada/init.o ada/initialize.o ada/raise.o \
ada/raise-gcc.o \
ada/seh_init.o ada/targext.o ada/cuintp.o ada/decl.o ada/rtfinal.o \
- ada/rtinit.o ada/misc.o ada/utils.o ada/utils2.o ada/trans.o ada/targtyps.o
+ ada/rtinit.o ada/misc.o ada/utils.o ada/utils2.o ada/trans.o ada/targtyps.o \
+ ada/version.o
# Object files from Ada sources that are used by gnat1
GNAT_ADA_OBJS = \
@@ -491,6 +492,7 @@ GNAT_ADA_OBJS = \
ada/usage.o \
ada/validsw.o \
ada/vast.o \
+ ada/version.o \
ada/warnsw.o \
ada/widechar.o
@@ -648,6 +650,7 @@ GNATBIND_OBJS = \
ada/uintp.o \
ada/uname.o \
ada/urealp.o \
+ ada/version.o \
ada/widechar.o
# Language-independent object files.
diff --git a/gcc/ada/gcc-interface/Makefile.in b/gcc/ada/gcc-interface/Makefile.in
index 333e2035455..2598cea2b19 100644
--- a/gcc/ada/gcc-interface/Makefile.in
+++ b/gcc/ada/gcc-interface/Makefile.in
@@ -250,7 +250,7 @@ LIBS = $(LIBINTL) $(LIBICONV) $(LIBBACKTRACE) $(LIBIBERTY) $(SYSLIBS)
LIBDEPS = $(LIBINTL_DEP) $(LIBICONV_DEP) $(LIBBACKTRACE) $(LIBIBERTY)
# Default is no TGT_LIB; one might be passed down or something
TGT_LIB =
-TOOLS_LIBS = ../link.o ../targext.o ../../ggc-none.o ../../libcommon-target.a \
+TOOLS_LIBS = ../version.o ../link.o ../targext.o ../../ggc-none.o ../../libcommon-target.a \
../../libcommon.a ../../../libcpp/libcpp.a $(LIBGNAT) $(LIBINTL) $(LIBICONV) \
../$(LIBBACKTRACE) ../$(LIBIBERTY) $(SYSLIBS) $(TGT_LIB)
@@ -302,7 +302,7 @@ ADA_INCLUDES_FOR_SUBDIR = -I. -I$(fsrcdir)/ada
$(CC) -c $(ALL_ADAFLAGS) $(ADA_INCLUDES) $< $(OUTPUT_OPTION)
# how to regenerate this file
-Makefile: ../config.status $(srcdir)/ada/gcc-interface/Makefile.in $(srcdir)/ada/Makefile.in $(srcdir)/version.c
+Makefile: ../config.status $(srcdir)/ada/gcc-interface/Makefile.in $(srcdir)/ada/Makefile.in $(srcdir)/ada/version.c
cd ..; \
LANGUAGES="$(CONFIG_LANGUAGES)" \
CONFIG_HEADERS= \
diff --git a/gcc/ada/gnatvsn.adb b/gcc/ada/gnatvsn.adb
index 578a1aa9743..d6d2a5a3ace 100644
--- a/gcc/ada/gnatvsn.adb
+++ b/gcc/ada/gnatvsn.adb
@@ -53,7 +53,7 @@ package body Gnatvsn is
-- version.c using the zero-based convention of the C language.
-- The size is not the real one, which does not matter since we will
-- check for the nul character in Gnat_Version_String.
- pragma Import (C, Version_String, "version_string");
+ pragma Import (C, Version_String, "gnat_version_string");
-------------------------
-- Gnat_Version_String --
diff --git a/gcc/ada/version.c b/gcc/ada/version.c
new file mode 100644
index 00000000000..e6cc6124040
--- /dev/null
+++ b/gcc/ada/version.c
@@ -0,0 +1,34 @@
+/****************************************************************************
+ * *
+ * GNAT COMPILER COMPONENTS *
+ * *
+ * V E R S I O N *
+ * *
+ * C Implementation File *
+ * *
+ * Copyright (C) 2021, Free Software Foundation, Inc. *
+ * *
+ * GNAT is free software; you can redistribute it and/or modify it under *
+ * terms of the GNU General Public License as published by the Free Soft- *
+ * ware Foundation; either version 3, or (at your option) any later ver- *
+ * sion. GNAT is distributed in the hope that it will be useful, but WITH- *
+ * OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY *
+ * or FITNESS FOR A PARTICULAR PURPOSE. *
+ * *
+ * As a special exception under Section 7 of GPL version 3, you are granted *
+ * additional permissions described in the GCC Runtime Library Exception, *
+ * version 3.1, as published by the Free Software Foundation. *
+ * *
+ * You should have received a copy of the GNU General Public License and *
+ * a copy of the GCC Runtime Library Exception along with this program; *
+ * see the files COPYING3 and COPYING.RUNTIME respectively. If not, see *
+ * <http://www.gnu.org/licenses/>. *
+ * *
+ * GNAT was originally developed by the GNAT team at New York University. *
+ * Extensive contributions were provided by Ada Core Technologies Inc. *
+ * *
+ ****************************************************************************/
+
+#include "version.h"
+
+char gnat_version_string[] = version_string;
^ permalink raw reply [flat|nested] 3+ messages in thread
* [gcc(refs/users/marxin/heads/fix-ada-version)] Fix missing version_string in Ada.
@ 2021-05-10 19:10 Martin Liska
0 siblings, 0 replies; 3+ messages in thread
From: Martin Liska @ 2021-05-10 19:10 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:217785ed3df1d959498e7668b577606a9f5b51e2
commit 217785ed3df1d959498e7668b577606a9f5b51e2
Author: Martin Liska <mliska@suse.cz>
Date: Mon May 10 10:22:43 2021 +0200
Fix missing version_string in Ada.
gcc/ada/ChangeLog:
PR bootstrap/100506
* Make-generated.in: Replace version.c with ada/version.c.
* gcc-interface/Make-lang.in: Add version.o to GNAT1_C_OBJS.
Add version.o to GNAT_ADA_OBJS and GNATBIND_OBJS.
* gcc-interface/Makefile.in: Add version.o to TOOLS_LIBS.
* gnatvsn.adb: Start using a new C symbol gnat_version_string.
* version.c: New file.
Diff:
---
gcc/ada/Make-generated.in | 2 +-
gcc/ada/gcc-interface/Make-lang.in | 4 +++-
gcc/ada/gcc-interface/Makefile.in | 4 ++--
gcc/ada/gnatvsn.adb | 2 +-
gcc/ada/version.c | 34 ++++++++++++++++++++++++++++++++++
5 files changed, 41 insertions(+), 5 deletions(-)
diff --git a/gcc/ada/Make-generated.in b/gcc/ada/Make-generated.in
index 237444c7a26..3a65da9b962 100644
--- a/gcc/ada/Make-generated.in
+++ b/gcc/ada/Make-generated.in
@@ -87,7 +87,7 @@ ada/stamp-snames : ada/snames.ads-tmpl ada/snames.adb-tmpl ada/snames.h-tmpl ada
touch ada/stamp-snames
ada/sdefault.adb: ada/stamp-sdefault ; @true
-ada/stamp-sdefault : $(srcdir)/version.c Makefile
+ada/stamp-sdefault : $(srcdir)/ada/version.c Makefile
$(ECHO) "pragma Style_Checks (Off);" >tmp-sdefault.adb
$(ECHO) "with Osint; use Osint;" >>tmp-sdefault.adb
$(ECHO) "package body Sdefault is" >>tmp-sdefault.adb
diff --git a/gcc/ada/gcc-interface/Make-lang.in b/gcc/ada/gcc-interface/Make-lang.in
index 969022e21a7..c8c02d3f795 100644
--- a/gcc/ada/gcc-interface/Make-lang.in
+++ b/gcc/ada/gcc-interface/Make-lang.in
@@ -247,7 +247,8 @@ GNAT1_C_OBJS = ada/adadecode.o ada/adaint.o ada/argv.o ada/cio.o \
ada/cstreams.o ada/env.o ada/init.o ada/initialize.o ada/raise.o \
ada/raise-gcc.o \
ada/seh_init.o ada/targext.o ada/cuintp.o ada/decl.o ada/rtfinal.o \
- ada/rtinit.o ada/misc.o ada/utils.o ada/utils2.o ada/trans.o ada/targtyps.o
+ ada/rtinit.o ada/misc.o ada/utils.o ada/utils2.o ada/trans.o ada/targtyps.o \
+ ada/version.o
# Object files from Ada sources that are used by gnat1
GNAT_ADA_OBJS = \
@@ -648,6 +649,7 @@ GNATBIND_OBJS = \
ada/uintp.o \
ada/uname.o \
ada/urealp.o \
+ ada/version.o \
ada/widechar.o
# Language-independent object files.
diff --git a/gcc/ada/gcc-interface/Makefile.in b/gcc/ada/gcc-interface/Makefile.in
index 333e2035455..2598cea2b19 100644
--- a/gcc/ada/gcc-interface/Makefile.in
+++ b/gcc/ada/gcc-interface/Makefile.in
@@ -250,7 +250,7 @@ LIBS = $(LIBINTL) $(LIBICONV) $(LIBBACKTRACE) $(LIBIBERTY) $(SYSLIBS)
LIBDEPS = $(LIBINTL_DEP) $(LIBICONV_DEP) $(LIBBACKTRACE) $(LIBIBERTY)
# Default is no TGT_LIB; one might be passed down or something
TGT_LIB =
-TOOLS_LIBS = ../link.o ../targext.o ../../ggc-none.o ../../libcommon-target.a \
+TOOLS_LIBS = ../version.o ../link.o ../targext.o ../../ggc-none.o ../../libcommon-target.a \
../../libcommon.a ../../../libcpp/libcpp.a $(LIBGNAT) $(LIBINTL) $(LIBICONV) \
../$(LIBBACKTRACE) ../$(LIBIBERTY) $(SYSLIBS) $(TGT_LIB)
@@ -302,7 +302,7 @@ ADA_INCLUDES_FOR_SUBDIR = -I. -I$(fsrcdir)/ada
$(CC) -c $(ALL_ADAFLAGS) $(ADA_INCLUDES) $< $(OUTPUT_OPTION)
# how to regenerate this file
-Makefile: ../config.status $(srcdir)/ada/gcc-interface/Makefile.in $(srcdir)/ada/Makefile.in $(srcdir)/version.c
+Makefile: ../config.status $(srcdir)/ada/gcc-interface/Makefile.in $(srcdir)/ada/Makefile.in $(srcdir)/ada/version.c
cd ..; \
LANGUAGES="$(CONFIG_LANGUAGES)" \
CONFIG_HEADERS= \
diff --git a/gcc/ada/gnatvsn.adb b/gcc/ada/gnatvsn.adb
index 578a1aa9743..d6d2a5a3ace 100644
--- a/gcc/ada/gnatvsn.adb
+++ b/gcc/ada/gnatvsn.adb
@@ -53,7 +53,7 @@ package body Gnatvsn is
-- version.c using the zero-based convention of the C language.
-- The size is not the real one, which does not matter since we will
-- check for the nul character in Gnat_Version_String.
- pragma Import (C, Version_String, "version_string");
+ pragma Import (C, Version_String, "gnat_version_string");
-------------------------
-- Gnat_Version_String --
diff --git a/gcc/ada/version.c b/gcc/ada/version.c
new file mode 100644
index 00000000000..e6cc6124040
--- /dev/null
+++ b/gcc/ada/version.c
@@ -0,0 +1,34 @@
+/****************************************************************************
+ * *
+ * GNAT COMPILER COMPONENTS *
+ * *
+ * V E R S I O N *
+ * *
+ * C Implementation File *
+ * *
+ * Copyright (C) 2021, Free Software Foundation, Inc. *
+ * *
+ * GNAT is free software; you can redistribute it and/or modify it under *
+ * terms of the GNU General Public License as published by the Free Soft- *
+ * ware Foundation; either version 3, or (at your option) any later ver- *
+ * sion. GNAT is distributed in the hope that it will be useful, but WITH- *
+ * OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY *
+ * or FITNESS FOR A PARTICULAR PURPOSE. *
+ * *
+ * As a special exception under Section 7 of GPL version 3, you are granted *
+ * additional permissions described in the GCC Runtime Library Exception, *
+ * version 3.1, as published by the Free Software Foundation. *
+ * *
+ * You should have received a copy of the GNU General Public License and *
+ * a copy of the GCC Runtime Library Exception along with this program; *
+ * see the files COPYING3 and COPYING.RUNTIME respectively. If not, see *
+ * <http://www.gnu.org/licenses/>. *
+ * *
+ * GNAT was originally developed by the GNAT team at New York University. *
+ * Extensive contributions were provided by Ada Core Technologies Inc. *
+ * *
+ ****************************************************************************/
+
+#include "version.h"
+
+char gnat_version_string[] = version_string;
^ permalink raw reply [flat|nested] 3+ messages in thread
* [gcc(refs/users/marxin/heads/fix-ada-version)] Fix missing version_string in Ada.
@ 2021-05-10 9:06 Martin Liska
0 siblings, 0 replies; 3+ messages in thread
From: Martin Liska @ 2021-05-10 9:06 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:ba25e961ae05e769c355e8d9ed48da457826a129
commit ba25e961ae05e769c355e8d9ed48da457826a129
Author: Martin Liska <mliska@suse.cz>
Date: Mon May 10 10:22:43 2021 +0200
Fix missing version_string in Ada.
Diff:
---
gcc/ada/Make-generated.in | 2 +-
gcc/ada/gcc-interface/Make-lang.in | 2 ++
gcc/ada/gcc-interface/Makefile.in | 6 +++---
gcc/ada/gnatvsn.adb | 2 +-
gcc/ada/version.c | 34 ++++++++++++++++++++++++++++++++++
5 files changed, 41 insertions(+), 5 deletions(-)
diff --git a/gcc/ada/Make-generated.in b/gcc/ada/Make-generated.in
index 237444c7a26..3a65da9b962 100644
--- a/gcc/ada/Make-generated.in
+++ b/gcc/ada/Make-generated.in
@@ -87,7 +87,7 @@ ada/stamp-snames : ada/snames.ads-tmpl ada/snames.adb-tmpl ada/snames.h-tmpl ada
touch ada/stamp-snames
ada/sdefault.adb: ada/stamp-sdefault ; @true
-ada/stamp-sdefault : $(srcdir)/version.c Makefile
+ada/stamp-sdefault : $(srcdir)/ada/version.c Makefile
$(ECHO) "pragma Style_Checks (Off);" >tmp-sdefault.adb
$(ECHO) "with Osint; use Osint;" >>tmp-sdefault.adb
$(ECHO) "package body Sdefault is" >>tmp-sdefault.adb
diff --git a/gcc/ada/gcc-interface/Make-lang.in b/gcc/ada/gcc-interface/Make-lang.in
index 969022e21a7..2fb87c74d6a 100644
--- a/gcc/ada/gcc-interface/Make-lang.in
+++ b/gcc/ada/gcc-interface/Make-lang.in
@@ -491,6 +491,7 @@ GNAT_ADA_OBJS = \
ada/usage.o \
ada/validsw.o \
ada/vast.o \
+ ada/version.o \
ada/warnsw.o \
ada/widechar.o
@@ -648,6 +649,7 @@ GNATBIND_OBJS = \
ada/uintp.o \
ada/uname.o \
ada/urealp.o \
+ ada/version.o \
ada/widechar.o
# Language-independent object files.
diff --git a/gcc/ada/gcc-interface/Makefile.in b/gcc/ada/gcc-interface/Makefile.in
index 333e2035455..b8e6b214c53 100644
--- a/gcc/ada/gcc-interface/Makefile.in
+++ b/gcc/ada/gcc-interface/Makefile.in
@@ -302,7 +302,7 @@ ADA_INCLUDES_FOR_SUBDIR = -I. -I$(fsrcdir)/ada
$(CC) -c $(ALL_ADAFLAGS) $(ADA_INCLUDES) $< $(OUTPUT_OPTION)
# how to regenerate this file
-Makefile: ../config.status $(srcdir)/ada/gcc-interface/Makefile.in $(srcdir)/ada/Makefile.in $(srcdir)/version.c
+Makefile: ../config.status $(srcdir)/ada/gcc-interface/Makefile.in $(srcdir)/ada/Makefile.in $(srcdir)/ada/version.c
cd ..; \
LANGUAGES="$(CONFIG_LANGUAGES)" \
CONFIG_HEADERS= \
@@ -319,7 +319,7 @@ GNATLINK_OBJS = gnatlink.o \
gnatvsn.o hostparm.o indepsw.o interfac.o i-c.o i-cstrin.o namet.o opt.o \
osint.o output.o rident.o s-exctab.o s-secsta.o s-stalib.o s-stoele.o \
sdefault.o snames.o stylesw.o switch.o system.o table.o targparm.o \
- types.o validsw.o widechar.o
+ types.o validsw.o version.o widechar.o
GNATMAKE_OBJS = a-except.o ali.o ali-util.o aspects.o s-casuti.o alloc.o \
atree.o binderr.o butil.o casing.o csets.o debug.o elists.o einfo.o errout.o \
@@ -331,7 +331,7 @@ GNATMAKE_OBJS = a-except.o ali.o ali-util.o aspects.o s-casuti.o alloc.o \
s-purexc.o s-htable.o scil_ll.o sem_aux.o sinfo.o sinput.o sinput-c.o \
snames.o stand.o stringt.o styleg.o stylesw.o system.o validsw.o \
switch.o switch-m.o table.o targparm.o tempdir.o types.o uintp.o \
- uname.o urealp.o usage.o widechar.o \
+ uname.o urealp.o usage.o version.o widechar.o \
seinfo.o einfo-entities.o einfo-utils.o sinfo-nodes.o sinfo-utils.o \
$(EXTRA_GNATMAKE_OBJS)
diff --git a/gcc/ada/gnatvsn.adb b/gcc/ada/gnatvsn.adb
index 578a1aa9743..d6d2a5a3ace 100644
--- a/gcc/ada/gnatvsn.adb
+++ b/gcc/ada/gnatvsn.adb
@@ -53,7 +53,7 @@ package body Gnatvsn is
-- version.c using the zero-based convention of the C language.
-- The size is not the real one, which does not matter since we will
-- check for the nul character in Gnat_Version_String.
- pragma Import (C, Version_String, "version_string");
+ pragma Import (C, Version_String, "gnat_version_string");
-------------------------
-- Gnat_Version_String --
diff --git a/gcc/ada/version.c b/gcc/ada/version.c
new file mode 100644
index 00000000000..e6cc6124040
--- /dev/null
+++ b/gcc/ada/version.c
@@ -0,0 +1,34 @@
+/****************************************************************************
+ * *
+ * GNAT COMPILER COMPONENTS *
+ * *
+ * V E R S I O N *
+ * *
+ * C Implementation File *
+ * *
+ * Copyright (C) 2021, Free Software Foundation, Inc. *
+ * *
+ * GNAT is free software; you can redistribute it and/or modify it under *
+ * terms of the GNU General Public License as published by the Free Soft- *
+ * ware Foundation; either version 3, or (at your option) any later ver- *
+ * sion. GNAT is distributed in the hope that it will be useful, but WITH- *
+ * OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY *
+ * or FITNESS FOR A PARTICULAR PURPOSE. *
+ * *
+ * As a special exception under Section 7 of GPL version 3, you are granted *
+ * additional permissions described in the GCC Runtime Library Exception, *
+ * version 3.1, as published by the Free Software Foundation. *
+ * *
+ * You should have received a copy of the GNU General Public License and *
+ * a copy of the GCC Runtime Library Exception along with this program; *
+ * see the files COPYING3 and COPYING.RUNTIME respectively. If not, see *
+ * <http://www.gnu.org/licenses/>. *
+ * *
+ * GNAT was originally developed by the GNAT team at New York University. *
+ * Extensive contributions were provided by Ada Core Technologies Inc. *
+ * *
+ ****************************************************************************/
+
+#include "version.h"
+
+char gnat_version_string[] = version_string;
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-05-10 19:10 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-10 18:52 [gcc(refs/users/marxin/heads/fix-ada-version)] Fix missing version_string in Ada Martin Liska
-- strict thread matches above, loose matches on Subject: below --
2021-05-10 19:10 Martin Liska
2021-05-10 9:06 Martin Liska
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).