Use case..esac instead of [[.
Not all /bin/sh have [[ available, so for compatibility using case..esac for pattern matching is better.
This commit is contained in:
parent
a33b808ac0
commit
bc85eb49f5
|
@ -977,8 +977,8 @@ fi
|
||||||
|
|
||||||
if [ ! -z "$CFG_ENABLE_CLANG" ]
|
if [ ! -z "$CFG_ENABLE_CLANG" ]
|
||||||
then
|
then
|
||||||
if [ -z "$CC" ] || [[ $CC == *clang ]]
|
case "$CC" in
|
||||||
then
|
(''|*clang)
|
||||||
CFG_CLANG_VERSION=$($CFG_CC \
|
CFG_CLANG_VERSION=$($CFG_CC \
|
||||||
--version \
|
--version \
|
||||||
| grep version \
|
| grep version \
|
||||||
|
@ -998,9 +998,11 @@ then
|
||||||
err "bad CLANG version: $CFG_CLANG_VERSION, need >=3.0svn"
|
err "bad CLANG version: $CFG_CLANG_VERSION, need >=3.0svn"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
else
|
;;
|
||||||
|
(*)
|
||||||
msg "skipping CFG_ENABLE_CLANG version check; provided CC=$CC"
|
msg "skipping CFG_ENABLE_CLANG version check; provided CC=$CC"
|
||||||
fi
|
;;
|
||||||
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -z "$CFG_ENABLE_CCACHE" ]
|
if [ ! -z "$CFG_ENABLE_CCACHE" ]
|
||||||
|
|
Loading…
Reference in New Issue