Created
January 15, 2022 18:15
-
-
Save xypron/900510c0d3b3971f8ea517673a70e55c to your computer and use it in GitHub Desktop.
Dockerfile for building U-Boot on Alpine Linux
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# SPDX-License-Identifier: GPL-2.0+ | |
# This Dockerfile is used to build an image containing basic stuff to be used | |
# to build U-Boot and run our test suites. | |
FROM alpine:3.15.0 | |
MAINTAINER Heinrich Schuchardt <xypron.glpk@gmx.de> | |
LABEL Description=" This image is for building U-Boot inside a container" | |
# Install packages | |
RUN apk update | |
RUN apk add \ | |
alpine-sdk \ | |
bc \ | |
bison \ | |
dtc \ | |
flex \ | |
git \ | |
linux-headers \ | |
ncurses-dev \ | |
openssl-dev \ | |
python3 \ | |
py3-setuptools \ | |
python3-dev \ | |
sdl2-dev \ | |
sudo | |
# Create our user/group | |
RUN echo uboot ALL=NOPASSWD: ALL > /etc/sudoers.d/uboot | |
RUN adduser -D uboot | |
RUN addgroup uboot wheel | |
USER uboot:uboot | |
WORKDIR /home/uboot | |
RUN git clone https://source.denx.de/u-boot/u-boot.git | |
WORKDIR /home/uboot/u-boot | |
RUN make sandbox_defconfig | |
RUN sed -i 's/CONFIG_ETH_SANDBOX_RAW=y/# CONFIG_ETH_SANDBOX_RAW is not set/g' .config | |
RUN make -j$(nproc) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment