* [PATCH V2 0/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
@ 2014-10-15 9:23 Hongxu Jia
2014-10-15 9:23 ` [PATCH 1/1] " Hongxu Jia
0 siblings, 1 reply; 9+ messages in thread
From: Hongxu Jia @ 2014-10-15 9:23 UTC (permalink / raw)
To: openembedded-core, ross.burton
Changed in V2:
V1 caused build failure of meta-toolchain, in order to avoid it, we
should use DEFAULTTUNE_virtclass-multilib-lib32 first, if it is not
available, and try to use DEFAULTTUNE_ML_<multilib>
Test steps:
1. env
vim local.conf
...
MACHINE = "qemux86-64"
require conf/multilib.conf
MULTILIBS ?= "multilib:lib32"
DEFAULTTUNE_virtclass-multilib-lib32 ?= "x86"
...
2. build lib32-meta-toolchain success
$ bitbake lib32-meta-toolchain
3. build meta-toolchain success
$ bitbake meta-toolchain
//Hongxu
The following changes since commit ccf5a4d2342c4fd40e4e0b332ea7e34e0bf175d4:
build-appliance-image: Update to dizzy head revision (2014-10-11 08:11:17 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib hongxu/fix-lib32-meta-toolchain
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-lib32-meta-toolchain
Hongxu Jia (1):
multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain
build failure
meta/classes/multilib.bbclass | 1 +
meta/lib/oe/package_manager.py | 3 +++
2 files changed, 4 insertions(+)
--
1.9.1
^ permalink raw reply [flat|nested] 9+ messages in thread* [PATCH 1/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
2014-10-15 9:23 [PATCH V2 0/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure Hongxu Jia
@ 2014-10-15 9:23 ` Hongxu Jia
2014-10-15 11:00 ` Laurentiu Palcu
0 siblings, 1 reply; 9+ messages in thread
From: Hongxu Jia @ 2014-10-15 9:23 UTC (permalink / raw)
To: openembedded-core, ross.burton
There is a failure to build lib32-meta-toolchain:
...
|ERROR: lib32-packagegroup-core-standalone-sdk-target not found in the base
feeds (qemux86_64 x86 noarch any all).
...
In package_manager.py, the variable 'DEFAULTTUNE_virtclass-multilib-lib32'
is used to process multilib image/toolchain. But for the build of lib32-
meta-toolchain, the value of 'DEFAULTTUNE_virtclass-multilib-lib32' is
deleted. In 'bitbake lib32-meta-toolchain -e', we got:
...
|# $DEFAULTTUNE_virtclass-multilib-lib32 [2 operations]
|# set? /home/jiahongxu/yocto/build-20141010-yocto/conf/local.conf:237
|# "x86"
|# del data_smart.py:406 [finalize]
|# ""
|# pre-expansion value:
|# "None"
...
The commit 899d45b90061eb3cf3e71029072eee42cd80930c in oe-core deleted
it at DataSmart.finalize
...
Author: Richard Purdie <richard.purdie@linuxfoundation.org>
Date: Tue May 31 23:52:50 2011 +0100
bitbake/data_smart: Change overrides behaviour to remove
expanded variables from the datastore
...
We add an internal variable 'DEFAULTTUNE_ML_<multilib>', assign it with the
value of 'DEFAULTTUNE_virtclass-multilib-lib32' before deleting.
In package_manager.py, we use DEFAULTTUNE_virtclass-multilib-lib32 first,
if it is not available, and try to use DEFAULTTUNE_ML_<multilib>
[YOCTO #6842]
Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
---
meta/classes/multilib.bbclass | 1 +
meta/lib/oe/package_manager.py | 3 +++
2 files changed, 4 insertions(+)
diff --git a/meta/classes/multilib.bbclass b/meta/classes/multilib.bbclass
index 6e143dd..6aad894 100644
--- a/meta/classes/multilib.bbclass
+++ b/meta/classes/multilib.bbclass
@@ -60,6 +60,7 @@ python multilib_virtclass_handler () {
newtune = e.data.getVar("DEFAULTTUNE_" + "virtclass-multilib-" + variant, False)
if newtune:
e.data.setVar("DEFAULTTUNE", newtune)
+ e.data.setVar('DEFAULTTUNE_ML_%s' % variant, newtune)
}
addhandler multilib_virtclass_handler
diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
index 27fdf26..d42cdcc 100644
--- a/meta/lib/oe/package_manager.py
+++ b/meta/lib/oe/package_manager.py
@@ -63,6 +63,9 @@ class RpmIndexer(Indexer):
localdata = bb.data.createCopy(self.d)
default_tune_key = "DEFAULTTUNE_virtclass-multilib-" + eext[1]
default_tune = localdata.getVar(default_tune_key, False)
+ if not default_tune:
+ default_tune_key = "DEFAULTTUNE_ML_" + eext[1]
+ default_tune = localdata.getVar(default_tune_key, False)
if default_tune:
localdata.setVar("DEFAULTTUNE", default_tune)
bb.data.update_data(localdata)
--
1.9.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* Re: [PATCH 1/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
2014-10-15 9:23 ` [PATCH 1/1] " Hongxu Jia
@ 2014-10-15 11:00 ` Laurentiu Palcu
2014-10-15 11:32 ` Hongxu Jia
0 siblings, 1 reply; 9+ messages in thread
From: Laurentiu Palcu @ 2014-10-15 11:00 UTC (permalink / raw)
To: Hongxu Jia; +Cc: openembedded-core
Hi Hongxu,
On Wed, Oct 15, 2014 at 05:23:16PM +0800, Hongxu Jia wrote:
> There is a failure to build lib32-meta-toolchain:
> ...
> |ERROR: lib32-packagegroup-core-standalone-sdk-target not found in the base
> feeds (qemux86_64 x86 noarch any all).
> ...
>
> In package_manager.py, the variable 'DEFAULTTUNE_virtclass-multilib-lib32'
> is used to process multilib image/toolchain. But for the build of lib32-
> meta-toolchain, the value of 'DEFAULTTUNE_virtclass-multilib-lib32' is
> deleted. In 'bitbake lib32-meta-toolchain -e', we got:
> ...
> |# $DEFAULTTUNE_virtclass-multilib-lib32 [2 operations]
> |# set? /home/jiahongxu/yocto/build-20141010-yocto/conf/local.conf:237
> |# "x86"
> |# del data_smart.py:406 [finalize]
> |# ""
> |# pre-expansion value:
> |# "None"
> ...
>
> The commit 899d45b90061eb3cf3e71029072eee42cd80930c in oe-core deleted
> it at DataSmart.finalize
> ...
> Author: Richard Purdie <richard.purdie@linuxfoundation.org>
> Date: Tue May 31 23:52:50 2011 +0100
>
> bitbake/data_smart: Change overrides behaviour to remove
> expanded variables from the datastore
> ...
>
> We add an internal variable 'DEFAULTTUNE_ML_<multilib>', assign it with the
> value of 'DEFAULTTUNE_virtclass-multilib-lib32' before deleting.
>
> In package_manager.py, we use DEFAULTTUNE_virtclass-multilib-lib32 first,
> if it is not available, and try to use DEFAULTTUNE_ML_<multilib>
>
> [YOCTO #6842]
Is this an RPM only issue? (It's not clear from the bug description...) If
not, maybe this should be fixed for the other backends too.
>
> Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ---
> meta/classes/multilib.bbclass | 1 +
> meta/lib/oe/package_manager.py | 3 +++
> 2 files changed, 4 insertions(+)
>
> diff --git a/meta/classes/multilib.bbclass b/meta/classes/multilib.bbclass
> index 6e143dd..6aad894 100644
> --- a/meta/classes/multilib.bbclass
> +++ b/meta/classes/multilib.bbclass
> @@ -60,6 +60,7 @@ python multilib_virtclass_handler () {
> newtune = e.data.getVar("DEFAULTTUNE_" + "virtclass-multilib-" + variant, False)
> if newtune:
> e.data.setVar("DEFAULTTUNE", newtune)
> + e.data.setVar('DEFAULTTUNE_ML_%s' % variant, newtune)
> }
>
> addhandler multilib_virtclass_handler
> diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
> index 27fdf26..d42cdcc 100644
> --- a/meta/lib/oe/package_manager.py
> +++ b/meta/lib/oe/package_manager.py
> @@ -63,6 +63,9 @@ class RpmIndexer(Indexer):
> localdata = bb.data.createCopy(self.d)
> default_tune_key = "DEFAULTTUNE_virtclass-multilib-" + eext[1]
> default_tune = localdata.getVar(default_tune_key, False)
> + if not default_tune:
Testing for None should always be done using 'is' or 'is not'. There's a
good explanation for this in PEP8.
laurentiu
> + default_tune_key = "DEFAULTTUNE_ML_" + eext[1]
> + default_tune = localdata.getVar(default_tune_key, False)
> if default_tune:
> localdata.setVar("DEFAULTTUNE", default_tune)
> bb.data.update_data(localdata)
> --
> 1.9.1
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: [PATCH 1/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
2014-10-15 11:00 ` Laurentiu Palcu
@ 2014-10-15 11:32 ` Hongxu Jia
0 siblings, 0 replies; 9+ messages in thread
From: Hongxu Jia @ 2014-10-15 11:32 UTC (permalink / raw)
To: Laurentiu Palcu; +Cc: openembedded-core
On 10/15/2014 07:00 PM, Laurentiu Palcu wrote:
> Hi Hongxu,
>
> On Wed, Oct 15, 2014 at 05:23:16PM +0800, Hongxu Jia wrote:
>> There is a failure to build lib32-meta-toolchain:
>> ...
>> |ERROR: lib32-packagegroup-core-standalone-sdk-target not found in the base
>> feeds (qemux86_64 x86 noarch any all).
>> ...
>>
>> In package_manager.py, the variable 'DEFAULTTUNE_virtclass-multilib-lib32'
>> is used to process multilib image/toolchain. But for the build of lib32-
>> meta-toolchain, the value of 'DEFAULTTUNE_virtclass-multilib-lib32' is
>> deleted. In 'bitbake lib32-meta-toolchain -e', we got:
>> ...
>> |# $DEFAULTTUNE_virtclass-multilib-lib32 [2 operations]
>> |# set? /home/jiahongxu/yocto/build-20141010-yocto/conf/local.conf:237
>> |# "x86"
>> |# del data_smart.py:406 [finalize]
>> |# ""
>> |# pre-expansion value:
>> |# "None"
>> ...
>>
>> The commit 899d45b90061eb3cf3e71029072eee42cd80930c in oe-core deleted
>> it at DataSmart.finalize
>> ...
>> Author: Richard Purdie <richard.purdie@linuxfoundation.org>
>> Date: Tue May 31 23:52:50 2011 +0100
>>
>> bitbake/data_smart: Change overrides behaviour to remove
>> expanded variables from the datastore
>> ...
>>
>> We add an internal variable 'DEFAULTTUNE_ML_<multilib>', assign it with the
>> value of 'DEFAULTTUNE_virtclass-multilib-lib32' before deleting.
>>
>> In package_manager.py, we use DEFAULTTUNE_virtclass-multilib-lib32 first,
>> if it is not available, and try to use DEFAULTTUNE_ML_<multilib>
>>
>> [YOCTO #6842]
> Is this an RPM only issue? (It's not clear from the bug description...) If
> not, maybe this should be fixed for the other backends too.
Yes, it is rpm only, only rpm staff use the variable
'DEFAULTTUNE_virtclass-multilib-lib32'.
>> Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ---
>> meta/classes/multilib.bbclass | 1 +
>> meta/lib/oe/package_manager.py | 3 +++
>> 2 files changed, 4 insertions(+)
>>
>> diff --git a/meta/classes/multilib.bbclass b/meta/classes/multilib.bbclass
>> index 6e143dd..6aad894 100644
>> --- a/meta/classes/multilib.bbclass
>> +++ b/meta/classes/multilib.bbclass
>> @@ -60,6 +60,7 @@ python multilib_virtclass_handler () {
>> newtune = e.data.getVar("DEFAULTTUNE_" + "virtclass-multilib-" + variant, False)
>> if newtune:
>> e.data.setVar("DEFAULTTUNE", newtune)
>> + e.data.setVar('DEFAULTTUNE_ML_%s' % variant, newtune)
>> }
>>
>> addhandler multilib_virtclass_handler
>> diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
>> index 27fdf26..d42cdcc 100644
>> --- a/meta/lib/oe/package_manager.py
>> +++ b/meta/lib/oe/package_manager.py
>> @@ -63,6 +63,9 @@ class RpmIndexer(Indexer):
>> localdata = bb.data.createCopy(self.d)
>> default_tune_key = "DEFAULTTUNE_virtclass-multilib-" + eext[1]
>> default_tune = localdata.getVar(default_tune_key, False)
>> + if not default_tune:
> Testing for None should always be done using 'is' or 'is not'. There's a
> good explanation for this in PEP8.
Got it, thanks for figuring it out, I will read PEP8, V3 incoming
//Hongxu
> laurentiu
>
>> + default_tune_key = "DEFAULTTUNE_ML_" + eext[1]
>> + default_tune = localdata.getVar(default_tune_key, False)
>> if default_tune:
>> localdata.setVar("DEFAULTTUNE", default_tune)
>> bb.data.update_data(localdata)
>> --
>> 1.9.1
>>
>> --
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.openembedded.org/mailman/listinfo/openembedded-core
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH V3 0/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
@ 2014-10-15 12:31 Hongxu Jia
2014-10-15 12:31 ` [PATCH 1/1] " Hongxu Jia
0 siblings, 1 reply; 9+ messages in thread
From: Hongxu Jia @ 2014-10-15 12:31 UTC (permalink / raw)
To: openembedded-core, ross.burton
Changed in V3:
Comparisons to singletons like None should always be done 'is not'
Changed in V2:
V1 caused build failure of meta-toolchain, in order to avoid it, we
should use DEFAULTTUNE_virtclass-multilib-lib32 first, if it is not
available, and try to use DEFAULTTUNE_ML_<multilib>
Test steps:
1. env
vim local.conf
...
MACHINE = "qemux86-64"
require conf/multilib.conf
MULTILIBS ?= "multilib:lib32"
DEFAULTTUNE_virtclass-multilib-lib32 ?= "x86"
...
2. build lib32-meta-toolchain success
$ bitbake lib32-meta-toolchain
3. build meta-toolchain success
$ bitbake meta-toolchain
//Hongxu
The following changes since commit ccf5a4d2342c4fd40e4e0b332ea7e34e0bf175d4:
build-appliance-image: Update to dizzy head revision (2014-10-11 08:11:17 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib hongxu/fix-lib32-meta-toolchain
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-lib32-meta-toolchain
Hongxu Jia (1):
multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain
build failure
meta/classes/multilib.bbclass | 1 +
meta/lib/oe/package_manager.py | 3 +++
2 files changed, 4 insertions(+)
--
1.9.1
^ permalink raw reply [flat|nested] 9+ messages in thread* [PATCH 1/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
2014-10-15 12:31 [PATCH V3 0/1] " Hongxu Jia
@ 2014-10-15 12:31 ` Hongxu Jia
2014-10-15 13:27 ` Laurentiu Palcu
0 siblings, 1 reply; 9+ messages in thread
From: Hongxu Jia @ 2014-10-15 12:31 UTC (permalink / raw)
To: openembedded-core, ross.burton
There is a failure to build lib32-meta-toolchain:
...
|ERROR: lib32-packagegroup-core-standalone-sdk-target not found in the base
feeds (qemux86_64 x86 noarch any all).
...
In package_manager.py, the variable 'DEFAULTTUNE_virtclass-multilib-lib32'
is used to process multilib image/toolchain. But for the build of lib32-
meta-toolchain, the value of 'DEFAULTTUNE_virtclass-multilib-lib32' is
deleted. In 'bitbake lib32-meta-toolchain -e', we got:
...
|# $DEFAULTTUNE_virtclass-multilib-lib32 [2 operations]
|# set? /home/jiahongxu/yocto/build-20141010-yocto/conf/local.conf:237
|# "x86"
|# del data_smart.py:406 [finalize]
|# ""
|# pre-expansion value:
|# "None"
...
The commit 899d45b90061eb3cf3e71029072eee42cd80930c in oe-core deleted
it at DataSmart.finalize
...
Author: Richard Purdie <richard.purdie@linuxfoundation.org>
Date: Tue May 31 23:52:50 2011 +0100
bitbake/data_smart: Change overrides behaviour to remove
expanded variables from the datastore
...
We add an internal variable 'DEFAULTTUNE_ML_<multilib>', assign it with the
value of 'DEFAULTTUNE_virtclass-multilib-lib32' before deleting.
For rpm backend in package_manager.py, we use DEFAULTTUNE_virtclass-multilib
-lib32 first, if it is not available, and try to use DEFAULTTUNE_ML_<multilib>
[YOCTO #6842]
Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
---
meta/classes/multilib.bbclass | 1 +
meta/lib/oe/package_manager.py | 3 +++
2 files changed, 4 insertions(+)
diff --git a/meta/classes/multilib.bbclass b/meta/classes/multilib.bbclass
index 6e143dd..6aad894 100644
--- a/meta/classes/multilib.bbclass
+++ b/meta/classes/multilib.bbclass
@@ -60,6 +60,7 @@ python multilib_virtclass_handler () {
newtune = e.data.getVar("DEFAULTTUNE_" + "virtclass-multilib-" + variant, False)
if newtune:
e.data.setVar("DEFAULTTUNE", newtune)
+ e.data.setVar('DEFAULTTUNE_ML_%s' % variant, newtune)
}
addhandler multilib_virtclass_handler
diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
index 27fdf26..221b38a 100644
--- a/meta/lib/oe/package_manager.py
+++ b/meta/lib/oe/package_manager.py
@@ -63,6 +63,9 @@ class RpmIndexer(Indexer):
localdata = bb.data.createCopy(self.d)
default_tune_key = "DEFAULTTUNE_virtclass-multilib-" + eext[1]
default_tune = localdata.getVar(default_tune_key, False)
+ if default_tune is None:
+ default_tune_key = "DEFAULTTUNE_ML_" + eext[1]
+ default_tune = localdata.getVar(default_tune_key, False)
if default_tune:
localdata.setVar("DEFAULTTUNE", default_tune)
bb.data.update_data(localdata)
--
1.9.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* Re: [PATCH 1/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
2014-10-15 12:31 ` [PATCH 1/1] " Hongxu Jia
@ 2014-10-15 13:27 ` Laurentiu Palcu
2014-10-15 13:57 ` Hongxu Jia
0 siblings, 1 reply; 9+ messages in thread
From: Laurentiu Palcu @ 2014-10-15 13:27 UTC (permalink / raw)
To: Hongxu Jia; +Cc: openembedded-core
Hi Hongxu,
Out of curiosity, was this broken since 2011? Because the commit you're
mentioning is more than 3 years old and I'm not totally convinced that it's
the one triggering the problem...
laurentiu
On Wed, Oct 15, 2014 at 08:31:14PM +0800, Hongxu Jia wrote:
> There is a failure to build lib32-meta-toolchain:
> ...
> |ERROR: lib32-packagegroup-core-standalone-sdk-target not found in the base
> feeds (qemux86_64 x86 noarch any all).
> ...
>
> In package_manager.py, the variable 'DEFAULTTUNE_virtclass-multilib-lib32'
> is used to process multilib image/toolchain. But for the build of lib32-
> meta-toolchain, the value of 'DEFAULTTUNE_virtclass-multilib-lib32' is
> deleted. In 'bitbake lib32-meta-toolchain -e', we got:
> ...
> |# $DEFAULTTUNE_virtclass-multilib-lib32 [2 operations]
> |# set? /home/jiahongxu/yocto/build-20141010-yocto/conf/local.conf:237
> |# "x86"
> |# del data_smart.py:406 [finalize]
> |# ""
> |# pre-expansion value:
> |# "None"
> ...
>
> The commit 899d45b90061eb3cf3e71029072eee42cd80930c in oe-core deleted
> it at DataSmart.finalize
> ...
> Author: Richard Purdie <richard.purdie@linuxfoundation.org>
> Date: Tue May 31 23:52:50 2011 +0100
>
> bitbake/data_smart: Change overrides behaviour to remove
> expanded variables from the datastore
> ...
>
> We add an internal variable 'DEFAULTTUNE_ML_<multilib>', assign it with the
> value of 'DEFAULTTUNE_virtclass-multilib-lib32' before deleting.
>
> For rpm backend in package_manager.py, we use DEFAULTTUNE_virtclass-multilib
> -lib32 first, if it is not available, and try to use DEFAULTTUNE_ML_<multilib>
>
> [YOCTO #6842]
>
> Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ---
> meta/classes/multilib.bbclass | 1 +
> meta/lib/oe/package_manager.py | 3 +++
> 2 files changed, 4 insertions(+)
>
> diff --git a/meta/classes/multilib.bbclass b/meta/classes/multilib.bbclass
> index 6e143dd..6aad894 100644
> --- a/meta/classes/multilib.bbclass
> +++ b/meta/classes/multilib.bbclass
> @@ -60,6 +60,7 @@ python multilib_virtclass_handler () {
> newtune = e.data.getVar("DEFAULTTUNE_" + "virtclass-multilib-" + variant, False)
> if newtune:
> e.data.setVar("DEFAULTTUNE", newtune)
> + e.data.setVar('DEFAULTTUNE_ML_%s' % variant, newtune)
> }
>
> addhandler multilib_virtclass_handler
> diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
> index 27fdf26..221b38a 100644
> --- a/meta/lib/oe/package_manager.py
> +++ b/meta/lib/oe/package_manager.py
> @@ -63,6 +63,9 @@ class RpmIndexer(Indexer):
> localdata = bb.data.createCopy(self.d)
> default_tune_key = "DEFAULTTUNE_virtclass-multilib-" + eext[1]
> default_tune = localdata.getVar(default_tune_key, False)
> + if default_tune is None:
> + default_tune_key = "DEFAULTTUNE_ML_" + eext[1]
> + default_tune = localdata.getVar(default_tune_key, False)
> if default_tune:
> localdata.setVar("DEFAULTTUNE", default_tune)
> bb.data.update_data(localdata)
> --
> 1.9.1
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: [PATCH 1/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
2014-10-15 13:27 ` Laurentiu Palcu
@ 2014-10-15 13:57 ` Hongxu Jia
0 siblings, 0 replies; 9+ messages in thread
From: Hongxu Jia @ 2014-10-15 13:57 UTC (permalink / raw)
To: Laurentiu Palcu; +Cc: openembedded-core
On 10/15/2014 09:27 PM, Laurentiu Palcu wrote:
> Hi Hongxu,
>
> Out of curiosity, was this broken since 2011? Because the commit you're
> mentioning is more than 3 years old and I'm not totally convinced that it's
> the one triggering the problem...
It failed after do_rootfs refactor, in previous version, the code of using
'DEFAULTTUNE_virtclass-multilib-lib32' by rpm located in
python __anonymous () {
}
which not invoking data_smart.finalize. At that time, everyting is ok.
//Hongxu
>> There is a failure to build lib32-meta-toolchain:
>> ...
>> |ERROR: lib32-packagegroup-core-standalone-sdk-target not found in the base
>> feeds (qemux86_64 x86 noarch any all).
>> ...
>>
>> In package_manager.py, the variable 'DEFAULTTUNE_virtclass-multilib-lib32'
>> is used to process multilib image/toolchain. But for the build of lib32-
>> meta-toolchain, the value of 'DEFAULTTUNE_virtclass-multilib-lib32' is
>> deleted. In 'bitbake lib32-meta-toolchain -e', we got:
>> ...
>> |# $DEFAULTTUNE_virtclass-multilib-lib32 [2 operations]
>> |# set? /home/jiahongxu/yocto/build-20141010-yocto/conf/local.conf:237
>> |# "x86"
>> |# del data_smart.py:406 [finalize]
>> |# ""
>> |# pre-expansion value:
>> |# "None"
>> ...
>>
>> The commit 899d45b90061eb3cf3e71029072eee42cd80930c in oe-core deleted
>> it at DataSmart.finalize
>> ...
>> Author: Richard Purdie <richard.purdie@linuxfoundation.org>
>> Date: Tue May 31 23:52:50 2011 +0100
>>
>> bitbake/data_smart: Change overrides behaviour to remove
>> expanded variables from the datastore
>> ...
>>
>> We add an internal variable 'DEFAULTTUNE_ML_<multilib>', assign it with the
>> value of 'DEFAULTTUNE_virtclass-multilib-lib32' before deleting.
>>
>> For rpm backend in package_manager.py, we use DEFAULTTUNE_virtclass-multilib
>> -lib32 first, if it is not available, and try to use DEFAULTTUNE_ML_<multilib>
>>
>> [YOCTO #6842]
>>
>> Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ---
>> meta/classes/multilib.bbclass | 1 +
>> meta/lib/oe/package_manager.py | 3 +++
>> 2 files changed, 4 insertions(+)
>>
>> diff --git a/meta/classes/multilib.bbclass b/meta/classes/multilib.bbclass
>> index 6e143dd..6aad894 100644
>> --- a/meta/classes/multilib.bbclass
>> +++ b/meta/classes/multilib.bbclass
>> @@ -60,6 +60,7 @@ python multilib_virtclass_handler () {
>> newtune = e.data.getVar("DEFAULTTUNE_" + "virtclass-multilib-" + variant, False)
>> if newtune:
>> e.data.setVar("DEFAULTTUNE", newtune)
>> + e.data.setVar('DEFAULTTUNE_ML_%s' % variant, newtune)
>> }
>>
>> addhandler multilib_virtclass_handler
>> diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
>> index 27fdf26..221b38a 100644
>> --- a/meta/lib/oe/package_manager.py
>> +++ b/meta/lib/oe/package_manager.py
>> @@ -63,6 +63,9 @@ class RpmIndexer(Indexer):
>> localdata = bb.data.createCopy(self.d)
>> default_tune_key = "DEFAULTTUNE_virtclass-multilib-" + eext[1]
>> default_tune = localdata.getVar(default_tune_key, False)
>> + if default_tune is None:
>> + default_tune_key = "DEFAULTTUNE_ML_" + eext[1]
>> + default_tune = localdata.getVar(default_tune_key, False)
>> if default_tune:
>> localdata.setVar("DEFAULTTUNE", default_tune)
>> bb.data.update_data(localdata)
>> --
>> 1.9.1
>>
>> --
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.openembedded.org/mailman/listinfo/openembedded-core
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH 0/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
@ 2014-10-15 5:58 Hongxu Jia
2014-10-15 5:59 ` [PATCH 1/1] " Hongxu Jia
0 siblings, 1 reply; 9+ messages in thread
From: Hongxu Jia @ 2014-10-15 5:58 UTC (permalink / raw)
To: openembedded-core, ross.burton
Test steps:
1. env
vim local.conf
...
MACHINE = "qemux86-64"
require conf/multilib.conf
MULTILIBS ?= "multilib:lib32"
DEFAULTTUNE_virtclass-multilib-lib32 ?= "x86"
...
2. build lib32-meta-toolchain sucess
$ bitbake lib32-meta-toolchain
//Hongxu
The following changes since commit ccf5a4d2342c4fd40e4e0b332ea7e34e0bf175d4:
build-appliance-image: Update to dizzy head revision (2014-10-11 08:11:17 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib hongxu/fix-lib32-meta-toolchain
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-lib32-meta-toolchain
Hongxu Jia (1):
multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain
build failure
meta/classes/multilib.bbclass | 1 +
meta/lib/oe/package_manager.py | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
--
1.9.1
^ permalink raw reply [flat|nested] 9+ messages in thread* [PATCH 1/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
2014-10-15 5:58 [PATCH 0/1] " Hongxu Jia
@ 2014-10-15 5:59 ` Hongxu Jia
2014-10-15 7:53 ` Hongxu Jia
0 siblings, 1 reply; 9+ messages in thread
From: Hongxu Jia @ 2014-10-15 5:59 UTC (permalink / raw)
To: openembedded-core, ross.burton
There is a failure to build lib32-meta-toolchain:
...
|ERROR: lib32-packagegroup-core-standalone-sdk-target not found in the base
feeds (qemux86_64 x86 noarch any all).
...
In package_manager.py, the variable 'DEFAULTTUNE_virtclass-multilib-lib32'
is used to process multilib image/toolchain. But for the build of lib32-
meta-toolchain, the value of 'DEFAULTTUNE_virtclass-multilib-lib32' is
deleted. In 'bitbake lib32-meta-toolchain -e', we got:
...
|# $DEFAULTTUNE_virtclass-multilib-lib32 [2 operations]
|# set? /home/jiahongxu/yocto/build-20141010-yocto/conf/local.conf:237
|# "x86"
|# del data_smart.py:406 [finalize]
|# ""
|# pre-expansion value:
|# "None"
...
The commit 899d45b90061eb3cf3e71029072eee42cd80930c in oe-core has delete
it in DataSmart.finalize
...
Author: Richard Purdie <richard.purdie@linuxfoundation.org>
Date: Tue May 31 23:52:50 2011 +0100
bitbake/data_smart: Change overrides behaviour to remove
expanded variables from the datastore
...
We add an internal variable 'DEFAULTTUNE_ML_<multilib>', assign it with the
value of 'DEFAULTTUNE_virtclass-multilib-lib32' before deleting, and read
it in package_manager.py for multilib processing.
[YOCTO #6842]
Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
---
meta/classes/multilib.bbclass | 1 +
meta/lib/oe/package_manager.py | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/meta/classes/multilib.bbclass b/meta/classes/multilib.bbclass
index 6e143dd..6aad894 100644
--- a/meta/classes/multilib.bbclass
+++ b/meta/classes/multilib.bbclass
@@ -60,6 +60,7 @@ python multilib_virtclass_handler () {
newtune = e.data.getVar("DEFAULTTUNE_" + "virtclass-multilib-" + variant, False)
if newtune:
e.data.setVar("DEFAULTTUNE", newtune)
+ e.data.setVar('DEFAULTTUNE_ML_%s' % variant, newtune)
}
addhandler multilib_virtclass_handler
diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
index 27fdf26..ff66ece 100644
--- a/meta/lib/oe/package_manager.py
+++ b/meta/lib/oe/package_manager.py
@@ -61,7 +61,7 @@ class RpmIndexer(Indexer):
eext = ext.split(':')
if len(eext) > 1 and eext[0] == 'multilib':
localdata = bb.data.createCopy(self.d)
- default_tune_key = "DEFAULTTUNE_virtclass-multilib-" + eext[1]
+ default_tune_key = "DEFAULTTUNE_ML_" + eext[1]
default_tune = localdata.getVar(default_tune_key, False)
if default_tune:
localdata.setVar("DEFAULTTUNE", default_tune)
--
1.9.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* Re: [PATCH 1/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure
2014-10-15 5:59 ` [PATCH 1/1] " Hongxu Jia
@ 2014-10-15 7:53 ` Hongxu Jia
0 siblings, 0 replies; 9+ messages in thread
From: Hongxu Jia @ 2014-10-15 7:53 UTC (permalink / raw)
To: openembedded-core, ross.burton
On 10/15/2014 01:59 PM, Hongxu Jia wrote:
> @@ -61,7 +61,7 @@ class RpmIndexer(Indexer):
> eext = ext.split(':')
> if len(eext) > 1 and eext[0] == 'multilib':
> localdata = bb.data.createCopy(self.d)
> - default_tune_key = "DEFAULTTUNE_virtclass-multilib-" + eext[1]
> + default_tune_key = "DEFAULTTUNE_ML_" + eext[1]
> default_tune = localdata.getVar(default_tune_key, False)
> if default_tune:
> localdata.setVar("DEFAULTTUNE", default_tune)
It caused build failure of meta-toolchain, in order to avoid it, we
should use DEFAULTTUNE_virtclass-multilib-lib32 first, if it is not
available, and try to use DEFAULTTUNE_ML_<multilib>
So it does not affect previous build workflow.
Please drop it, V2 incoming
//Hongxu
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2014-10-15 13:57 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-15 9:23 [PATCH V2 0/1] multilib.bbclass/package_manager.py: fix <multilib>-meta-toolchain build failure Hongxu Jia
2014-10-15 9:23 ` [PATCH 1/1] " Hongxu Jia
2014-10-15 11:00 ` Laurentiu Palcu
2014-10-15 11:32 ` Hongxu Jia
-- strict thread matches above, loose matches on Subject: below --
2014-10-15 12:31 [PATCH V3 0/1] " Hongxu Jia
2014-10-15 12:31 ` [PATCH 1/1] " Hongxu Jia
2014-10-15 13:27 ` Laurentiu Palcu
2014-10-15 13:57 ` Hongxu Jia
2014-10-15 5:58 [PATCH 0/1] " Hongxu Jia
2014-10-15 5:59 ` [PATCH 1/1] " Hongxu Jia
2014-10-15 7:53 ` Hongxu Jia
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox