23 lines
450 B
Makefile
23 lines
450 B
Makefile
.PHONY: default
|
|
|
|
default: docs
|
|
|
|
DOCUMENTS=$(shell find doc/ -name '*.md')
|
|
|
|
HTMLDOCS=$(patsubst %.md,%.html,$(DOCUMENTS))
|
|
PDFDOCS=$(patsubst %.md,%.pdf,$(DOCUMENTS))
|
|
|
|
docs: $(HTMLDOCS) $(PDFDOCS)
|
|
|
|
%.html: %.md
|
|
multimarkdown -t html $^ -o $@
|
|
|
|
%.tex: %.md
|
|
multimarkdown -t latex $^ -o $@
|
|
|
|
%.pdf: %.tex doc/arctic-leader.tex doc/arctic-begin.tex doc/arctic-footer.tex
|
|
cd $$(dirname $<) && xelatex -interaction=batchmode $<
|
|
|
|
print-%:
|
|
@echo '$*=$($*)'
|