[ELDK] compiling u-boot/tools/env

Marek Vasut marex at denx.de
Wed May 27 20:03:37 CEST 2015


On Friday, May 22, 2015 at 06:35:25 AM, K Richard Pixley wrote:

Hi!

> Short summary:
> 
> As shipped and as directed, (meaning, sourcing the env file), the
> eldk-5.6 toolchain for powerpc-e500v2 can't build u-boot.  Or at least,
> it can't build the u-boot/tools/env portion of u-boot.  This can serve
> as a regression test for this bug.  (I'm surprised this wasn't done
> already).
> 
> This can be traced to a bad directory reference in the env file,
> "--with-sysroot=/opt/eldk-5.6/powerpc-e500v2/sysroots/ppce500v2-linux"
> which doesn't exist.  It's not clear whether this directory is missing,
> (and should have been included which seems most likely), or whether this
> value should have pointed to a directory which /was/ shipped, (perhaps
> ppce500v2-linux-gnuspe).
> 
> I haven't been into the source, but I'd start with how the env file is
> configured and/or produced.  That should likely expose whether the
> directory is missing or badly pointed.

I spoke to the Yocto guys. They gave me this hint and it seems to work
with ELDK 5.8:

$ . /opt/eldk-5.8/powerpc-e500v2/environment-setup-ppce500v2-linux
$ make "CC=${CC}" EP2020XS_config
$ make "CC=${CC}" env

ELDK 5.8's gcc is compiled with sysroot pointing to /not/exist even, so you
need to explicitly specify --sysroot argument to the compiler to point it to
the correct place. Adding this "CC=${CC}" overrides the internal CC setting
in U-Boot's Makefile (which is set to ${CROSS_COMPILE}-gcc) and thus passes
the entire content of $CC into the build as it was set by Yocto including the
correct --sysroot settings.

Can you please give this a spin?

I _think_ some further discussion about this on U-Boot ML would have to take
place, since this problem starts to grow rather big with newer Yoctos.

btw. why is "HOSTCC  scripts/basic/fixdep" wrong (you mentioned this in an
     email from May 17th) ?

Best regards,
Marek Vasut


More information about the eldk mailing list