[pgrouting] 02/02: Hardlink identical extension upgrade scripts to cut down installation size.

Christoph Berg myon at debian.org
Wed Sep 13 20:18:58 UTC 2017


This is an automated email from the git hooks/post-receive script.

myon pushed a commit to branch master
in repository pgrouting.

commit 2a454de0a569b9d24e88e326025da2cee6ce1267
Author: Christoph Berg <myon at debian.org>
Date:   Wed Sep 13 21:10:56 2017 +0200

    Hardlink identical extension upgrade scripts to cut down installation size.
    
    The installation size of the -scripts package goes down from 2.8MB to 1.4MB.
    (The size of the .deb itself moves only from 46.6kB to 46.3kB, though.)
---
 debian/changelog                    |  2 ++
 debian/control                      |  3 ++-
 debian/control.in                   |  3 ++-
 debian/patches/extension-no-version | 13 +++++++++++++
 debian/patches/series               |  1 +
 debian/rules                        |  2 ++
 6 files changed, 22 insertions(+), 2 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index e716743..bb8cc6f 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,8 @@ pgrouting (2.4.2-2) UNRELEASED; urgency=medium
 
   * Clarify -scripts package description; the SQL files are also necessary
     for the initial installation.
+  * Hardlink identical extension upgrade scripts to cut down installation
+    size.
 
  -- Christoph Berg <myon at debian.org>  Wed, 13 Sep 2017 20:18:47 +0200
 
diff --git a/debian/control b/debian/control
index 90e7af4..c0e019f 100644
--- a/debian/control
+++ b/debian/control
@@ -10,7 +10,8 @@ Build-Depends: cmake,
                libjs-mathjax,
                postgis,
                postgresql-server-dev-all,
-               python-sphinx (>= 1.0.7+dfsg)
+               python-sphinx (>= 1.0.7+dfsg),
+               rdfind,
 Standards-Version: 4.0.0
 Vcs-Browser: https://anonscm.debian.org/cgit/pkg-grass/pgrouting.git
 Vcs-Git: https://anonscm.debian.org/git/pkg-grass/pgrouting.git
diff --git a/debian/control.in b/debian/control.in
index 0e32864..097743f 100644
--- a/debian/control.in
+++ b/debian/control.in
@@ -10,7 +10,8 @@ Build-Depends: cmake,
                libjs-mathjax,
                postgis,
                postgresql-server-dev-all,
-               python-sphinx (>= 1.0.7+dfsg)
+               python-sphinx (>= 1.0.7+dfsg),
+               rdfind,
 Standards-Version: 4.0.0
 Vcs-Browser: https://anonscm.debian.org/cgit/pkg-grass/pgrouting.git
 Vcs-Git: https://anonscm.debian.org/git/pkg-grass/pgrouting.git
diff --git a/debian/patches/extension-no-version b/debian/patches/extension-no-version
new file mode 100644
index 0000000..9fc4adc
--- /dev/null
+++ b/debian/patches/extension-no-version
@@ -0,0 +1,13 @@
+# Remove "from xxx" from the files so we can better de-duplicate them
+
+--- a/tools/build-extension-update-files.pl
++++ b/tools/build-extension-update-files.pl
+@@ -226,7 +226,7 @@ sub write_script {
+     # write out the header and the commands to clean up the old extension
+     print OUT <<EOF;
+ -- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+--- pgRouting extension upgrade from $o_ver to $n_ver
++-- pgRouting extension upgrade to $n_ver
+ -- generated by tools/build-extension-update-files
+ -- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+ -- remove functions no longer in the $n_ver extension
diff --git a/debian/patches/series b/debian/patches/series
index 1a4adf4..245a393 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
 privacy-breach-uses-embedded-file.patch
+extension-no-version
diff --git a/debian/rules b/debian/rules
index 5790f24..978fe9a 100755
--- a/debian/rules
+++ b/debian/rules
@@ -43,6 +43,8 @@ override_dh_auto_install:
 		sed "s,PGVERSION,$$v,g" < debian/postgresql-pgrouting-doc.doc-base.in > debian/postgresql-$$v-pgrouting-doc/usr/share/doc-base/postgresql-$$v-pgrouting-doc; \
 		mkdir -p debian/postgresql-$$v-pgrouting-scripts/usr; \
 		mv debian/postgresql-$$v-pgrouting/usr/share debian/postgresql-$$v-pgrouting-scripts/usr; \
+		rdfind -makeresultsfile false -makehardlinks true \
+			debian/postgresql-$$v-pgrouting-scripts/usr/share/postgresql/*/extension; \
 	done
 
 override_dh_auto_clean:

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/pgrouting.git



More information about the Pkg-grass-devel mailing list