Skip to content

Commit 3f81936

Browse files
amadiobernhardmgruber
authored andcommitted
Update Makefile to use latexmk
1 parent bd39c32 commit 3f81936

File tree

1 file changed

+19
-11
lines changed

1 file changed

+19
-11
lines changed

talk/Makefile

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,27 @@
11
all: C++Course.pdf
22

3-
essentials:
4-
ESSENTIALS=1 make
3+
LATEXMK=latexmk
4+
OPTIONS=-pdf -shell-escape -halt-on-error
55

6-
%.pdf: *.tex **/*.tex
7-
ifdef ESSENTIALS
8-
echo "\basictrue" > onlybasics.tex
6+
essentials: all
7+
essentials: OPTIONS+=-pretex='\basictrue'
8+
9+
preview: all
10+
preview: OPTIONS+=-pvc
11+
12+
ifneq ($(V), 1)
13+
OPTIONS+=-quiet
914
else
10-
rm -f onlybasics.tex
15+
OPTIONS+=-interaction=nonstopmode
1116
endif
12-
pdflatex -shell-escape C++Course.tex
13-
pdflatex -shell-escape C++Course.tex
17+
18+
.PHONY: clean clobber FORCE
19+
20+
%.pdf: %.tex FORCE
21+
$(LATEXMK) $(OPTIONS) $<
1422

1523
clean:
16-
rm -rf *.aux */*.aux *.log *.nav *.out *.pyg *.snm *.vrb *.toc C++Course.l* _minted-C++Course
24+
$(LATEXMK) -quiet -c
1725

18-
clobber: clean
19-
rm -f C++Course.pdf
26+
clobber:
27+
$(LATEXMK) -quiet -C

0 commit comments

Comments
 (0)