Skip to contentSkip to conversation

Building sysroot for SDK

DISCUSSION Patrick 3 participants 5 messages Feb 14, 2012 – Feb 16, 2012

lore
Share & tools
lore

Patrick

author
#0 lore raw

Dear list,

I use poky 6.0 to build a complete rootfs for my own target, it's working nicely !Now I would like to build a small application SDK for my system.

I have red carefully the ADT manual and decided to build a toolchain with meta-toolchain. The toolchain generated works properly but some libraries and headers are missing. For example my target use SQLite built in the rootfs. The sqlite library and the headers files are missing in the toolchain.

I would like to know how to build the sysroot to add those files in the toolchain or how to add it directly to the toolchain.

Thanks in advance for any help

Patrick

#1 lore raw

Patrick wrote on 2012-02-14:

Quoted 6 lines

Dear list,

I use poky 6.0 to build a complete rootfs for my own target, it's working nicely !Now I would like to build a small application SDK for my system.

Quoted 6 lines

I have red carefully the ADT manual and decided to build a toolchain with meta-toolchain. The toolchain generated works properly but some libraries and headers are missing.
For example my target use SQLite built in the rootfs. The sqlite library and the headers files are missing in the toolchain.

I would like to know how to build the sysroot to add those files in the toolchain or how to add it directly to the toolchain.

Hi Patrick,

If you want to add more packages into the sysroot built by meta-toolchain, you may add your extra packages(i.e. libsqlite3-dev) into the variable "TOOLCHAIN_TARGET_TASK". Meta/recipes-core/meta/meta-toolchain-gmae.bb might be an example of how to add more packages into the target sysroot.

Best Regards,
Lianhao

author
#2 lore raw
Quoted 11 lines

Patrick wrote on 2012-02-14:

Quoted 7 lines

Dear list,

I use poky 6.0 to build a complete rootfs for my own target, it's working nicely !Now I would like to build a small application SDK for my system.

I have red carefully the ADT manual and decided to build a toolchain
with meta-toolchain. The toolchain generated works properly but some

Quoted 2 lines
Quoted 2 lines

libraries and headers are missing.

For example my target use SQLite built in the rootfs. The sqlite
library and the headers files are missing in the toolchain.

Quoted 2 lines
Quoted 2 lines

I would like to know how to build the sysroot to add those files in the toolchain or how to add it directly to the toolchain.

Quoted 4 lines
Quoted 1 line

Hi Patrick,

If

you want to add more packages into the sysroot built by meta-toolchain, you may add your extra packages(i.e. libsqlite3-dev) into the variable
"TOOLCHAIN_TARGET_TASK".

Quoted 1 line

Meta/recipes-core/meta/meta-toolchain-gmae.bb might be an example of

how to add more packages into the target sysroot.

Quoted 4 lines

Best Regards,
Lianhao

Hi Lianhao,

Thanks for your help ! I have created my own meta-toolchain based on meta-toolchain-gmae.bb and it's work nicely. However, there remains a small problem. My own meta-toolchain-perso.bb file is stored in my own layer meta-perso. To include the meta-toolchain.bb with require I need to use the full
path to the meta layer: require
../../../meta/recipes-core/meta/meta-toolchain.bb
This is not really clean, do you know how to point the meta-toolchain.bb file without using the full path ?

Thanks again for your help

Patrick

author
#3 lore raw
Quoted 14 lines
Quoted 11 lines

Hi Patrick,

If you want to add more packages into the sysroot built by meta-toolchain, you may add your extra packages(i.e. libsqlite3-dev) into the variable "TOOLCHAIN_TARGET_TASK". Meta/recipes-core/meta/meta-toolchain-gmae.bb might be an example of how to add more packages into the target sysroot.

Best Regards,
Lianhao

Hi Lianhao,

Quoted 8 lines

Thanks for your help ! I have created my own meta-toolchain based on meta-toolchain-gmae.bb and it's work nicely.
However, there remains a small problem. My own meta-toolchain-perso.bb file is stored in my own layer meta-perso.
To include the meta-toolchain.bb with require I need to use the full path to the meta layer: require ../../../meta/recipes-core/meta/meta-toolchain.bb This is not really clean, do you know how to point the meta-toolchain.bb file without using the full path ?

Thanks again for your help

Patrick

I answer myself to my question:
I used a meta-toolchain.bbappend file placed in my own layer. This file append the libqlite3-dev package to the TOOLCHAIN_TARGET_TASK. This works fine !

Patrick

#4 lore raw
Quoted 22 lines · Patrick
Quoted 10 lines
Quoted 8 lines

Hi Patrick,

If you want to add more packages into the sysroot built by meta-toolchain, you may add your extra packages(i.e. libsqlite3-dev) into the variable "TOOLCHAIN_TARGET_TASK". Meta/recipes-core/meta/meta-toolchain-gmae.bb might be an example of how to add more packages into the target sysroot.

Best Regards,
Lianhao

Hi Lianhao,

Quoted 8 lines

Thanks for your help ! I have created my own meta-toolchain based on meta-toolchain-gmae.bb and it's work nicely.
However, there remains a small problem. My own meta-toolchain-perso.bb file is stored in my own layer meta-perso.
To include the meta-toolchain.bb with require I need to use the full path to the meta layer: require ../../../meta/recipes-core/meta/meta-toolchain.bb This is not really clean, do you know how to point the meta-toolchain.bb file without using the full path ?

Thanks again for your help

Patrick

I answer myself to my question:
I used a meta-toolchain.bbappend file placed in my own layer. This file append the libqlite3-dev package to the TOOLCHAIN_TARGET_TASK. This works fine !

Quoted 6 lines

Patrick

_______________________________________________
poky mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/poky

Hi,

Should you not also be able to use your favourite package manager included in the toolchain tarball for this ?
opkg-cl -f /opt/poky/1.1/sysroots/ppce500mc-enea-linux/etc/opkg.conf --offline-root /opt/poky/1.1/sysroots/ppce500mc-enea-linux/ update opkg-cl -f /opt/poky/1.1/sysroots/ppce500mc-enea-linux/etc/opkg.conf --offline-root /opt/poky/1.1/sysroots/ppce500mc-enea-linux/ install libsqlite3-dev