emk / rust-musl-builder

Docker images for compiling static Rust binaries using musl-libc and musl-gcc, with static versions of useful C libraries. Supports openssl and diesel crates.
Apache License 2.0
1.54k stars 193 forks source link

Help building musl binaries for other architectures #15

Closed mcandre closed 7 years ago

mcandre commented 7 years ago

Inspired by your helpful rust-musl-builder, I sketched out some rustup Docker images for GNU libc and musl, targeting the x86_64 and i686 architectures.

https://github.com/mcandre/docker-rustup

Do you happen to know if rustup can target musl on further architectures such as ARM?

emk commented 7 years ago

Here are the architectures that rustup claims to support:

> rustup target list | grep musl
arm-unknown-linux-musleabi
arm-unknown-linux-musleabihf
armv7-unknown-linux-musleabihf
i686-unknown-linux-musl
mips-unknown-linux-musl
mipsel-unknown-linux-musl
x86_64-unknown-linux-musl (installed)

Presumably you'd also need to install an appropriate version of musl's gcc and header files, and I have absolutely no idea whatsoever how to do that.

messense commented 7 years ago

@mcandre I just made https://github.com/messense/rust-musl-cross (it's inspired by rust-musl-builder project, Thanks!) which has ARM targets.

emk commented 7 years ago

@messense Cool!

(I'm not sure why I actually closed this issue, BTW, maybe it was by mistake? Feel free to re-open it if anybody is still interested.)