From 200accc8560e1567fc4b0fe1d76ccfc22cf2d168 Mon Sep 17 00:00:00 2001 From: Johannes Schauer Marin Rodrigues <josch@mister-muffin.de> Date: Sun, 1 Jan 2023 08:42:37 +0100 Subject: [PATCH] build.sh: retry 'native' box64 build if cross-build failed --- build.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/build.sh b/build.sh index aa4dfa4..f88e091 100755 --- a/build.sh +++ b/build.sh @@ -183,7 +183,13 @@ if [ -z "$(reprepro listfilter reform "\$Source (== box64)")" ]; then git checkout upstream git checkout master pristine-tar checkout ../box64_0.1.8.orig.tar.xz - sbuild --host="$HOST_ARCH" --no-arch-all --arch-any $COMMON_SBUILD_OPTS --extra-repository="$SRC_LIST_PATCHED" + ret=0 + sbuild --host="$HOST_ARCH" --arch-all --arch-any $COMMON_SBUILD_OPTS --extra-repository="$SRC_LIST_PATCHED" || ret=$? + if [ "$ret" -ne 0 ]; then + # cross building failed -- try building + # "natively" with qemu-user + sbuild --build="$HOST_ARCH" --host="$HOST_ARCH" --arch-all --arch-any $COMMON_SBUILD_OPTS --extra-repository="$SRC_LIST_PATCHED" + fi reprepro include "$OURSUITE" ../box64_0.1.8-1_arm64.changes cd .. ) -- GitLab