aboutsummaryrefslogtreecommitdiffhomepage
path: root/doc/Makefile.local
blob: 471924736124af44a7138a3eb774530667d3e3ee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# -*- makefile -*-

dir := doc

# You can set these variables from the command line.
SPHINXOPTS    := -q -c $(dir)
SPHINXBUILD   = sphinx-build
DOCBUILDDIR      := $(dir)/_build

prerst2man := python $(dir)/prerst2man.py

# Internal variables.
ALLSPHINXOPTS   := -d $(DOCBUILDDIR)/doctrees $(SPHINXOPTS) $(dir)

.PHONY: sphinx-html sphinx-man sphinx-texinfo sphinx-info
.PHONY: rst2man

sphinx-html:
	$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(DOCBUILDDIR)/html

sphinx-man:
	$(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(DOCBUILDDIR)/man

sphinx-texinfo:
	$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(DOCBUILDDIR)/texinfo

sphinx-info: sphinx-texinfo
	make -C $(DOCBUILDDIR)/texinfo info

# fallback target in case sphinx not installed
rst2man:
	$(prerst2man) $(DOCBUILDDIR)/.. $(DOCBUILDDIR)/man

CLEAN := $(CLEAN) $(DOCBUILDDIR)