[Cmake-commits] CMake branch, next, updated. v2.8.5-1451-gf1c4765
Brad King
brad.king at kitware.com
Mon Aug 8 12:59:39 EDT 2011
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".
The branch, next has been updated
via f1c4765623e9d6d81dbe4bff366011185245e58e (commit)
via ed6be501de960a21fc756d08e9a0a2318f276307 (commit)
from b3b858b07fe64cd1ec97d9dade2f9d8f28bc1144 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=f1c4765623e9d6d81dbe4bff366011185245e58e
commit f1c4765623e9d6d81dbe4bff366011185245e58e
Merge: b3b858b ed6be50
Author: Brad King <brad.king at kitware.com>
AuthorDate: Mon Aug 8 12:59:34 2011 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Mon Aug 8 12:59:34 2011 -0400
Merge topic 'fix-clang-flag-check-issue-12394' into next
ed6be50 Fix CHECK_(C|CXX)_COMPILER_FLAG for Clang (#12394)
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=ed6be501de960a21fc756d08e9a0a2318f276307
commit ed6be501de960a21fc756d08e9a0a2318f276307
Author: Brad King <brad.king at kitware.com>
AuthorDate: Mon Aug 8 12:53:17 2011 -0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Mon Aug 8 12:53:17 2011 -0400
Fix CHECK_(C|CXX)_COMPILER_FLAG for Clang (#12394)
This compiler warns and returns 0 for unrecognized flags. We fix the
compiler flag check macros by looking for a warning in the output.
diff --git a/Modules/CheckCCompilerFlag.cmake b/Modules/CheckCCompilerFlag.cmake
index a390b38..ec0a773 100644
--- a/Modules/CheckCCompilerFlag.cmake
+++ b/Modules/CheckCCompilerFlag.cmake
@@ -30,6 +30,7 @@ MACRO (CHECK_C_COMPILER_FLAG _FLAG _RESULT)
FAIL_REGEX "warning: command line option .* is valid for .* but not for C"
# Apple gcc
FAIL_REGEX "unrecognized .*option" # GNU
+ FAIL_REGEX "unknown .*option" # Clang
FAIL_REGEX "ignoring unknown option" # MSVC
FAIL_REGEX "warning D9002" # MSVC, any lang
FAIL_REGEX "[Uu]nknown option" # HP
diff --git a/Modules/CheckCXXCompilerFlag.cmake b/Modules/CheckCXXCompilerFlag.cmake
index 788bf35..f646e78 100644
--- a/Modules/CheckCXXCompilerFlag.cmake
+++ b/Modules/CheckCXXCompilerFlag.cmake
@@ -28,6 +28,7 @@ MACRO (CHECK_CXX_COMPILER_FLAG _FLAG _RESULT)
CHECK_CXX_SOURCE_COMPILES("int main() { return 0;}" ${_RESULT}
# Some compilers do not fail with a bad flag
FAIL_REGEX "unrecognized .*option" # GNU
+ FAIL_REGEX "unknown .*option" # Clang
FAIL_REGEX "ignoring unknown option" # MSVC
FAIL_REGEX "warning D9002" # MSVC, any lang
FAIL_REGEX "[Uu]nknown option" # HP
-----------------------------------------------------------------------
Summary of changes:
Modules/CheckCCompilerFlag.cmake | 1 +
Modules/CheckCXXCompilerFlag.cmake | 1 +
2 files changed, 2 insertions(+), 0 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list