From 0e0760bba942776b8f7256aff2b7807cbdd29d2d Mon Sep 17 00:00:00 2001 From: Mikhail Chusavitin Date: Sat, 7 Mar 2026 11:59:37 +0300 Subject: [PATCH] build: always nuke apks_* cache to prevent stale package errors MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Stale apks_* dirs (from old mirror or previous version pin) cause "unable to select package" failures. Nuke them on every build. kernel_*, syslinux_*, grub_* are still preserved — they're large, stable, and only need to change when KERNEL_PKG_VERSION changes. Co-Authored-By: Claude Sonnet 4.6 --- iso/builder/build.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/iso/builder/build.sh b/iso/builder/build.sh index 7745176..c21987d 100755 --- a/iso/builder/build.sh +++ b/iso/builder/build.sh @@ -181,11 +181,11 @@ cp "${BUILDER_DIR}/genapkovl-bee.sh" "${HOME}/.mkimage/" # Export overlay dir so the profile script can find it regardless of SRCDIR. export BEE_OVERLAY_DIR="${OVERLAY_DIR}" -# Clean workdir selectively: remove everything except apks cache so packages aren't re-downloaded. -# mkimage stores each section in a hash-named subdir; apks_* dirs contain downloaded packages. +# Clean workdir: always nuke apks_* (stale packages from old mirror/version cause "unable to select" errors). +# Keep kernel_*, syslinux_*, grub_* — these are large but stable; they only change when KERNEL_PKG_VERSION changes. if [ -d /var/tmp/bee-iso-work ]; then find /var/tmp/bee-iso-work -maxdepth 1 -mindepth 1 \ - -not -name 'apks_*' -not -name 'kernel_*' \ + -not -name 'kernel_*' \ -not -name 'syslinux_*' -not -name 'grub_*' \ -exec rm -rf {} + 2>/dev/null || true fi