1 # Generate the docker image for this file by running:
5 FROM debian:stable AS coreboot-sdk
7 # The coreboot Commit-ID to build the toolchain from.
9 # The version of the coreboot sdk to use. Typically, this corresponds to the
10 # toolchain version. This is used to identify this docker image.
15 useradd -p locked -m coreboot && \
16 apt-get -qq update && \
17 apt-get -y install --no-install-recommends \
28 device-tree-compiler \
40 graphicsmagick-imagemagick-compat \
44 libcapture-tiny-perl \
46 libcurl4-openssl-dev \
97 git clone https://review.coreboot.org/coreboot && \
99 git checkout ${DOCKER_COMMIT}; \
100 if echo ${CROSSGCC_PARAM} | grep -q ^all; then \
101 make -C /tmp/coreboot/util/crossgcc/ build_clang \
102 BUILD_LANGUAGES=c,ada CPUS=$(nproc) DEST=/opt/xgcc; \
104 make -C /tmp/coreboot/util/crossgcc/ ${CROSSGCC_PARAM} \
105 BUILD_LANGUAGES=c,ada CPUS=$(nproc) DEST=/opt/xgcc && \
108 RUN mkdir /home/coreboot/.ccache && \
109 chown coreboot:coreboot /home/coreboot/.ccache && \
110 mkdir /home/coreboot/cb_build && \
111 chown coreboot:coreboot /home/coreboot/cb_build && \
112 echo "export PATH=$PATH:/opt/xgcc/bin" >> /home/coreboot/.bashrc && \
113 echo "export SDK_VERSION=${SDK_VERSION}" >> /home/coreboot/.bashrc && \
114 echo "export SDK_COMMIT=${DOCKER_COMMIT}" >> /home/coreboot/.bashrc
116 ENV PATH $PATH:/opt/xgcc/bin
117 ENV SDK_VERSION=${SDK_VERSION}
118 ENV SDK_COMMIT=${DOCKER_COMMIT}
122 VOLUME /home/coreboot/.ccache