linux-doc: Copy source to build directory

This is necessary to avoid creating files in source directory, which
makes the linux-source package unclean (and unreproducible).

Firstly, Python creates bytecode files alongside the module sources.
We can and do exclude those, though.

Secondly, starting with 4.10, Documentation/media/Makefile converts
from dot to SVG and from SVG to PDF in the source directory.  These
can't easily be excluded, as SVG is also used as a source format.
This commit is contained in:
Ben Hutchings 2017-01-30 23:15:48 +00:00
parent 90c2b44bab
commit 3c80d83bb1
2 changed files with 7 additions and 4 deletions

2
debian/changelog vendored
View File

@ -15,6 +15,8 @@ linux (4.10~rc6-1~exp1) UNRELEASED; urgency=medium
* linux-doc: Update documentation file list for 4.10 * linux-doc: Update documentation file list for 4.10
* linux-doc: Fix up symlinks to gzipped docs * linux-doc: Fix up symlinks to gzipped docs
* debian/control: Add build-dependency on graphviz for documentation * debian/control: Add build-dependency on graphviz for documentation
* linux-doc: Copy source to build directory, to avoid creating files in
source directory
[ Roger Shimizu ] [ Roger Shimizu ]
* debian/copyright: Add GPL/X11 Dual License * debian/copyright: Add GPL/X11 Dual License

9
debian/rules.real vendored
View File

@ -192,10 +192,11 @@ $(STAMPS_DIR)/build_$(ARCH)_$(FEATURESET)_$(FLAVOUR):
$(STAMPS_DIR)/build-doc: DIR=$(BUILD_DIR)/build-doc $(STAMPS_DIR)/build-doc: DIR=$(BUILD_DIR)/build-doc
$(STAMPS_DIR)/build-doc: $(STAMPS_DIR)/source $(STAMPS_DIR)/build-doc: $(STAMPS_DIR)/source
rm -rf $(DIR) mkdir -p '$(BUILD_DIR)'
mkdir -p $(DIR) rm -rf '$(DIR)'
+$(MAKE_CLEAN) O='$(CURDIR)/$(DIR)' xmldocs $(call copy_source,$(DIR))
+$(MAKE_CLEAN) O='$(CURDIR)/$(DIR)' htmldocs mandocs +$(MAKE_CLEAN) -C '$(DIR)' xmldocs
+$(MAKE_CLEAN) -C '$(DIR)' htmldocs mandocs
@$(stamp) @$(stamp)
install-base: install-base: