[yocto] The sysroot location in eclipse plugin?

Ni Qingliang niqingliang at insigma.com.cn
Thu Feb 16 23:58:35 PST 2012


thanks! another question:
why I must specify the sysroot location in eclipse plugin? the
environment-setup has it already.

On Fri, 2012-02-17 at 15:49 +0800, Lu, Lianhao wrote:
> Ni Qingliang wrote on 2012-02-17:
> > the environment-setup file in build tree had defined CFLAGS and CXXFLAGS
> > which include the sysroot argument(<build_tree>/tmp/sysroots/<machine>).
> >
> > Do we must specify the sysroot location in the eclipse plugin?
> >
> > after specify it, I found the CFLAGS CXXFLAGS in project property follow
> > it, and dropped the sysroot defined in environment-setup file.
> >
> > and I have another sysroot running on target (qemu) unzipped from the
> > image.
> >
> > If I specify the target sysroot in eclipse-plugin, I can't compile my
> > code, because there is no any header file in /usr/include.
> > If I specify the <build_tree>/tmp/sysroots/<machine>, I can't running
> > the qemu machine in eclipse, because there is no 'init'.
> >
> The eclipse-plugin by default assumes the user using the same target sysroot for both cross compiling and qemu launching. So this requires the target sysroot having the libraries and header files.
> 
> You might have 2 options here:
> 1. build a new image with the "dev-pkgs" image feature(you can set that in conf/local.conf in variable EXTRA_IMAGE_FEATURES) and use that image as target sysroot in eclipse.
> 
> 2. launch the qemu in console terminal, out of eclipse, using a different target sysroot.
> 
> Best Regards,
> Lianhao
> 
> 

-- 
Yi Qingliang
niqingliang at insigma.com.cn
https://niqingliang2003.wordpress.com




More information about the yocto mailing list