Skip to content

Commit

Permalink
neaten up the Makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
cpmpercussion committed Nov 21, 2024
1 parent 39acd60 commit 0876983
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

# Output PDF names
NIME_PDF = nime-paper-template.pdf
MUSIC_PDF = nime-music-workshop-template.pdf
PAPER_TEMPLATE = nime-paper-template
MUSIC_TEMPLATE = nime-music-workshop-template

# Full compilation rule with BibTeX
define compile_tex
Expand All @@ -12,15 +12,17 @@ define compile_tex
cd $(dir $<) && pdflatex -interaction=nonstopmode $(notdir $<)
endef

$(NIME_PDF): nime-paper-template.tex
$(PAPER_TEMPLATE).pdf: $(PAPER_TEMPLATE).tex
$(compile_tex)

$(MUSIC_PDF): nime-music-workshop-template.tex
$(MUSIC_TEMPLATE).pdf: $(MUSIC_TEMPLATE).tex
$(compile_tex)

all: $(MUSIC_TEMPLATE).pdf $(PAPER_TEMPLATE).pdf

# Clean generated files
clean:
rm -f $(NIME_PDF) $(MUSIC_PDF)
rm -f $(PAPER_TEMPLATE).pdf $(MUSIC_TEMPLATE).pdf
rm -f *.aux *.log *.out \
*.bbl *.blg *.fls *.fdb_latexmk \
*.synctex.gz
Expand Down

0 comments on commit 0876983

Please sign in to comment.