This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] ada/36001: Define GNATMAKE when building from the gcc subdirectory


GNATMAKE is undefined in the following invocation, leading to a
build error if, for example, einfo has changed and xeinfo needs to
be built and run:

  make -C gcc gnat1

This invocation is commonly used to build a modified gnat1 during
development.

This patch adds the substitution of GNATMAKE and GNATBIND into
gcc/Makefile.in in addition to the top-level one. The substitution
in the top-level Makefile.in has been kept because it makes it easier
to override this choice from the top-level directory, since it will
the override the extra definition in gcc/Makefile.in.

However, I don't seem to have the right libtool version. What is the
version to use to regenerate gcc/aclocal.m4 and gcc/configure?

    gcc/
	PR ada/36001
	* Makefile.in: Substitute GNATMAKE and GNATBIND.
	* configure.ac: Add call to ACX_PROG_GNAT.

Tested on i686-pc-linux-gnu, with and without Ada. Ok for trunk if
I can figure out how to properly regenerate other files? (or if
someone volunteers to do so)
---
 gcc/Makefile.in  |    4 ++++
 gcc/configure.ac |    2 ++
 2 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/gcc/Makefile.in b/gcc/Makefile.in
index 2e3da2c..dabb3c6 100644
--- a/gcc/Makefile.in
+++ b/gcc/Makefile.in
@@ -872,6 +872,10 @@ LIBS = @LIBS@ $(CPPLIB) $(LIBINTL) $(LIBICONV) $(LIBIBERTY) $(LIBDECNUMBER)
 # Any system libraries needed just for GNAT.
 SYSLIBS = @GNAT_LIBEXC@
 
+# Used from ada/Make-lang.in
+GNATBIND = @GNATBIND@
+GNATMAKE = @GNATMAKE@
+
 # Libs needed (at present) just for jcf-dump.
 LDEXP_LIB = @LDEXP_LIB@
 
diff --git a/gcc/configure.ac b/gcc/configure.ac
index 61d0d10..c464136 100644
--- a/gcc/configure.ac
+++ b/gcc/configure.ac
@@ -943,6 +943,8 @@ case $gcc_cv_collect2_libs in
 esac
 AC_SUBST(COLLECT2_LIBS)
 
+ACX_PROG_GNAT
+
 # When building Ada code on Alpha, we need exc_resume which is usually in
 # -lexc.  So test for it.
 save_LIBS="$LIBS"
-- 
1.5.5.1.406.g126ce


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]