We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent dcbdc52 commit e040ab9Copy full SHA for e040ab9
crates/spirv-builder/src/lib.rs
@@ -999,6 +999,12 @@ fn invoke_rustc(builder: &SpirvBuilder) -> Result<PathBuf, SpirvBuilderError> {
999
// so we turn off that caching with an env var, just to avoid any issues.
1000
cargo.env("CARGO_CACHE_RUSTC_INFO", "0");
1001
1002
+ // NOTE(firestar99) If you call SpirvBuilder in a build script, it will
1003
+ // set `RUSTC` before calling it. And if we were to propagate it to our
1004
+ // cargo invocation, it will take precedence over the `+toolchain` we
1005
+ // previously set.
1006
+ cargo.env_remove("RUSTC");
1007
+
1008
// NOTE(eddyb) this used to be just `RUSTFLAGS` but at some point Cargo
1009
// added a separate environment variable using `\x1f` instead of spaces,
1010
// which allows us to have spaces within individual `rustc` flags.
0 commit comments