1
0
mirror of https://github.com/moparisthebest/pacman synced 2024-08-13 17:03:46 -04:00

repo-add: Use openssl instead of md5sum

This is similar to the change we made in makepkg so it is cross-platform
compatible and doesn't require coreutils.

Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
Dan McGee 2008-10-18 21:27:00 -05:00
parent d1fec15d81
commit 50e3dc02bf

View File

@ -121,7 +121,7 @@ db_write_delta()
arch=${deltavars[3]}
# get md5sum and size of delta
md5sum="$(md5sum "$deltafile" | cut -d ' ' -f 1)"
md5sum="$(openssl dgst -md5 "$deltafile" | awk '{print $NF}')"
csize=$(@SIZECMD@ "$deltafile")
# ensure variables were found
@ -201,7 +201,7 @@ db_write_entry()
# compute checksums
msg2 "$(gettext "Computing md5 checksums...")"
echo -e "%MD5SUM%\n$(md5sum "$pkgfile" | cut -d ' ' -f 1)\n" >>desc
echo -e "%MD5SUM%\n$(openssl dgst -md5 "$pkgfile" | awk '{print $NF}')\n" >>desc
[ -n "$url" ] && echo -e "%URL%\n$url\n" >>desc
write_list_entry "LICENSE" "$_licenses" "desc"