From patchwork Thu Jan 17 07:49:12 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [2/2] qemu-native:fix do_compile failed with gcc 4.3.4 on x86 host Date: Thu, 17 Jan 2013 07:49:12 -0000 From: Hongxu Jia X-Patchwork-Id: 42775 Message-Id: <7608c2fd4983ae627fa882baee6faf8546c22719.1358408649.git.hongxu.jia@windriver.com> To: Add an option `-march' to BUILD_CFLAGS, GCC 4.3.4 on x86 host needs this option to let the atomic operations ("lock free") be available while it is used to compile qemu-native. [YOCTO #3563] Signed-off-by: Hongxu Jia --- meta/recipes-devtools/qemu/qemu.inc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index ca411a6..467035c 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -38,6 +38,11 @@ EXTRA_OECONF_class-nativesdk = "--target-list=${@get_qemu_target_list(d)} --disa --disable-curl \ " +# Add an option `-march' to BUILD_CFLAGS, GCC 4.3.4 on x86 host needs this +# option to let the atomic operations ("lock free") be available while it +# is used to compile qemu-native +BUILD_CFLAGS += "-march=${@'${BUILD_ARCH}'.replace('_','-')}" + do_configure_prepend_class-native() { # Undo the -lX11 added by linker-flags.patch, don't assume that host has libX11 installed sed -i 's/-lX11//g' Makefile.target