summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorDavid Bremner <david@tethera.net>2020-07-11 10:20:26 -0300
committerDavid Bremner <david@tethera.net>2020-07-15 08:32:15 -0300
commit0e03e2d45e36edb635229f356bf41f153c30a70f (patch)
tree523cef4c6c6be805f06bff83b4fc5eee1eef78ff /configure
parent78e9b3467d9f09228a444bb2eec93e4c765b7e9b (diff)
doc: replace use of environment variables with a generated config
It is getting unwieldy to pass configuration options on the sphinx-build command line, and I anticipate further use of conditionals. As far as I could tell, execing a string is the idiomatic way to emulate include in Python.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure8
1 files changed, 8 insertions, 0 deletions
diff --git a/configure b/configure
index 4e16ff40..c8690d3a 100755
--- a/configure
+++ b/configure
@@ -1548,6 +1548,14 @@ NOTMUCH_HAVE_PYTHON3_PYTEST=${have_python3_pytest}
PLATFORM=${platform}
EOF
+cat > sphinx.config <<EOF
+# Generated by configure, run from doc/conf.py
+EOF
+if [ $WITH_EMACS = "1" ]; then
+ printf "tags.add('WITH_EMACS')\n" >> sphinx.config
+fi
+printf "rsti_dir = '%s'\n" $(realpath emacs) >> sphinx.config
+
# Finally, after everything configured, inform the user how to continue.
cat <<EOF