-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile.musl-cross-make
More file actions
29 lines (26 loc) · 1.23 KB
/
Dockerfile.musl-cross-make
File metadata and controls
29 lines (26 loc) · 1.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
ARG MUSL_TARGET=x86_64-linux-musl
FROM debian:bullseye
ARG MUSL_TARGET
ADD ./download /usr/local/bin
RUN mkdir /output && \
export DEBIAN_FRONTEND=noninteractive && \
sed -e 's/http:\/\/[^/]*/http:\/\/deb.debian.org/g' -i /etc/apt/sources.list && \
apt-get --option=Dpkg::Options::=--force-unsafe-io update && \
apt-get --option=Dpkg::Options::=--force-confold --option=Dpkg::Options::=--force-unsafe-io -y dist-upgrade && \
apt-get --option=Dpkg::Options::=--force-unsafe-io -y autoremove && \
apt-get --option=Dpkg::Options::=--force-confold --option=Dpkg::Options::=--force-unsafe-io install -y --no-install-recommends build-essential ca-certificates wget unzip flex bison autoconf file python3 cmake gawk && \
apt-get clean
RUN download https://github.com/richfelker/musl-cross-make/archive/refs/tags/v0.9.9.zip /tmp/musl-cross-make.zip 6cbe2f6ce92e7f8f3973786aaf0b990d0db380c0e0fc419a7d516df5bb03c891 && \
mkdir /build && \
cd /build && \
unzip /tmp/musl-cross-make.zip && \
cd musl-cross-make-* && \
cp config.mak.dist config.mak && \
echo "OUTPUT=/build/cross" >> config.mak && \
echo "TARGET=$MUSL_TARGET" >> config.mak && \
make -j $(nproc) && \
make install && \
cd .. && \
rm -rf musl-cross-make-* && \
rm /tmp/musl-cross-make.zip
CMD ["bash"]