Skip to content

usr: clear the attach manifest on do_clean so clean+build is reliable#266

Merged
daniel-rossier merged 1 commit into
mainfrom
usr/clean-attach-manifest
Jul 6, 2026
Merged

usr: clear the attach manifest on do_clean so clean+build is reliable#266
daniel-rossier merged 1 commit into
mainfrom
usr/clean-attach-manifest

Conversation

@daniel-rossier

Copy link
Copy Markdown
Contributor

Fixes the recurring Refusing to re-attach usr-so3 failure on build.sh -xc bsp-so3 (and any usr recipe) when a build mutates the attached tree in place — notably the :lvgl override, which fetches lib/lvgl and renames its stray CMakeLists.txt to hide them from the recursive CMake glob. Those renames make do_attach_infrabase's sha256sum -c report the manifest entries as FAILED on the next attach.

Generic fix in meta-usr/classes/usr.bbclass:do_clean (not per-recipe): drop ${IB_TARGET}.attach.sha256 on clean so the next attach re-attaches fresh. Safe — a clean is an explicit reset, the attach still keeps ${IB_TARGET}.back, and the guard stays active for builds not preceded by a clean.

Validated: build.sh -xc bsp-so3 with :lvgl now succeeds on two consecutive runs (previously failed on the 2nd).

Generic meta-usr fix. The usr build mutates the attached tree (IB_TARGET)
in place — e.g. the :lvgl override fetches lib/lvgl and renames its stray
CMakeLists.txt (-> __CMakeLists.txt__) to hide them from the recursive CMake
glob. Those renames/removals make the next do_attach_infrabase abort:
'sha256sum -c ${IB_TARGET}.attach.sha256' reports the manifest's original
entries as FAILED (renamed/missing) -> 'Refusing to re-attach usr-so3'.

Clear the manifest in usr.bbclass:do_clean (applies to every usr recipe:
usr-so3, usr-linux) so the next attach re-attaches from a fresh fetch+patch
instead of checking stale entries. A clean is an explicit reset and the attach
still backs the tree up to ${IB_TARGET}.back; the guard stays fully active for
builds NOT preceded by a clean.

Validated: 'build.sh -xc bsp-so3' (clean+build, :lvgl) now succeeds repeatedly
(was failing on the 2nd run).
@daniel-rossier daniel-rossier merged commit 3cc01c5 into main Jul 6, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant