-
Notifications
You must be signed in to change notification settings - Fork 237
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
musl-gcc required when building with target=x86_64-unknown-linux-musl #34
Comments
I'm running into this issue as well when trying to cross-compile my Rust project using the target The following cargo configuration allowed me to cross-compile a much simpler project that didn't include
|
@rogeruiz the .cargo/config configuration tells Cargo what linker to use, but unfortunately that's different than the configuration used to tell build scripts what compiler to use. For that you'll want to use the environment variable |
Thanks @alexcrichton. Looks like I'm running into other issues related to I think I may just follow the process of having my rust project build in an actual Linux environment. thanks again! |
@alexcrichton how to pass env variable with dashes in it? |
Indeed yeah, dashes to underscores should work! |
I'm going to close this as this is largely working as expected |
For cross compile, you can add env args |
On Fedora fixed by
or by
|
On archlinux: sudo pacman -S musl |
When building backtrace-sys for x86_64-unknown-linux-musl I got the following errors:
Opening up the config.log i saw:
On ubuntu I can fix this with
apt-get install musl-tools
.I suspect there is no workaround for this, but it probably should be noted in the readme that a compiler is required to build this, and specifically musl-gcc if building for the the musl target.
The text was updated successfully, but these errors were encountered: