source: doc/proposals/concurrency/Makefile @ b3048d4

ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsdeferred_resndemanglerenumforall-pointer-decayjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprnew-envno_listpersistent-indexerpthread-emulationqualifiedEnumresolv-newwith_gc
Last change on this file since b3048d4 was f739788, checked in by Thierry Delisle <tdelisle@…>, 7 years ago

Can now generate pngs for any figures and moved the legend of the system figure down

  • Property mode set to 100644
File size: 3.7 KB
Line 
1## Define the appropriate configuration variables.
2
3TeXLIB = .:./style:./text:./annex:./build:../../LaTeXmacros:../../LaTeXmacros/listings:../../LaTeXmacros/enumitem:~/bibliographies:
4LaTeX  = TEXINPUTS=${TeXLIB} && export TEXINPUTS && latex -halt-on-error -output-directory=build -interaction=nonstopmode
5BibTeX = BIBINPUTS=${TeXLIB} && export BIBINPUTS && bibtex -terse
6
7## Define the text source files.
8
9SOURCES = ${addsuffix .tex, \
10thesis \
11style/style \
12style/cfa-format \
13annex/glossary \
14text/frontpgs \
15text/intro \
16text/basics \
17text/cforall \
18text/concurrency \
19text/internals \
20text/parallelism \
21text/results \
22text/together \
23text/future \
24}
25
26FIGURES = ${addprefix build/, ${addsuffix .tex, \
27        monitor \
28        ext_monitor \
29        int_monitor \
30        dependency \
31}}
32
33PICTURES = ${addprefix build/, ${addsuffix .pstex, \
34        system \
35        monitor_structs \
36}}
37
38PROGRAMS = ${addsuffix .tex, \
39}
40
41GRAPHS = ${addsuffix .tex, \
42}
43
44## Define the documents that need to be made.
45
46DOCUMENT = thesis.pdf
47
48# Directives #
49
50all : ${DOCUMENT}
51
52clean :
53        @rm -fv ${DOCUMENT} \
54        build/*.acn     \
55        build/*.acr     \
56        build/*.alg     \
57        build/*.aux     \
58        build/*.bbl     \
59        build/*.blg     \
60        build/*.brf     \
61        build/*.cf      \
62        build/*.dvi     \
63        build/*.glg     \
64        build/*.glo     \
65        build/*.gls     \
66        build/*.ist     \
67        build/*.idx     \
68        build/*.ilg     \
69        build/*.ind     \
70        build/*.log     \
71        build/*.out     \
72        build/*.ps      \
73        build/*.pstex   \
74        build/*.pstex_t \
75        build/*.tex     \
76        build/*.toc     \
77        figures/*.tex   \
78        *.png           \
79
80
81# File Dependencies #
82
83${DOCUMENT} : build/${basename ${DOCUMENT}}.ps
84        ps2pdf $<
85
86build/${basename ${DOCUMENT}}.ps : build/${basename ${DOCUMENT}}.dvi
87        dvips $< -o $@
88
89build/${basename ${DOCUMENT}}.dvi : Makefile ${GRAPHS} ${PROGRAMS} ${PICTURES} ${FIGURES} ${SOURCES} ${basename ${DOCUMENT}}.tex ../../LaTeXmacros/common.tex ../../LaTeXmacros/indexstyle annex/local.bib
90
91        @ if [ ! -r ${basename $@}.ind ] ; then touch ${basename $@}.ind ; fi                           # Conditionally create an empty *.ind (index) file for inclusion until makeindex is run.
92        @ echo "Citation lookup"                                                                                        # Must have *.aux file containing citations for bibtex
93        @ if [ ! -r ${basename $@}.aux ] ; then ${LaTeX} ${basename ${notdir $@}}.tex ; fi
94        @ echo "Citation Pass 1"
95        @ -${BibTeX} ${basename $@}                                                                                     # Some citations reference others so run steps again to resolve these citations
96        @ echo "Citation Pass 2"
97        @ ${LaTeX} ${basename ${notdir $@}}.tex
98        @ -${BibTeX} ${basename $@}
99        @ echo "Glossary"
100        @ makeglossaries -q -s ${basename $@}.ist ${basename $@}                                                # Make index from *.aux entries and input index at end of document
101        @ echo ".dvi generation"
102        @ -build/bump_ver.sh
103        @ ${LaTeX} ${basename ${notdir $@}}.tex                                                                 # Run again to get index title into table of contents
104
105
106predefined :
107        sed -f predefined.sed ${basename ${DOCUMENT}}.tex > ${basename $@}.cf
108
109## Define the default recipes.
110
111build/%.tex : figures/%.fig
112        fig2dev -L eepic $< > $@
113
114build/%.ps : figures/%.fig
115        fig2dev -L ps $< > $@
116
117build/%.pstex : figures/%.fig
118        fig2dev -L pstex $< > $@
119        fig2dev -L pstex_t -p $@ $< > $@_t
120
121figures/%.tex: build/%.pstex
122        echo -n         "\documentclass[preview]{standalone}\n"         \
123                        "\usepackage[T1]{fontenc}\n"                    \
124                        "\usepackage[usenames]{color}\n"                \
125                        "\usepackage{graphicx}\n"                       \
126                        "\usepackage{listings}\n"                       \
127                        "\usepackage{xspace}\n"                         \
128                        "\input{style}\n"                               \
129                        "\\\\begin{document}\n"                         \
130                        "{\\\\resizebox{3\\\\textwidth}{!}{\input{${basename ${notdir $@}}.pstex_t}}}\n" \
131                        "\end{document}" > $@
132
133%.png : build/%.pstex figures/%.tex
134        echo ${basename $@}
135        ${LaTeX} figures/${basename $@}.tex
136        dvips build/${basename $@}.dvi -o build/${basename $@}.ps
137        ps2pdf build/${basename $@}.ps
138        convert -negate ${basename $@}.pdf $@
139
140
141
142# Local Variables: #
143# compile-command: "make" #
144# End: #
Note: See TracBrowser for help on using the repository browser.