Skip to contentSkip to conversation

gcc: Upgrade GCC to 16.1 release

PATCH Superseded [email protected] 2 participants 15 messages May 18

v2 of 5 Superseded Latest is v5 →

lore
Share & tools
lore
#0 lore raw

v2 cover gcc: Upgrade GCC to 16.1 release

From: Hemanth Kumar M D <[email protected]>

This patch series upgrades GCC to 16.1 and includes the required runtime and compatibility fixes identified during testing in OE-Core. The series also includes fixes for packages failing to build with GCC 16, updates for libatomic runtime handling, and packaging changes for newly generated libatomic_asneeded files.

Changes in v2:
- Add libatomic-dev to elfutils ptest RDEPENDS
- Add libatomic-staticdev to libc-test ptest RDEPENDS
- Package new libcaf_shmem.a static library in libgfortran
- Fix gn build with GCC 16 on musl
- Backport GCC i386 ICE fix with -ffloat-store and SSE [PR125308]

Summary of patches:
- Patch 01: Backport piglit fix for building with GCC 16.
- Patch 02: Backport rxvt-unicode fix for building with GCC 16.
- Patch 03: Disable automatic libatomic linking in glibc.
- Patch 04: Upgrade GCC to 16.1 release.
- Patch 05: Disable automatic libatomic linking during gcc-runtime build.
- Patch 06: Package new libatomic_asneeded runtime files.
- Patch 07: Avoid passing MULTIBUILDTOP to libatomic in OE builds.
- Patch 08: Package new libcaf_shmem.a static library in libgfortran.
- Patch 09: Fix gn build with GCC 16 on musl.
- Patch 10: Add libatomic-dev to elfutils ptest RDEPENDS.
- Patch 11: Add libatomic-staticdev to libc-test ptest RDEPENDS.
- Patch 12: Fix ICE on i386 with -ffloat-store and SSE [PR125308].

 meta/conf/distro/include/maintainers.inc      |  2 +-
 meta/conf/distro/include/tcmode-default.inc   |  2 +-
 meta/recipes-core/glibc/glibc.inc             |  3 +
 meta/recipes-core/musl/libc-test_git.bb       |  1 +
 .../elfutils/elfutils_0.194.bb                |  2 +-
 .../gcc/{gcc-15.2.inc => gcc-16.1.inc}        | 18 ++--
 ...ian_15.2.bb => gcc-cross-canadian_16.1.bb} |  0
 .../{gcc-cross_15.2.bb => gcc-cross_16.1.bb}  |  0
 ...-crosssdk_15.2.bb => gcc-crosssdk_16.1.bb} |  0
 meta/recipes-devtools/gcc/gcc-runtime.inc     | 18 +++-
 ...cc-runtime_15.2.bb => gcc-runtime_16.1.bb} |  0
 ...itizers_15.2.bb => gcc-sanitizers_16.1.bb} |  0
 ...{gcc-source_15.2.bb => gcc-source_16.1.bb} |  0
 ...AMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch |  2 +-
 ...sroot-gcc-version-specific-dirs-with.patch |  4 +-
 ...omic-Do-not-enforce-march-on-aarch64.patch | 18 ++--
 ...025-gcc-testsuite-tweaks-for-mips-OE.patch | 78 ++++++++++-------
 ...6-fix-ICE-with-ffloat-store-PR125308.patch | 85 +++++++++++++++++++
 .../gcc/{gcc_15.2.bb => gcc_16.1.bb}          |  0
 ...initial_15.2.bb => libgcc-initial_16.1.bb} |  0
 .../gcc/{libgcc_15.2.bb => libgcc_16.1.bb}    |  0
 ...ibgfortran_15.2.bb => libgfortran_16.1.bb} |  1 +
 ...001-gn-fix-build-with-gcc-16-on-musl.patch | 31 +++++++
 meta/recipes-devtools/gn/gn_git.bb            |  4 +-
 ...h-rename-local-lerp-to-linear_interp.patch | 46 ++++++++++
 meta/recipes-graphics/piglit/piglit_git.bb    |  1 +
 .../rxvt-unicode/rxvt-unicode.inc             |  3 +-
 .../0001-rxvt-unicode-fix-gcc16-c-20.patch    | 61 +++++++++++++
 28 files changed, 317 insertions(+), 63 deletions(-)
 rename meta/recipes-devtools/gcc/{gcc-15.2.inc => gcc-16.1.inc} (88%)
 rename meta/recipes-devtools/gcc/{gcc-cross-canadian_15.2.bb => gcc-cross-canadian_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-cross_15.2.bb => gcc-cross_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-crosssdk_15.2.bb => gcc-crosssdk_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-runtime_15.2.bb => gcc-runtime_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-sanitizers_15.2.bb => gcc-sanitizers_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-source_15.2.bb => gcc-source_16.1.bb} (100%)
 create mode 100644 meta/recipes-devtools/gcc/gcc/0026-gcc-i386-fix-ICE-with-ffloat-store-PR125308.patch
 rename meta/recipes-devtools/gcc/{gcc_15.2.bb => gcc_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{libgcc-initial_15.2.bb => libgcc-initial_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{libgcc_15.2.bb => libgcc_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{libgfortran_15.2.bb => libgfortran_16.1.bb} (51%)
 create mode 100644 meta/recipes-devtools/gn/files/0001-gn-fix-build-with-gcc-16-on-musl.patch
 create mode 100644 meta/recipes-graphics/piglit/piglit/0001-fbo-blit-stretch-rename-local-lerp-to-linear_interp.patch
 create mode 100644 meta/recipes-sato/rxvt-unicode/rxvt-unicode/0001-rxvt-unicode-fix-gcc16-c-20.patch
Signature · 1 line
2.49.0
#1 lore raw

PATCH v2 1/12 piglit:backport a fix for building with gcc-16

From: Hemanth Kumar M D <[email protected]>

Avoid conflict with C++20 std::lerp from <cmath>, which causes redefinition and ambiguous call errors with newer toolchains.

Upstream-Status: Backport [https://gitlab.freedesktop.org/mesa/piglit/-/commit/ec0fc2fef0755b1595c3799ab25129174a4b2007]

---
 ...h-rename-local-lerp-to-linear_interp.patch | 46 +++++++++++++++++++
 meta/recipes-graphics/piglit/piglit_git.bb    |  1 +
 2 files changed, 47 insertions(+)
 create mode 100644 meta/recipes-graphics/piglit/piglit/0001-fbo-blit-stretch-rename-local-lerp-to-linear_interp.patch
meta/recipes-graphics/piglit/piglit/0001-fbo-blit-stretch-rename-local-lerp-to-linear_interp.patch new file +46 -0
new file mode 100644
index 0000000000..05f1dd687a
@@ -0,0 +1,46 @@
+From ec0fc2fef0755b1595c3799ab25129174a4b2007 Mon Sep 17 00:00:00 2001
+From: Vinson Lee <[email protected]>
+Date: Sat, 7 Feb 2026 18:39:39 -0800
+Subject: [PATCH] fbo-blit-stretch: rename local lerp to linear_interp
+
+Avoid conflict with C++20 std::lerp from <cmath>, which
+causes redefinition and ambiguous call errors with newer
+toolchains.
+
+Upstream-Status: Backport [https://gitlab.freedesktop.org/mesa/piglit/-/commit/ec0fc2fef0755b1595c3799ab25129174a4b2007]
+
+Signed-off-by: Vinson Lee <[email protected]>
+Signed-off-by: Hemanth Kumar M D <[email protected]>
+---
+ tests/fbo/fbo-blit-stretch.cpp | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/tests/fbo/fbo-blit-stretch.cpp b/tests/fbo/fbo-blit-stretch.cpp
+index a83288c0f..b0d362ecd 100644
+--- a/tests/fbo/fbo-blit-stretch.cpp
++++ b/tests/fbo/fbo-blit-stretch.cpp
+@@ -173,7 +173,7 @@ clamp(GLint &x, GLint xmin, GLint xmax)
+ }
+ 
+ static float
+-lerp(float x0, float x1, float w)
++linear_interp(float x0, float x1, float w)
+ {
+ 	return x0 + (x1 - x0) * w;
+ }
+@@ -181,9 +181,9 @@ lerp(float x0, float x1, float w)
+ static float
+ lerp2d(float xy00, float xy01, float xy10, float xy11, float wx, float wy)
+ {
+-	float y0 = lerp(xy00, xy01, wx);
+-	float y1 = lerp(xy10, xy11, wx);
+-	return lerp(y0, y1, wy);
++	float y0 = linear_interp(xy00, xy01, wx);
++	float y1 = linear_interp(xy10, xy11, wx);
++	return linear_interp(y0, y1, wy);
+ }
+ 
+ static float clearColor[4] = {
+-- 
+2.49.0
+
meta/recipes-graphics/piglit/piglit_git.bb +1 -0
index 7659635062..0dd9c58714 100644
@@ -14,6 +14,7 @@ SRC_URI = "git://gitlab.freedesktop.org/mesa/piglit.git;protocol=https;branch=ma
            file://0001-tests-egl-spec-make-egl_ext_surface_compression-cond.patch \
            file://0001-tests-no_error.py-modify-_command-and-not-command.patch \
            file://0001-generated_tests-use-shape-in-place-of-newshape-on-nu.patch \
+           file://0001-fbo-blit-stretch-rename-local-lerp-to-linear_interp.patch \
            "
 UPSTREAM_CHECK_COMMITS = "1"
 
Signature · 1 line
2.49.0
#2 lore raw

PATCH v2 2/12 rxvt-unicode: backport a fix for building with gcc-16

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

rename lerp to avoid conflict with the non-identical function std::lerp

Upstream-Status: Submitted [https://lists.schmorp.de/pipermail/rxvt-unicode/2026q2/002707.html]

---
 .../rxvt-unicode/rxvt-unicode.inc             |  3 +-
 .../0001-rxvt-unicode-fix-gcc16-c-20.patch    | 61 +++++++++++++++++++
 2 files changed, 63 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-sato/rxvt-unicode/rxvt-unicode/0001-rxvt-unicode-fix-gcc16-c-20.patch
meta/recipes-sato/rxvt-unicode/rxvt-unicode.inc +2 -1
index f8c0d8ab83..80791ca511 100644
@@ -11,7 +11,8 @@ DEPENDS = "virtual/libx11 libxt libxft gdk-pixbuf libxmu libptytty ncurses-nativ
 SRC_URI = "http://dist.schmorp.de/rxvt-unicode/Attic/rxvt-unicode-${PV}.tar.bz2 \
 	   file://xwc.patch \
 	   file://rxvt.desktop \
-	   file://rxvt.png"
+	   file://rxvt.png \
+           file://0001-rxvt-unicode-fix-gcc16-c-20.patch"
 
 inherit autotools features_check pkgconfig update-alternatives
 
meta/recipes-sato/rxvt-unicode/rxvt-unicode/0001-rxvt-unicode-fix-gcc16-c-20.patch new file +61 -0

61 lines not on this page · raw message

Signature · 1 line
2.49.0
#3 lore raw

PATCH v2 3/12 glibc: disable automatic libatomic linking

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

GCC 16 introduced -flink-libatomic which automatically injects -latomic_asneeded into link commands via LINK_LIBATOMIC_SPEC. When glibc is built with a GCC 16 cross-compiler, the compiler would attempt to link against libatomic which does not exist yet at this stage.(libatomic is built later as part of gcc-runtime)

---
 meta/recipes-core/glibc/glibc.inc | 3 +++
 1 file changed, 3 insertions(+)
meta/recipes-core/glibc/glibc.inc +3 -0
index dae087d53f..751cc0c572 100644
@@ -46,6 +46,9 @@ EXTRA_OEMAKE += "SHELL=/bin/bash"
 # bash but it can be configured by setting KSHELL Makefile variable
 EXTRA_OEMAKE += "KSHELL=/bin/sh"
 
+TARGET_CC_ARCH += "-fno-link-libatomic"
+SDK_CC_ARCH += "-fno-link-libatomic"
+
 do_configure:prepend() {
 	sed -e "s#/bin/bash#/bin/sh#" -i ${S}/elf/ldd.bash.in
 }
Signature · 1 line
2.49.0
#4 lore raw

PATCH v2 4/12 gcc: Upgrade GCC to 16.1 release

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

Notable changes in GCC 16 include:
- Improved C23/C++23 support and initial C++26 features
- Enhanced diagnostics and static analyzer improvements
- Optimizer and code generation enhancements
- Target-specific updates for AArch64, RISC-V, x86, and others
- Runtime library updates (libstdc++, libatomic, libgomp, libsanitizer)
- Multiple bug fixes and performance improvements

* Rebased existing OE-Core patches for GCC 16.1 and dropped patches merged upstream.

For detailed info: https://gcc.gnu.org/gcc-16/changes.html

---
 meta/conf/distro/include/maintainers.inc      |  2 +-
 meta/conf/distro/include/tcmode-default.inc   |  2 +-
 .../gcc/{gcc-15.2.inc => gcc-16.1.inc}        | 17 ++--
 ...ian_15.2.bb => gcc-cross-canadian_16.1.bb} |  0
 .../{gcc-cross_15.2.bb => gcc-cross_16.1.bb}  |  0
 ...-crosssdk_15.2.bb => gcc-crosssdk_16.1.bb} |  0
 ...cc-runtime_15.2.bb => gcc-runtime_16.1.bb} |  0
 ...itizers_15.2.bb => gcc-sanitizers_16.1.bb} |  0
 ...{gcc-source_15.2.bb => gcc-source_16.1.bb} |  0
 ...AMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch |  2 +-
 ...sroot-gcc-version-specific-dirs-with.patch |  4 +-
 ...omic-Do-not-enforce-march-on-aarch64.patch | 18 ++---
 ...025-gcc-testsuite-tweaks-for-mips-OE.patch | 78 +++++++++++--------
 .../gcc/{gcc_15.2.bb => gcc_16.1.bb}          |  0
 ...initial_15.2.bb => libgcc-initial_16.1.bb} |  0
 .../gcc/{libgcc_15.2.bb => libgcc_16.1.bb}    |  0
 ...ibgfortran_15.2.bb => libgfortran_16.1.bb} |  0
 17 files changed, 66 insertions(+), 57 deletions(-)
 rename meta/recipes-devtools/gcc/{gcc-15.2.inc => gcc-16.1.inc} (88%)
 rename meta/recipes-devtools/gcc/{gcc-cross-canadian_15.2.bb => gcc-cross-canadian_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-cross_15.2.bb => gcc-cross_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-crosssdk_15.2.bb => gcc-crosssdk_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-runtime_15.2.bb => gcc-runtime_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-sanitizers_15.2.bb => gcc-sanitizers_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc-source_15.2.bb => gcc-source_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{gcc_15.2.bb => gcc_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{libgcc-initial_15.2.bb => libgcc-initial_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{libgcc_15.2.bb => libgcc_16.1.bb} (100%)
 rename meta/recipes-devtools/gcc/{libgfortran_15.2.bb => libgfortran_16.1.bb} (100%)
meta/conf/distro/include/maintainers.inc +1 -1
index 24c5a9d712..fdfdec28b5 100644
@@ -200,7 +200,7 @@ RECIPE_MAINTAINER:pn-gcc-cross-canadian-${TRANSLATED_TARGET_ARCH} = "Khem Raj <r
 RECIPE_MAINTAINER:pn-gcc-crosssdk-${SDK_SYS} = "Khem Raj <[email protected]>"
 RECIPE_MAINTAINER:pn-gcc-runtime = "Khem Raj <[email protected]>"
 RECIPE_MAINTAINER:pn-gcc-sanitizers = "Khem Raj <[email protected]>"
-RECIPE_MAINTAINER:pn-gcc-source-15.2.0 = "Khem Raj <[email protected]>"
+RECIPE_MAINTAINER:pn-gcc-source-16.1.0 = "Khem Raj <[email protected]>"
 RECIPE_MAINTAINER:pn-gcompat = "Khem Raj <[email protected]>"
 RECIPE_MAINTAINER:pn-gconf = "Ross Burton <[email protected]>"
 RECIPE_MAINTAINER:pn-gcr = "Unassigned <[email protected]>"
meta/conf/distro/include/tcmode-default.inc +1 -1
index d2dd5abc03..804b32c1dc 100644
@@ -9,7 +9,7 @@ PREFERRED_PROVIDER_virtual/nativesdk-cross-binutils ?= "binutils-crosssdk-${SDK_
 # Default libc config
 PREFERRED_PROVIDER_virtual/gettext ??= "gettext"
 
-GCCVERSION ?= "15.%"
+GCCVERSION ?= "16.%"
 SDKGCCVERSION ?= "${GCCVERSION}"
 GLIBCVERSION ?= "2.43%"
 RUSTVERSION ?= "1.94.1%"
meta/recipes-devtools/gcc/gcc-16.1.inc renamed from meta/recipes-devtools/gcc/gcc-15.2.inc +6 -11
similarity index 88%
rename from meta/recipes-devtools/gcc/gcc-15.2.inc
rename to meta/recipes-devtools/gcc/gcc-16.1.inc
index a96f2b8411..3a96228631 100644
@@ -2,11 +2,11 @@ require gcc-common.inc
 
 # Third digit in PV should be incremented after a minor release
 
-PV = "15.2.0"
+PV = "16.1.0"
 
 # BINV should be incremented to a revision after a minor gcc release
 
-BINV = "15.2.0"
+BINV = "16.1.0"
 
 FILESEXTRAPATHS =. "${FILE_DIRNAME}/gcc:${FILE_DIRNAME}/gcc/backport:"
 
@@ -34,17 +34,17 @@ LIC_FILES_CHKSUM = "\
 #SRC_URI[sha256sum] = "41bf7be5dc029112a9df625266e7de030ffc36ff3638f270b180ae8c91fe6449"
 
 # from snapshot
-#RELEASE ?= "15-20250420"
-#RELEASE ?= "15.1.0-RC-20250418"
+#RELEASE ?= "16-20260502"
+#RELEASE ?= "16.1.0-RC-20260424"
 #BASEURI ?= "https://gcc.gnu.org/pub/gcc/snapshots/${RELEASE}/gcc-${RELEASE}.tar.xz"
 #SOURCEDIR ?= "gcc-${RELEASE}"
-#SRC_URI[sha256sum] = "fe18624317c6c662977eea8b5a506ec6c132fc11c7a8d53e2f6d21b139b0af3c"
+#SRC_URI[sha256sum] = "e8edc2aaf0affce7020658b0be9a3fc820aa33dc610640d3fe1ba1aee360051b"
 
 # official release
 RELEASE ?= "${PV}"
 BASEURI ?= "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.xz"
 SOURCEDIR ?= "gcc-${PV}"
-SRC_URI[sha256sum] = "438fd996826b0c82485a29da03a72d71d6e3541a83ec702df4271f6fe025d24e"
+SRC_URI[sha256sum] = "50efb4d94c3397aff3b0d61a5abd748b4dd31d9d3f2ab7be05b171d36a510f79"
 
 SRC_URI = "${BASEURI} \
            file://0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch \
@@ -72,11 +72,6 @@ SRC_URI = "${BASEURI} \
            file://0023-Fix-install-path-of-linux64.h.patch \
            file://0024-Avoid-hardcoded-build-paths-into-ppc-libgcc.patch \
            file://0025-gcc-testsuite-tweaks-for-mips-OE.patch \
-           file://0026-fix-pr90579-testcases.patch \
-           file://0027-gcc15-pr122394.patch \
-           file://0028-fix-gcc-libitm-false-postives-01.patch \
-           file://0028-fix-gcc-libitm-false-postives-02.patch \
-           file://0028-libcody-Make-it-buildable-by-C-11-to-C-26.patch \
            file://0001-mapper-localhost-might-not-be-known.patch \
 "
 
meta/recipes-devtools/gcc/gcc-cross-canadian_16.1.bb renamed from meta/recipes-devtools/gcc/gcc-cross-canadian_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/gcc-cross-canadian_15.2.bb
rename to meta/recipes-devtools/gcc/gcc-cross-canadian_16.1.bb
meta/recipes-devtools/gcc/gcc-cross_16.1.bb renamed from meta/recipes-devtools/gcc/gcc-cross_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/gcc-cross_15.2.bb
rename to meta/recipes-devtools/gcc/gcc-cross_16.1.bb
meta/recipes-devtools/gcc/gcc-crosssdk_16.1.bb renamed from meta/recipes-devtools/gcc/gcc-crosssdk_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/gcc-crosssdk_15.2.bb
rename to meta/recipes-devtools/gcc/gcc-crosssdk_16.1.bb
meta/recipes-devtools/gcc/gcc-runtime_16.1.bb renamed from meta/recipes-devtools/gcc/gcc-runtime_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/gcc-runtime_15.2.bb
rename to meta/recipes-devtools/gcc/gcc-runtime_16.1.bb
meta/recipes-devtools/gcc/gcc-sanitizers_16.1.bb renamed from meta/recipes-devtools/gcc/gcc-sanitizers_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/gcc-sanitizers_15.2.bb
rename to meta/recipes-devtools/gcc/gcc-sanitizers_16.1.bb
meta/recipes-devtools/gcc/gcc-source_16.1.bb renamed from meta/recipes-devtools/gcc/gcc-source_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/gcc-source_15.2.bb
rename to meta/recipes-devtools/gcc/gcc-source_16.1.bb
meta/recipes-devtools/gcc/gcc/0007-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch +1 -1
index 621f8bc41f..07e9e23f3d 100644
@@ -172,7 +172,7 @@ index fbc75a90ad5..38c239940bd 100644
 +  SYSTEMLIBS_DIR "ld-linux-loongarch-" ABI_SPEC ".so.1"
  
  #define MUSL_ABI_SPEC \
-   "%{mabi=lp64d:}" \
+   "%{mabi=ilp32d:}" \
 @@ -40,7 +40,7 @@ along with GCC; see the file COPYING3.  If not see
  
  #undef MUSL_DYNAMIC_LINKER
meta/recipes-devtools/gcc/gcc/0017-Search-target-sysroot-gcc-version-specific-dirs-with.patch +2 -2
index a087ba17d9..678457bbc9 100644
@@ -89,12 +89,12 @@ index 007c91780f6..22eb17bc099 100644
 +	            {
 +		      memcpy (path + len, this_multi, this_multi_len + 1);
 +	              memcpy (path + len + this_multi_len, multi_suffix, suffix_len + 1);
-+	              ret = callback (path, callback_info);
++	              ret = callback (path);
 +	                if (ret)
 +		          break;
 +	            }
 +	        }
 +
  	      memcpy (path + len, multi_suffix, suffix_len + 1);
- 	      ret = callback (path, callback_info);
+ 	      ret = callback (path);
  	      if (ret)
meta/recipes-devtools/gcc/gcc/0022-libatomic-Do-not-enforce-march-on-aarch64.patch +9 -9
index 0f2a9d8c1f..5a8a79c0d2 100644
@@ -29,14 +29,14 @@ index 0f1a7156084..255fe448e63 100644
  
  endif
 diff --git a/libatomic/Makefile.in b/libatomic/Makefile.in
-index 9798e7c09e9..3b3027eb77d 100644
+index 887ae41..b3d5e6f 100644
 --- a/libatomic/Makefile.in
 +++ b/libatomic/Makefile.in
-@@ -452,7 +452,6 @@ M_SRC = $(firstword $(filter %/$(M_FILE), $(all_c_files)))
- libatomic_la_LIBADD = $(foreach s,$(SIZES),$(addsuffix \
- 	_$(s)_.lo,$(SIZEOBJS))) $(am__append_1) $(am__append_2) \
- 	$(am__append_3) $(am__append_4)
--@ARCH_AARCH64_LINUX_TRUE@@HAVE_IFUNC_TRUE@IFUNC_OPTIONS = -march=armv8-a+lse
- @ARCH_ARM_LINUX_TRUE@@HAVE_IFUNC_TRUE@IFUNC_OPTIONS = -march=armv7-a+fp -DHAVE_KERNEL64
- @ARCH_I386_TRUE@@HAVE_IFUNC_TRUE@IFUNC_OPTIONS = -march=i586
- @ARCH_X86_64_TRUE@@HAVE_IFUNC_TRUE@IFUNC_OPTIONS = -mcx16 -mcx16
+@@ -470,7 +470,6 @@ libatomic_la_LDFLAGS = $(libatomic_version_info) $(libatomic_version_script) \
+ @PARTIAL_VXWORKS_FALSE@	_$(s)_.lo,$(SIZEOBJS))) $(am__append_1) \
+ @PARTIAL_VXWORKS_FALSE@	$(am__append_2) $(am__append_3) \
+ @PARTIAL_VXWORKS_FALSE@	$(am__append_4) $(am__append_5)
+-@ARCH_AARCH64_LINUX_TRUE@@HAVE_IFUNC_TRUE@@PARTIAL_VXWORKS_FALSE@IFUNC_OPTIONS = -march=armv8-a+lse
+ @ARCH_ARM_LINUX_TRUE@@HAVE_IFUNC_TRUE@@PARTIAL_VXWORKS_FALSE@IFUNC_OPTIONS = -march=armv7-a+fp -DHAVE_KERNEL64
+ @ARCH_I386_TRUE@@HAVE_IFUNC_TRUE@@PARTIAL_VXWORKS_FALSE@IFUNC_OPTIONS = -march=i586
+ @ARCH_LOONGARCH_TRUE@@HAVE_IFUNC_TRUE@@PARTIAL_VXWORKS_FALSE@IFUNC_OPTIONS = -mlsx|-mscq
meta/recipes-devtools/gcc/gcc/0025-gcc-testsuite-tweaks-for-mips-OE.patch +46 -32

156 lines not on this page · raw message

meta/recipes-devtools/gcc/gcc_16.1.bb renamed from meta/recipes-devtools/gcc/gcc_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/gcc_15.2.bb
rename to meta/recipes-devtools/gcc/gcc_16.1.bb
meta/recipes-devtools/gcc/libgcc-initial_16.1.bb renamed from meta/recipes-devtools/gcc/libgcc-initial_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/libgcc-initial_15.2.bb
rename to meta/recipes-devtools/gcc/libgcc-initial_16.1.bb
meta/recipes-devtools/gcc/libgcc_16.1.bb renamed from meta/recipes-devtools/gcc/libgcc_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/libgcc_15.2.bb
rename to meta/recipes-devtools/gcc/libgcc_16.1.bb
meta/recipes-devtools/gcc/libgfortran_16.1.bb renamed from meta/recipes-devtools/gcc/libgfortran_15.2.bb +0 -0
similarity index 100%
rename from meta/recipes-devtools/gcc/libgfortran_15.2.bb
rename to meta/recipes-devtools/gcc/libgfortran_16.1.bb
Signature · 1 line
2.49.0
#5 lore raw

PATCH v2 5/12 gcc-runtime: disable automatic libatomic linking during build

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

GCC 16 introduced -flink-libatomic which automatically injects -latomic_asneeded into link commands via LINK_LIBATOMIC_SPEC. During gcc-runtime do_compile, OE uses a pre-built GCC 16 cross-compiler to build target runtime libraries before libatomic itself is ready.

---
 meta/recipes-devtools/gcc/gcc-runtime.inc | 3 +++
 1 file changed, 3 insertions(+)
meta/recipes-devtools/gcc/gcc-runtime.inc +3 -0
index ef38cff58a..d975153bc2 100644
@@ -15,6 +15,9 @@ EXTRA_OECONF_PATHS = "\
     --with-build-sysroot=${STAGING_DIR_TARGET} \
 "
 
+TARGET_CC_ARCH += "-fno-link-libatomic"
+SDK_CC_ARCH += "-fno-link-libatomic"
+
 EXTRA_OECONF:append:linuxstdbase = " --enable-clocale=gnu"
 EXTRA_OECONF:append = " --cache-file=${B}/config.cache"
 EXTRA_OECONF:append:libc-newlib = " --with-newlib --with-target-subdir"
Signature · 1 line
2.49.0
#6 lore raw

PATCH v2 6/12 gcc-runtime: package new libatomic_asneeded files

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

GCC 16 generates libatomic_asneeded.so and libatomic_asneeded.a during the build as part of the fix for unnecessary DT_NEEDED entries on libatomic in GCC runtime libraries (PR libstdc++/123396). Add them to avoid unpackaged files QA errors.

---
 meta/recipes-devtools/gcc/gcc-runtime.inc | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
meta/recipes-devtools/gcc/gcc-runtime.inc +2 -1
index d975153bc2..30b2832c82 100644
@@ -268,9 +268,10 @@ SUMMARY:libatomic = "GNU C++11 atomics support library"
 FILES:libatomic-dev = "\
     ${libdir}/libatomic.so \
     ${libdir}/libatomic.la \
+    ${libdir}/libatomic_asneeded.so \
 "
 SUMMARY:libatomic-dev = "GNU C++11 atomics support library - development files"
-FILES:libatomic-staticdev = "${libdir}/libatomic.a"
+FILES:libatomic-staticdev = "${libdir}/libatomic.a ${libdir}/libatomic_asneeded.a"
 SUMMARY:libatomic-staticdev = "GNU C++11 atomics support library - static development files"
 
 FILES:libitm = "${libdir}/libitm.so.*"
Signature · 1 line
2.49.0
#7 lore raw

PATCH v2 7/12 gcc-runtime: avoid passing MULTIBUILDTOP to libatomic

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

libatomic constructs gcc_objdir using pwd and assumes MULTIBUILDTOP is relative. Passing an absolute MULTIBUILDTOP from OE results in malformed paths during libtool install operations in both compile and install stages.

Avoid passing MULTIBUILDTOP for libatomic and use the upstream default handling instead.

---
 meta/recipes-devtools/gcc/gcc-runtime.inc | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)
meta/recipes-devtools/gcc/gcc-runtime.inc +10 -2
index 30b2832c82..e305180c64 100644
@@ -83,14 +83,22 @@ do_configure[depends] += "${COMPILERDEP}"
 do_compile () {
 	for d in libgcc ${RUNTIMETARGET}; do
 		cd ${B}/${TARGET_SYS}/$d/
-		oe_runmake MULTIBUILDTOP=${B}/${TARGET_SYS}/$d/
+		if [ "$d" = "libatomic" ]; then
+			oe_runmake
+		else
+			oe_runmake MULTIBUILDTOP=${B}/${TARGET_SYS}/$d/
+		fi
 	done
 }
 
 do_install () {
 	for d in ${RUNTIMETARGET}; do
 		cd ${B}/${TARGET_SYS}/$d/
-		oe_runmake 'DESTDIR=${D}' MULTIBUILDTOP=${B}/${TARGET_SYS}/$d/ install
+		if [ "$d" = "libatomic" ]; then
+			oe_runmake 'DESTDIR=${D}' install
+		else
+			oe_runmake 'DESTDIR=${D}' MULTIBUILDTOP=${B}/${TARGET_SYS}/$d/ install
+		fi
 	done
 	install -d ${D}${datadir}/gdb/auto-load/${libdir}
 	mv ${D}${libdir}/libstdc++*-gdb.py ${D}${datadir}/gdb/auto-load/${libdir}
Signature · 1 line
2.49.0
#8 lore raw

PATCH v2 8/12 gcc/libgfortran: package libcaf libraries

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

Package libcaf static libraries installed by GCC 16 to avoid installed-vs-shipped QA errors.

---
 meta/recipes-devtools/gcc/libgfortran_16.1.bb | 1 +
 1 file changed, 1 insertion(+)
meta/recipes-devtools/gcc/libgfortran_16.1.bb +1 -0
index 71dd8b4bdc..6ad12b73d8 100644
@@ -1,3 +1,4 @@
 require recipes-devtools/gcc/gcc-${PV}.inc
 require libgfortran.inc
 
+FILES:${PN}-dev += "${libdir}/gcc/${TARGET_SYS}/${BINV}/libcaf*"
Signature · 1 line
2.49.0
#9 lore raw

PATCH v2 9/12 gn: fix build with GCC 16 on musl

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

Add missing <cstdint> include in src/gn/pool.h for int64_t.

Fixes:
| ../sources/gn-0+git/src/gn/pool.h:26:3: error: 'int64_t' does not name a type

Upstream-Status: Submitted [https://gn-review.googlesource.com/c/gn/+/22740]

---
 ...001-gn-fix-build-with-gcc-16-on-musl.patch | 31 +++++++++++++++++++
 meta/recipes-devtools/gn/gn_git.bb            |  4 ++-
 2 files changed, 34 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-devtools/gn/files/0001-gn-fix-build-with-gcc-16-on-musl.patch
meta/recipes-devtools/gn/files/0001-gn-fix-build-with-gcc-16-on-musl.patch new file +31 -0
new file mode 100644
index 0000000000..04598134e2
@@ -0,0 +1,31 @@
+From 6d22f5c9e96811f1abcedd8fb1849fe72747b5c4 Mon Sep 17 00:00:00 2001
+From: Hemanth Kumar M D <[email protected]>
+Date: Mon, 11 May 2026 02:43:10 -0700
+Subject: [PATCH] gn: fix build with GCC 16 on musl
+
+Add missing <cstdint> include in src/gn/pool.h for int64_t.
+
+Fixes:
+| ../sources/gn-0+git/src/gn/pool.h:26:3: error: 'int64_t' does not name a type
+
+Upstream-Status: Submitted [https://gn-review.googlesource.com/c/gn/+/22740]
+
+---
+ src/gn/pool.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/gn/pool.h b/src/gn/pool.h
+index e03113608..247cb6425 100644
+--- a/src/gn/pool.h
++++ b/src/gn/pool.h
+@@ -6,6 +6,7 @@
+ #define TOOLS_GN_POOL_H_
+ 
+ #include <string>
++#include <cstdint>
+ 
+ #include "gn/item.h"
+ 
+-- 
+2.49.0
+
meta/recipes-devtools/gn/gn_git.bb +3 -1
index d2f61c2098..6047ab5e2b 100644
@@ -6,7 +6,9 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=0fca02217a5d49a14dfe2d11837bb34d"
 DEPENDS += "ninja-native"
 UPSTREAM_CHECK_COMMITS = "1"
 
-SRC_URI = "git://gn.googlesource.com/gn;protocol=https;branch=main"
+SRC_URI = "git://gn.googlesource.com/gn;protocol=https;branch=main \
+           file://0001-gn-fix-build-with-gcc-16-on-musl.patch \
+"
 SRCREV = "eab8a9f92dca9b8548a89d9e5eb6aeb8ac6bba77"
 PV = "0+git"
 
Signature · 1 line
2.49.0
#10 lore raw

Patchtest results for [PATCH v2 09/12] gn: fix build with GCC 16 on musl

Thank you for your submission. Patchtest identified one or more issues with the patch. Please see the log below for more information:

---
Testing patch /home/patchtest/share/mboxes/v2-09-12-gn-fix-build-with-GCC-16-on-musl.patch

FAIL: test Signed-off-by presence: A patch file has been added without a Signed-off-by tag: '0001-gn-fix-build-with-gcc-16-on-musl.patch' (test_patch.TestPatch.test_signed_off_by_presence)

PASS: test CVE tag format (test_patch.TestPatch.test_cve_tag_format)
PASS: test Signed-off-by presence (test_mbox.TestMbox.test_signed_off_by_presence)
PASS: test Upstream-Status presence (test_patch.TestPatch.test_upstream_status_presence_format)
PASS: test author valid (test_mbox.TestMbox.test_author_valid)
PASS: test commit message presence (test_mbox.TestMbox.test_commit_message_presence)
PASS: test commit message user tags (test_mbox.TestMbox.test_commit_message_user_tags)
PASS: test mbox format (test_mbox.TestMbox.test_mbox_format)
PASS: test non-AUH upgrade (test_mbox.TestMbox.test_non_auh_upgrade)
PASS: test shortlog format (test_mbox.TestMbox.test_shortlog_format)
PASS: test shortlog length (test_mbox.TestMbox.test_shortlog_length)
PASS: test target mailing list (test_mbox.TestMbox.test_target_mailing_list)

SKIP: pretest pylint: No python related patches, skipping test (test_python_pylint.PyLint.pretest_pylint)
SKIP: test bugzilla entry format: No bug ID found (test_mbox.TestMbox.test_bugzilla_entry_format)
SKIP: test pylint: No python related patches, skipping test (test_python_pylint.PyLint.test_pylint)
SKIP: test series merge on head: Merge test is disabled for now (test_mbox.TestMbox.test_series_merge_on_head)

---

Please address the issues identified and
submit a new revision of the patch, or alternatively, reply to this email with an explanation of why the patch should be accepted. If you believe these results are due to an error in patchtest, please submit a bug at https://bugzilla.yoctoproject.org/ (use the 'Patchtest' category under 'Yocto Project Subprojects'). For more information on specific failures, see: https://wiki.yoctoproject.org/wiki/Patchtest. Thank you!

#11 lore raw

PATCH v2 10/12 elfutils: add libatomic-dev to ptest RDEPENDS

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

GCC 16 adds libatomic_asneeded.so which is referenced by the GCC spec at link time. Add libatomic-dev to ptest RDEPENDS so it is available on the target when ptests compile code, following the same pattern as libgcc-dev.

---
 meta/recipes-devtools/elfutils/elfutils_0.194.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-devtools/elfutils/elfutils_0.194.bb +1 -1
index f5dc986e1d..2173a94401 100644
@@ -46,7 +46,7 @@ PACKAGECONFIG[zstd] = "--with-zstd,--without-zstd,zstd"
 PACKAGECONFIG[libdebuginfod] = "--enable-libdebuginfod,--disable-libdebuginfod,curl json-c"
 PACKAGECONFIG[debuginfod] = "--enable-debuginfod,--disable-debuginfod,libarchive sqlite3 libmicrohttpd"
 
-RDEPENDS:${PN}-ptest += "libasm libelf bash make coreutils ${PN}-binutils iproute2-ss bsdtar gcc-symlinks binutils-symlinks libgcc-dev"
+RDEPENDS:${PN}-ptest += "libasm libelf bash make coreutils ${PN}-binutils iproute2-ss bsdtar gcc-symlinks binutils-symlinks libgcc-dev libatomic-dev"
 
 EXTRA_OECONF:append:class-target = " --disable-tests-rpath"
 
Signature · 1 line
2.49.0
#12 lore raw

PATCH v2 11/12 libc-test: add libatomic-staticdev to ptest RDEPENDS

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

GCC 16 adds libatomic_asneeded.a which is required when statically linking. The libc-test static tests fail on musl without it. Add libatomic-staticdev alongside musl-staticdev for the same reason.

---
 meta/recipes-core/musl/libc-test_git.bb | 1 +
 1 file changed, 1 insertion(+)
meta/recipes-core/musl/libc-test_git.bb +1 -0
index 9d159ea9d2..d9999ec377 100644
@@ -36,6 +36,7 @@ RDEPENDS:${PN} = " \
 
 RDEPENDS:${PN}-ptest = " \
      ${PN} \
+     libatomic-staticdev \
      locale-base-en-us \
      musl-staticdev \
      sed \
Signature · 1 line
2.49.0
#13 lore raw

PATCH v2 12/12 gcc: i386: fix ICE with -ffloat-store and SSE [PR125308]

In reply to [email protected]

From: Hemanth Kumar M D <[email protected]>

Backport upstream commit c96589414eeb0e46d9fe9cc1d562e048230b5f67 to fix an ICE on i386 seen while building piglit with GCC 16. The failure happens during the IRA pass in extract_insn() when handling UNSPEC_IEEE_MAX patterns generated with -ffloat-store and SSE enabled.

---
 meta/recipes-devtools/gcc/gcc-16.1.inc        |  1 +
 ...6-fix-ICE-with-ffloat-store-PR125308.patch | 85 +++++++++++++++++++
 2 files changed, 86 insertions(+)
 create mode 100644 meta/recipes-devtools/gcc/gcc/0026-gcc-i386-fix-ICE-with-ffloat-store-PR125308.patch
meta/recipes-devtools/gcc/gcc-16.1.inc +1 -0
index 3a96228631..4598aff045 100644
@@ -73,6 +73,7 @@ SRC_URI = "${BASEURI} \
            file://0024-Avoid-hardcoded-build-paths-into-ppc-libgcc.patch \
            file://0025-gcc-testsuite-tweaks-for-mips-OE.patch \
            file://0001-mapper-localhost-might-not-be-known.patch \
+           file://0026-gcc-i386-fix-ICE-with-ffloat-store-PR125308.patch \
 "
 
 UNPACKDIR = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/sources"
meta/recipes-devtools/gcc/gcc/0026-gcc-i386-fix-ICE-with-ffloat-store-PR125308.patch new file +85 -0

85 lines not on this page · raw message

Signature · 1 line
2.49.0
#14 lore raw

Patchtest results for [PATCH v2 12/12] gcc: i386: fix ICE with -ffloat-store and SSE [PR125308]

Thank you for your submission. Patchtest identified one or more issues with the patch. Please see the log below for more information:

---
Testing patch /home/patchtest/share/mboxes/v2-12-12-gcc-i386-fix-ICE-with--ffloat-store-and-SSE-PR125308.patch

FAIL: test Signed-off-by presence: A patch file has been added without a Signed-off-by tag: '0026-gcc-i386-fix-ICE-with-ffloat-store-PR125308.patch' (test_patch.TestPatch.test_signed_off_by_presence)

PASS: test CVE tag format (test_patch.TestPatch.test_cve_tag_format)
PASS: test Signed-off-by presence (test_mbox.TestMbox.test_signed_off_by_presence)
PASS: test Upstream-Status presence (test_patch.TestPatch.test_upstream_status_presence_format)
PASS: test author valid (test_mbox.TestMbox.test_author_valid)
PASS: test commit message presence (test_mbox.TestMbox.test_commit_message_presence)
PASS: test commit message user tags (test_mbox.TestMbox.test_commit_message_user_tags)
PASS: test mbox format (test_mbox.TestMbox.test_mbox_format)
PASS: test non-AUH upgrade (test_mbox.TestMbox.test_non_auh_upgrade)
PASS: test shortlog format (test_mbox.TestMbox.test_shortlog_format)
PASS: test shortlog length (test_mbox.TestMbox.test_shortlog_length)
PASS: test target mailing list (test_mbox.TestMbox.test_target_mailing_list)

SKIP: pretest pylint: No python related patches, skipping test (test_python_pylint.PyLint.pretest_pylint)
SKIP: test bugzilla entry format: No bug ID found (test_mbox.TestMbox.test_bugzilla_entry_format)
SKIP: test pylint: No python related patches, skipping test (test_python_pylint.PyLint.test_pylint)
SKIP: test series merge on head: Merge test is disabled for now (test_mbox.TestMbox.test_series_merge_on_head)

---

Please address the issues identified and
submit a new revision of the patch, or alternatively, reply to this email with an explanation of why the patch should be accepted. If you believe these results are due to an error in patchtest, please submit a bug at https://bugzilla.yoctoproject.org/ (use the 'Patchtest' category under 'Yocto Project Subprojects'). For more information on specific failures, see: https://wiki.yoctoproject.org/wiki/Patchtest. Thank you!