* go-bootstrap / go-native conflict during do_rootfs
@ 2017-03-20 13:47 Kristian Amlie
2017-03-20 14:49 ` Khem Raj
0 siblings, 1 reply; 6+ messages in thread
From: Kristian Amlie @ 2017-03-20 13:47 UTC (permalink / raw)
To: OE-core
First of all, kudos to Khem Raj for the hard work on the go compiler
support, this will help a lot!
However, I have one problem when my project reaches do_rootfs:
----------------------------------------------
ERROR: core-image-full-cmdline-1.0-r0 do_rootfs: Error executing a
python function in exec_python_func() autogenerated:
The stack trace of python calls that resulted in this exception/failure was:
File: 'exec_python_func() autogenerated', lineno: 2, function: <module>
0001:
*** 0002:extend_recipe_sysroot(d)
0003:
File: '/home/kristian/code/poky/meta/classes/staging.bbclass', lineno:
623, function: extend_recipe_sysroot
0619: dest = newmanifest[l]
0620: if l.endswith("/"):
0621: staging_copydir(l, targetdir, dest,
seendirs)
0622: continue
*** 0623: staging_copyfile(l, targetdir, dest,
postinsts, seendirs)
0624:
0625: for f in fixme:
0626: if f == '':
0627: staging_processfixme(fixme[f], recipesysroot,
recipesysroot, recipesysrootnative, d)
File: '/home/kristian/code/poky/meta/classes/staging.bbclass', lineno:
269, function: staging_copyfile
0265: os.symlink(linkto, dest)
0266: #bb.warn(c)
0267: else:
0268: try:
*** 0269: os.link(c, dest)
0270: except OSError as err:
0271: if err.errno == errno.EXDEV:
0272: bb.utils.copyfile(c, dest)
0273: else:
Exception: FileExistsError: [Errno 17] File exists:
'/home/kristian/code/poky/build/tmp/sysroots-components/x86_64/go-bootstrap-native/usr/bin/go'
->
'/home/kristian/code/poky/build/tmp/work/vexpress_qemu-poky-linux-gnueabi/core-image-full-cmdline/1.0-r0/recipe-sysroot-native/usr/bin/go'
ERROR: core-image-full-cmdline-1.0-r0 do_rootfs: Function failed:
extend_recipe_sysroot
ERROR: Logfile of failure stored in:
/home/kristian/code/poky/build/tmp/work/vexpress_qemu-poky-linux-gnueabi/core-image-full-cmdline/1.0-r0/temp/log.do_rootfs.18987
ERROR: Task
(/home/kristian/code/poky/meta/recipes-extended/images/core-image-full-cmdline.bb:do_rootfs)
failed with exit code '1'
NOTE: Tasks Summary: Attempted 3634 tasks of which 3589 didn't need to
be rerun and 1 failed.
Summary: 1 task failed:
/home/kristian/code/poky/meta/recipes-extended/images/core-image-full-cmdline.bb:do_rootfs
Summary: There were 3 WARNING messages shown.
Summary: There were 2 ERROR messages shown, returning a non-zero exit code.
--------------------------------------------------
Additionally, in the logs I found these two snippets:
--------------------------------------------------
Considering setscene task: ['go-native', 'do_populate_sysroot']
considering dependency: ['go-native', 'do_populate_sysroot']
considering dependency: ['mender-artifact-native', 'do_populate_sysroot']
Adding dependency on go-native
...
Considering setscene task: ['go-bootstrap-native', 'do_populate_sysroot']
considering dependency: ['go-native', 'do_populate_sysroot']
Adding dependency on go-bootstrap-native
--------------------------------------------------
which lead me to believe that all dependencies are being pulled in
simultaneously by do_rootfs, but go-native and go-bootstrap-native are
in fact mutually exclusive, since they install to the sysroot in the
same location. Note that both compilers build just fine, it's only at
the do_rootfs stage that this shows up.
I think the oe-meta-go layer solved this by having go-bootstrap-native
install in a different location, but I'm unsure what is the best
approach for OE.
Thoughts?
--
Kristian
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: go-bootstrap / go-native conflict during do_rootfs
2017-03-20 13:47 go-bootstrap / go-native conflict during do_rootfs Kristian Amlie
@ 2017-03-20 14:49 ` Khem Raj
2017-03-20 15:17 ` Richard Purdie
0 siblings, 1 reply; 6+ messages in thread
From: Khem Raj @ 2017-03-20 14:49 UTC (permalink / raw)
To: Kristian Amlie; +Cc: OE-core
On Mon, Mar 20, 2017 at 6:47 AM, Kristian Amlie
<kristian.amlie@mender.io> wrote:
> First of all, kudos to Khem Raj for the hard work on the go compiler
> support, this will help a lot!
>
> However, I have one problem when my project reaches do_rootfs:
>
> ----------------------------------------------
> ERROR: core-image-full-cmdline-1.0-r0 do_rootfs: Error executing a
> python function in exec_python_func() autogenerated:
>
> The stack trace of python calls that resulted in this exception/failure was:
> File: 'exec_python_func() autogenerated', lineno: 2, function: <module>
> 0001:
> *** 0002:extend_recipe_sysroot(d)
> 0003:
> File: '/home/kristian/code/poky/meta/classes/staging.bbclass', lineno:
> 623, function: extend_recipe_sysroot
> 0619: dest = newmanifest[l]
> 0620: if l.endswith("/"):
> 0621: staging_copydir(l, targetdir, dest,
> seendirs)
> 0622: continue
> *** 0623: staging_copyfile(l, targetdir, dest,
> postinsts, seendirs)
> 0624:
> 0625: for f in fixme:
> 0626: if f == '':
> 0627: staging_processfixme(fixme[f], recipesysroot,
> recipesysroot, recipesysrootnative, d)
> File: '/home/kristian/code/poky/meta/classes/staging.bbclass', lineno:
> 269, function: staging_copyfile
> 0265: os.symlink(linkto, dest)
> 0266: #bb.warn(c)
> 0267: else:
> 0268: try:
> *** 0269: os.link(c, dest)
> 0270: except OSError as err:
> 0271: if err.errno == errno.EXDEV:
> 0272: bb.utils.copyfile(c, dest)
> 0273: else:
> Exception: FileExistsError: [Errno 17] File exists:
> '/home/kristian/code/poky/build/tmp/sysroots-components/x86_64/go-bootstrap-native/usr/bin/go'
> ->
> '/home/kristian/code/poky/build/tmp/work/vexpress_qemu-poky-linux-gnueabi/core-image-full-cmdline/1.0-r0/recipe-sysroot-native/usr/bin/go'
>
> ERROR: core-image-full-cmdline-1.0-r0 do_rootfs: Function failed:
> extend_recipe_sysroot
> ERROR: Logfile of failure stored in:
> /home/kristian/code/poky/build/tmp/work/vexpress_qemu-poky-linux-gnueabi/core-image-full-cmdline/1.0-r0/temp/log.do_rootfs.18987
> ERROR: Task
> (/home/kristian/code/poky/meta/recipes-extended/images/core-image-full-cmdline.bb:do_rootfs)
> failed with exit code '1'
> NOTE: Tasks Summary: Attempted 3634 tasks of which 3589 didn't need to
> be rerun and 1 failed.
>
> Summary: 1 task failed:
>
> /home/kristian/code/poky/meta/recipes-extended/images/core-image-full-cmdline.bb:do_rootfs
> Summary: There were 3 WARNING messages shown.
> Summary: There were 2 ERROR messages shown, returning a non-zero exit code.
> --------------------------------------------------
>
> Additionally, in the logs I found these two snippets:
>
> --------------------------------------------------
> Considering setscene task: ['go-native', 'do_populate_sysroot']
> considering dependency: ['go-native', 'do_populate_sysroot']
> considering dependency: ['mender-artifact-native', 'do_populate_sysroot']
> Adding dependency on go-native
> ...
> Considering setscene task: ['go-bootstrap-native', 'do_populate_sysroot']
> considering dependency: ['go-native', 'do_populate_sysroot']
> Adding dependency on go-bootstrap-native
> --------------------------------------------------
>
> which lead me to believe that all dependencies are being pulled in
> simultaneously by do_rootfs, but go-native and go-bootstrap-native are
> in fact mutually exclusive, since they install to the sysroot in the
> same location. Note that both compilers build just fine, it's only at
> the do_rootfs stage that this shows up.
>
> I think the oe-meta-go layer solved this by having go-bootstrap-native
> install in a different location, but I'm unsure what is the best
> approach for OE.
go-bootstrap is only needed for few recipes. I think we should find out
a way to keep this dep limited to those recipes and not reflect in final
image rootfs creation. That seems to be not useful.
>
> Thoughts?
>
> --
> Kristian
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: go-bootstrap / go-native conflict during do_rootfs
2017-03-20 14:49 ` Khem Raj
@ 2017-03-20 15:17 ` Richard Purdie
2017-03-20 15:29 ` Khem Raj
0 siblings, 1 reply; 6+ messages in thread
From: Richard Purdie @ 2017-03-20 15:17 UTC (permalink / raw)
To: Khem Raj, Kristian Amlie; +Cc: OE-core
On Mon, 2017-03-20 at 07:49 -0700, Khem Raj wrote:
> On Mon, Mar 20, 2017 at 6:47 AM, Kristian Amlie
> <kristian.amlie@mender.io> wrote:
> >
> > --------------------------------------------------
> >
> > Additionally, in the logs I found these two snippets:
> >
> > --------------------------------------------------
> > Considering setscene task: ['go-native', 'do_populate_sysroot']
> > considering dependency: ['go-native', 'do_populate_sysroot']
> > considering dependency: ['mender-artifact-native',
> > 'do_populate_sysroot']
> > Adding dependency on go-native
> > ...
> > Considering setscene task: ['go-bootstrap-native',
> > 'do_populate_sysroot']
> > considering dependency: ['go-native', 'do_populate_sysroot']
> > Adding dependency on go-bootstrap-native
> > --------------------------------------------------
> >
> > which lead me to believe that all dependencies are being pulled in
> > simultaneously by do_rootfs, but go-native and go-bootstrap-native
> > are
> > in fact mutually exclusive, since they install to the sysroot in
> > the
> > same location. Note that both compilers build just fine, it's only
> > at
> > the do_rootfs stage that this shows up.
> >
> > I think the oe-meta-go layer solved this by having go-bootstrap-
> > native
> > install in a different location, but I'm unsure what is the best
> > approach for OE.
> go-bootstrap is only needed for few recipes. I think we should find
> out
> a way to keep this dep limited to those recipes and not reflect in
> final
> image rootfs creation. That seems to be not useful.
There is code in sstate.bbclass in setscene_depvalid:
# Consider sysroot depending on sysroot tasks
if taskdependees[task][1] == 'do_populate_sysroot' and taskdependees[dep][1] == 'do_populate_sysroot':
[...]
# Nothing need depend on libc-initial/gcc-cross-initial
if "-initial" in taskdependees[task][0]:
continue
so if go-bootstrap-native were renamed go-native-initial, things might
happen to work better...
Cheers,
Richard
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: go-bootstrap / go-native conflict during do_rootfs
2017-03-20 15:17 ` Richard Purdie
@ 2017-03-20 15:29 ` Khem Raj
2017-03-20 16:50 ` Khem Raj
0 siblings, 1 reply; 6+ messages in thread
From: Khem Raj @ 2017-03-20 15:29 UTC (permalink / raw)
To: Richard Purdie; +Cc: OE-core
On Mon, Mar 20, 2017 at 8:17 AM, Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
> On Mon, 2017-03-20 at 07:49 -0700, Khem Raj wrote:
>> On Mon, Mar 20, 2017 at 6:47 AM, Kristian Amlie
>> <kristian.amlie@mender.io> wrote:
>> >
>> > --------------------------------------------------
>> >
>> > Additionally, in the logs I found these two snippets:
>> >
>> > --------------------------------------------------
>> > Considering setscene task: ['go-native', 'do_populate_sysroot']
>> > considering dependency: ['go-native', 'do_populate_sysroot']
>> > considering dependency: ['mender-artifact-native',
>> > 'do_populate_sysroot']
>> > Adding dependency on go-native
>> > ...
>> > Considering setscene task: ['go-bootstrap-native',
>> > 'do_populate_sysroot']
>> > considering dependency: ['go-native', 'do_populate_sysroot']
>> > Adding dependency on go-bootstrap-native
>> > --------------------------------------------------
>> >
>> > which lead me to believe that all dependencies are being pulled in
>> > simultaneously by do_rootfs, but go-native and go-bootstrap-native
>> > are
>> > in fact mutually exclusive, since they install to the sysroot in
>> > the
>> > same location. Note that both compilers build just fine, it's only
>> > at
>> > the do_rootfs stage that this shows up.
>> >
>> > I think the oe-meta-go layer solved this by having go-bootstrap-
>> > native
>> > install in a different location, but I'm unsure what is the best
>> > approach for OE.
>> go-bootstrap is only needed for few recipes. I think we should find
>> out
>> a way to keep this dep limited to those recipes and not reflect in
>> final
>> image rootfs creation. That seems to be not useful.
>
> There is code in sstate.bbclass in setscene_depvalid:
>
> # Consider sysroot depending on sysroot tasks
> if taskdependees[task][1] == 'do_populate_sysroot' and taskdependees[dep][1] == 'do_populate_sysroot':
> [...]
> # Nothing need depend on libc-initial/gcc-cross-initial
> if "-initial" in taskdependees[task][0]:
> continue
>
> so if go-bootstrap-native were renamed go-native-initial, things might
> happen to work better...
ah thats right, forgot about that, I think we should rename the recipe
to go-native-initial
>
> Cheers,
>
> Richard
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: go-bootstrap / go-native conflict during do_rootfs
2017-03-20 15:29 ` Khem Raj
@ 2017-03-20 16:50 ` Khem Raj
2017-03-21 6:13 ` Kristian Amlie
0 siblings, 1 reply; 6+ messages in thread
From: Khem Raj @ 2017-03-20 16:50 UTC (permalink / raw)
To: Richard Purdie; +Cc: OE-core
On Mon, Mar 20, 2017 at 8:29 AM, Khem Raj <raj.khem@gmail.com> wrote:
> On Mon, Mar 20, 2017 at 8:17 AM, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
>> On Mon, 2017-03-20 at 07:49 -0700, Khem Raj wrote:
>>> On Mon, Mar 20, 2017 at 6:47 AM, Kristian Amlie
>>> <kristian.amlie@mender.io> wrote:
>>> >
>>> > --------------------------------------------------
>>> >
>>> > Additionally, in the logs I found these two snippets:
>>> >
>>> > --------------------------------------------------
>>> > Considering setscene task: ['go-native', 'do_populate_sysroot']
>>> > considering dependency: ['go-native', 'do_populate_sysroot']
>>> > considering dependency: ['mender-artifact-native',
>>> > 'do_populate_sysroot']
>>> > Adding dependency on go-native
>>> > ...
>>> > Considering setscene task: ['go-bootstrap-native',
>>> > 'do_populate_sysroot']
>>> > considering dependency: ['go-native', 'do_populate_sysroot']
>>> > Adding dependency on go-bootstrap-native
>>> > --------------------------------------------------
>>> >
>>> > which lead me to believe that all dependencies are being pulled in
>>> > simultaneously by do_rootfs, but go-native and go-bootstrap-native
>>> > are
>>> > in fact mutually exclusive, since they install to the sysroot in
>>> > the
>>> > same location. Note that both compilers build just fine, it's only
>>> > at
>>> > the do_rootfs stage that this shows up.
>>> >
>>> > I think the oe-meta-go layer solved this by having go-bootstrap-
>>> > native
>>> > install in a different location, but I'm unsure what is the best
>>> > approach for OE.
>>> go-bootstrap is only needed for few recipes. I think we should find
>>> out
>>> a way to keep this dep limited to those recipes and not reflect in
>>> final
>>> image rootfs creation. That seems to be not useful.
>>
>> There is code in sstate.bbclass in setscene_depvalid:
>>
>> # Consider sysroot depending on sysroot tasks
>> if taskdependees[task][1] == 'do_populate_sysroot' and taskdependees[dep][1] == 'do_populate_sysroot':
>> [...]
>> # Nothing need depend on libc-initial/gcc-cross-initial
>> if "-initial" in taskdependees[task][0]:
>> continue
>>
>> so if go-bootstrap-native were renamed go-native-initial, things might
>> happen to work better...
>
> ah thats right, forgot about that, I think we should rename the recipe
> to go-native-initial
>
>>
Can you try
http://lists.openembedded.org/pipermail/openembedded-core/2017-March/134372.html
and see if this works out for you ?
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: go-bootstrap / go-native conflict during do_rootfs
2017-03-20 16:50 ` Khem Raj
@ 2017-03-21 6:13 ` Kristian Amlie
0 siblings, 0 replies; 6+ messages in thread
From: Kristian Amlie @ 2017-03-21 6:13 UTC (permalink / raw)
To: Khem Raj, Richard Purdie; +Cc: OE-core
On 20/03/17 17:50, Khem Raj wrote:
> On Mon, Mar 20, 2017 at 8:29 AM, Khem Raj <raj.khem@gmail.com> wrote:
>> On Mon, Mar 20, 2017 at 8:17 AM, Richard Purdie
>> <richard.purdie@linuxfoundation.org> wrote:
>>> On Mon, 2017-03-20 at 07:49 -0700, Khem Raj wrote:
>>>> On Mon, Mar 20, 2017 at 6:47 AM, Kristian Amlie
>>>> <kristian.amlie@mender.io> wrote:
>>>>>
>>>>> --------------------------------------------------
>>>>>
>>>>> Additionally, in the logs I found these two snippets:
>>>>>
>>>>> --------------------------------------------------
>>>>> Considering setscene task: ['go-native', 'do_populate_sysroot']
>>>>> considering dependency: ['go-native', 'do_populate_sysroot']
>>>>> considering dependency: ['mender-artifact-native',
>>>>> 'do_populate_sysroot']
>>>>> Adding dependency on go-native
>>>>> ...
>>>>> Considering setscene task: ['go-bootstrap-native',
>>>>> 'do_populate_sysroot']
>>>>> considering dependency: ['go-native', 'do_populate_sysroot']
>>>>> Adding dependency on go-bootstrap-native
>>>>> --------------------------------------------------
>>>>>
>>>>> which lead me to believe that all dependencies are being pulled in
>>>>> simultaneously by do_rootfs, but go-native and go-bootstrap-native
>>>>> are
>>>>> in fact mutually exclusive, since they install to the sysroot in
>>>>> the
>>>>> same location. Note that both compilers build just fine, it's only
>>>>> at
>>>>> the do_rootfs stage that this shows up.
>>>>>
>>>>> I think the oe-meta-go layer solved this by having go-bootstrap-
>>>>> native
>>>>> install in a different location, but I'm unsure what is the best
>>>>> approach for OE.
>>>> go-bootstrap is only needed for few recipes. I think we should find
>>>> out
>>>> a way to keep this dep limited to those recipes and not reflect in
>>>> final
>>>> image rootfs creation. That seems to be not useful.
>>>
>>> There is code in sstate.bbclass in setscene_depvalid:
>>>
>>> # Consider sysroot depending on sysroot tasks
>>> if taskdependees[task][1] == 'do_populate_sysroot' and taskdependees[dep][1] == 'do_populate_sysroot':
>>> [...]
>>> # Nothing need depend on libc-initial/gcc-cross-initial
>>> if "-initial" in taskdependees[task][0]:
>>> continue
>>>
>>> so if go-bootstrap-native were renamed go-native-initial, things might
>>> happen to work better...
>>
>> ah thats right, forgot about that, I think we should rename the recipe
>> to go-native-initial
>>
>>>
>
> Can you try
>
> http://lists.openembedded.org/pipermail/openembedded-core/2017-March/134372.html
>
> and see if this works out for you ?
That worked, thanks!
--
Kristian
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2017-03-21 6:13 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-20 13:47 go-bootstrap / go-native conflict during do_rootfs Kristian Amlie
2017-03-20 14:49 ` Khem Raj
2017-03-20 15:17 ` Richard Purdie
2017-03-20 15:29 ` Khem Raj
2017-03-20 16:50 ` Khem Raj
2017-03-21 6:13 ` Kristian Amlie
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox