curl-compilers.m4: escape square brackets in regex
authorMarcel Raad <raad@teamviewer.com>
Thu, 1 Jun 2017 15:46:32 +0000 (17:46 +0200)
committerMarcel Raad <raad@teamviewer.com>
Thu, 1 Jun 2017 15:47:37 +0000 (17:47 +0200)
Otherwise, they are removed in the final configure file.
Also changed sed to "$SED" like in most other calls in this file.

m4/curl-compilers.m4

index dcca88493fcf2cf1c878967a60e7652c452fe580..88e9d67ba2b5da05745174af26e3abc7267e7b72 100644 (file)
@@ -84,7 +84,7 @@ AC_DEFUN([CURL_CHECK_COMPILER_CLANG], [
   if test "$curl_cv_have_def___clang__" = "yes"; then
     AC_MSG_RESULT([yes])
     compiler_id="CLANG"
-    clangver=`$CC -v 2>&1 | grep version | sed "s/.*version \([0-9]*\.[0-9]*\).*/\1/"`
+    clangver=`$CC -v 2>&1 | grep version | "$SED" 's/.*version \(@<:@0-9@:>@*\.@<:@0-9@:>@*\).*/\1/'`
     clangvhi=`echo $clangver | cut -d . -f1`
     clangvlo=`echo $clangver | cut -d . -f2`
     compiler_num=`(expr $clangvhi "*" 100 + $clangvlo) 2>/dev/null`