]> code.ossystems Code Review - openembedded-core.git/commitdiff
cross: export CC family from BUILD_* for cross compilers
authorJérémy Rosen <jeremy.rosen@smile.fr>
Wed, 7 Sep 2016 09:08:42 +0000 (11:08 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 13 Sep 2016 14:17:34 +0000 (15:17 +0100)
cross-compilers are native recipes that need to be compiled by the host's
compiler. However they do not use native.bbclass

As a consequence, the various CC, CXX etc environment variables are not
correctly set and they will not honor the host compiler name provided
by the BUILD_* variables.

Signed-off-by: Jérémy Rosen <jeremy.rosen@smile.fr>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/classes/cross.bbclass

index 81d1c9d85555e016171060f5b7b2e5689a2c4fe2..8d1e7795aa82a92a406dd54b20868c8ebe8ed4ff 100644 (file)
@@ -68,4 +68,16 @@ do_install () {
 
 USE_NLS = "no"
 
+export CC = "${BUILD_CC}"
+export CXX = "${BUILD_CXX}"
+export FC = "${BUILD_FC}"
+export CPP = "${BUILD_CPP}"
+export LD = "${BUILD_LD}"
+export CCLD = "${BUILD_CCLD}"
+export AR = "${BUILD_AR}"
+export AS = "${BUILD_AS}"
+export RANLIB = "${BUILD_RANLIB}"
+export STRIP = "${BUILD_STRIP}"
+export NM = "${BUILD_NM}"
+
 inherit nopackages