From 1b461374264abd62c54133e544dedd5feb866043 Mon Sep 17 00:00:00 2001 From: Allan McRae Date: Thu, 22 Dec 2011 16:51:22 +1000 Subject: makepkg: Use SKIP in checksum to skip integrity check Using the value of "SKIP" in the checksum array will cause that integrity check to be skipped. This makes building packages that rely on user configurable sources less painful. Based-on-patch-by: Dan McGee Based-on-patch-by: David Campbell Signed-off-by: Allan McRae Signed-off-by: Dan McGee --- scripts/makepkg.sh.in | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) (limited to 'scripts') diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index a4a3d13d..64b33c68 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -663,14 +663,18 @@ check_checksums() { fi if (( $found )) ; then - local expectedsum=$(tr '[:upper:]' '[:lower:]' <<< "${integrity_sums[$idx]}") - local realsum="$(openssl dgst -${integ} "$file")" - realsum="${realsum##* }" - if [[ $expectedsum = $realsum ]]; then - echo "$(gettext "Passed")" >&2 + if [[ ${integrity_sums[$idx]} = 'SKIP' ]]; then + echo "$(gettext "Skipped")" >&2 else - echo "$(gettext "FAILED")" >&2 - errors=1 + local expectedsum=$(tr '[:upper:]' '[:lower:]' <<< "${integrity_sums[$idx]}") + local realsum="$(openssl dgst -${integ} "$file")" + realsum="${realsum##* }" + if [[ $expectedsum = $realsum ]]; then + echo "$(gettext "Passed")" >&2 + else + echo "$(gettext "FAILED")" >&2 + errors=1 + fi fi fi -- cgit v1.2.3-70-g09d2