source: doc/theses/thierry_delisle/Makefile @ d807ca28

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

Merge branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

  • Property mode set to 100644
File size: 3.2 KB
RevLine 
[23c27039]1## Define the configuration variables.
[694ee7d]2
[23c27039]3Build = build
4Figures = figures
5Macros = ../../LaTeXmacros
6TeXLIB = .:style:text:annex:${Macros}:${Build}:../../bibliography:
7LaTeX  = TEXINPUTS=${TeXLIB} && export TEXINPUTS && latex -halt-on-error -output-directory=${Build}
[27dde72]8BibTeX = BIBINPUTS=${TeXLIB} && export BIBINPUTS && bibtex -terse
[694ee7d]9
[23c27039]10MAKEFLAGS = --no-print-directory --silent #
11VPATH = ${Build} ${Figures}
12
[694ee7d]13## Define the text source files.
14
15SOURCES = ${addsuffix .tex, \
[db0fa7c]16thesis \
[27dde72]17style/style \
18style/cfa-format \
19annex/glossary \
[cf966b5]20text/frontpgs \
[27dde72]21text/intro \
22text/basics \
[64b272a]23text/cforall \
[27dde72]24text/concurrency \
[dcfc4b35]25text/internals \
[27dde72]26text/parallelism \
[64b272a]27text/results \
[d67cdb7]28text/together \
29text/future \
[694ee7d]30}
31
[23c27039]32FIGURES = ${addsuffix .tex, \
33monitor \
34ext_monitor \
35int_monitor \
36dependency \
37}
[694ee7d]38
[23c27039]39PICTURES = ${addsuffix .pstex, \
40system \
41monitor_structs \
42}
[694ee7d]43
44PROGRAMS = ${addsuffix .tex, \
45}
46
47GRAPHS = ${addsuffix .tex, \
48}
49
50## Define the documents that need to be made.
51
[db0fa7c]52DOCUMENT = thesis.pdf
[694ee7d]53
54# Directives #
55
[23c27039]56.PHONY : all clean                                      # not file names
57
[694ee7d]58all : ${DOCUMENT}
59
60clean :
[23c27039]61        @rm -frv ${DOCUMENT} ${basename ${DOCUMENT}}.ps ${Build}
[694ee7d]62
63# File Dependencies #
64
[23c27039]65${DOCUMENT} : ${basename ${DOCUMENT}}.ps
[694ee7d]66        ps2pdf $<
67
[23c27039]68${basename ${DOCUMENT}}.ps : ${basename ${DOCUMENT}}.dvi
69        dvips ${Build}/$< -o $@
70
71${basename ${DOCUMENT}}.dvi : Makefile ${Build} ${GRAPHS} ${PROGRAMS} ${PICTURES} ${FIGURES} ${SOURCES} \
72                ${Macros}/common.tex ${Macros}/indexstyle annex/local.bib ../../bibliography/pl.bib
73        # Must have *.aux file containing citations for bibtex
74        if [ ! -r ${basename $@}.aux ] ; then ${LaTeX} ${basename $@}.tex ; fi
75        -${BibTeX} ${Build}/${basename $@}
76        # Some citations reference others so run again to resolve these citations
77        ${LaTeX} ${basename $@}.tex
78        -${BibTeX} ${Build}/${basename $@}
79        # Make index from *.aux entries and input index at end of document
80        makeglossaries -q -s ${Build}/${basename $@}.ist ${Build}/${basename $@}
81        -version.sh
82        # Run again to finish citations
83        ${LaTeX} ${basename $@}.tex
[694ee7d]84
85## Define the default recipes.
86
[23c27039]87${Build}:
88        mkdir -p ${Build}
[694ee7d]89
[23c27039]90%.tex : %.fig
91        fig2dev -L eepic $< > ${Build}/$@
[694ee7d]92
[23c27039]93%.ps : %.fig
94        fig2dev -L ps $< > ${Build}/$@
[694ee7d]95
[23c27039]96%.pstex : %.fig
97        fig2dev -L pstex $< > ${Build}/$@
98        fig2dev -L pstex_t -p ${Build}/$@ $< > ${Build}/$@_t
[694ee7d]99
[e76bd39]100#-----------------------------------------------------------------------------------
101# Tools to generate png files
102# to create a png we create a pdf and convert it to png
103%.png : build/%.pstex figures/%.tex
104        echo ${basename $@}
105        ${LaTeX} figures/${basename $@}.tex
106        dvips build/${basename $@}.dvi -o build/${basename $@}.ps
107        ps2pdf build/${basename $@}.ps
108        convert -negate ${basename $@}.pdf $@
109
110# creating a pdf of a figure requires generating some latex that just includes the figure
[f739788]111figures/%.tex: build/%.pstex
112        echo -n         "\documentclass[preview]{standalone}\n"         \
113                        "\usepackage[T1]{fontenc}\n"                    \
114                        "\usepackage[usenames]{color}\n"                \
115                        "\usepackage{graphicx}\n"                       \
116                        "\usepackage{listings}\n"                       \
117                        "\usepackage{xspace}\n"                         \
118                        "\input{style}\n"                               \
119                        "\\\\begin{document}\n"                         \
120                        "{\\\\resizebox{3\\\\textwidth}{!}{\input{${basename ${notdir $@}}.pstex_t}}}\n" \
121                        "\end{document}" > $@
122
[694ee7d]123# Local Variables: #
124# compile-command: "make" #
125# End: #
Note: See TracBrowser for help on using the repository browser.