Raul Rangel has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/35137 )
Change subject: util/abuild: Have abuild generate the .xcompile if it doesn't exist ......................................................................
util/abuild: Have abuild generate the .xcompile if it doesn't exist
Previously if .xcompile was missing, abuild would silently ignore the error. With https://review.coreboot.org/c/coreboot/+/34241 we now check the return code so abuild started failing.
We should generate the .xcompile if it doesn't exist. The Makefile will handle that so we include it as the first Makefile.
We then need to override the default target so we don't use the one from the Makefile.
BUG=b:112267918 TEST=ran abuild and made sure it generated a .xcompile in the root.
Change-Id: I79ded36d47b0219d0b126adff80a57be1c2bdf07 Signed-off-by: Raul E Rangel rrangel@chromium.org --- M util/abuild/abuild 1 file changed, 3 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/37/35137/1
diff --git a/util/abuild/abuild b/util/abuild/abuild index 4a62cfa..23b22aa 100755 --- a/util/abuild/abuild +++ b/util/abuild/abuild @@ -471,13 +471,14 @@ required_arches=$(grep -E "^CONFIG_ARCH_(BOOTBLOCK|R.MSTAGE|VERSTAGE)" "$TARGET/${BUILD_NAME}/config.build" | \ sed "s,^CONFIG_ARCH_[^_]*_([^=]*)=.*$,\1," |sort -u |tr 'A-Z\n\r' 'a-z ')
- missing_arches="$($MAKE --no-print-directory -f - \ - REQUIRED_ARCHES="$required_arches" <<'EOF' + missing_arches="$($MAKE --no-print-directory -f Makefile -f - \ + REQUIRED_ARCHES="$required_arches" obj="${build_dir}" <<'EOF' include .xcompile .PHONY: missing_arches missing_arches: $(if $(XCOMPILE_COMPLETE),,$(error .xcompile is invalid.)) @echo $(foreach arch,$(REQUIRED_ARCHES),$(if $(filter $(arch),$(SUBARCH_SUPPORTED)),,$(arch))) +.DEFAULT_GOAL := missing_arches EOF )" # shellcheck disable=SC2181