diff options
author | Philipp Gesang <phg42.2a@gmail.com> | 2014-02-10 07:14:53 +0100 |
---|---|---|
committer | Philipp Gesang <phg42.2a@gmail.com> | 2014-02-10 07:14:53 +0100 |
commit | 708c689312e75953db431f8838846996ff447789 (patch) | |
tree | 457dfafe34693e668d99b3c8e6f37f0ab0073d83 /doc/Makefile | |
parent | 9fab25beeac99c0295f1a1f3db5aae711e564d72 (diff) | |
download | luaotfload-708c689312e75953db431f8838846996ff447789.tar.gz |
[doc] add Makefile for doc subtree
Diffstat (limited to 'doc/Makefile')
-rw-r--r-- | doc/Makefile | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/doc/Makefile b/doc/Makefile new file mode 100644 index 0000000..1ef7243 --- /dev/null +++ b/doc/Makefile @@ -0,0 +1,46 @@ +NAME = luaotfload +DOCPDF = $(NAME).pdf +DOCDTX = $(NAME).dtx + +SCRIPTNAME = luaotfload-tool +MANSOURCE = $(SCRIPTNAME).rst +MANPAGE = $(SCRIPTNAME).1 + +GRAPH = filegraph +DOTPDF = $(GRAPH).pdf +DOT = $(GRAPH).dot + +DOCS = $(DOTPDF) $(DOCPDF) $(MANPAGE) + +DO_LATEXMK = @latexmk -e '$$max_repeat = 5' -pdf -lualatex -silent $< >/dev/null +# latexmk does only one run on my machine, so we’re not going to rely on it +DO_LATEX = @lualatex -interaction=batchmode $< >/dev/null +DO_GRAPHVIZ = @dot -Tpdf -o $@ $< > /dev/null +DO_DOCUTILS = @rst2man $< >$@ 2>/dev/null + +doc: graph $(DOCPDF) +all: manual doc +graph: $(DOTPDF) +manual: $(MANPAGE) + +$(DOCPDF): $(DOCDTX) + @echo "creating PDF documentation ($(DOCPDF))" + $(DO_LATEX) + $(DO_LATEX) + +$(MANPAGE): $(MANSOURCE) + @echo "creating man page ($(MANPAGE))" + $(DO_DOCUTILS) + +$(DOTPDF): $(DOT) + @echo "creating file graph ($(DOTPDF))" + $(DO_GRAPHVIZ) + +.PHONY: clean mrproper + +clean: + @$(RM) -- *.log *.aux *.toc *.idx *.ind *.ilg *.out + +mrproper: clean + @$(RM) -- $(DOCS) + |