[sagemath] 02/05: Basic version of deduplicating the docs, for a much smaller install size
Ximin Luo
infinity0 at debian.org
Fri Aug 18 16:55:21 UTC 2017
This is an automated email from the git hooks/post-receive script.
infinity0 pushed a commit to branch master
in repository sagemath.
commit 70378383dccdc421e8b75a4d41268af48e7a0d13
Author: Ximin Luo <infinity0 at debian.org>
Date: Fri Aug 18 16:11:48 2017 +0200
Basic version of deduplicating the docs, for a much smaller install size
---
debian/changelog | 1 +
debian/control.in | 1 +
debian/rules | 9 ++++++++-
3 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/debian/changelog b/debian/changelog
index 0f195e8..2a60d17 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,7 @@
sagemath (8.0-4) UNRELEASED; urgency=medium
* Relax the runtime dependencies.
+ * Deduplicate the documentation using rdfind(1).
-- Ximin Luo <infinity0 at debian.org> Thu, 17 Aug 2017 12:08:03 +0200
diff --git a/debian/control.in b/debian/control.in
index 40426fd..59f3e53 100644
--- a/debian/control.in
+++ b/debian/control.in
@@ -75,6 +75,7 @@ Build-Depends:
python-dev,
python3-dev,
r-base-dev,
+ rdfind,
scons,
texlive-latex-base,
zlib1g-dev,
diff --git a/debian/rules b/debian/rules
index 31a65e3..b8a21d1 100755
--- a/debian/rules
+++ b/debian/rules
@@ -35,6 +35,7 @@ LANGS = $(shell cd sage/src/doc && find . -mindepth 1 -maxdepth 1 -type d | grep
DOCS_INSTALL = $(LANGS:%=debian/sagemath-doc-%.install)
DOCS_CONTROL = $(LANGS:%=debian/sagemath-doc-%.control)
DOCS_DOC_BASE = $(LANGS:%=debian/sagemath-doc-%.doc-base)
+DOCS_INSTALL_DIRS = $(LANGS:%=debian/sagemath-doc-%)
ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
@@ -179,9 +180,15 @@ else
dh_auto_clean -Dsage -- maintainer-clean
endif
-override_dh_install: $(DOCS_INSTALL) $(DOCS_DOC_BASE)
+override_dh_install-indep: $(DOCS_INSTALL) $(DOCS_DOC_BASE)
dh_install --package sagemath-common -X.so
dh_install --remaining-packages --list-missing
+# Basic version of deduplicating the docs, for a much smaller install size.
+# Upstream bug report is at https://trac.sagemath.org/ticket/22088
+# Hard links do work in Debian packages, but only within packages.
+ set -e; for d in $(DOCS_INSTALL_DIRS); do \
+ rdfind -outputname /dev/null -makehardlinks true "$$d"; \
+ done
override_dh_python2-arch:
dh_python2
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/sagemath.git
More information about the debian-science-commits
mailing list