| [a43dd54] | 1 | ## Define the configuration variables.
 | 
|---|
 | 2 | 
 | 
|---|
 | 3 | Build = build
 | 
|---|
| [5ff188f] | 4 | Figures = figures
 | 
|---|
| [d046db2] | 5 | Macros = ../AMA/AMA-stix/ama
 | 
|---|
| [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
 | 
|---|
| [a43dd54] | 9 | 
 | 
|---|
| [49eb6a2] | 10 | MAKEFLAGS = --no-print-directory # --silent
 | 
|---|
| [23c27039] | 11 | VPATH = ${Build} ${Figures} evaluation
 | 
|---|
| [a43dd54] | 12 | 
 | 
|---|
 | 13 | ## Define the text source files.
 | 
|---|
 | 14 | 
 | 
|---|
 | 15 | SOURCES = ${addsuffix .tex, \
 | 
|---|
 | 16 | Paper \
 | 
|---|
 | 17 | }
 | 
|---|
 | 18 | 
 | 
|---|
 | 19 | FIGURES = ${addsuffix .tex, \
 | 
|---|
| [04ba967] | 20 | Cdecl \
 | 
|---|
| [a43dd54] | 21 | }
 | 
|---|
 | 22 | 
 | 
|---|
 | 23 | PICTURES = ${addsuffix .pstex, \
 | 
|---|
 | 24 | }
 | 
|---|
 | 25 | 
 | 
|---|
 | 26 | PROGRAMS = ${addsuffix .tex, \
 | 
|---|
 | 27 | }
 | 
|---|
 | 28 | 
 | 
|---|
 | 29 | GRAPHS = ${addsuffix .tex, \
 | 
|---|
 | 30 | timing \
 | 
|---|
 | 31 | }
 | 
|---|
 | 32 | 
 | 
|---|
 | 33 | ## Define the documents that need to be made.
 | 
|---|
 | 34 | 
 | 
|---|
 | 35 | DOCUMENT = Paper.pdf
 | 
|---|
| [53dece1] | 36 | BASE = ${basename ${DOCUMENT}}
 | 
|---|
| [a43dd54] | 37 | 
 | 
|---|
 | 38 | # Directives #
 | 
|---|
 | 39 | 
 | 
|---|
| [5ff188f] | 40 | .PHONY : all clean                                      # not file names
 | 
|---|
| [a43dd54] | 41 | 
 | 
|---|
 | 42 | all : ${DOCUMENT}
 | 
|---|
 | 43 | 
 | 
|---|
 | 44 | clean :
 | 
|---|
| [53dece1] | 45 |         @rm -frv ${DOCUMENT} ${BASE}.ps WileyNJD-AMA.bst ${BASE}.out.ps ${Build}
 | 
|---|
| [a43dd54] | 46 | 
 | 
|---|
| [3d60c08] | 47 | Paper.zip :
 | 
|---|
| [9459c01] | 48 |         zip -x general/.gitignore -x general/Paper.out.ps -x general/Paper.tex.plain -x -x general/WileyNJD-AMA.bst general/"*evaluation*" -x general/evaluation.zip \
 | 
|---|
 | 49 |                 -x general/mail -x general/response -x general/test.c -x general/Paper.ps -x general/"*build*" -r Paper.zip general pl.bib
 | 
|---|
| [3d60c08] | 50 | 
 | 
|---|
| [cfc3e0f] | 51 | evaluation.zip :
 | 
|---|
| [9459c01] | 52 |         zip -x evaluation/.gitignore -x evaluation/timing.xlsx -x evaluation/timing.dat -r evaluation.zip evaluation
 | 
|---|
| [cfc3e0f] | 53 | 
 | 
|---|
| [a43dd54] | 54 | # File Dependencies #
 | 
|---|
 | 55 | 
 | 
|---|
| [53dece1] | 56 | ${DOCUMENT} : ${BASE}.ps
 | 
|---|
| [a43dd54] | 57 |         ps2pdf $<
 | 
|---|
 | 58 | 
 | 
|---|
| [53dece1] | 59 | ${BASE}.ps : ${BASE}.dvi
 | 
|---|
| [3fd3bda] | 60 |         dvips ${Build}/$< -o $@
 | 
|---|
| [a43dd54] | 61 | 
 | 
|---|
| [b7c55277] | 62 | ${BASE}.dvi : Makefile ${BASE}.out.ps ${Macros}/WileyNJD-v2.cls WileyNJD-AMA.bst ${GRAPHS} ${PROGRAMS} ${PICTURES} ${FIGURES} ${SOURCES} \
 | 
|---|
| [484ee53] | 63 |                 ../../bibliography/pl.bib | ${Build}
 | 
|---|
| [5ff188f] | 64 |         # Must have *.aux file containing citations for bibtex
 | 
|---|
 | 65 |         if [ ! -r ${basename $@}.aux ] ; then ${LaTeX} ${basename $@}.tex ; fi
 | 
|---|
| [49eb6a2] | 66 |         ${BibTeX} ${Build}/${basename $@}
 | 
|---|
| [5ff188f] | 67 |         # Some citations reference others so run again to resolve these citations
 | 
|---|
| [a43dd54] | 68 |         ${LaTeX} ${basename $@}.tex
 | 
|---|
| [49eb6a2] | 69 |         ${BibTeX} ${Build}/${basename $@}
 | 
|---|
| [5ff188f] | 70 |         # Run again to finish citations
 | 
|---|
 | 71 |         ${LaTeX} ${basename $@}.tex
 | 
|---|
| [a43dd54] | 72 | 
 | 
|---|
 | 73 | ## Define the default recipes.
 | 
|---|
 | 74 | 
 | 
|---|
| [cfc3e0f] | 75 | ${Build} :
 | 
|---|
| [a43dd54] | 76 |         mkdir -p ${Build}
 | 
|---|
 | 77 | 
 | 
|---|
| [484ee53] | 78 | ${BASE}.out.ps : | ${Build}
 | 
|---|
| [fb16d5c] | 79 |         ln -fs ${Build}/Paper.out.ps .
 | 
|---|
| [53dece1] | 80 | 
 | 
|---|
| [cfc3e0f] | 81 | WileyNJD-AMA.bst :
 | 
|---|
| [d046db2] | 82 |         ln -fs ../AMA/AMA-stix/ama/WileyNJD-AMA.bst .
 | 
|---|
| [53dece1] | 83 | 
 | 
|---|
| [fb16d5c] | 84 | ${GRAPHS} : ${Build} timing.gp timing.dat
 | 
|---|
| [5ff188f] | 85 |         gnuplot -e Build="'${Build}/'" evaluation/timing.gp
 | 
|---|
| [a43dd54] | 86 | 
 | 
|---|
| [484ee53] | 87 | %.tex : %.fig | ${Build}
 | 
|---|
| [a43dd54] | 88 |         fig2dev -L eepic $< > ${Build}/$@
 | 
|---|
 | 89 | 
 | 
|---|
| [484ee53] | 90 | %.ps : %.fig | ${Build}
 | 
|---|
| [a43dd54] | 91 |         fig2dev -L ps $< > ${Build}/$@
 | 
|---|
 | 92 | 
 | 
|---|
| [484ee53] | 93 | %.pstex : %.fig | ${Build}
 | 
|---|
| [a43dd54] | 94 |         fig2dev -L pstex $< > ${Build}/$@
 | 
|---|
 | 95 |         fig2dev -L pstex_t -p ${Build}/$@ $< > ${Build}/$@_t
 | 
|---|
 | 96 | 
 | 
|---|
 | 97 | # Local Variables: #
 | 
|---|
 | 98 | # compile-command: "make" #
 | 
|---|
 | 99 | # End: #
 | 
|---|