| [5ff188f] | 1 | ## Define the configuration variables. | 
|---|
| [038726d] | 2 |  | 
|---|
| [5ff188f] | 3 | Build = build | 
|---|
|  | 4 | Figures = figures | 
|---|
|  | 5 | Macros = ../LaTeXmacros | 
|---|
| [3b1825b] | 6 | TeXLIB = .:${Macros}:${Build}: | 
|---|
| [5ff188f] | 7 | LaTeX  = TEXINPUTS=${TeXLIB} && export TEXINPUTS && latex -halt-on-error -output-directory=${Build} | 
|---|
| [3b1825b] | 8 | BibTeX = BIBINPUTS=../bibliography: && export BIBINPUTS && bibtex | 
|---|
| [038726d] | 9 |  | 
|---|
| [5ff188f] | 10 | MAKEFLAGS = --no-print-directory --silent # | 
|---|
| [23c27039] | 11 | VPATH = ${Build} ${Figures} | 
|---|
| [5ff188f] | 12 |  | 
|---|
| [038726d] | 13 | ## Define the text source files. | 
|---|
|  | 14 |  | 
|---|
|  | 15 | SOURCES = ${addsuffix .tex, \ | 
|---|
|  | 16 | user \ | 
|---|
| [af4903b] | 17 | ../refrat/keywords \ | 
|---|
| [92c0f81] | 18 | ../refrat/operidents \ | 
|---|
| [038726d] | 19 | } | 
|---|
|  | 20 |  | 
|---|
|  | 21 | FIGURES = ${addsuffix .tex, \ | 
|---|
| [fbefc4d] | 22 | EHMHierarchy \ | 
|---|
| [6b6597c] | 23 | Cdecl \ | 
|---|
| [4096de0] | 24 | pointer1 \ | 
|---|
| [038726d] | 25 | } | 
|---|
|  | 26 |  | 
|---|
|  | 27 | PICTURES = ${addsuffix .pstex, \ | 
|---|
| [4096de0] | 28 | pointer2 \ | 
|---|
| [038726d] | 29 | } | 
|---|
|  | 30 |  | 
|---|
|  | 31 | PROGRAMS = ${addsuffix .tex, \ | 
|---|
|  | 32 | } | 
|---|
|  | 33 |  | 
|---|
|  | 34 | GRAPHS = ${addsuffix .tex, \ | 
|---|
|  | 35 | } | 
|---|
|  | 36 |  | 
|---|
|  | 37 | ## Define the documents that need to be made. | 
|---|
|  | 38 |  | 
|---|
|  | 39 | DOCUMENT = user.pdf | 
|---|
| [fb16d5c] | 40 | BASE = ${basename ${DOCUMENT}} | 
|---|
| [038726d] | 41 |  | 
|---|
|  | 42 | # Directives # | 
|---|
|  | 43 |  | 
|---|
| [5ff188f] | 44 | .PHONY : all clean                                      # not file names | 
|---|
|  | 45 |  | 
|---|
| [038726d] | 46 | all : ${DOCUMENT} | 
|---|
|  | 47 |  | 
|---|
|  | 48 | clean : | 
|---|
| [fb16d5c] | 49 | @rm -frv ${DOCUMENT} ${BASE}.ps ${Build} | 
|---|
| [038726d] | 50 |  | 
|---|
|  | 51 | # File Dependencies # | 
|---|
|  | 52 |  | 
|---|
| [e10537a9] | 53 | build/version: ../../configure | ${Build} | 
|---|
|  | 54 | ../../configure --version | grep "cfa-cc configure" | grep -oEe "([0-9]+\.)+[0-9]+" > $@ | 
|---|
|  | 55 |  | 
|---|
| [fb16d5c] | 56 | ${DOCUMENT} : ${BASE}.ps | 
|---|
| [179510c5] | 57 | ps2pdf -dPDFSETTINGS=/prepress $< | 
|---|
| [038726d] | 58 |  | 
|---|
| [fb16d5c] | 59 | ${BASE}.ps : ${BASE}.dvi | 
|---|
| [5ff188f] | 60 | dvips ${Build}/$< -o $@ | 
|---|
| [038726d] | 61 |  | 
|---|
| [484ee53] | 62 | ${BASE}.dvi : Makefile ${GRAPHS} ${PROGRAMS} ${PICTURES} ${FIGURES} ${SOURCES} \ | 
|---|
| [4ab767a] | 63 | ${Macros}/common.sty ${Macros}/lstlang.sty ${Macros}/indexstyle ../bibliography/pl.bib build/version | ${Build} | 
|---|
| [038726d] | 64 | # Conditionally create an empty *.ind (index) file for inclusion until makeindex is run. | 
|---|
| [5ff188f] | 65 | if [ ! -r ${basename $@}.ind ] ; then touch ${Build}/${basename $@}.ind ; fi | 
|---|
| [038726d] | 66 | # Must have *.aux file containing citations for bibtex | 
|---|
|  | 67 | if [ ! -r ${basename $@}.aux ] ; then ${LaTeX} ${basename $@}.tex ; fi | 
|---|
| [5ff188f] | 68 | -${BibTeX} ${Build}/${basename $@} | 
|---|
|  | 69 | # Some citations reference others so run again to resolve these citations | 
|---|
| [4ab767a] | 70 | #       ${LaTeX} ${basename $@}.tex | 
|---|
| [5ff188f] | 71 | -${BibTeX} ${Build}/${basename $@} | 
|---|
| [038726d] | 72 | # Make index from *.aux entries and input index at end of document | 
|---|
| [5ff188f] | 73 | makeindex -s ${Macros}/indexstyle ${Build}/${basename $@}.idx | 
|---|
|  | 74 | # Run again to finish citations | 
|---|
| [038726d] | 75 | ${LaTeX} ${basename $@}.tex | 
|---|
|  | 76 | # Run again to get index title into table of contents | 
|---|
| [4ab767a] | 77 | #       ${LaTeX} ${basename $@}.tex | 
|---|
| [038726d] | 78 |  | 
|---|
|  | 79 | ## Define the default recipes. | 
|---|
|  | 80 |  | 
|---|
| [519242e] | 81 | ${Build} : | 
|---|
| [5ff188f] | 82 | mkdir -p ${Build} | 
|---|
|  | 83 |  | 
|---|
| [484ee53] | 84 | %.tex : %.fig | ${Build} | 
|---|
| [5ff188f] | 85 | fig2dev -L eepic $< > ${Build}/$@ | 
|---|
| [038726d] | 86 |  | 
|---|
| [484ee53] | 87 | %.ps : %.fig | ${Build} | 
|---|
| [5ff188f] | 88 | fig2dev -L ps $< > ${Build}/$@ | 
|---|
| [038726d] | 89 |  | 
|---|
| [484ee53] | 90 | %.pstex : %.fig | ${Build} | 
|---|
| [5ff188f] | 91 | fig2dev -L pstex $< > ${Build}/$@ | 
|---|
|  | 92 | fig2dev -L pstex_t -p ${Build}/$@ $< > ${Build}/$@_t | 
|---|
| [4096de0] | 93 |  | 
|---|
| [038726d] | 94 | # Local Variables: # | 
|---|
|  | 95 | # compile-command: "make" # | 
|---|
|  | 96 | # End: # | 
|---|