Before this patch, building htmldocs on opensuseLEAP works
fine:
# make htmldocs
Available Python versions:
/usr/bin/python3.11
Python 3.6.15 not supported. Changing to /usr/bin/python3.11
Python 3.6.15 not supported. Changing to /usr/bin/python3.11
Using alabaster theme
Using Python kernel-doc
...
As the logic detects that Python 3.6 is too old and recommends
intalling python311-Sphinx. If installed, documentation builds
work like a charm.
Yet, some develpers complained that running python3.11 instead
of python3 should not happen. So, let's break the build to make
them happier:
# make htmldocs Available Python versions:
/usr/bin/python3.11
Python 3.6.15 not supported. Bailing out
make[2]: *** [Documentation/Makefile:74: htmldocs] Error 1
make[1]: *** [/root/Makefile:1806: htmldocs] Error 2
make: *** [Makefile:248: __sub-make] Error 2
It should be then up to the user to figure out a way to make
it work again.
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
---
tools/docs/sphinx-pre-install | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/docs/sphinx-pre-install b/tools/docs/sphinx-pre-install
index 663d4e2a3f57..ecd08e09bae9 100755
--- a/tools/docs/sphinx-pre-install
+++ b/tools/docs/sphinx-pre-install
@@ -1531,7 +1531,7 @@ def main():
checker = SphinxDependencyChecker(args)
- PythonVersion.check_python(MIN_PYTHON_VERSION)
+ PythonVersion.check_python(MIN_PYTHON_VERSION, show_alternatives=True)
checker.check_needs()
# Call main if not used as module
--
2.51.0