This is the mail archive of the
docbook@lists.oasis-open.org
mailing list for the DocBook project.
Re: page-numbering on Indexes
Jorge Godoy <godoy@conectiva.com.br> writes:
> (or the "bug" wouldn't exist in the TeX version too).
When using TeX one should run tex several times to get references
right. I always run jadetex three times to make sure the TeX gets the
references updated. Or do as Adam Di Carlo does (posted on this list
some weeks ago):
--------------- Adam Di Carlo solution ------------------
After each pass by JadeTeX, the .aux file is updated. In my
makefiles, I sometimes compare the .aux file prior to processing with
the file after processing, and make a decision based on that whether
to run again.
In this example Makefile snippet, we're using pdflatex directly, but
that doesn't matter, they all work the same. MAX_TEX_RECURSION needs
to be set to prevent infinite recursion (a tri-stable .aux file).
I've CC'd the SGMLtools list because this technique should be used there too.
%.pdf: %.tex
# note that I have seen bi-stable .aux files, thus we check two levels deep
-cp -pf prior.aux pprior.aux
-cp -pf $(shell basename $< .tex).aux prior.aux
# fail if we don't have pdflatex correctly installed
kpsewhich pdflatex.fmt > /dev/null
# due to a bug in debiandoc2latex2e output, this might fail
-pdflatex '\nonstopmode\input{$<}'
set -e ;\
if ! cmp $(shell basename $< .tex).aux prior.aux 2>/dev/null && \
! cmp $(shell basename $< .tex).aux pprior.aux 2>/dev/null &&\
expr $(MAKELEVEL) '<' $(MAX_TEX_RECURSION); then \
rm -f $@ ;\
$(MAKE) $@ ;\
fi
rm -f prior.aux pprior.aux
--
.....Adam Di Carlo....adam@onShore.com.....<URL:http://www.onShore.com/>