]> code.ossystems Code Review - meta-freescale.git/commitdiff
recipes-*: refine restrictions for NXP BSP
authorAndrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
Thu, 16 Apr 2020 22:17:45 +0000 (22:17 +0000)
committerOtavio Salvador <otavio@ossystems.com.br>
Thu, 16 Apr 2020 23:04:08 +0000 (20:04 -0300)
Certain packages are using linux-imx-headers, which enforces them to use
NXP BSP since headers are provided from the NXP kernel tree.

Those recipes, which requires NXP kernel headers, are now including the
use-imx-headers class to make sure the correct headers package is used.

Since the introduction of separation between NXP and Mainline BSP for
certain machines, recipes which are NXP-dependent are getting their
COMPATIBLE_HOST to be marked as (null) effectively making them
incompatible with mainline BSP which is expected behavior.

By extending this restriction into the use-imx-headers class, all
recipes which inherits is (because it is required) are getting
automatically restricted to NXP BSP, hence making package NXP-dependent
much easier.

linux-imx-headers is marked as "NXP-only" but it is done explicitly
inside the recipe in order to avoid confusion of inheriting the class.

Signed-off-by: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
classes/use-imx-headers.bbclass
recipes-bsp/imx-test/imx-test_git.bb
recipes-kernel/linux/linux-imx-headers_5.4.3.bb

index 9dcd864df777b8aab7bc71edc23c0f29e7da90a8..d2214b6d128f89e15123d59c89c1333852906a10 100644 (file)
@@ -17,3 +17,15 @@ DEPENDS_append_imx = " linux-imx-headers"
 PACKAGE_ARCH_imx ?= "${MACHINE_SOCARCH}"
 
 STAGING_INCDIR_IMX = "${STAGING_INCDIR}/imx"
+
+# Recipes that inherit this class are contracted to use NXP BSP only.
+# This is done by overriding the COMPATIBLE_HOST, as this would effectively
+# cause recipes to be skipped in case if 'use-nxp-bsp' override is not
+# defined for them. This effectively marks recipes that should only be
+# built using NXP BSP, and gives an indication to mainline BSP creators
+# that recipe is not compatible with mainline.
+#
+# Typical example here would be imx-vpu-hantro recipe, which requires NXP
+# BSP and is not compatible with mainline.
+COMPATIBLE_HOST = '(null)'
+COMPATIBLE_HOST_use-nxp-bsp = '.*'
index dacef82fd0df7a20ac0730b8d010732c079c1a95..81bbd3a34792077c6fc93ae5c9e359b0c0bf2d93 100644 (file)
@@ -79,7 +79,3 @@ FILES_${PN} += "/unit_tests /home/root/.profile"
 RDEPENDS_${PN} = "bash"
 
 FILES_${PN}-dbg += "/unit_tests/.debug"
-
-COMPATIBLE_MACHINE = "(mx6|mx7|mx8)"
-COMPATIBLE_HOST ?= "(none)"
-COMPATIBLE_HOST_use-nxp-bsp = "(.*)"
index 1517c6474d2fe430cc81e80a67fd5f92280716f7..8d52233db0f5f7e8a661dc48ac220afdeb1a57fe 100644 (file)
@@ -63,5 +63,8 @@ INHIBIT_DEFAULT_DEPS = "1"
 DEPENDS += "unifdef-native bison-native rsync-native"
 
 PACKAGE_ARCH = "${MACHINE_SOCARCH}"
-COMPATIBLE_HOST_imx = "(use-nxp-bsp)"
-COMPATIBLE_HOST ?= "(none)"
+
+# Restrict this recipe to NXP BSP only, this recipe is not compatible
+# with mainline BSP
+COMPATIBLE_HOST = '(null)'
+COMPATIBLE_HOST_use-nxp-bsp = '.*'