use the nightly compiler on windows to build platforms

This commit is contained in:
Folkert 2022-11-10 18:48:54 +01:00
parent 2b6ddc990c
commit 5b952616a9
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
2 changed files with 14 additions and 1 deletions

View file

@ -633,6 +633,12 @@ pub fn rebuild_host(
);
let mut cargo_cmd = cargo();
if cfg!(windows) {
// on windows, we need the `+nightly` toolchain so we can use `-Z export-executable-symbols`
cargo_cmd.arg("+nightly");
}
cargo_cmd.arg("build").current_dir(cargo_dir);
// Rust doesn't expose size without editing the cargo.toml. Instead just use release.
if matches!(opt_level, OptLevel::Optimize | OptLevel::Size) {