Skip to contentSkip to conversation

recipes-devtools/gcc accumulated patches

PATCH New Peter A. Bigot 1 participant 10 messages Aug 14, 2014

lore
Share & tools
lore
#0 lore raw

v2 cover recipes-devtools/gcc accumulated patches

The first five patches have the same content as the previous version, but the commit messages have been tweaked.

There's a new cleanup patch to change the name of a function from the name of a gcc configuration option it doesn't affect to the name of the gcc configuration option it does affect.

Khem's patch http://patches.openembedded.org/patch/78131/ is here, rebased on the whitespace cleanup that starts this series.

Then we have the backport of the patch required to fix problems with gcc 4.9 building some Linux kernels. The affected kernels have been patched but may not be in OE yet; the same patch is also relevant to 4.8 and has been added there for completeness.

Finally, the C++11 ABI issue that got me started on this has been fixed, in a slightly different way than previously discussed: this one follows the precedent of mips64 in specifying ABI-related configuration flags in gcc-configure-common.inc, but following Khem's suggestion of adding the necessary --with-arch flags. I've included armv6 for completeness; AFAICT armv7a covers all the other affected ARM platforms.

Feedback welcome; I have no additional gcc patches pending, so if there are no concerns these should be ready for integration testing.

Peter

Khem Raj (1):
gcc: Abstract long double configuration into python function

Peter A. Bigot (8):
gcc: recipe whitespace changes
gcc: remove inappropriate patch
gcc-4.9: Ensure c++ includes are in /usr/include/c++/${BINV}
gcc: remove outdated configuration option
gcc-target: make --enable-clocale consistent with gcc-runtime
sdk: change EXTRA_OECONF_FPU to EXTRA_OECONF_GCC_FLOAT
gcc: backport patch affecting Linux kernel builds
gcc: update compiler architecture to match gcc-runtime (armv6, armv7a)

 meta/classes/crosssdk.bbclass                      |   2 +-
 meta/classes/nativesdk.bbclass                     |   2 +-
 meta/recipes-devtools/gcc/gcc-4.8.inc              | 186 +++++++++++----------
 .../gcc/gcc-4.8/0037-gcc-4.8-PR56797.patch         |  66 --------
 .../gcc-4.8/0052-PR-rtl-optimization-61801.patch   |  36 ++++
 meta/recipes-devtools/gcc/gcc-4.9.inc              | 180 ++++++++++----------
 .../gcc/gcc-4.9/0037-gcc-4.8-PR56797.patch         |  66 --------
 .../gcc-4.9/0055-PR-rtl-optimization-61801.patch   |  36 ++++
 meta/recipes-devtools/gcc/gcc-common.inc           |   9 +-
 meta/recipes-devtools/gcc/gcc-configure-common.inc |  60 ++++---
 meta/recipes-devtools/gcc/gcc-cross-canadian.inc   |  25 +--
 meta/recipes-devtools/gcc/gcc-cross-initial.inc    |  32 ++--
 meta/recipes-devtools/gcc/gcc-cross.inc            |  27 +--
 meta/recipes-devtools/gcc/gcc-runtime.inc          | 154 ++++++++---------
 meta/recipes-devtools/gcc/gcc-target.inc           | 110 ++++++------
 meta/recipes-devtools/gcc/libgcc.inc               |  35 ++--
 meta/recipes-devtools/gcc/libgfortran.inc          |  29 ++--
 17 files changed, 521 insertions(+), 534 deletions(-)
 delete mode 100644 meta/recipes-devtools/gcc/gcc-4.8/0037-gcc-4.8-PR56797.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-4.8/0052-PR-rtl-optimization-61801.patch
 delete mode 100644 meta/recipes-devtools/gcc/gcc-4.9/0037-gcc-4.8-PR56797.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-4.9/0055-PR-rtl-optimization-61801.patch
Signature · 1 line
1.8.5.5
#1 lore raw

PATCH v2 1/9 gcc: recipe whitespace changes

Consistent use of whitespace in multi-line assignment, with special focus on OECONF modifications. Quotes on separate lines, four-space indentation, one value per line.

---
 meta/recipes-devtools/gcc/gcc-4.8.inc              | 186 +++++++++++----------
 meta/recipes-devtools/gcc/gcc-4.9.inc              | 180 ++++++++++----------
 meta/recipes-devtools/gcc/gcc-configure-common.inc |  46 ++---
 meta/recipes-devtools/gcc/gcc-cross-canadian.inc   |  24 +--
 meta/recipes-devtools/gcc/gcc-cross-initial.inc    |  32 ++--
 meta/recipes-devtools/gcc/gcc-cross.inc            |  28 ++--
 meta/recipes-devtools/gcc/gcc-runtime.inc          | 153 ++++++++---------
 meta/recipes-devtools/gcc/gcc-target.inc           | 106 ++++++------
 meta/recipes-devtools/gcc/libgcc.inc               |  35 ++--
 meta/recipes-devtools/gcc/libgfortran.inc          |  29 ++--
 10 files changed, 429 insertions(+), 390 deletions(-)
meta/recipes-devtools/gcc/gcc-4.8.inc +98 -88
index 2816f13..80a3fc4 100644
@@ -15,62 +15,65 @@ NATIVEDEPS = "mpfr-native gmp-native libmpc-native zlib-native"
 
 LICENSE = "GPL-3.0-with-GCC-exception & GPLv3"
 
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
-                   file://COPYING3;md5=d32239bcb673463ab874e80d47fae504 \
-                   file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
-                   file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
-                   file://COPYING.RUNTIME;md5=fe60d87048567d4fe8c8a0ed2448bcc8"
-
-SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
-	   file://0002-uclibc-conf.patch \
-	   file://0003-gcc-uclibc-locale-ctype_touplow_t.patch \
-	   file://0004-uclibc-locale.patch \
-	   file://0005-uclibc-locale-no__x.patch \
-	   file://0006-uclibc-locale-wchar_fix.patch \
-	   file://0007-uclibc-locale-update.patch \
-	   file://0008-missing-execinfo_h.patch \
-	   file://0009-c99-snprintf.patch \
-	   file://0010-c99-complex-ugly-hack.patch \
-	   file://0011-index_macro.patch \
-	   file://0012-libmudflap-susv3-legacy.patch \
-	   file://0013-libstdc-namespace.patch \
-	   file://0014-sh-pr24836.patch \
-	   file://0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch \
-	   file://0016-gcc-poison-system-directories.patch \
-	   file://0017-gcc-poison-dir-extend.patch \
-	   file://0018-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch \
-	   file://0019-64-bit-multilib-hack.patch \
-	   file://0020-optional-libstdc.patch \
-	   file://0021-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch \
-	   file://0022-COLLECT_GCC_OPTIONS.patch \
-	   file://0023-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch \
-	   file://0024-PR-target-32219.patch \
-	   file://0025-fortran-cross-compile-hack.patch \
-	   file://0026-libgcc-sjlj-check.patch \
-	   file://0027-cpp-honor-sysroot.patch \
-	   file://0028-MIPS64-Default-to-N64-ABI.patch \
-	   file://0029-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch \
-	   file://0030-gcc-Fix-argument-list-too-long-error.patch \
-	   file://0031-Disable-sdt.patch \
-	   file://0032-libtool.patch \
-	   file://0033-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch \
-	   file://0034-Use-the-multilib-config-files-from-B-instead-of-usin.patch \
-	   file://0035-wcast-qual-PR-55383.patch \
-	   file://0037-gcc-4.8-PR56797.patch \
-	   file://0038-gcc-4.8-build-args.patch \
-	   file://0039-gcc-4.8-PR57717.patch \
-	   file://0040-fix-g++-sysroot.patch \
-	   file://0041-libtool-avoid-libdir.patch \
-	   file://0042-pr57748.patch \
-	   file://0043-cpp.patch \
-	   file://0044-gengtypes.patch \
-	   file://0045-gcc-4.8-PR57717-PowerPC-E500v2.patch \
-	   file://0046-libatomic-deptracking.patch \
-	   file://0047-repomembug.patch \
-	   file://0048-PR58854_fix_arm_apcs_epilogue.patch \
-	   file://0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch \
-	   file://0050-PR-target-58595.patch \
-	  "
+LIC_FILES_CHKSUM = "\
+    file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
+    file://COPYING3;md5=d32239bcb673463ab874e80d47fae504 \
+    file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
+    file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
+    file://COPYING.RUNTIME;md5=fe60d87048567d4fe8c8a0ed2448bcc8 \
+"
+
+SRC_URI = "\
+    ${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
+    file://0002-uclibc-conf.patch \
+    file://0003-gcc-uclibc-locale-ctype_touplow_t.patch \
+    file://0004-uclibc-locale.patch \
+    file://0005-uclibc-locale-no__x.patch \
+    file://0006-uclibc-locale-wchar_fix.patch \
+    file://0007-uclibc-locale-update.patch \
+    file://0008-missing-execinfo_h.patch \
+    file://0009-c99-snprintf.patch \
+    file://0010-c99-complex-ugly-hack.patch \
+    file://0011-index_macro.patch \
+    file://0012-libmudflap-susv3-legacy.patch \
+    file://0013-libstdc-namespace.patch \
+    file://0014-sh-pr24836.patch \
+    file://0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch \
+    file://0016-gcc-poison-system-directories.patch \
+    file://0017-gcc-poison-dir-extend.patch \
+    file://0018-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch \
+    file://0019-64-bit-multilib-hack.patch \
+    file://0020-optional-libstdc.patch \
+    file://0021-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch \
+    file://0022-COLLECT_GCC_OPTIONS.patch \
+    file://0023-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch \
+    file://0024-PR-target-32219.patch \
+    file://0025-fortran-cross-compile-hack.patch \
+    file://0026-libgcc-sjlj-check.patch \
+    file://0027-cpp-honor-sysroot.patch \
+    file://0028-MIPS64-Default-to-N64-ABI.patch \
+    file://0029-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch \
+    file://0030-gcc-Fix-argument-list-too-long-error.patch \
+    file://0031-Disable-sdt.patch \
+    file://0032-libtool.patch \
+    file://0033-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch \
+    file://0034-Use-the-multilib-config-files-from-B-instead-of-usin.patch \
+    file://0035-wcast-qual-PR-55383.patch \
+    file://0037-gcc-4.8-PR56797.patch \
+    file://0038-gcc-4.8-build-args.patch \
+    file://0039-gcc-4.8-PR57717.patch \
+    file://0040-fix-g++-sysroot.patch \
+    file://0041-libtool-avoid-libdir.patch \
+    file://0042-pr57748.patch \
+    file://0043-cpp.patch \
+    file://0044-gengtypes.patch \
+    file://0045-gcc-4.8-PR57717-PowerPC-E500v2.patch \
+    file://0046-libatomic-deptracking.patch \
+    file://0047-repomembug.patch \
+    file://0048-PR58854_fix_arm_apcs_epilogue.patch \
+    file://0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch \
+    file://0050-PR-target-58595.patch \
+"
 SRC_URI[md5sum] = "a3d7d63b9cb6b6ea049469a0c4a43c9d"
 SRC_URI[sha256sum] = "09dc2276c73424bbbfda1dbddc62bbbf900c9f185acf7f3e1d773ce2d7e3cdc8"
 
@@ -83,40 +86,47 @@ JAVA = ""
 
 LTO = "--enable-lto"
 
-EXTRA_OECONF_BASE = "   ${LTO} \
-			--enable-libssp \
-			--disable-bootstrap \
-			--disable-libmudflap \
-			--with-system-zlib \
-			--with-linker-hash-style=${LINKER_HASH_STYLE} \
-			--enable-linker-build-id \
-			--with-ppl=no \
-			--with-cloog=no \
-			--enable-checking=release \
-			--enable-cheaders=c_global "
-
-EXTRA_OECONF_INITIAL = "--disable-libmudflap \
-			--disable-libgomp \
-			--disable-libssp \
-			--disable-libquadmath \
-			--with-system-zlib \
-			--disable-lto \
-			--disable-plugin \
-			--enable-decimal-float=no"
-
-EXTRA_OECONF_INTERMEDIATE = "--disable-libmudflap \
-				--disable-libgomp \
-				--disable-libquadmath \
-				--with-system-zlib \
-				--disable-lto \
-				--disable-plugin \
-				--disable-libssp"
+EXTRA_OECONF_BASE = "\
+    ${LTO} \
+    --enable-libssp \
+    --disable-bootstrap \
+    --disable-libmudflap \
+    --with-system-zlib \
+    --with-linker-hash-style=${LINKER_HASH_STYLE} \
+    --enable-linker-build-id \
+    --with-ppl=no \
+    --with-cloog=no \
+    --enable-checking=release \
+    --enable-cheaders=c_global \
+"
+
+EXTRA_OECONF_INITIAL = "\
+    --disable-libmudflap \
+    --disable-libgomp \
+    --disable-libssp \
+    --disable-libquadmath \
+    --with-system-zlib \
+    --disable-lto \
+    --disable-plugin \
+    --enable-decimal-float=no \
+"
+
+EXTRA_OECONF_INTERMEDIATE = "\
+    --disable-libmudflap \
+    --disable-libgomp \
+    --disable-libquadmath \
+    --with-system-zlib \
+    --disable-lto \
+    --disable-plugin \
+    --disable-libssp \
+"
 
 EXTRA_OECONF_append_libc-uclibc = " --disable-decimal-float "
 
-EXTRA_OECONF_PATHS = " \ 
-                      --with-gxx-include-dir=${STAGING_DIR_TARGET}${target_includedir}/c++/${BINV} \ 
-                      --with-sysroot=${STAGING_DIR_TARGET} \ 
-                      --with-build-sysroot=${STAGING_DIR_TARGET}"
+EXTRA_OECONF_PATHS = "\ 
+    --with-gxx-include-dir=${STAGING_DIR_TARGET}${target_includedir}/c++/${BINV} \ 
+    --with-sysroot=${STAGING_DIR_TARGET} \ 
+    --with-build-sysroot=${STAGING_DIR_TARGET} \
+"
 
 
meta/recipes-devtools/gcc/gcc-4.9.inc +95 -85

194 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-configure-common.inc +24 -22

59 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-cross-canadian.inc +14 -10
index f0a03a6..7da5058 100644
@@ -9,10 +9,12 @@ GCCMULTILIB = "--enable-multilib"
 
 require gcc-configure-common.inc
 
-EXTRA_OECONF_PATHS = "--with-gxx-include-dir=${SDKPATH}/sysroots/${TUNE_PKGARCH}${TARGET_VENDOR}-${TARGET_OS}${target_includedir}/c++/${BINV} \
-                      --with-build-time-tools=${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin \
-                      --with-sysroot=${SDKPATH}/sysroots/${TUNE_PKGARCH}${TARGET_VENDOR}-${TARGET_OS} \
-                      --with-build-sysroot=${STAGING_DIR_TARGET}"
+EXTRA_OECONF_PATHS = "\
+    --with-gxx-include-dir=${SDKPATH}/sysroots/${TUNE_PKGARCH}${TARGET_VENDOR}-${TARGET_OS}${target_includedir}/c++/${BINV} \
+    --with-build-time-tools=${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin \
+    --with-sysroot=${SDKPATH}/sysroots/${TUNE_PKGARCH}${TARGET_VENDOR}-${TARGET_OS} \
+    --with-build-sysroot=${STAGING_DIR_TARGET} \
+"
 # We have to point gcc at a sysroot but we don't need to rebuild if this changes
 # e.g. we switch between different machines with different tunes.
 EXTRA_OECONF_PATHS[vardepsexclude] = "TUNE_PKGARCH"
@@ -82,14 +84,14 @@ FILES_${PN} = "\
     ${prefix}/${TARGET_SYS}/bin/* \
     ${prefix}/${TARGET_SYS}/lib/* \
     ${prefix}/${TARGET_SYS}/usr/include/* \
-    "
+"
 INSANE_SKIP_${PN} += "dev-so"
 
 FILES_${PN}-doc = "\
     ${infodir} \
     ${mandir} \
     ${gcclibdir}/${TARGET_SYS}/${BINV}/include/README \
-    "
+"
 
 EXEEXT = ""
 
@@ -156,11 +158,13 @@ SYSTEMHEADERS = "/usr/include"
 SYSTEMLIBS = "${target_base_libdir}/"
 SYSTEMLIBS1 = "${target_libdir}/"
 
-EXTRA_OECONF += " --enable-poison-system-directories"
+EXTRA_OECONF += "--enable-poison-system-directories"
 
-EXTRA_OECONF += "--disable-libunwind-exceptions \
-		--with-mpfr=${STAGING_DIR_HOST}${layout_exec_prefix} \
-		--with-mpc=${STAGING_DIR_HOST}${layout_exec_prefix}"
+EXTRA_OECONF += "\
+    --disable-libunwind-exceptions \
+    --with-mpfr=${STAGING_DIR_HOST}${layout_exec_prefix} \
+    --with-mpc=${STAGING_DIR_HOST}${layout_exec_prefix} \
+"
 
 # gcc 4.7 needs -isystem
 export ARCH_FLAGS_FOR_TARGET = "--sysroot=${STAGING_DIR_TARGET} -isystem=${target_includedir}"
meta/recipes-devtools/gcc/gcc-cross-initial.inc +17 -15
index 5a6da8b..b8e3a86 100644
@@ -11,22 +11,24 @@ CROSS_TARGET_SYS_DIR_append = ".${PN}"
 
 # This is intended to be a -very- basic config
 # sysroot is needed in case we use libc-initial
-EXTRA_OECONF = "--with-newlib \
-		--without-headers \
-		--disable-shared \
-		--disable-threads \
-		--disable-multilib \
-		--disable-__cxa_atexit \
-		--enable-languages=c \
-                ${OPTSPACE} \
-		--program-prefix=${TARGET_PREFIX} \
-		--with-sysroot=${STAGING_DIR_TARGET} \
-		--with-build-sysroot=${GCCCROSS_BUILDSYSROOT} \
-		${EXTRA_OECONF_INITIAL} \
-		${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', '--with-ld=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}ld.bfd', '', d)} \
-		${EXTRA_OECONF_FPU}"
+EXTRA_OECONF = "\
+    --with-newlib \
+    --without-headers \
+    --disable-shared \
+    --disable-threads \
+    --disable-multilib \
+    --disable-__cxa_atexit \
+    --enable-languages=c \
+    ${OPTSPACE} \
+    --program-prefix=${TARGET_PREFIX} \
+    --with-sysroot=${STAGING_DIR_TARGET} \
+    --with-build-sysroot=${GCCCROSS_BUILDSYSROOT} \
+    ${EXTRA_OECONF_INITIAL} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', '--with-ld=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}ld.bfd', '', d)} \
+    ${EXTRA_OECONF_FPU} \
+"
 
-EXTRA_OECONF += " --with-native-system-header-dir=${SYSTEMHEADERS} "
+EXTRA_OECONF += "--with-native-system-header-dir=${SYSTEMHEADERS}"
 
 GCCCROSS_BUILDSYSROOT = "${B}/tmpsysroot"
 
meta/recipes-devtools/gcc/gcc-cross.inc +17 -11
index cf3e5e8..64d0652 100644
@@ -13,17 +13,23 @@ PN = "gcc-cross-${TARGET_ARCH}"
 
 require gcc-configure-common.inc
 
-EXTRA_OECONF += " --enable-poison-system-directories"
-EXTRA_OECONF_append_sh4 = " --with-multilib-list= --enable-incomplete-targets "
-
-EXTRA_OECONF += "--disable-libunwind-exceptions \
-                 --with-mpfr=${STAGING_DIR_NATIVE}${prefix_native} \
-                 --with-system-zlib "
-
-EXTRA_OECONF_PATHS = " \
-                      --with-gxx-include-dir=${STAGING_DIR_TARGET}${target_includedir}/c++/${BINV} \
-                      --with-sysroot=${STAGING_DIR_TARGET} \
-                      --with-build-sysroot=${STAGING_DIR_TARGET}"
+EXTRA_OECONF += "--enable-poison-system-directories"
+EXTRA_OECONF_append_sh4 = " \
+    --with-multilib-list= \
+    --enable-incomplete-targets \
+"
+
+EXTRA_OECONF += "\
+    --disable-libunwind-exceptions \
+    --with-mpfr=${STAGING_DIR_NATIVE}${prefix_native} \
+    --with-system-zlib \
+"
+
+EXTRA_OECONF_PATHS = "\
+    --with-gxx-include-dir=${STAGING_DIR_TARGET}${target_includedir}/c++/${BINV} \
+    --with-sysroot=${STAGING_DIR_TARGET} \
+    --with-build-sysroot=${STAGING_DIR_TARGET} \
+"
 
 ARCH_FLAGS_FOR_TARGET += "-isystem${STAGING_DIR_TARGET}${target_includedir}"
 
meta/recipes-devtools/gcc/gcc-runtime.inc +78 -75

199 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-target.inc +53 -53

158 lines not on this page · raw message

meta/recipes-devtools/gcc/libgcc.inc +18 -17
index 45dd151..22c42d5 100644
@@ -3,25 +3,26 @@ require libgcc-common.inc
 DEPENDS = "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}g++"
 
 PACKAGES = "\
-  ${PN} \
-  ${PN}-dev \
-  ${PN}-dbg \
-  libgcov-dev \
-  "
+    ${PN} \
+    ${PN}-dev \
+    ${PN}-dbg \
+    libgcov-dev \
+"
 
 FILES_${PN} = "${base_libdir}/libgcc*.so.*"
-FILES_${PN}-dev = " \
-  ${base_libdir}/libgcc*.so \
-  ${libdir}/${TARGET_SYS}/${BINV}/*crt* \
-  ${libdir}/${TARGET_SYS}/${BINV}/64 \
-  ${libdir}/${TARGET_SYS}/${BINV}/32 \
-  ${libdir}/${TARGET_SYS}/${BINV}/x32 \
-  ${libdir}/${TARGET_SYS}/${BINV}/n32 \
-  ${libdir}/${TARGET_SYS}/${BINV}/libgcc* \
-  ${@base_conditional('TARGET_SYS_NO_EXTENSION', '${TARGET_SYS}', '', '${libdir}/${TARGET_SYS_NO_EXTENSION}', d)}"
-FILES_libgcov-dev = " \
-  ${libdir}/${TARGET_SYS}/${BINV}/libgcov.a \
-  "
+FILES_${PN}-dev = "\
+    ${base_libdir}/libgcc*.so \
+    ${libdir}/${TARGET_SYS}/${BINV}/*crt* \
+    ${libdir}/${TARGET_SYS}/${BINV}/64 \
+    ${libdir}/${TARGET_SYS}/${BINV}/32 \
+    ${libdir}/${TARGET_SYS}/${BINV}/x32 \
+    ${libdir}/${TARGET_SYS}/${BINV}/n32 \
+    ${libdir}/${TARGET_SYS}/${BINV}/libgcc* \
+    ${@base_conditional('TARGET_SYS_NO_EXTENSION', '${TARGET_SYS}', '', '${libdir}/${TARGET_SYS_NO_EXTENSION}', d)} \
+"
+FILES_libgcov-dev = "\
+    ${libdir}/${TARGET_SYS}/${BINV}/libgcov.a \
+"
 FILES_${PN}-dbg += "${base_libdir}/.debug/"
 
 LIBGCCBUILDTREENAME = "gcc-build-internal-"
meta/recipes-devtools/gcc/libgfortran.inc +15 -14
index 7bf4121..cf7942f 100644
@@ -1,8 +1,9 @@
 require gcc-configure-common.inc
 
-EXTRA_OECONF_PATHS = " \
+EXTRA_OECONF_PATHS = "\
     --with-sysroot=${STAGING_DIR_TARGET} \
-    --with-build-sysroot=${STAGING_DIR_TARGET}"
+    --with-build-sysroot=${STAGING_DIR_TARGET} \
+"
 
 do_configure () {
 	mtarget=`echo ${TARGET_SYS} | sed -e s#-${SDKPKGSUFFIX}##`
@@ -45,20 +46,20 @@ DEPENDS = "gcc-runtime"
 BBCLASSEXTEND = "nativesdk"
 
 PACKAGES = "\
-  ${PN}-dbg \
-  libgfortran \
-  libgfortran-dev \
-  libgfortran-staticdev \
+    ${PN}-dbg \
+    libgfortran \
+    libgfortran-dev \
+    libgfortran-staticdev \
 "
 FILES_${PN} = "${libdir}/libgfortran.so.*"
-FILES_${PN}-dev = " \
-  ${libdir}/libgfortran*.so \
-  ${libdir}/libgfortran.spec \
-  ${libdir}/libgfortran.la \
-  ${libdir}/gcc/${TARGET_SYS}/${BINV}/libgfortranbegin.* \
-  ${libdir}/gcc/${TARGET_SYS}/${BINV}/libcaf_single*"
-FILES_${PN}-staticdev = " \
-  ${libdir}/libgfortran.a"
+FILES_${PN}-dev = "\
+    ${libdir}/libgfortran*.so \
+    ${libdir}/libgfortran.spec \
+    ${libdir}/libgfortran.la \
+    ${libdir}/gcc/${TARGET_SYS}/${BINV}/libgfortranbegin.* \
+    ${libdir}/gcc/${TARGET_SYS}/${BINV}/libcaf_single* \
+"
+FILES_${PN}-staticdev = "${libdir}/libgfortran.a"
 
 INSANE_SKIP_${MLPREFIX}libgfortran-dev = "staticdev"
 
Signature · 1 line
1.8.5.5
#2 lore raw

PATCH v2 2/9 gcc: remove inappropriate patch

In reply to Peter A. Bigot

0037-gcc-4.8-PR56797.patch was originally added as an OE backport during 4.8.0. Upstream merged it in 4.8.1, and it was present in 4.9.0.

The original patch still applies to 4.9.1 (and presumably 4.8.2), but now is modifying store_multiple_sequence instead of load_multiple_sequence (the two functions are nearly identical). It may or may not be necessary in store_multiple_sequence, but absent a bug report upstream supporting its application in this case, or a least an updated comment and upstream status in the patch, I think this patch should be dropped.

---
 meta/recipes-devtools/gcc/gcc-4.8.inc              |  1 -
 .../gcc/gcc-4.8/0037-gcc-4.8-PR56797.patch         | 66 ----------------------
 meta/recipes-devtools/gcc/gcc-4.9.inc              |  1 -
 .../gcc/gcc-4.9/0037-gcc-4.8-PR56797.patch         | 66 ----------------------
 4 files changed, 134 deletions(-)
 delete mode 100644 meta/recipes-devtools/gcc/gcc-4.8/0037-gcc-4.8-PR56797.patch
 delete mode 100644 meta/recipes-devtools/gcc/gcc-4.9/0037-gcc-4.8-PR56797.patch
meta/recipes-devtools/gcc/gcc-4.8.inc +0 -1
index 80a3fc4..dbe1ba6 100644
@@ -59,7 +59,6 @@ SRC_URI = "\
     file://0033-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch \
     file://0034-Use-the-multilib-config-files-from-B-instead-of-usin.patch \
     file://0035-wcast-qual-PR-55383.patch \
-    file://0037-gcc-4.8-PR56797.patch \
     file://0038-gcc-4.8-build-args.patch \
     file://0039-gcc-4.8-PR57717.patch \
     file://0040-fix-g++-sysroot.patch \
meta/recipes-devtools/gcc/gcc-4.8/0037-gcc-4.8-PR56797.patch deleted +0 -66

66 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-4.9.inc +0 -1
index 5a1c028..01dfde1 100644
@@ -58,7 +58,6 @@ SRC_URI = "\
     file://0032-libtool.patch \
     file://0033-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch \
     file://0034-Use-the-multilib-config-files-from-B-instead-of-usin.patch \
-    file://0037-gcc-4.8-PR56797.patch \
     file://0040-fix-g++-sysroot.patch \
     file://0041-libtool-avoid-libdir.patch \
     file://0043-cpp.patch \
meta/recipes-devtools/gcc/gcc-4.9/0037-gcc-4.8-PR56797.patch deleted +0 -66

66 lines not on this page · raw message

Signature · 1 line
1.8.5.5
#3 lore raw

PATCH v2 3/9 gcc-4.9: Ensure c++ includes are in /usr/include/c++/${BINV}

In reply to Peter A. Bigot

Apply to gcc 4.9 the recent fix to the --with-gxx-include-dir override.

Original OE-Core rev: 5a2ff3e8f7cd7a47a5ab4e581847ecc4df87fca

---
 meta/recipes-devtools/gcc/gcc-4.9.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-devtools/gcc/gcc-4.9.inc +1 -1
index 01dfde1..bdea3405e 100644
@@ -120,7 +120,7 @@ EXTRA_OECONF_INTERMEDIATE = "\
 EXTRA_OECONF_append_libc-uclibc = " --disable-decimal-float "
 
 EXTRA_OECONF_PATHS = "\ 
-    --with-gxx-include-dir=${STAGING_DIR_TARGET}${target_includedir}/c++ \ 
+    --with-gxx-include-dir=${STAGING_DIR_TARGET}${target_includedir}/c++/${BINV} \ 
     --with-sysroot=${STAGING_DIR_TARGET} \ 
     --with-build-sysroot=${STAGING_DIR_TARGET} \
 "
Signature · 1 line
1.8.5.5
#4 lore raw

PATCH v2 4/9 gcc: remove outdated configuration option

In reply to Peter A. Bigot

--enable-libunwind-exceptions was removed from gcc at release 3.4.3 about ten years ago.

---
 meta/recipes-devtools/gcc/gcc-cross-canadian.inc | 1 -
 meta/recipes-devtools/gcc/gcc-cross.inc          | 1 -
 meta/recipes-devtools/gcc/gcc-runtime.inc        | 1 -
 3 files changed, 3 deletions(-)
meta/recipes-devtools/gcc/gcc-cross-canadian.inc +0 -1
index 7da5058..d8868bb 100644
@@ -161,7 +161,6 @@ SYSTEMLIBS1 = "${target_libdir}/"
 EXTRA_OECONF += "--enable-poison-system-directories"
 
 EXTRA_OECONF += "\
-    --disable-libunwind-exceptions \
     --with-mpfr=${STAGING_DIR_HOST}${layout_exec_prefix} \
     --with-mpc=${STAGING_DIR_HOST}${layout_exec_prefix} \
 "
meta/recipes-devtools/gcc/gcc-cross.inc +0 -1
index 64d0652..4cdb55f 100644
@@ -20,7 +20,6 @@ EXTRA_OECONF_append_sh4 = " \
 "
 
 EXTRA_OECONF += "\
-    --disable-libunwind-exceptions \
     --with-mpfr=${STAGING_DIR_NATIVE}${prefix_native} \
     --with-system-zlib \
 "
meta/recipes-devtools/gcc/gcc-runtime.inc +0 -1
index e7d938d..7ce84f1 100644
@@ -8,7 +8,6 @@ EXTRA_OECONF_PATHS = "\
     --with-build-sysroot=${STAGING_DIR_TARGET} \
 "
 
-EXTRA_OECONF += "--disable-libunwind-exceptions"
 EXTRA_OECONF_append_linuxstdbase = " --enable-clocale=gnu"
 
 RUNTIMETARGET = "libssp libstdc++-v3 libgomp libatomic"
Signature · 1 line
1.8.5.5
#5 lore raw

PATCH v2 5/9 gcc-target: make --enable-clocale consistent with gcc-runtime

In reply to Peter A. Bigot
---
 meta/recipes-devtools/gcc/gcc-target.inc | 2 ++
 1 file changed, 2 insertions(+)
meta/recipes-devtools/gcc/gcc-target.inc +2 -0
index 8941f5f..0f9a5f8 100644
@@ -8,6 +8,8 @@ EXTRA_OECONF_PATHS = "\
     --with-gxx-include-dir=${includedir}/c++/${BINV} \
 "
 
+EXTRA_OECONF_append_linuxstdbase = " --enable-clocale=gnu"
+
 EXTRA_OECONF_FPU = "${@get_gcc_fpu_setting(bb, d)}"
 
 PACKAGES = "\
Signature · 1 line
1.8.5.5
#6 lore raw

PATCH v2 6/9 sdk: change EXTRA_OECONF_FPU to EXTRA_OECONF_GCC_FLOAT

In reply to Peter A. Bigot

This variable is used to ensure the proper version of --with-float=FOO is passed to gcc's configure script. gcc also has a --with-fpu=FOO option that means something different. To avoid confusion, change the names to be consistent.

---
 meta/classes/crosssdk.bbclass                      | 2 +-
 meta/classes/nativesdk.bbclass                     | 2 +-
 meta/recipes-devtools/gcc/gcc-common.inc           | 4 ++--
 meta/recipes-devtools/gcc/gcc-configure-common.inc | 4 ++--
 meta/recipes-devtools/gcc/gcc-cross-canadian.inc   | 2 +-
 meta/recipes-devtools/gcc/gcc-cross-initial.inc    | 2 +-
 meta/recipes-devtools/gcc/gcc-target.inc           | 2 +-
 7 files changed, 9 insertions(+), 9 deletions(-)
meta/classes/crosssdk.bbclass +1 -1
index 261a374..7a10c59 100644
@@ -30,6 +30,6 @@ do_populate_sysroot[stamp-extra-info] = ""
 do_packagedata[stamp-extra-info] = ""
 
 # Need to force this to ensure consitency accross architectures
-EXTRA_OECONF_FPU = ""
+EXTRA_OECONF_GCC_FLOAT = ""
 
 USE_NLS = "no"
meta/classes/nativesdk.bbclass +1 -1
index 7f94258..37c9f79 100644
@@ -42,7 +42,7 @@ TARGET_CC_ARCH = "${SDK_CC_ARCH}"
 TARGET_LD_ARCH = "${SDK_LD_ARCH}"
 TARGET_AS_ARCH = "${SDK_AS_ARCH}"
 TARGET_FPU = ""
-EXTRA_OECONF_FPU = ""
+EXTRA_OECONF_GCC_FLOAT = ""
 
 CPPFLAGS = "${BUILDSDK_CPPFLAGS}"
 CFLAGS = "${BUILDSDK_CFLAGS}"
meta/recipes-devtools/gcc/gcc-common.inc +2 -2
index 66a18d9..4c55542 100644
@@ -9,7 +9,7 @@ inherit autotools gettext texinfo
 
 BPN = "gcc"
 
-def get_gcc_fpu_setting(bb, d):
+def get_gcc_float_setting(bb, d):
     if d.getVar('ARMPKGSFX_EABI', True) == "hf" and d.getVar('TRANSLATED_TARGET_ARCH', True) == "arm":
         return "--with-float=hard"
     if d.getVar('TARGET_FPU', True) in [ 'soft' ]:
@@ -18,7 +18,7 @@ def get_gcc_fpu_setting(bb, d):
         return "--enable-e500_double"
     return ""
 
-get_gcc_fpu_setting[vardepvalue] = "${@get_gcc_fpu_setting(bb, d)}"
+get_gcc_float_setting[vardepvalue] = "${@get_gcc_float_setting(bb, d)}"
 
 def get_gcc_mips_plt_setting(bb, d):
     if d.getVar('TRANSLATED_TARGET_ARCH', True) in [ 'mips', 'mipsel' ] and bb.utils.contains('DISTRO_FEATURES', 'mplt', True, False, d):
meta/recipes-devtools/gcc/gcc-configure-common.inc +2 -2
index 9c4e986..3f9d03f 100644
@@ -44,7 +44,7 @@ EXTRA_OECONF = "\
     --without-local-prefix \
     ${OPTSPACE} \
     ${EXTRA_OECONF_BASE} \
-    ${EXTRA_OECONF_FPU} \
+    ${EXTRA_OECONF_GCC_FLOAT} \
     ${EXTRA_OECONF_PATHS} \
     ${@get_gcc_mips_plt_setting(bb, d)} \
     ${@get_gcc_multiarch_setting(bb, d)} \
@@ -63,7 +63,7 @@ EXTRA_OECONF_append_libc-uclibc = " --enable-__cxa_atexit"
 EXTRA_OECONF_append_mips64 = " --with-abi=64 --with-arch-64=mips64 --with-tune-64=mips64"
 EXTRA_OECONF_append_mips64el = " --with-abi=64 --with-arch-64=mips64 --with-tune-64=mips64"
 
-EXTRA_OECONF_FPU ??= ""
+EXTRA_OECONF_GCC_FLOAT ??= ""
 CPPFLAGS = ""
 
 # powerpc needs this to comply with the ABI
meta/recipes-devtools/gcc/gcc-cross-canadian.inc +1 -1
index d8868bb..0b1f37b 100644
@@ -19,7 +19,7 @@ EXTRA_OECONF_PATHS = "\
 # e.g. we switch between different machines with different tunes.
 EXTRA_OECONF_PATHS[vardepsexclude] = "TUNE_PKGARCH"
 TARGET_ARCH[vardepsexclude] = "TUNE_ARCH"
-get_gcc_fpu_setting[vardepvalue] = ""
+get_gcc_float_setting[vardepvalue] = ""
 
 #
 # gcc-cross looks and finds these in ${exec_prefix} but we're not so lucky
meta/recipes-devtools/gcc/gcc-cross-initial.inc +1 -1
index b8e3a86..c655934 100644
@@ -25,7 +25,7 @@ EXTRA_OECONF = "\
     --with-build-sysroot=${GCCCROSS_BUILDSYSROOT} \
     ${EXTRA_OECONF_INITIAL} \
     ${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', '--with-ld=${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}ld.bfd', '', d)} \
-    ${EXTRA_OECONF_FPU} \
+    ${EXTRA_OECONF_GCC_FLOAT} \
 "
 
 EXTRA_OECONF += "--with-native-system-header-dir=${SYSTEMHEADERS}"
meta/recipes-devtools/gcc/gcc-target.inc +1 -1
index 0f9a5f8..a266f16 100644
@@ -10,7 +10,7 @@ EXTRA_OECONF_PATHS = "\
 
 EXTRA_OECONF_append_linuxstdbase = " --enable-clocale=gnu"
 
-EXTRA_OECONF_FPU = "${@get_gcc_fpu_setting(bb, d)}"
+EXTRA_OECONF_GCC_FLOAT = "${@get_gcc_float_setting(bb, d)}"
 
 PACKAGES = "\
     ${PN} ${PN}-plugins ${PN}-symlinks \
Signature · 1 line
1.8.5.5
#7 lore raw

PATCH v2 7/9 gcc: Abstract long double configuration into python function

In reply to Peter A. Bigot

From: Khem Raj <[email protected]>

musl does not support IBM 128 long double for ppc, instead of doing complex overrides move it into a pythong snippet which is easier to read and more compact.

---
 meta/recipes-devtools/gcc/gcc-common.inc           | 5 +++++
 meta/recipes-devtools/gcc/gcc-configure-common.inc | 5 +----
 2 files changed, 6 insertions(+), 4 deletions(-)
meta/recipes-devtools/gcc/gcc-common.inc +5 -0
index 4c55542..497d06a 100644
@@ -25,6 +25,11 @@ def get_gcc_mips_plt_setting(bb, d):
         return "--with-mips-plt"
     return ""
 
+def get_long_double_setting(bb, d):
+    if d.getVar('TRANSLATED_TARGET_ARCH', True) in [ 'powerpc', 'powerpc64' ] and d.getVar('TCLIBC', True) in [ 'uclibc', 'eglibc' ]:
+        return "--with-long-double-128"
+    return ""
+
 def get_gcc_multiarch_setting(bb, d):
     target_arch = d.getVar('TRANSLATED_TARGET_ARCH', True)
     multiarch_options = {
meta/recipes-devtools/gcc/gcc-configure-common.inc +1 -4
index 3f9d03f..71dce12 100644
@@ -47,6 +47,7 @@ EXTRA_OECONF = "\
     ${EXTRA_OECONF_GCC_FLOAT} \
     ${EXTRA_OECONF_PATHS} \
     ${@get_gcc_mips_plt_setting(bb, d)} \
+    ${@get_long_double_setting(bb, d)} \
     ${@get_gcc_multiarch_setting(bb, d)} \
 "
 
@@ -66,10 +67,6 @@ EXTRA_OECONF_append_mips64el = " --with-abi=64 --with-arch-64=mips64 --with-tune
 EXTRA_OECONF_GCC_FLOAT ??= ""
 CPPFLAGS = ""
 
-# powerpc needs this to comply with the ABI
-EXTRA_OECONF_append_powerpc = " --with-long-double-128"
-EXTRA_OECONF_append_powerpc64 = " --with-long-double-128"
-
 SYSTEMHEADERS = "${target_includedir}"
 SYSTEMLIBS = "${target_base_libdir}/"
 SYSTEMLIBS1 = "${target_libdir}/"
Signature · 1 line
1.8.5.5
#8 lore raw

PATCH v2 8/9 gcc: backport patch affecting Linux kernel builds

In reply to Peter A. Bigot

A long-standing bug in gcc turns out to cause problems with unpatched Linux versions due to improved optimization enabled by gcc 4.9. The upstream fix missed the gcc-4.9.1 cut-off. It's also been applied upstream to the 4.8 branch so is being added for OE's 4.8 as well.

---
 meta/recipes-devtools/gcc/gcc-4.8.inc              |  1 +
 .../gcc-4.8/0052-PR-rtl-optimization-61801.patch   | 36 ++++++++++++++++++++++
 meta/recipes-devtools/gcc/gcc-4.9.inc              |  1 +
 .../gcc-4.9/0055-PR-rtl-optimization-61801.patch   | 36 ++++++++++++++++++++++
 4 files changed, 74 insertions(+)
 create mode 100644 meta/recipes-devtools/gcc/gcc-4.8/0052-PR-rtl-optimization-61801.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-4.9/0055-PR-rtl-optimization-61801.patch
meta/recipes-devtools/gcc/gcc-4.8.inc +1 -0
index dbe1ba6..18a6692 100644
@@ -72,6 +72,7 @@ SRC_URI = "\
     file://0048-PR58854_fix_arm_apcs_epilogue.patch \
     file://0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch \
     file://0050-PR-target-58595.patch \
+    file://0052-PR-rtl-optimization-61801.patch \
 "
 SRC_URI[md5sum] = "a3d7d63b9cb6b6ea049469a0c4a43c9d"
 SRC_URI[sha256sum] = "09dc2276c73424bbbfda1dbddc62bbbf900c9f185acf7f3e1d773ce2d7e3cdc8"
meta/recipes-devtools/gcc/gcc-4.8/0052-PR-rtl-optimization-61801.patch new file +36 -0
new file mode 100644
index 0000000..300b204
@@ -0,0 +1,36 @@
+From 8dfe30973ab03f0480f1e249f320e78f210dc230 Mon Sep 17 00:00:00 2001
+From: rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
+Date: Thu, 17 Jul 2014 07:49:44 +0000
+Subject: [PATCH] 2014-07-17  Richard Biener  <[email protected]>
+
+	PR rtl-optimization/61801
+	* sched-deps.c (sched_analyze_2): For ASM_OPERANDS and
+	ASM_INPUT don't set reg_pending_barrier if it appears in a
+	debug-insn.
+
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-4_8-branch@212740 138bc75d-0d04-0410-961f-82ee72b054a4
+
+Upstream-Status: Backport [https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61801]
+Signed-off-by: Peter A. Bigot <[email protected]>
+
+---
+ gcc/sched-deps.c | 3 ++-
+
+diff --git a/gcc/sched-deps.c b/gcc/sched-deps.c
+index 07857f2..4ac2542 100644
+--- a/gcc/sched-deps.c
++++ b/gcc/sched-deps.c
+@@ -2744,7 +2744,8 @@ sched_analyze_2 (struct deps_desc *deps, rtx x, rtx insn)
+ 	   Consider for instance a volatile asm that changes the fpu rounding
+ 	   mode.  An insn should not be moved across this even if it only uses
+ 	   pseudo-regs because it might give an incorrectly rounded result.  */
+-	if (code != ASM_OPERANDS || MEM_VOLATILE_P (x))
++	if ((code != ASM_OPERANDS || MEM_VOLATILE_P (x))
++	    && !DEBUG_INSN_P (insn))
+ 	  reg_pending_barrier = TRUE_BARRIER;
+ 
+ 	/* For all ASM_OPERANDS, we must traverse the vector of input operands.
+-- 
+1.8.5.5
+
meta/recipes-devtools/gcc/gcc-4.9.inc +1 -0
index bdea3405e..25778bd 100644
@@ -69,6 +69,7 @@ SRC_URI = "\
     file://0051-eabispe.patch \
     file://0053-gcc-fix-segfault-from-calling-free-on-non-malloc-d-a.patch \
     file://0054-gcc-Makefile.in-fix-parallel-building-failure.patch \
+    file://0055-PR-rtl-optimization-61801.patch \
 "
 SRC_URI[md5sum] = "fddf71348546af523353bd43d34919c1"
 SRC_URI[sha256sum] = "d334781a124ada6f38e63b545e2a3b8c2183049515a1abab6d513f109f1d717e"
meta/recipes-devtools/gcc/gcc-4.9/0055-PR-rtl-optimization-61801.patch new file +36 -0
new file mode 100644
index 0000000..b27abde
@@ -0,0 +1,36 @@
+From 556537c4ad0df4cbebb74197bb2bdea75cf5dd35 Mon Sep 17 00:00:00 2001
+From: rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
+Date: Thu, 17 Jul 2014 07:48:49 +0000
+Subject: [PATCH] 2014-07-17  Richard Biener  <[email protected]>
+
+	PR rtl-optimization/61801
+	* sched-deps.c (sched_analyze_2): For ASM_OPERANDS and
+	ASM_INPUT don't set reg_pending_barrier if it appears in a
+	debug-insn.
+
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-4_9-branch@212739 138bc75d-0d04-0410-961f-82ee72b054a4
+
+Upstream-Status: Backport [https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61801]
+Signed-off-by: Peter A. Bigot <[email protected]>
+
+---
+ gcc/sched-deps.c | 3 ++-
+
+diff --git a/gcc/sched-deps.c b/gcc/sched-deps.c
+index efc4223..df29bd3 100644
+--- a/gcc/sched-deps.c
++++ b/gcc/sched-deps.c
+@@ -2750,7 +2750,8 @@ sched_analyze_2 (struct deps_desc *deps, rtx x, rtx insn)
+ 	   Consider for instance a volatile asm that changes the fpu rounding
+ 	   mode.  An insn should not be moved across this even if it only uses
+ 	   pseudo-regs because it might give an incorrectly rounded result.  */
+-	if (code != ASM_OPERANDS || MEM_VOLATILE_P (x))
++	if ((code != ASM_OPERANDS || MEM_VOLATILE_P (x))
++	    && !DEBUG_INSN_P (insn))
+ 	  reg_pending_barrier = TRUE_BARRIER;
+ 
+ 	/* For all ASM_OPERANDS, we must traverse the vector of input operands.
+-- 
+1.8.5.5
+
Signature · 1 line
1.8.5.5
#9 lore raw

PATCH v2 9/9 gcc: update compiler architecture to match gcc-runtime (armv6, armv7a)

In reply to Peter A. Bigot

The gcc-runtime recipe builds the gcc libraries including libstdc++ with $TARGET_CC_ARCH flags, which include -march=FOO flags that affect whether atomic instructions are available. This causes an ABI incompatibility when the compiler by default generates code for less capable architectures. For example, gcc-runtime libraries on a Cortex-A8 are built with a different C++11/C++14 mutex implementation than is used code compiled outside OE and without architecture-specific flags.

This commit fixes the problem specifically for ABI issues related to atomic instructions available in ARMV6 and subsequent architectures. Other ABI incompatibilities may remain in other architectures.

See: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62100

---
 meta/recipes-devtools/gcc/gcc-configure-common.inc | 7 +++++++
 1 file changed, 7 insertions(+)
meta/recipes-devtools/gcc/gcc-configure-common.inc +7 -0
index 71dce12..48fb799 100644
@@ -64,6 +64,13 @@ EXTRA_OECONF_append_libc-uclibc = " --enable-__cxa_atexit"
 EXTRA_OECONF_append_mips64 = " --with-abi=64 --with-arch-64=mips64 --with-tune-64=mips64"
 EXTRA_OECONF_append_mips64el = " --with-abi=64 --with-arch-64=mips64 --with-tune-64=mips64"
 
+# ARMv6+ adds atomic instructions that affect the ABI in libraries built
+# with TUNE_CCARGS in gcc-runtime.  Make the compiler default to a
+# compatible architecture.  armv6 and armv7a cover the minimum tune
+# features used in OE.
+EXTRA_OECONF_append_armv6 = " --with-arch=armv6"
+EXTRA_OECONF_append_armv7a = " --with-arch=armv7-a"
+
 EXTRA_OECONF_GCC_FLOAT ??= ""
 CPPFLAGS = ""
 
Signature · 1 line
1.8.5.5