[Bf-blender-cvs] [e748abda92c] master: PyDoc: Remove workaround for slow sphinx builds

Aaron Carlisle noreply at git.blender.org
Wed Oct 7 16:27:27 CEST 2020


Commit: e748abda92cf71852db29150f4f2524e3a17b156
Author: Aaron Carlisle
Date:   Wed Oct 7 10:14:42 2020 -0400
Branches: master
https://developer.blender.org/rBe748abda92cf71852db29150f4f2524e3a17b156

PyDoc: Remove workaround for slow sphinx builds

Tesing with newer versions of sphinx to directory `sphinx-build` is 
executed has no affect on the build time. Testing even gave a 2-3% speed 
boost.

===================================================================

M	GNUmakefile
M	doc/python_api/sphinx_doc_gen.py
M	doc/python_api/sphinx_doc_gen.sh

===================================================================

diff --git a/GNUmakefile b/GNUmakefile
index ffde7885301..e4b5f3b99dc 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -517,7 +517,7 @@ doc_py: .FORCE
 	ASAN_OPTIONS=halt_on_error=0 \
 	$(BLENDER_BIN) --background -noaudio --factory-startup \
 		--python doc/python_api/sphinx_doc_gen.py
-	cd doc/python_api ; sphinx-build -b html sphinx-in sphinx-out
+	sphinx-build -b html doc/python_api/sphinx-in doc/python_api/sphinx-out
 	@echo "docs written into: '$(BLENDER_DIR)/doc/python_api/sphinx-out/index.html'"
 
 doc_doxy: .FORCE
diff --git a/doc/python_api/sphinx_doc_gen.py b/doc/python_api/sphinx_doc_gen.py
index 7e9a42a721a..9526e236f20 100644
--- a/doc/python_api/sphinx_doc_gen.py
+++ b/doc/python_api/sphinx_doc_gen.py
@@ -41,8 +41,7 @@ Sphinx: HTML generation
   After you have built doc/python_api/sphinx-in (see above),
   generate html docs by running:
 
-    cd doc/python_api
-    sphinx-build sphinx-in sphinx-out
+    sphinx-build doc/python_api/sphinx-in doc/python_api/sphinx-out
 
 
 Sphinx: PDF generation
diff --git a/doc/python_api/sphinx_doc_gen.sh b/doc/python_api/sphinx_doc_gen.sh
index 1c5b9ec0b61..be11a10d053 100755
--- a/doc/python_api/sphinx_doc_gen.sh
+++ b/doc/python_api/sphinx_doc_gen.sh
@@ -76,11 +76,7 @@ fi
 # Generate HTML (sphinx)
 
 if $DO_OUT_HTML ; then
-  # sphinx-build -n -b html $SPHINX_WORKDIR/sphinx-in $SPHINX_WORKDIR/sphinx-out
-
-  # annoying bug in sphinx makes it very slow unless we do this. should report.
-  cd $SPHINX_WORKDIR
-  sphinx-build -b html sphinx-in sphinx-out
+  sphinx-build -b html $SPHINX_WORKDIR/sphinx-in $SPHINX_WORKDIR/sphinx-out
 
   # XXX, saves space on upload and zip, should move HTML outside
   # and zip up there, for now this is OK
@@ -107,7 +103,6 @@ fi
 # Generate PDF (sphinx/laytex)
 
 if $DO_OUT_PDF ; then
-  cd $SPHINX_WORKDIR
   sphinx-build -n -b latex $SPHINX_WORKDIR/sphinx-in $SPHINX_WORKDIR/sphinx-out
   make -C $SPHINX_WORKDIR/sphinx-out
   mv $SPHINX_WORKDIR/sphinx-out/contents.pdf \



More information about the Bf-blender-cvs mailing list