]> code.ossystems Code Review - openembedded-core.git/commitdiff
u-boot: Package extlinux.conf separately
authorPaul Barker <paul@pbarker.dev>
Mon, 9 Aug 2021 19:20:42 +0000 (20:20 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 13 Aug 2021 13:44:01 +0000 (14:44 +0100)
A separate u-boot-extlinux package is created for the extlinux.conf file
so that it can be installed on its own if needed. If this package is
populated, it is added as a dependency of the main u-boot package so
that installing just u-boot still results in the extlinux.conf file
being present in the rootfs.

Signed-off-by: Paul Barker <paul@pbarker.dev>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-bsp/u-boot/u-boot.inc

index 4340b17cb632904e6e5a3c2e21893751d8b64fbd..971fdbb102dbcc074073472f69a2ca1841dbf944 100644 (file)
@@ -210,7 +210,7 @@ do_install () {
     fi
 }
 
-PACKAGE_BEFORE_PN += "${PN}-env"
+PACKAGE_BEFORE_PN += "${PN}-env ${PN}-extlinux"
 
 RPROVIDES:${PN}-env += "u-boot-default-env"
 ALLOW_EMPTY:${PN}-env = "1"
@@ -219,6 +219,9 @@ FILES:${PN}-env = " \
     ${sysconfdir}/fw_env.config \
 "
 
+FILES:${PN}-extlinux = "${UBOOT_EXTLINUX_INSTALL_DIR}/${UBOOT_EXTLINUX_CONF_NAME}"
+RDEPENDS:${PN} += "${@bb.utils.contains('UBOOT_EXTLINUX', '1', '${PN}-extlinux', '', d)}"
+
 FILES:${PN} = "/boot ${datadir}"
 RDEPENDS:${PN} += "${PN}-env"