Re: #yocto do_package error for custom app #yocto


Quentin Schulz
 

Salut Bastien,

On Mon, May 04, 2020 at 06:05:19AM -0700, Bastien0530 wrote:
This file is supposed to be my application.
The `file` command on Linux (could be run on the host and not the
target) will give you important info such as the architecture for which
it was built. In that case, we would have detected that it was built for
your host architecture and guide you to CC=gcc (which is a classic in
many pieces of SW).

I tried to run it on my target cible but doesn't work.
I have just resolved the issue, that was a mistake in my makefile, I fixed CC=GCC instead of CC?=GCC.
Make sure that all variables that could be set from outside are weakly
set as well. (e.g. CFLAGS, LDFLAGS, etc...) otherwise you might
encounter some other issues later (though in some cases, you'll then
need to modify CFLAGS/LDFLAGS from the recipe if the recipe does not
compile with Yocto CFLAGS/LDFLAGS, if it's not fixable in the source
code).

BTW, you most probably don't need your FILEXTRAPATHS_prepend, nor your
do_compile and do_install as what you've in there is their default
"content". (c.f. base.bbclass and cross.bbclass in openembedded-core).

Have fun!
Quentin

Join yocto@lists.yoctoproject.org to automatically receive all group messages.