From: Thomas Monjalon Date: Wed, 15 Oct 2014 20:12:20 +0000 (+0200) Subject: mk: generate html guides with sphinx X-Git-Tag: spdx-start~10270 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=3fbcfb76190f322f9c15bcc0057a437bc42775c8;p=dpdk.git mk: generate html guides with sphinx Add minimal configuration and index to validate new rules inside "make doc" and "make doc-clean". RTE_SPHINX_BUILD can be overriden. Signed-off-by: Thomas Monjalon --- diff --git a/doc/guides/conf.py b/doc/guides/conf.py new file mode 100644 index 0000000000..25978a0fba --- /dev/null +++ b/doc/guides/conf.py @@ -0,0 +1,3 @@ +project = 'DPDK' + +master_doc = 'index' diff --git a/doc/guides/index.rst b/doc/guides/index.rst new file mode 100644 index 0000000000..70938be97d --- /dev/null +++ b/doc/guides/index.rst @@ -0,0 +1,4 @@ +DPDK documentation +================== + +.. toctree:: diff --git a/mk/rte.sdkdoc.mk b/mk/rte.sdkdoc.mk index f305bf98e8..995daf3dd3 100644 --- a/mk/rte.sdkdoc.mk +++ b/mk/rte.sdkdoc.mk @@ -36,16 +36,24 @@ $(error "Cannot use T= with doc target") endif endif +RTE_SPHINX_BUILD = sphinx-build +ifndef V +RTE_SPHINX_VERBOSE := -q +endif +ifeq '$V' '0' +RTE_SPHINX_VERBOSE := -q +endif + .PHONY: help help: @cat $(RTE_SDK)/doc/build-sdk-quick.txt @$(MAKE) -rR showconfigs | sed 's,^,\t\t\t\t,' .PHONY: all -all: api-html +all: api-html guides-html .PHONY: clean -clean: api-html-clean +clean: api-html-clean guides-html-clean .PHONY: api-html api-html: api-html-clean @@ -62,7 +70,16 @@ api-html: api-html-clean doxygen - $(Q)$(RTE_SDK)/doc/api/doxy-html-custom.sh $(RTE_OUTPUT)/doc/html/api/doxygen.css +guides-%: + @echo 'sphinx for guides...' + $(Q)$(RTE_SPHINX_BUILD) -b $* $(RTE_SPHINX_VERBOSE) \ + -c $(RTE_SDK)/doc/guides $(RTE_SDK)/doc/guides $(RTE_OUTPUT)/doc/$*/guides + .PHONY: api-html-clean api-html-clean: $(Q)rm -f $(RTE_OUTPUT)/doc/html/api/* $(Q)rmdir -p --ignore-fail-on-non-empty $(RTE_OUTPUT)/doc/html/api 2>&- || true + +guides-%-clean: + $(Q)rm -rf $(RTE_OUTPUT)/doc/$*/guides + $(Q)rmdir -p --ignore-fail-on-non-empty $(RTE_OUTPUT)/doc/$* 2>&- || true