Use ${CKSUM} rather than cksum if the former's defined.

This commit is contained in:
bjh21 2002-03-31 15:17:58 +00:00
parent c3e2abe891
commit fdfbb66f3a

View File

@ -1,6 +1,6 @@
#!/bin/sh
#
# $NetBSD: makesums,v 1.2 2000/08/20 08:29:59 toddpw Exp $
# $NetBSD: makesums,v 1.3 2002/03/31 15:17:58 bjh21 Exp $
#
# Make checksum files for files in ``tardir''. Usage:
# makesums [-t tardir] [ -all ] [setname ...]
@ -18,6 +18,7 @@
#
# set defaults
: ${CKSUM=cksum}
: ${MAKE=make} # XXX: what purpose does this serve??
tars=$RELEASEDIR
dash_all=no
@ -62,8 +63,8 @@ elif [ -z "$pat" ]; then
fi
lists=`find $pat -prune -type f \! -name '*SUM' \! -name MD5 2>/dev/null`
if [ -n "$lists" ]; then
cksum -o1 $lists > BSDSUM
cksum $lists > CKSUM
cksum -m $lists > MD5
cksum -o2 $lists > SYSVSUM
${CKSUM} -o1 $lists > BSDSUM
${CKSUM} $lists > CKSUM
${CKSUM} -m $lists > MD5
${CKSUM} -o2 $lists > SYSVSUM
fi