# # $Id: Makefile,v 1.2 2000/03/28 19:04:39 rgb Exp $ # #====================================================================== # THIS IS A "GENERIC" MAKEFILE FOR LATEX PROJECTS # # make alone makes only the $(DVI) file, running latex twice # so that all references and toc's are correct. # # make ps makes $(PS) (and $(DVI) if necessary) # make pdf makes $(PDF) (and $(PS) and $(DVI) as necessary) # make clean deletes all transient build files and output formats. # make tar makes $(TAR) from >>all<< the sources # make gz makes $(TARGZ) from >>all<< the sources # make commit does a cvs commit and creates the timestamp $(CVS) # make sync does a cvs commit and runs synccvs to list of # CVSROOT hosts # # Feel free to add your own! rgb 3/5/90 #======================================================================= # This is the main source file, which should have the same base name # as the project (CVS and build directory). SOURCE = beowulf_advanced.tex # The list of includes are things required for the build to work. Examples # might be included .tex or .sty files, embedded .eps files, and so forth. # Naturally, anything on this list should be in the CVS tree. INCLUDE = beowulf.fig beowulf.eps cluster.fig cluster.eps \ cca.time discover.gprof discover.pvm.gprof discover.times \ neural.fig neural.eps pvm_neural.fig pvm_neural.eps # All sources (tex and ps) SOURCES = $(SOURCE) $(INCLUDE) DIR = $(SOURCE:.tex=) DVI = $(SOURCE:.tex=.dvi) AUX = $(SOURCE:.tex=.aux) LOG = $(SOURCE:.tex=.log) ERR = $(SOURCE:.tex=.err) PS = $(SOURCE:.tex=.ps) PDF = $(SOURCE:.tex=.pdf) TAR = $(SOURCE:.tex=.tar) CVS = $(SOURCE:.tex=.cvs.time) # Build targets (from rules) all: $(DVI) ps: $(DVI) $(PS) pdf: $(DVI) $(PS) $(PDF) # Build targets (from commands) tar: $(SOURCES) rm -f $(DVI) $(AUX) $(LOG) $(ERR) $(PS) $(PDF) tar -cvpf $(TAR) -C .. $(DIR) gz: $(SOURCES) $(TAR) gzip $(TAR) cvs: touch $(CVS) # Will force a commit! cvs commit . # doesn't sync (yet). sync: touch $(CVS) # Will force a commit! cvs commit . # Do the commit synccvs $(DIR) ganesh synccvs $(DIR) rgb # Clean up all the junk build files and output formats to save space. clean: rm -f $(DVI) $(AUX) $(LOG) $(ERR) $(PS) $(PDF) # Rule for making dvi out of tex. Do it twice to build table of contents # and resolve forward references. %.dvi:%.tex latex $< $@ latex $< $@ # Rule for making postscript image %.ps:%.dvi dvips -o $@ $< # Rule for making pdf out of a postscript image %.pdf:%.ps ps2pdf $<