-
Notifications
You must be signed in to change notification settings - Fork 12.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
statically linking ALL deps for cross compiling [support a RISC-V + musl target] #73051
Comments
You need to pass Note, however, that not all Rust targets support So you may have to use a musl libc based target. Actually, it would be great to add the |
@petrochenkov Does it make sense to
Cause I am not so sure about targetting |
@chaozju Anyway, it won't help in your case because Rust standard library will still pull libc dynamically unless you rebuild the standard library yourself. In other words, this is not a configuration readily supported by rustc, and I'd recommend to address further questions about workarounds to https://users.rust-lang.org if they appear. Also, you'll need to talk to people maintaining wasmer to figure out how to make it pull other native libraries like libffi statically. |
@petrochenkov Thanks a lot ! |
Closing -- questions generally should be directed to users or other forums rather than the issue tracker. |
Hi I am working on cross compilation for wasmer to RISC-V.
I want to statically link all dependencies into 1 executable to avoid
qemu
issue like below.Is there a way to globally configure
cargo build
or something else like-static
flag forgcc
?The text was updated successfully, but these errors were encountered: