Base images containing the muslcc tools build for multiple architectures with x86_64 (amd64) host
10K+
This hub repo is mostly used by the rust-musl repo: https://hub.docker.com/r/blackdex/rust-musl & https://github.com/BlackDex/rust-musl
These are images which hold pre-build musl toolchains for several architectures. The musl toolchain is build using the following versions(as of 2022-04):
v11.2.0v2.33.1v1.1.24v1.2.3v6.1.2v1.1.0v4.0.2v4.19.88-1| Cross Target | Docker Tag |
|---|---|
| x86_64-unknown-linux-musl | x86_64-musl |
| armv7-unknown-linux-musleabihf | armv7-musleabihf |
| aarch64-unknown-linux-musl | aarch64-musl |
| arm-unknown-linux-musleabi | arm-musleabi |
| arm-unknown-linux-musleabihf | arm-musleabihf |
| armv5te-unknown-linux-musleabi | armv5te-musleabi |
Since the musl toolchain builds do not changes that much, using these pre-build images lower the build time for the musl-rust images. If you want to use these musl toolchains your self you could can do that like this.
FROM ubuntu:22.04
ARG IMAGE_TAG=aarch64-musl
# Extract the pre-build toolchain from the musl-toolchain image
# This doesn't need to be build every time since not much will change
FROM blackdex/musl-toolchain:${IMAGE_TAG} AS musl-toolchain
ARG TARGET=aarch64-unknown-linux-musl
ENV TARGET="${TARGET}" \
TARGET_PREFIX=/usr/local/musl
LANG=C.UTF-8 \
TERM=xterm-256color \
TARGET_PKG_CONFIG_PATH=/usr/local/musl/lib/pkgconfig \
TARGET_LD="${TARGET}-ld" \
TARGET_CC="${TARGET}-gcc" \
TARGET_CXX="${TARGET}-g++" \
RUST_MUSL_CROSS_TARGET="${TARGET}" \
PATH="/usr/local/musl/bin:/root/.cargo/bin:${PATH}" \
RUN mkdir -p "${TARGET_PREFIX}/tbin" /home/rust/src
COPY --from=musl-toolchain /usr/local/musl/$TARGET ${TARGET_PREFIX}
RUN echo "Start building your C/C++ Libraries" && \
./configure --static && \
make
Content type
Image
Digest
sha256:a3e6e9b20…
Size
70.9 MB
Last updated
4 days ago
docker pull blackdex/musl-toolchain:armv7-musleabihf-2026-09-24