[master] b782c2c6d Revert "Use sphinx source/build facility directly"

Nils Goroll nils.goroll at uplex.de
Wed Jun 10 08:06:07 UTC 2020


commit b782c2c6d4ec3710dcd7124959c1a6a505a34f70
Author: Nils Goroll <nils.goroll at uplex.de>
Date:   Fri May 8 19:29:38 2020 +0200

    Revert "Use sphinx source/build facility directly"
    
    Partially reverts commit 883fddfea4e185ff417762fb64207b81d4cea971.
    
    Ref #3309

diff --git a/doc/sphinx/Makefile.am b/doc/sphinx/Makefile.am
index 7c2a38a37..fa71cacc9 100644
--- a/doc/sphinx/Makefile.am
+++ b/doc/sphinx/Makefile.am
@@ -5,9 +5,9 @@
 SPHINXOPTS    =
 SPHINXBUILD   = $(SPHINX) -W -q -N
 PAPER         = a4
-BUILDDIR      = $(builddir)/build
+BUILDDIR      = build
 
-ALLSPHINXOPTS   = -d $(BUILDDIR)/doctrees -D latex_elements.papersize=$(PAPER) $(SPHINXOPTS) $(srcdir)
+ALLSPHINXOPTS   = -d $(BUILDDIR)/doctrees -D latex_elements.papersize=$(PAPER) $(SPHINXOPTS) $(builddir)
 
 .PHONY: help clean html dirhtml pickle json htmlhelp qthelp latex changes linkcheck doctest
 
@@ -27,12 +27,22 @@ help:
 clean:
 	-rm -rf $(BUILDDIR)/* $(CLEANFILES)
 
+# use index.rst as an indicator if we have copied already
+.PHONY: link_srcdir
+link_srcdir:
+	if test "x$(srcdir)" != "x$(builddir)" && test ! -f index.rst ; then \
+		d=`pwd`/$(builddir) ; \
+		cd $(srcdir) && find . -type f | cpio -dmp $${d} || true ; \
+	fi
+
 # work around for make html called within doc/sphinx
 .PHONY: graphviz
 graphviz:
 	cd ../graphviz && $(MAKE) html
 
-sphinx_prereq: graphviz conf.py
+sphinx_prereq: link_srcdir graphviz conf.py
+
+all: link_srcdir
 
 html: sphinx_prereq
 	$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html


More information about the varnish-commit mailing list