source: doc/theses/colby_parsons_MMAth/Makefile @ 0faacb8

ADTast-experimental
Last change on this file since 0faacb8 was 0faacb8, checked in by caparsons <caparson@…>, 13 months ago

various additions to thesis, finished first draft of actor chapter (lots of polish needed), added first draft of intro to CFA features & intro to CFA threading, added start of mutex stmt chapter

  • Property mode set to 100644
File size: 3.8 KB
Line 
1## Define the configuration variables.
2
3Build = build
4Figures = figures
5Macros = ../../LaTeXmacros
6TeXLIB = .:style:text:${Macros}:${Build}:../../bibliography:
7LaTeX  = TEXINPUTS=${TeXLIB} && export TEXINPUTS && latex -halt-on-error -output-directory=${Build}
8BibTeX = BIBINPUTS=${TeXLIB} && export BIBINPUTS && bibtex -terse
9
10MAKEFLAGS = --no-print-directory --silent #
11VPATH = ${Build} ${Figures}
12
13## Define the text source files.
14
15SOURCES = ${addsuffix .tex, \
16text/CFA_intro                          \
17text/actors                                     \
18text/frontpgs                           \
19text/CFA_concurrency            \
20thesis                                          \
21text/mutex_stmt                         \
22}
23
24FIGURES = ${addsuffix .pgf,             \
25        figures/pykeExecutor                    \
26        figures/pykeCFAExecutor                 \
27        figures/nasusExecutor                   \
28        figures/nasusCFAExecutor                \
29        figures/pykeMatrix                              \
30        figures/pykeCFAMatrix                   \
31        figures/nasusMatrix                     \
32        figures/nasusCFAMatrix                  \
33        figures/pykeRepeat                              \
34        figures/pykeCFARepeat                   \
35        figures/nasusRepeat                     \
36        figures/nasusCFARepeat                  \
37        figures/pykeCFABalance-One              \
38        figures/nasusCFABalance-One             \
39        figures/pykeCFABalance-Multi    \
40        figures/nasusCFABalance-Multi   \
41}
42
43DATA =  data/pykeSendStatic             \
44                data/pykeSendDynamic    \
45                data/pykeExecutorMem    \
46                data/nasusSendStatic    \
47                data/nasusSendDynamic   \
48                data/pykeExecutorMem    \
49
50PICTURES = ${addsuffix .tikz,   \
51        diagrams/standard_actor         \
52        diagrams/inverted_actor         \
53        diagrams/gulp                           \
54        diagrams/chain_swap             \
55        diagrams/M_to_one_swap          \
56        diagrams/acyclic_swap           \
57        diagrams/cyclic_swap            \
58}
59
60PROGRAMS = ${addsuffix .tex, \
61}
62
63GRAPHS = ${addsuffix .tex, \
64}
65
66## Define the documents that need to be made.
67
68DOCUMENT = thesis.pdf
69BASE = ${basename ${DOCUMENT}}
70
71# Directives #
72
73.PHONY : all clean                                      # not file names
74
75all : ${DOCUMENT}
76
77clean :
78        @rm -frv ${DOCUMENT} ${BASE}.ps ${Build}
79
80# File Dependencies #
81
82${DOCUMENT} : ${BASE}.ps
83        ps2pdf $<
84
85${BASE}.ps : ${BASE}.dvi
86        dvips ${Build}/$< -o $@
87
88${BASE}.dvi : Makefile ${GRAPHS} ${PROGRAMS} ${PICTURES} ${FIGURES} ${SOURCES} ${DATA} \
89                ${Macros}/common.tex ${Macros}/indexstyle local.bib ../../bibliography/pl.bib | ${Build}
90        # Must have *.aux file containing citations for bibtex
91        if [ ! -r ${basename $@}.aux ] ; then ${LaTeX} ${basename $@}.tex ; fi
92        -${BibTeX} ${Build}/${basename $@}
93        # Some citations reference others so run again to resolve these citations
94        ${LaTeX} ${basename $@}.tex
95        -${BibTeX} ${Build}/${basename $@}
96        # Make index from *.aux entries and input index at end of document
97        makeglossaries -q -s ${Build}/${basename $@}.ist ${Build}/${basename $@}
98        -version.sh
99        # Run again to finish citations
100        ${LaTeX} ${basename $@}.tex
101       
102
103## Define the default recipes.
104
105${Build}:
106        mkdir -p ${Build}
107
108%.tex : %.fig ${Build}
109        fig2dev -L eepic $< > ${Build}/$@
110
111%.ps : %.fig | ${Build}
112        fig2dev -L ps $< > ${Build}/$@
113
114%.pstex : %.fig | ${Build}
115        fig2dev -L pstex $< > ${Build}/$@
116        fig2dev -L pstex_t -p ${Build}/$@ $< > ${Build}/$@_t
117
118#-----------------------------------------------------------------------------------
119# Tools to generate png files
120# to create a png we create a pdf and convert it to png
121%.png : build/%.pstex figures/%.tex ${Build}
122        echo ${basename $@}
123        ${LaTeX} figures/${basename $@}.tex
124        dvips build/${basename $@}.dvi -o build/${basename $@}.ps
125        ps2pdf build/${basename $@}.ps
126        convert -negate ${basename $@}.pdf $@
127
128# creating a pdf of a figure requires generating some latex that just includes the figure
129figures/%.tex: build/%.pstex ${Build}
130        echo -n         "\documentclass[preview]{standalone}\n"         \
131                        "\usepackage[T1]{fontenc}\n"                    \
132                        "\usepackage[usenames]{color}\n"                \
133                        "\usepackage{graphicx}\n"                       \
134                        "\usepackage{listings}\n"                       \
135                        "\usepackage{xspace}\n"                         \
136                        "\input{style}\n"                               \
137                        "\\\\begin{document}\n"                         \
138                        "{\\\\resizebox{3\\\\textwidth}{!}{\input{${basename ${notdir $@}}.pstex_t}}}\n" \
139                        "\end{document}" > $@
140
141data/%: ;
142%.tikz: ;
143%.pgf: ;
144
145# Local Variables: #
146# compile-command: "make" #
147# End: #
Note: See TracBrowser for help on using the repository browser.