master
docker 185 lines 7.15 KB
Raw
1 # THIS FILE WAS AUTO-GENERATED
2 #
3 # $ lcitool dockerfile --layers all --cross-arch riscv64 debian-13 qemu
4 #
5 # https://gitlab.com/libvirt/libvirt-ci
6
7 FROM docker.io/library/debian:13-slim
8
9 RUN 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 bindgen \
17 bison \
18 bsdextrautils \
19 bzip2 \
20 ca-certificates \
21 ccache \
22 coreutils \
23 dbus \
24 debianutils \
25 diffutils \
26 exuberant-ctags \
27 findutils \
28 flex \
29 gcc \
30 gcovr \
31 gettext \
32 git \
33 hostname \
34 libclang-rt-dev \
35 libglib2.0-dev \
36 llvm \
37 locales \
38 make \
39 mtools \
40 ninja-build \
41 openssh-client \
42 pkgconf \
43 python3 \
44 python3-pip \
45 python3-setuptools \
46 python3-sphinx \
47 python3-sphinx-rtd-theme \
48 python3-tomli \
49 python3-venv \
50 python3-wheel \
51 rpm2cpio \
52 rustc \
53 sed \
54 socat \
55 sparse \
56 swtpm \
57 tar \
58 tesseract-ocr \
59 tesseract-ocr-eng \
60 vulkan-tools \
61 xorriso \
62 zstd && \
63 eatmydata apt-get autoremove -y && \
64 eatmydata apt-get autoclean -y && \
65 sed -Ei 's,^# (en_US\.UTF-8 .*)$,\1,' /etc/locale.gen && \
66 dpkg-reconfigure locales && \
67 rm -f /usr/lib*/python3*/EXTERNALLY-MANAGED
68
69 RUN /usr/bin/pip3 install meson==1.12.0
70
71 ENV CCACHE_WRAPPERSDIR="/usr/libexec/ccache-wrappers"
72 ENV LANG="en_US.UTF-8"
73 ENV MAKE="/usr/bin/make"
74 ENV NINJA="/usr/bin/ninja"
75 ENV PYTHON="/usr/bin/python3"
76
77 RUN export DEBIAN_FRONTEND=noninteractive && \
78 dpkg --add-architecture riscv64 && \
79 eatmydata apt-get update && \
80 eatmydata apt-get dist-upgrade -y && \
81 eatmydata apt-get install --no-install-recommends -y dpkg-dev && \
82 eatmydata apt-get install --no-install-recommends -y \
83 gcc-riscv64-linux-gnu \
84 libaio-dev:riscv64 \
85 libasan8:riscv64 \
86 libasound2-dev:riscv64 \
87 libattr1-dev:riscv64 \
88 libbpf-dev:riscv64 \
89 libbrlapi-dev:riscv64 \
90 libbz2-dev:riscv64 \
91 libc6-dev:riscv64 \
92 libcacard-dev:riscv64 \
93 libcap-ng-dev:riscv64 \
94 libcapstone-dev:riscv64 \
95 libcbor-dev:riscv64 \
96 libcmocka-dev:riscv64 \
97 libcurl4-gnutls-dev:riscv64 \
98 libdaxctl-dev:riscv64 \
99 libdrm-dev:riscv64 \
100 libepoxy-dev:riscv64 \
101 libfdt-dev:riscv64 \
102 libffi-dev:riscv64 \
103 libfuse3-dev:riscv64 \
104 libgbm-dev:riscv64 \
105 libgcrypt20-dev:riscv64 \
106 libglib2.0-dev:riscv64 \
107 libgnutls28-dev:riscv64 \
108 libgtk-3-dev:riscv64 \
109 libgtk-vnc-2.0-dev:riscv64 \
110 libibverbs-dev:riscv64 \
111 libiscsi-dev:riscv64 \
112 libjemalloc-dev:riscv64 \
113 libjpeg62-turbo-dev:riscv64 \
114 libjson-c-dev:riscv64 \
115 liblttng-ust-dev:riscv64 \
116 liblzo2-dev:riscv64 \
117 libncursesw5-dev:riscv64 \
118 libnfs-dev:riscv64 \
119 libnuma-dev:riscv64 \
120 libpam0g-dev:riscv64 \
121 libpcre2-dev:riscv64 \
122 libpipewire-0.3-dev:riscv64 \
123 libpixman-1-dev:riscv64 \
124 libpng-dev:riscv64 \
125 libpulse-dev:riscv64 \
126 librbd-dev:riscv64 \
127 librdmacm-dev:riscv64 \
128 libsasl2-dev:riscv64 \
129 libsdl2-dev:riscv64 \
130 libsdl2-image-dev:riscv64 \
131 libseccomp-dev:riscv64 \
132 libselinux1-dev:riscv64 \
133 libslirp-dev:riscv64 \
134 libsnappy-dev:riscv64 \
135 libsndio-dev:riscv64 \
136 libspice-protocol-dev:riscv64 \
137 libspice-server-dev:riscv64 \
138 libssh-dev:riscv64 \
139 libstd-rust-dev:riscv64 \
140 libsystemd-dev:riscv64 \
141 libtasn1-6-dev:riscv64 \
142 libubsan1:riscv64 \
143 libudev-dev:riscv64 \
144 liburing-dev:riscv64 \
145 libusb-1.0-0-dev:riscv64 \
146 libusbredirhost-dev:riscv64 \
147 libvdeplug-dev:riscv64 \
148 libvirglrenderer-dev:riscv64 \
149 libvte-2.91-dev:riscv64 \
150 libxdp-dev:riscv64 \
151 libzstd-dev:riscv64 \
152 nettle-dev:riscv64 \
153 systemtap-sdt-dev:riscv64 \
154 zlib1g-dev:riscv64 && \
155 eatmydata apt-get autoremove -y && \
156 eatmydata apt-get autoclean -y && \
157 mkdir -p /usr/local/share/meson/cross && \
158 printf "[binaries]\n\
159 c = '/usr/bin/riscv64-linux-gnu-gcc'\n\
160 ar = '/usr/bin/riscv64-linux-gnu-gcc-ar'\n\
161 strip = '/usr/bin/riscv64-linux-gnu-strip'\n\
162 pkgconfig = '/usr/bin/riscv64-linux-gnu-pkg-config'\n\
163 \n\
164 [host_machine]\n\
165 system = 'linux'\n\
166 cpu_family = 'riscv64'\n\
167 cpu = 'riscv64'\n\
168 endian = 'little'\n" > /usr/local/share/meson/cross/riscv64-linux-gnu && \
169 dpkg-query --showformat '${Package}_${Version}_${Architecture}\n' --show > /packages.txt && \
170 mkdir -p /usr/libexec/ccache-wrappers && \
171 ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/riscv64-linux-gnu-cc && \
172 ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/riscv64-linux-gnu-gcc
173
174 ENV ABI="riscv64-linux-gnu"
175 ENV MESON_OPTS="--cross-file=riscv64-linux-gnu"
176 ENV RUST_TARGET="riscv64gc-unknown-linux-gnu"
177 ENV QEMU_CONFIGURE_OPTS=--cross-prefix=riscv64-linux-gnu-
178 ENV DEF_TARGET_LIST=riscv64-softmmu,riscv64-linux-user
179 # As a final step configure the user (if env is defined)
180 ARG USER
181 ARG UID
182 RUN if [ "${USER}" ]; then \
183 id ${USER} 2>/dev/null || useradd -u ${UID} -U ${USER}; fi
184
185 ENV ENABLE_RUST=1