@@ -18,8 +18,7 @@ S = "${WORKDIR}/git"
CPSW9G_FW_DIR = "${S}/ethfw"
CPSW9G_FW_FILENAME = "app_remoteswitchcfg_server_pdk_mem_map_strip.xer5f"
-# make sure that lib/firmware, and all its contents are part of the package
-FILES:${PN} += "${nonarch_base_libdir}/firmware"
+require recipes-bsp/ti-linux-fw/firmware-common.inc
do_install() {
install -d ${D}${nonarch_base_libdir}/firmware
@@ -32,10 +31,3 @@ ALTERNATIVE:${PN} = "j7-main-r5f0_0-fw"
ALTERNATIVE_LINK_NAME[j7-main-r5f0_0-fw] = "${nonarch_base_libdir}/firmware/${TARGET_MAIN_R5FSS0_0}"
ALTERNATIVE_TARGET[j7-main-r5f0_0-fw] = "${nonarch_base_libdir}/firmware/${CPSW9G_FW_FILENAME}"
ALTERNATIVE_PRIORITY = "17"
-
-INHIBIT_PACKAGE_STRIP = "1"
-INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
-INSANE_SKIP:${PN} += "arch"
-
-do_compile[noexec] = "1"
-do_configure[noexec] = "1"
new file mode 100644
@@ -0,0 +1,22 @@
+# Clean is broken for most firmware-only repos
+CLEANBROKEN = "1"
+
+# Make sure that lib/firmware, and all its contents are part of the package
+FILES:${PN} = "${nonarch_base_libdir}/firmware"
+
+# This is used to prevent the build system from stripping the firmwares
+INHIBIT_PACKAGE_STRIP = "1"
+INHIBIT_SYSROOT_STRIP = "1"
+
+# This is used to prevent the build system from splitting out the firmware debug info into a separate file
+INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
+
+# Firmware here are prebuilt with no external dependencies
+INHIBIT_DEFAULT_DEPS = "1"
+
+# Disable arch checking as firmware is likely to be a different arch from the Yocto build
+INSANE_SKIP:${PN} += "arch"
+
+# Firmware has no configure nor build steps
+do_compile[noexec] = "1"
+do_configure[noexec] = "1"
@@ -1,5 +1,3 @@
-SUMMARY = "Common include for TI Linux firmware"
-
LICENSE = "TI-TFL"
LIC_FILES_CHKSUM = "file://LICENSE.ti;md5=b5aebf0668bdf95621259288c4a46d76"
@@ -32,24 +30,4 @@ SRC_URI = "${TI_LINUX_FW_GIT_URI};protocol=${TI_LINUX_FW_GIT_PROTOCOL};${TI_LINU
S = "${WORKDIR}/git"
-CLEANBROKEN = "1"
-
-# Make sure that lib/firmware, and all its contents are part of the package
-FILES:${PN} = "${nonarch_base_libdir}/firmware"
-
-# This is used to prevent the build system from stripping the firmwares
-INHIBIT_PACKAGE_STRIP = "1"
-INHIBIT_SYSROOT_STRIP = "1"
-
-# This is used to prevent the build system from splitting out the firmware debug info into a separate file
-INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
-
-# Firmware here are prebuilt with no external dependencies
-INHIBIT_DEFAULT_DEPS = "1"
-
-# Disable arch checking as firmware is likely to be a different arch from the Yocto build
-INSANE_SKIP:${PN} += "arch"
-
-# Firmware in Linux Firmware has no configure nor build steps
-do_compile[noexec] = "1"
-do_configure[noexec] = "1"
+require recipes-bsp/ti-linux-fw/firmware-common.inc
@@ -39,26 +39,7 @@ do_install() {
done
}
-# Make sure that lib/firmware, and all its contents are part of the package
-FILES:${PN} = "${nonarch_base_libdir}/firmware"
-
-# This is used to prevent the build system from stripping the firmwares
-INHIBIT_PACKAGE_STRIP = "1"
-INHIBIT_SYSROOT_STRIP = "1"
-
-# This is used to prevent the build system from splitting out the firmware debug info into a separate file
-INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
-
-# This is a prebuilt with no external dependencies
-INHIBIT_DEFAULT_DEPS = "1"
-
-# Disable arch checking as firmware is likely to be a different arch from the Yocto build
-INSANE_SKIP:${PN} += "arch"
-
-# Zephyr-Firmware has no configure, compile, nor clean steps
-do_configure[noexec] = "1"
-do_compile[noexec] = "1"
-CLEANBROKEN = "1"
+require recipes-bsp/ti-linux-fw/firmware-common.inc
inherit update-alternatives
Firmware-only packages tend to set all the same long list of options, factor these out into a helper include and include that in firmware- only package. Signed-off-by: Andrew Davis <afd@ti.com> --- .../cpsw9g-eth-fw/cpsw9g-eth-fw_git.bb | 10 +------- .../ti-linux-fw/firmware-common.inc | 22 +++++++++++++++++ .../recipes-bsp/ti-linux-fw/ti-linux-fw.inc | 24 +------------------ .../zephyr-fw/zephyr-openamp-rsc-table-fw.bb | 21 +--------------- 4 files changed, 25 insertions(+), 52 deletions(-) create mode 100644 meta-ti-bsp/recipes-bsp/ti-linux-fw/firmware-common.inc