[NFC] Don't run clang/bindings/python/tests with msan
authorVitaly Buka <vitalybuka@google.com>
Fri, 30 Oct 2020 01:13:23 +0000 (18:13 -0700)
committerVitaly Buka <vitalybuka@google.com>
Fri, 30 Oct 2020 05:29:25 +0000 (22:29 -0700)
Fixes check-all with LLVM_USE_SANITIZER=Memory

clang/bindings/python/tests/CMakeLists.txt

index 3f58c4b..46dafa5 100644 (file)
@@ -15,14 +15,13 @@ if(NOT LLVM_ENABLE_PIC)
   set(RUN_PYTHON_TESTS FALSE)
 endif()
 
-# Do not try to run if libclang was built with ASan because
+# Do not try to run if libclang was built with ASan/MSan because
 # the sanitizer library will likely be loaded too late to perform
 # interception and will then fail.
 # We could use LD_PRELOAD/DYLD_INSERT_LIBRARIES but this isn't
 # portable so its easier just to not run the tests when building
 # with ASan.
-list(FIND LLVM_USE_SANITIZER "Address" LLVM_USE_ASAN_INDEX)
-if(NOT LLVM_USE_ASAN_INDEX EQUAL -1)
+if(LLVM_USE_SANITIZER MATCHES ".*(Memory|Address).*")
   set(RUN_PYTHON_TESTS FALSE)
 endif()