Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • doc/theses/aaron_moss/comp_II/Makefile

    r728df66 r23c27039  
    1 ## Define the appropriate configuration variables.
     1## Define the configuration variables.
    22
    3 TeXLIB = .:../LaTeXmacros:../LaTeXmacros/listings:../LaTeXmacros/enumitem:../bibliography/:
    4 LaTeX  = TEXINPUTS=${TeXLIB} && export TEXINPUTS && latex -halt-on-error
     3Build = build
     4Figures = figures
     5Macros = ../../../LaTeXmacros
     6TeXLIB = .:${Macros}:${Build}:../../../bibliography:
     7LaTeX  = TEXINPUTS=${TeXLIB} && export TEXINPUTS && latex -halt-on-error -output-directory=${Build}
    58BibTeX = BIBINPUTS=${TeXLIB} && export BIBINPUTS && bibtex
     9
     10MAKEFLAGS = --no-print-directory --silent #
     11VPATH = ${Build} ${Figures}
    612
    713## Define the text source files.
     
    2935# Directives #
    3036
     37.PHONY : all clean                                      # not file names
     38
    3139all : ${DOCUMENT}
    3240
    3341clean :
    34         rm -f *.bbl *.aux *.dvi *.idx *.ilg *.ind *.brf *.out *.log *.toc *.blg *.pstex_t *.cf \
    35                 ${FIGURES} ${PICTURES} ${PROGRAMS} ${GRAPHS} ${basename ${DOCUMENT}}.ps ${DOCUMENT}
     42        @rm -frv ${DOCUMENT} ${basename ${DOCUMENT}}.ps ${Build}
    3643
    3744# File Dependencies #
     
    4148
    4249${basename ${DOCUMENT}}.ps : ${basename ${DOCUMENT}}.dvi
    43         dvips $< -o $@
     50        dvips ${Build}/$< -o $@
    4451
    45 ${basename ${DOCUMENT}}.dvi : Makefile ${GRAPHS} ${PROGRAMS} ${PICTURES} ${FIGURES} ${SOURCES} ${basename ${DOCUMENT}}.tex \
    46                 ../LaTeXmacros/common.tex ../LaTeXmacros/indexstyle ../bibliography/cfa.bib
    47         # Conditionally create an empty *.ind (index) file for inclusion until makeindex is run.
    48         if [ ! -r ${basename $@}.ind ] ; then touch ${basename $@}.ind ; fi
     52${basename ${DOCUMENT}}.dvi : Makefile ${Build} ${GRAPHS} ${PROGRAMS} ${PICTURES} ${FIGURES} ${SOURCES} \
     53                ${Macros}/common.tex ${Macros}/indexstyle ../../../bibliography/pl.bib
    4954        # Must have *.aux file containing citations for bibtex
    5055        if [ ! -r ${basename $@}.aux ] ; then ${LaTeX} ${basename $@}.tex ; fi
    51         -${BibTeX} ${basename $@}
    52         # Some citations reference others so run steps again to resolve these citations
     56        -${BibTeX} ${Build}/${basename $@}
     57        # Some citations reference others so run again to resolve these citations
    5358        ${LaTeX} ${basename $@}.tex
    54         -${BibTeX} ${basename $@}
    55         # Make index from *.aux entries and input index at end of document
    56         makeindex -s ../LaTeXmacros/indexstyle ${basename $@}.idx
     59        -${BibTeX} ${Build}/${basename $@}
     60        # Run again to finish citations
    5761        ${LaTeX} ${basename $@}.tex
    58         # Run again to get index title into table of contents
    59         ${LaTeX} ${basename $@}.tex
    60 
    61 predefined :
    62         sed -f predefined.sed ${basename ${DOCUMENT}}.tex > ${basename $@}.cf
    6362
    6463## Define the default recipes.
    6564
     65${Build}:
     66        mkdir -p ${Build}
     67
    6668%.tex : %.fig
    67         fig2dev -L eepic $< > $@
     69        fig2dev -L eepic $< > ${Build}/$@
    6870
    6971%.ps : %.fig
    70         fig2dev -L ps $< > $@
     72        fig2dev -L ps $< > ${Build}/$@
    7173
    7274%.pstex : %.fig
    73         fig2dev -L pstex $< > $@
    74         fig2dev -L pstex_t -p $@ $< > $@_t
     75        fig2dev -L pstex $< > ${Build}/$@
     76        fig2dev -L pstex_t -p ${Build}/$@ $< > ${Build}/$@_t
    7577
    7678# Local Variables: #
Note: See TracChangeset for help on using the changeset viewer.