Minimum host gcc version? (was: [PATCH] qemu-native: set ld.bfd, fix cflags, and set some environment vars)
Quoted 41 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Stephen Arnold
Sent: den 19 juni 2016 21:40
To: [email protected]
Cc: Stephen Arnold; Stephen Arnold
Subject: [OE-core] [PATCH] qemu-native: set ld.bfd, fix cflags, and set some environment varsThe main thing is build failures with gold linker, but qemu is also a little too aggressive at finding random tools on the build host, so we also set the build env for qemu-native and make sure it doesn't reset its own (hard-coded) cflags when we don't want it to.
Signed-off-by Stephen Arnold <[email protected]>The cflags patch was imported from Gentoo Portage and has been manitained over several versions; this version was rebased against upstream qemu git.
Upstream-Status: Inappropriate
- Patch addresses distribution maintenance and build environment sanity.Signed-off-by Stephen Arnold <[email protected]>--- meta/recipes-devtools/qemu/qemu.inc | 13 +++++++-- .../qemu/qemu/qemu-2.6.0-cflags.patch | 31 ++++++++++++++++++++++ meta/recipes-devtools/qemu/qemu_2.6.0.bb | 1 + 3 files changed, 43 insertions(+), 2 deletions(-) create mode 100644 meta/recipes-devtools/qemu/qemu/qemu-2.6.0-cflags.patch
meta/recipes- renamed from meta/recipes-devtools/qemu/qemu.inc +0
-0devtools/qemu/qemu.inc
index bf689bb..d5925fd 100644
meta/recipes-devtools/qemu/qemu.inc SRC_URI_append_class-native = "\ · line 37
Quoted 10 lines
meta/recipes-devtools/qemu/qemu.inc +5
-2@@ -30,8 +30,12 @@ SRC_URI_append_class-native = "\ EXTRA_OECONF += "--target-list=${@get_qemu_target_list(d)} --disable-werror --disable-bluez --disable-libiscsi --with-system-pixman --extra-cflags='${CFLAGS}'" -EXTRA_OECONF_class-nativesdk = "--target-list=${@get_qemu_target_list(d)} --disable-werror \ - " +EXTRA_OECONF_class-nativesdk = "--target-list=${@get_qemu_target_list(d)} --disable-werror" + +EXTRA_OEMAKE_append_class-native = " LD='${LD}' AR='${AR}' OBJCOPY='${OBJCOPY}' LDFLAGS='${LDFLAGS}'" + +LDFLAGS_append_class-native = " -fuse-ld=bfd"
The use of -fuse-ld=bfd causes a build a failure with gcc 4.7.2 that I still use as host compiler. Was it intentional to increase the minimum required host compiler version? If not, can this option be made conditional for compilers that do not support it?
//Peter