public inbox for poky@lists.yoctoproject.org
 help / color / mirror / Atom feed
From: Trevor Woerner <twoerner@gmail.com>
To: poky@lists.yoctoproject.org
Subject: [meta-yocto-bsp][PATCH] meta-yocto-bsp: oeqa/selftest/systemd_boot: update for standalone wic
Date: Wed,  4 Feb 2026 09:46:00 -0500	[thread overview]
Message-ID: <20260204144600.514629-1-twoerner@gmail.com> (raw)

The systemd_boot.Systemdboot.test_efi_systemdboot_images_can_be_built
oe-selftest invokes the wic utility. If wic is removed from oe-core,
how it is invoked would need to be updated. However, updating how it is
invoked will also succeed even if wic continues to be part of oe-core;
it is simply a more elaborate way to invoke wic which works in either
case.

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
---
 meta-yocto-bsp/lib/oeqa/selftest/cases/systemd_boot.py | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/meta-yocto-bsp/lib/oeqa/selftest/cases/systemd_boot.py b/meta-yocto-bsp/lib/oeqa/selftest/cases/systemd_boot.py
index 961d4ea31d0c..d727432d311f 100644
--- a/meta-yocto-bsp/lib/oeqa/selftest/cases/systemd_boot.py
+++ b/meta-yocto-bsp/lib/oeqa/selftest/cases/systemd_boot.py
@@ -60,10 +60,12 @@ class Systemdboot(OESelftestTestCase):
         if os.path.isfile(imagebootfile):
             runCmd('rm -f %s' % imagebootfile)
 
-        sysroot = get_bb_var('RECIPE_SYSROOT_NATIVE', 'wic-tools')
-
-        runCmd('wic cp %s:1/EFI/BOOT/bootx64.efi %s -n %s' % (systemdbootimage,
-                                                           imagebootfile, sysroot))
+        oldpath = os.environ['PATH']
+        os.environ['PATH'] = get_bb_var('PATH', 'wic-tools') + ':' + os.environ['PATH']
+        envfile = os.path.join(get_bb_var('STAGING_DIR', image), 'genericx86-64', 'imgdata', image) + '.env'
+        runCmd('wic cp %s:1/EFI/BOOT/bootx64.efi %s --vars %s' % (systemdbootimage,
+                                                                  imagebootfile, envfile))
+        os.environ['PATH'] = oldpath
 
         found = os.path.isfile(imagebootfile)
         self.assertTrue(found, 'bootx64.efi file %s was not copied from image'
-- 
2.51.0



                 reply	other threads:[~2026-02-04 14:46 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20260204144600.514629-1-twoerner@gmail.com \
    --to=twoerner@gmail.com \
    --cc=poky@lists.yoctoproject.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