[compiler-rt] r236505 - Disable exceptions with Clang on Windows in lib/sanitizer-common/tests

Reid Kleckner reid at kleckner.net
Tue May 5 09:52:50 PDT 2015


Author: rnk
Date: Tue May  5 11:52:50 2015
New Revision: 236505

URL: http://llvm.org/viewvc/llvm-project?rev=236505&view=rev
Log:
Disable exceptions with Clang on Windows in lib/sanitizer-common/tests

While I'm here, fix a copy-paste bug so we get debug info for these
tests.

Modified:
    compiler-rt/trunk/lib/sanitizer_common/tests/CMakeLists.txt

Modified: compiler-rt/trunk/lib/sanitizer_common/tests/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/sanitizer_common/tests/CMakeLists.txt?rev=236505&r1=236504&r2=236505&view=diff
==============================================================================
--- compiler-rt/trunk/lib/sanitizer_common/tests/CMakeLists.txt (original)
+++ compiler-rt/trunk/lib/sanitizer_common/tests/CMakeLists.txt Tue May  5 11:52:50 2015
@@ -51,11 +51,16 @@ set(SANITIZER_TEST_CFLAGS_COMMON
   -Werror=sign-compare
   -Wno-non-virtual-dtor)
 
+if(MSVC)
+  # Disable exceptions on Windows until they work reliably.
+  list(APPEND SANITIZER_TEST_CFLAGS_COMMON -fno-exceptions -DGTEST_HAS_SEH=0)
+endif()
+
 # -gline-tables-only must be enough for these tests, so use it if possible.
 if(COMPILER_RT_TEST_COMPILER_ID MATCHES "Clang")
-  list(APPEND ASAN_UNITTEST_COMMON_CFLAGS -gline-tables-only)
+  list(APPEND SANITIZER_TEST_CFLAGS_COMMON -gline-tables-only)
 else()
-  list(APPEND ASAN_UNITTEST_COMMON_CFLAGS -g)
+  list(APPEND SANITIZER_TEST_CFLAGS_COMMON -g)
 endif()
 
 if(NOT MSVC)





More information about the llvm-commits mailing list