[bazel] Respect llvm_target_list in llvm-exegesis
- 47afaf2e changed llvm-exegesis cmake rules - 5b2f838d ported them to bazel, but did so by adding all the `lib/{target}/*.cpp` sources in exegesis to the build rule - c7bf9d08 removed it, because it breaks users who don't build Mips and fail when building `lib/Mips/*.cpp`. But that in turn breaks those who *do* build the Mips target. This should hopefully fix it for the final time by using selectively build subdirectories of exegesis target libs using llvm_target_exegesis, which is derived from llvm_targets, and is the list that can vary based on the downstream user. I verified this builds with and without `Mips` in the `DEFAULT_TARGETS` configure list, and also double checked with `bazel query --output=build @llvm-project//llvm:Exegesis` that `lib/Mips/Target.cpp` is being included if and only if `Mips` is in the target list. Reviewed By: aeubanks Differential Revision: https://reviews.llvm.org/D134512
Loading
Please sign in to comment