[waffle] [PATCH] cmake: Fix test for thread-local storage
Chad Versace
chad.versace at linux.intel.com
Tue Aug 20 13:08:24 PDT 2013
Commit 6fcbe52 "cmake: Refactor compiler flags into new module" exposed a bug
in the test for thread-local storage, causing the test to always fail. If the
regex "warning|error" appears in the compiler log, then the test fails. This
causes false failures when the test invokes the compiler with
'-Werror=missing-prototypes'.
Fix the regex to more closely match gcc and clang error messages.
Reported-by: Paul Berry <stereotype441 at gmail.com>
Signed-off-by: Chad Versace <chad.versace at linux.intel.com>
---
cmake/Modules/WaffleCheckThreadLocalStorage.cmake | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/cmake/Modules/WaffleCheckThreadLocalStorage.cmake b/cmake/Modules/WaffleCheckThreadLocalStorage.cmake
index c8bc3fe..f988f6f 100644
--- a/cmake/Modules/WaffleCheckThreadLocalStorage.cmake
+++ b/cmake/Modules/WaffleCheckThreadLocalStorage.cmake
@@ -61,7 +61,7 @@ macro(waffle_check_thread_local_storage)
waffle_has_tls
- FAIL_REGEX "warning|error"
+ FAIL_REGEX "warning: |error: "
)
check_c_source_compiles(
@@ -77,6 +77,6 @@ macro(waffle_check_thread_local_storage)
waffle_has_tls_model_initial_exec
- FAIL_REGEX "warning|error"
+ FAIL_REGEX "warning: |error: "
)
endmacro()
--
1.8.3.1
More information about the waffle
mailing list