util/docker: Update coreboot-sdk consolidate coreboot build
Because docker saves a container for every run command, by breaking the coreboot build into 3 commands, it greatly increased the size of the docker containers needed. When combined as one run command, the coreboot repo that is downloaded, along with the coreboot test build are deleted before the container is created. Since those directories are deleted in a later run command, they don't even make it into the final container, and just force coreboot-sdk users to download extra data for no reason. While splitting the build may help with debugging failures when creating the docker container, that debugging can be done locally by splitting up a working copy. Signed-off-by: Martin Roth <martin@coreboot.org> Change-Id: Ia28ee4e22c0a76dc45343755c45678795308adca Reviewed-on: https://review.coreboot.org/c/coreboot/+/46801 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Patrick Georgi <pgeorgi@google.com>
This commit is contained in:
parent
b86d2b0935
commit
ebeec5aed3
|
@ -84,21 +84,17 @@ RUN \
|
|||
&& ln -s /usr/bin/aclocal /usr/bin/aclocal-1.15
|
||||
|
||||
RUN \
|
||||
cd /root && \
|
||||
cd /tmp && \
|
||||
git clone https://review.coreboot.org/coreboot && \
|
||||
cd coreboot && \
|
||||
git checkout {{DOCKER_COMMIT}}
|
||||
|
||||
RUN \
|
||||
git checkout {{DOCKER_COMMIT}}; \
|
||||
if echo {{CROSSGCC_PARAM}} | grep -q ^all; then \
|
||||
make -C/root/coreboot/util/crossgcc/ build_clang \
|
||||
make -C /tmp/coreboot/util/crossgcc/ build_clang \
|
||||
BUILD_LANGUAGES=c,ada CPUS=$(nproc) DEST=/opt/xgcc; \
|
||||
fi
|
||||
|
||||
RUN \
|
||||
make -C/root/coreboot/util/crossgcc/ {{CROSSGCC_PARAM}} \
|
||||
fi; \
|
||||
make -C /tmp/coreboot/util/crossgcc/ {{CROSSGCC_PARAM}} \
|
||||
BUILD_LANGUAGES=c,ada CPUS=$(nproc) DEST=/opt/xgcc && \
|
||||
rm -rf /root/coreboot
|
||||
rm -rf /tmp/coreboot
|
||||
|
||||
RUN mkdir /home/coreboot/.ccache && \
|
||||
chown coreboot:coreboot /home/coreboot/.ccache && \
|
||||
|
|
Loading…
Reference in New Issue