Source: efitools Version: 1.9.2-3 Tags: patch User: debian-cr...@lists.debian.org Usertags: ftcbfs
efitools cannot be cross built from source, because it uses build architecture aspects. The ARCH variable is detected from uname and LD and OBJCOPY are also for the build architecture. I'm attaching a patch to fix these for your conveniecne. Once fixing these, you can see this: ./cert-to-efi-sig-list -g 11111111-2222-3333-4444-123456789abc PK.crt PK.esl ./cert-to-efi-sig-list: 1: Syntax error: word unexpected (expecting ")") This looks a little more involved. It is running a tool that has just been built. It is not clear to me whether this tool behaves in an architecture-independent way and we can maybe use a self dependency. It also is not clear to me whether we have to run it at all during build given that yocto patched this out. Could you shed some light on this invocation? Helmut
diff --minimal -Nru efitools-1.9.2/debian/changelog efitools-1.9.2/debian/changelog --- efitools-1.9.2/debian/changelog 2022-06-17 01:53:21.000000000 +0200 +++ efitools-1.9.2/debian/changelog 2022-11-06 20:33:39.000000000 +0100 @@ -1,3 +1,10 @@ +efitools (1.9.2-3.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Improve cross building: Pass ARCH, LD, OBJCOPY. (Closes: #-1) + + -- Helmut Grohne <hel...@subdivi.de> Sun, 06 Nov 2022 20:33:39 +0100 + efitools (1.9.2-3) unstable; urgency=medium [ Bo YU ] diff --minimal -Nru efitools-1.9.2/debian/rules efitools-1.9.2/debian/rules --- efitools-1.9.2/debian/rules 2022-05-24 19:48:58.000000000 +0200 +++ efitools-1.9.2/debian/rules 2022-11-06 20:33:39.000000000 +0100 @@ -4,6 +4,18 @@ # Uncomment this to turn on verbose mode. export DH_VERBOSE=1 +include /usr/share/dpkg/architecture.mk +include /usr/share/dpkg/buildtools.mk + +ifeq ($(DEB_HOST_ARCH_CPU),i386)) +ARCH=ia32 +else +ARCH=$(DEB_HOST_GNU_CPU) +endif + +override_dh_auto_build: + dh_auto_build -- ARCH=$(ARCH) LD=$(LD) OBJCOPY=$(OBJCOPY) + override_dh_auto_install: dh_auto_install -- EFIDIR="debian/efitools/usr/lib/efitools/${DEB_TARGET_MULTIARCH}"