From dd16896324f14ff1059d6e7781ce673e88ebcf7d Mon Sep 17 00:00:00 2001 From: Reid Kleckner Date: Thu, 8 Sep 2016 16:25:34 +0000 Subject: [PATCH] Really fix warnings about passing -std=gnu99 to MSVC llvm-svn: 280958 --- compiler-rt/cmake/Modules/BuiltinTests.cmake | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/compiler-rt/cmake/Modules/BuiltinTests.cmake b/compiler-rt/cmake/Modules/BuiltinTests.cmake index 5f3cc7e5..a6bf864 100644 --- a/compiler-rt/cmake/Modules/BuiltinTests.cmake +++ b/compiler-rt/cmake/Modules/BuiltinTests.cmake @@ -50,12 +50,13 @@ function(try_compile_only output) ) CHECK_COMPILER_FLAG_COMMON_PATTERNS(_CheckCCompilerFlag_COMMON_PATTERNS) + set(ERRORS_FOUND OFF) foreach(var ${_CheckCCompilerFlag_COMMON_PATTERNS}) if("${var}" STREQUAL "FAIL_REGEX") continue() endif() - if("${var}" MATCHES "${_CheckCCompilerFlag_COMMON_PATTERNS}") - set(ERRORS_FOUND True) + if("${TEST_ERROR}" MATCHES "${var}" OR "${TEST_OUTPUT}" MATCHES "${var}") + set(ERRORS_FOUND ON) endif() endforeach() -- 2.7.4