[PATCH 0/4] Address some issues with sphinx detection

Mauro Carvalho Chehab posted 4 patches 3 years, 10 months ago
There is a newer version of this series
scripts/sphinx-pre-install | 74 ++++++++++++++++++++++++++++----------
1 file changed, 55 insertions(+), 19 deletions(-)
[PATCH 0/4] Address some issues with sphinx detection
Posted by Mauro Carvalho Chehab 3 years, 10 months ago
Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>,
 linux-kernel@vger.kernel.org, Jonathan Corbet <corbet@lwn.net>,
 ksummit-discuss@lists.linuxfoundation.org
Cc: "Jonathan Corbet" <corbet@lwn.net>
Cc: "Mauro Carvalho Chehab" <mchehab+huawei@kernel.org>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: ksummit-discuss@lists.linuxfoundation.org
Cc: linux-doc@vger.kernel.org
Cc: linux-kernel@vger.kernel.org

Checking if Sphinx is available and read to run is tricky, and may involve
installing several packages for the document build to happen.

There are two options to install Sphinx:

	- via distro-provided packages;
	- via pip, using virtualenv/venv.

Some recent discussions showed a couple of misleading instructions.

This series improves the Sphinx detection by:

- Fixing the logich with checks if a past venv is working and recommend
  just enabling it instead of installing a new venv;
- Detect if sphinx-build stopped working on a venv. This may happen during
  distribution updates;
- Move the PDF minimal version to be later, in order for it to be printed only
  after finishing the Sphinx version check;

Additionally, as now the Sphinx provided on almost all modern distros are
above the minimal required version, place instructions about how to install
Sphinx from the distro-provided packages after placing the instructions for
installing it via venv.

This will hopefully help to have more developers checking documentation
builds with

	make htmldocs

Mauro Carvalho Chehab (4):
  scripts: sphinx-pre-install: fix venv version check logic
  scripts: sphinx-pre-install: report broken venv
  scripts: sphinx-pre-install: check for PDF min version later on
  scripts: sphinx-pre-install: provide both venv and package installs

 scripts/sphinx-pre-install | 74 ++++++++++++++++++++++++++++----------
 1 file changed, 55 insertions(+), 19 deletions(-)

-- 
2.36.1