Skip to content

Commit 6133999

Browse files
committed
Fix cargo vendor not working without rustc installed
This fixes an issue where vendoring would fail if `rustc` is not in PATH. This happens with the update of some workspaces to the 2024 edition which need to run `rustc -Vv` to determine which rust version is in use.
1 parent 5d4ff50 commit 6133999

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/bootstrap/src/core/build_steps/vendor.rs

+1
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ impl Step for Vendor {
103103
// Will read the libstd Cargo.toml
104104
// which uses the unstable `public-dependency` feature.
105105
cmd.env("RUSTC_BOOTSTRAP", "1");
106+
cmd.env("RUSTC", &builder.initial_rustc);
106107

107108
cmd.current_dir(self.root_dir).arg(&self.output_dir);
108109

0 commit comments

Comments
 (0)