* [PATCH 0/1] base.bbclass: fix COMPATIBLE_MACHINE
@ 2016-04-10 14:14 Robert Yang
2016-04-10 14:14 ` [PATCH 1/1] " Robert Yang
0 siblings, 1 reply; 12+ messages in thread
From: Robert Yang @ 2016-04-10 14:14 UTC (permalink / raw)
To: openembedded-core
The following changes since commit d2734fbfe209fcb8bd908b55e64d1ea8712d02c1:
local.conf.sample: Make it possible to override EXTRA_IMAGE_FEATURES (2016-04-09 07:56:57 +0100)
are available in the git repository at:
git://git.openembedded.org/openembedded-core-contrib rbt/base
http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=rbt/base
Robert Yang (1):
base.bbclass: fix COMPATIBLE_MACHINE
meta/classes/base.bbclass | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--
2.8.0
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-10 14:14 [PATCH 0/1] base.bbclass: fix COMPATIBLE_MACHINE Robert Yang
@ 2016-04-10 14:14 ` Robert Yang
2016-04-10 17:30 ` Christopher Larson
2016-04-10 19:06 ` Denys Dmytriyenko
0 siblings, 2 replies; 12+ messages in thread
From: Robert Yang @ 2016-04-10 14:14 UTC (permalink / raw)
To: openembedded-core
It mismatched such as qemux86 and qemux86-64 which was incorrect, for
example:
COMPATIBLE_MACHINE = "(qemux86)"
But it treated MACHINE = "qemux86-64" as matched. The similar to others.
This patch fixes the problem.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
meta/classes/base.bbclass | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
index f9697a9..f376478 100644
--- a/meta/classes/base.bbclass
+++ b/meta/classes/base.bbclass
@@ -469,7 +469,7 @@ python () {
import re
compat_machines = (d.getVar('MACHINEOVERRIDES', True) or "").split(":")
for m in compat_machines:
- if re.match(need_machine, m):
+ if re.match('^' + need_machine + '$', m):
break
else:
raise bb.parse.SkipPackage("incompatible with machine %s (not in COMPATIBLE_MACHINE)" % d.getVar('MACHINE', True))
--
2.8.0
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-10 14:14 ` [PATCH 1/1] " Robert Yang
@ 2016-04-10 17:30 ` Christopher Larson
2016-04-11 1:10 ` Robert Yang
2016-04-10 19:06 ` Denys Dmytriyenko
1 sibling, 1 reply; 12+ messages in thread
From: Christopher Larson @ 2016-04-10 17:30 UTC (permalink / raw)
To: Robert Yang, openembedded-core
[-- Attachment #1: Type: text/plain, Size: 647 bytes --]
On Sun, Apr 10, 2016 at 7:16 AM Robert Yang <liezhi.yang@windriver.com>
wrote:
> It mismatched such as qemux86 and qemux86-64 which was incorrect, for
> example:
> COMPATIBLE_MACHINE = "(qemux86)"
> But it treated MACHINE = "qemux86-64" as matched. The similar to others.
>
> This patch fixes the problem.
>
> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
>
Did you verify that no recipes are in fact relying on this behavior? This
variable has always been a regex, so this has always been the case. Also
the ^ is unnecessary, re.match always matches at the beginning of the
string, re.search is the one that does not.
[-- Attachment #2: Type: text/html, Size: 1010 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-10 14:14 ` [PATCH 1/1] " Robert Yang
2016-04-10 17:30 ` Christopher Larson
@ 2016-04-10 19:06 ` Denys Dmytriyenko
2016-04-11 1:17 ` Robert Yang
1 sibling, 1 reply; 12+ messages in thread
From: Denys Dmytriyenko @ 2016-04-10 19:06 UTC (permalink / raw)
To: Robert Yang; +Cc: openembedded-core
On Sun, Apr 10, 2016 at 07:14:56AM -0700, Robert Yang wrote:
> It mismatched such as qemux86 and qemux86-64 which was incorrect, for
> example:
> COMPATIBLE_MACHINE = "(qemux86)"
That will match qemux86 and qemux86-64 and is by design! It's a regular
expression, not an exact string match! There are plenty of recipes
(especially outside of oe-core) that depend on this behavior, so please don't
break it!
> But it treated MACHINE = "qemux86-64" as matched. The similar to others.
>
> This patch fixes the problem.
>
> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
> ---
> meta/classes/base.bbclass | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
> index f9697a9..f376478 100644
> --- a/meta/classes/base.bbclass
> +++ b/meta/classes/base.bbclass
> @@ -469,7 +469,7 @@ python () {
> import re
> compat_machines = (d.getVar('MACHINEOVERRIDES', True) or "").split(":")
> for m in compat_machines:
> - if re.match(need_machine, m):
> + if re.match('^' + need_machine + '$', m):
> break
> else:
> raise bb.parse.SkipPackage("incompatible with machine %s (not in COMPATIBLE_MACHINE)" % d.getVar('MACHINE', True))
> --
> 2.8.0
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-10 17:30 ` Christopher Larson
@ 2016-04-11 1:10 ` Robert Yang
0 siblings, 0 replies; 12+ messages in thread
From: Robert Yang @ 2016-04-11 1:10 UTC (permalink / raw)
To: Christopher Larson, openembedded-core
On 04/11/2016 01:30 AM, Christopher Larson wrote:
> On Sun, Apr 10, 2016 at 7:16 AM Robert Yang <liezhi.yang@windriver.com
> <mailto:liezhi.yang@windriver.com>> wrote:
>
> It mismatched such as qemux86 and qemux86-64 which was incorrect, for
> example:
> COMPATIBLE_MACHINE = "(qemux86)"
> But it treated MACHINE = "qemux86-64" as matched. The similar to others.
>
> This patch fixes the problem.
>
> Signed-off-by: Robert Yang <liezhi.yang@windriver.com
> <mailto:liezhi.yang@windriver.com>>
>
>
> Did you verify that no recipes are in fact relying on this behavior? This
This recipe:
meta/recipes-kernel/linux/linux-yocto-tiny_4.4.bb:
COMPATIBLE_MACHINE = "(qemux86)"
And only when MACHINE="qemux86" works well, if MACHINE="qemux86-64",
there is no errors or warnings when building, but a lot of unexpected errors
when running.
> variable has always been a regex, so this has always been the case. Also the ^
Ah, yes, '^' is not needed, it's a little late last night, so I was confused.
Updated in the repo:
git://git.openembedded.org/openembedded-core-contrib rbt/base
http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=rbt/base
Robert Yang (1):
base.bbclass: fix COMPATIBLE_MACHINE
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
index f9697a9..dc43406 100644
--- a/meta/classes/base.bbclass
+++ b/meta/classes/base.bbclass
@@ -469,7 +469,7 @@ python () {
import re
compat_machines = (d.getVar('MACHINEOVERRIDES', True) or "").split(":")
for m in compat_machines:
- if re.match(need_machine, m):
+ if re.match(need_machine + '$', m):
break
else:
raise bb.parse.SkipPackage("incompatible with machine %s (not in
COMPATIBLE_MACHINE)" % d.getVar('MACHINE', True))
// Robert
> is unnecessary, re.match always matches at the beginning of the string,
> re.search is the one that does not.
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-10 19:06 ` Denys Dmytriyenko
@ 2016-04-11 1:17 ` Robert Yang
2016-04-11 1:56 ` Christopher Larson
0 siblings, 1 reply; 12+ messages in thread
From: Robert Yang @ 2016-04-11 1:17 UTC (permalink / raw)
To: Denys Dmytriyenko; +Cc: openembedded-core
On 04/11/2016 03:06 AM, Denys Dmytriyenko wrote:
> On Sun, Apr 10, 2016 at 07:14:56AM -0700, Robert Yang wrote:
>> It mismatched such as qemux86 and qemux86-64 which was incorrect, for
>> example:
>> COMPATIBLE_MACHINE = "(qemux86)"
>
> That will match qemux86 and qemux86-64 and is by design! It's a regular
I'm afraid no, please see my last reply, for others such as
MACHINE_OVERRIDES, they never design to work in such a way, so I don't
think that COMPATIBLE_MACHINE should work in this way. If you really
want to match more, I think that you can set it as "(qemux86.*)" or
something familiar.
> expression, not an exact string match! There are plenty of recipes
> (especially outside of oe-core) that depend on this behavior, so please don't
> break it!
I checked oe-core, there isn't any wrong when set MACHINE to:
"qemuarm"
"qemuarm64"
"qemumips"
"qemumips64"
"qemuppc"
"qemux86"
"qemux86-64"
and run bitbake world -g.
Would you please tell me which recipes outside of oe-core relay on this?
I think that we should fix the recipe.
// Robert
>
>
>> But it treated MACHINE = "qemux86-64" as matched. The similar to others.
>>
>> This patch fixes the problem.
>>
>> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
>> ---
>> meta/classes/base.bbclass | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
>> index f9697a9..f376478 100644
>> --- a/meta/classes/base.bbclass
>> +++ b/meta/classes/base.bbclass
>> @@ -469,7 +469,7 @@ python () {
>> import re
>> compat_machines = (d.getVar('MACHINEOVERRIDES', True) or "").split(":")
>> for m in compat_machines:
>> - if re.match(need_machine, m):
>> + if re.match('^' + need_machine + '$', m):
>> break
>> else:
>> raise bb.parse.SkipPackage("incompatible with machine %s (not in COMPATIBLE_MACHINE)" % d.getVar('MACHINE', True))
>> --
>> 2.8.0
>>
>> --
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.openembedded.org/mailman/listinfo/openembedded-core
>
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-11 1:17 ` Robert Yang
@ 2016-04-11 1:56 ` Christopher Larson
2016-04-11 2:11 ` Robert Yang
0 siblings, 1 reply; 12+ messages in thread
From: Christopher Larson @ 2016-04-11 1:56 UTC (permalink / raw)
To: Robert Yang, Denys Dmytriyenko; +Cc: openembedded-core
[-- Attachment #1: Type: text/plain, Size: 1054 bytes --]
On Sun, Apr 10, 2016 at 6:17 PM Robert Yang <liezhi.yang@windriver.com>
wrote:
>
>
> On 04/11/2016 03:06 AM, Denys Dmytriyenko wrote:
> > On Sun, Apr 10, 2016 at 07:14:56AM -0700, Robert Yang wrote:
> >> It mismatched such as qemux86 and qemux86-64 which was incorrect, for
> >> example:
> >> COMPATIBLE_MACHINE = "(qemux86)"
> >
> > That will match qemux86 and qemux86-64 and is by design! It's a regular
>
> I'm afraid no, please see my last reply, for others such as
> MACHINE_OVERRIDES, they never design to work in such a way, so I don't
> think that COMPATIBLE_MACHINE should work in this way. If you really
> want to match more, I think that you can set it as "(qemux86.*)" or
> something familiar.
>
That's an apples and oranges comparison. MACHINEOVERRIDES is part of
OVERRIDES, which has *completely* different semantics than COMPATIBLE_*.
COMPATIBLE_MACHINE is a regex variable more like BBMASK than anything else,
and it's been that way since we introduced it. OVERRIDES has nothing to do
with regular expressions.
[-- Attachment #2: Type: text/html, Size: 1409 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-11 1:56 ` Christopher Larson
@ 2016-04-11 2:11 ` Robert Yang
2016-04-11 2:29 ` Denys Dmytriyenko
2016-04-11 8:29 ` Richard Purdie
0 siblings, 2 replies; 12+ messages in thread
From: Robert Yang @ 2016-04-11 2:11 UTC (permalink / raw)
To: Christopher Larson, Denys Dmytriyenko; +Cc: openembedded-core
On 04/11/2016 09:56 AM, Christopher Larson wrote:
> On Sun, Apr 10, 2016 at 6:17 PM Robert Yang <liezhi.yang@windriver.com
> <mailto:liezhi.yang@windriver.com>> wrote:
>
>
>
> On 04/11/2016 03:06 AM, Denys Dmytriyenko wrote:
> > On Sun, Apr 10, 2016 at 07:14:56AM -0700, Robert Yang wrote:
> >> It mismatched such as qemux86 and qemux86-64 which was incorrect, for
> >> example:
> >> COMPATIBLE_MACHINE = "(qemux86)"
> >
> > That will match qemux86 and qemux86-64 and is by design! It's a regular
>
> I'm afraid no, please see my last reply, for others such as
> MACHINE_OVERRIDES, they never design to work in such a way, so I don't
> think that COMPATIBLE_MACHINE should work in this way. If you really
> want to match more, I think that you can set it as "(qemux86.*)" or
> something familiar.
>
>
> That's an apples and oranges comparison. MACHINEOVERRIDES is part of OVERRIDES,
> which has *completely* different semantics than COMPATIBLE_*. COMPATIBLE_MACHINE
> is a regex variable more like BBMASK than anything else, and it's been that way
> since we introduced it. OVERRIDES has nothing to do with regular expressions.
Since introduced ? I did a grep in oe-core and meta-openembedded, it seems
that no ?
In oe-core:
$ grep 'COMPATIBLE_MACHINE.*qemux86' meta/recipes* -r
linux-yocto_4.4.bb:COMPATIBLE_MACHINE =
"qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
linux-yocto-tiny_4.4.bb:COMPATIBLE_MACHINE = "(qemux86)"
linux-yocto-dev.bb:COMPATIBLE_MACHINE =
"(qemuarm|qemux86|qemuppc|qemumips|qemumips64|qemux86-64)"
linux-yocto-tiny_4.1.bb:COMPATIBLE_MACHINE = "(qemux86)"
linux-yocto-rt_4.1.bb:COMPATIBLE_MACHINE =
"(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
linux-yocto-rt_4.4.bb:COMPATIBLE_MACHINE =
"(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
linux-yocto_4.1.bb:COMPATIBLE_MACHINE =
"qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
In meta-openembedded:
vboxguestdrivers_4.3.30.bb:COMPATIBLE_MACHINE = "(qemux86|qemux86-64)"
We can see that the only one sets qemux86 but no set qemux86-64 is
linux-yocto-tiny:
COMPATIBLE_MACHINE = "(qemux86)"
And it really doesn't work with qemux86-64.
// Robert
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-11 2:11 ` Robert Yang
@ 2016-04-11 2:29 ` Denys Dmytriyenko
2016-04-11 13:12 ` Denys Dmytriyenko
2016-04-11 8:29 ` Richard Purdie
1 sibling, 1 reply; 12+ messages in thread
From: Denys Dmytriyenko @ 2016-04-11 2:29 UTC (permalink / raw)
To: Robert Yang; +Cc: openembedded-core
On Mon, Apr 11, 2016 at 10:11:41AM +0800, Robert Yang wrote:
> On 04/11/2016 09:56 AM, Christopher Larson wrote:
> >On Sun, Apr 10, 2016 at 6:17 PM Robert Yang <liezhi.yang@windriver.com
> ><mailto:liezhi.yang@windriver.com>> wrote:
> >
> >
> >
> > On 04/11/2016 03:06 AM, Denys Dmytriyenko wrote:
> > > On Sun, Apr 10, 2016 at 07:14:56AM -0700, Robert Yang wrote:
> > >> It mismatched such as qemux86 and qemux86-64 which was incorrect, for
> > >> example:
> > >> COMPATIBLE_MACHINE = "(qemux86)"
> > >
> > > That will match qemux86 and qemux86-64 and is by design! It's a regular
> >
> > I'm afraid no, please see my last reply, for others such as
> > MACHINE_OVERRIDES, they never design to work in such a way, so I don't
> > think that COMPATIBLE_MACHINE should work in this way. If you really
> > want to match more, I think that you can set it as "(qemux86.*)" or
> > something familiar.
> >
> >
> >That's an apples and oranges comparison. MACHINEOVERRIDES is part of OVERRIDES,
> >which has *completely* different semantics than COMPATIBLE_*. COMPATIBLE_MACHINE
> >is a regex variable more like BBMASK than anything else, and it's been that way
> >since we introduced it. OVERRIDES has nothing to do with regular expressions.
I completely agree with Chris here! And Robert, what is with this "I think it
should work this way" reasoning? I'm arguing with you in another thread
exactly due to this, where your only explanation was "I think that one recipe
should only have one -dev package, I'm not sure whether this is right or not"
and hence you summarize "it should"...
> Since introduced ? I did a grep in oe-core and meta-openembedded, it seems
> that no ?
Not really sure what you are trying to say here... Are you arguing that it was
never used as a regular expression? I beg to differ and I can provide multiple
examples for that:
http://cgit.openembedded.org/meta-openembedded/tree/meta-oe/recipes-devtools/nodejs/nodejs_4.4.1.bb#n8
http://arago-project.org/git/?p=meta-arago.git;a=blob;f=meta-arago-distro/recipes-core/images/arago-console-image.bb;hb=HEAD#l6
It was like that for 15+ years, since OpenEmbedded Classic days...
> In oe-core:
>
> $ grep 'COMPATIBLE_MACHINE.*qemux86' meta/recipes* -r
> linux-yocto_4.4.bb:COMPATIBLE_MACHINE =
> "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
> linux-yocto-tiny_4.4.bb:COMPATIBLE_MACHINE = "(qemux86)"
> linux-yocto-dev.bb:COMPATIBLE_MACHINE =
> "(qemuarm|qemux86|qemuppc|qemumips|qemumips64|qemux86-64)"
> linux-yocto-tiny_4.1.bb:COMPATIBLE_MACHINE = "(qemux86)"
> linux-yocto-rt_4.1.bb:COMPATIBLE_MACHINE =
> "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
> linux-yocto-rt_4.4.bb:COMPATIBLE_MACHINE =
> "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
> linux-yocto_4.1.bb:COMPATIBLE_MACHINE =
> "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
>
> In meta-openembedded:
> vboxguestdrivers_4.3.30.bb:COMPATIBLE_MACHINE = "(qemux86|qemux86-64)"
>
> We can see that the only one sets qemux86 but no set qemux86-64 is
> linux-yocto-tiny:
> COMPATIBLE_MACHINE = "(qemux86)"
Do you know that the world doesn't end with oe-core and meta-oe?
> And it really doesn't work with qemux86-64.
Well, then fix it by setting it to "qemu86$"
--
Denys
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-11 2:11 ` Robert Yang
2016-04-11 2:29 ` Denys Dmytriyenko
@ 2016-04-11 8:29 ` Richard Purdie
2016-04-11 8:33 ` Robert Yang
1 sibling, 1 reply; 12+ messages in thread
From: Richard Purdie @ 2016-04-11 8:29 UTC (permalink / raw)
To: Robert Yang, Christopher Larson, Denys Dmytriyenko; +Cc: openembedded-core
On Mon, 2016-04-11 at 10:11 +0800, Robert Yang wrote:
>
> On 04/11/2016 09:56 AM, Christopher Larson wrote:
> > On Sun, Apr 10, 2016 at 6:17 PM Robert Yang <
> > liezhi.yang@windriver.com
> > <mailto:liezhi.yang@windriver.com>> wrote:
> >
> >
> >
> > On 04/11/2016 03:06 AM, Denys Dmytriyenko wrote:
> > > On Sun, Apr 10, 2016 at 07:14:56AM -0700, Robert Yang wrote:
> > >> It mismatched such as qemux86 and qemux86-64 which was
> > incorrect, for
> > >> example:
> > >> COMPATIBLE_MACHINE = "(qemux86)"
> > >
> > > That will match qemux86 and qemux86-64 and is by design!
> > It's a regular
> >
> > I'm afraid no, please see my last reply, for others such as
> > MACHINE_OVERRIDES, they never design to work in such a way, so
> > I don't
> > think that COMPATIBLE_MACHINE should work in this way. If you
> > really
> > want to match more, I think that you can set it as
> > "(qemux86.*)" or
> > something familiar.
> >
> >
> > That's an apples and oranges comparison. MACHINEOVERRIDES is part
> > of OVERRIDES,
> > which has *completely* different semantics than COMPATIBLE_*.
> > COMPATIBLE_MACHINE
> > is a regex variable more like BBMASK than anything else, and it's
> > been that way
> > since we introduced it. OVERRIDES has nothing to do with regular
> > expressions.
>
> Since introduced ? I did a grep in oe-core and meta-openembedded, it
> seems
> that no ?
>
> In oe-core:
>
> $ grep 'COMPATIBLE_MACHINE.*qemux86' meta/recipes* -r
> linux-yocto_4.4.bb:COMPATIBLE_MACHINE =
> "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
> linux-yocto-tiny_4.4.bb:COMPATIBLE_MACHINE = "(qemux86)"
> linux-yocto-dev.bb:COMPATIBLE_MACHINE =
> "(qemuarm|qemux86|qemuppc|qemumips|qemumips64|qemux86-64)"
> linux-yocto-tiny_4.1.bb:COMPATIBLE_MACHINE = "(qemux86)"
> linux-yocto-rt_4.1.bb:COMPATIBLE_MACHINE =
> "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
> linux-yocto-rt_4.4.bb:COMPATIBLE_MACHINE =
> "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
> linux-yocto_4.1.bb:COMPATIBLE_MACHINE =
> "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
>
> In meta-openembedded:
> vboxguestdrivers_4.3.30.bb:COMPATIBLE_MACHINE = "(qemux86|qemux86
> -64)"
>
> We can see that the only one sets qemux86 but no set qemux86-64 is
> linux-yocto-tiny:
> COMPATIBLE_MACHINE = "(qemux86)"
>
> And it really doesn't work with qemux86-64.
The trouble is as others have mentioned, COMPATIBLE_MACHINE has always
worked this way. We can't really change that without a wider discussion
and at this point in the release in particular, I can't take such a
patch.
We do really need to think about the behaviour as it does do unexpected
things and catch people out.
I'd suggest you add a '$' to the end of the regex in linux-yocto-tiny
to resolve this. We could also add '$' to the end of the other usages
and make it clear it is a regex?
Cheers,
Richard
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-11 8:29 ` Richard Purdie
@ 2016-04-11 8:33 ` Robert Yang
0 siblings, 0 replies; 12+ messages in thread
From: Robert Yang @ 2016-04-11 8:33 UTC (permalink / raw)
To: Richard Purdie, Christopher Larson, Denys Dmytriyenko; +Cc: openembedded-core
On 04/11/2016 04:29 PM, Richard Purdie wrote:
> On Mon, 2016-04-11 at 10:11 +0800, Robert Yang wrote:
>>
>> On 04/11/2016 09:56 AM, Christopher Larson wrote:
>>> On Sun, Apr 10, 2016 at 6:17 PM Robert Yang <
>>> liezhi.yang@windriver.com
>>> <mailto:liezhi.yang@windriver.com>> wrote:
>>>
>>>
>>>
>>> On 04/11/2016 03:06 AM, Denys Dmytriyenko wrote:
>>> > On Sun, Apr 10, 2016 at 07:14:56AM -0700, Robert Yang wrote:
>>> >> It mismatched such as qemux86 and qemux86-64 which was
>>> incorrect, for
>>> >> example:
>>> >> COMPATIBLE_MACHINE = "(qemux86)"
>>> >
>>> > That will match qemux86 and qemux86-64 and is by design!
>>> It's a regular
>>>
>>> I'm afraid no, please see my last reply, for others such as
>>> MACHINE_OVERRIDES, they never design to work in such a way, so
>>> I don't
>>> think that COMPATIBLE_MACHINE should work in this way. If you
>>> really
>>> want to match more, I think that you can set it as
>>> "(qemux86.*)" or
>>> something familiar.
>>>
>>>
>>> That's an apples and oranges comparison. MACHINEOVERRIDES is part
>>> of OVERRIDES,
>>> which has *completely* different semantics than COMPATIBLE_*.
>>> COMPATIBLE_MACHINE
>>> is a regex variable more like BBMASK than anything else, and it's
>>> been that way
>>> since we introduced it. OVERRIDES has nothing to do with regular
>>> expressions.
>>
>> Since introduced ? I did a grep in oe-core and meta-openembedded, it
>> seems
>> that no ?
>>
>> In oe-core:
>>
>> $ grep 'COMPATIBLE_MACHINE.*qemux86' meta/recipes* -r
>> linux-yocto_4.4.bb:COMPATIBLE_MACHINE =
>> "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
>> linux-yocto-tiny_4.4.bb:COMPATIBLE_MACHINE = "(qemux86)"
>> linux-yocto-dev.bb:COMPATIBLE_MACHINE =
>> "(qemuarm|qemux86|qemuppc|qemumips|qemumips64|qemux86-64)"
>> linux-yocto-tiny_4.1.bb:COMPATIBLE_MACHINE = "(qemux86)"
>> linux-yocto-rt_4.1.bb:COMPATIBLE_MACHINE =
>> "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
>> linux-yocto-rt_4.4.bb:COMPATIBLE_MACHINE =
>> "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
>> linux-yocto_4.1.bb:COMPATIBLE_MACHINE =
>> "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
>>
>> In meta-openembedded:
>> vboxguestdrivers_4.3.30.bb:COMPATIBLE_MACHINE = "(qemux86|qemux86
>> -64)"
>>
>> We can see that the only one sets qemux86 but no set qemux86-64 is
>> linux-yocto-tiny:
>> COMPATIBLE_MACHINE = "(qemux86)"
>>
>> And it really doesn't work with qemux86-64.
>
> The trouble is as others have mentioned, COMPATIBLE_MACHINE has always
> worked this way. We can't really change that without a wider discussion
> and at this point in the release in particular, I can't take such a
> patch.
>
> We do really need to think about the behaviour as it does do unexpected
> things and catch people out.
>
> I'd suggest you add a '$' to the end of the regex in linux-yocto-tiny
Thanks, I will send a new patch it.
> to resolve this. We could also add '$' to the end of the other usages
> and make it clear it is a regex?
I'd like to only fix linux-yocto-tiny atm in case of cause other errors,
maybe we can do that for other recipes in YP 2.2.
// Robert
>
> Cheers,
>
> Richard
>
>
>
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/1] base.bbclass: fix COMPATIBLE_MACHINE
2016-04-11 2:29 ` Denys Dmytriyenko
@ 2016-04-11 13:12 ` Denys Dmytriyenko
0 siblings, 0 replies; 12+ messages in thread
From: Denys Dmytriyenko @ 2016-04-11 13:12 UTC (permalink / raw)
To: openembedded-core
> > Since introduced ? I did a grep in oe-core and meta-openembedded, it seems
> > that no ?
>
> Not really sure what you are trying to say here... Are you arguing that it was
> never used as a regular expression? I beg to differ and I can provide multiple
> examples for that:
>
> http://cgit.openembedded.org/meta-openembedded/tree/meta-oe/recipes-devtools/nodejs/nodejs_4.4.1.bb#n8
> http://arago-project.org/git/?p=meta-arago.git;a=blob;f=meta-arago-distro/recipes-core/images/arago-console-image.bb;hb=HEAD#l6
>
> It was like that for 15+ years, since OpenEmbedded Classic days...
Oops, that does sound more impressive, but I meant 10+ years - my math failed
me that late at night... :)
--
Denys
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2016-04-11 13:12 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-10 14:14 [PATCH 0/1] base.bbclass: fix COMPATIBLE_MACHINE Robert Yang
2016-04-10 14:14 ` [PATCH 1/1] " Robert Yang
2016-04-10 17:30 ` Christopher Larson
2016-04-11 1:10 ` Robert Yang
2016-04-10 19:06 ` Denys Dmytriyenko
2016-04-11 1:17 ` Robert Yang
2016-04-11 1:56 ` Christopher Larson
2016-04-11 2:11 ` Robert Yang
2016-04-11 2:29 ` Denys Dmytriyenko
2016-04-11 13:12 ` Denys Dmytriyenko
2016-04-11 8:29 ` Richard Purdie
2016-04-11 8:33 ` Robert Yang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox