From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25415 invoked from network); 21 Feb 2000 02:12:11 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 21 Feb 2000 02:12:11 -0000 Received: (qmail 1812 invoked by alias); 21 Feb 2000 02:12:03 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 9798 Received: (qmail 1804 invoked from network); 21 Feb 2000 02:12:03 -0000 Date: Mon, 21 Feb 2000 02:12:01 +0000 From: Adam Spiers To: zsh workers mailing list Subject: PATCH: Re: duplicate targets in Makefile rule Message-ID: <20000221021201.A27957@thelonious.new.ox.ac.uk> Reply-To: Adam Spiers Mail-Followup-To: zsh workers mailing list References: <20000210170351.A19964@thelonious.new.ox.ac.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0.1i In-Reply-To: X-Home-Page: http://www.new.ox.ac.uk/~adam/ X-OS: Linux 2.2.12 i686 Zefram (zefram@fysh.org) wrote: > Adam Spiers wrote: > > zsh.dvi: $(sdir)/zsh.texi > >- $(TEXI2DVI) $(sdir)/zsh.texi > >+ $(TEXI2DVI) $< > > Not portable: $< does not portably exist *sigh* You learn something every day. Why is it not meaningful though, out of curiosity? This patch is instead of 9669. It's been sitting in my postponed folder for weeks (forgot to send it when I wrote it), so I hope it's still good. Last time I sent patches in I probably broke the record for the most incorrect patches submitted to zsh-workers in one day... apologies in advance if there's STILL something wrong with this. Index: Doc/Makefile.in =================================================================== RCS file: /projects/zsh/zsh/Doc/Makefile.in,v retrieving revision 1.1.1.60 diff -u -r1.1.1.60 Makefile.in --- Doc/Makefile.in 2000/02/07 01:59:21 1.1.1.60 +++ Doc/Makefile.in 2000/02/10 17:13:36 @@ -51,7 +51,7 @@ # yodl documentation -YODLDOC = $(MAN) zsh.texi +YODLDOC = $(MAN) texi MODDOCSRC = \ Zsh/mod_cap.yo Zsh/mod_clone.yo \ @@ -73,23 +73,28 @@ # ========== DEPENDENCIES FOR BUILDING ========== -all: $(MAN) zsh.texi ../META-FAQ +all: man texi ../META-FAQ .PHONY: all -everything: all zsh.dvi zsh_us.ps zsh_a4.ps zsh_toc.html +everything: all dvi ps html .PHONY: everything +dvi: zsh.dvi +.PHONY: dvi + zsh.dvi: $(sdir)/zsh.texi $(TEXI2DVI) $(sdir)/zsh.texi -zsh.texi $(sdir)/zsh.texi: - case $@ in \ - */*) target=$@ ;; \ - *) target=$(sdir)/$@ ;; \ - esac; \ - $(YODL) -o $$target -I$(sdir) -w ztexi.yo version.yo zsh.yo; \ - test -f $$target +texi: $(sdir)/zsh.texi +.PHONY: texi + +$(sdir)/zsh.texi: + $(YODL) -o $@ -I$(sdir) -w ztexi.yo version.yo zsh.yo; \ + test -f $@ +info: zsh.info +.PHONY: info + zsh.info: $(sdir)/zsh.texi $(MAKEINFO) $(sdir)/zsh.texi @@ -103,12 +108,24 @@ ;; esac; \ test -f $$target +ps: us_ps a4_ps +.PHONY: ps + +us_ps: zsh_us.ps +.PHONY: us_ps + zsh_us.ps: zsh.dvi $(DVIPS) -t letter -o $@ zsh.dvi +a4_ps: zsh_a4.ps +.PHONY: a4_ps + zsh_a4.ps: zsh.dvi $(DVIPS) -t a4 -o $@ zsh.dvi +html: zsh_toc.html +.PHONY: html + zsh_toc.html: $(sdir)/zsh.texi $(TEXI2HTML) $(sdir)/zsh.texi @@ -129,8 +146,11 @@ test -f $(sdir_top)/META-FAQ $(YODLDOC): version.yo + +$(sdir)/zsh.texi: $(YODLSRC) -zsh.texi: $(YODLSRC) +man: $(MAN) +.PHONY: man $(MAN): zmacros.yo zman.yo @@ -225,7 +245,7 @@ .PHONY: uninstall # install man pages, creating install directory if necessary -install.man: $(MAN) +install.man: man $(sdir_top)/mkinstalldirs $(DESTDIR)$(mandir)/man1 for file in $(MAN); do \ $(INSTALL_DATA) $(sdir)/$$file $(DESTDIR)$(mandir)/man1/`echo $$file | sed 's|zsh|$(tzsh)|'` || exit 1; \ @@ -233,7 +253,7 @@ .PHONY: install.man # install info pages, creating install directory if necessary -install.info: zsh.texi +install.info: texi $(sdir_top)/mkinstalldirs $(DESTDIR)$(infodir) rm -rf infodir mkdir infodir @@ -267,7 +287,7 @@ .PHONY: uninstall.info # install HTML manual -install.html: zsh_toc.html +install.html: html $(sdir_top)/mkinstalldirs $(DESTDIR)$(htmldir) for file in zsh_*.html; do \ $(INSTALL_DATA) $$file $(DESTDIR)$(htmldir) || exit 1; \