doc/man-html/index.html: ENABLE_MANPAGES = 1
doc/man-html/index.html: doc/manpages-enabled.rst $(mandocrst)
+if HAS_SPHINX_PRE13
+ SPHINX_HTML_THEME=default
+else
+ SPHINX_HTML_THEME=classic
+endif
# Note: we use here an order-only prerequisite, as the contents of
# _constants.py are not actually influencing the html build output: it
# has to exist in order for the sphinx module to be loaded
dir=$(dir $@) && \
@mkdir_p@ $$dir && \
PYTHONPATH=. ENABLE_MANPAGES=$(ENABLE_MANPAGES) COPY_DOC=1 \
+ HTML_THEME=$(SPHINX_HTML_THEME) \
$(RUN_IN_TEMPDIR) autotools/sphinx-wrapper $(SPHINX) -q -W -b html \
-d . \
-D version="$(VERSION_MAJOR).$(VERSION_MINOR)" \
-D release="$(PACKAGE_VERSION)" \
-D graphviz_dot="$(DOT)" \
- -D enable_manpages="$(ENABLE_MANPAGES)" \
doc $(CURDIR)/$$dir && \
rm -f $$dir/.buildinfo $$dir/objects.inv
touch $@
fi
fi
AM_CONDITIONAL([HAS_SPHINX], [test -n "$SPHINX"])
+AM_CONDITIONAL([HAS_SPHINX_PRE13],
+ [test -n "$SPHINX" && echo "$sphinxver" | grep -q -E \
+ '^Sphinx([[[:space:]]]+|\(sphinx-build[[1-9]]?\)|v)*[[1-9]]\.[[0-2]]\.'])
AC_ARG_ENABLE([manpages-in-doc],
[AS_HELP_STRING([--enable-manpages-in-doc],
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
-html_theme = "default"
+html_theme = os.getenv("HTML_THEME")
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the