[llvm] cmake: Avoid using if(TARGET x AND TARGET y) (PR #159707)
Martin Storsjö via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 19 02:32:52 PDT 2025
mstorsjo wrote:
This does indeed fix the build errors - but it doesn't seem to do the right thing; if building with `-DLLVM_NATIVE_TOOL_DIR=<dir>`, we may have preexisting `llvm-nm` and `llc` binaries which we wanted to use; then we can just invoke `${llvm_nm_exe}` right away without needing to build it. So in that way, the current `if (TARGET ${llvm_nm_target})` check makes so that we don't use it at all (and don't build it either) in that case.
So what's the intended purpose of adding these TARGET checks in the first place?
https://github.com/llvm/llvm-project/pull/159707
More information about the llvm-commits
mailing list