diff mbox series

[meta-ti,master/scarthgap] u-boot-ti: Move UBOOT_VERSION into dynamic layer

Message ID 20250709161437.4707-1-reatmon@ti.com
State Accepted
Delegated to: Ryan Eatmon
Headers show
Series [meta-ti,master/scarthgap] u-boot-ti: Move UBOOT_VERSION into dynamic layer | expand

Commit Message

Ryan Eatmon July 9, 2025, 4:14 p.m. UTC
The gitpkgv class we are using to set UBOOT_VERSION is located in
meta-openembedded.  We do not want to depend on meta-openembedded to
keep meta-ti-bsp as light as possible, and the naming of UBOOT_VERSION
is not a requirement, just a nice to have.  Dynamic layers allow us to
use the class if it is available in the build, but not require it.

Signed-off-by: Ryan Eatmon <reatmon@ti.com>
---
 meta-ti-bsp/conf/layer.conf                               | 8 ++++++++
 .../recipes-bsp/u-boot/u-boot-ti-%.bbappend               | 5 +++++
 meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti.inc              | 4 ----
 3 files changed, 13 insertions(+), 4 deletions(-)
 create mode 100644 meta-ti-bsp/dynamic-layers/openembedded-layer/recipes-bsp/u-boot/u-boot-ti-%.bbappend
diff mbox series

Patch

diff --git a/meta-ti-bsp/conf/layer.conf b/meta-ti-bsp/conf/layer.conf
index 481daf2c..cbf7f509 100644
--- a/meta-ti-bsp/conf/layer.conf
+++ b/meta-ti-bsp/conf/layer.conf
@@ -18,6 +18,14 @@  LAYERDEPENDS_meta-ti-bsp = " \
     meta-arm \
 "
 
+LAYERRECOMMENDS_meta-ti-bsp = " \
+    openembedded-layer \
+"
+
+BBFILES_DYNAMIC += " \
+    openembedded-layer:${LAYERDIR}/dynamic-layers/openembedded-layer/recipes*/*/*.bbappend \
+"
+
 SIGGEN_EXCLUDERECIPES_ABISAFE += " \
     mesa-pvr \
 "
diff --git a/meta-ti-bsp/dynamic-layers/openembedded-layer/recipes-bsp/u-boot/u-boot-ti-%.bbappend b/meta-ti-bsp/dynamic-layers/openembedded-layer/recipes-bsp/u-boot/u-boot-ti-%.bbappend
new file mode 100644
index 00000000..0f91e37e
--- /dev/null
+++ b/meta-ti-bsp/dynamic-layers/openembedded-layer/recipes-bsp/u-boot/u-boot-ti-%.bbappend
@@ -0,0 +1,5 @@ 
+
+inherit gitpkgv
+PKGV = "${PV}${GITPKGV}"
+UBOOT_VERSION = "${PKGV}-${PKGR}"
+
diff --git a/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti.inc b/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti.inc
index 8a000331..642bb6cd 100644
--- a/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti.inc
+++ b/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti.inc
@@ -5,10 +5,6 @@  do_compile:prepend () {
     echo ${scm_version} > ${S}/.scmversion
 }
 
-inherit gitpkgv
-PKGV = "${PV}${GITPKGV}"
-UBOOT_VERSION = "${PKGV}-${PKGR}"
-
 UBOOT_SUFFIX ?= "img"
 SPL_BINARY ?= "MLO"