From b2e2e324ac3fef09658671ffd76c7f58492698ea Mon Sep 17 00:00:00 2001 From: Drew Fisher Date: Mon, 19 Aug 2013 19:00:24 -0700 Subject: dpkg: use homebrew gtar and OSX md5, shasum - The formula claims to depend on homebrew's gnu-tar package, but then uses OSX's bundled gnutar, rather than homebrew's gnutar. On older OSX machines, this breaks, as dpkg 1.17 depends on tar >= 1.23, see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=642802 - dpkg-scanpackages fails, since md5sum, sha1sum, and sha256sum don't exist. So replace the invocations with OSX's md5 and shasum tools. Signed-Off-By: Drew Fisher Closes #22019. Signed-off-by: Adam Vandenberg --- Library/Formula/dpkg.rb | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) (limited to 'Library') diff --git a/Library/Formula/dpkg.rb b/Library/Formula/dpkg.rb index 9f99f322b..3a7b535e9 100644 --- a/Library/Formula/dpkg.rb +++ b/Library/Formula/dpkg.rb @@ -60,7 +60,7 @@ index c0f633d..b692806 100644 #define DEBSIGVERIFY "/usr/bin/debsig-verify" -#define TAR "tar" -+#define TAR "gnutar" ++#define TAR "gtar" #define RM "rm" #define CAT "cat" #define FIND "find" @@ -90,3 +90,27 @@ index 754488e..8b233fb 100644 -e "s:\$$CONFDIR[[:space:]]*=[[:space:]]*['\"][^'\"]*['\"]:\$$CONFDIR='$(pkgconfdir)':" \ -e "s:\$$ADMINDIR[[:space:]]*=[[:space:]]*['\"][^'\"]*['\"]:\$$ADMINDIR='$(admindir)':" \ -e "s:\$$LIBDIR[[:space:]]*=[[:space:]]*['\"][^'\"]*['\"]:\$$LIBDIR='$(pkglibdir)':" \ + +diff --git a/scripts/Dpkg/Checksums.pm b/scripts/Dpkg/Checksums.pm +index 4a64fd1..bb19f59 100644 +--- a/scripts/Dpkg/Checksums.pm ++++ b/scripts/Dpkg/Checksums.pm +@@ -50,15 +50,15 @@ about supported checksums. + + my $CHECKSUMS = { + md5 => { +- program => [ 'md5sum' ], ++ program => [ 'md5', '-q' ], + regex => qr/[0-9a-f]{32}/, + }, + sha1 => { +- program => [ 'sha1sum' ], ++ program => [ 'shasum', '-a', '1' ], + regex => qr/[0-9a-f]{40}/, + }, + sha256 => { +- program => [ 'sha256sum' ], ++ program => [ 'shasum', '-a', '256' ], + regex => qr/[0-9a-f]{64}/, + }, + }; -- cgit v1.2.3