* [meta-rockchip][PATCH] bsp: rkbin: fix default COMPATIBLE_MACHINE matching all
@ 2023-10-16 11:21 Quentin Schulz
2023-10-25 13:42 ` [yocto] " Trevor Woerner
0 siblings, 1 reply; 2+ messages in thread
From: Quentin Schulz @ 2023-10-16 11:21 UTC (permalink / raw)
To: twoerner; +Cc: yocto, Quentin Schulz, Quentin Schulz
From: Quentin Schulz <quentin.schulz@theobroma-systems.com>
The goal of the default COMPATIBLE_MACHINE was to not allow
rockchip-rkbin to be even parsed if a MACHINE isn't part of the
COMPATIBLE_MACHINE.
However, COMPATIBLE_MACHINE is a regexp checked using Python's re module
approximately like:
"""
if re.match(COMPATIBLE_MACHINE, MACHINE):
return True
"""
and re.match() returns a match whatever MACHINE is if COMPATIBLE_MACHINE
is the empty string.
Therefore, let's change it to `^$` which only matches the empty string,
which shouldn't be possible for anything in MACHINEOVERRIDES, and if it
is there are probably bigger problems than parsing rockchip-rkbin.
Fixes: f8af59dd7cd7 ("rock-5b: add")
Cc: Quentin Schulz <foss+yocto@0leil.net>
Signed-off-by: Quentin Schulz <quentin.schulz@theobroma-systems.com>
---
recipes-bsp/rkbin/rockchip-rkbin_git.bb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/recipes-bsp/rkbin/rockchip-rkbin_git.bb b/recipes-bsp/rkbin/rockchip-rkbin_git.bb
index 7fefb01..f9e680d 100644
--- a/recipes-bsp/rkbin/rockchip-rkbin_git.bb
+++ b/recipes-bsp/rkbin/rockchip-rkbin_git.bb
@@ -12,7 +12,7 @@ inherit bin_package deploy
S = "${WORKDIR}/git"
-COMPATIBLE_MACHINE = ""
+COMPATIBLE_MACHINE = "^$"
COMPATIBLE_MACHINE:rk3588s = "rk3588s"
PACKAGE_ARCH = "${MACHINE_ARCH}"
--
2.41.0
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [yocto] [meta-rockchip][PATCH] bsp: rkbin: fix default COMPATIBLE_MACHINE matching all
2023-10-16 11:21 [meta-rockchip][PATCH] bsp: rkbin: fix default COMPATIBLE_MACHINE matching all Quentin Schulz
@ 2023-10-25 13:42 ` Trevor Woerner
0 siblings, 0 replies; 2+ messages in thread
From: Trevor Woerner @ 2023-10-25 13:42 UTC (permalink / raw)
To: Quentin Schulz; +Cc: yocto, Quentin Schulz, Quentin Schulz
On Mon 2023-10-16 @ 01:21:10 PM, Quentin Schulz wrote:
> From: Quentin Schulz <quentin.schulz@theobroma-systems.com>
>
> The goal of the default COMPATIBLE_MACHINE was to not allow
> rockchip-rkbin to be even parsed if a MACHINE isn't part of the
> COMPATIBLE_MACHINE.
>
> However, COMPATIBLE_MACHINE is a regexp checked using Python's re module
> approximately like:
> """
> if re.match(COMPATIBLE_MACHINE, MACHINE):
> return True
> """
>
> and re.match() returns a match whatever MACHINE is if COMPATIBLE_MACHINE
> is the empty string.
>
> Therefore, let's change it to `^$` which only matches the empty string,
> which shouldn't be possible for anything in MACHINEOVERRIDES, and if it
> is there are probably bigger problems than parsing rockchip-rkbin.
>
> Fixes: f8af59dd7cd7 ("rock-5b: add")
> Cc: Quentin Schulz <foss+yocto@0leil.net>
> Signed-off-by: Quentin Schulz <quentin.schulz@theobroma-systems.com>
> ---
> recipes-bsp/rkbin/rockchip-rkbin_git.bb | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied to meta-rockchip, master branch. Thanks!
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-10-25 13:42 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-16 11:21 [meta-rockchip][PATCH] bsp: rkbin: fix default COMPATIBLE_MACHINE matching all Quentin Schulz
2023-10-25 13:42 ` [yocto] " Trevor Woerner
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.