From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24212 invoked by alias); 7 Mar 2016 03:15:18 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 38108 Received: (qmail 27295 invoked from network); 7 Mar 2016 03:15:16 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.1 X-Biglobe-Sender: Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 6.6 \(1510\)) Subject: Re: zsh manual - missing bookmarks in pdf file? From: "Jun T." In-Reply-To: <20160304150852.4b4bfe08@pwslap01u.europe.root.pri> Date: Mon, 7 Mar 2016 12:15:11 +0900 Content-Transfer-Encoding: 7bit Message-Id: <0E9AF03F-FFBA-47FD-A5A2-33C95722C708@kba.biglobe.ne.jp> References: <22229.42616.86422.222557@lwm.klanderman.net> <87vb55leop.fsf@lwm.klanderman.net> <194AAF32-4EB5-412D-A200-27AE7832EF86@kba.biglobe.ne.jp> <87egbs7usn.fsf@lwm.klanderman.net> <1850B214-73A8-4373-A9AE-0C533702A6CD@kba.biglobe.ne.jp> <87si07lj6s.fsf@lwm.klanderman.net> <36FD86DF-3BA9-4277-B587-38EC212BDDEB@kba.biglobe.ne.jp> <20160304150852.4b4bfe08@pwslap01u.europe.root.pri> To: "zsh-workers@zsh.org" X-Mailer: Apple Mail (2.1510) X-Biglobe-Spnum: 58251 On 2016/03/05, at 0:08, Peter Stephenson wrote: > On Fri, 4 Mar 2016 23:25:40 +0900 > Jun T. wrote: >> is it really >> necessary to check for pdfetex? > > It probably was originally there for older versions of texi2dvi, but > that doesn't mean it's necessarily still needed. I've removed the check for pdfetex. Also added a fix to use zsh_{a4,us}.dvi for creating zsh_{a4,us}.ps. # Currently, zsh_us.ps has almost zero bottom margin. diff --git a/Config/defs.mk.in b/Config/defs.mk.in index 3c84610..2bc1748 100644 --- a/Config/defs.mk.in +++ b/Config/defs.mk.in @@ -79,8 +79,6 @@ ANSI2KNR = @ANSI2KNR@ YODL = @YODL@ @YODL_OPTIONS@ YODL2TXT = @YODL@2txt YODL2HTML = @YODL@2html -PDFETEX = @PDFETEX@ -TEXI2PDF = @TEXI2PDF@ # install utility INSTALL_PROGRAM = @INSTALL_PROGRAM@ diff --git a/Doc/Makefile.in b/Doc/Makefile.in index d589991..2752096 100644 --- a/Doc/Makefile.in +++ b/Doc/Makefile.in @@ -39,9 +39,11 @@ LN_S = @LN_S@ @DEFS_MK@ MAKEINFO = makeinfo -TEXI2DVI = texi2dvi +TEXI2DVI = @TEXI2DVI@ DVIPS = dvips +TEXI2PDF = @TEXI2PDF@ TEXI2HTML = @TEXI2HTML@ +PAPERSIZE = @PAPERSIZE@ .SUFFIXES: .yo .1 @@ -86,33 +88,41 @@ Zsh/seealso.yo Zsh/tcpsys.yo Zsh/zftpsys.yo Zsh/zle.yo all: man $(runhelp) texi ../META-FAQ .PHONY: all -everything: all dvi html pdf info +everything: all html info zsh_a4.dvi zsh_us.dvi zsh_a4.pdf zsh_us.pdf \ + intro.a4.pdf intro.us.pdf .PHONY: everything dvi: zsh.dvi .PHONY: dvi -zsh.dvi: $(sdir)/zsh.texi - $(TEXI2DVI) $(sdir)/zsh.texi +zsh.dvi zsh_a4.dvi zsh_us.dvi: $(sdir)/zsh.texi + if test $@ = zsh_us.dvi || \ + { test $@ = zsh.dvi && test "$(PAPERSIZE)" = us; }; then \ + $(TEXI2DVI) -o $@ $(sdir)/zsh.texi; \ + else \ + $(TEXI2DVI) -o $@ -t @afourpaper $(sdir)/zsh.texi; \ + fi -pdf: zsh.pdf intro.a4.pdf intro.us.pdf +pdf: zsh.pdf intro.pdf .PHONY: pdf -zsh.pdf: $(sdir)/zsh.texi - if [ x$(TEXI2PDF) != x ]; then \ - $(TEXI2PDF) $(sdir)/zsh.texi; \ +zsh.pdf zsh_a4.pdf zsh_us.pdf: $(sdir)/zsh.texi + if test $@ = zsh_us.pdf || \ + { test $@ = zsh.pdf && test "$(PAPERSIZE)" = us; }; then \ + $(TEXI2PDF) -o $@ $(sdir)/zsh.texi; \ else \ - PDFTEX=$(PDFETEX) $(TEXI2DVI) --pdf $(sdir)/zsh.texi; \ + $(TEXI2PDF) -o $@ -t @afourpaper $(sdir)/zsh.texi; \ fi # Use roff2ps / ps2pdf because pdfroff produces doubled output. -intro.a4.pdf: $(sdir)/intro.ms - roff2ps -ms -P-pa4 < $(sdir)/intro.ms > intro.a4.ps - ps2pdf intro.a4.ps - -intro.us.pdf: $(sdir)/intro.ms - roff2ps -ms -P-pletter < $(sdir)/intro.ms > intro.us.ps - ps2pdf intro.us.ps +intro.pdf intro.a4.pdf intro.us.pdf: $(sdir)/intro.ms + if test $@ = intro.us.pdf || \ + { test $@ = intro.pdf && test "$(PAPERSIZE)" = us; }; then \ + roff2ps -ms -P-pletter < $(sdir)/intro.ms > intro.ps; \ + else \ + roff2ps -ms -P-pa4 < $(sdir)/intro.ms > intro.ps; \ + fi; \ + ps2pdf -sOutputFile=$@ intro.ps texi: $(sdir)/zsh.texi .PHONY: texi @@ -149,14 +159,14 @@ ps: us_ps a4_ps us_ps: zsh_us.ps .PHONY: us_ps -zsh_us.ps: zsh.dvi - $(DVIPS) -t letter -o $@ zsh.dvi +zsh_us.ps: zsh_us.dvi + $(DVIPS) -t letter -o $@ zsh_us.dvi a4_ps: zsh_a4.ps .PHONY: a4_ps -zsh_a4.ps: zsh.dvi - $(DVIPS) -t a4 -o $@ zsh.dvi +zsh_a4.ps: zsh_a4.dvi + $(DVIPS) -t a4 -o $@ zsh_a4.dvi html: zsh_toc.html .PHONY: html diff --git a/Doc/ztexi.yo b/Doc/ztexi.yo index e878345..7d52e6e 100644 --- a/Doc/ztexi.yo +++ b/Doc/ztexi.yo @@ -53,7 +53,6 @@ def(texinfo)(2)(\ NOTRANS(\input texinfo.tex)+NL()\ NOTRANS(@c %**start of header)+NL()\ NOTRANS(@iftex)+NL()\ - NOTRANS(@afourpaper)+NL()\ NOTRANS(@setchapternewpage off)+NL()\ NOTRANS(@end iftex)+NL()\ NOTRANS(@setfilename )ARG1+NL()\ diff --git a/configure.ac b/configure.ac index 9947b16..9ce3a45 100644 --- a/configure.ac +++ b/configure.ac @@ -632,14 +632,24 @@ if test "x$ac_cv_prog_YODL" = xyodl; then fi AC_SUBST(YODL_OPTIONS) -AC_CHECK_PROGS([PDFETEX], [pdfetex], [: pdfetex]) -AC_CHECK_PROGS([TEXI2PDF], [texi2pdf], []) +AC_CHECK_PROGS([TEXI2DVI], [texi2dvi], [: texi2dvi]) +AC_CHECK_PROGS([TEXI2PDF], [texi2pdf], [: texi2pdf]) AC_CHECK_PROGS([TEXI2HTML], [texi2any texi2html], [: texi2html]) +if test x"$TEXI2PDF" != xtexi2pdf && test x"$TEXI2DVI" = xtexi2dvi; then + TEXI2PDF='texi2dvi --pdf' +fi + if test x"$TEXI2HTML" = xtexi2any; then TEXI2HTML='texi2any -c TEXI2HTML=1' fi +case "$LC_PAPER" in + ??_US*) PAPERSIZE=us ;; + *) PAPERSIZE=a4 ;; +esac +AC_SUBST(PAPERSIZE) + AC_CHECK_PROGS([ANSI2KNR], [ansi2knr], [: ansi2knr]) if test x"$ansi2knr" = xyes && test x"$ANSI2KNR" = x": ansi2knr"; then