xuantie-gnu-toolchain-docker/Dockerfile

75 lines
1.6 KiB
Docker
Raw Normal View History

# need bookworm for most up to date cmake
FROM debian:bookworm as build
RUN true && \
apt-get update && \
apt-get install -y \
autoconf \
automake \
autotools-dev \
curl \
python3 \
libmpc-dev \
libmpfr-dev \
libgmp-dev \
gawk \
build-essential \
bison \
flex \
texinfo \
gperf \
libtool \
patchutils \
bc \
zlib1g-dev \
libexpat-dev \
git \
&& \
git clone --recurse-submodules https://github.com/T-head-Semi/xuantie-gnu-toolchain && \
cd xuantie-gnu-toolchain && \
./configure --prefix=/usr/local --enable-multilib && \
make -j8 && \
cd / && \
rm -rf xuantie-gnu-toolchain && \
apt-get remove -y \
autoconf \
automake \
autotools-dev \
curl \
python3 \
libmpc-dev \
libmpfr-dev \
libgmp-dev \
gawk \
build-essential \
bison \
flex \
texinfo \
gperf \
libtool \
patchutils \
bc \
zlib1g-dev \
libexpat-dev \
git \
&& \
apt-get clean && \
true
FROM debian:bookworm
2023-04-26 04:47:55 +00:00
COPY --from=build /usr/local/bin/ /usr/local/bin/
COPY --from=build /usr/local/riscv64-unknown-elf/ /usr/local/riscv64-unknown-elf/
COPY --from=build /usr/local/libexec/ /usr/local/libexec/
COPY --from=build /usr/local/lib/ /usr/local/lib/
RUN true && \
apt-get update && \
apt-get install -y --no-install-recommends \
2023-04-25 00:56:52 +00:00
make \
cmake \
2023-04-26 04:47:55 +00:00
libmpc3 \
&& \
apt-get clean && \
true