Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Trevor Woerner <twoerner@gmail.com>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH v5 0/6] wic: ship the tools it invokes
Date: Fri, 31 Jul 2026 11:28:04 -0400	[thread overview]
Message-ID: <20260731152810.2641327-1-twoerner@gmail.com> (raw)

wic shells out to a range of host tools but does not declare them, so
wherever it is installed as a package it works only by chance depending
on what the host has installed. The do_image_wic task does not have that
problem: image_types_wic.bbclass makes the image recipe depend on the
-native recipe of each tool, so they are all in the image's own native
sysroot by the time wic runs. Nothing outside that task gets the same
treatment.

Patch 1 narrows wic-tools to staging wic's host tools: the target
bootloader firmware (syslinux, grub-efi, systemd-boot) it depended on
for the wic oe-selftest is now built by that oe-selftest instead. Which
firmware is needed depends on the plugins a .wks uses, so it belongs to
whoever supplies the .wks, not to wic-tools. Images already work that
way through WKS_FILE_DEPENDS in image_types_wic.bbclass, and now the
oe-selftest does too.

Patch 2 gives that tool list a single home. It was written out three
times -- in wic-tools, in image_types_wic.bbclass and (as of patch 3)
in the wic recipe -- and the copies had already drifted.

Patch 3 makes wic declare the host tools it runs as RDEPENDS, so they
are installed alongside it in every variant that packages it.

Patches 4 and 5 are follow-on cleanups of the wic oe-selftest: drop a
dead in-tree wic lookup, and drop the redundant per-test PATH overrides
that duplicated what the test setup already establishes.

Patch 6 fixes a dependency that has been on the wrong axis since 2019:
an image depends on syslinux-native when the build host is x86, but it
is the target that decides whether a .wks needs it, so an x86 image
built on a non-x86 host ends up with the bootloader but not the
installer. That is bug 16383, which carries the full history:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=16383

Should wic-tools be renamed? Nothing but the wic oe-selftest has used it
since 2017, when do_image_wic stopped depending on it, and it already
sits in meta/recipes-core/meta/ alongside meta-environment,
meta-ide-support and meta-toolchain without following their naming.
meta-wic-support would fit better, but it is a user-visible rename, so I
would rather hear objections before doing it.

changes in v5:
- the SDK_FEATURES half of the v4 series (patches 5 to 10) is not here.
  Reworking it to resolve features at the class level, as review asked,
  turned it into a larger piece of work than the wic changes it was
  travelling with, so it is being finished and sent as its own series.
- new patch 2: one shared list of the tools wic runs, replacing the
  three copies that had drifted apart. Images gain tar-native and
  util-linux-native, which only wic-tools staged before.
- new patch 6: gate syslinux-native on the target rather than the build
  host [YOCTO #13276]
- wic RDEPENDS patch: drop the bootloader (grub, syslinux) RDEPENDS
  entirely; wic declares only the host tools it runs. The bootloader
  firmware wic copies into an image is the responsibility of whatever
  drives wic (the oe-selftest, and image_types_wic.bbclass via
  WKS_FILE_DEPENDS), not of the wic package. This also removes the
  arch-gating that the v4 grub/syslinux RDEPENDS required.
- drastically trimmed the commit messages and in-tree comments
  throughout the series

changes in v4:
- new patch 1: move the target bootloader firmware out of wic-tools and
  stage it from the wic oe-selftest instead, so wic-tools carries only
  the host tools wic runs
- new selftest cleanups (drop the dead COREBASE/scripts wic lookup and
  the redundant per-test PATH overrides)

changes in v3:
- list the tools on all variants rather than only the nativesdk variant

changes in v2:
- dropped the wic-tools.inc refactor; folded the tool list into the wic
  recipe
- reworked the buildtools-extended-tarball change into a plain removal

Trevor Woerner (6):
  wic-tools: drop the target bootloader firmware
  wic: add a shared helper tool list
  wic: add runtime dependencies on the tools it invokes
  oeqa/selftest/wic: drop dead COREBASE/scripts wic lookup
  oeqa/selftest/wic: drop redundant per-test PATH overrides
  wic: gate syslinux-native on the target, not the build host

 meta/classes-recipe/image_types_wic.bbclass |   8 +-
 meta/conf/wic-helper-tools.inc              |  22 +
 meta/lib/oeqa/selftest/cases/wic.py         | 842 +++++++++-----------
 meta/recipes-core/meta/wic-tools.bb         |  12 +-
 meta/recipes-support/wic/wic_0.3.1.bb       |   3 +
 5 files changed, 425 insertions(+), 462 deletions(-)
 create mode 100644 meta/conf/wic-helper-tools.inc

-- 
2.50.0.173.g8b6f19ccfc3a



             reply	other threads:[~2026-07-31 15:28 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-31 15:28 Trevor Woerner [this message]
2026-07-31 15:28 ` [PATCH v5 1/6] wic-tools: drop the target bootloader firmware Trevor Woerner
2026-07-31 15:28 ` [PATCH v5 2/6] wic: add a shared helper tool list Trevor Woerner
2026-07-31 15:28 ` [PATCH v5 3/6] wic: add runtime dependencies on the tools it invokes Trevor Woerner
2026-07-31 15:28 ` [PATCH v5 4/6] oeqa/selftest/wic: drop dead COREBASE/scripts wic lookup Trevor Woerner
2026-07-31 15:28 ` [PATCH v5 5/6] oeqa/selftest/wic: drop redundant per-test PATH overrides Trevor Woerner
2026-07-31 15:28 ` [PATCH v5 6/6] wic: gate syslinux-native on the target, not the build host Trevor Woerner

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=20260731152810.2641327-1-twoerner@gmail.com \
    --to=twoerner@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    /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