summaryrefslogtreecommitdiff
path: root/app-arch/dpkg/files/dpkg-1.18.12-rsyncable.patch
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /app-arch/dpkg/files/dpkg-1.18.12-rsyncable.patch
reinit the tree, so we can have metadata
Diffstat (limited to 'app-arch/dpkg/files/dpkg-1.18.12-rsyncable.patch')
-rw-r--r--app-arch/dpkg/files/dpkg-1.18.12-rsyncable.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/app-arch/dpkg/files/dpkg-1.18.12-rsyncable.patch b/app-arch/dpkg/files/dpkg-1.18.12-rsyncable.patch
new file mode 100644
index 000000000000..69802da67092
--- /dev/null
+++ b/app-arch/dpkg/files/dpkg-1.18.12-rsyncable.patch
@@ -0,0 +1,28 @@
+--- a/scripts/Dpkg/Compression.pm
++++ b/scripts/Dpkg/Compression.pm
+@@ -81,20 +81,12 @@
+ };
+
+ #
+-# XXX: The gzip package in Debian at some point acquired a Debian-specific
+-# --rsyncable option via a vendor patch. Which is not present in most of the
+-# major distributions, dpkg downstream systems, nor gzip upstream, who have
+-# stated they will most probably not accept it because people should be using
+-# pigz instead.
++# If gzip supports --rsyncable (version >=1.7 or the Debian patched variant),
++# we use it. Sadly a non-compliant gzip will not complain about the argument
++# when it does not understand it, so we can only print out the usage and infer
++# --rsyncable support from that.
+ #
+-# This option should have never been accepted in dpkg, ever. But removing it
+-# now would probably cause demands for tarring and feathering. In addition
+-# we cannot use the Dpkg::Vendor logic because that would cause circular
+-# module dependencies. The whole affair is pretty disgusting really.
+-#
+-# Check the perl Config to discern Debian and hopefully derivatives too.
+-#
+-if ($Config{cf_by} eq 'Debian Project') {
++if (system("gzip --help 2>&1 | grep -q -- --rsyncable") == 0) {
+ push @{$COMP->{gzip}->{comp_prog}}, '--rsyncable';
+ }
+