All of lore.kernel.org
 help / color / mirror / Atom feed
From: dbaryshkov@gmail.com
To: openembedded-core@lists.openembedded.org
Cc: Dmitry Eremin-Solenikov <dmitry_eremin-solenikov@mentor.com>
Subject: [PATCH 5/9] systemd-boot: switch to uefi.bbclass
Date: Wed, 11 Sep 2019 12:29:57 +0300	[thread overview]
Message-ID: <20190911093001.7849-5-dbaryshkov@gmail.com> (raw)
In-Reply-To: <20190911093001.7849-1-dbaryshkov@gmail.com>

From: Dmitry Eremin-Solenikov <dmitry_eremin-solenikov@mentor.com>

Use variables from uefi.bbclass instead of hardcoding them in the recipe.

Signed-off-by: Dmitry Eremin-Solenikov <dmitry_eremin-solenikov@mentor.com>
---
 meta/recipes-core/systemd/systemd-boot_242.bb | 15 ++++++---------
 1 file changed, 6 insertions(+), 9 deletions(-)

diff --git a/meta/recipes-core/systemd/systemd-boot_242.bb b/meta/recipes-core/systemd/systemd-boot_242.bb
index 56a25c35babc..3cb05db345ff 100644
--- a/meta/recipes-core/systemd/systemd-boot_242.bb
+++ b/meta/recipes-core/systemd/systemd-boot_242.bb
@@ -1,6 +1,8 @@
 require systemd.inc
 FILESEXTRAPATHS =. "${FILE_DIRNAME}/systemd:"
 
+inherit uefi
+
 DEPENDS = "intltool-native libcap util-linux gnu-efi gperf-native"
 
 # NOTE: These three patches are in theory not needed, but we haven't
@@ -33,16 +35,13 @@ python __anonymous () {
     import re
     target = d.getVar('TARGET_ARCH')
     prefix = "" if d.getVar('EFI_PROVIDER') == "systemd-boot" else "systemd-"
-    if target == "x86_64":
-        systemdimage = prefix + "bootx64.efi"
-    else:
-        systemdimage = prefix + "bootia32.efi"
+    systemdimage = prefix + d.getVar("EFI_BOOT_IMAGE")
     d.setVar("SYSTEMD_BOOT_IMAGE", systemdimage)
     prefix = "systemd-" if prefix == "" else ""
     d.setVar("SYSTEMD_BOOT_IMAGE_PREFIX", prefix)
 }
 
-FILES_${PN} = "/boot/EFI/BOOT/${SYSTEMD_BOOT_IMAGE}"
+FILES_${PN} = "${EFI_FILES_PATH}/${SYSTEMD_BOOT_IMAGE}"
 
 RDEPENDS_${PN} += "virtual/systemd-bootconf"
 
@@ -61,10 +60,8 @@ do_compile() {
 }
 
 do_install() {
-	install -d ${D}/boot
-	install -d ${D}/boot/EFI
-	install -d ${D}/boot/EFI/BOOT
-	install ${B}/src/boot/efi/systemd-boot*.efi ${D}/boot/EFI/BOOT/${SYSTEMD_BOOT_IMAGE}
+	install -d ${D}${EFI_FILES_PATH}
+	install ${B}/src/boot/efi/systemd-boot*.efi ${D}${EFI_FILES_PATH}/${SYSTEMD_BOOT_IMAGE}
 }
 
 do_deploy () {
-- 
2.23.0



  parent reply	other threads:[~2019-09-11  9:30 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-11  9:29 [PATCH 1/9] uefi.bbclass: add bbclass holding configuration for UEFI applications dbaryshkov
2019-09-11  9:29 ` [PATCH 2/9] grub-bootconf: switch to uefi.bbclass dbaryshkov
2019-09-11  9:29 ` [PATCH 3/9] grub-efi: " dbaryshkov
2019-09-11  9:29 ` [PATCH 4/9] grub-efi.bbclass: " dbaryshkov
2019-09-11  9:29 ` dbaryshkov [this message]
2019-09-11  9:29 ` [PATCH 6/9] systemd-boot.bbclass: " dbaryshkov
2019-09-11  9:29 ` [PATCH 7/9] uefi.bbclass: provide efi population functions for live images dbaryshkov
2019-09-11  9:30 ` [PATCH 8/9] grub-efi.bbclass: use efi_*_populate_common dbaryshkov
2019-09-11  9:30 ` [PATCH 9/9] systemd-boot.bbclass: " dbaryshkov
2019-09-12 23:12 ` [PATCH 1/9] uefi.bbclass: add bbclass holding configuration for UEFI applications Mittal, Anuj
2019-09-13 11:59   ` Dmitry Eremin-Solenikov
2019-09-13  2:14 ` Ang, Chin Huat
2019-09-13 12:06   ` Dmitry Eremin-Solenikov

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=20190911093001.7849-5-dbaryshkov@gmail.com \
    --to=dbaryshkov@gmail.com \
    --cc=dmitry_eremin-solenikov@mentor.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.