summaryrefslogtreecommitdiff
path: root/script
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2024-06-24 14:23:56 +0100
committerLeah Rowe <leah@libreboot.org>2024-06-24 14:23:56 +0100
commit19e7c1eabb3f1f00b8329c3832f239c75041b05d (patch)
tree18289c6228f757a8bf1a9d6e41c21168ba9e39ea /script
parent6468bdb3aa9501c2cc4abb38185dddb7bc779aa4 (diff)
trees: try xgcc build twice if first attempt fails
sometimes buildgcc just fails for like no reason. we had this the other day and another fix was made to the trees script, to mitigate; the user ran it again and buildgcc worked just fine. run it twice, and then call err only if the second one fails. Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'script')
-rwxr-xr-xscript/trees7
1 files changed, 5 insertions, 2 deletions
diff --git a/script/trees b/script/trees
index f0071d5e..2619892f 100755
--- a/script/trees
+++ b/script/trees
@@ -170,8 +170,11 @@ check_cross_compiler()
export CROSS_COMPILE="${xarch% *}-"
[ -n "$xlang" ] && export BUILD_LANGUAGES="$xlang"
- x_ make -C "$cbdir" crossgcc-${_xarch%-*} $cbmakeargs
- done
+ # sometimes buildgcc fails for like no reason. try twice.
+ make -C "$cbdir" crossgcc-${_xarch%-*} $cbmakeargs || \
+ make -C "$cbdir" crossgcc-${_xarch%-*} $cbmakeargs || \
+ $err "!mkxgcc $project/$xtree '${_xarch%-*}' '$cbmakeargs'"
+ done; return 0
}
check_coreboot_utils()