catala/examples/Makefile.common

25 lines
527 B
Makefile
Raw Normal View History

LATEXMK=latexmk
PYGMENTIZE=../../syntax_highlighting/pygments/pygments/env/bin/pygmentize
2020-04-20 10:05:40 +03:00
CATALA=dune exec ../../src/main.exe --
%.tex: %.catala
2020-04-20 10:05:40 +03:00
$(CATALA) --language=en Makefile $<
$(CATALA) \
--debug \
--wrap_latex \
--language=en \
2020-04-20 10:05:40 +03:00
--pygmentize=$(PYGMENTIZE) \
LaTeX \
$<
%.pdf: %.tex
cd $(@D) && $(LATEXMK) -g -pdf -halt-on-error -shell-escape $(%F)
clean:
$(LATEXMK) -f -C $(SRC:.catala=.tex)
rm -rf $(SRC:.catala=.tex) $(SRC:.catala=.d) _minted-$(SRC:.catala=)
include $(wildcard $(SRC:.catala=.d))