summaryrefslogtreecommitdiff
path: root/autogen.sh
diff options
context:
space:
mode:
authorEvgeny Vereshchagin <evvers@ya.ru>2016-10-26 02:39:48 +0300
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2016-10-25 19:39:48 -0400
commit2b7466a22b897c7c30550f3572fbdd7bc77554ec (patch)
tree9d7b9b18e30bef5cef52b1cdf370b58009daec36 /autogen.sh
parent803467c46dd409bef0280f37a4c1555f7b997b5c (diff)
build-sys/autogen: don't use bashisms (#4489)
Fixes: $ ls -l /bin/sh lrwxrwxrwx 1 root root 4 Feb 17 2016 /bin/sh -> dash $ ./autogen.sh c ./autogen.sh: 22: ./autogen.sh: [[: not found ... checking whether make supports nested variables... (cached) yes checking build system type... Invalid configuration `c': machine `c' not recognized configure: error: /bin/bash build-aux/config.sub c failed this is a follow-up for a5e739a570081231
Diffstat (limited to 'autogen.sh')
-rwxr-xr-xautogen.sh12
1 files changed, 5 insertions, 7 deletions
diff --git a/autogen.sh b/autogen.sh
index fa8d2916ad..1897e23b53 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -19,13 +19,11 @@ set -e
verb="$1"
-if [[ -n "$verb" ]]; then
- if [[ "$verb" != [cgals] ]]; then
- echo "Unexpected argument: $verb" >&2
- exit 1
- fi
- shift
-fi
+case "$verb" in
+"") ;;
+[cgals]) shift ;;
+*) echo "Unexpected argument: $verb" >&2; exit 1 ;;
+esac
oldpwd=$(pwd)
topdir=$(dirname $0)