Debian Codegraph @

docs/Makefile

raw
1 # Makefile for Sphinx documentation
2 #
3
4 # You can set these variables from the command line.
5 SPHINXOPTS =
6 SPHINXBUILD = sphinx-build
7 PAPER =
8 BUILDDIR = build
9
10 # Internal variables.
11 PAPEROPT_a4 = -D latex_paper_size=a4
12 PAPEROPT_letter = -D latex_paper_size=letter
13 ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
14
15 .PHONY: help clean html dirhtml pickle json htmlhelp qthelp latex changes linkcheck doctest
16
17 help:
18 @echo "Please use \`make <target>' where <target> is one of"
19 @echo " html to make standalone HTML files"
20 @echo " pdf to make PDF document"
21 @echo " dirhtml to make HTML files named index.html in directories"
22 @echo " pickle to make pickle files"
23 @echo " json to make JSON files"
24 @echo " htmlhelp to make HTML files and a HTML help project"
25 @echo " qthelp to make HTML files and a qthelp project"
26 @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
27 @echo " changes to make an overview of all changed/added/deprecated items"
28 @echo " linkcheck to check all external links for integrity"
29 @echo " doctest to run all doctests embedded in the documentation (if enabled)"
30
31 clean:
32 -rm -rf $(BUILDDIR)/*
33
34 apidocs:
35 sphinx-apidoc -feM -s txt -o api ../dulwich
36
37 html: apidocs
38 $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
39 @echo
40 @echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
41
42 dirhtml: apidocs
43 $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
44 @echo
45 @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
46
47 pickle: apidocs
48 $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
49 @echo
50 @echo "Build finished; now you can process the pickle files."
51
52 json: apidocs
53 $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
54 @echo
55 @echo "Build finished; now you can process the JSON files."
56
57 htmlhelp: apidocs
58 $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
59 @echo
60 @echo "Build finished; now you can run HTML Help Workshop with the" \
61 ".hhp project file in $(BUILDDIR)/htmlhelp."
62
63 qthelp: apidocs
64 $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
65 @echo
66 @echo "Build finished; now you can run "qcollectiongenerator" with the" \
67 ".qhcp project file in $(BUILDDIR)/qthelp, like this:"
68 @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/dulwich.qhcp"
69 @echo "To view the help file:"
70 @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/dulwich.qhc"
71
72 latex: apidocs
73 $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
74 @echo
75 @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
76 @echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \
77 "run these through (pdf)latex."
78
79 changes: apidocs
80 $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
81 @echo
82 @echo "The overview file is in $(BUILDDIR)/changes."
83
84 linkcheck:
85 $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
86 @echo
87 @echo "Link check complete; look for any errors in the above output " \
88 "or in $(BUILDDIR)/linkcheck/output.txt."
89
90 doctest:
91 $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
92 @echo "Testing of doctests in the sources finished, look at the " \
93 "results in $(BUILDDIR)/doctest/output.txt."
94
95 pdf:
96 $(SPHINXBUILD) -b pdf $(ALLSPHINXOPTS) $(BUILDDIR)/pdf
97 @echo
98 @echo "Build finished. The PDF files are in $(BUILDDIR)/pdf."
99