[OE-core] [PATCH 0/2] Two gcc compatibility/usability fixes

Richard Tollerton rich.tollerton at ni.com
Thu Jul 3 22:00:24 UTC 2014


I have a couple changes that help some sources build under meta-toolchain without
workarounds. These were originally developed on dylan; I just tested them by
building mingw SDKs under daisy with vanilla poky+meta-mingw, then applying the
patches to oe-core.

[01/02]: The build infrastructure for the Linux kernel tools (at least) doesn't
really expect you to supply a --sysroot for cross-compilation; they expect
setting CROSS_COMPILE to be all that you need. You can see the sorts of
contortions this leads to in perf.bb; but I need to build some other kernel
tools, outside of bitbake, so I'm exposed to this.

The root fix is *not* to supply --sysroot to these builds: thanks to some
ungodly-complex path mangling, gcc is actually smart enough to find the target
sysroot on its own. It just needs a little goading to work, which is provided in
this patch.

This might help simplify some recipes, including perf's.

[02/02]: Virtually every g++ configuration installs C++ headers to e.g.
/usr/include/c++/4.8.2 -- with the exception of OE, which doesn't include the
gcc version. This breaks ancient versions of STLport; it also precludes
side-by-side installation of multiple g++ versions. This patch fixes that.

Richard Tollerton (2):
  gcc-cross-canadian: Adjust $prefix to fix sysroot autodetect
  gcc: Ensure c++ includes are in /usr/include/c++/${BINV}

 meta/recipes-devtools/gcc/gcc-4.8.inc            | 2 +-
 meta/recipes-devtools/gcc/gcc-cross-canadian.inc | 5 ++++-
 meta/recipes-devtools/gcc/gcc-cross.inc          | 2 +-
 meta/recipes-devtools/gcc/gcc-runtime.inc        | 2 +-
 meta/recipes-devtools/gcc/gcc-target.inc         | 2 +-
 5 files changed, 8 insertions(+), 5 deletions(-)

-- 
2.0.1



More information about the Openembedded-core mailing list