summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz@archlinux.org>2019-02-15 11:38:18 -0500
committerAllan McRae <allan@archlinux.org>2019-03-07 11:12:12 +1000
commite03752e6adc86cbb4cb4f52a38f6e3e98cbe9dd5 (patch)
treeb54915aa614c31b29f0df1c93b353ef582e3b457 /scripts
parent0113214db9a9e9ae48bffa3c3e7b39be16e8272a (diff)
downloadpacman-e03752e6adc86cbb4cb4f52a38f6e3e98cbe9dd5.tar.xz
makepkg: add new checksum algorithm via coreutils b2sum
coreutils 8.26 in December 2016 added this new hashing method which is compatible with the existing md5sum and sha*sum tool usage, while using the blake2 hash algorithm. makepkg uses coreutils to provide source file integrity checks via ${integ}sum binaries and it makes sense to offer this as an additional option. Signed-off-by: Eli Schwartz <eschwartz@archlinux.org> Signed-off-by: Allan McRae <allan@archlinux.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/libmakepkg/util/schema.sh.in2
-rw-r--r--scripts/makepkg.sh.in2
2 files changed, 2 insertions, 2 deletions
diff --git a/scripts/libmakepkg/util/schema.sh.in b/scripts/libmakepkg/util/schema.sh.in
index 38f034e0..a611d221 100644
--- a/scripts/libmakepkg/util/schema.sh.in
+++ b/scripts/libmakepkg/util/schema.sh.in
@@ -26,7 +26,7 @@ LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$LIBRARY/util/util.sh"
-known_hash_algos=({md5,sha{1,224,256,384,512}})
+known_hash_algos=({md5,sha{1,224,256,384,512},b2})
pkgbuild_schema_arrays=(arch backup checkdepends conflicts depends groups
license makedepends noextract optdepends options
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
index bca71c70..e12826af 100644
--- a/scripts/makepkg.sh.in
+++ b/scripts/makepkg.sh.in
@@ -1217,7 +1217,7 @@ unset sha{1,224,256,384,512}sums makedepends optdepends options noextract validp
unset "${!makedepends_@}" "${!depends_@}" "${!source_@}" "${!checkdepends_@}"
unset "${!optdepends_@}" "${!conflicts_@}" "${!provides_@}" "${!replaces_@}"
unset "${!md5sums_@}" "${!sha1sums_@}" "${!sha224sums_@}" "${!sha256sums_@}"
-unset "${!sha384sums_@}" "${!sha512sums_@}"
+unset "${!sha384sums_@}" "${!sha512sums_@}" "${!b2sums_@}"
BUILDFILE=${BUILDFILE:-$BUILDSCRIPT}
if [[ ! -f $BUILDFILE ]]; then