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]

Re: what's up with automake?


On Aug 16, 2000, Alexandre Oliva <oliva@lsd.ic.unicamp.br> wrote:

> On Aug 16, 2000, Benjamin Kosnik <bkoz@redhat.com> wrote:
>>> 
>>> rc.gcc/libstdc++-v3/src -I.. 1 -g -O2 -fvtable-thunks -D_GNU_SOURCE -fno-implic
>>> ^
>>> This looks like it is part of CXXFLAGS, passed down from top-level configure.

>> Correction. This looks like it's from INCLUDES. . . for some reason 
>> src/Makefile.in has:

>> INCLUDES = 1

> Uh oh.  This is a bug in old (i.e., not relatively current CVS)
> version of automake.

> The problem is that the namespace of macros and targets clashes.

> We'll have to rename the INCLUDES target to libstdcxx_INCLUDES or
> something alike, and change the top-level configure.in to use it :-(

I'm checking this in:

Index: ChangeLog
from  Alexandre Oliva  <aoliva@redhat.com>

	* configure.in (libstdcxx_flags): Use
	libstdc++-v3/src/libstdc++.INC.

Index: libstdc++-v3/ChangeLog
from  Alexandre Oliva  <aoliva@redhat.com>

	* src/Makefile.am (libstdc++.INC): Renamed from INCLUDES.
	* src/Makefile.in: Regenerate.

Index: configure.in
===================================================================
RCS file: /cvs/gcc/egcs/configure.in,v
retrieving revision 1.66
diff -u -p -r1.66 configure.in
--- configure.in	2000/08/15 07:49:58	1.66
+++ configure.in	2000/08/16 18:27:00
@@ -51,7 +51,7 @@ fi
 if [ "${enable_libstdcxx_v3}" = "yes" ] && test -d $srcdir/libstdc++-v3; then
         libstdcxx_version="target-libstdc++-v3"
 	# Don't use libstdc++-v3's flags to configure/build itself.
-	libstdcxx_flags='`case $$dir in libstdc++-v3) ;; *) cat $$r/$(TARGET_SUBDIR)/libstdc++-v3/src/INCLUDES 2>/dev/null || : ;; esac` -L$$r/$(TARGET_SUBDIR)/libstd++-v3/src -L$$r/$(TARGET_SUBDIR)/libstd++-v3/src/.libs'
+	libstdcxx_flags='`case $$dir in libstdc++-v3) ;; *) cat $$r/$(TARGET_SUBDIR)/libstdc++-v3/src/libstdc++.INC 2>/dev/null || : ;; esac` -L$$r/$(TARGET_SUBDIR)/libstd++-v3/src -L$$r/$(TARGET_SUBDIR)/libstd++-v3/src/.libs'
 else
         libstdcxx_version="target-libio target-libstdc++"
         libstdcxx_flags='-isystem $$s/libstdc++ -isystem $$s/libstdc++/std -isystem $$s/libstdc++/stl -isystem $$s/libio -L$$r/$(TARGET_SUBDIR)/libstdc++'
Index: libstdc++-v3/src/Makefile.am
===================================================================
RCS file: /cvs/gcc/egcs/libstdc++-v3/src/Makefile.am,v
retrieving revision 1.27
diff -u -p -r1.27 Makefile.am
--- libstdc++-v3/src/Makefile.am	2000/08/16 04:11:29	1.27
+++ libstdc++-v3/src/Makefile.am	2000/08/16 18:27:01
@@ -314,14 +314,14 @@ wstring-inst.o: string-inst.cc
 wstring-inst.lo: string-inst.cc
 	$(LTCXXCOMPILE) -fimplicit-templates -c -DC=wchar_t $< -o $@
 
-all: INCLUDES
-INCLUDES: Makefile
+all: libstdc++.INC
+libstdc++.INC: Makefile
 	$(MAKE) \
 	  top_builddir=`CDPATH=:. && cd $(top_builddir) && pwd` \
 	  top_srcdir=`CDPATH=:. && cd $(top_srcdir) && pwd` \
-	  tmp-INCLUDES
-	-rm -f INCLUDES
-	mv tmp-INCLUDES INCLUDES
+	  tmp-$@
+	-rm -f $@
+	mv tmp-$@ $@
 
-tmp-INCLUDES: Makefile
+tmp-libstdc++.INC: Makefile
 	echo -I$(top_builddir) $(INCLUDES) > $@
Index: libstdc++-v3/src/Makefile.in
===================================================================
RCS file: /cvs/gcc/egcs/libstdc++-v3/src/Makefile.in,v
retrieving revision 1.35
diff -u -p -r1.35 Makefile.in
--- libstdc++-v3/src/Makefile.in	2000/08/16 05:00:29	1.35
+++ libstdc++-v3/src/Makefile.in	2000/08/16 18:27:01
@@ -515,16 +515,16 @@ wstring-inst.o: string-inst.cc
 wstring-inst.lo: string-inst.cc
 	$(LTCXXCOMPILE) -fimplicit-templates -c -DC=wchar_t $< -o $@
 
-all: INCLUDES
-INCLUDES: Makefile
+all: libstdc++.INC
+libstdc++.INC: Makefile
 	$(MAKE) \
 	  top_builddir=`CDPATH=:. && cd $(top_builddir) && pwd` \
 	  top_srcdir=`CDPATH=:. && cd $(top_srcdir) && pwd` \
-	  tmp-INCLUDES
-	-rm -f INCLUDES
-	mv tmp-INCLUDES INCLUDES
+	  tmp-$@
+	-rm -f $@
+	mv tmp-$@ $@
 
-tmp-INCLUDES: Makefile
+tmp-libstdc++.INC: Makefile
 	echo -I$(top_builddir) $(INCLUDES) > $@
 
 # Tell versions [3.59,3.63) of GNU make to not export all variables.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist    *Please* write to mailing lists, not to me

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