From: Stefano Stabellini Date: Tue, 7 Apr 2015 10:30:06 +0000 (+0000) Subject: Add BASH version compatibility check X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=009302142289a5ce8fface72dea0485324a21fc0;p=raisin.git Add BASH version compatibility check Require BASH 3.2 or newer. Signed-off-by: Stefano Stabellini --- diff --git a/common-functions.sh b/common-functions.sh index cec1636..5b9c163 100644 --- a/common-functions.sh +++ b/common-functions.sh @@ -22,6 +22,13 @@ function common_init() { exit 1 fi + if test -z "$BASH_VERSINFO" || test ${BASH_VERSINFO[0]} -lt 3 || + (test ${BASH_VERSINFO[0]} -eq 3 && test ${BASH_VERSINFO[1]} -lt 2) + then + echo "Raisin requires BASH 3.2 or newer." + exit 1 + fi + get_distro get_arch