[compiler-rt] [test] Don't check COMPILER_RT_STANDALONE_BUILD for deps (PR #66259)

Shoaib Meenai via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 19 15:26:20 PDT 2023


smeenai wrote:

This change exposed a bug, where e.g. https://github.com/llvm/llvm-project/blob/6af26745974e9d14765d7e961be6af45b9ccd978/compiler-rt/test/lsan/CMakeLists.txt#L47 is checking `COMPILER_RT_HAS_HWASAN` to decide whether to add `hwasan` as a dependency. However, `COMPILER_RT_HAS_HWASAN` only says whether the current OS and architecture supports hwasan, not whether it's actually being built (which is determined by `COMPILER_RT_SANITIZERS_TO_BUILD`. Consequently, even if you're not building hwasan, you try to add a dependency on it, and the build fails cos the target doesn't exist. How would you suggest fixing that?

https://github.com/llvm/llvm-project/pull/66259


More information about the llvm-commits mailing list