[packages/python3-sphinxcontrib-programoutput] Rel 5.

arekm arekm at pld-linux.org
Thu Nov 12 13:35:10 CET 2026


commit c0acd511845c2bd0d3b1efa3c38dbb7bfba27d94
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date:   Thu Nov 12 13:17:24 2026 +0100

    Rel 5.
    
    docs/conf.py imports sphinxcontrib.programoutput too: run Sphinx with
    src/ first in the namespace, like the tests.

 python3-sphinxcontrib-programoutput.spec | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)
---
diff --git a/python3-sphinxcontrib-programoutput.spec b/python3-sphinxcontrib-programoutput.spec
index b825944..c0265be 100644
--- a/python3-sphinxcontrib-programoutput.spec
+++ b/python3-sphinxcontrib-programoutput.spec
@@ -7,7 +7,7 @@ Summary:	Sphinx extension to include program output
 Summary(pl.UTF-8):	Rozszerzenie Sphinksa do załączania wyjścia programu
 Name:		python3-sphinxcontrib-programoutput
 Version:	0.20
-Release:	4
+Release:	5
 License:	BSD
 Group:		Libraries/Python
 #Source0Download: https://pypi.org/simple/sphinxcontrib-programoutput/
@@ -56,6 +56,11 @@ API documentation for Python sphinxcontrib-programoutput module.
 %description apidocs -l pl.UTF-8
 Dokumentacja API modułu Pythona sphinxcontrib-programoutput.
 
+# the sphinxcontrib namespace comes from site-packages (nspkg.pth of other
+# sphinxcontrib packages, pkgutil __init__.py), which ignores src/ or puts
+# it after an installed copy; tests and docs put src/ first explicitly
+%define	src_first	import sys, sphinxcontrib; sphinxcontrib.__path__ = [sys.argv.pop(1), *sphinxcontrib.__path__]
+
 %prep
 %setup -q -n sphinxcontrib_programoutput-%{version}
 
@@ -63,17 +68,15 @@ Dokumentacja API modułu Pythona sphinxcontrib-programoutput.
 %py3_build
 
 %if %{with tests}
-# the sphinxcontrib namespace comes from site-packages (nspkg.pth of other
-# sphinxcontrib packages, pkgutil __init__.py), which ignores src/ or puts
-# it after an installed copy; put src/ first explicitly
 PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
 PYTHONPATH=$(pwd)/src \
-%{__python3} -c 'import sys, sphinxcontrib, pytest; sphinxcontrib.__path__ = [sys.argv[1], *sphinxcontrib.__path__]; sys.exit(pytest.main(["src"]))' $(pwd)/src/sphinxcontrib
+%{__python3} -c '%{src_first}; import pytest; sys.exit(pytest.main(["src"]))' $(pwd)/src/sphinxcontrib
 %endif
 
 %if %{with doc}
 PYTHONPATH=$(pwd)/src \
-sphinx-build-3 -b html docs docs/_build/html
+%{__python3} -c '%{src_first}; from sphinx.cmd.build import main; sys.exit(main(sys.argv[1:]))' $(pwd)/src/sphinxcontrib \
+	-b html docs docs/_build/html
 %endif
 
 %install
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python3-sphinxcontrib-programoutput.git/commitdiff/c0acd511845c2bd0d3b1efa3c38dbb7bfba27d94



More information about the pld-cvs-commit mailing list