Two fixes related to uninative-tarball
cover Two fixes related to uninative-tarball
The following changes since commit c9b06c79ed8a082d1b385e9f61721aeeda9bf1af:
init-install-efi.sh: fix gummiboot entry installation (2015-04-21 07:19:07 +0100)
are available in the git repository at:
git://git.openembedded.org/openembedded-core-contrib ChenQi/uninative-tarball-fixes
http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=ChenQi/uninative-tarball-fixes
Chen Qi (2):
uninative-tarball: delete the packagedata task
populate_sdk_base: avoid executing empty function
meta/classes/populate_sdk_base.bbclass | 6 +++++- meta/recipes-core/meta/uninative-tarball.bb | 1 + 2 files changed, 6 insertions(+), 1 deletion(-)
Signature · 1 line
1.9.1
PATCH 1/2 uninative-tarball: delete the packagedata task
This task is meaningless for uninative-tarball as the package task has been deleted. Besides, sometimes it would cause problems. To reproduce, use the following command.
bitbake uninative-tarball -c cleansstate && bitbake uninative-tarball && bitbake uninative-tarball -c clean && bitbake uninative-tarball
The error is something like below.
File: 'sstate.bbclass', lineno: 33, function: sstate_installpkg
0029: bb.build.exec_func(f, d)
0030:
0031: for state in ss['dirs']:
0032: prepdir(state[1])
*** 0033: os.rename(sstateinst + state[0], state[1])
0034: sstate_install(ss, d)
0035:
0036: for plain in ss['plaindirs']:
0037: workdir = d.getVar('WORKDIR', True)Exception: OSError: [Errno 2] No such file or directory
--- meta/recipes-core/meta/uninative-tarball.bb | 1 + 1 file changed, 1 insertion(+)
meta/recipes-core/meta/uninative-tarball.bb +1 -0
@@ -23,6 +23,7 @@ inherit populate_sdk deltask install deltask package +deltask packagedata SDK_DEPENDS += "patchelf-native"
Signature · 1 line
1.9.1
PATCH 2/2 populate_sdk_base: avoid executing empty function
In reply to Chen Qi`bitbake uninative-tarball' raises the following warning.
WARNING: Function doesn't exist
This is because SDK_PACKAGING_FUNC is set to "" in its recipe. Anyway, we need to check this variable to avoid executing empty function.
--- meta/classes/populate_sdk_base.bbclass | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
meta/classes/populate_sdk_base.bbclass +5 -1
@@ -94,7 +94,11 @@ fakeroot python do_populate_sdk() { bb.build.exec_func("tar_sdk", d) - bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d) + sdk_packaging_func = d.getVar("SDK_PACKAGING_FUNC", True) + if sdk_packaging_func: + sdk_packaging_func = sdk_packaging_func.strip() + if sdk_packaging_func != "": + bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d) } fakeroot create_sdk_files() {
Signature · 1 line
1.9.1
Re: [PATCH 2/2] populate_sdk_base: avoid executing empty function
Quoted 17 lines · Chen Qi
`bitbake uninative-tarball' raises the following warning.
WARNING: Function doesn't exist
This is because
SDK_PACKAGING_FUNCis set to "" in its recipe. Anyway, we need to check this variable to avoid executing empty function.Signed-off-by Chen Qi <[email protected]>--- meta/classes/populate_sdk_base.bbclass | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)meta/classes/populate_sdk_base.bbclass +0
-0
meta/classes/populate_sdk_base.bbclass fakeroot python do_populate_sdk() { · line 101
Quoted 9 lines
meta/classes/populate_sdk_base.bbclass +5
-1@@ -94,7 +94,11 @@ fakeroot python do_populate_sdk() { bb.build.exec_func("tar_sdk", d) - bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d) + sdk_packaging_func = d.getVar("SDK_PACKAGING_FUNC", True) + if sdk_packaging_func: + sdk_packaging_func = sdk_packaging_func.strip() + if sdk_packaging_func != "": + bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d)
This is slightly overcomplicated. You can just do something like:
sdk_packaging_func = d.getVar("SDK_PACKAGING_FUNC", True) or "" if sdk_packaging_func.strip():
bb.build.exec_func(sdk_packaging_func, d)
Cheers,
Richard
Re: [PATCH 2/2] populate_sdk_base: avoid executing empty function
Quoted 29 lines · Richard Purdie
Quoted 17 lines · Chen Qi
`bitbake uninative-tarball' raises the following warning.
WARNING: Function doesn't exist
This is because
SDK_PACKAGING_FUNCis set to "" in its recipe. Anyway, we need to check this variable to avoid executing empty function.Signed-off-by Chen Qi <[email protected]>--- meta/classes/populate_sdk_base.bbclass | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)meta/classes/populate_sdk_base.bbclass +0
-0meta/classes/populate_sdk_base.bbclass fakeroot python do_populate_sdk() { · line 101
Quoted 9 lines
meta/classes/populate_sdk_base.bbclass +5
-1@@ -94,7 +94,11 @@ fakeroot python do_populate_sdk() { bb.build.exec_func("tar_sdk", d) - bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d) + sdk_packaging_func = d.getVar("SDK_PACKAGING_FUNC", True) + if sdk_packaging_func: + sdk_packaging_func = sdk_packaging_func.strip() + if sdk_packaging_func != "": + bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d)This is slightly overcomplicated. You can just do something like:
Quoted 10 lines
sdk_packaging_func=d.getVar("SDK_PACKAGING_FUNC", True)or "" ifsdk_packaging_func.strip():
bb.build.exec_func(sdk_packaging_func, d)Cheers,
Richard
Thanks a lot.
I'll send out V2.
Best Regards,
Chen Qi
Re: [PATCH 2/2] populate_sdk_base: avoid executing empty function
Quoted 32 lines · On Friday 24 April 2015 16:14:36 ChenQi wrote:
Quoted 31 lines · Richard Purdie
Quoted 18 lines · Chen Qi
`bitbake uninative-tarball' raises the following warning.
WARNING: Function doesn't exist
This is because
SDK_PACKAGING_FUNCis set to "" in its recipe. Anyway, we need to check this variable to avoid executing empty function.Signed-off-by Chen Qi <[email protected]>---
meta/classes/populate_sdk_base.bbclass | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)(quoted diff) +0
-0b/meta/classes/populate_sdk_base.bbclass index 5c07693..6e3e84f 100644
meta/classes/populate_sdk_base.bbclass fakeroot python do_populate_sdk() { · line 101
Quoted 9 lines
meta/classes/populate_sdk_base.bbclass +5
-1@@ -94,7 +94,11 @@ fakeroot python do_populate_sdk() { bb.build.exec_func("tar_sdk", d) - bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d) + sdk_packaging_func = d.getVar("SDK_PACKAGING_FUNC", True) + if sdk_packaging_func: + sdk_packaging_func = sdk_packaging_func.strip() + if sdk_packaging_func != "": + bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d)This is slightly overcomplicated. You can just do something like:
Quoted 8 lines
Quoted 4 lines
sdk_packaging_func=d.getVar("SDK_PACKAGING_FUNC", True)or ""if
sdk_packaging_func.strip():
bb.build.exec_func(sdk_packaging_func, d)Thanks a lot.
I'll send out V2.
Could you also please add [YOCTO #7598] to the commit message since that covers this issue:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=7598
Thanks,
Paul
Signature · 2 lines
Paul Eggleton Intel Open Source Technology Centre