Re: [isar-cip-core][PATCH] efibootguard-efi: Use correct search path for the efibinary

Jan Kiszka

On 24.05.22 17:38, Gylstorff Quirin wrote:

On 5/24/22 17:23, Quirin Gylstorff via wrote:

On 5/24/22 17:07, Jan Kiszka wrote:
On 24.05.22 16:57, Quirin Gylstorff wrote:
From: Quirin Gylstorff <quirin.gylstorff@...>

This fixes the build error:
ERROR: _exec_cmd: cp /usr/share/efibootguard/efibootguardx64.efi
returned '1' instead of 0
output: cp: cannot stat
'/usr/share/efibootguard/efibootguardx64.efi': No such file or

Signed-off-by: Quirin Gylstorff <quirin.gylstorff@...>
  scripts/lib/wic/plugins/source/ | 6 ++++--
  1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/scripts/lib/wic/plugins/source/
index e1411cb..a01e484 100644
--- a/scripts/lib/wic/plugins/source/
+++ b/scripts/lib/wic/plugins/source/
@@ -59,8 +59,10 @@ class EfibootguardEFIPlugin(SourcePlugin):
          distro_arch = get_bitbake_var("DISTRO_ARCH")
-        bootloader =
-            distro_to_efi_arch[distro_arch])
+        rootfs_path = rootfs_dir.get('ROOTFS_DIR')
+        bootloader =

+            rootfs_path=rootfs_path,
+            efiarch=distro_to_efi_arch[distro_arch])
          part_rootfs_dir = "%s/disk/%s.%s" % (cr_workdir,
Makes sense in first sight - but why did it work so far? Or did I miss
to test one of the two cases (signed/unsigned)? Did you test both?

I am still try to find the reason why it work in isar-cip-core. The
error occured in a downstream project.
In isar-cip-core the error never occured as we install `efibootguard`
as a dependency for wic[1].

efibootguard-boot uses the same logic[2] to access the kernel stub.

We should decide which is the correct way. I would prefer that we take
both stubs from the buildchroot.
Yes, the preferred source for bootloader artifacts should be the
buildchroot and NOT that target image. We are currently installing more
on the target as practically needed. If that should ever change, things
shouldn't break here at plugin level.




Siemens AG, Technology
Competence Center Embedded Linux

Join to automatically receive all group messages.