mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-10-24 18:02:27 -09:00
board/raspberrypi: Support boot.scr for U-Boot
If using U-Boot as "kernel" for the raspberrypi bootloader, include boot.scr in the boot partition if it exists. To use this, use BR2_PACKAGE_RPI_FIRMWARE_CONFIG_FILE to set a config file that uses U-Boot, and enable building a boot script in the U-Boot host tool settings. Signed-off-by: Fiona Klute (WIWA) <fiona.klute@gmx.de> Reviewed-by: Yann E. MORIN <yann.morin.1998@free.fr> Tested-by: Gaël PORTAY <gael.portay+rtone@gmail.com> Signed-off-by: Arnout Vandecappelle <arnout@rnout.be>
This commit is contained in:
committed by
Arnout Vandecappelle
parent
4738cdae83
commit
afdd9c079d
@@ -19,6 +19,12 @@ if [ ! -e "${GENIMAGE_CFG}" ]; then
|
||||
KERNEL=$(sed -n 's/^kernel=//p' "${BINARIES_DIR}/rpi-firmware/config.txt")
|
||||
FILES+=( "${KERNEL}" )
|
||||
|
||||
# If config.txt calls for running U-Boot, include the boot
|
||||
# script if any.
|
||||
if [ "${KERNEL}" = "u-boot.bin" ] && [ -e "${BINARIES_DIR}/boot.scr" ]; then
|
||||
FILES+=( "boot.scr" )
|
||||
fi
|
||||
|
||||
BOOT_FILES=$(printf '\\t\\t\\t"%s",\\n' "${FILES[@]}")
|
||||
sed "s|#BOOT_FILES#|${BOOT_FILES}|" "${BOARD_DIR}/genimage.cfg.in" \
|
||||
> "${GENIMAGE_CFG}"
|
||||
|
||||
Reference in New Issue
Block a user