[yocto] devshell env in warrior

matthew stanger stangerm2 at gmail.com
Tue Jun 18 10:08:25 PDT 2019


Hey Khem,

Check that Makefiles are not overriding CC/CXX/LD etc. some old crufty
> Makefiles I have seen doing that, you might see something like

In the recipe it's caused by 'inherit module', which is needed because part
of the recipe is building modules. I would understand this would unset
CFLAGS and such but am not sure why the devshell should be different that
the environment at the first line of do_compile?

On Tue, Jun 18, 2019 at 10:08 AM Khem Raj <raj.khem at gmail.com> wrote:

> On Mon, Jun 17, 2019 at 4:55 PM matthew stanger <stangerm2 at gmail.com>
> wrote:
> >
> > I'm trying to figure out why when running devshell in Warrior CC/CFLAGS
> are not the same as do_compile for a recipe. For example.
> > devshell printenv yields:
> > CC=aarch64-poky-linux-gcc   -fuse-ld=bfd
> -fmacro-prefix-map=/home/matt/rdk_warrior/build/tmp/work/7271-poky-linux/brcm/18.3+AUTOINC+0a6fb7430f-0=/usr/src/debug/ursr/18.3+AUTOINC+0a6fb7430f-0
> -fdebug-prefix-map=/home/matt/rdk_warrior/build/tmp/work/7271-poky-linux/brcm/18.3+AUTOINC+0a6fb7430f-0=/usr/src/debug/ursr/18.3+AUTOINC+0a6fb7430f-0
> -fdebug-prefix-map=/home/matt/rdk_warrior/build/tmp/work/7271-poky-linux/brcm/18.3+AUTOINC+0a6fb7430f-0/recipe-sysroot=
> -fdebug-prefix-map=/home/matt/rdk_warrior/build/tmp/work/7271-poky-linux/brcm/18.3+AUTOINC+0a6fb7430f-0/recipe-sysroot-native=
> -fdebug-prefix-map=/home/matt/rdk_warrior/build/tmp/work-shared/tmobile-7271-kaon-mini/kernel-source=/usr/src/kernel
> >
> > do_compile() {
> >     /usr/bin/printenv | sort > debug.log
> > }
> > yields...
> > CC=aarch64-poky-linux-gcc  -mcpu=cortex-a53+crc+crypto
> -fstack-protector-strong  -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security
> -Werror=format-security
> --sysroot=/home/matt/rdk_warrior/build/tmp/work/tmobile_7271_kaon_mini-poky-linux/ursr/18.3+AUTOINC+0a6fb7430f-0/recipe-sysroot
> >
> > This causes some very different behavior out of the makefile. The recipe
> I"m working with has no do_configure, and only calls a makefile through
> do_compile. No appends/prepends or custom functions in the recipe. This
> recipe is for a lovely Broadcom driver/userspace glob and I'm trying to
> troubleshoot it with x64 but not being able to get a correct working env
> makes life hard. Any idea's of where I might be going wrong?
> >
>
> Check that Makefiles are not overriding CC/CXX/LD etc. some old crufty
> Makefiles I have seen doing that, you might see something like
>
> CC = ${CROSS_COMPILE}gcc etc. which you should convert to weak defines
> e.g. CC ?= ....
>
> > Cheers
> > --
> > _______________________________________________
> > yocto mailing list
> > yocto at yoctoproject.org
> > https://lists.yoctoproject.org/listinfo/yocto
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20190618/8888afea/attachment-0001.html>


More information about the yocto mailing list