The std i686-unknown-linux-musl for i686-unknown-linux-musl are only available on Rust 1.10 or later. You can create static binary code for i686 with the following commands:
$ rustup default stable # stable must at least 1.10 $ rustup target add i686-unknown-linux-musl $ cargo build --target i686-unknown-linux-musl
The generated binaries can be found at target/i686-unknown-linux-musl/debug/ or target/i686-unknown-linux-musl/release/ .
We can verify that the generated binary is statically linked to ldd :
$ ldd target/i686-unknown-linux-musl/debug/main not a dynamic executable
source share