https://github.com/python/cpython/commit/9737ce2ac23b86d34b2894c6a1a16fe4a0594627
commit: 9737ce2ac23b86d34b2894c6a1a16fe4a0594627
branch: 3.14
author: Maciej Olko <[email protected]>
committer: hugovk <[email protected]>
date: 2026-03-21T19:07:12+02:00
summary:

[3.14] gh-139588: Docs: fix PDF build (#145741)

files:
M Doc/Makefile
M Doc/conf.py

diff --git a/Doc/Makefile b/Doc/Makefile
index 5b7fdf8ec08ed4..6eb466a3417626 100644
--- a/Doc/Makefile
+++ b/Doc/Makefile
@@ -89,7 +89,8 @@ htmlhelp: build
 
 .PHONY: latex
 latex: BUILDER = latex
-latex: build
+latex: _ensure-sphinxcontrib-svg2pdfconverter
+       $(MAKE) build BUILDER=$(BUILDER)
        @echo "Build finished; the LaTeX files are in build/latex."
        @echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \
              "run these through (pdf)latex."
@@ -231,7 +232,7 @@ dist-text:
        @echo "Build finished and archived!"
 
 .PHONY: dist-pdf
-dist-pdf:
+dist-pdf: _ensure-sphinxcontrib-svg2pdfconverter
        # archive the A4 latex
        @echo "Building LaTeX (A4 paper)..."
        mkdir -p dist
@@ -292,6 +293,10 @@ _ensure-pre-commit:
 _ensure-sphinx-autobuild:
        $(MAKE) _ensure-package PACKAGE=sphinx-autobuild
 
+.PHONY: _ensure-sphinxcontrib-svg2pdfconverter
+_ensure-sphinxcontrib-svg2pdfconverter:
+       $(MAKE) _ensure-package PACKAGE=sphinxcontrib-svg2pdfconverter
+
 .PHONY: check
 check: _ensure-pre-commit
        $(VENVDIR)/bin/python3 -m pre_commit run --all-files
diff --git a/Doc/conf.py b/Doc/conf.py
index c0e26f4f7e1458..f4427819eda82f 100644
--- a/Doc/conf.py
+++ b/Doc/conf.py
@@ -45,6 +45,7 @@
     'linklint.ext',
     'notfound.extension',
     'sphinxext.opengraph',
+    'sphinxcontrib.rsvgconverter',
 )
 for optional_ext in _OPTIONAL_EXTENSIONS:
     try:

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]

Reply via email to