[PATCH] D95750: [CMake] [MinGW] Enable use of LLVM_USE_SANITIZER in a MinGW environment

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 8 12:49:56 PST 2021


rnk accepted this revision.
rnk added a comment.
This revision is now accepted and ready to land.

lgtm



================
Comment at: llvm/cmake/modules/HandleLLVMOptions.cmake:803-804
+      append("${LLVM_UBSAN_FLAGS}" CMAKE_C_FLAGS CMAKE_CXX_FLAGS)
+    elseif (LLVM_USE_SANITIZER STREQUAL "Address;Undefined" OR
+            LLVM_USE_SANITIZER STREQUAL "Undefined;Address")
+      append_common_sanitizer_flags()
----------------
Well, I guess there is prior art for this tortured conditional.


================
Comment at: llvm/cmake/modules/HandleLLVMOptions.cmake:811
+    endif()
   elseif(MSVC)
     if (LLVM_USE_SANITIZER STREQUAL "Address")
----------------
MSVC should probably get the same treatment, but that doesn't need to be part of this change.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D95750/new/

https://reviews.llvm.org/D95750



More information about the llvm-commits mailing list