FILEROOT= SHELL=/bin/sh VERSION=1.2 LATEX=pdflatex TEXFILES=ryesample.tex BIBFILES=ryesample.bib FIGS=figure1.pdf FILES=README ryethesis.ins ryethesis.dtx ryethesis.pdf ryesample.pdf Makefile TEXMFFLAGS=-file-line-error -halt-on-error -interaction=batchmode TARGETS=ryethesis.cls ryethesis.pdf ryesample.pdf ryethesis-$(VERSION).zip all: $(TARGETS) .PHONY: again.and.again again.and.again: @if [ $(MAKELEVEL) = 4 ]; then \ echo "Too many nesting levels of make!"; exit 1; \ fi @$(LATEX) $(TEXMFFLAGS) $(FILEROOT) || ( rm -f $(FILEROOT).pdf && exit 2) @bibtex -terse $(FILEROOT) @if [ -f $(FILEROOT).ist ]; then makeglossaries -q $(FILEROOT) ; fi @if [ -f $(FILEROOT).idx ]; then makeindex -q $(FILEROOT) ; fi @if [ -f $(FILEROOT).glo ]; then makeindex -q $(FILEROOT).nlo -s nomencl.ist -o $(FILEROOT).nls; fi @$(LATEX) $(TEXMFFLAGS) $(FILEROOT) || ( rm -f $(FILEROOT).pdf && exit 2) @if `grep -q -e "There were undefined references" -e "There were multiply-defined labels" -e "Label(s) may have changed. Rerun to get cross-references right" $(FILEROOT).log`; \ then $(MAKE) FILEROOT=$(FILEROOT) again.and.again; \ fi clean: @rm -rf $(TARGETS) *.aux *.lof *.lot *.loa *.log *.bbl *.blg *.ind *.ilg *.toc *.idx *.gls *.glo *.out *~ *.nls *.nlo *.ist *.toa *.glg auto ryesample.pdf: Makefile ${TEXFILES} ${BIBFILES} ${FIGS} $(MAKE) FILEROOT=ryesample again.and.again ryethesis.pdf: Makefile ryethesis.dtx $(LATEX) $(TEXMFFLAGS) ryethesis.dtx $(LATEX) $(TEXMFFLAGS) ryethesis.dtx ryethesis.cls: Makefile ryethesis.ins $(LATEX) $(TEXMFFLAGS) ryethesis.ins ryethesis-$(VERSION).zip: ${FILES} ${TEXFILES} ${BIBFILES} ${FIGS} zip $@ $^