From 4f76f7fe17ca293c22aeb93a4f2d7d34f962f7d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Kope=C4=87?= Date: Fri, 28 Mar 2025 12:41:50 +0100 Subject: [PATCH] build.sh: protectli: add default logo MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add the custom Protectli logo to built binaries, replacing the black screen in the normal boot path and preserving it in recovery. Upstream-Status: Inappropriate [Dasharo downstream] Change-Id: I3ddbb41233403b89d2c8d823f0ae36abfaef8f0a Signed-off-by: Michał Kopeć --- build.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/build.sh b/build.sh index b3dff354a6..c13b304f44 100755 --- a/build.sh +++ b/build.sh @@ -145,6 +145,7 @@ function build_msi { function build_protectli_vault { DEFCONFIG="configs/config.protectli_${BOARD}" FW_VERSION=$(cat ${DEFCONFIG} | grep CONFIG_LOCALVERSION | cut -d '=' -f 2 | tr -d '"') + LOGO="3rdparty/dasharo-blobs/protectli/bootsplash.bmp" build_prep @@ -153,6 +154,15 @@ function build_protectli_vault { build_start cp build/coreboot.rom protectli_${BOARD}_${FW_VERSION}.rom + + sdk_run /bin/bash -c "./build/cbfstool \ + protectli_${BOARD}_${FW_VERSION}.rom add \ + -r BOOTSPLASH \ + -f \"$LOGO\" \ + -n logo.bmp \ + -t raw \ + -c lzma" + if [ $? -eq 0 ]; then echo "Result binary placed in $PWD/protectli_${BOARD}_${FW_VERSION}.rom" sha256sum protectli_${BOARD}_${FW_VERSION}.rom > protectli_${BOARD}_${FW_VERSION}.rom.sha256 @@ -165,6 +175,7 @@ function build_protectli_vault { function build_v1x10 { DEFCONFIG="configs/config.protectli_vault_jsl_$1" FW_VERSION=$(cat ${DEFCONFIG} | grep CONFIG_LOCALVERSION | cut -d '=' -f 2 | tr -d '"') + LOGO="3rdparty/dasharo-blobs/protectli/bootsplash.bmp" build_prep @@ -173,6 +184,15 @@ function build_v1x10 { build_start cp build/coreboot.rom protectli_$1_${FW_VERSION}.rom + + sdk_run /bin/bash -c "./build/cbfstool \ + ./protectli_${1}_${FW_VERSION}.rom add \ + -r BOOTSPLASH \ + -f \"$LOGO\" \ + -n logo.bmp \ + -t raw \ + -c lzma" + if [ $? -eq 0 ]; then echo "Result binary placed in $PWD/protectli_$1_${FW_VERSION}.rom" sha256sum protectli_$1_${FW_VERSION}.rom > protectli_$1_${FW_VERSION}.rom.sha256