Open doawoo opened 3 weeks ago
Can you try filter out it in here? https://github.com/rust-cross/cargo-zigbuild/blob/d420792226cef24e8a718dbef87fec14df77f3d2/src/zig.rs#L105-L132
Thanks
FYI, -lmsvcrt
seems to be added by Rust in https://github.com/rust-lang/rust/blob/b5723af3457b9cd3795eeb97e9af2d34964854f2/compiler/rustc_target/src/spec/base/windows_gnu.rs#L33-L44
Thanks for the quick reply. Looking at the CI results there's some other gotchas involved here. I've cloned down your branch and will be playing a bit with it to see if I can resolve any of the linker issues I've seen in CI.
I have had a lot of success targeting Linux and macOS machines with this. However I'm running into a puzzling issue, it seems that Rust really wants to link
msvcrt
, even when the command I'm specifying is:It complains about not being able to locate the library.
Does this flag need to be filtered out in the linker argument processing step? Re-running the long command that's spat out, and then removing the
-lmsvcrt
results in the build proceeding further until it hits the temp files that no longer exist post-build.