proot build: fall back to Debian's copy of talloc when samba.org is down

samba.org has been timing out and returning 504s, which fails
native-proot/build.sh and with it the APK build and LinuxUiTest. Try
Debian's copy of the same tarball after it; the SHA-256 check still
covers whichever one is downloaded.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01B82eRVHnHRzok8eDG2idnz
This commit is contained in:
Claude committed 2026-10-29 12:40:26 +00:00
1 parent d435187ee5
commit 4b08994783
1 file changed
+7 -1
+7 -1
View File
@@ -61,8 +61,14 @@ export PATH
# talloc: its one source file, with the little of Samba's lib/replace it uses
TARBALL=$WORK/talloc-$TALLOC_VERSION.tar.gz
# (samba.org first, Debian's copy of the same tarball when it is down; the checksum below checks either)
if [ ! -f "$TARBALL" ]; then
curl -fsSL -o "$TARBALL.part" "https://www.samba.org/ftp/talloc/talloc-$TALLOC_VERSION.tar.gz"
for url in "https://www.samba.org/ftp/talloc/talloc-$TALLOC_VERSION.tar.gz" \
"https://deb.debian.org/debian/pool/main/t/talloc/talloc_$TALLOC_VERSION.orig.tar.gz"; do
curl -fsSL --connect-timeout 20 --max-time 120 -o "$TARBALL.part" "$url" && break
rm -f "$TARBALL.part"
done
[ -f "$TARBALL.part" ] || { echo "talloc $TALLOC_VERSION couldn't be downloaded" >&2; exit 1; }
mv "$TARBALL.part" "$TARBALL"
fi
echo "$TALLOC_SHA256 $TARBALL" | sha256sum -c - >/dev/null || { echo "talloc's checksum doesn't match" >&2; rm -f "$TARBALL"; exit 1; }