Fix build with host gcc9 / latest glibc
cover Fix build with host gcc9 / latest glibc
Build errors popped up with Fedora 30
Andreas Müller (3):
elfutils(-native): Add backported patch to fix build with host gcc9 glib-2.0: Add patch from upstream to fix build with host gcc9
cross-localedef-native: Fix build for hosts with recent glibc
Khem Raj (1):
bison: Fix build break with glibc 2.28
...11-gdbus-Avoid-printing-null-strings.patch | 77 ++++++++++++++++++ meta/recipes-core/glib-2.0/glib-2.0_2.54.3.bb | 1 + .../glibc/cross-localedef-native_2.27.bb | 1 + ...ll-_IO_fwide-if-_LIBC-is-not-defined.patch | 78 +++++++++++++++++++ .../recipes-devtools/bison/bison/gnulib.patch | 21 +++++ meta/recipes-devtools/bison/bison_3.0.4.bb | 1 + .../elfutils/elfutils_0.170.bb | 1 + ...-fsize-and-msize-with-const-attribut.patch | 42 ++++++++++ 8 files changed, 222 insertions(+) create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/0011-gdbus-Avoid-printing-null-strings.patch create mode 100644 meta/recipes-core/glibc/glibc/0032-argp-do-not-call-_IO_fwide-if-_LIBC-is-not-defined.patch create mode 100644 meta/recipes-devtools/bison/bison/gnulib.patch create mode 100644 meta/recipes-devtools/elfutils/files/0009-libelf-Mark-both-fsize-and-msize-with-const-attribut.patch
Signature · 1 line
2.21.0
PATCH 1/4 elfutils(-native): Add backported patch to fix build with host gcc9
--- .../elfutils/elfutils_0.170.bb | 1 + ...-fsize-and-msize-with-const-attribut.patch | 42 +++++++++++++++++++ 2 files changed, 43 insertions(+) create mode 100644 meta/recipes-devtools/elfutils/files/0009-libelf-Mark-both-fsize-and-msize-with-const-attribut.patch
meta/recipes-devtools/elfutils/elfutils_0.170.bb +1 -0
@@ -25,6 +25,7 @@ SRC_URI = "https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \ file://debian/0003-Add-mips-n64-relocation-format-hack.patch \ file://0001-Use-fallthrough-attribute.patch \ file://0001-Ensure-that-packed-structs-follow-the-gcc-memory-lay.patch \ + file://0009-libelf-Mark-both-fsize-and-msize-with-const-attribut.patch \ " SRC_URI_append_libc-musl = " file://0008-build-Provide-alternatives-for-glibc-assumptions-hel.patch" SRC_URI[md5sum] = "03599aee98c9b726c7a732a2dd0245d5"
meta/recipes-devtools/elfutils/files/0009-libelf-Mark-both-fsize-and-msize-with-const-attribut.patch new file +42 -0
42 lines not on this page · raw message
Signature · 1 line
2.21.0
PATCH 2/4 bison: Fix build break with glibc 2.28
In reply to Andreas MüllerFrom: Khem Raj <[email protected]>
(From OE-Core rev: 741415c58b3565764000028c26efd081212eb989)
--- .../recipes-devtools/bison/bison/gnulib.patch | 21 +++++++++++++++++++ meta/recipes-devtools/bison/bison_3.0.4.bb | 1 + 2 files changed, 22 insertions(+) create mode 100644 meta/recipes-devtools/bison/bison/gnulib.patch
meta/recipes-devtools/bison/bison/gnulib.patch new file +21 -0
@@ -0,0 +1,21 @@ +Fix gnulib issues found with glibc 2.28 libio.h removal + +see +https://lists.gnu.org/r/bug-gnulib/2018-03/msg00000.html + +Upstream-Status: Pending +Signed-off-by: Khem Raj <[email protected]> + +Index: bison-3.0.4/lib/fseterr.c +=================================================================== +--- bison-3.0.4.orig/lib/fseterr.c ++++ bison-3.0.4/lib/fseterr.c +@@ -29,7 +29,7 @@ fseterr (FILE *fp) + /* Most systems provide FILE as a struct and the necessary bitmask in + <stdio.h>, because they need it for implementing getc() and putc() as + fast macros. */ +-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ ++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ + fp->_flags |= _IO_ERR_SEEN; + #elif defined __sferror || defined __DragonFly__ /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin */ + fp_->_flags |= __SERR;
meta/recipes-devtools/bison/bison_3.0.4.bb +1 -0
@@ -14,6 +14,7 @@ SRC_URI = "${GNU_MIRROR}/bison/bison-${PV}.tar.xz \ file://dont-depend-on-help2man.patch.patch \ file://0001-src-local.mk-fix-parallel-issue.patch \ file://add-with-bisonlocaledir.patch \ + file://gnulib.patch \ " # No point in hardcoding path to m4, just use PATH
Signature · 1 line
2.21.0
PATCH 3/4 glib-2.0: Add patch from upstream to fix build with host gcc9
In reply to Andreas Müller--- ...11-gdbus-Avoid-printing-null-strings.patch | 77 +++++++++++++++++++ meta/recipes-core/glib-2.0/glib-2.0_2.54.3.bb | 1 + 2 files changed, 78 insertions(+) create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/0011-gdbus-Avoid-printing-null-strings.patch
meta/recipes-core/glib-2.0/glib-2.0/0011-gdbus-Avoid-printing-null-strings.patch new file +77 -0
@@ -0,0 +1,77 @@ +From 566e1d61a500267c7849ad0b2552feec9c9a29a6 Mon Sep 17 00:00:00 2001 +From: Ernestas Kulik <[email protected]> +Date: Tue, 29 Jan 2019 09:50:46 +0100 +Subject: [PATCH] gdbus: Avoid printing null strings +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +This mostly affects the 2.56 branch, but, given that GCC 9 is being +stricter about passing null string pointers to printf-like functions, it +might make sense to proactively fix such calls. + +gdbusauth.c: In function '_g_dbus_auth_run_server': +gdbusauth.c:1302:11: error: '%s' directive argument is null +[-Werror=format-overflow=] + 1302 | debug_print ("SERVER: WaitingForBegin, read '%s'", + line); + | + +gdbusmessage.c: In function ‘g_dbus_message_to_blob’: +gdbusmessage.c:2730:30: error: ‘%s’ directive argument is null [-Werror=format-overflow=] + 2730 | tupled_signature_str = g_strdup_printf ("(%s)", signature_str); + | + +Upstream-Status: Applied [1] + +[1] https://gitlab.gnome.org/GNOME/glib/commit/566e1d61a500267c7849ad0b2552feec9c9a29a6 + +Signed-off-by: Andreas Müller <[email protected]> +--- + gio/gdbusauth.c | 2 +- + gio/gdbusmessage.c | 5 ++--- + 2 files changed, 3 insertions(+), 4 deletions(-) + +diff --git a/gio/gdbusauth.c b/gio/gdbusauth.c +index 1f8ea8057..752ec23fc 100644 +--- a/gio/gdbusauth.c ++++ b/gio/gdbusauth.c +@@ -1272,9 +1272,9 @@ _g_dbus_auth_run_server (GDBusAuth *auth, + &line_length, + cancellable, + error); +- debug_print ("SERVER: WaitingForBegin, read '%s'", line); + if (line == NULL) + goto out; ++ debug_print ("SERVER: WaitingForBegin, read '%s'", line); + if (g_strcmp0 (line, "BEGIN") == 0) + { + /* YAY, done! */ +diff --git a/gio/gdbusmessage.c b/gio/gdbusmessage.c +index 3221b925d..3a1a1f9e9 100644 +--- a/gio/gdbusmessage.c ++++ b/gio/gdbusmessage.c +@@ -2731,7 +2731,6 @@ g_dbus_message_to_blob (GDBusMessage *message, + if (message->body != NULL) + { + gchar *tupled_signature_str; +- tupled_signature_str = g_strdup_printf ("(%s)", signature_str); + if (signature == NULL) + { + g_set_error (error, +@@ -2739,10 +2738,10 @@ g_dbus_message_to_blob (GDBusMessage *message, + G_IO_ERROR_INVALID_ARGUMENT, + _("Message body has signature “%s” but there is no signature header"), + signature_str); +- g_free (tupled_signature_str); + goto out; + } +- else if (g_strcmp0 (tupled_signature_str, g_variant_get_type_string (message->body)) != 0) ++ tupled_signature_str = g_strdup_printf ("(%s)", signature_str); ++ if (g_strcmp0 (tupled_signature_str, g_variant_get_type_string (message->body)) != 0) + { + g_set_error (error, + G_IO_ERROR, +-- +2.21.0 +
meta/recipes-core/glib-2.0/glib-2.0_2.54.3.bb +1 -0
@@ -16,6 +16,7 @@ SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \ file://0001-Do-not-ignore-return-value-of-write.patch \ file://0001-Test-for-pthread_getname_np-before-using-it.patch \ file://0010-Do-not-hardcode-python-path-into-various-tools.patch \ + file://0011-gdbus-Avoid-printing-null-strings.patch \ " SRC_URI_append_class-native = " file://relocate-modules.patch"
Signature · 1 line
2.21.0
PATCH 4/4 cross-localedef-native: Fix build for hosts with recent glibc
In reply to Andreas MüllerFixes:
| argp-help.c:(.text+0x1f51): undefined reference to `_IO_fwide' | collect2: error: ld returned 1 exit status | make: *** [Makefile:60: localedef] Error 1
--- .../glibc/cross-localedef-native_2.27.bb | 1 + ...ll-_IO_fwide-if-_LIBC-is-not-defined.patch | 78 +++++++++++++++++++ 2 files changed, 79 insertions(+) create mode 100644 meta/recipes-core/glibc/glibc/0032-argp-do-not-call-_IO_fwide-if-_LIBC-is-not-defined.patch
meta/recipes-core/glibc/cross-localedef-native_2.27.bb +1 -0
@@ -35,6 +35,7 @@ SRC_URI = "${GLIBC_GIT_URI};branch=${SRCBRANCH};name=glibc \ file://0021-eglibc-Install-PIC-archives.patch \ file://0022-eglibc-Forward-port-cross-locale-generation-support.patch \ file://0023-Define-DUMMY_LOCALE_T-if-not-defined.patch \ + file://0032-argp-do-not-call-_IO_fwide-if-_LIBC-is-not-defined.patch \ file://archive-path.patch \ " # Makes for a rather long rev (22 characters), but...
meta/recipes-core/glibc/glibc/0032-argp-do-not-call-_IO_fwide-if-_LIBC-is-not-defined.patch new file +78 -0
78 lines not on this page · raw message
Signature · 1 line
2.21.0
✗ patchtest: failure for Fix build with host gcc9 / latest glibc
In reply to Andreas Müller== Series Details ==
Series: Fix build with host gcc9 / latest glibc
Revision: 1
URL : https://patchwork.openembedded.org/series/20136/
State : failure
== Summary ==
Thank you for submitting this patch series to OpenEmbedded Core. This is an automated response. Several tests have been executed on the proposed series by patchtest resulting in the following failures:
* Issue Upstream-Status is in incorrect format [test_upstream_status_presence_format]
Suggested fix Fix Upstream-Status format in 0011-gdbus-Avoid-printing-null-strings.patch Current Upstream-Status: Applied [1] Standard format Upstream-Status: <Valid status> Valid status Pending, Accepted, Backport, Denied, Inappropriate [reason], Submitted [where]
If you believe any of these test results are incorrect, please reply to the mailing list ([email protected]) raising your concerns. Otherwise we would appreciate you correcting the issues and submitting a new version of the patchset if applicable. Please ensure you add/increment the version number when sending the new version (i.e. [PATCH] -> [PATCH v2] -> [PATCH v3] -> ...).
---
Guidelines: https://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest Test suite: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe