Identify run-make tests by mode name instead of suite name

This commit is contained in:
Zalathar 2024-06-07 16:33:35 +10:00
parent 6c4755dcb7
commit b8e734a8ca

View File

@ -1973,9 +1973,7 @@ NOTE: if you're sure you want to do this, please open an issue as to why. In the
add_link_lib_path(vec![llvm_libdir.trim().into()], &mut cmd); add_link_lib_path(vec![llvm_libdir.trim().into()], &mut cmd);
} }
if !builder.config.dry_run() if !builder.config.dry_run() && matches!(mode, "run-make" | "coverage-run") {
&& (matches!(suite, "run-make" | "run-make-fulldeps") || mode == "coverage-run")
{
// The llvm/bin directory contains many useful cross-platform // The llvm/bin directory contains many useful cross-platform
// tools. Pass the path to run-make tests so they can use them. // tools. Pass the path to run-make tests so they can use them.
// (The coverage-run tests also need these tools to process // (The coverage-run tests also need these tools to process
@ -1987,7 +1985,7 @@ NOTE: if you're sure you want to do this, please open an issue as to why. In the
cmd.arg("--llvm-bin-dir").arg(llvm_bin_path); cmd.arg("--llvm-bin-dir").arg(llvm_bin_path);
} }
if !builder.config.dry_run() && matches!(suite, "run-make" | "run-make-fulldeps") { if !builder.config.dry_run() && mode == "run-make" {
// If LLD is available, add it to the PATH // If LLD is available, add it to the PATH
if builder.config.lld_enabled { if builder.config.lld_enabled {
let lld_install_root = let lld_install_root =
@ -2007,7 +2005,7 @@ NOTE: if you're sure you want to do this, please open an issue as to why. In the
// Only pass correct values for these flags for the `run-make` suite as it // Only pass correct values for these flags for the `run-make` suite as it
// requires that a C++ compiler was configured which isn't always the case. // requires that a C++ compiler was configured which isn't always the case.
if !builder.config.dry_run() && matches!(suite, "run-make" | "run-make-fulldeps") { if !builder.config.dry_run() && mode == "run-make" {
cmd.arg("--cc") cmd.arg("--cc")
.arg(builder.cc(target)) .arg(builder.cc(target))
.arg("--cxx") .arg("--cxx")