let target = target.as_ref().unwrap_or(host);
// We always setup.
- setup(&subcommand, target, &rustc_version);
+ setup(&subcommand, target, &rustc_version, verbose);
// Invoke actual cargo for the job, but with different flags.
// We re-use `cargo test` and `cargo run`, which makes target and binary handling very easy but
/// Performs the setup required to make `cargo miri` work: Getting a custom-built libstd. Then sets
/// `MIRI_SYSROOT`. Skipped if `MIRI_SYSROOT` is already set, in which case we expect the user has
/// done all this already.
-pub fn setup(subcommand: &MiriCommand, target: &str, rustc_version: &VersionMeta) {
+pub fn setup(subcommand: &MiriCommand, target: &str, rustc_version: &VersionMeta, verbose: usize) {
let only_setup = matches!(subcommand, MiriCommand::Setup);
let ask_user = !only_setup;
let print_sysroot = only_setup && has_arg_flag("--print-sysroot"); // whether we just print the sysroot path
command.env("RUSTC_WRAPPER", "");
if only_setup && !print_sysroot {
- // Forward output.
+ // Forward output. Even make it verbose, if requested.
+ for _ in 0..verbose {
+ command.arg("-v");
+ }
} else {
// Supress output.
command.stdout(process::Stdio::null());