| [038726d] | 1 | ## Define the appropriate configuration variables.
 | 
|---|
 | 2 | 
 | 
|---|
| [9724df0] | 3 | TeXLIB = .:../LaTeXmacros:../LaTeXmacros/listings:../LaTeXmacros/enumitem:../bibliography/:
 | 
|---|
| [554a0db] | 4 | LaTeX  = TEXINPUTS=${TeXLIB} && export TEXINPUTS && latex -halt-on-error
 | 
|---|
| [e55ca05] | 5 | BibTeX = BIBINPUTS=${TeXLIB} && export BIBINPUTS && bibtex
 | 
|---|
| [038726d] | 6 | 
 | 
|---|
 | 7 | ## Define the text source files.
 | 
|---|
 | 8 | 
 | 
|---|
 | 9 | SOURCES = ${addsuffix .tex, \
 | 
|---|
 | 10 | user \
 | 
|---|
 | 11 | }
 | 
|---|
 | 12 | 
 | 
|---|
 | 13 | FIGURES = ${addsuffix .tex, \
 | 
|---|
| [fbefc4d] | 14 | EHMHierarchy \
 | 
|---|
| [6b6597c] | 15 | Cdecl \
 | 
|---|
| [4096de0] | 16 | pointer1 \
 | 
|---|
| [038726d] | 17 | }
 | 
|---|
 | 18 | 
 | 
|---|
 | 19 | PICTURES = ${addsuffix .pstex, \
 | 
|---|
| [4096de0] | 20 | pointer2 \
 | 
|---|
| [038726d] | 21 | }
 | 
|---|
 | 22 | 
 | 
|---|
 | 23 | PROGRAMS = ${addsuffix .tex, \
 | 
|---|
 | 24 | }
 | 
|---|
 | 25 | 
 | 
|---|
 | 26 | GRAPHS = ${addsuffix .tex, \
 | 
|---|
 | 27 | }
 | 
|---|
 | 28 | 
 | 
|---|
 | 29 | ## Define the documents that need to be made.
 | 
|---|
 | 30 | 
 | 
|---|
 | 31 | DOCUMENT = user.pdf
 | 
|---|
 | 32 | 
 | 
|---|
 | 33 | # Directives #
 | 
|---|
 | 34 | 
 | 
|---|
 | 35 | all : ${DOCUMENT}
 | 
|---|
 | 36 | 
 | 
|---|
 | 37 | clean :
 | 
|---|
 | 38 |         rm -f *.bbl *.aux *.dvi *.idx *.ilg *.ind *.brf *.out *.log *.toc *.blg *.pstex_t *.cf \
 | 
|---|
 | 39 |                 ${FIGURES} ${PICTURES} ${PROGRAMS} ${GRAPHS} ${basename ${DOCUMENT}}.ps ${DOCUMENT}
 | 
|---|
 | 40 | 
 | 
|---|
 | 41 | # File Dependencies #
 | 
|---|
 | 42 | 
 | 
|---|
 | 43 | ${DOCUMENT} : ${basename ${DOCUMENT}}.ps
 | 
|---|
 | 44 |         ps2pdf $<
 | 
|---|
 | 45 | 
 | 
|---|
 | 46 | ${basename ${DOCUMENT}}.ps : ${basename ${DOCUMENT}}.dvi
 | 
|---|
 | 47 |         dvips $< -o $@
 | 
|---|
 | 48 | 
 | 
|---|
| [e55ca05] | 49 | ${basename ${DOCUMENT}}.dvi : Makefile ${GRAPHS} ${PROGRAMS} ${PICTURES} ${FIGURES} ${SOURCES} ${basename ${DOCUMENT}}.tex \
 | 
|---|
| [218aecf] | 50 |                 ../LaTeXmacros/common.tex ../LaTeXmacros/lstlang.sty ../LaTeXmacros/indexstyle ../bibliography/cfa.bib
 | 
|---|
| [038726d] | 51 |         # Conditionally create an empty *.ind (index) file for inclusion until makeindex is run.
 | 
|---|
 | 52 |         if [ ! -r ${basename $@}.ind ] ; then touch ${basename $@}.ind ; fi
 | 
|---|
 | 53 |         # Must have *.aux file containing citations for bibtex
 | 
|---|
 | 54 |         if [ ! -r ${basename $@}.aux ] ; then ${LaTeX} ${basename $@}.tex ; fi
 | 
|---|
 | 55 |         -${BibTeX} ${basename $@}
 | 
|---|
 | 56 |         # Some citations reference others so run steps again to resolve these citations
 | 
|---|
 | 57 |         ${LaTeX} ${basename $@}.tex
 | 
|---|
 | 58 |         -${BibTeX} ${basename $@}
 | 
|---|
 | 59 |         # Make index from *.aux entries and input index at end of document
 | 
|---|
| [e55ca05] | 60 |         makeindex -s ../LaTeXmacros/indexstyle ${basename $@}.idx
 | 
|---|
| [038726d] | 61 |         ${LaTeX} ${basename $@}.tex
 | 
|---|
 | 62 |         # Run again to get index title into table of contents
 | 
|---|
 | 63 |         ${LaTeX} ${basename $@}.tex
 | 
|---|
 | 64 | 
 | 
|---|
 | 65 | predefined :
 | 
|---|
 | 66 |         sed -f predefined.sed ${basename ${DOCUMENT}}.tex > ${basename $@}.cf
 | 
|---|
 | 67 | 
 | 
|---|
 | 68 | ## Define the default recipes.
 | 
|---|
 | 69 | 
 | 
|---|
 | 70 | %.tex : %.fig
 | 
|---|
 | 71 |         fig2dev -L eepic $< > $@
 | 
|---|
 | 72 | 
 | 
|---|
 | 73 | %.ps : %.fig
 | 
|---|
 | 74 |         fig2dev -L ps $< > $@
 | 
|---|
 | 75 | 
 | 
|---|
| [4096de0] | 76 | %.pstex : %.fig
 | 
|---|
 | 77 |         fig2dev -L pstex $< > $@
 | 
|---|
 | 78 |         fig2dev -L pstex_t -p $@ $< > $@_t
 | 
|---|
 | 79 | 
 | 
|---|
| [038726d] | 80 | # Local Variables: #
 | 
|---|
 | 81 | # compile-command: "make" #
 | 
|---|
 | 82 | # End: #
 | 
|---|