Procházet zdrojové kódy

swupdate: Fix DEPENDS, add libubootenv and efibootguard to RDEPENDS

Added features in commit `b8897ed` that runtime-dynamic bootloader selection
means using IMAGE_INSTALL += "swupdate" will not install libubootenv in rootfs
so swupdate will not run either

[TRACE] : SWUPDATE running :  [print_registered_bootloaders] : Registered bootloaders:
[TRACE] : SWUPDATE running :  [print_registered_bootloaders] :  uboot   shared lib not found.
[ERROR] : SWUPDATE failed [0] ERROR : Default bootloader interface 'uboot' couldn't be loaded.
[INFO ] : SWUPDATE running :  [main] : Check that the bootloader interface shared library is present.
[INFO ] : SWUPDATE running :  [main] : Or chose another bootloader interface by supplying -B <loader>.

Signed-off-by: He Yong <hyyoxhk@163.com>
Acked-by: Stefano Babic <sbabic@denx.de>
He Yong před 2 roky
rodič
revize
604e93240f
1 změnil soubory, kde provedl 5 přidání a 0 odebrání
  1. 5 0
      recipes-support/swupdate/swupdate.inc

+ 5 - 0
recipes-support/swupdate/swupdate.inc

@@ -131,6 +131,8 @@ python () {
 
 
     depends = d.getVar('DEPENDS', False)
+    pn = d.getVar('PN')
+    rdepends = d.getVar("RDEPENDS:%s" % pn) or ""
 
     if 'CONFIG_REMOTE_HANDLER=y\n' in features:
         depends += ' zeromq'
@@ -156,6 +158,7 @@ python () {
 
     if 'CONFIG_UBOOT=y\n' in features:
         depends += ' libubootenv'
+        rdepends += ' libubootenv'
 
     if 'CONFIG_DOWNLOAD=y\n' in features or 'CONFIG_SURICATTA=y\n' in features:
         depends += ' curl'
@@ -174,6 +177,7 @@ python () {
 
     if 'CONFIG_BOOTLOADER_EBG=y\n' in features:
         depends += ' efibootguard'
+        rdepends += ' efibootguard'
 
     if 'CONFIG_ZSTD=y\n' in features:
         depends += ' zstd'
@@ -185,6 +189,7 @@ python () {
         depends += ' zchunk'
 
     d.setVar('DEPENDS', depends)
+    d.setVar("RDEPENDS:%s" % pn, rdepends)
 
     if 'CONFIG_MONGOOSE=y\n' in features:
         d.setVar('SWUPDATE_MONGOOSE', 'true')