on master help sign in
[fix] buildprocess of the docs by adding sphinx-doc-prebuilds target
15924bcMarkus Heiser
Makefile+10−7
@@ -77,19 +77,22 @@ run: buildenv pyenvinstall
77# docs
77# docs
78# ----
78# ----
79
79
80+sphinx-doc-prebuilds:: buildenv pyenvinstall prebuild-includes
81+
80PHONY += docs
82PHONY += docs
81−docs: buildenv pyenvinstall sphinx-doc prebuild-includes
83+docs: sphinx-doc-prebuilds sphinx-doc
82 $(call cmd,sphinx,html,docs,docs)
84 $(call cmd,sphinx,html,docs,docs)
83
85
84−PHONY += docs-live prebuild-includes
86+PHONY += docs-live
85−docs-live: buildenv pyenvinstall sphinx-live prebuild-includes
87+docs-live: sphinx-doc-prebuilds sphinx-live
86 $(call cmd,sphinx_autobuild,html,docs,docs)
88 $(call cmd,sphinx_autobuild,html,docs,docs)
87
89
90+PHONY += prebuild-includes
88prebuild-includes:
91prebuild-includes:
89− @mkdir -p $(DOCS_BUILD)/includes
92+ $(Q)mkdir -p $(DOCS_BUILD)/includes
90− @./utils/searx.sh doc | cat > $(DOCS_BUILD)/includes/searx.rst
93+ $(Q)./utils/searx.sh doc | cat > $(DOCS_BUILD)/includes/searx.rst
91− @./utils/filtron.sh doc | cat > $(DOCS_BUILD)/includes/filtron.rst
94+ $(Q)./utils/filtron.sh doc | cat > $(DOCS_BUILD)/includes/filtron.rst
92− @./utils/morty.sh doc | cat > $(DOCS_BUILD)/includes/morty.rst
95+ $(Q)./utils/morty.sh doc | cat > $(DOCS_BUILD)/includes/morty.rst
93
96
94
97
95$(GH_PAGES)::
98$(GH_PAGES)::
utils/makefile.sphinx+7−5
@@ -7,12 +7,12 @@ SPHINXOPTS ?=
7SPHINXBUILD ?= $(PY_ENV_BIN)/sphinx-build
7SPHINXBUILD ?= $(PY_ENV_BIN)/sphinx-build
8SPHINX_CONF ?= conf.py
8SPHINX_CONF ?= conf.py
9
9
10−DOCS_FOLDER = ./$(LXC_ENV_FOLDER)docs
10+DOCS_FOLDER = ./docs
11DOCS_BUILD = ./$(LXC_ENV_FOLDER)build/docs
11DOCS_BUILD = ./$(LXC_ENV_FOLDER)build/docs
12DOCS_DIST = ./$(LXC_ENV_FOLDER)dist/docs
12DOCS_DIST = ./$(LXC_ENV_FOLDER)dist/docs
13GH_PAGES ?= gh-pages
13GH_PAGES ?= gh-pages
14
14
15−BOOKS_FOLDER = ./$(LXC_ENV_FOLDER)docs
15+BOOKS_FOLDER = ./docs
16BOOKS_DIST = ./$(LXC_ENV_FOLDER)dist/books
16BOOKS_DIST = ./$(LXC_ENV_FOLDER)dist/books
17
17
18ifeq ($(KBUILD_VERBOSE),1)
18ifeq ($(KBUILD_VERBOSE),1)
@@ -56,11 +56,13 @@ docs-help:
56# requirements
56# requirements
57# ------------------------------------------------------------------------------
57# ------------------------------------------------------------------------------
58
58
59−sphinx-doc: $(PY_ENV)
59+sphinx-doc-prebuilds:: $(PY_ENV)
60+
61+sphinx-doc: sphinx-doc-prebuilds
60 @echo "PYENV installing Sphinx$(SPHINXVERS)"
62 @echo "PYENV installing Sphinx$(SPHINXVERS)"
61 $(Q)$(PY_ENV_BIN)/pip install $(PIP_VERBOSE) 'Sphinx$(SPHINXVERS)'
63 $(Q)$(PY_ENV_BIN)/pip install $(PIP_VERBOSE) 'Sphinx$(SPHINXVERS)'
62
64
63−sphinx-live: $(PY_ENV)
65+sphinx-live: sphinx-doc-prebuilds
64 @echo "PYENV installing Sphinx$(SPHINXVERS)"
66 @echo "PYENV installing Sphinx$(SPHINXVERS)"
65 $(Q)$(PY_ENV_BIN)/pip install $(PIP_VERBOSE) 'Sphinx$(SPHINXVERS)' sphinx-autobuild
67 $(Q)$(PY_ENV_BIN)/pip install $(PIP_VERBOSE) 'Sphinx$(SPHINXVERS)' sphinx-autobuild
66
68
@@ -115,7 +117,7 @@ quiet_cmd_sphinx_clean = CLEAN $@
115# targets
117# targets
116# ------------------------------------------------------------------------------
118# ------------------------------------------------------------------------------
117
119
118−# build PDF of whole documentation in: $(DOCS_DIST)/pdf
120+# build PDF of whole documentation in: $(DOCS_DIST)/pdf
119
121
120PHONY += sphinx-pdf
122PHONY += sphinx-pdf
121sphinx-pdf: sphinx-latex
123sphinx-pdf: sphinx-latex