@@ -8,10 +8,9 @@ RUN mkdir -p /opt && mkdir -p /home/gcc-user && useradd gcc-user && chown gcc-us
88
99RUN apt-get clean -y && apt-get check -y
1010
11- # # for nightly build of cross compiler with GNAT (Ada), we need "a matching"
12- # # compiler. So using gcc-13 for master is not working. So we have a *hardcoded*
13- # # snapshot below that should be "good enough". When there's a failure caused by
14- # # GNAT, it's probably time to bump the snapshot.
11+ # # For nightly build of cross compiler with GNAT (Ada), we need "a matching"
12+ # # compiler. The nightly gcc trunk is installed via ce_install which handles
13+ # # the symlink automatically.
1514
1615RUN apt-get update -y -q && apt-get upgrade -y -q && apt-get upgrade -y -q && \
1716 apt-get install -y -q \
@@ -48,30 +47,35 @@ RUN apt-get update -y -q && apt-get upgrade -y -q && apt-get upgrade -y -q && \
4847 vim \
4948 zlib1g-dev \
5049 software-properties-common \
51- xz-utils && \
50+ xz-utils \
51+ openssh-client \
52+ python3 \
53+ python3-venv && \
5254 cd /tmp && \
5355 curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" && \
5456 unzip -q awscliv2.zip && \
5557 ./aws/install && \
56- rm -rf aws* && \
57- mkdir -p /opt/compiler-explorer/ && \
58- cd /opt/compiler-explorer && \
59- curl "https://s3.amazonaws.com/compiler-explorer/opt/gcc-11.4.0.tar.xz" -o gcc11.tar.xz && \
60- curl "https://s3.amazonaws.com/compiler-explorer/opt/gcc-12.3.0.tar.xz" -o gcc12.tar.xz && \
61- curl "https://s3.amazonaws.com/compiler-explorer/opt/gcc-13.2.0.tar.xz" -o gcc13.tar.xz && \
62- curl "https://s3.amazonaws.com/compiler-explorer/opt/gcc-14.2.0.tar.xz" -o gcc14.tar.xz && \
63- curl "https://s3.amazonaws.com/compiler-explorer/opt/gcc-trunk-20251023.tar.xz" -o gcc-trunk.tar.xz && \
64- tar Jxf gcc11.tar.xz && \
65- tar Jxf gcc12.tar.xz && \
66- tar Jxf gcc13.tar.xz && \
67- tar Jxf gcc14.tar.xz && \
68- tar Jxf gcc-trunk.tar.xz && \
69- mv gcc-trunk-20251023 gcc-trunk && \
70- rm gcc*.tar.xz
58+ rm -rf aws*
7159
72- # # Beware of the "trunk" download. It is useful when a cross compiler really
73- # # needs a very recent base compiler (e.g. GNAT). The hardcoded filename for
74- # # trunk will only work for some time as we are expiring them after a few days.
60+ # Add github public key to known_hosts for interaction-less clone
61+ RUN mkdir -p /root/.ssh && \
62+ touch /root/.ssh/known_hosts && \
63+ ssh-keyscan github.com >> /root/.ssh/known_hosts
64+
65+ # Clone infra and set up ce_install
66+ RUN mkdir -p /opt/compiler-explorer && \
67+ git clone https://github.com/compiler-explorer/infra /opt/compiler-explorer/infra && \
68+ cd /opt/compiler-explorer/infra && make ce
69+
70+ # Install host GCC compilers via ce_install
71+ RUN /opt/compiler-explorer/infra/bin/ce_install install 'compilers/c++/x86/gcc 11.4.0' && \
72+ /opt/compiler-explorer/infra/bin/ce_install install 'compilers/c++/x86/gcc 12.3.0' && \
73+ /opt/compiler-explorer/infra/bin/ce_install install 'compilers/c++/x86/gcc 13.2.0' && \
74+ /opt/compiler-explorer/infra/bin/ce_install install 'compilers/c++/x86/gcc 14.2.0' && \
75+ /opt/compiler-explorer/infra/bin/ce_install --enable nightly install 'compilers/c++/nightly/gcc trunk'
76+
77+ # # The trunk download is useful when a cross compiler really needs a very recent
78+ # # base compiler (e.g. GNAT). ce_install handles the trunk symlink automatically.
7579
7680# # Need for host GCC version to be ~= latest cross GCC being built.
7781# # This is at least needed for building cross-GNAT (Ada) as the GNAT runtime has no
0 commit comments