blob: 479b4d6ebab6709fcfac664e0e894511cc440818 [file] [log] [blame]
Philippe Mathieu-Daudé36dc5fe2018-05-01 21:21:43 -03001#
2# Docker TriCore cross-compiler target
3#
Alex Bennée39ce9232021-07-21 00:27:01 +01004# This docker target builds on the Debian Buster base image but
5# doesn't inherit from the common one to avoid bringing in unneeded
6# dependencies.
Philippe Mathieu-Daudé36dc5fe2018-05-01 21:21:43 -03007#
8# Copyright (c) 2018 Philippe Mathieu-Daudé
9#
10# SPDX-License-Identifier: GPL-2.0-or-later
11#
Paolo Bonzini87f77f52023-08-08 16:02:57 +020012FROM docker.io/library/debian:11-slim
Philippe Mathieu-Daudé36dc5fe2018-05-01 21:21:43 -030013
14MAINTAINER Philippe Mathieu-Daudé <f4bug@amsat.org>
15
Alex Bennée39ce9232021-07-21 00:27:01 +010016RUN apt update && \
17 DEBIAN_FRONTEND=noninteractive apt install -yy eatmydata && \
18 DEBIAN_FRONTEND=noninteractive eatmydata apt install -yy \
Paolo Bonzini3265d1f2022-01-05 13:50:08 +000019 bison \
Alex Bennée39ce9232021-07-21 00:27:01 +010020 bzip2 \
21 ca-certificates \
22 ccache \
Bastian Koppelmann3c471b02023-02-28 19:06:40 +000023 curl \
Philippe Mathieu-Daudé7ac17cb2023-01-24 18:01:05 +000024 flex \
Alex Bennée39ce9232021-07-21 00:27:01 +010025 g++ \
26 gcc \
27 git \
28 libglib2.0-dev \
29 libpixman-1-dev \
Alex Bennée39ce9232021-07-21 00:27:01 +010030 locales \
31 make \
32 ninja-build \
Alex Bennée39ce9232021-07-21 00:27:01 +010033 pkgconf \
34 python3-pip \
35 python3-setuptools \
John Snowa22a4b22023-05-10 23:54:19 -040036 python3-wheel \
Daniel P. Berrangéc1d822c2024-07-29 15:44:01 +010037 python3-venv && \
38 dpkg-query --showformat '${Package}_${Version}_${Architecture}\n' --show > /packages.txt
Alex Bennée39ce9232021-07-21 00:27:01 +010039
Paolo Bonzini7ace2192023-08-08 23:35:47 +020040RUN /usr/bin/pip3 install tomli
41
Bastian Koppelmann3c471b02023-02-28 19:06:40 +000042RUN curl -#SL https://github.com/bkoppelmann/package_940/releases/download/tricore-toolchain-9.40/tricore-toolchain-9.4.0.tar.gz \
43 | tar -xzC /usr/local/
Philippe Mathieu-Daudé36dc5fe2018-05-01 21:21:43 -030044
Alex Bennée39ce9232021-07-21 00:27:01 +010045# This image can only build a very minimal QEMU as well as the tests
46ENV DEF_TARGET_LIST tricore-softmmu
47ENV QEMU_CONFIGURE_OPTS --disable-user --disable-tools --disable-fdt
Daniel P. Berrangébad7a272024-05-13 12:15:49 +010048ENV MAKE /usr/bin/make
Alex Bennée93bd2952023-02-28 19:06:48 +000049# As a final step configure the user (if env is defined)
50ARG USER
51ARG UID
52RUN if [ "${USER}" ]; then \
53 id ${USER} 2>/dev/null || useradd -u ${UID} -U ${USER}; fi