summaryrefslogtreecommitdiffstats
path: root/Documentation/conf.py
diff options
context:
space:
mode:
authorMarkus Heiser <markus.heiser@darmarIT.de>2016-08-13 10:12:42 -0400
committerJonathan Corbet <corbet@lwn.net>2016-08-14 13:51:51 -0400
commit606b9ac81a63ab3adb7e61206b9ae34ee186a89d (patch)
tree8ff0fcf5ec5d762a0ad7fc7e05fbbeb8d17f6801 /Documentation/conf.py
parent3eb6cd6834c356f40e1633a0ced4ff9a4c59936b (diff)
doc-rst: generic way to build only sphinx sub-folders
Add a generic way to build only a reST sub-folder with or without a individual *build-theme*. * control *sub-folders* by environment SPHINXDIRS * control *build-theme* by environment SPHINX_CONF Folders with a conf.py file, matching $(srctree)/Documentation/*/conf.py can be build and distributed *stand-alone*. E.g. to compile only the html of 'media' and 'gpu' folder use:: make SPHINXDIRS="media gpu" htmldocs To use an additional sphinx-build configuration (*build-theme*) set the name of the configuration file to SPHINX_CONF. E.g. to compile only the html of 'media' with the *nit-picking* build use:: make SPHINXDIRS=media SPHINX_CONF=conf_nitpick.py htmldocs With this, the Documentation/conf.py is read first and updated with the configuration values from the Documentation/media/conf_nitpick.py. Signed-off-by: Markus Heiser <markus.heiser@darmarIT.de> Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Diffstat (limited to 'Documentation/conf.py')
-rw-r--r--Documentation/conf.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/Documentation/conf.py b/Documentation/conf.py
index 827dafc515b1..43e41ed74584 100644
--- a/Documentation/conf.py
+++ b/Documentation/conf.py
@@ -19,6 +19,7 @@ import os
19# add these directories to sys.path here. If the directory is relative to the 19# add these directories to sys.path here. If the directory is relative to the
20# documentation root, use os.path.abspath to make it absolute, like shown here. 20# documentation root, use os.path.abspath to make it absolute, like shown here.
21sys.path.insert(0, os.path.abspath('sphinx')) 21sys.path.insert(0, os.path.abspath('sphinx'))
22from load_config import loadConfig
22 23
23# -- General configuration ------------------------------------------------ 24# -- General configuration ------------------------------------------------
24 25
@@ -421,3 +422,9 @@ pdf_documents = [
421# line arguments. 422# line arguments.
422kerneldoc_bin = '../scripts/kernel-doc' 423kerneldoc_bin = '../scripts/kernel-doc'
423kerneldoc_srctree = '..' 424kerneldoc_srctree = '..'
425
426# ------------------------------------------------------------------------------
427# Since loadConfig overwrites settings from the global namespace, it has to be
428# the last statement in the conf.py file
429# ------------------------------------------------------------------------------
430loadConfig(globals())