diff options
author | Leah Rowe <leah@libreboot.org> | 2023-10-06 03:03:31 +0100 |
---|---|---|
committer | Leah Rowe <leah@libreboot.org> | 2023-10-06 03:03:31 +0100 |
commit | 5494ffb3d10b66de8723d1c841a25e404d4885bd (patch) | |
tree | 3af7c04f0df2f89d20722514fe0d5615b51843ea /script/build | |
parent | ce10c1b38c6ed2137803e37e8a69e7eecd5ce61d (diff) |
build/firmware/coreboot: confirm compiled roms
return with error status if no images were compiled
if a rom image fails to compile, then it will also
exit with error status, but sometimes you can pass
argument "cros" or "default", and it would not give
you rom images due to no target.cfg files, but these
are also ignored because of that.
this restores the same behaviour that existed before,
for this final error check.
Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'script/build')
-rwxr-xr-x | script/build/firmware/coreboot | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/script/build/firmware/coreboot b/script/build/firmware/coreboot index bfc059a5..15430255 100755 --- a/script/build/firmware/coreboot +++ b/script/build/firmware/coreboot @@ -28,7 +28,7 @@ v="romdir cbdir cbfstool cbrom initmode displaymode cbcfg targetdir tree arch" v="${v} grub_timeout ubdir blobs_required board grub_scan_disk uboot_config" eval "$(setvars "n" ${pv})" eval "$(setvars "" ${v})" -eval "$(setvars "" boards _displaymode _payload _keyboard all)" +eval "$(setvars "" boards _displaymode _payload _keyboard all targets)" main() { @@ -56,8 +56,13 @@ main() eval "$(setvars "" ${v})" board="${x}" check_target - prepare_target + prepare_target + [ -f "bin/${x}" ] || continue + targets="bin/${x}\n${targets}" done + + [ -z ${targets} ] && err "No ROM images were compiled" + printf "ROM images available in these directories:\n${targets%, }\n" } check_target() |