hash.o should use $(GCONFIG_H)

Zack Weinberg zackw@stanford.edu
Mon Mar 19 10:40:00 GMT 2001


I've installed the appended patch as an obvious bugfix.  Files
compiled with -DGENERATOR_FILE need to depend on $(GCONFIG_H), not
$(CONFIG_H).  This does not cause any actual problems for hash.o, but
in general, if you don't do that you're liable to get a dependency
loop.

It is not clear to me why hash.o needs -DGENERATOR_FILE; it is only
linked into cc1 and maybe collect2, and does nothing special...

zw

	* Makefile.in (hash.o): Depend on $(GCONFIG_H), not $(CONFIG_H).

===================================================================
Index: Makefile.in
--- Makefile.in	2001/03/19 17:36:46	1.623
+++ Makefile.in	2001/03/19 18:39:44
@@ -1215,7 +1215,7 @@ collect2.o : collect2.c $(CONFIG_H) syst
 	-c $(srcdir)/collect2.c
 
 tlink.o: tlink.c $(DEMANGLE_H) hash.h $(CONFIG_H) system.h collect2.h intl.h
-hash.o: hash.c hash.h system.h toplev.h $(CONFIG_H)
+hash.o: hash.c hash.h system.h toplev.h $(GCONFIG_H)
 	$(CC) -c $(ALL_CFLAGS) -DGENERATOR_FILE $(ALL_CPPFLAGS) $(INCLUDES) $< $(OUTPUT_OPTION)
 
 vfprintf.o: $(srcdir)/../libiberty/vfprintf.c $(GCONFIG_H) system.h



More information about the Gcc-patches mailing list