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