[yocto] ADT development with makefiles

Katu Txakur katutxakurra at gmail.com
Tue Apr 23 06:49:12 PDT 2013


Hi,

new to Yocto, I want to develop a software that runs when you start an
overo gusmtix. I read the documentation but I still have many questions. If
you can answer any of them you will be helping me a lot.

I've built the gumstix-console-image<https://github.com/gumstix/Gumstix-YoctoProject-Repo>,
extracted the sysroot (gumstix-sysroot) and I have adt-installer for arm
(arm-sysroot) at /opt/poky/1.3
(environment-setup-armv5te-poky-linux-gnueabi) and also using bitbake and
the build directory (environment-setup-armv7a-vfp-neon-poky-linux-gnueabi).
I've done a hello world example and cross debugged it with Eclipse and ADT
plugin and qemu.
for ADT-plugin, I'm using:
Built system derived toolchain > opt/poky/1.3/
sysroot Location > ~/test-yocto/arm-sysroot
QEMU > ~/adt-installer/downloaded-images/zImage-qemuarm.bin

and it works, but my code uses libraries like net-snmp and others not
included in the arm-sysroot. Shoul I..

a) Leave the same Eclipse ADT options and manually add the libraries that I
use like suggested here <https://wiki.yoctoproject.org/wiki/Training>. Then
build the software and install it manually to the gumstix-console-image.

b) Include the libraries and their -dev packages, build the gumstix image
again, extract sysroot, change Eclipse ADT options to be
Built system derived toolchain > ~/yocto/build/
sysroot Location > ~/yocto/qemu-extracted-sysroot-from-built-image
Can I use the same QEMU kernel in b? I don't think so. I tried to build the
image for qemuarm machine but it failed.


c) forget about Eclipse and manually source the toolchain and "make". I
added to the Makefile
     CC=arm-poky-linux-gnueabi-gcc
     LD=arm-poky-linux-gnueabi-ld
     CFLAGS=”${CFLAGS} --sysroot=<sysroot-dir>”
     CXXFLAGS=”${CXXFLAGS} --sysroot=<sysroot-dir>”
with sysroot-dir to the gumstix-sysroot. This gave me "Recursive variable
`CFLAGS' references itself (eventually). Stop." and using += didn't work
either. Any tutorial (other than the gnu
make<http://www.gnu.org/software/make/manual/make.html>)
of how to create Makefiles for this situation? Should I change to autotools?

d) A better way to do this?

Thanks a lot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20130423/27d3abdf/attachment.html>


More information about the yocto mailing list