From a9474d1260a8c8cc9eae14f2984098919d9684e5 Mon Sep 17 00:00:00 2001 From: Raphael Kubo da Costa Date: Tue, 23 Aug 2016 20:25:14 +0200 Subject: [PATCH] configure: Correctly detect clang's version on FreeBSD "clang -v" on FreeBSD reports something like "FreeBSD clang version x.y.z [...]" instead of just "clang version x.y.z [...]", which fails to match the sed pattern in the configure script, resulting in qconfig.pri having no clang version defined. Augment the pattern so that both version strings match. Change-Id: I5f38f8480f4b1156ca7147e32c1157a009557035 Reviewed-by: Thiago Macieira --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index f4c7813fd04..e590da9514e 100755 --- a/configure +++ b/configure @@ -6697,7 +6697,7 @@ case "$QMAKE_CONF_COMPILER" in # Clang COMPILER_VERSION=`${QMAKE_CONF_COMPILER} -v 2>&1 | sed -n -E ' /^Apple (clang|LLVM) version /{s///; s/^([0-9]*)\.([0-9]*).*$/QT_APPLE_CLANG_MAJOR_VERSION=\1; QT_APPLE_CLANG_MINOR_VERSION=\2/;p;q;} -/^clang version /{s///; s/^([0-9]*)\.([0-9]*).*$/QT_CLANG_MAJOR_VERSION=\1; QT_CLANG_MINOR_VERSION=\2/;p;q;}'` +/^(FreeBSD )?clang version /{s///; s/^([0-9]*)\.([0-9]*).*$/QT_CLANG_MAJOR_VERSION=\1; QT_CLANG_MINOR_VERSION=\2/;p;q;}'` eval "$COMPILER_VERSION" ;; *icpc)