All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: how does one use a prebuilt toolchain from the toolchain/ directory?
@ 2012-10-10 15:22 Patrick Turley
  0 siblings, 0 replies; 8+ messages in thread
From: Patrick Turley @ 2012-10-10 15:22 UTC (permalink / raw)
  To: yocto

I just read your posting of 26 June on the Yocto mailing list:


https://lists.yoctoproject.org/pipermail/yocto/2012-June/009714.html


I didn't see any responses. Did you get any help with this issue?



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: how does one use a prebuilt toolchain from the toolchain/ directory?
  2012-07-03 10:08       ` Gary Thomas
  2012-07-03 10:20         ` Robert P. J. Day
@ 2012-07-03 10:23         ` Robert P. J. Day
  1 sibling, 0 replies; 8+ messages in thread
From: Robert P. J. Day @ 2012-07-03 10:23 UTC (permalink / raw)
  To: Gary Thomas; +Cc: yocto

On Tue, 3 Jul 2012, Gary Thomas wrote:

> Use SSTATE_MIRRORS to point at the sstate-cache of the first build.
> This will let bitbake reuse as much as possible, including the toolchain.
>
> I do exactly as you are proposing above and my builds for the "secondary"
> targets can be as little as a couple of minutes (from scratch).

  what's strange is that there's a whole yocto wiki page devoted to
build performance issues:

https://wiki.yoctoproject.org/wiki/Build_Performance

which says nothing about this.

rday

-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: how does one use a prebuilt toolchain from the toolchain/ directory?
  2012-07-03 10:08       ` Gary Thomas
@ 2012-07-03 10:20         ` Robert P. J. Day
  2012-07-03 10:23         ` Robert P. J. Day
  1 sibling, 0 replies; 8+ messages in thread
From: Robert P. J. Day @ 2012-07-03 10:20 UTC (permalink / raw)
  To: Gary Thomas; +Cc: yocto

On Tue, 3 Jul 2012, Gary Thomas wrote:

> Use SSTATE_MIRRORS to point at the sstate-cache of the first build.
> This will let bitbake reuse as much as possible, including the toolchain.
>
> I do exactly as you are proposing above and my builds for the "secondary"
> targets can be as little as a couple of minutes (from scratch).

  ah, and once i knew what to look for, a quick google brought me
here:

https://wiki.yoctoproject.org/wiki/Enable_sstate_cache

but that page is not linked to either from the main wiki page or the
FAQ page, which makes it a bit hard to find.

rday

-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: how does one use a prebuilt toolchain from the toolchain/ directory?
  2012-07-03  9:51     ` Robert P. J. Day
@ 2012-07-03 10:08       ` Gary Thomas
  2012-07-03 10:20         ` Robert P. J. Day
  2012-07-03 10:23         ` Robert P. J. Day
  0 siblings, 2 replies; 8+ messages in thread
From: Gary Thomas @ 2012-07-03 10:08 UTC (permalink / raw)
  To: yocto

On 2012-07-03 03:51, Robert P. J. Day wrote:
> On Mon, 2 Jul 2012, Zhang, Jessica wrote:
>
>> On Tue, Jun 26, 2012 at 4:51 AM, Robert P. J. Day <rpjday@crashcourse.ca> wrote:
>
> ... snip ...
>
>>> 4) once i install a toolchain, how do i use it?  say i install the arm
>>> toolchain, and want to build a beagleboard image.  at what point do i
>>> source the arm toolchain environment setup file?  is that all it
>>> takes?  will the bitbake build process automatically recognize what
>>> i've done and use that toolchain?
>>
>> [JZ] Please note this toolchain is meant to be used by application
>> developers not image builders.  This toolchain is meant for cross
>> development that allows you to develop target application on your
>> host machines.  Once you source the environment-setup script, it'll
>> setup your path correctly that makes it able to find all the cross
>> development tools, e.g.
>> /opt/poky/1.2/sysroots/i686-pokysdk-linux/usr/bin/i586-poky-linux/i586-poky-linux-gcc
>> will be used for compiling your programs.
>
>    ah, i wasn't aware that the prebuilt toolchains were meant primarily
> for *app* development, not *image* development.  i already knew how to
> use them for app development, that's fairly straightforward.
>
>    which brings me back to my original curiosity -- how can i use the
> same toolchain across a number of different *image* builds?  under
> what circumstances does that make sense, and how would i do that?
>
>    say i want to configure and build images for a number of
> beagleboards, and a beaglebone, and a pandaboard, etc., all of which
> require an ARM toolchain.  if these builds can share the same
> toolchain, how can i build it once, then not have to build it over and
> over for the remaining builds?

Use SSTATE_MIRRORS to point at the sstate-cache of the first build.
This will let bitbake reuse as much as possible, including the toolchain.

I do exactly as you are proposing above and my builds for the "secondary"
targets can be as little as a couple of minutes (from scratch).

-- 
------------------------------------------------------------
Gary Thomas                 |  Consulting for the
MLB Associates              |    Embedded world
------------------------------------------------------------




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: how does one use a prebuilt toolchain from the toolchain/ directory?
  2012-07-02 20:18   ` Zhang, Jessica
@ 2012-07-03  9:51     ` Robert P. J. Day
  2012-07-03 10:08       ` Gary Thomas
  0 siblings, 1 reply; 8+ messages in thread
From: Robert P. J. Day @ 2012-07-03  9:51 UTC (permalink / raw)
  To: Zhang, Jessica; +Cc: Yocto discussion list

On Mon, 2 Jul 2012, Zhang, Jessica wrote:

> On Tue, Jun 26, 2012 at 4:51 AM, Robert P. J. Day <rpjday@crashcourse.ca> wrote:

... snip ...

> > 4) once i install a toolchain, how do i use it?  say i install the arm
> > toolchain, and want to build a beagleboard image.  at what point do i
> > source the arm toolchain environment setup file?  is that all it
> > takes?  will the bitbake build process automatically recognize what
> > i've done and use that toolchain?
>
> [JZ] Please note this toolchain is meant to be used by application
> developers not image builders.  This toolchain is meant for cross
> development that allows you to develop target application on your
> host machines.  Once you source the environment-setup script, it'll
> setup your path correctly that makes it able to find all the cross
> development tools, e.g.
> /opt/poky/1.2/sysroots/i686-pokysdk-linux/usr/bin/i586-poky-linux/i586-poky-linux-gcc
> will be used for compiling your programs.

  ah, i wasn't aware that the prebuilt toolchains were meant primarily
for *app* development, not *image* development.  i already knew how to
use them for app development, that's fairly straightforward.

  which brings me back to my original curiosity -- how can i use the
same toolchain across a number of different *image* builds?  under
what circumstances does that make sense, and how would i do that?

  say i want to configure and build images for a number of
beagleboards, and a beaglebone, and a pandaboard, etc., all of which
require an ARM toolchain.  if these builds can share the same
toolchain, how can i build it once, then not have to build it over and
over for the remaining builds?

rday

-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: how does one use a prebuilt toolchain from the toolchain/ directory?
  2012-07-02 20:01 ` Manuel Bessler
@ 2012-07-02 20:18   ` Zhang, Jessica
  2012-07-03  9:51     ` Robert P. J. Day
  0 siblings, 1 reply; 8+ messages in thread
From: Zhang, Jessica @ 2012-07-02 20:18 UTC (permalink / raw)
  To: Manuel Bessler, Yocto discussion list

See my comments below...

-----Original Message-----
From: yocto-bounces@yoctoproject.org [mailto:yocto-bounces@yoctoproject.org] On Behalf Of Manuel Bessler
Sent: Monday, July 02, 2012 1:02 PM
To: Yocto discussion list
Subject: Re: [yocto] how does one use a prebuilt toolchain from the toolchain/ directory?

I'm in a similar situation and have been wondering about the same questions Robert is raising...

I'd love to see others chime in with any insight they might have.

Thanks,
Manuel

On Tue, Jun 26, 2012 at 4:51 AM, Robert P. J. Day <rpjday@crashcourse.ca> wrote:
>
>   it sounds like a trivial question whose answer should be easy to
> find, but surprisingly, it isn't.  if a user wants to save all that
> toolchain-building time and take advantage of an existing toolchain,
> what to do?
>
>   the ADT user's guide *sort of* addresses that, but in a somewhat
> confusing way:
>
> http://www.yoctoproject.org/docs/current/adt-manual/adt-manual.html
>
>   first, the ADT guide, in section 2.1.2, talks about how to do this,
> but only after the more complicated and involved recipe for using the
> ADT installer.  this strikes me as backwards -- a set of alternatives
> would make sense going from simplest to most complicated.  using a
> prebuilt toolchain would seem to be the *first* thing that should be
> explained.
>
>   next, that section 2.1.2 in the ADT guide opens reasonably by
> explaining how to find and download the appropriate toolchain and
> then, for no apparent reason, takes this massive sidestep in a "Note"
> to ask the reader to consider using bitbake to build it instead.  um
> ... no.  in the midst of explaining something really simple, it's
> totally counter-productive to suddenly ask the reader to consider
> something noticeably more complex and unnecessary in the context of
> the current explanation.
>
>   finally, after the Note is over, the instructions return to point
> 3., correctly telling the reader to unload the tarball at the root
> directory, then vaguely referring to some "environment setup files"
> without explaining what to do with them or when to run them or what
> effect they'll have on the build process from then on. should one run
> the appropriate env setup file *before* invoking oe-init-build-env?
> after?  does it matter?
>
>   so to clarify this issue, here's a set of questions to which i know
> *some* of the answers and would like to know the rest.
>
> 1) i want to save buckets of time in my builds by using a pre-built
> toolchain appropriate for my architecture.  can i always use one of
> the toolchains at
> http://downloads.yoctoproject.org/releases/yocto/yocto-1.2/toolchain/?
> is there any downside to doing that?  if so, what?
>

[JZ] you can always use the pre-built toolchain from there.

> 2) do those pre-built toolchains always need to be installed under
> /opt/poky?  it seems pretty obvious that they do, given that the
> environment setup scripts hardcode references to /opt/poky.
>

[JZ] As you've found, yes, currently all the toolchains, either extracted from pre-built tar ball or through adt-installer will always go under /opt/poky.  For 1.3, there's a feature request to make toolchain reloadable.

> 3) can i install multiple toolchains at the same time?  it seems so --
> the common native content in the toolchains seems identical so i don't
> see any issue with having two or more toolchains installed at the same
> time.

[JZ] yes you can, actually the directory structure is designed that way.

>
> 4) once i install a toolchain, how do i use it?  say i install the arm
> toolchain, and want to build a beagleboard image.  at what point do i
> source the arm toolchain environment setup file?  is that all it
> takes?  will the bitbake build process automatically recognize what
> i've done and use that toolchain?

[JZ] Please note this toolchain is meant to be used by application developers not image builders.  This toolchain is meant for cross development that allows you to develop target application on your host machines.  Once you source the environment-setup script, it'll setup your path correctly that makes it able to find all the cross development tools, e.g. /opt/poky/1.2/sysroots/i686-pokysdk-linux/usr/bin/i586-poky-linux/i586-poky-linux-gcc will be used for compiling your programs.
>
>   and so on, and so on.  thoughts?
>
> rday
>
> --
>
> ======================================================================
> == Robert P. J. Day                                 Ottawa, Ontario,
> CANADA
>                         http://crashcourse.ca
>
> Twitter:
> http://twitter.com/rpjday
> LinkedIn:
> http://ca.linkedin.com/in/rpjday
> ======================================================================
> == _______________________________________________
> yocto mailing list
> yocto@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto
_______________________________________________
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: how does one use a prebuilt toolchain from the toolchain/ directory?
  2012-06-26  8:51 Robert P. J. Day
@ 2012-07-02 20:01 ` Manuel Bessler
  2012-07-02 20:18   ` Zhang, Jessica
  0 siblings, 1 reply; 8+ messages in thread
From: Manuel Bessler @ 2012-07-02 20:01 UTC (permalink / raw)
  To: Yocto discussion list

I'm in a similar situation and have been wondering about the same
questions Robert is raising...

I'd love to see others chime in with any insight they might have.

Thanks,
Manuel

On Tue, Jun 26, 2012 at 4:51 AM, Robert P. J. Day <rpjday@crashcourse.ca> wrote:
>
>   it sounds like a trivial question whose answer should be easy to
> find, but surprisingly, it isn't.  if a user wants to save all that
> toolchain-building time and take advantage of an existing toolchain,
> what to do?
>
>   the ADT user's guide *sort of* addresses that, but in a somewhat
> confusing way:
>
> http://www.yoctoproject.org/docs/current/adt-manual/adt-manual.html
>
>   first, the ADT guide, in section 2.1.2, talks about how to do this,
> but only after the more complicated and involved recipe for using the
> ADT installer.  this strikes me as backwards -- a set of alternatives
> would make sense going from simplest to most complicated.  using a
> prebuilt toolchain would seem to be the *first* thing that should be
> explained.
>
>   next, that section 2.1.2 in the ADT guide opens reasonably by
> explaining how to find and download the appropriate toolchain and
> then, for no apparent reason, takes this massive sidestep in a "Note"
> to ask the reader to consider using bitbake to build it instead.  um
> ... no.  in the midst of explaining something really simple, it's
> totally counter-productive to suddenly ask the reader to consider
> something noticeably more complex and unnecessary in the context of
> the current explanation.
>
>   finally, after the Note is over, the instructions return to point
> 3., correctly telling the reader to unload the tarball at the root
> directory, then vaguely referring to some "environment setup files"
> without explaining what to do with them or when to run them or what
> effect they'll have on the build process from then on. should one run
> the appropriate env setup file *before* invoking oe-init-build-env?
> after?  does it matter?
>
>   so to clarify this issue, here's a set of questions to which i know
> *some* of the answers and would like to know the rest.
>
> 1) i want to save buckets of time in my builds by using a pre-built
> toolchain appropriate for my architecture.  can i always use one of
> the toolchains at
> http://downloads.yoctoproject.org/releases/yocto/yocto-1.2/toolchain/?
> is there any downside to doing that?  if so, what?
>
> 2) do those pre-built toolchains always need to be installed under
> /opt/poky?  it seems pretty obvious that they do, given that the
> environment setup scripts hardcode references to /opt/poky.
>
> 3) can i install multiple toolchains at the same time?  it seems so --
> the common native content in the toolchains seems identical so i don't
> see any issue with having two or more toolchains installed at the same
> time.
>
> 4) once i install a toolchain, how do i use it?  say i install the arm
> toolchain, and want to build a beagleboard image.  at what point do i
> source the arm toolchain environment setup file?  is that all it
> takes?  will the bitbake build process automatically recognize what
> i've done and use that toolchain?
>
>   and so on, and so on.  thoughts?
>
> rday
>
> --
>
> ========================================================================
> Robert P. J. Day                                 Ottawa, Ontario, CANADA
>                         http://crashcourse.ca
>
> Twitter:                                       http://twitter.com/rpjday
> LinkedIn:                               http://ca.linkedin.com/in/rpjday
> ========================================================================
> _______________________________________________
> yocto mailing list
> yocto@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto


^ permalink raw reply	[flat|nested] 8+ messages in thread

* how does one use a prebuilt toolchain from the toolchain/ directory?
@ 2012-06-26  8:51 Robert P. J. Day
  2012-07-02 20:01 ` Manuel Bessler
  0 siblings, 1 reply; 8+ messages in thread
From: Robert P. J. Day @ 2012-06-26  8:51 UTC (permalink / raw)
  To: Yocto discussion list


  it sounds like a trivial question whose answer should be easy to
find, but surprisingly, it isn't.  if a user wants to save all that
toolchain-building time and take advantage of an existing toolchain,
what to do?

  the ADT user's guide *sort of* addresses that, but in a somewhat
confusing way:

http://www.yoctoproject.org/docs/current/adt-manual/adt-manual.html

  first, the ADT guide, in section 2.1.2, talks about how to do this,
but only after the more complicated and involved recipe for using the
ADT installer.  this strikes me as backwards -- a set of alternatives
would make sense going from simplest to most complicated.  using a
prebuilt toolchain would seem to be the *first* thing that should be
explained.

  next, that section 2.1.2 in the ADT guide opens reasonably by
explaining how to find and download the appropriate toolchain and
then, for no apparent reason, takes this massive sidestep in a "Note"
to ask the reader to consider using bitbake to build it instead.  um
... no.  in the midst of explaining something really simple, it's
totally counter-productive to suddenly ask the reader to consider
something noticeably more complex and unnecessary in the context of
the current explanation.

  finally, after the Note is over, the instructions return to point
3., correctly telling the reader to unload the tarball at the root
directory, then vaguely referring to some "environment setup files"
without explaining what to do with them or when to run them or what
effect they'll have on the build process from then on. should one run
the appropriate env setup file *before* invoking oe-init-build-env?
after?  does it matter?

  so to clarify this issue, here's a set of questions to which i know
*some* of the answers and would like to know the rest.

1) i want to save buckets of time in my builds by using a pre-built
toolchain appropriate for my architecture.  can i always use one of
the toolchains at
http://downloads.yoctoproject.org/releases/yocto/yocto-1.2/toolchain/?
is there any downside to doing that?  if so, what?

2) do those pre-built toolchains always need to be installed under
/opt/poky?  it seems pretty obvious that they do, given that the
environment setup scripts hardcode references to /opt/poky.

3) can i install multiple toolchains at the same time?  it seems so --
the common native content in the toolchains seems identical so i don't
see any issue with having two or more toolchains installed at the same
time.

4) once i install a toolchain, how do i use it?  say i install the arm
toolchain, and want to build a beagleboard image.  at what point do i
source the arm toolchain environment setup file?  is that all it
takes?  will the bitbake build process automatically recognize what
i've done and use that toolchain?

  and so on, and so on.  thoughts?

rday

-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2012-10-10 15:22 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-10 15:22 how does one use a prebuilt toolchain from the toolchain/ directory? Patrick Turley
  -- strict thread matches above, loose matches on Subject: below --
2012-06-26  8:51 Robert P. J. Day
2012-07-02 20:01 ` Manuel Bessler
2012-07-02 20:18   ` Zhang, Jessica
2012-07-03  9:51     ` Robert P. J. Day
2012-07-03 10:08       ` Gary Thomas
2012-07-03 10:20         ` Robert P. J. Day
2012-07-03 10:23         ` Robert P. J. Day

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.