summaryrefslogtreecommitdiff
path: root/script/build/boot/roms
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2023-09-30 16:14:27 +0100
committerLeah Rowe <leah@libreboot.org>2023-09-30 16:14:27 +0100
commit49b266eb4248f87d111e9babae86a873300afa03 (patch)
tree91a5e024849c127077a26ba8dc2d9137f1b176c3 /script/build/boot/roms
parentd268f5eb28bc95b2d72bae022fce1768a5cb7147 (diff)
build/boot/roms: only do 1 custom kbd/payload/mode
-k, -p and -d let you set keymap, payload and displaymode respectively, but the handling for this is buggy when passing multiple arguments. Support only one argument, for simplicity. This is how people use them anyway, and it makes lbmk less buggy. Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'script/build/boot/roms')
-rwxr-xr-xscript/build/boot/roms14
1 files changed, 7 insertions, 7 deletions
diff --git a/script/build/boot/roms b/script/build/boot/roms
index d4261757..39c0eed6 100755
--- a/script/build/boot/roms
+++ b/script/build/boot/roms
@@ -13,18 +13,16 @@ set -u -e
. "include/boot.sh"
read projectname < projectname
-opts=""
-first=""
targets=""
# main() is in include/boot.sh
handle_targets()
{
- [ -z "${displaymodes}" ] || opts="-d \"${displaymodes}\" ${opts}"
- [ -z "${payloads}" ] || opts="-p \"${payloads}\" ${opts}"
- [ -z "${keyboard_layouts}" ] || \
- opts="-k \"${keyboard_layouts}\" ${opts}"
+ [ -z "${_displaymode}" ] || _displaymode="-d ${_displaymode}"
+ [ -z "${_payload}" ] || _payload="-p ${_payload}"
+ [ -z "${_keyboard_layout}" ] || \
+ _keyboard_layout="-k ${_keyboard_layout}"
printf "Building %s ROM images\n" "${projectname}"
@@ -46,8 +44,10 @@ check_targets()
build_bootroms()
{
+ opts="${_displaymode} ${_payload} ${_keyboard_layout}"
for x in ${boards}; do
- ./build boot roms_helper ${opts} ${x} || \
+ ./build boot roms_helper ${_displaymode} ${_payload} \
+ ${_keyboard_layout} ${x} || \
err "handle_targets ${opts} ${x}: build error"
[ -d "bin/${x}" ] && targets="${x} ${targets}"
done