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