From 7c0ae5f17f84a9282e30e828aa06fe4d441ca566 Mon Sep 17 00:00:00 2001 From: Doug Evans Date: Mon, 21 Jul 1997 18:05:29 +0000 Subject: [PATCH] (Makefile): Depend on config.status instead of configure. (config.status): Depend on configure. Run config.status --recheck if out of date. From-SVN: r14511 --- gcc/Makefile.in | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/gcc/Makefile.in b/gcc/Makefile.in index 7f80ab3..a9e9469 100644 --- a/gcc/Makefile.in +++ b/gcc/Makefile.in @@ -651,7 +651,7 @@ T = # Avoid a lot of time thinking about remaking Makefile.in and *.def. .SUFFIXES: .in .def -Makefile: $(srcdir)/Makefile.in $(srcdir)/configure $(srcdir)/version.c \ +Makefile: $(srcdir)/Makefile.in config.status $(srcdir)/version.c \ $(xmake_file) $(tmake_file) \ $(LANG_MAKEFILES) $(SHELL) $(srcdir)/configure.frag $(srcdir) "$(SUBDIRS)" @@ -663,6 +663,9 @@ $(srcdir)/configure: $(srcdir)/configure.in cd $(srcdir); autoconf # cstamp-h.in controls rebuilding of config.in. +# It is named cstamp-h.in and not stamp-h.in so the mostlyclean rule doesn't +# delete it. A stamp file is needed as autoheader won't update the file if +# nothing has changed. # It remains in the source directory and is part of the distribution. # This follows what is done in shellutils, fileutils, etc. # ??? Newer versions have a maintainer mode that may be useful here. @@ -674,6 +677,17 @@ config.h: cstamp-h ; @true cstamp-h: config.in config.status CONFIG_HEADERS=config.h:config.in $(SHELL) config.status +# Really, really stupid make features, such as SUN's KEEP_STATE, may force +# a target to build even if it is up-to-date. So we must verify that +# config.status does not exist before failing. +config.status: configure + @if [ ! -f config.status ] ; then \ + echo You must configure gcc. Look at the INSTALL file for details.; \ + false; \ + else \ + $(SHELL) config.status --recheck; \ + fi + all.internal: start.encap rest.encap # This is what to compile if making a cross-compiler. # Note that we can compile enquire using the cross-compiler just built, @@ -697,17 +711,6 @@ PROTO: proto # Tell GNU make these are phony targets. .PHONY: C c PROTO proto -# Really, really stupid make features, such as SUN's KEEP_STATE, may force -# a target to build even if it is up-to-date. So we must verify that -# config.status does not exist before failing. -config.status: - @if [ ! -f config.status ] ; then \ - echo You must configure gcc. Look at the INSTALL file for details.; \ - false; \ - else \ - true; \ - fi - # On the target machine, finish building a cross compiler. # This does the things that can't be done on the host machine. rest.cross: $(LIBGCC) gfloat.h specs -- 2.7.4