]> granicus.if.org Git - python/commitdiff
bpo-34293: Fix PDF documentation paper size (GH-8585)
authorJean-François B <jfbu@free.fr>
Mon, 9 Sep 2019 21:52:03 +0000 (23:52 +0200)
committerZachary Ware <zachary.ware@gmail.com>
Mon, 9 Sep 2019 21:52:03 +0000 (22:52 +0100)
The "A4" pdfs were previously the wrong size due to a change in the options in Sphinx 1.5.

See also sphinx-doc/sphinx#5235

Doc/Makefile
Misc/NEWS.d/next/Documentation/2018-07-31-15-38-26.bpo-34293.yHupAL.rst [new file with mode: 0644]

index 3bcd9f23752b00a8f069efe6826b491aa080a623..f06689f83d8763969c7c62be534fa00e591e9673 100644 (file)
@@ -13,7 +13,11 @@ SOURCES      =
 DISTVERSION  = $(shell $(PYTHON) tools/extensions/patchlevel.py)
 SPHINXERRORHANDLING = -W
 
-ALLSPHINXOPTS = -b $(BUILDER) -d build/doctrees -D latex_elements.papersize=$(PAPER) \
+# Internal variables.
+PAPEROPT_a4     = -D latex_elements.papersize=a4paper
+PAPEROPT_letter = -D latex_elements.papersize=letterpaper
+
+ALLSPHINXOPTS = -b $(BUILDER) -d build/doctrees $(PAPEROPT_$(PAPER)) \
                 $(SPHINXOPTS) $(SPHINXERRORHANDLING) . build/$(BUILDER) $(SOURCES)
 
 .PHONY: help build html htmlhelp latex text changes linkcheck \
diff --git a/Misc/NEWS.d/next/Documentation/2018-07-31-15-38-26.bpo-34293.yHupAL.rst b/Misc/NEWS.d/next/Documentation/2018-07-31-15-38-26.bpo-34293.yHupAL.rst
new file mode 100644 (file)
index 0000000..912a3ad
--- /dev/null
@@ -0,0 +1 @@
+Fix the Doc/Makefile regarding PAPER environment variable and PDF builds