| 1 | # Minimal makefile for Sphinx documentation |
| 2 | # |
| 3 | |
| 4 | # You can set these variables from the command line. |
| 5 | SPHINXOPTS = |
| 6 | SPHINXBUILD = sphinx-build |
| 7 | SOURCEDIR = . |
| 8 | BUILDDIR = _build |
| 9 | |
| 10 | # Put it first so that "make" without argument is like "make help". $(O) here |
| 11 | # and in the other rules below is meant as a shortcut for adding options to |
| 12 | # what's in $(SPHINXOPTS). |
| 13 | help: |
| 14 | @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
| 15 | |
| 16 | # Catch-all target: route all unknown targets to Sphinx using the new |
| 17 | # "make mode" option. |
| 18 | .DEFAULT: |
| 19 | @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
| 20 | |
| 21 | # Explicitly handle this one to take care of the empty directory for the |
| 22 | # built documents. |
| 23 | clean: |
| 24 | @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) clean |
| 25 | @if test -f $(BUILDDIR) || test -d $(BUILDDIR); then rm -fr $(BUILDDIR); fi |
| 26 | |
| 27 | .PHONY: help clean |