* [PATCH] archiver.bbclass: fix an exception of the mode configured
@ 2015-11-16 5:33 Jian Liu
2015-11-16 15:08 ` Burton, Ross
0 siblings, 1 reply; 6+ messages in thread
From: Jian Liu @ 2015-11-16 5:33 UTC (permalink / raw)
To: openembedded-core
gcc-source does not have the task do_configure, so if configured mode is set,
the task do_ar_configured depends on do_configure.
This will cause an error.
Signed-off-by: Jian Liu <jian.liu@windriver.com>
---
archiver.bbclass | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/meta/classes/archiver.bbclass b/meta/classes/archiver.bbclass
index 41a552c..76571fb 100644
--- a/meta/classes/archiver.bbclass
+++ b/meta/classes/archiver.bbclass
@@ -73,8 +73,14 @@ python () {
# We can't use "addtask do_ar_configured after do_configure" since it
# will cause the deptask of do_populate_sysroot to run not matter what
# archives we need, so we add the depends here.
- d.appendVarFlag('do_ar_configured', 'depends', ' %s:do_configure' % pn)
- d.appendVarFlag('do_deploy_archives', 'depends', ' %s:do_ar_configured' % pn)
+ ##
+ # For some specific packages like gcc-source, do_configure may be deleted.
+ if d.getVarFlag('do_configure', 'noexec') == '1' or 'do_configure' not in d.getVar('__BBTASKS', False):
+ pass
+ else:
+ bb.build.addtask('do_ar_configured', None, 'do_unpack_and_patch', d)
+ d.appendVarFlag('do_ar_configured', 'depends', ' %s:do_configure' % pn)
+ d.appendVarFlag('do_deploy_archives', 'depends', ' %s:do_ar_configured' % pn)
elif ar_src:
bb.fatal("Invalid ARCHIVER_MODE[src]: %s" % ar_src)
@@ -348,7 +354,6 @@ do_deploy_archives[sstate-outputdirs] = "${DEPLOY_DIR_SRC}"
addtask do_ar_original after do_unpack
addtask do_ar_patched after do_unpack_and_patch
-addtask do_ar_configured after do_unpack_and_patch
addtask do_dumpdata
addtask do_ar_recipe
addtask do_deploy_archives before do_build
^ permalink raw reply related [flat|nested] 6+ messages in thread* Re: [PATCH] archiver.bbclass: fix an exception of the mode configured
2015-11-16 5:33 [PATCH] archiver.bbclass: fix an exception of the mode configured Jian Liu
@ 2015-11-16 15:08 ` Burton, Ross
2015-11-17 5:31 ` Jian Liu
0 siblings, 1 reply; 6+ messages in thread
From: Burton, Ross @ 2015-11-16 15:08 UTC (permalink / raw)
To: Jian Liu; +Cc: OE-core
[-- Attachment #1: Type: text/plain, Size: 373 bytes --]
On 16 November 2015 at 05:33, Jian Liu <jian.liu@windriver.com> wrote:
> + if d.getVarFlag('do_configure', 'noexec') == '1' or
> 'do_configure' not in d.getVar('__BBTASKS', False):
>
__BBTASKS is internal so shouldn't beused unless you have an awesome
reason. Richard tells me that d.getVarFlag('do_configure', 'task') is
probably what you want.
Ross
[-- Attachment #2: Type: text/html, Size: 900 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [PATCH] archiver.bbclass: fix an exception of the mode configured
2015-11-16 15:08 ` Burton, Ross
@ 2015-11-17 5:31 ` Jian Liu
2015-12-22 5:08 ` Jian Liu
0 siblings, 1 reply; 6+ messages in thread
From: Jian Liu @ 2015-11-17 5:31 UTC (permalink / raw)
To: Burton, Ross; +Cc: OE-core
[-- Attachment #1: Type: text/plain, Size: 1048 bytes --]
Hi Ross,
I check the values of d.getVarFlag('do_configure', 'task') and
d.getVarFlag('do_unpack', 'task') for gcc-source.
But it seems that both values are 1.
I use the following command to get the values,
os.system("echo 'do_unpack=%s, do_configure=%s, noexec=%s, pn=%s' >>
/tmp/task.txt" %(d.getVarFlag('do_unpack',
'task'),d.getVarFlag('do_configure',
'task'),d.getVarFlag('do_configure', 'noexec'),pn))
Does I miss something?
I query several people about how to get the current tasks of a recipe.
But I get nothing more.
Thanks!
Jian
On 2015年11月16日 23:08, Burton, Ross wrote:
>
> On 16 November 2015 at 05:33, Jian Liu <jian.liu@windriver.com
> <mailto:jian.liu@windriver.com>> wrote:
>
> + if d.getVarFlag('do_configure', 'noexec') == '1' or
> 'do_configure' not in d.getVar('__BBTASKS', False):
>
>
> __BBTASKS is internal so shouldn't beused unless you have an awesome
> reason. Richard tells me that d.getVarFlag('do_configure', 'task') is
> probably what you want.
>
> Ross
[-- Attachment #2: Type: text/html, Size: 2336 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [PATCH] archiver.bbclass: fix an exception of the mode configured
2015-11-17 5:31 ` Jian Liu
@ 2015-12-22 5:08 ` Jian Liu
0 siblings, 0 replies; 6+ messages in thread
From: Jian Liu @ 2015-12-22 5:08 UTC (permalink / raw)
To: Burton, Ross; +Cc: OE-core
[-- Attachment #1: Type: text/plain, Size: 1159 bytes --]
Ping
On 2015年11月17日 13:31, Jian Liu wrote:
> Hi Ross,
>
> I check the values of d.getVarFlag('do_configure', 'task') and
> d.getVarFlag('do_unpack', 'task') for gcc-source.
> But it seems that both values are 1.
>
> I use the following command to get the values,
> os.system("echo 'do_unpack=%s, do_configure=%s, noexec=%s, pn=%s' >>
> /tmp/task.txt" %(d.getVarFlag('do_unpack',
> 'task'),d.getVarFlag('do_configure',
> 'task'),d.getVarFlag('do_configure', 'noexec'),pn))
>
> Does I miss something?
>
> I query several people about how to get the current tasks of a recipe.
> But I get nothing more.
>
> Thanks!
> Jian
>
> On 2015年11月16日 23:08, Burton, Ross wrote:
>>
>> On 16 November 2015 at 05:33, Jian Liu <jian.liu@windriver.com
>> <mailto:jian.liu@windriver.com>> wrote:
>>
>> + if d.getVarFlag('do_configure', 'noexec') == '1' or
>> 'do_configure' not in d.getVar('__BBTASKS', False):
>>
>>
>> __BBTASKS is internal so shouldn't beused unless you have an awesome
>> reason. Richard tells me that d.getVarFlag('do_configure', 'task')
>> is probably what you want.
>>
>> Ross
>
>
>
[-- Attachment #2: Type: text/html, Size: 2735 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH] archiver.bbclass: fix an exception of the mode configured
@ 2015-11-13 10:09 Jian Liu
2015-11-16 5:17 ` Jian Liu
0 siblings, 1 reply; 6+ messages in thread
From: Jian Liu @ 2015-11-13 10:09 UTC (permalink / raw)
To: openembedded-core
gcc-source does not have the task do_configure, so if configured mode is set,
the task do_ar_configured depends on do_configure.
This will cause an error.
Signed-off-by: Jian Liu <jian.liu@windriver.com>
---
archiver.bbclass | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/meta/classes/archiver.bbclass b/meta/classes/archiver.bbclass
index 41a552c..3d1952a 100644
--- a/meta/classes/archiver.bbclass
+++ b/meta/classes/archiver.bbclass
@@ -73,8 +73,18 @@ python () {
# We can't use "addtask do_ar_configured after do_configure" since it
# will cause the deptask of do_populate_sysroot to run not matter what
# archives we need, so we add the depends here.
- d.appendVarFlag('do_ar_configured', 'depends', ' %s:do_configure' % pn)
- d.appendVarFlag('do_deploy_archives', 'depends', ' %s:do_ar_configured' % pn)
+ ##
+ # For some specific packages like gcc-source, do_configure may be deleted.
+ deltask = d.getVar('__BBDELTASKS', False)
+ noexec = d.getVarFlag('do_configure', 'noexec')
+ os.system("echo deltask=%s, noexec=%s, pn=%s >> /tmp/tasks.txt" %(deltask,noexec,pn))
+ #if 'do_configure' in (d.getVar('__BBDELTASKS', False) or []) or d.getVarFlag('do_configure', 'noexec') == '1':
+ if d.getVarFlag('do_configure', 'noexec') == '1' or 'do_configure' not in d.getVar('__BBTASKS', False):
+ pass
+ else:
+ bb.build.addtask('do_ar_configured', None, 'do_unpack_and_patch', d)
+ d.appendVarFlag('do_ar_configured', 'depends', ' %s:do_configure' % pn)
+ d.appendVarFlag('do_deploy_archives', 'depends', ' %s:do_ar_configured' % pn)
elif ar_src:
bb.fatal("Invalid ARCHIVER_MODE[src]: %s" % ar_src)
@@ -348,7 +358,6 @@ do_deploy_archives[sstate-outputdirs] = "${DEPLOY_DIR_SRC}"
addtask do_ar_original after do_unpack
addtask do_ar_patched after do_unpack_and_patch
-addtask do_ar_configured after do_unpack_and_patch
addtask do_dumpdata
addtask do_ar_recipe
addtask do_deploy_archives before do_build
^ permalink raw reply related [flat|nested] 6+ messages in thread* Re: [PATCH] archiver.bbclass: fix an exception of the mode configured
2015-11-13 10:09 Jian Liu
@ 2015-11-16 5:17 ` Jian Liu
0 siblings, 0 replies; 6+ messages in thread
From: Jian Liu @ 2015-11-16 5:17 UTC (permalink / raw)
To: openembedded-core
Hi all,
Sorry for a mistake. Please ignore this patch
Jian
On 2015年11月13日 18:09, Jian Liu wrote:
> gcc-source does not have the task do_configure, so if configured mode is set,
> the task do_ar_configured depends on do_configure.
> This will cause an error.
>
> Signed-off-by: Jian Liu <jian.liu@windriver.com>
> ---
> archiver.bbclass | 15 ++++++++++++---
> 1 file changed, 12 insertions(+), 3 deletions(-)
>
> diff --git a/meta/classes/archiver.bbclass b/meta/classes/archiver.bbclass
> index 41a552c..3d1952a 100644
> --- a/meta/classes/archiver.bbclass
> +++ b/meta/classes/archiver.bbclass
> @@ -73,8 +73,18 @@ python () {
> # We can't use "addtask do_ar_configured after do_configure" since it
> # will cause the deptask of do_populate_sysroot to run not matter what
> # archives we need, so we add the depends here.
> - d.appendVarFlag('do_ar_configured', 'depends', ' %s:do_configure' % pn)
> - d.appendVarFlag('do_deploy_archives', 'depends', ' %s:do_ar_configured' % pn)
> + ##
> + # For some specific packages like gcc-source, do_configure may be deleted.
> + deltask = d.getVar('__BBDELTASKS', False)
> + noexec = d.getVarFlag('do_configure', 'noexec')
> + os.system("echo deltask=%s, noexec=%s, pn=%s >> /tmp/tasks.txt" %(deltask,noexec,pn))
> + #if 'do_configure' in (d.getVar('__BBDELTASKS', False) or []) or d.getVarFlag('do_configure', 'noexec') == '1':
> + if d.getVarFlag('do_configure', 'noexec') == '1' or 'do_configure' not in d.getVar('__BBTASKS', False):
> + pass
> + else:
> + bb.build.addtask('do_ar_configured', None, 'do_unpack_and_patch', d)
> + d.appendVarFlag('do_ar_configured', 'depends', ' %s:do_configure' % pn)
> + d.appendVarFlag('do_deploy_archives', 'depends', ' %s:do_ar_configured' % pn)
> elif ar_src:
> bb.fatal("Invalid ARCHIVER_MODE[src]: %s" % ar_src)
>
> @@ -348,7 +358,6 @@ do_deploy_archives[sstate-outputdirs] = "${DEPLOY_DIR_SRC}"
>
> addtask do_ar_original after do_unpack
> addtask do_ar_patched after do_unpack_and_patch
> -addtask do_ar_configured after do_unpack_and_patch
> addtask do_dumpdata
> addtask do_ar_recipe
> addtask do_deploy_archives before do_build
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2015-12-22 5:08 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-16 5:33 [PATCH] archiver.bbclass: fix an exception of the mode configured Jian Liu
2015-11-16 15:08 ` Burton, Ross
2015-11-17 5:31 ` Jian Liu
2015-12-22 5:08 ` Jian Liu
-- strict thread matches above, loose matches on Subject: below --
2015-11-13 10:09 Jian Liu
2015-11-16 5:17 ` Jian Liu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox