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>
This commit is contained in:
Leah Rowe
2023-09-30 16:14:27 +01:00
parent d268f5eb28
commit 49b266eb42
3 changed files with 24 additions and 31 deletions
+7 -6
View File
@@ -3,11 +3,12 @@
# SPDX-FileCopyrightText: 2022 Ferass El Hafidi <vitali64pmemail@protonmail.com>
# SPDX-FileCopyrightText: 2023 Leah Rowe <leah@libreboot.org>
first=""
board=""
boards=""
displaymodes=""
payloads=""
keyboard_layouts=""
_displaymode=""
_payload=""
_keyboard_layout=""
main()
{
@@ -21,13 +22,13 @@ main()
while [ $# -gt 0 ]; do
case ${1} in
-d)
displaymodes="${2} ${displaymodes}"
_displaymode="${2}"
shift ;;
-p)
payloads="${2} ${payloads}"
_payload="${2}"
shift ;;
-k)
keyboard_layouts="${2} ${keyboard_layouts}"
_keyboard_layout="${2}"
shift ;;
all)
first="all" ;;