Skip to content
This repository was archived by the owner on Nov 26, 2025. It is now read-only.

Commit 6b6e856

Browse files
committed
patch: Update Dockerfile
1 parent 0105b0a commit 6b6e856

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

Dockerfile

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
FROM rust:slim
22

33
RUN apt-get update \
4-
&& apt-get install -y --no-install-recommends libclang-dev qemu-system wget make \
4+
&& apt-get install -y --no-install-recommends libclang-dev wget make python3 \
5+
xz-utils python3-venv ninja-build bzip2 meson \
6+
pkg-config libglib2.0-dev git libslirp-dev \
57
&& rm -rf /var/lib/apt/lists/*
68

79
RUN cargo install cargo-binutils axconfig-gen
@@ -13,9 +15,23 @@ RUN rustc --version
1315
RUN wget https://musl.cc/aarch64-linux-musl-cross.tgz \
1416
&& wget https://musl.cc/riscv64-linux-musl-cross.tgz \
1517
&& wget https://musl.cc/x86_64-linux-musl-cross.tgz \
18+
&& wget https://github.com/LoongsonLab/oscomp-toolchains-for-oskernel/releases/download/gcc-13.2.0-loongarch64/gcc-13.2.0-loongarch64-linux-gnu.tgz \
19+
&& wget https://github.com/LoongsonLab/oscomp-toolchains-for-oskernel/raw/refs/heads/main/musl-loongarch64-1.2.2.tgz \
1620
&& tar zxf aarch64-linux-musl-cross.tgz \
1721
&& tar zxf riscv64-linux-musl-cross.tgz \
1822
&& tar zxf x86_64-linux-musl-cross.tgz \
23+
&& tar zxf gcc-13.2.0-loongarch64-linux-gnu.tgz \
24+
&& tar zxf musl-loongarch64-1.2.2.tgz && cd musl-loongarch64-1.2.2 && ./setup && cd .. \
1925
&& rm -f *.tgz
2026

27+
RUN wget https://download.qemu.org/qemu-9.2.1.tar.xz \
28+
&& tar xf qemu-9.2.1.tar.xz \
29+
&& cd qemu-9.2.1 \
30+
&& ./configure --prefix=/qemu-bin-9.2.1 \
31+
--target-list=loongarch64-softmmu,riscv64-softmmu,aarch64-softmmu,x86_64-softmmu \
32+
--enable-gcov --enable-debug --enable-slirp \
33+
&& make -j$(nproc) \
34+
&& make install
35+
RUN rm -rf qemu-9.2.1 qemu-9.2.1.tar.xz
2136
ENV PATH="/x86_64-linux-musl-cross/bin:/aarch64-linux-musl-cross/bin:/riscv64-linux-musl-cross/bin:$PATH"
37+
ENV PATH="/gcc-13.2.0-loongarch64-linux-gnu/bin:/musl-loongarch64-1.2.2/bin:/qemu-bin-9.2.1/bin:$PATH"

0 commit comments

Comments
 (0)