summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorwbx <wbx@openadk.org>2011-04-08 12:37:48 +0200
committerwbx <wbx@openadk.org>2011-04-08 12:37:48 +0200
commit34fc06736330cc993fd1c936ed9205cdc73aa0fd (patch)
tree42319fe9aa25f82370948335d6dccd571da945d6 /scripts
parent6ea415c59b9ced9d08be7348d268ae4543017a56 (diff)
parent297e4004d154572e29ee71f8ed852b022686e852 (diff)
Merge branch 'master' of git+ssh://openadk.org/git/openadk
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/reloc.sh2
-rw-r--r--scripts/scan-pkgs.sh8
-rwxr-xr-xscripts/sha256sum5
3 files changed, 14 insertions, 1 deletions
diff --git a/scripts/reloc.sh b/scripts/reloc.sh
index 59323612f..03034ea35 100755
--- a/scripts/reloc.sh
+++ b/scripts/reloc.sh
@@ -4,7 +4,7 @@
olddir=$(grep "^TOPDIR" prereq.mk 2>/dev/null |cut -d '=' -f 2)
newdir=$(pwd)
-if [ ! -z $olddir ];then
+if [ ! -z "$olddir" ];then
if [ "$olddir" != "$newdir" ];then
echo "adk directory relocated!"
echo "old directory: $olddir"
diff --git a/scripts/scan-pkgs.sh b/scripts/scan-pkgs.sh
index 36f861d67..2faa334b6 100644
--- a/scripts/scan-pkgs.sh
+++ b/scripts/scan-pkgs.sh
@@ -66,6 +66,7 @@ if [[ -n $ADK_PACKAGE_GPSD ]]; then
fi
if [[ -n $ADK_PACKAGE_FIREFOX ]]; then
+ NEED_YASM="$NEED_YASM firefox"
NEED_LIBIDL="$NEED_LIBIDL firefox"
NEED_PYTHON="$NEED_PYTHON firefox"
fi
@@ -332,6 +333,13 @@ if [[ -n $NEED_FLEX ]]; then
fi
fi
+if [[ -n $NEED_YASM ]]; then
+ if ! which yasm >/dev/null 2>&1; then
+ echo >&2 You need yasm to build $NEED_YASM
+ out=1
+ fi
+fi
+
if [[ -n $NEED_XSLTPROC ]]; then
if ! which xsltproc >/dev/null 2>&1; then
echo >&2 You need xsltproc to build $NEED_XSLTPROC
diff --git a/scripts/sha256sum b/scripts/sha256sum
index da34d9113..2a7ffb6f7 100755
--- a/scripts/sha256sum
+++ b/scripts/sha256sum
@@ -4,6 +4,11 @@
if [ -x /usr/bin/sha256sum ]; then
/usr/bin/sha256sum "$@"
+elif [ -x /bin/cksum ] && [ $(echo | cksum -a sha256) = 01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b ]; then
+ # we assume the arguments are exactly "-c" or "-c -"
+ x=$(sed 's/^\([0-9a-fA-F]*\) *\([^ ].*\)$/SHA256 (\2) = \1/' | cksum -c -a sha256)
+ [[ $x = *FAILED* ]] && exit 1
+ exit 0
else
tmp=$(mktemp -t yyy)
cat - > $tmp