From: Sami Kerola Date: Sun, 18 Mar 2012 20:34:09 +0000 (+0100) Subject: tools: checkconfig.sh: make scripts bourne sh compliant [checkbashisms] X-Git-Tag: v2.22-rc1~571 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8b32e57f290c63685e1325e70006e7a8ba62add2;p=thirdparty%2Futil-linux.git tools: checkconfig.sh: make scripts bourne sh compliant [checkbashisms] script checkconfig.sh does not appear to be a /bin/sh script possible bashism in checkconfig.sh line 14 ('function' is useless): function die() { possible bashism in checkconfig.sh line 27 ('((' should be '$(('): while (( "$#" )); do Signed-off-by: Sami Kerola --- diff --git a/tools/checkconfig.sh b/tools/checkconfig.sh index 984e72bea2..91f7b1c05c 100755 --- a/tools/checkconfig.sh +++ b/tools/checkconfig.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/sh # # This script checks for HAVE_ and ENABLE_ macros which are @@ -11,7 +11,7 @@ # -function die() { +die() { echo "error: $1" exit 1 } @@ -24,7 +24,7 @@ config="$srcdir/config.h.in" shift -while (( "$#" )); do +while [ "$#" -ne 0 ]; do srcfile=$1 shift