34 lines
677 B
Makefile
34 lines
677 B
Makefile
PDF_APP = zathura
|
|
OUTPUT_DIR = output
|
|
svgfiles = $(wildcard images/svg/*.svg)
|
|
figures = $(subst svg/,generated/,$(subst .svg,.pdf,$(svgfiles)))
|
|
|
|
default: build
|
|
|
|
images: $(figures)
|
|
|
|
clean:
|
|
rm -rf images/generated/*
|
|
rm -rf output/*
|
|
|
|
build:
|
|
$(shell mkdir -p $(OUTPUT_DIR))
|
|
lualatex --output-directory $(OUTPUT_DIR) rapport.tex
|
|
|
|
buildall: images build
|
|
|
|
presbuild:
|
|
$(shell mkdir -p $(OUTPUT_DIR))
|
|
lualatex --output-directory $(OUTPUT_DIR) presentation.tex
|
|
|
|
|
|
images/generated/%.pdf: images/svg/%.svg
|
|
@echo build $@
|
|
inkscape --export-type=pdf -o $@ $<
|
|
|
|
echo:
|
|
@echo "svg files: $(svgfiles)"
|
|
@echo "generated figures: $(figures)"
|
|
|
|
view:
|
|
$(PDF_APP) $(OUTPUT_DIR)/rapport.pdf
|