changeset 2055:1523f75dc160

[project @ 1996-04-07 04:05:50 by jwe]
author jwe
date Sun, 07 Apr 1996 04:07:59 +0000
parents ec7dd9f85f42
children 3e7017491d3f
files liboctave/Makefile.in src/Makefile.in
diffstat 2 files changed, 25 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/liboctave/Makefile.in
+++ b/liboctave/Makefile.in
@@ -92,9 +92,12 @@
 
 LIBOCTAVE_DEPEND := $(patsubst %, liboctave.a(%), $(OBJECTS))
 
-all: safe-stat.h safe-lstat.h stamp-picdir liboctave.a stamp-shared
+all: stamp-prereq stamp-picdir liboctave.a stamp-shared
 .PHONY: all
 
+stamp-prereq: safe-stat.h safe-lstat.h
+	touch stamp-prereq
+
 stamp-picdir:
 	if [ -n "$(CXXPICFLAG)" ]; then \
 	  if [ -d pic ]; then true; else mkdir pic ; fi ; \
@@ -187,12 +190,12 @@
 .PHONY: mostlyclean
 
 distclean: clean
-	rm -f Makefile so_locations stamp-picdir stamp-shared
+	rm -f Makefile so_locations stamp-picdir stamp-shared stamp-prereq
 	-rmdir pic
 .PHONY: distclean
 
 maintainer-clean: distclean
-	rm -f tags TAGS stamp-picdir stamp-shared
+	rm -f tags TAGS stamp-picdir stamp-shared stamp-prereq
 	-rmdir pic
 .PHONY: maintainer-clean
 
@@ -204,6 +207,11 @@
 	ln $(DISTFILES) ../`cat ../.fname`/liboctave
 .PHONY: dist
 
+# If missing, GNU make attempts to create them in the reverse of the
+# order in which they are listed here.  We rely on that fact to ensure
+# that the safe-stat.h and safe-lstat.h files are created before trying
+# to create the .d files.  Hmm.  I wonder if we can count on that...
+
 ifndef omit_deps
--include $(MAKEDEPS)
+-include $(MAKEDEPS) stamp-prereq
 endif
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -166,10 +166,13 @@
 	octave.gperf octave.cc parse.cc lex.cc y.tab.h \
 	$(INCLUDES) $(DLD_SRC) $(SOURCES) $(TEMPLATE_SRC) $(TI_SRC)
 
-all: defaults.h stamp-picdir libraries \
+all: stamp-prereq stamp-picdir libraries \
 	$(OCT_FILES) octave
 .PHONY: all
 
+stamp-prereq: defaults.h
+	touch stamp-prereq
+
 octave: octave.o builtins.o $(DLD_STATIC_OBJ) libraries
 	$(CXX) $(CPPFLAGS) $(ALL_CXXFLAGS) $(ALL_LDFLAGS) -o octave \
 	octave.o builtins.o $(DLD_STATIC_OBJ) \
@@ -268,13 +271,13 @@
 
 distclean: clean
 	rm -f Makefile octave .fname so_locations
-	rm -f stamp-picdir stamp-tinst stamp-interp
+	rm -f stamp-picdir stamp-tinst stamp-interp stamp-prereq
 	-rmdir pic
 .PHONY: distclean
 
 maintainer-clean: distclean
-	rm -f tags TAGS y.tab.c y.tab.h y.output yy.lex.c lex.cc \
-	rm -f parse.cc oct-gperf.h stamp-picdir stamp-tinst stamp-interp
+	rm -f tags TAGS y.tab.c y.tab.h y.output yy.lex.c lex.cc parse.cc
+	rm -f oct-gperf.h stamp-picdir stamp-tinst stamp-interp stamp-prereq
 	-rmdir pic
 .PHONY: maintainer-clean
 
@@ -330,6 +333,11 @@
 check: all
 .PHONY: check
 
+# If missing, GNU make attempts to create them in the reverse of the
+# order in which they are listed here.  We rely on that fact to ensure
+# that defaults.h is created before trying to create the .d files.
+# Hmm.  I wonder if we can count on that...
+
 ifndef omit_deps
--include $(MAKEDEPS)
+-include $(MAKEDEPS) stamp-prereq
 endif