From: Zhihang Wei <wzh@ilbers.de>
To: Gourav Singh <gouravsingh@siemens.com>, isar-users@googlegroups.com
Subject: Re: [PATCH v2] installer-add-rootfs: wait for full target image build via do_build
Date: Wed, 22 Apr 2026 12:28:20 +0200 [thread overview]
Message-ID: <12fb90b0-cd1a-429a-aac5-97111160b971@ilbers.de> (raw)
In-Reply-To: <20260421172147.4077796-1-gouravsingh@siemens.com>
Applied to next, thanks.
Zhihang
On 4/21/26 19:21, 'Gourav Singh' via isar-users wrote:
> Previously, the installer depended only on do_image_<type>, which was
> derived from IMAGE_DATA_POSTFIX (e.g. do_image_wic for wic.zst). This
> created a hidden ordering assumption that the image type being installed
> was also the last artifact to be built.
>
> This assumption breaks silently when target images include additional
> build steps that run after the wic image, such as swupdate (.swu)
> generation. In that case, the installer would start before all artifacts
> were ready, missing files like the .swu image entirely.
>
> Replace the derived do_image_<type> dependency with do_build, which is
> the natural synchronization point signaling that a recipe is fully done.
> This guarantees the installer only starts after all target image
> artifacts are produced, regardless of which features are enabled.
>
> As a result, the get_image_type() helper function is no longer needed
> and is removed.
>
> Fixes: a7364ea ("installer-add-rootfs: build target image for image data postfix")
>
> Signed-off-by: Gourav Singh <gouravsingh@siemens.com>
> ---
> meta-isar/classes-recipe/installer-add-rootfs.bbclass | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/meta-isar/classes-recipe/installer-add-rootfs.bbclass b/meta-isar/classes-recipe/installer-add-rootfs.bbclass
> index 69d87be8..111506df 100644
> --- a/meta-isar/classes-recipe/installer-add-rootfs.bbclass
> +++ b/meta-isar/classes-recipe/installer-add-rootfs.bbclass
> @@ -56,10 +56,6 @@ def get_mc_depends(d, task):
> deps.append(f"mc:{installer_mc}:{installer_target_mc}:{image}:{task}")
> return " ".join(deps)
>
> -def get_image_type(suffix):
> - image_type = suffix.split(".")[0]
> - return f"{image_type}"
> -
> python() {
> entries = []
>
> @@ -80,5 +76,5 @@ python() {
> d.setVar("ROOTFS_ADDITIONAL_FILES", " ".join(entries))
> }
>
> -INSTALLER_TARGET_TASK ??="do_image_${@ get_image_type(d.getVar('IMAGE_DATA_POSTFIX'))}"
> +INSTALLER_TARGET_TASK ??="do_build"
> do_rootfs_install[mcdepends] += "${@ get_mc_depends(d, d.getVar('INSTALLER_TARGET_TASK'))}"
> --
> 2.39.5
>
--
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/12fb90b0-cd1a-429a-aac5-97111160b971%40ilbers.de.
prev parent reply other threads:[~2026-04-22 10:28 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-21 17:21 'Gourav Singh' via isar-users
2026-04-22 10:28 ` Zhihang Wei [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=12fb90b0-cd1a-429a-aac5-97111160b971@ilbers.de \
--to=wzh@ilbers.de \
--cc=gouravsingh@siemens.com \
--cc=isar-users@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox