PROJECTNAME=currents-4 currents-8 density-4 density-8 integrated_current-4 integrated_current-8 PDFS=$(addsuffix .pdf, $(PROJECTNAME)) TEXS=$(addsuffix .tikz.tex, $(PROJECTNAME)) all: $(PDFS) currents-4.pdf density-4.pdf integrated_current-4.pdf: current_density-4.dat gnuplot $(patsubst %.pdf, %.gnuplot, $@) > $(patsubst %.pdf, %.tikz.tex, $@) pdflatex -jobname $(basename $@) -file-line-error $(patsubst %.pdf, %.tikz.tex, $@) currents-8.pdf density-8.pdf integrated_current-8.pdf: current_density-8.dat gnuplot $(patsubst %.pdf, %.gnuplot, $@) > $(patsubst %.pdf, %.tikz.tex, $@) pdflatex -jobname $(basename $@) -file-line-error $(patsubst %.pdf, %.tikz.tex, $@) current_density-4.dat: julia current_density.jl 4 > $@ current_density-8.dat: julia current_density.jl 8 > $@ install: $(PDFS) cp $^ $(INSTALLDIR)/ clean-aux: rm -f $(addsuffix .tikz.tex, $(PROJECTNAME)) rm -f $(addsuffix .aux, $(PROJECTNAME)) rm -f $(addsuffix .log, $(PROJECTNAME)) clean-dat: rm -f current_density-4.dat rm -f current_density-8.dat clean-tex: rm -f $(PDFS) clean: clean-dat clean-aux clean-tex