scripts: sphinx-pre-install: some adjustments related to venv
While nothing was really needed for virtualenv to work on most distros, we had an issue with OpenMandriva. While checking for it, it was noticed that there was no check if python-virtualenv was installed. This didn't solve the issues we faced there: at least with the half-broken OpenMandriva Lx 4.0 docker container we used, ensurepip was not available anywhere, causing venv to fail. Add a distro-specific note about that. Note: at least at the time we did our tests, OpenMandriva Lx 4.0 docker was shipped with wrong dnf repositories. Also, there was no repos available for it anymore. So, we had to do some hacks to upgrade to 4.3 before being able to run any tests. Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Link: https://lore.kernel.org/r/e3a0e5eccd50eb506846e3e8487a2d9124ef83e2.1754992972.git.mchehab+huawei@kernel.org
This commit is contained in:
committed by
Jonathan Corbet
parent
491a99511e
commit
6170b1eaca
@@ -983,6 +983,22 @@ class SphinxDependencyChecker(MissingCheckers):
|
||||
# Tested on OpenMandriva Lx 4.3
|
||||
progs["convert"] = "imagemagick"
|
||||
progs["yaml"] = "python-pyyaml"
|
||||
progs["python-virtualenv"] = "python-virtualenv"
|
||||
progs["python-sphinx"] = "python-sphinx"
|
||||
|
||||
self.check_program("python-virtualenv", DepManager.PYTHON_MANDATORY)
|
||||
|
||||
# On my tests with openMandriva LX 4.0 docker image, upgraded
|
||||
# to 4.3, python-virtualenv package is broken: it is missing
|
||||
# ensurepip. Without it, the alternative would be to run:
|
||||
# python3 -m venv --without-pip ~/sphinx_latest, but running
|
||||
# pip there won't install sphinx at venv.
|
||||
#
|
||||
# Add a note about that.
|
||||
|
||||
if not self.distro_msg:
|
||||
self.distro_msg = \
|
||||
"Note: for venv, ensurepip could be broken, preventing its install method."
|
||||
|
||||
else:
|
||||
packager_cmd = "urpmi"
|
||||
|
||||
Reference in New Issue
Block a user