summaryrefslogtreecommitdiff
path: root/meta/conf/distro/include
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2016-11-22 17:41:43 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-11-28 14:49:35 +0000
commit60c912ae9306532bdd4c5e09a65863ee77c12f43 (patch)
tree26386ddbced3be4814ce9f46a400b407190b6fcd /meta/conf/distro/include
parent9f1fe76727e98e58fc9e46ea2b49cf5c0cb48e6c (diff)
downloadopenembedded-core-60c912ae9306532bdd4c5e09a65863ee77c12f43.tar.gz
openembedded-core-60c912ae9306532bdd4c5e09a65863ee77c12f43.tar.bz2
openembedded-core-60c912ae9306532bdd4c5e09a65863ee77c12f43.zip
conf: add C++ flags for uninative interoperatility
Create a common include file for compiler flags which allow native binaries to be interoperable on a wide range of hosts. In particular the C++ ABI is problematic so choose the CXX11 version to allow interoperation between gcc4 and gcc5 based hosts. Moving this to a common include instead of uninative.bbclass allows uninative to be configured later and used in the eSDK (where its mandatory) even if the base configuration doesn't enable uninative by default (e.g. nodistro in OE-Core). [ YOCTO #10645 ] Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/conf/distro/include')
-rw-r--r--meta/conf/distro/include/uninative-flags.inc9
1 files changed, 9 insertions, 0 deletions
diff --git a/meta/conf/distro/include/uninative-flags.inc b/meta/conf/distro/include/uninative-flags.inc
new file mode 100644
index 0000000000..e9f82c39ea
--- /dev/null
+++ b/meta/conf/distro/include/uninative-flags.inc
@@ -0,0 +1,9 @@
+# https://wiki.debian.org/GCC5
+# We may see binaries built with gcc5 run or linked into gcc4 environment
+# so use the older libstdc++ standard for now until we don't support gcc4
+# on the host system.
+BUILD_CXXFLAGS_append = " -D_GLIBCXX_USE_CXX11_ABI=0"
+
+# icu configure defaults to CXX11 if no -std= option is passed in CXXFLAGS
+# therefore pass one
+BUILD_CXXFLAGS_append_pn-icu-native = " -std=c++98"