1# THIS FILE WAS AUTO-GENERATED 2# 3# $ lcitool dockerfile --layers all --cross-arch riscv64 debian-sid qemu-minimal 4# 5# https://gitlab.com/libvirt/libvirt-ci 6 7FROM docker.io/library/debian:sid-slim 8 9RUN export DEBIAN_FRONTEND=noninteractive && \ 10 apt-get update && \ 11 apt-get install -y eatmydata && \ 12 eatmydata apt-get dist-upgrade -y && \ 13 eatmydata apt-get install --no-install-recommends -y \ 14 bash \ 15 bc \ 16 bison \ 17 ca-certificates \ 18 ccache \ 19 findutils \ 20 flex \ 21 gcc \ 22 git \ 23 libglib2.0-dev \ 24 locales \ 25 make \ 26 meson \ 27 ninja-build \ 28 pkgconf \ 29 python3 \ 30 python3-venv \ 31 sed \ 32 tar && \ 33 eatmydata apt-get autoremove -y && \ 34 eatmydata apt-get autoclean -y && \ 35 sed -Ei 's,^# (en_US\.UTF-8 .*)$,\1,' /etc/locale.gen && \ 36 dpkg-reconfigure locales && \ 37 rm -f /usr/lib*/python3*/EXTERNALLY-MANAGED 38 39ENV CCACHE_WRAPPERSDIR "/usr/libexec/ccache-wrappers" 40ENV LANG "en_US.UTF-8" 41ENV MAKE "/usr/bin/make" 42ENV NINJA "/usr/bin/ninja" 43ENV PYTHON "/usr/bin/python3" 44 45RUN export DEBIAN_FRONTEND=noninteractive && \ 46 dpkg --add-architecture riscv64 && \ 47 eatmydata apt-get install debian-ports-archive-keyring && \ 48 eatmydata echo 'deb http://ftp.ports.debian.org/debian-ports/ sid main' > /etc/apt/sources.list.d/ports.list && \ 49 eatmydata echo 'deb http://ftp.ports.debian.org/debian-ports/ unreleased main' >> /etc/apt/sources.list.d/ports.list && \ 50 eatmydata apt-get update && \ 51 eatmydata apt-get dist-upgrade -y && \ 52 eatmydata apt-get install --no-install-recommends -y dpkg-dev && \ 53 eatmydata apt-get install --no-install-recommends -y \ 54 gcc-riscv64-linux-gnu \ 55 libc6-dev:riscv64 \ 56 libfdt-dev:riscv64 \ 57 libffi-dev:riscv64 \ 58 libglib2.0-dev:riscv64 \ 59 libpixman-1-dev:riscv64 && \ 60 eatmydata apt-get autoremove -y && \ 61 eatmydata apt-get autoclean -y && \ 62 mkdir -p /usr/local/share/meson/cross && \ 63 printf "[binaries]\n\ 64c = '/usr/bin/riscv64-linux-gnu-gcc'\n\ 65ar = '/usr/bin/riscv64-linux-gnu-gcc-ar'\n\ 66strip = '/usr/bin/riscv64-linux-gnu-strip'\n\ 67pkgconfig = '/usr/bin/riscv64-linux-gnu-pkg-config'\n\ 68\n\ 69[host_machine]\n\ 70system = 'linux'\n\ 71cpu_family = 'riscv64'\n\ 72cpu = 'riscv64'\n\ 73endian = 'little'\n" > /usr/local/share/meson/cross/riscv64-linux-gnu && \ 74 dpkg-query --showformat '${Package}_${Version}_${Architecture}\n' --show > /packages.txt && \ 75 mkdir -p /usr/libexec/ccache-wrappers && \ 76 ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/riscv64-linux-gnu-cc && \ 77 ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/riscv64-linux-gnu-gcc 78 79ENV ABI "riscv64-linux-gnu" 80ENV MESON_OPTS "--cross-file=riscv64-linux-gnu" 81ENV QEMU_CONFIGURE_OPTS --cross-prefix=riscv64-linux-gnu- 82ENV DEF_TARGET_LIST riscv64-softmmu,riscv64-linux-user 83# As a final step configure the user (if env is defined) 84ARG USER 85ARG UID 86RUN if [ "${USER}" ]; then \ 87 id ${USER} 2>/dev/null || useradd -u ${UID} -U ${USER}; fi 88