#-------------------------------------------------------------------------------
SHELL = /bin/sh
CDBMERGE = $(HOME)/local/sh/cdbmerge
LCBTEX = $(HOME)/local/sh/lcbtex
LCBTAGS = $(HOME)/local/sh/lcbtags
BIBTEX = /usr/texbin/bibtex
#-------------------------------------------------------------------------------
.PHONY: all
#-------------------------------------------------------------------------------
all: .source .source-alt .paper
#-------------------------------------------------------------------------------
.paper: paper.texp paper.cfg source.tex source-alt.tex
			make paper
.source: source.cdbp source.cfg
			make source
.source-alt: source-alt.cdbp source-alt.cfg
			make source-alt
#-------------------------------------------------------------------------------
paper:
	$(LCBTAGS) $@
	$(LCBTEX) $@
	$(LCBTEX) $@
	touch .$@
#-------------------------------------------------------------------------------
%:
	$(CDBMERGE) $*
	touch .$*
#-------------------------------------------------------------------------------
clean:
	rm -f *.aux *.dvi *.log *.tmp *.xcd *.eqn tmp*.* core.* *.out
#-------------------------------------------------------------------------------
veryclean:
	make clean
	rm -f .paper .source .source-alt
