diff mbox series

[4/4] systemd-boot: improve cross file generation

Message ID 20230809144917.3110384-4-ross.burton@arm.com
State New
Headers show
Series [1/4] meson.bbclass: add MESON_TARGET | expand

Commit Message

Ross Burton Aug. 9, 2023, 2:49 p.m. UTC
From: Ross Burton <ross.burton@arm.com>

The meson.cross generated by the class already has c and objcopy
entries, so these can be removed.

Pass the --cross-file option in MESON_CROSS_FILE to ensure the ordering
is always correct.

Signed-off-by: Ross Burton <ross.burton@arm.com>
---
 meta/recipes-core/systemd/systemd-boot_254.bb | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
diff mbox series

Patch

diff --git a/meta/recipes-core/systemd/systemd-boot_254.bb b/meta/recipes-core/systemd/systemd-boot_254.bb
index a490c0328e6..c32aa0ae125 100644
--- a/meta/recipes-core/systemd/systemd-boot_254.bb
+++ b/meta/recipes-core/systemd/systemd-boot_254.bb
@@ -12,22 +12,21 @@  LDFLAGS:prepend = "${@ " ".join(d.getVar('LD').split()[1:])} "
 
 EFI_LD = "bfd"
 
-do_write_config[vardeps] += "CC OBJCOPY EFI_LD"
+do_write_config[vardeps] += "EFI_LD"
 do_write_config:append() {
     cat >${WORKDIR}/meson-${PN}.cross <<EOF
 [binaries]
-c = ${@meson_array('CC', d)}
-objcopy = ${@meson_array('OBJCOPY', d)}
 c_ld = ${@meson_array('EFI_LD', d)}
 EOF
 }
 
+MESON_CROSS_FILE:append = " --cross-file ${WORKDIR}/meson-${PN}.cross"
+
 MESON_TARGET = "systemd-boot"
 
 EXTRA_OEMESON += "-Defi=true \
                   -Dbootloader=true \
                   -Dman=false \
-                  --cross-file ${WORKDIR}/meson-${PN}.cross \
                   "
 
 # install to the image as boot*.efi if its the EFI_PROVIDER,