]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.13] gh-139741: Make `dist-pdf` docs archive build work for macOS (GH-140837) ...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Sat, 8 Nov 2025 10:26:51 +0000 (11:26 +0100)
committerGitHub <noreply@github.com>
Sat, 8 Nov 2025 10:26:51 +0000 (10:26 +0000)
Co-authored-by: Naitree Zhu <Naitreey@gmail.com>
Doc/Makefile

index f6f4c721080c4259730ca1f427e0c02b2d6cff86..f16d9cacb1b6fb92b3efdec0252b4b4c1173d807 100644 (file)
@@ -241,7 +241,8 @@ dist-pdf:
        # as otherwise the full latexmk process is run twice.
        # ($$ is needed to escape the $; https://www.gnu.org/software/make/manual/make.html#Basics-of-Variable-References)
        -sed -i 's/: all-$$(FMT)/:/' build/latex/Makefile
-       (cd build/latex; $(MAKE) clean && $(MAKE) --jobs=$$((`nproc`+1)) --output-sync LATEXMKOPTS='-quiet' all-pdf && $(MAKE) FMT=pdf zip bz2)
+       if [ -n "$(filter output-sync,$(value .FEATURES))" ]; then OUTPUTSYNC=--output-sync; else OUTPUTSYNC=; fi && \
+       (cd build/latex; $(MAKE) clean && $(MAKE) --jobs=$$((`getconf _NPROCESSORS_ONLN`+1)) $$OUTPUTSYNC LATEXMKOPTS='-quiet' all-pdf && $(MAKE) FMT=pdf zip bz2)
        cp build/latex/docs-pdf.zip dist/python-$(DISTVERSION)-docs-pdf-a4.zip
        cp build/latex/docs-pdf.tar.bz2 dist/python-$(DISTVERSION)-docs-pdf-a4.tar.bz2
        @echo "Build finished and archived!"