catala/Makefile

55 lines
949 B
Makefile
Raw Normal View History

2020-03-08 05:30:37 +03:00
build: format
dune build
2020-04-17 14:02:15 +03:00
install-dependencies:
opam install \
ANSITerminal \
sedlex \
menhir \
menhirLib \
dune \
cmdliner \
re
git submodule update --init
2020-04-16 18:47:35 +03:00
install:
dune build @install
2020-03-08 05:30:37 +03:00
format:
2020-03-12 20:04:27 +03:00
dune build @fmt --auto-promote | true
2020-03-08 05:30:37 +03:00
ALLOCATIONS_FAMILIALES_DIR=examples/allocations_familiales
PYGMENTS_DIR=syntax_highlighting/pygments
PYGMENTIZE=$(PYGMENTS_DIR)/pygments/env/bin/pygmentize
ifdef $(PVC)
PVC_OPTION=-pvc
else
PVC_OPTION=
endif
LATEXMK=latexmk $(PVC_OPTION) -g -pdf -halt-on-error -shell-escape
%.tex: %.catala
dune exec src/main.exe -- --wrap_latex --debug --backend LaTeX \
--output $@ \
$^
%.pdf: %.tex $(PYGMENTIZE)
cd $(@D) && $(LATEXMK) $(%F)
$(PYGMENTIZE): $(PYGMENTS_DIR)/set_up_pygments.sh $(PYGMENTS_DIR)/catala.py
chmod +x $<
$<
allocations_familiales: $(ALLOCATIONS_FAMILIALES_DIR)/allocations_familiales.pdf
2020-04-13 19:57:24 +03:00
inspect:
2020-04-16 18:47:35 +03:00
gitinspector -f ml,mli,mly,iro,tex,catala,md,ir --grading