--- gforth/Makefile.in 1998/12/20 11:20:28 1.132 +++ gforth/Makefile.in 1998/12/22 21:17:13 1.135 @@ -278,7 +278,7 @@ ARCHS = \ arch/shboom/sh.p \ arch/shboom/doers.fs -SOURCES = $(CVSDIRS) compat Makefile.in engine/Makefile.in gforthmi.in \ +SOURCES = $(CVSDIRS) compat Makefile.in Makedist.in engine/Makefile.in gforthmi.in \ configure.in configure config.sub config.guess elisp-comp missing \ acconfig.h acinclude.m4 engine/config.h.in stamp-h.in \ install-sh INSTALL INSTALL.BINDIST NEWS README ToDo BUGS model \ @@ -314,7 +314,7 @@ FORTH_GEN1 = $(FORTH_GEN0) @kernel_fi@ DOCDIST = doc/gforth.info doc/gforth.info-* doc/gforth.txt doc/gforth.ps #stuff in a binonly distribution -BINONLYDIST = config.status Makefile gforth$(EXE) gforth-ditc$(EXE) \ +BINONLYDIST = config.status Makefile Makedist gforth$(EXE) gforth-ditc$(EXE) \ $(OBJECTS0) $(OBJECTS) $(OBJECTS_DITC)\ arch/$(machine)/machine.h engine/config.h engine/Makefile \ stamp-h kernel/version.fs version-stamp \ @@ -324,7 +324,7 @@ KERNLS = kernl16b.fi- kernl16l.fi- \ kernl32b.fi- kernl32l.fi- \ kernl64b.fi- kernl64l.fi- -GEN_PRECIOUS = $(FORTH_GEN) $(KERNLS) doc/gforth.texi doc/gforth.dvi doc/gforth.ps Makefile engine/Makefile configure +GEN_PRECIOUS = $(FORTH_GEN) $(KERNLS) doc/gforth.texi doc/gforth.dvi doc/gforth.ps Makefile Makedist engine/Makefile configure #standards.info recommends this: .SUFFIXES: @@ -378,7 +378,7 @@ clean: mostlyclean distclean: clean -$(RM) config.cache config.log config.status \ - engine/config.h Makefile engine/Makefile \ + engine/config.h Makefile Makedist engine/Makefile \ stamp-h engine/stamp-h \ doc/version.texi gforthmi @@ -391,78 +391,32 @@ virtualclean: mostlyclean -$(RM) -rf gforth.fns gforth.texi gforth.ps gforth.info* \ gforth-$(VERSION).tar.gz config.cache *~ */*~ -#use dist targets only when srcdir=. -dist: $(SOURCES) $(FORTH_GEN0) @KERNEL@ $(DOCDIST) - -$(RMTREE) gforth-$(VERSION) - mkdir gforth-$(VERSION) - $(TAR) $(SOURCES) $(FORTH_GEN0) @KERNEL@ $(DOCDIST) | \ - (cd gforth-$(VERSION); tar xf -) - $(TAR) gforth-$(VERSION)|gzip -9 >gforth-$(VERSION).tar.gz - -$(RMTREE) gforth-$(VERSION) - -#use dist targets only when srcdir=. -dosdist: $(SOURCES) $(FORTH_GEN0) @KERNEL@ $(DOCDIST) - -$(RMTREE) gforth.$(DOSVERSION) - mkdir gforth.$(DOSVERSION) - $(TAR) $(SOURCES) $(FORTH_GEN0) @KERNEL@ $(DOCDIST) | \ - (cd gforth.$(DOSVERSION); tar xf -) - $(MV) gforth.$(DOSVERSION)/engine/strsignal.c gforth.$(DOSVERSION)/engine/strsig.c - for i in 1 2 3 4 5 6 7 8; do \ - $(MV) gforth.$(DOSVERSION)/doc/gforth.info-$$i gforth.$(DOSVERSION)/doc/gforth.i$$i; \ - done - zip -r9 gf$(DOSVERSION)dos.zip gforth.$(DOSVERSION)/* - -$(RMTREE) gforth.$(DOSVERSION) +#Some makes (Ultrix, SunOS, IRIX) are so broken, they cannot read the +#Makefile if it contains our dist rules. Therefore we have put these +#rules in Makedist (you can use them with GNU make on these systems). +dist: Makedist + $(MAKE) -f Makedist d$@ + +dosdist: Makedist + $(MAKE) -f Makedist d$@ + +srcdist: Makedist + $(MAKE) -f Makedist d$@ + +srconlydist: Makedist + $(MAKE) -f Makedist d$@ -#A source distribution contains only the things needed to install gforth, -#without the documents. -srcdist: $(SOURCES) $(FORTH_GEN0) @KERNEL@ - -$(RMTREE) gforth-$(VERSION) - mkdir gforth-$(VERSION) - $(TAR) $(SOURCES) $(FORTH_GEN0) @KERNEL@ | \ - (cd gforth-$(VERSION); tar xf -) - $(TAR) gforth-$(VERSION)|gzip -9 >gforth-src-$(VERSION).tar.gz - -$(RMTREE) gforth-$(VERSION) - -srconlydist: $(SOURCES) - -$(RMTREE) gforth-$(VERSION) - mkdir gforth-$(VERSION) - $(TAR) $(SOURCES) | \ - (cd gforth-$(VERSION); tar xf -) - $(TAR) gforth-$(VERSION)|gzip -9 >gforth-srconly-$(VERSION).tar.gz - -$(RMTREE) gforth-$(VERSION) - -#A document distribution contains only the documents, which can be created -#with MAKE. -docdist: $(DOCDIST) - -$(RMTREE) gforth-$(VERSION) - mkdir gforth-$(VERSION) - $(TAR) $(DOCDIST) | (cd gforth-$(VERSION); tar xf -) - $(TAR) gforth-$(VERSION)|gzip -9 >gforth-doc-$(VERSION).tar.gz - -$(RMTREE) gforth-$(VERSION) - -#a binary distribution contains the complete source distribution, -# the objects, the executable and the links. the objects are there for making -# make happy. -bindist: $(SOURCES) $(FORTH_GEN0) @KERNEL@ $(DOCDIST) $(BINONLYDIST) - -$(RMTREE) gforth-$(VERSION) - mkdir gforth-$(VERSION) - $(TAR) $(SOURCES) $(FORTH_GEN0) @KERNEL@ $(DOCDIST) $(BINONLYDIST) | (cd gforth-$(VERSION); tar xf -) - strip gforth-$(VERSION)/gforth - $(TAR) gforth-$(VERSION)|gzip -9 >gforth-$(VERSION)-@host@.tar.gz - -#makes a package with only the stuff not present in the source -#package. For installation the source package is still needed! -#This is useful if you want to distribute many binary versions in -#little space (e.g., on floppy disk): Put the source package and -#all the binonly packages you are interested in on the disk. The user -#then just has to unpack the source and his favourite binonly into the -#same directory and has a full binary distribution. -binonlydist: $(SOURCES) $(FORTH_GEN0) @KERNEL@ $(DOCDIST) $(BINONLYDIST) - -$(RMTREE) gforth-$(VERSION) - mkdir gforth-$(VERSION) - $(TAR) $(BINONLYDIST) | (cd gforth-$(VERSION); tar xf -) - strip gforth-$(VERSION)/gforth - $(TAR) gforth-$(VERSION)|gzip -9 >gforth-$(VERSION)-binonly-@host@.tar.gz +docdist: Makedist + $(MAKE) -f Makedist d$@ + +htmldist: Makedist + $(MAKE) -f Makedist d$@ + +bindist: Makedist + $(MAKE) -f Makedist d$@ + +binonlydist: Makedist + $(MAKE) -f Makedist d$@ #strip gforth, because the debugging stuff is hardly useful once @@ -473,7 +427,7 @@ binonlydist: $(SOURCES) $(FORTH_GEN0) @K #hard to generate) install: gforth$(EXE) $(FORTH_SRC) $(kernel_fi) gforth.fi gforthmi doc/gforth.1 prim install.TAGS installdirs touch $(datadir)/gforth/site-forth/siteinit.fs - -$(RM) $(bindir)/gforth$(EXE) $(bindir)/gforth-$(VERSION)$(EXE) + -$(RM) $(bindir)/gforth$(EXE) $(bindir)/gforth-$(VERSION)$(EXE) $(bindir)/gforthmi $(INSTALL_PROGRAM) -s gforth$(EXE) $(bindir)/gforth-$(VERSION)$(EXE) $(LN_S) $(bindir)/gforth-$(VERSION)$(EXE) $(bindir)/gforth$(EXE) $(INSTALL_PROGRAM) gforthmi $(bindir)/gforthmi-$(VERSION) @@ -722,10 +676,7 @@ stamp-h: engine/config.h.in config.statu CONFIG_FILES=$@ CONFIG_HEADERS=engine/config.h ./config.status echo timestamp > stamp-h -Makefile: Makefile.in engine/Makefile.in config.status - CONFIG_FILES="$@ engine/$@" CONFIG_HEADERS=engine/config.h ./config.status - -gforthmi: gforthmi.in config.status +Makefile Makedist engine/Makefile gforthmi: Makefile.in Makedist.in engine/Makefile.in gforthmi.in config.status CONFIG_FILES="$@" CONFIG_HEADERS=engine/config.h ./config.status config.status: configure