download.pl: fix openssl sha256 digest output
authornbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Sat, 16 Jan 2016 10:24:15 +0000 (10:24 +0000)
committernbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Sat, 16 Jan 2016 10:24:15 +0000 (10:24 +0000)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@48259 3c298f89-4303-0410-b956-a3cf2f4a3e73

scripts/download.pl

index 3b8b267..9d1fe47 100755 (executable)
@@ -63,7 +63,7 @@ sub hash_cmd() {
        my $len = length($file_hash);
        my $cmd;
 
-       $len == 64 and return "openssl dgst -sha256";
+       $len == 64 and return "openssl dgst -sha256 | sed -e 's,.*= ,,'";
        $len == 32 and do {
                my $cmd = which("md5sum") || which("md5") || die 'no md5 checksum program found, please install md5 or md5sum';
                chomp $cmd;