diff options
author | Brad King <brad.king@kitware.com> | 2009-09-17 21:16:43 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2009-09-17 21:16:43 (GMT) |
commit | 53fb07ef5d94398223f0abcf8d6bc5d8785ac075 (patch) | |
tree | 08c4bd3576fffb9cb820fa2068a39394937f149a /Modules/CheckCXXCompilerFlag.cmake | |
parent | 6362d4c7439edfc7340acf53207ef759c1e2aeb1 (diff) | |
download | CMake-53fb07ef5d94398223f0abcf8d6bc5d8785ac075.zip CMake-53fb07ef5d94398223f0abcf8d6bc5d8785ac075.tar.gz CMake-53fb07ef5d94398223f0abcf8d6bc5d8785ac075.tar.bz2 |
Fix CHECK_(C|CXX)_COMPILER_FLAG for HP
This compiler warns and returns 0 for unrecognized flags. We fix the
compiler flag check macros by looking for a warning in the output.
See issue #9516.
Diffstat (limited to 'Modules/CheckCXXCompilerFlag.cmake')
-rw-r--r-- | Modules/CheckCXXCompilerFlag.cmake | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Modules/CheckCXXCompilerFlag.cmake b/Modules/CheckCXXCompilerFlag.cmake index e883282..018eacd 100644 --- a/Modules/CheckCXXCompilerFlag.cmake +++ b/Modules/CheckCXXCompilerFlag.cmake @@ -21,6 +21,7 @@ MACRO (CHECK_CXX_COMPILER_FLAG _FLAG _RESULT) # Some compilers do not fail with a bad flag FAIL_REGEX "unrecognized option" # GNU FAIL_REGEX "ignoring unknown option" # MSVC + FAIL_REGEX "[Uu]nknown option" # HP ) SET (CMAKE_REQUIRED_DEFINITIONS "${SAFE_CMAKE_REQUIRED_DEFINITIONS}") ENDMACRO (CHECK_CXX_COMPILER_FLAG) |