make sure FileCheck is copied in the LLVM output directory

The tool, which is needed by parts of our test suite, is built as part
of LLVM but is *not* copied to the directory containing the output LLVM
binaries. This adds a flag to ensure the binary is copied.

This shouldn't add any extra built time, as the flag just installs extra
binaries that were already compiled.
This commit is contained in:
Pietro Albini 2021-08-26 16:47:42 +02:00
parent 20997f6ad8
commit 9df630707e
No known key found for this signature in database
GPG key ID: CD76B35F7734769E

View file

@ -189,6 +189,11 @@ impl Step for Llvm {
.define("LLVM_TARGET_ARCH", target_native.split('-').next().unwrap())
.define("LLVM_DEFAULT_TARGET_TRIPLE", target_native);
// Parts of our test suite rely on the `FileCheck` tool, which is built by default in
// `build/$TARGET/llvm/build/bin` is but *not* then installed to `build/$TARGET/llvm/bin`.
// This flag makes sure `FileCheck` is copied in the final binaries directory.
cfg.define("LLVM_INSTALL_UTILS", "ON");
if builder.config.llvm_profile_generate {
cfg.define("LLVM_BUILD_INSTRUMENTED", "IR");
cfg.define("LLVM_BUILD_RUNTIME", "No");