Skip to contentSkip to conversation

gcc-9.0: Add recipes for upcoming gcc 9.0 release in mid-2019

PATCH In review Khem Raj 4 participants 7 messages Apr 30, 2019 – May 2, 2019

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/1 gcc-9.0: Add recipes for upcoming gcc 9.0 release in mid-2019

Its already in RC phase now.

---
 meta/recipes-devtools/gcc/gcc-9.0.inc         | 120 ++++++++
 ...0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch |  42 +++
 .../0002-gcc-poison-system-directories.patch  | 203 ++++++++++++++
 ...-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch |  73 +++++
 .../gcc-9.0/0004-64-bit-multilib-hack.patch   | 119 ++++++++
 .../gcc/gcc-9.0/0005-optional-libstdc.patch   | 125 +++++++++
 ...gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch |  59 ++++
 .../gcc-9.0/0007-COLLECT_GCC_OPTIONS.patch    |  38 +++
 ...ts.h-in-B-instead-of-S-and-t-oe-in-B.patch |  96 +++++++
 .../0009-fortran-cross-compile-hack.patch     |  46 ++++
 .../gcc/gcc-9.0/0010-cpp-honor-sysroot.patch  |  54 ++++
 .../0011-MIPS64-Default-to-N64-ABI.patch      |  57 ++++
 ...AMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch | 232 ++++++++++++++++
 ...gcc-Fix-argument-list-too-long-error.patch |  40 +++
 .../gcc/gcc-9.0/0014-Disable-sdt.patch        | 113 ++++++++
 .../gcc/gcc-9.0/0015-libtool.patch            |  42 +++
 ...s-fix-v4bx-to-linker-to-support-EABI.patch |  43 +++
 ...-config-files-from-B-instead-of-usin.patch | 102 +++++++
 ...ir-from-.la-which-usually-points-to-.patch |  31 +++
 .../gcc/gcc-9.0/0019-export-CPP.patch         |  53 ++++
 ...e-target-gcc-headers-can-be-included.patch |  98 +++++++
 ...ild-with-disable-dependency-tracking.patch |  54 ++++
 ...t-directory-during-relink-if-inst_pr.patch |  38 +++
 ...IR-replacement-instead-of-hardcoding.patch |  29 ++
 ...24-aarch64-Add-support-for-musl-ldso.patch |  28 ++
 ...-fix-libcc1-s-install-path-and-rpath.patch |  54 ++++
 ...le-sysroot-support-for-nativesdk-gcc.patch | 213 +++++++++++++++
 ...sroot-gcc-version-specific-dirs-with.patch | 102 +++++++
 ...ous-_FOR_BUILD-and-related-variables.patch | 137 ++++++++++
 ...029-nios2-Define-MUSL_DYNAMIC_LINKER.patch |  28 ++
 ...d-to-link-commandline-for-musl-targe.patch |  87 ++++++
 ...bgcc-Add-knob-to-use-ldbl-128-on-ppc.patch | 125 +++++++++
 ...using-LDFLAGS-not-just-SHLIB_LDFLAGS.patch |  29 ++
 ...as-for-__cpu_indicator_init-instead-.patch |  86 ++++++
 .../0034-sync-gcc-stddef.h-with-musl.patch    |  91 ++++++
 ...-fault-in-precompiled-header-generat.patch |  60 ++++
 .../0036-Fix-for-testsuite-failure.patch      | 258 ++++++++++++++++++
 ...Re-introduce-spe-commandline-options.patch |  41 +++
 .../gcc/gcc-cross-canadian_9.0.bb             |   5 +
 meta/recipes-devtools/gcc/gcc-cross_9.0.bb    |   3 +
 meta/recipes-devtools/gcc/gcc-crosssdk_9.0.bb |   2 +
 meta/recipes-devtools/gcc/gcc-runtime_9.0.bb  |  12 +
 .../gcc/gcc-sanitizers_9.0.bb                 |   7 +
 meta/recipes-devtools/gcc/gcc-source_9.0.bb   |   4 +
 meta/recipes-devtools/gcc/gcc_9.0.bb          |  14 +
 .../gcc/libgcc-initial_9.0.bb                 |   5 +
 meta/recipes-devtools/gcc/libgcc_9.0.bb       |   5 +
 meta/recipes-devtools/gcc/libgfortran_9.0.bb  |   3 +
 48 files changed, 3306 insertions(+)
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0.inc
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0002-gcc-poison-system-directories.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0003-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0004-64-bit-multilib-hack.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0005-optional-libstdc.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0006-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0007-COLLECT_GCC_OPTIONS.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0008-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0009-fortran-cross-compile-hack.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0010-cpp-honor-sysroot.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0011-MIPS64-Default-to-N64-ABI.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0012-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0013-gcc-Fix-argument-list-too-long-error.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0014-Disable-sdt.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0015-libtool.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0016-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0017-Use-the-multilib-config-files-from-B-instead-of-usin.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0018-Avoid-using-libdir-from-.la-which-usually-points-to-.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0019-export-CPP.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0020-Ensure-target-gcc-headers-can-be-included.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0021-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0022-Don-t-search-host-directory-during-relink-if-inst_pr.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0023-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0024-aarch64-Add-support-for-musl-ldso.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0025-libcc1-fix-libcc1-s-install-path-and-rpath.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0026-handle-sysroot-support-for-nativesdk-gcc.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0027-Search-target-sysroot-gcc-version-specific-dirs-with.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0028-Fix-various-_FOR_BUILD-and-related-variables.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0029-nios2-Define-MUSL_DYNAMIC_LINKER.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0030-Add-ssp_nonshared-to-link-commandline-for-musl-targe.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0031-libgcc-Add-knob-to-use-ldbl-128-on-ppc.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0032-Link-libgcc-using-LDFLAGS-not-just-SHLIB_LDFLAGS.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0033-libgcc_s-Use-alias-for-__cpu_indicator_init-instead-.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0034-sync-gcc-stddef.h-with-musl.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0035-fix-segmentation-fault-in-precompiled-header-generat.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0036-Fix-for-testsuite-failure.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-9.0/0037-Re-introduce-spe-commandline-options.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-cross-canadian_9.0.bb
 create mode 100644 meta/recipes-devtools/gcc/gcc-cross_9.0.bb
 create mode 100644 meta/recipes-devtools/gcc/gcc-crosssdk_9.0.bb
 create mode 100644 meta/recipes-devtools/gcc/gcc-runtime_9.0.bb
 create mode 100644 meta/recipes-devtools/gcc/gcc-sanitizers_9.0.bb
 create mode 100644 meta/recipes-devtools/gcc/gcc-source_9.0.bb
 create mode 100644 meta/recipes-devtools/gcc/gcc_9.0.bb
 create mode 100644 meta/recipes-devtools/gcc/libgcc-initial_9.0.bb
 create mode 100644 meta/recipes-devtools/gcc/libgcc_9.0.bb
 create mode 100644 meta/recipes-devtools/gcc/libgfortran_9.0.bb
meta/recipes-devtools/gcc/gcc-9.0.inc new file +120 -0
new file mode 100644
index 0000000000..dfc770b24b
@@ -0,0 +1,120 @@
+require gcc-common.inc
+
+# Third digit in PV should be incremented after a minor release
+
+PV = "9.0.1"
+
+# BINV should be incremented to a revision after a minor gcc release
+
+BINV = "9.0.1"
+
+FILESEXTRAPATHS =. "${FILE_DIRNAME}/gcc-9.0:${FILE_DIRNAME}/gcc-9.0/backport:"
+
+DEPENDS =+ "mpfr gmp libmpc zlib flex-native"
+NATIVEDEPS = "mpfr-native gmp-native libmpc-native zlib-native flex-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 \
+"
+
+#BASEURI ?= "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.xz"
+RELEASE ?= "7833ad1"
+BASEURI ?= "https://repo.or.cz/official-gcc.git/snapshot/${RELEASE}.tar.gz;downloadfilename=gcc-${RELEASE}.tar.gz"
+#RELEASE = "9-20190120"
+#BASEURI ?= "http://mirrors.concertpass.com/gcc/snapshots/${RELEASE}/gcc-${RELEASE}.tar.xz"
+SRC_URI = "\
+           ${BASEURI} \
+           file://0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch \
+           file://0002-gcc-poison-system-directories.patch \
+           file://0003-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch \
+           file://0004-64-bit-multilib-hack.patch \
+           file://0005-optional-libstdc.patch \
+           file://0006-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch \
+           file://0007-COLLECT_GCC_OPTIONS.patch \
+           file://0008-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch \
+           file://0009-fortran-cross-compile-hack.patch \
+           file://0010-cpp-honor-sysroot.patch \
+           file://0011-MIPS64-Default-to-N64-ABI.patch \
+           file://0012-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch \
+           file://0013-gcc-Fix-argument-list-too-long-error.patch \
+           file://0014-Disable-sdt.patch \
+           file://0015-libtool.patch \
+           file://0016-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch \
+           file://0017-Use-the-multilib-config-files-from-B-instead-of-usin.patch \
+           file://0018-Avoid-using-libdir-from-.la-which-usually-points-to-.patch \
+           file://0019-export-CPP.patch \
+           file://0020-Ensure-target-gcc-headers-can-be-included.patch \
+           file://0021-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch \
+           file://0022-Don-t-search-host-directory-during-relink-if-inst_pr.patch \
+           file://0023-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch \
+           file://0024-aarch64-Add-support-for-musl-ldso.patch \
+           file://0025-libcc1-fix-libcc1-s-install-path-and-rpath.patch \
+           file://0026-handle-sysroot-support-for-nativesdk-gcc.patch \
+           file://0027-Search-target-sysroot-gcc-version-specific-dirs-with.patch \
+           file://0028-Fix-various-_FOR_BUILD-and-related-variables.patch \
+           file://0029-nios2-Define-MUSL_DYNAMIC_LINKER.patch \
+           file://0030-Add-ssp_nonshared-to-link-commandline-for-musl-targe.patch \
+           file://0031-libgcc-Add-knob-to-use-ldbl-128-on-ppc.patch \
+           file://0032-Link-libgcc-using-LDFLAGS-not-just-SHLIB_LDFLAGS.patch \
+           file://0033-libgcc_s-Use-alias-for-__cpu_indicator_init-instead-.patch \
+           file://0034-sync-gcc-stddef.h-with-musl.patch \
+           file://0035-fix-segmentation-fault-in-precompiled-header-generat.patch \
+           file://0036-Fix-for-testsuite-failure.patch \
+           file://0037-Re-introduce-spe-commandline-options.patch \
+"
+SRC_URI[md5sum] = "dc3bcb7161626726954b818789e9062b"
+SRC_URI[sha256sum] = "159d5bb442820282a0528807cd94e306be4d41fad116bddf7665d53fc6031cf4"
+#S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/gcc-${PV}"
+#S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/git"
+S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/official-gcc-${RELEASE}"
+B = "${WORKDIR}/gcc-${PV}/build.${HOST_SYS}.${TARGET_SYS}"
+
+# Language Overrides
+FORTRAN = ""
+JAVA = ""
+
+LTO = "--enable-lto"
+SSP ?= "--disable-libssp"
+SSP_mingw32 = "--enable-libssp"
+
+EXTRA_OECONF_BASE = "\
+    ${LTO} \
+    ${SSP} \
+    --enable-libitm \
+    --disable-bootstrap \
+    --disable-libmudflap \
+    --with-system-zlib \
+    ${@'--with-linker-hash-style=${LINKER_HASH_STYLE}' if '${LINKER_HASH_STYLE}' else ''} \
+    --enable-linker-build-id \
+    --with-ppl=no \
+    --with-cloog=no \
+    --enable-checking=release \
+    --enable-cheaders=c_global \
+    --without-isl \
+"
+
+EXTRA_OECONF_INITIAL = "\
+    --disable-libmudflap \
+    --disable-libgomp \
+    --disable-libitm \
+    --disable-libquadmath \
+    --with-system-zlib \
+    --disable-lto \
+    --disable-plugin \
+    --enable-linker-build-id \
+    --enable-decimal-float=no \
+    --without-isl \
+    --disable-libssp \
+"
+
+EXTRA_OECONF_PATHS = "\
+    --with-gxx-include-dir=/not/exist{target_includedir}/c++/${BINV} \
+    --with-sysroot=/not/exist \
+    --with-build-sysroot=${STAGING_DIR_TARGET} \
+"
meta/recipes-devtools/gcc/gcc-9.0/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch new file +42 -0

42 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0002-gcc-poison-system-directories.patch new file +203 -0

203 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0003-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch new file +73 -0

73 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0004-64-bit-multilib-hack.patch new file +119 -0

119 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0005-optional-libstdc.patch new file +125 -0

125 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0006-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch new file +59 -0

59 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0007-COLLECT_GCC_OPTIONS.patch new file +38 -0
new file mode 100644
index 0000000000..a522ada448
@@ -0,0 +1,38 @@
+From c7b8c2a6e81daaa50047c336c8ee90086aa4d4d5 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Fri, 29 Mar 2013 09:16:28 +0400
+Subject: [PATCH 07/37] COLLECT_GCC_OPTIONS
+
+This patch adds --sysroot into COLLECT_GCC_OPTIONS which is used to
+invoke collect2.
+
+Signed-off-by: Khem Raj <[email protected]>
+
+Upstream-Status: Pending
+---
+ gcc/gcc.c | 9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index 308872aef5f..30845e5b125 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -4804,6 +4804,15 @@ set_collect_gcc_options (void)
+ 		sizeof ("COLLECT_GCC_OPTIONS=") - 1);
+ 
+   first_time = TRUE;
++#ifdef HAVE_LD_SYSROOT
++  if (target_system_root_changed && target_system_root)
++    {
++      obstack_grow (&collect_obstack, "'--sysroot=", sizeof("'--sysroot=")-1);
++      obstack_grow (&collect_obstack, target_system_root,strlen(target_system_root));
++      obstack_grow (&collect_obstack, "'", 1);
++      first_time = FALSE;
++    }
++#endif
+   for (i = 0; (int) i < n_switches; i++)
+     {
+       const char *const *args;
+-- 
+2.20.1
+
meta/recipes-devtools/gcc/gcc-9.0/0008-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch new file +96 -0

96 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0009-fortran-cross-compile-hack.patch new file +46 -0

46 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0010-cpp-honor-sysroot.patch new file +54 -0

54 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0011-MIPS64-Default-to-N64-ABI.patch new file +57 -0

57 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0012-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch new file +232 -0

232 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0013-gcc-Fix-argument-list-too-long-error.patch new file +40 -0
new file mode 100644
index 0000000000..f853ff90d2
@@ -0,0 +1,40 @@
+From d8a24eca2d7a222d4910c8a508d75d0d1418e201 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Fri, 29 Mar 2013 09:26:37 +0400
+Subject: [PATCH 13/37] gcc: Fix argument list too long error.
+
+There would be an "Argument list too long" error when the
+build directory is longer than 200, this is caused by:
+
+headers=`echo $(PLUGIN_HEADERS) | tr ' ' '\012' | sort -u`
+
+The PLUGIN_HEADERS is too long before sort, so the "echo" can't handle
+it, use the $(sort list) of GNU make which can handle the too long list
+would fix the problem, the header would be short enough after sorted.
+The "tr ' ' '\012'" was used for translating the space to "\n", the
+$(sort list) doesn't need this.
+
+Signed-off-by: Robert Yang <[email protected]>
+Signed-off-by: Khem Raj <[email protected]>
+
+Upstream-Status: Pending
+---
+ gcc/Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gcc/Makefile.in b/gcc/Makefile.in
+index 3ccff1614bb..88b1aec732b 100644
+--- a/gcc/Makefile.in
++++ b/gcc/Makefile.in
+@@ -3538,7 +3538,7 @@ install-plugin: installdirs lang.install-plugin s-header-vars install-gengtype
+ # We keep the directory structure for files in config or c-family and .def
+ # files. All other files are flattened to a single directory.
+ 	$(mkinstalldirs) $(DESTDIR)$(plugin_includedir)
+-	headers=`echo $(PLUGIN_HEADERS) $$(cd $(srcdir); echo *.h *.def) | tr ' ' '\012' | sort -u`; \
++	headers="$(sort $(PLUGIN_HEADERS) $$(cd $(srcdir); echo *.h *.def))"; \
+ 	srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`; \
+ 	for file in $$headers; do \
+ 	  if [ -f $$file ] ; then \
+-- 
+2.20.1
+
meta/recipes-devtools/gcc/gcc-9.0/0014-Disable-sdt.patch new file +113 -0

113 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0015-libtool.patch new file +42 -0

42 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0016-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch new file +43 -0

43 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0017-Use-the-multilib-config-files-from-B-instead-of-usin.patch new file +102 -0

102 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0018-Avoid-using-libdir-from-.la-which-usually-points-to-.patch new file +31 -0
new file mode 100644
index 0000000000..596337bc1f
@@ -0,0 +1,31 @@
+From 1ffbbb39c9848aa7a04da18fb79b1f0bd7731e00 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Fri, 20 Feb 2015 09:39:38 +0000
+Subject: [PATCH 18/37] Avoid using libdir from .la which usually points to a
+ host path
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Jonathan Liu <[email protected]>
+Signed-off-by: Khem Raj <[email protected]>
+---
+ ltmain.sh | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/ltmain.sh b/ltmain.sh
+index 8e222f7c16b..0a93b4e5c3b 100644
+--- a/ltmain.sh
++++ b/ltmain.sh
+@@ -5628,6 +5628,9 @@ func_mode_link ()
+ 	    absdir="$abs_ladir"
+ 	    libdir="$abs_ladir"
+ 	  else
++	    # Instead of using libdir from .la which usually points to a host path,
++	    # use the path the .la is contained in.
++	    libdir="$abs_ladir"
+ 	    dir="$libdir"
+ 	    absdir="$libdir"
+ 	  fi
+-- 
+2.20.1
+
meta/recipes-devtools/gcc/gcc-9.0/0019-export-CPP.patch new file +53 -0

53 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0020-Ensure-target-gcc-headers-can-be-included.patch new file +98 -0

98 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0021-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch new file +54 -0

54 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0022-Don-t-search-host-directory-during-relink-if-inst_pr.patch new file +38 -0
new file mode 100644
index 0000000000..8316c4d814
@@ -0,0 +1,38 @@
+From 4b9f8cfbfb48a1a9781b7c3a9b867732ef37b7c5 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Tue, 3 Mar 2015 08:21:19 +0000
+Subject: [PATCH 22/37] Don't search host directory during "relink" if
+ $inst_prefix is provided
+
+http://lists.gnu.org/archive/html/libtool-patches/2011-01/msg00026.html
+
+Upstream-Status: Submitted
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ ltmain.sh | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/ltmain.sh b/ltmain.sh
+index 0a93b4e5c3b..6de6ed2f9a0 100644
+--- a/ltmain.sh
++++ b/ltmain.sh
+@@ -6004,12 +6004,13 @@ func_mode_link ()
+ 	      fi
+ 	    else
+ 	      # We cannot seem to hardcode it, guess we'll fake it.
++	      # Default if $libdir is not relative to the prefix:
+ 	      add_dir="-L$libdir"
+-	      # Try looking first in the location we're being installed to.
++
+ 	      if test -n "$inst_prefix_dir"; then
+ 		case $libdir in
+ 		  [\\/]*)
+-		    add_dir="$add_dir -L$inst_prefix_dir$libdir"
++		    add_dir="-L$inst_prefix_dir$libdir"
+ 		    ;;
+ 		esac
+ 	      fi
+-- 
+2.20.1
+
meta/recipes-devtools/gcc/gcc-9.0/0023-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch new file +29 -0
new file mode 100644
index 0000000000..fdea599abd
@@ -0,0 +1,29 @@
+From 3a554b321250f6ddf1277e5559890ee977e78cb0 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Tue, 28 Apr 2015 23:15:27 -0700
+Subject: [PATCH 23/37] Use SYSTEMLIBS_DIR replacement instead of hardcoding
+ base_libdir
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ gcc/config/aarch64/aarch64-linux.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gcc/config/aarch64/aarch64-linux.h b/gcc/config/aarch64/aarch64-linux.h
+index 9d0292d64f2..51661995fc7 100644
+--- a/gcc/config/aarch64/aarch64-linux.h
++++ b/gcc/config/aarch64/aarch64-linux.h
+@@ -21,7 +21,7 @@
+ #ifndef GCC_AARCH64_LINUX_H
+ #define GCC_AARCH64_LINUX_H
+ 
+-#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
++#define GLIBC_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+ 
+ #undef MUSL_DYNAMIC_LINKER
+ #define MUSL_DYNAMIC_LINKER "/lib/ld-musl-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+-- 
+2.20.1
+
meta/recipes-devtools/gcc/gcc-9.0/0024-aarch64-Add-support-for-musl-ldso.patch new file +28 -0
new file mode 100644
index 0000000000..f53c9949c7
@@ -0,0 +1,28 @@
+From b7001034f35e7e5090fa95cb9a622469300cd45d Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Tue, 28 Apr 2015 23:18:39 -0700
+Subject: [PATCH 24/37] aarch64: Add support for musl ldso
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ gcc/config/aarch64/aarch64-linux.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gcc/config/aarch64/aarch64-linux.h b/gcc/config/aarch64/aarch64-linux.h
+index 51661995fc7..db687f753f6 100644
+--- a/gcc/config/aarch64/aarch64-linux.h
++++ b/gcc/config/aarch64/aarch64-linux.h
+@@ -24,7 +24,7 @@
+ #define GLIBC_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+ 
+ #undef MUSL_DYNAMIC_LINKER
+-#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
++#define MUSL_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-musl-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+ 
+ #undef  ASAN_CC1_SPEC
+ #define ASAN_CC1_SPEC "%{%:sanitize(address):-funwind-tables}"
+-- 
+2.20.1
+
meta/recipes-devtools/gcc/gcc-9.0/0025-libcc1-fix-libcc1-s-install-path-and-rpath.patch new file +54 -0

54 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0026-handle-sysroot-support-for-nativesdk-gcc.patch new file +213 -0

213 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0027-Search-target-sysroot-gcc-version-specific-dirs-with.patch new file +102 -0

102 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0028-Fix-various-_FOR_BUILD-and-related-variables.patch new file +137 -0

137 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0029-nios2-Define-MUSL_DYNAMIC_LINKER.patch new file +28 -0
new file mode 100644
index 0000000000..08da1ab986
@@ -0,0 +1,28 @@
+From e293df9a5734b43cb60cc47a3f5ff9af50fee3aa Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Tue, 2 Feb 2016 10:26:10 -0800
+Subject: [PATCH 29/37] nios2: Define MUSL_DYNAMIC_LINKER
+
+Upstream-Status: Pending
+
+Signed-off-by: Marek Vasut <[email protected]>
+Signed-off-by: Khem Raj <[email protected]>
+---
+ gcc/config/nios2/linux.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/gcc/config/nios2/linux.h b/gcc/config/nios2/linux.h
+index 698734add35..eeee60ecfea 100644
+--- a/gcc/config/nios2/linux.h
++++ b/gcc/config/nios2/linux.h
+@@ -30,6 +30,7 @@
+ #define CPP_SPEC "%{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}"
+ 
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-nios2.so.1"
++#define MUSL_DYNAMIC_LINKER  "/lib/ld-musl-nios2.so.1"
+ 
+ #undef LINK_SPEC
+ #define LINK_SPEC LINK_SPEC_ENDIAN \
+-- 
+2.20.1
+
meta/recipes-devtools/gcc/gcc-9.0/0030-Add-ssp_nonshared-to-link-commandline-for-musl-targe.patch new file +87 -0

87 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0031-libgcc-Add-knob-to-use-ldbl-128-on-ppc.patch new file +125 -0

125 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0032-Link-libgcc-using-LDFLAGS-not-just-SHLIB_LDFLAGS.patch new file +29 -0
new file mode 100644
index 0000000000..3de8345f93
@@ -0,0 +1,29 @@
+From 9d76a765a12677597134953352b25dc16dea721e Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Wed, 4 May 2016 21:11:34 -0700
+Subject: [PATCH 32/37] Link libgcc using LDFLAGS, not just SHLIB_LDFLAGS
+
+Upstream-Status: Pending
+
+Signed-off-by: Christopher Larson <[email protected]>
+Signed-off-by: Khem Raj <[email protected]>
+---
+ libgcc/config/t-slibgcc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libgcc/config/t-slibgcc b/libgcc/config/t-slibgcc
+index 099bf23e62f..436b277a79f 100644
+--- a/libgcc/config/t-slibgcc
++++ b/libgcc/config/t-slibgcc
+@@ -32,7 +32,7 @@ SHLIB_INSTALL_SOLINK = $(LN_S) $(SHLIB_SONAME) \
+ 	$(DESTDIR)$(slibdir)$(SHLIB_SLIBDIR_QUAL)/$(SHLIB_SOLINK)
+ 
+ SHLIB_LINK = $(CC) $(LIBGCC2_CFLAGS) -shared -nodefaultlibs \
+-	$(SHLIB_LDFLAGS) \
++	$(LDFLAGS) $(SHLIB_LDFLAGS) \
+ 	-o $(SHLIB_DIR)/$(SHLIB_SONAME).tmp @multilib_flags@ \
+ 	$(SHLIB_OBJS) $(SHLIB_LC) && \
+ 	rm -f $(SHLIB_DIR)/$(SHLIB_SOLINK) && \
+-- 
+2.20.1
+
meta/recipes-devtools/gcc/gcc-9.0/0033-libgcc_s-Use-alias-for-__cpu_indicator_init-instead-.patch new file +86 -0

86 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0034-sync-gcc-stddef.h-with-musl.patch new file +91 -0

91 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0035-fix-segmentation-fault-in-precompiled-header-generat.patch new file +60 -0

60 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0036-Fix-for-testsuite-failure.patch new file +258 -0

53 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-9.0/0037-Re-introduce-spe-commandline-options.patch new file +41 -0

41 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc-cross-canadian_9.0.bb new file +5 -0
new file mode 100644
index 0000000000..bf53c5cd78

Lines of this file are not shown. View the raw message.

meta/recipes-devtools/gcc/gcc-cross_9.0.bb new file +3 -0
new file mode 100644
index 0000000000..b43cca0c52

Lines of this file are not shown. View the raw message.

meta/recipes-devtools/gcc/gcc-crosssdk_9.0.bb new file +2 -0
new file mode 100644
index 0000000000..40a6c4feff

Lines of this file are not shown. View the raw message.

meta/recipes-devtools/gcc/gcc-runtime_9.0.bb new file +12 -0
new file mode 100644
index 0000000000..a1c7a76d0b

Lines of this file are not shown. View the raw message.

meta/recipes-devtools/gcc/gcc-sanitizers_9.0.bb new file +7 -0
new file mode 100644
index 0000000000..f3c7058114

Lines of this file are not shown. View the raw message.

meta/recipes-devtools/gcc/gcc-source_9.0.bb new file +4 -0
new file mode 100644
index 0000000000..b890fa33ea

Lines of this file are not shown. View the raw message.

meta/recipes-devtools/gcc/gcc_9.0.bb new file +14 -0
new file mode 100644
index 0000000000..7d93590588

Lines of this file are not shown. View the raw message.

meta/recipes-devtools/gcc/libgcc-initial_9.0.bb new file +5 -0
new file mode 100644
index 0000000000..0c698c26ec

Lines of this file are not shown. View the raw message.

meta/recipes-devtools/gcc/libgcc_9.0.bb new file +5 -0
new file mode 100644
index 0000000000..ea210a1130

Lines of this file are not shown. View the raw message.

meta/recipes-devtools/gcc/libgfortran_9.0.bb new file +3 -0
new file mode 100644
index 0000000000..71dd8b4bdc

Lines of this file are not shown. View the raw message.

The rest of this diff is not shown. View the raw message.

Signature · 1 line
2.21.0

Part of the diff is not shown here. View the raw message.

#2 lore raw
In reply to Khem Raj
Quoted 3 lines · Khem Raj

Its already in RC phase now.

I ran this on the autobuilder:

https://autobuilder.yoctoproject.org/typhoon/#/builders/85/builds/429
http://errors.yoctoproject.org/Errors/Details/238976/

Basic summary:

a) gcc-source needs a maintainers.inc entry (selftest fail)
b) fortran selftest is broken
c) mdadm fails to compile
d) runtime test gpp2 fails
e) systemd fails to compile
f) on target runtime g++ compile tests fail

error from f and d look related:

Exception: Command cd ~/buildtest/lzip-1.19; make failed with exit code 2: g++ -Wall -W -O2 -c -o arg_parser.o arg_parser.cc arg_parser.cc:20:10: fatal error: cstring: No such file or directory
20 | #include <cstring>

      |          ^~~~~~~~~

compilation terminated.

DEBUG: Partial data from SSH call: /tmp/test.cpp:1:10: fatal error:
limits: No such file or directory
1 | #include <limits>
| ^~~~~~~~
compilation terminated.

DEBUG: time: 1556703543.2447464, endtime: 1556703843.2447433

RESULTS - buildlzip.BuildLzipTest.test_lzip - Testcase 206: ERROR (0.79s) RESULTS - gcc.GccCompileTest.test_gpp2_compile - Testcase 1142: FAILED (0.71s)

Build will look a lot happier with the on target C++ headers fixed! Not too bad for a first pass :)

Cheers,

Richard

author
#5 lore raw
In reply to Richard Purdie
Quoted 6 lines · Richard Purdie
Quoted 3 lines · Khem Raj

Its already in RC phase now.

Quoted 8 lines

I ran this on the autobuilder:

https://autobuilder.yoctoproject.org/typhoon/#/builders/85/builds/429
http://errors.yoctoproject.org/Errors/Details/238976/

Basic summary:

a) gcc-source needs a maintainers.inc entry (selftest fail)

I will fix that in next rev.

Quoted 1 line

b) fortran selftest is broken

some more details on this would be helpful.

Quoted 1 line

c) mdadm fails to compile

Yes, this appeared in my builds too but got ignored since recent builds are using clang
but I will look into fixing it.

Quoted 3 lines

d) runtime test gpp2 fails
e) systemd fails to compile
f) on target runtime g++ compile tests fail

The headers include problem is interesting I will see if I can reproduce it.

Quoted 18 lines

error from f and d look related:

Exception: Command cd ~/buildtest/lzip-1.19; make failed with exit code 2: g++ -Wall -W -O2 -c -o arg_parser.o arg_parser.cc arg_parser.cc:20:10: fatal error: cstring: No such file or directory
20 | #include <cstring>

      |          ^~~~~~~~~

compilation terminated.

DEBUG: Partial data from SSH call: /tmp/test.cpp:1:10: fatal error:
limits: No such file or directory
1 | #include <limits>
| ^~~~~~~~
compilation terminated.

Quoted 8 lines

DEBUG: time: 1556703543.2447464, endtime: 1556703843.2447433

RESULTS - buildlzip.BuildLzipTest.test_lzip - Testcase 206: ERROR (0.79s) RESULTS - gcc.GccCompileTest.test_gpp2_compile - Testcase 1142: FAILED (0.71s)

Build will look a lot happier with the on target C++ headers fixed! Not too bad for a first pass :)

This is because we can build master branch easily for toolchain recipes. so a lot
of pre-emptive work has happened already

Quoted 4 lines

Cheers,

Richard

#6 lore raw
Quoted 14 lines · Khem Raj
Quoted 12 lines · Richard Purdie
Quoted 3 lines · Khem Raj

Its already in RC phase now.

I ran this on the autobuilder:

https://autobuilder.yoctoproject.org/typhoon/#/builders/85/builds/429
http://errors.yoctoproject.org/Errors/Details/238976/

Basic summary:

Quoted 7 lines
Quoted 1 line

a) gcc-source needs a maintainers.inc entry (selftest fail)

I will fix that in next rev.

Quoted 1 line

b) fortran selftest is broken

some more details on this would be helpful.

"oe-selftest -r buildoptions.ToolchainOptions.test_toolchain_fortran" should reproduce.

| In file included from ../../../../../../../../work-shared/gcc-9.0.1-r0/official-gcc-7833ad1/libgfortran/runtime/backtrace.c:27:
| ../../../../../../../../work-shared/gcc-9.0.1-r0/official-gcc-7833ad1/libgfortran/../libgcc/gthr.h:148:10: fatal error: gthr-default.h: No such file or directory
|  #include "gthr-default.h"
|           ^~~~~~~~~~~~~~~~
| compilation terminated.
| Makefile:2772: recipe for target 'backtrace.lo' failed

from

https://autobuilder.yoctoproject.org/typhoon/api/v2/logs/468206/raw

Quoted 7 lines
Quoted 2 lines

c) mdadm fails to compile

Yes, this appeared in my builds too but got ignored since recent builds are using clang
but I will look into fixing it.

Quoted 6 lines
Quoted 3 lines

d) runtime test gpp2 fails
e) systemd fails to compile
f) on target runtime g++ compile tests fail

The headers include problem is interesting I will see if I can reproduce it.

"bitbake core-image-sato-sdk -c testimage"

should reproduce.

Quoted 5 lines
Quoted 2 lines

Build will look a lot happier with the on target C++ headers fixed! Not too bad for a first pass :)

This is because we can build master branch easily for toolchain recipes. so a lot of pre-emptive work has happened already

I can imagine there was quite some work in that, nicely done! :)

Cheers,

Richard