Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mention --with-cargo in tutorial or make it a default #81

Closed
petrochenkov opened this issue May 3, 2020 · 2 comments · Fixed by #98
Closed

Mention --with-cargo in tutorial or make it a default #81

petrochenkov opened this issue May 3, 2020 · 2 comments · Fixed by #98
Assignees

Comments

@petrochenkov
Copy link

Without correct version of cargo any version of rustc that is older than few weeks will produce random build errors which will be counted as "regression found" by default.

It is pretty confusing when bisect-rustc tells that revision xyz produces an error and silently stops bisecting correctly, while cargo +xyz build doesn't produce any error when run explicitly.

@chrissimpkins chrissimpkins self-assigned this Jun 12, 2020
@chrissimpkins
Copy link
Member

chrissimpkins commented Jun 12, 2020

As discussed in https://rust-lang.zulipchat.com/#narrow/stream/217417-t-compiler.2Fcargo-bisect-rustc/topic/unrecognized.20option.20json, we will transition to the --with-cargo behavior as default.

For my reference:

configuration source is here:

#[structopt(
long = "with-cargo",
help = "Download cargo [default: installed cargo]"
)]
with_cargo: bool,

pub(crate) fn from_cfg_with_url_prefix(cfg: &Config, url_prefix: String) -> Self {
DownloadParams {
url_prefix,
tmp_dir: cfg.rustup_tmp_path.clone(),
install_dir: cfg.toolchains_path.clone(),
install_cargo: cfg.args.with_cargo,
install_src: cfg.args.with_src,
force_install: cfg.args.force_install,
}
}
}

install source is here:

if dl_params.install_cargo {
let filename = format!("cargo-nightly-{}", self.host);
download_tarball(
&client,
&format!("cargo for {}", self.host),
&format!("{}/{}/{}.tar", dl_params.url_prefix, location, filename,),
Some(&PathBuf::from(&filename).join("cargo")),
tmpdir.path(),
)
.map_err(InstallError::Download)?;
}

@chrissimpkins
Copy link
Member

#98

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants