summaryrefslogtreecommitdiff
path: root/coreconf
diff options
context:
space:
mode:
authorFranziskus Kiefer <franziskuskiefer@gmail.com>2017-01-24 12:15:13 +0100
committerFranziskus Kiefer <franziskuskiefer@gmail.com>2017-01-24 12:15:13 +0100
commit13ad7bf3e9d9cee84c63495fa3478cb73adbfa8d (patch)
tree6ce031775876b5cf360dbf22c98546dd159abf02 /coreconf
parent42ada19f890a396199dc515cab2531802f6e8b6f (diff)
downloadnss-hg-13ad7bf3e9d9cee84c63495fa3478cb73adbfa8d.tar.gz
Bug 1177759 - make clang version detection robust for higher versions, r=ttaubert
Differential Revision: https://nss-review.dev.mozaws.net/D171
Diffstat (limited to 'coreconf')
-rw-r--r--coreconf/sanitizers.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/coreconf/sanitizers.sh b/coreconf/sanitizers.sh
index 6315a1e86..cbfb566d2 100644
--- a/coreconf/sanitizers.sh
+++ b/coreconf/sanitizers.sh
@@ -21,8 +21,8 @@ enable_sanitizer()
enable_sancov()
{
- local clang_version=$($CC --version | grep -oE 'clang version (3\.9\.|4\.)')
- if [ -z "$clang_version" ]; then
+ local clang_version=$($CC --version | grep -oE '([0-9]{1,}\.)+[0-9]{1,}')
+ if [[ ${clang_version:0:1} -lt 4 && ${clang_version:0:1} -eq 3 && ${clang_version:2:1} -lt 9 ]]; then
echo "Need at least clang-3.9 (better 4.0) for sancov." 1>&2
exit 1
fi