Skip to content

Commit 88d058f

Browse files
committed
Don't unnecessarily copy rustc_std_workspace_std into the sysroot
1 parent 2e65a8f commit 88d058f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

build_system/build_sysroot.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,8 @@ pub(crate) fn build_sysroot(
137137
// libstd.
138138
for file in fs::read_dir(host_rustlib_lib).unwrap() {
139139
let file = file.unwrap().path();
140-
if file.file_name().unwrap().to_str().unwrap().contains("std-") {
140+
let filename = file.file_name().unwrap().to_str().unwrap();
141+
if filename.contains("std-") && !filename.contains(".rlib") {
141142
try_hard_link(&file, target_dir.join("lib").join(file.file_name().unwrap()));
142143
}
143144
}

0 commit comments

Comments
 (0)