unzip: Fix build with GCC-15
PATCH 1/15 unzip: Fix build with GCC-15
From: Khem Raj <[email protected]>
Add a patch to remove redundant declarations
--- meta/recipes-extended/unzip/unzip/gcc15.patch | 17 +++++++++++++++++ meta/recipes-extended/unzip/unzip_6.0.bb | 1 + 2 files changed, 18 insertions(+) create mode 100644 meta/recipes-extended/unzip/unzip/gcc15.patch
meta/recipes-extended/unzip/unzip/gcc15.patch new file +17 -0
@@ -0,0 +1,17 @@ +Do not redefine gmtime(), localtime() + +They are already provided by system time.h header + +Upstream-Status: Inactive-Upstream [need a new release] + +Sign-off-by: Khem Raj <[email protected]> +--- a/unix/unxcfg.h ++++ b/unix/unxcfg.h +@@ -117,7 +117,6 @@ typedef struct stat z_stat; + # endif + #else + # include <time.h> +- struct tm *gmtime(), *localtime(); + #endif + + #if (defined(BSD4_4) || (defined(SYSV) && defined(MODERN)))
meta/recipes-extended/unzip/unzip_6.0.bb +1 -0
@@ -32,6 +32,7 @@ SRC_URI = "${SOURCEFORGE_MIRROR}/infozip/UnZip%206.x%20%28latest%29/UnZip%206.0/ file://CVE-2022-0530.patch \ file://0001-configure-Add-correct-system-headers-and-prototypes-.patch \ file://0001-unix-configure-fix-detection-for-cross-compilation.patch \ + file://gcc15.patch \ " UPSTREAM_VERSION_UNKNOWN = "1"
PATCH 2/15 m4: Stick to C17 standard
From: Khem Raj <[email protected]>
GCC15 imposes C23 by default and 1.4.19 release has gnulib version which can not be compiled without errors, while new release of m4 is in progress we might use C17 until then and use GCC15 to compile it
For scarthgap also add it in BUILD_CFLAGS.
--- meta/recipes-devtools/m4/m4-1.4.19.inc | 3 +++ 1 file changed, 3 insertions(+)
meta/recipes-devtools/m4/m4-1.4.19.inc +3 -0
@@ -30,6 +30,9 @@ EXTRA_OECONF += "--without-libsigsegv-prefix" EXTRA_OEMAKE += "'infodir=${infodir}'" +CFLAGS += "-std=gnu17" +BUILD_CFLAGS += "-std=gnu17" + do_compile_ptest() { cd ${B}/tests sed -i '/^buildtest-TESTS: /c buildtest-TESTS: $(TESTS) $(check_LIBRARIES) $(check_PROGRAMS)' Makefile
PATCH 3/15 gmp: Fix build with GCC15/C23
In reply to [email protected]From: Khem Raj <[email protected]>
--- ...n-prototype-in-acinclude.m4-for-C23-.patch | 25 +++++++++++++++++++ meta/recipes-support/gmp/gmp_6.3.0.bb | 1 + 2 files changed, 26 insertions(+) create mode 100644 meta/recipes-support/gmp/gmp/0001-Complete-function-prototype-in-acinclude.m4-for-C23-.patch
meta/recipes-support/gmp/gmp/0001-Complete-function-prototype-in-acinclude.m4-for-C23-.patch new file +25 -0
@@ -0,0 +1,25 @@ +From 51a657c827422d2bc284d752dfbcfd2b1311a5bf Mon Sep 17 00:00:00 2001 +From: Marc Glisse <[email protected]> +Date: Wed, 29 Jan 2025 22:38:02 +0100 +Subject: [PATCH] Complete function prototype in acinclude.m4 for C23 + compatibility + +Upstream-Status: Backport [https://gmplib.org/repo/gmp/rev/8e7bb4ae7a18] +Signed-off-by: Khem Raj <[email protected]> +--- + acinclude.m4 | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/acinclude.m4 b/acinclude.m4 +index 9cf9483..787511f 100644 +--- a/acinclude.m4 ++++ b/acinclude.m4 +@@ -609,7 +609,7 @@ GMP_PROG_CC_WORKS_PART([$1], [long long reliability test 1], + + #if defined (__GNUC__) && ! defined (__cplusplus) + typedef unsigned long long t1;typedef t1*t2; +-void g(){} ++void g(int,t1 const*,t1,t2,t1 const*,int){} + void h(){} + static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0) + {t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
meta/recipes-support/gmp/gmp_6.3.0.bb +1 -0
@@ -14,6 +14,7 @@ SRC_URI = "https://gmplib.org/download/${BPN}/${BP}${REVISION}.tar.bz2 \ file://use-includedir.patch \ file://0001-Append-the-user-provided-flags-to-the-auto-detected-.patch \ file://0001-confiure.ac-Believe-the-cflags-from-environment.patch \ + file://0001-Complete-function-prototype-in-acinclude.m4-for-C23-.patch \ " SRC_URI[sha256sum] = "ac28211a7cfb609bae2e2c8d6058d66c8fe96434f740cf6fe2e47b000d1c20cb"
PATCH 4/15 gmp: Fix build with older gcc versions
In reply to [email protected]From: Khem Raj <[email protected]>
The fix to make this work with GCC15/C23 caused problems with older gcc versions. Add a fix for that.
--- ...d-parameter-names-in-prototype-for-g.patch | 50 +++++++++++++++++++ meta/recipes-support/gmp/gmp_6.3.0.bb | 1 + 2 files changed, 51 insertions(+) create mode 100644 meta/recipes-support/gmp/gmp/0001-acinclude.m4-Add-parameter-names-in-prototype-for-g.patch
meta/recipes-support/gmp/gmp/0001-acinclude.m4-Add-parameter-names-in-prototype-for-g.patch new file +50 -0
@@ -0,0 +1,50 @@ +From 1744e433a16fb39a55c4c771b8ecb02246aa5b99 Mon Sep 17 00:00:00 2001 +From: Khem Raj <[email protected]> +Date: Sat, 15 Mar 2025 09:40:06 -0700 +Subject: [PATCH] acinclude.m4: Add parameter names in prototype for g(). +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +This allows it to compile with older gcc e.g. gcc-10 +which does not have allow parameter name omission, it results +in + +a.c: In function ‘g’: +a.c:3:8: error: parameter name omitted + 3 | void g(int,t1 const*,t1,t2,t1 const*,int){} + | ^~~ + +this was added to gcc via [1] thats why it is supported in +newer gcc. + +Adding the parameter names make it compatible with +old and new gcc + +[1] https://gcc.gnu.org/pipermail/gcc-cvs/2020-October/336068.html + +Upstream-Status: Submitted [https://gmplib.org/list-archives/gmp-devel/2025-March/006294.html] +Signed-off-by: Khem Raj <[email protected]> +--- +ChangeLog + +2025-03-15 Khem Raj <[email protected]> + + * acinclude.m4: Add parameter names to function prototype. + + acinclude.m4 | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/acinclude.m4 b/acinclude.m4 +index 4fca12de2..b9d1eacfe 100644 +--- a/acinclude.m4 ++++ b/acinclude.m4 +@@ -609,7 +609,7 @@ GMP_PROG_CC_WORKS_PART([$1], [long long reliability test 1], + + #if defined (__GNUC__) && ! defined (__cplusplus) + typedef unsigned long long t1;typedef t1*t2; +-void g(int,t1 const*,t1,t2,t1 const*,int){} ++void g(int a,t1 const* b,t1 c,t2 d,t1 const* e,int f){} + void h(){} + static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0) + {t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
meta/recipes-support/gmp/gmp_6.3.0.bb +1 -0
@@ -15,6 +15,7 @@ SRC_URI = "https://gmplib.org/download/${BPN}/${BP}${REVISION}.tar.bz2 \ file://0001-Append-the-user-provided-flags-to-the-auto-detected-.patch \ file://0001-confiure.ac-Believe-the-cflags-from-environment.patch \ file://0001-Complete-function-prototype-in-acinclude.m4-for-C23-.patch \ + file://0001-acinclude.m4-Add-parameter-names-in-prototype-for-g.patch \ " SRC_URI[sha256sum] = "ac28211a7cfb609bae2e2c8d6058d66c8fe96434f740cf6fe2e47b000d1c20cb"
PATCH 5/15 gdbm: Use C11 standard
In reply to [email protected]From: Khem Raj <[email protected]>
GCC15 is switching defaults to C23 and gdbm is not yet ready to compile using C23 std.
For scarthgap also add it in BUILD_CFLAGS.
--- meta/recipes-support/gdbm/gdbm_1.23.bb | 4 ++++ 1 file changed, 4 insertions(+)
meta/recipes-support/gdbm/gdbm_1.23.bb +4 -0
@@ -23,6 +23,10 @@ EXTRA_OECONF = "--enable-libgdbm-compat --without-readline" # Stop presence of dbm/nbdm on the host contaminating builds CACHED_CONFIGUREVARS += "ac_cv_lib_ndbm_main=no ac_cv_lib_dbm_main=no" +# Not yet ready for C23 +CFLAGS += "-std=gnu11" +BUILD_CFLAGS += "-std=gnu11" + BBCLASSEXTEND = "native nativesdk" do_install:append () {
PATCH 6/15 unifdef: Don't use C23 constexpr keyword
In reply to [email protected]From: Khem Raj <[email protected]>
Fixes build with GCC-15
--- ...0001-Don-t-use-C23-constexpr-keyword.patch | 57 +++++++++++++++++++ meta/recipes-devtools/unifdef/unifdef_2.12.bb | 3 +- 2 files changed, 59 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-devtools/unifdef/unifdef/0001-Don-t-use-C23-constexpr-keyword.patch
meta/recipes-devtools/unifdef/unifdef/0001-Don-t-use-C23-constexpr-keyword.patch new file +57 -0
@@ -0,0 +1,57 @@ +From ca1ac9c8bde84dbdea972299b1a6e30e78c2d785 Mon Sep 17 00:00:00 2001 +From: Sam James <[email protected]> +Date: Sun, 17 Nov 2024 01:26:27 +0000 +Subject: [PATCH] Don't use C23 constexpr keyword + +This fixes building with upcoming GCC 15 which defaults to -std=gnu23. + +Upstream-Status: Submitted [https://github.com/fanf2/unifdef/pull/19] +Signed-off-by: Khem Raj <[email protected]> +--- + unifdef.c | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/unifdef.c b/unifdef.c +index dc145a2..4bd3bda 100644 +--- a/unifdef.c ++++ b/unifdef.c +@@ -202,7 +202,7 @@ static int depth; /* current #if nesting */ + static int delcount; /* count of deleted lines */ + static unsigned blankcount; /* count of blank lines */ + static unsigned blankmax; /* maximum recent blankcount */ +-static bool constexpr; /* constant #if expression */ ++static bool is_constexpr; /* constant #if expression */ + static bool zerosyms; /* to format symdepth output */ + static bool firstsym; /* ditto */ + +@@ -1086,7 +1086,7 @@ eval_unary(const struct ops *ops, long *valp, const char **cpp) + *valp = (value[sym] != NULL); + lt = *valp ? LT_TRUE : LT_FALSE; + } +- constexpr = false; ++ is_constexpr = false; + } else if (!endsym(*cp)) { + debug("eval%d symbol", prec(ops)); + sym = findsym(&cp); +@@ -1103,7 +1103,7 @@ eval_unary(const struct ops *ops, long *valp, const char **cpp) + lt = *valp ? LT_TRUE : LT_FALSE; + cp = skipargs(cp); + } +- constexpr = false; ++ is_constexpr = false; + } else { + debug("eval%d bad expr", prec(ops)); + return (LT_ERROR); +@@ -1170,10 +1170,10 @@ ifeval(const char **cpp) + long val = 0; + + debug("eval %s", *cpp); +- constexpr = killconsts ? false : true; ++ is_constexpr = killconsts ? false : true; + ret = eval_table(eval_ops, &val, cpp); + debug("eval = %d", val); +- return (constexpr ? LT_IF : ret == LT_ERROR ? LT_IF : ret); ++ return (is_constexpr ? LT_IF : ret == LT_ERROR ? LT_IF : ret); + } + + /*
meta/recipes-devtools/unifdef/unifdef_2.12.bb +2 -1
@@ -8,7 +8,8 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=3498caf346f6b77934882101749ada23 \ file://unifdef.c;endline=32;md5=6f4ee8085d6e6ab0f7cb4390e1a9c497 \ " -SRC_URI = "http://dotat.at/prog/${BPN}/${BP}.tar.xz" +SRC_URI = "http://dotat.at/prog/${BPN}/${BP}.tar.xz \ + file://0001-Don-t-use-C23-constexpr-keyword.patch" SRC_URI[md5sum] = "ae8c0b3b4c43c1f6bc5f32412a820818" SRC_URI[sha256sum] = "43ce0f02ecdcdc723b2475575563ddb192e988c886d368260bc0a63aee3ac400"
PATCH 7/15 pkgconfig: fix build with gcc-15
In reply to [email protected]From: Martin Jansa <[email protected]>
* on hosts with gcc-15 or whenever glib PACKAGECONFIG isn't enabled and pkgconfig uses own old bundled glib
* fixes:
http://errors.yoctoproject.org/Errors/Details/853015/../../../git/glib/glib/goption.c:169:14: error: two or more data types in declaration specifiers
169 | gboolean bool;
| ^~~~../../../git/glib/glib/goption.c:169:18: warning: declaration does not declare anything
169 | gboolean bool;
| ^
--- ...0001-Do-not-use-bool-as-a-field-name.patch | 36 +++++++++++++++++++ .../pkgconfig/pkgconfig_git.bb | 1 + 2 files changed, 37 insertions(+) create mode 100644 meta/recipes-devtools/pkgconfig/pkgconfig/0001-Do-not-use-bool-as-a-field-name.patch
meta/recipes-devtools/pkgconfig/pkgconfig/0001-Do-not-use-bool-as-a-field-name.patch new file +36 -0
@@ -0,0 +1,36 @@ +From b3b26a7e125e5e4f5b69975cc17eb6d33198ebaa Mon Sep 17 00:00:00 2001 +From: Emmanuele Bassi <[email protected]> +Date: Thu, 11 Apr 2024 14:40:21 +0100 +Subject: [PATCH] Do not use bool as a field name + +C99 aliases `bool` to `_Bool`, and C23 introduces `bool` as a reserved +keyword. Let's avoid using `bool` as a field name. + +Upstream-Status: Backport [Backport from glib to bunlded version in pkg-config https://github.com/GNOME/glib/commit/9e320e1c43a4770ed1532248fe5416eb0c618120] +Signed-off-by: Martin Jansa <[email protected]> +--- + glib/glib/goption.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/glib/glib/goption.c b/glib/glib/goption.c +index 0a22f6f..f439fd4 100644 +--- a/glib/glib/goption.c ++++ b/glib/glib/goption.c +@@ -166,7 +166,7 @@ typedef struct + gpointer arg_data; + union + { +- gboolean bool; ++ gboolean boolean; + gint integer; + gchar *str; + gchar **array; +@@ -1600,7 +1600,7 @@ free_changes_list (GOptionContext *context, + switch (change->arg_type) + { + case G_OPTION_ARG_NONE: +- *(gboolean *)change->arg_data = change->prev.bool; ++ *(gboolean *)change->arg_data = change->prev.boolean; + break; + case G_OPTION_ARG_INT: + *(gint *)change->arg_data = change->prev.integer;
meta/recipes-devtools/pkgconfig/pkgconfig_git.bb +1 -0
@@ -15,6 +15,7 @@ SRC_URI = "git://gitlab.freedesktop.org/pkg-config/pkg-config.git;branch=master; file://pkg-config-esdk.in \ file://pkg-config-native.in \ file://0001-glib-gettext.m4-Update-AM_GLIB_GNU_GETTEXT-to-match-.patch \ + file://0001-Do-not-use-bool-as-a-field-name.patch \ " S = "${WORKDIR}/git"
PATCH 8/15 libgpg-error: fix build with gcc-15
In reply to [email protected]From: Martin Jansa <[email protected]>
Backport a fix for native build with gcc-15 on host
--- ...oid-use-of-nullptr-for-an-identifier.patch | 52 +++++++++++++++++++ .../libgpg-error/libgpg-error_1.48.bb | 1 + 2 files changed, 53 insertions(+) create mode 100644 meta/recipes-support/libgpg-error/libgpg-error/0001-Avoid-use-of-nullptr-for-an-identifier.patch
meta/recipes-support/libgpg-error/libgpg-error/0001-Avoid-use-of-nullptr-for-an-identifier.patch new file +52 -0
@@ -0,0 +1,52 @@ +From d14c69a7f256a9444c5c64b808d8767e5a8ba68e Mon Sep 17 00:00:00 2001 +From: NIIBE Yutaka <[email protected]> +Date: Wed, 23 Oct 2024 08:48:06 +0900 +Subject: [PATCH] Avoid use of 'nullptr' for an identifier. + +* tests/t-printf.c (check_fprintf_sf): Use 'null_ptr' +as an identifier. + +-- + +GnuPG-bug-id: 7344 +Signed-off-by: NIIBE Yutaka <[email protected]> + +Upstream-Status: Backport [libgpg-error-1.51 d14c69a7f256a9444c5c64b808d8767e5a8ba68e] +Signed-off-by: Martin Jansa <[email protected]> +--- + tests/t-printf.c | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/tests/t-printf.c b/tests/t-printf.c +index c1ad0b0..87c201d 100644 +--- a/tests/t-printf.c ++++ b/tests/t-printf.c +@@ -449,7 +449,7 @@ string_filter (const char *string, int no, void *opaque) + static void + check_fprintf_sf (void) + { +- volatile char *nullptr = NULL; /* Avoid compiler warning. */ ++ volatile char *null_ptr = NULL; /* Avoid compiler warning. */ + struct sfstate_s sfstate = {NULL}; + gpgrt_stream_t stream; + const char *expect; +@@ -461,8 +461,8 @@ check_fprintf_sf (void) + + gpgrt_fprintf_sf (stream, string_filter, &sfstate, + "%s a=%d b=%s c=%d d=%.8s null=%s\n", +- nullptr, 1, "foo\x01 bar", 2, +- "a longer string", nullptr); ++ null_ptr, 1, "foo\x01 bar", 2, ++ "a longer string", null_ptr); + expect = "[==>Niente<==] a=1 b=foo\x01 bar c=2 d=a longer null=(null)\n"; + result = stream_to_string (stream); + if (strcmp (result, expect)) +@@ -475,7 +475,7 @@ check_fprintf_sf (void) + + gpgrt_fprintf_sf (stream, string_filter, &sfstate, + "a=%d b=%s c=%d d=%.8s e=%s\n", +- 1, "foo\n bar", 2, nullptr, ""); ++ 1, "foo\n bar", 2, null_ptr, ""); + expect = "a=1 b=foo\n bar c=2 d=[==>Nien e=\n"; + result = stream_to_string (stream); + if (strcmp (result, expect))
meta/recipes-support/libgpg-error/libgpg-error_1.48.bb +1 -0
@@ -17,6 +17,7 @@ UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html" SRC_URI = "${GNUPG_MIRROR}/libgpg-error/libgpg-error-${PV}.tar.bz2 \ file://pkgconfig.patch \ file://0001-Do-not-fail-when-testing-config-scripts.patch \ + file://0001-Avoid-use-of-nullptr-for-an-identifier.patch \ file://run-ptest \ "
PATCH 9/15 rust-llvm: fix build with gcc-15
In reply to [email protected]From: Martin Jansa <[email protected]>
As in meta-clang for clang-native:
https://github.com/kraj/meta-clang/commit/f915bbfc71f7b58c38607b8407718bd8b5cefa44
--- ...36-Add-cstdint-to-SmallVector-101761.patch | 28 ++++++++++++++++ ...cstdint-in-AMDGPUMCTargetDesc-101766.patch | 23 +++++++++++++ ...-include-to-X86MCTargetDesc.h-123320.patch | 32 +++++++++++++++++++ .../recipes-devtools/rust/rust-llvm_1.75.0.bb | 8 +++-- 4 files changed, 89 insertions(+), 2 deletions(-) create mode 100644 meta/recipes-devtools/rust/rust-llvm/0036-Add-cstdint-to-SmallVector-101761.patch create mode 100644 meta/recipes-devtools/rust/rust-llvm/0037-Include-cstdint-in-AMDGPUMCTargetDesc-101766.patch create mode 100644 meta/recipes-devtools/rust/rust-llvm/0038-Add-missing-include-to-X86MCTargetDesc.h-123320.patch
meta/recipes-devtools/rust/rust-llvm/0036-Add-cstdint-to-SmallVector-101761.patch new file +28 -0
@@ -0,0 +1,28 @@ +From 9c9071480edd4093b28a9e9a9980c2426d27344c Mon Sep 17 00:00:00 2001 +From: Sam James <[email protected]> +Date: Fri, 2 Aug 2024 23:07:21 +0100 +Subject: [PATCH] Add `<cstdint>` to SmallVector (#101761) + +SmallVector uses `uint32_t`, `uint64_t` without including `<cstdint>` +which fails to build w/ GCC 15 after a change in libstdc++ [0] + +[0] https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=3a817a4a5a6d94da9127af3be9f84a74e3076ee2 + +Upstream-Status: Backport [https://github.com/llvm/llvm-project/commit/7e44305041d96b064c197216b931ae3917a34ac1] +Signed-off-by: Martin Jansa <[email protected]> +--- + llvm/include/llvm/ADT/SmallVector.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/llvm/include/llvm/ADT/SmallVector.h b/llvm/include/llvm/ADT/SmallVector.h +index 09676d792..17444147b 100644 +--- a/llvm/include/llvm/ADT/SmallVector.h ++++ b/llvm/include/llvm/ADT/SmallVector.h +@@ -19,6 +19,7 @@ + #include <algorithm> + #include <cassert> + #include <cstddef> ++#include <cstdint> + #include <cstdlib> + #include <cstring> + #include <functional>
meta/recipes-devtools/rust/rust-llvm/0037-Include-cstdint-in-AMDGPUMCTargetDesc-101766.patch new file +23 -0
@@ -0,0 +1,23 @@ +From 422390b31680305ce6babcfbf65579b7dbe090a5 Mon Sep 17 00:00:00 2001 +From: Sam James <[email protected]> +Date: Sat, 3 Aug 2024 06:36:43 +0100 +Subject: [PATCH] Include `<cstdint>` in AMDGPUMCTargetDesc (#101766) + +Upstream-Status: Backport [https://github.com/llvm/llvm-project/commit/8f39502b85d34998752193e85f36c408d3c99248] +Signed-off-by: Martin Jansa <[email protected]> +--- + llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.h b/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.h +index 3ef00f757..879dbe1b2 100644 +--- a/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.h ++++ b/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.h +@@ -15,6 +15,7 @@ + #ifndef LLVM_LIB_TARGET_AMDGPU_MCTARGETDESC_AMDGPUMCTARGETDESC_H + #define LLVM_LIB_TARGET_AMDGPU_MCTARGETDESC_AMDGPUMCTARGETDESC_H + ++#include <cstdint> + #include <memory> + + namespace llvm {
meta/recipes-devtools/rust/rust-llvm/0038-Add-missing-include-to-X86MCTargetDesc.h-123320.patch new file +32 -0
@@ -0,0 +1,32 @@ +From 72dc74c42eb9d9940b36c6804a4e4ac757370324 Mon Sep 17 00:00:00 2001 +From: Stephan Hageboeck <[email protected]> +Date: Mon, 20 Jan 2025 17:52:47 +0100 +Subject: [PATCH] Add missing include to X86MCTargetDesc.h (#123320) + +In gcc-15, explicit includes of `<cstdint>` are required when fixed-size +integers are used. In this file, this include only happened as a side +effect of including SmallVector.h + +Although llvm compiles fine, the root-project would benefit from +explicitly including it here, so we can backport the patch. + +Maybe interesting for @hahnjo and @vgvassilev + +Upstream-Status: Backport [https://github.com/llvm/llvm-project/commit/7abf44069aec61eee147ca67a6333fc34583b524] +Signed-off-by: Martin Jansa <[email protected]> +--- + llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h b/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h +index 437a7bd6f..fd7d79484 100644 +--- a/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h ++++ b/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h +@@ -13,6 +13,7 @@ + #ifndef LLVM_LIB_TARGET_X86_MCTARGETDESC_X86MCTARGETDESC_H + #define LLVM_LIB_TARGET_X86_MCTARGETDESC_X86MCTARGETDESC_H + ++#include <cstdint> + #include <memory> + #include <string> +
meta/recipes-devtools/rust/rust-llvm_1.75.0.bb +6 -2
@@ -10,8 +10,12 @@ require rust-source.inc SRC_URI += "file://0002-llvm-allow-env-override-of-exe-path.patch;striplevel=2 \ file://0001-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch;striplevel=2 \ - file://0003-llvm-fix-include-benchmarks.patch;striplevel=2 \ - file://0004-llvm-Fix-CVE-2024-0151.patch;striplevel=2" + file://0003-llvm-fix-include-benchmarks.patch;striplevel=2 \ + file://0004-llvm-Fix-CVE-2024-0151.patch;striplevel=2 \ + file://0036-Add-cstdint-to-SmallVector-101761.patch;striplevel=2 \ + file://0037-Include-cstdint-in-AMDGPUMCTargetDesc-101766.patch;striplevel=2 \ + file://0038-Add-missing-include-to-X86MCTargetDesc.h-123320.patch;striplevel=2 \ +" S = "${RUSTSRC}/src/llvm-project/llvm"
PATCH 10/15 libtirpc: Fix build with gcc-15/C23
In reply to [email protected]From: Khem Raj <[email protected]>
Update declarations to allow building with gcc-15 with C23 std being default now.
Fixes:
error: conflicting types for 'xdr_opaque_auth
--- ...rations-to-allow-compile-with-gcc-15.patch | 64 +++++++++++++++++++ ...d-key_call-declarations-to-allow-com.patch | 60 +++++++++++++++++ .../libtirpc/libtirpc_1.3.4.bb | 2 + 3 files changed, 126 insertions(+) create mode 100644 meta/recipes-extended/libtirpc/libtirpc/0001-Update-declarations-to-allow-compile-with-gcc-15.patch create mode 100644 meta/recipes-extended/libtirpc/libtirpc/0002-update-signal-and-key_call-declarations-to-allow-com.patch
meta/recipes-extended/libtirpc/libtirpc/0001-Update-declarations-to-allow-compile-with-gcc-15.patch new file +64 -0
@@ -0,0 +1,64 @@ +From b526c0a90953f47d4cbf7ef01e9ac13e9e76904a Mon Sep 17 00:00:00 2001 +From: Rudi Heitbaum <[email protected]> +Date: Thu, 12 Dec 2024 04:16:02 -0500 +Subject: [PATCH 1/2] Update declarations to allow compile with gcc-15 + +This patch fixes some of the compile errors with gcc 15-20241117. + +In addition the follow declarations need to be fixed: + sed -n 75,77p libtirpc-1.3.6/src/key_call.c + cryptkeyres *(*__key_encryptsession_pk_LOCAL)() = 0; + cryptkeyres *(*__key_decryptsession_pk_LOCAL)() = 0; + des_block *(*__key_gendes_LOCAL)() = 0; + +Upstream-Status: Backport [https://git.linux-nfs.org/?p=steved/libtirpc.git;a=commit;h=d473f1e1f6ba80bfaee4daa058da159305167323] +Signed-off-by: Rudi Heitbaum <[email protected]> +Signed-off-by: Steve Dickson <[email protected]> +Signed-off-by: Khem Raj <[email protected]> +--- + src/auth_none.c | 2 +- + src/getpublickey.c | 2 +- + src/svc_auth_none.c | 4 ++-- + 3 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/src/auth_none.c b/src/auth_none.c +index 0b0bbd1..aca6e71 100644 +--- a/src/auth_none.c ++++ b/src/auth_none.c +@@ -62,7 +62,7 @@ static bool_t authnone_validate (AUTH *, struct opaque_auth *); + static bool_t authnone_refresh (AUTH *, void *); + static void authnone_destroy (AUTH *); + +-extern bool_t xdr_opaque_auth(); ++extern bool_t xdr_opaque_auth(XDR *, struct opaque_auth *); + + static struct auth_ops *authnone_ops(); + +diff --git a/src/getpublickey.c b/src/getpublickey.c +index be37a24..4e96c7c 100644 +--- a/src/getpublickey.c ++++ b/src/getpublickey.c +@@ -52,7 +52,7 @@ + /* + * Hack to let ypserv/rpc.nisd use AUTH_DES. + */ +-int (*__getpublickey_LOCAL)() = 0; ++int (*__getpublickey_LOCAL)(const char *, char *) = 0; + + /* + * Get somebody's public key +diff --git a/src/svc_auth_none.c b/src/svc_auth_none.c +index 887e809..5ca98e9 100644 +--- a/src/svc_auth_none.c ++++ b/src/svc_auth_none.c +@@ -37,8 +37,8 @@ + + #include <rpc/rpc.h> + +-static bool_t svcauth_none_destroy(); +-static bool_t svcauth_none_wrap(); ++static bool_t svcauth_none_destroy(SVCAUTH *); ++static bool_t svcauth_none_wrap(SVCAUTH *, XDR *, bool_t (*)(XDR *, ...), char *); + + struct svc_auth_ops svc_auth_none_ops = { + svcauth_none_wrap,
meta/recipes-extended/libtirpc/libtirpc/0002-update-signal-and-key_call-declarations-to-allow-com.patch new file +60 -0
60 lines not on this page · raw message
meta/recipes-extended/libtirpc/libtirpc_1.3.4.bb +2 -0
@@ -11,6 +11,8 @@ PROVIDES = "virtual/librpc" SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.bz2 \ file://ipv6.patch \ + file://0001-Update-declarations-to-allow-compile-with-gcc-15.patch \ + file://0002-update-signal-and-key_call-declarations-to-allow-com.patch \ " UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/libtirpc/files/libtirpc/" UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)/"
PATCH 11/15 elfutils: fix build with gcc-15
In reply to [email protected]From: Martin Jansa <[email protected]>
--- .../elfutils/elfutils_0.191.bb | 1 + .../files/0007-Fix-build-with-gcc-15.patch | 72 +++++++++++++++++++ 2 files changed, 73 insertions(+) create mode 100644 meta/recipes-devtools/elfutils/files/0007-Fix-build-with-gcc-15.patch
meta/recipes-devtools/elfutils/elfutils_0.191.bb +1 -0
@@ -27,6 +27,7 @@ SRC_URI = "https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \ file://CVE-2025-1365.patch \ file://CVE-2025-1372.patch \ file://CVE-2025-1371.patch \ + file://0007-Fix-build-with-gcc-15.patch \ " SRC_URI:append:libc-musl = " \ file://0003-musl-utils.patch \
meta/recipes-devtools/elfutils/files/0007-Fix-build-with-gcc-15.patch new file +72 -0
72 lines not on this page · raw message
PATCH 12/15 binutils: fix build with gcc-15
In reply to [email protected]From: Martin Jansa <[email protected]>
--- .../binutils/binutils-2.42.inc | 4 + ...nu23-compatibility-wrt-static_assert.patch | 89 ++ ...ngs-when-building-gprofng-with-Clang.patch | 767 ++++++++++++++++++ ...gnu23-compatibility-wrt-unprototyped.patch | 606 ++++++++++++++ ...021-gprofng-fix-build-with-std-gnu23.patch | 196 +++++ 5 files changed, 1662 insertions(+) create mode 100644 meta/recipes-devtools/binutils/binutils/0018-opcodes-fix-std-gnu23-compatibility-wrt-static_assert.patch create mode 100644 meta/recipes-devtools/binutils/binutils/0019-Fix-32097-Warnings-when-building-gprofng-with-Clang.patch create mode 100644 meta/recipes-devtools/binutils/binutils/0020-gprofng-fix-std-gnu23-compatibility-wrt-unprototyped.patch create mode 100644 meta/recipes-devtools/binutils/binutils/0021-gprofng-fix-build-with-std-gnu23.patch
meta/recipes-devtools/binutils/binutils-2.42.inc +4 -0
@@ -39,6 +39,10 @@ SRC_URI = "\ file://0015-gprofng-change-use-of-bignum-to-bigint.patch \ file://0016-CVE-2024-53589.patch \ file://0017-dlltool-file-name-too-long.patch \ + file://0018-opcodes-fix-std-gnu23-compatibility-wrt-static_assert.patch \ + file://0019-Fix-32097-Warnings-when-building-gprofng-with-Clang.patch \ + file://0020-gprofng-fix-std-gnu23-compatibility-wrt-unprototyped.patch \ + file://0021-gprofng-fix-build-with-std-gnu23.patch \ file://0018-CVE-2025-0840.patch \ file://CVE-2025-1176.patch \ file://CVE-2025-1178.patch \
meta/recipes-devtools/binutils/binutils/0018-opcodes-fix-std-gnu23-compatibility-wrt-static_assert.patch new file +89 -0
89 lines not on this page · raw message
meta/recipes-devtools/binutils/binutils/0019-Fix-32097-Warnings-when-building-gprofng-with-Clang.patch new file +767 -0
767 lines not on this page · raw message
meta/recipes-devtools/binutils/binutils/0020-gprofng-fix-std-gnu23-compatibility-wrt-unprototyped.patch new file +606 -0
606 lines not on this page · raw message
meta/recipes-devtools/binutils/binutils/0021-gprofng-fix-build-with-std-gnu23.patch new file +196 -0
196 lines not on this page · raw message
PATCH 13/15 dbus-glib: fix build with gcc-15
In reply to [email protected]From: Martin Jansa <[email protected]>
--- .../dbus-glib/fix-build-with-gcc-15.patch | 37 +++++++++++++++++++ meta/recipes-core/dbus/dbus-glib_0.112.bb | 1 + 2 files changed, 38 insertions(+) create mode 100644 meta/recipes-core/dbus/dbus-glib/fix-build-with-gcc-15.patch
meta/recipes-core/dbus/dbus-glib/fix-build-with-gcc-15.patch new file +37 -0
@@ -0,0 +1,37 @@ +From 8c32bc9fa67513f46199bc31498dc1fecbb611bb Mon Sep 17 00:00:00 2001 +From: Simon McVittie <[email protected]> +Date: Thu, 13 Mar 2025 14:19:28 +0000 +Subject: [PATCH] dbus-gvalue: Avoid using the reserved word 'bool' + +This is reserved in C23 for the equivalent of `<stdbool.h>`. + +Bug-Debian: https://bugs.debian.org/1096507 +Signed-off-by: Simon McVittie <[email protected]> +Upstream-Status: Backport [https://gitlab.freedesktop.org/dbus/dbus-glib/-/commit/8c32bc9fa67513f46199bc31498dc1fecbb611bb] +igned-off-by: Martin Jansa <[email protected]> +--- + dbus/dbus-gvalue.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/dbus/dbus-gvalue.c b/dbus/dbus-gvalue.c +index 534e90a..788e360 100644 +--- a/dbus/dbus-gvalue.c ++++ b/dbus/dbus-gvalue.c +@@ -545,11 +545,11 @@ demarshal_basic (DBusGValueMarshalCtx *context, + { + case DBUS_TYPE_BOOLEAN: + { +- dbus_bool_t bool; ++ dbus_bool_t b; + if (!G_VALUE_HOLDS (value, G_TYPE_BOOLEAN)) + goto invalid_type; +- dbus_message_iter_get_basic (iter, &bool); +- g_value_set_boolean (value, bool); ++ dbus_message_iter_get_basic (iter, &b); ++ g_value_set_boolean (value, b); + return TRUE; + } + case DBUS_TYPE_BYTE: +-- +GitLab +
meta/recipes-core/dbus/dbus-glib_0.112.bb +1 -0
@@ -13,6 +13,7 @@ DEPENDS:class-native = "glib-2.0-native dbus-native" SRC_URI = "https://dbus.freedesktop.org/releases/dbus-glib/dbus-glib-${PV}.tar.gz \ file://no-examples.patch \ file://test-install-makefile.patch \ + file://fix-build-with-gcc-15.patch \ " SRC_URI[md5sum] = "021e6c8a288df02c227e4aafbf7e7527" SRC_URI[sha256sum] = "7d550dccdfcd286e33895501829ed971eeb65c614e73aadb4a08aeef719b143a"
PATCH 14/15 yocto-uninative: Update to 4.8 for GCC 15.1
In reply to [email protected]From: Michael Halstead <[email protected]>
--- meta/conf/distro/include/yocto-uninative.inc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
meta/conf/distro/include/yocto-uninative.inc +4 -4
@@ -7,9 +7,9 @@ # UNINATIVE_MAXGLIBCVERSION = "2.41" -UNINATIVE_VERSION = "4.7" +UNINATIVE_VERSION = "4.8" UNINATIVE_URL ?= "http://downloads.yoctoproject.org/releases/uninative/${UNINATIVE_VERSION}/" -UNINATIVE_CHECKSUM[aarch64] ?= "ac440e4fc80665c79f9718c665c6e28d771e51609c088c3c97ba3ad5cfed197a" -UNINATIVE_CHECKSUM[i686] ?= "c5efa31450f3bbd63ea961d4e7c747ae41317937d429f65e1d5cf2050338e27a" -UNINATIVE_CHECKSUM[x86_64] ?= "5800d4e9a129d1be09cf548918d25f74e91a7c1193ae5239d5b0c9246c486d2c" +UNINATIVE_CHECKSUM[aarch64] ?= "0d75ae3cc6e8245be40f55d48612285248ad331896ca3f4c772ed2fb34239fcf" +UNINATIVE_CHECKSUM[i686] ?= "2cbfd7ad3e1362538764999dd4962eb2511211867ae17a327b65631f64f38e31" +UNINATIVE_CHECKSUM[x86_64] ?= "6d5e28258176c52b9eecf882d4553033fa700902e60ba80d4b7ce0edacbe41d6"
PATCH 15/15 yocto-uninative: Update to 4.9 for glibc 2.42
In reply to [email protected]From: Michael Halstead <[email protected]>
--- meta/conf/distro/include/yocto-uninative.inc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
meta/conf/distro/include/yocto-uninative.inc +5 -5
@@ -6,10 +6,10 @@ # to the distro running on the build machine. # -UNINATIVE_MAXGLIBCVERSION = "2.41" -UNINATIVE_VERSION = "4.8" +UNINATIVE_MAXGLIBCVERSION = "2.42" +UNINATIVE_VERSION = "4.9" UNINATIVE_URL ?= "http://downloads.yoctoproject.org/releases/uninative/${UNINATIVE_VERSION}/" -UNINATIVE_CHECKSUM[aarch64] ?= "0d75ae3cc6e8245be40f55d48612285248ad331896ca3f4c772ed2fb34239fcf" -UNINATIVE_CHECKSUM[i686] ?= "2cbfd7ad3e1362538764999dd4962eb2511211867ae17a327b65631f64f38e31" -UNINATIVE_CHECKSUM[x86_64] ?= "6d5e28258176c52b9eecf882d4553033fa700902e60ba80d4b7ce0edacbe41d6" +UNINATIVE_CHECKSUM[aarch64] ?= "812045d826b7fda88944055e8526b95a5a9440bfef608d5b53fd52faab49bf85" +UNINATIVE_CHECKSUM[i686] ?= "5cc28efd0c15a75de4bcb147c6cce65f1c1c9d442173a220f08427f40a3ffa09" +UNINATIVE_CHECKSUM[x86_64] ?= "4c03d1ed2b7b4e823aca4a1a23d8f2e322f1770fc10e859adcede5777aff4f3a"
Patchtest results for [scarthgap][PATCH 01/15] unzip: Fix build with GCC-15
In reply to [email protected]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/scarthgap-01-15-unzip-Fix-build-with-GCC-15.patch
FAIL: test Signed-off-by presence: A patch file has been added without a Signed-off-by tag: 'gcc15.patch' (test_patch.TestPatch.test_signed_off_by_presence)
PASS: pretest src uri left files (test_metadata.TestMetadata.pretest_src_uri_left_files)
PASS: test CVE check ignore (test_metadata.TestMetadata.test_cve_check_ignore)
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 lic files chksum modified not mentioned (test_metadata.TestMetadata.test_lic_files_chksum_modified_not_mentioned)
PASS: test max line length (test_metadata.TestMetadata.test_max_line_length)
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 src uri left files (test_metadata.TestMetadata.test_src_uri_left_files)
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 lic files chksum presence: No added recipes, skipping test (test_metadata.TestMetadata.test_lic_files_chksum_presence)
SKIP: test license presence: No added recipes, skipping test (test_metadata.TestMetadata.test_license_presence)
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)
SKIP: test summary presence: No added recipes, skipping test (test_metadata.TestMetadata.test_summary_presence)
---
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!