meillo@0: NAME = thesis meillo@174: CHAPS = style front.roff dedication.roff toc.roff \ meillo@184: preface.roff intro.roff discussion.roff summary.roff tools.roff \ meillo@184: refs.roff official.roff colophon.roff meillo@197: BIB = bib *.bib meillo@0: PDFFLAGS = -sPAPERSIZE=a4 -dPDFSETTINGS=/prepress meillo@197: REFER = refer -n -p bib -p mail.bib -p web.bib -e -P -sLAD -l,2 -k meillo@0: meillo@0: all: $(NAME).ps meillo@0: meillo@197: $(NAME).ps: $(CHAPS) makefile $(BIB) toc.ig refs.ig meillo@150: export TROFFONTS=fonts;\ meillo@150: soelim $(CHAPS) | $(REFER) | \ meillo@184: tbl | grap | pic | troff -Tps -ms 2>err.ig | dpost >$@ meillo@79: meillo@79: err.ig: $(CHAPS) meillo@150: export TROFFONTS=fonts;\ meillo@150: soelim $(CHAPS) | $(REFER) | \ meillo@184: tbl | grap | pic | troff -Tps -ms -rZ1 -z 2>$@ meillo@79: meillo@79: toc.ig: err.ig meillo@113: sed -n '/^TOC____/s///p' err.ig >$@ meillo@0: meillo@156: refs.ig: err.ig meillo@156: mkdir -p refs meillo@176: awk -F '\t' '/^REF____/{ \ meillo@151: sub(/^REF____/,""); \ meillo@151: printf $$2 >"refs/"$$1; close("refs/$$1"); \ meillo@151: printf $$3 >"refs/"$$1".page"; close("refs/$$1.page");\ meillo@151: }' err.ig meillo@151: meillo@0: pdf: $(NAME).pdf meillo@0: $(NAME).pdf: $(NAME).ps meillo@115: ps2pdf $(PDFFLAGS) $(NAME).ps 2>/dev/null meillo@0: meillo@0: book: book.pdf meillo@0: book.pdf: book.ps meillo@115: ps2pdf $(PDFFLAGS) book.ps 2>/dev/null meillo@0: book.ps: $(NAME).ps meillo@0: psbook -s16 $(NAME).ps | psnup -2 -m2mm >$@ meillo@0: meillo@0: clean: meillo@0: rm -f $(NAME).ps $(NAME).pdf book.ps book.pdf meillo@156: rm -rf refs meillo@79: rm -f *.ig meillo@111: meillo@111: spell: meillo@121: sort -u -o terms terms meillo@111: spell +terms *.roff | egrep -v '[0-9a-f]{40}'