[yocto] examples / docs on utilizing an external toolchain

Richard Purdie richard.purdie at linuxfoundation.org
Fri Aug 5 01:25:01 PDT 2011


On Thu, 2011-08-04 at 19:05 -0500, Kumar Gala wrote:
> >>>>>> http://bugzilla.pokylinux.org/show_bug.cgi?id=1323
> >>>>>> 
> >>>>>> My question still stands even w/o it being in formal docs.
> >>>>> 
> >>>>> FWIW, POKYMODE was replaced by TCMODE as part of the OE-Core changes.
> >>>>> I'd be interested to know where we've missed the references to it and
> >>>>> get to get those references fixed.
> >>>> 
> >>>> Ok, but how does one use TCMODE?  :)
> >>>> 
> >>>> is there an example around anywhere?
> >>> 
> >>> I'll explain on the condition that someone actually documents this ;-).
> >>> 
> >>> TCMODE determines which of the files in
> >>> meta/conf/distro/include/tcmode-* is used. It defaults to "default" and
> >>> our default toolchain definition is in tcmode-default.inc.
> >>> 
> >>> There is another example there which is "external-csl2008q3". As you can
> >>> see from the tcmode-external-csl2008q3 file, it sets up the system to
> >>> use an external toolchain instead.
> >>> 
> >>> So you can define one of these files in your layer and then the system
> >>> can select alternative toolchain configurations.
> >>> 
> >>> Does that help? :)
> >>> 
> >>> There is a similar TCLIBC variable which controls which libc is used
> >>> (eglibc or uclibc).
> >> 
> >> Yes that helps.  So it looks as if today there is not a means to point
> >> to SDK prebuilt toolchain via this means.
> > 
> > We have supported this in the past but it got messy and I'd really
> > prefer people to use sstate for this.
> > 
> > You obviously can use the SDK toolchain as a prebuilt external toolchain
> > though since its no different from any other external toolchain.
> 
> 
> What got mess about it?  Seems like a poky built sdk toolchain should work as an external toolchain w/o too much issue.

When you have an external toolchain you have to consider things like
packaging up the libc locales and generating the pkgdata information
about shared libraries amongst other things. We therefore went down the
route of shipping that information with the toolchain rather than
generating it each time along with the package files (ipk/rpm/deb). It
turns out to get quite ugly trying to track all the pieces bitbake
generates and deal with all the corner cases (like it packaged with ipk
but you want rpm).

sstate is designed to be able to handle all those pieces.

If you have an external toolchain and don't mind regenerating all that
stuff, its fine.

Cheers,

Richard




More information about the yocto mailing list