try to strip prefix via string

This commit is contained in:
Folkert 2022-11-12 00:39:14 +01:00
parent e74ff3f50a
commit c556d96772
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
2 changed files with 5 additions and 8 deletions

View file

@ -1208,18 +1208,12 @@ fn link_wasm32(
// include wasi libc
// using `-lc` is broken in zig 8 (and early 9) in combination with ReleaseSmall
wasi_libc_path.to_str().unwrap(),
&format!(
"-femit-bin={}",
output_path.display().to_string().trim_start_matches(r"\\?")
),
&format!("-femit-bin={}", output_path.display()),
"-target",
"wasm32-wasi-musl",
"--pkg-begin",
"str",
zig_str_path
.display()
.to_string()
.trim_start_matches(r"\\?"),
&zig_str_path.display().to_string(),
"--pkg-end",
"--strip",
"-O",