Skip to contentSkip to conversation

Fixes for gcc-6 (Fedora-24)

PATCH In review Tim Orling 5 participants 17 messages Jul 15, 2016

lore
Share & tools
lore

Tim Orling

author
#0 lore raw

cover Fixes for gcc-6 (Fedora-24)

[YOCTO #9897]

Fedora-24 only has gcc-6.1.1.

This has caused a number of failures in -native recipes and gcc-cross.

This series either cherry-picks commits from master or applies known good patches from upstream.

Fixes broken build for:
- pkgconfig-native
- elfutils-native
- rpm-native
- binutils-native
- glib-2.0-native
- docbook-utils-native (actually openjade-native was the culprit)
- gcc-cross (gcc-cross-arm build tested for beaglebone)

Other problems may be lurking and only a world build on Fedora-24 AB will tell for sure.

The following changes since commit 98c57bb512ea6790db8604fcf0b88c81651d2ab4:

build-appliance-image: Update to krogoth head revision (2016-07-06 17:28:04 +0100)

are available in the git repository at:

git://git.yoctoproject.org/poky-contrib timo/krogoth-9897
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=timo/krogoth-9897

Dan McGregor (1):
binutils: disable werror on native build

Daniel McGregor (1):
openjade-native: work around bug exposed by GCC 6

Khem Raj (3):
elfutils-0.148: Fix build with gcc6
rpm: Fix build with gcc6
glib-2.0: Ignore useless warning found with gcc-6

Tim Orling (3):
pkgconfig: Fix build with gcc-6
elfutils: Fix build for gcc-6
gcc-5.3: fix build for gcc-6

 .../0001-Do-not-ignore-return-value-of-write.patch |  42 +++
 .../glib-2.0/0002-tests-Ignore-y2k-warnings.patch  |  42 +++
 .../ignore-format-nonliteral-warning.patch         |  39 ++
 meta/recipes-core/glib-2.0/glib-2.0_2.46.2.bb      |   7 +-
 meta/recipes-devtools/binutils/binutils_2.26.bb    |   3 +-
 .../elfutils/elfutils-0.148/gcc6.patch             |  23 ++
 ...missing-brackets-around-if-statement-body.patch | 419 +++++++++++++++++++++
 meta/recipes-devtools/elfutils/elfutils_0.148.bb   |   1 +
 meta/recipes-devtools/elfutils/elfutils_0.164.bb   |   1 +
 meta/recipes-devtools/gcc/gcc-5.3.inc              |   1 +
 .../gcc-5.3/0060-fix-build-when-using-gcc6.patch   | 157 ++++++++
 .../openjade/openjade-native_1.3.2.bb              |   1 +
 ...te-suppress-string-format-literal-warning.patch |  34 ++
 meta/recipes-devtools/pkgconfig/pkgconfig_git.bb   |   1 +
 meta/recipes-devtools/rpm/rpm/gcc6-stdlib.patch    |  54 +++
 meta/recipes-devtools/rpm/rpm_5.4.16.bb            |   3 +-
 16 files changed, 824 insertions(+), 4 deletions(-)
 create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/0001-Do-not-ignore-return-value-of-write.patch
 create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/0002-tests-Ignore-y2k-warnings.patch
 create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/ignore-format-nonliteral-warning.patch
 create mode 100644 meta/recipes-devtools/elfutils/elfutils-0.148/gcc6.patch
 create mode 100644 meta/recipes-devtools/elfutils/elfutils-0.164/libebl-Fix-missing-brackets-around-if-statement-body.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-5.3/0060-fix-build-when-using-gcc6.patch
 create mode 100644 meta/recipes-devtools/pkgconfig/pkgconfig/0001-gdate-suppress-string-format-literal-warning.patch
 create mode 100644 meta/recipes-devtools/rpm/rpm/gcc6-stdlib.patch
Signature · 1 line
2.7.4
author
#1 lore raw

PATCH 1/8 pkgconfig: Fix build with gcc-6

Our patch in master was on top of 0.29.1 update.
commit b83a808fcbd3e7aec3b0757c7180cf83dac44e92

Apply to krogoth stable 0.29 version instead.

[YOCTO #9897] (Fedora-24)

---
 ...te-suppress-string-format-literal-warning.patch | 34 ++++++++++++++++++++++
 meta/recipes-devtools/pkgconfig/pkgconfig_git.bb   |  1 +
 2 files changed, 35 insertions(+)
 create mode 100644 meta/recipes-devtools/pkgconfig/pkgconfig/0001-gdate-suppress-string-format-literal-warning.patch
meta/recipes-devtools/pkgconfig/pkgconfig/0001-gdate-suppress-string-format-literal-warning.patch new file +34 -0
new file mode 100644
index 0000000..830d3d2
@@ -0,0 +1,34 @@
+The upstream patch would not apply cleanly, so perform the same changes.
+
+Original patch header:
+From 00148329967adb196138372771052a3f606a6ea3 Mon Sep 17 00:00:00 2001
+From: coypu <[email protected]>
+Date: Wed, 2 Mar 2016 19:43:10 +0200
+Subject: [PATCH 2/2] gdate: Suppress string format literal warning
+
+Newer versions of GCC emit an error here, but we know it's safe.
+https://bugzilla.gnome.org/761550
+
+Upstream-Status: Backport
+
+Signed-off-by: Tim Orling <[email protected]>
+
+Index: git/glib/glib/gdate.c
+===================================================================
+--- git.orig/glib/glib/gdate.c
++++ git/glib/glib/gdate.c
+@@ -2439,6 +2439,8 @@ win32_strftime_helper (const GDate     *
+  *
+  * Returns: number of characters written to the buffer, or 0 the buffer was too small
+  */
++#pragma GCC diagnostic push
++#pragma GCC diagnostic ignored "-Wformat-nonliteral"
+ gsize     
+ g_date_strftime (gchar       *s, 
+                  gsize        slen, 
+@@ -2549,3 +2551,5 @@ g_date_strftime (gchar       *s,
+   return retval;
+ #endif
+ }
++
++#pragma GCC diagnostic pop
meta/recipes-devtools/pkgconfig/pkgconfig_git.bb +1 -0
index d34f608..cd4dc8e 100644
@@ -18,6 +18,7 @@ PV = "0.29+git${SRCPV}"
 SRC_URI = "git://anongit.freedesktop.org/pkg-config \
            file://pkg-config-native.in \
            file://fix-glib-configure-libtool-usage.patch \
+	   file://0001-gdate-suppress-string-format-literal-warning.patch \
            "
 
 S = "${WORKDIR}/git"
Signature · 1 line
2.7.4
#2 lore raw

Re: [krogoth][PATCH 1/8] pkgconfig: Fix build with gcc-6

So this is the host gcc not the one in OE?

- armin

Quoted 67 lines · Tim Orling

Our patch in master was on top of 0.29.1 update.
commit b83a808fcbd3e7aec3b0757c7180cf83dac44e92

Apply to krogoth stable 0.29 version instead.

[YOCTO #9897] (Fedora-24)

---
 ...te-suppress-string-format-literal-warning.patch | 34 ++++++++++++++++++++++
 meta/recipes-devtools/pkgconfig/pkgconfig_git.bb   |  1 +
 2 files changed, 35 insertions(+)
 create mode 100644 meta/recipes-devtools/pkgconfig/pkgconfig/0001-gdate-suppress-string-format-literal-warning.patch
meta/recipes-devtools/pkgconfig/pkgconfig/0001-gdate-suppress-string-format-literal-warning.patch new file +34 -0
new file mode 100644
index 0000000..830d3d2
@@ -0,0 +1,34 @@
+The upstream patch would not apply cleanly, so perform the same changes.
+
+Original patch header:
+From 00148329967adb196138372771052a3f606a6ea3 Mon Sep 17 00:00:00 2001
+From: coypu <[email protected]>
+Date: Wed, 2 Mar 2016 19:43:10 +0200
+Subject: [PATCH 2/2] gdate: Suppress string format literal warning
+
+Newer versions of GCC emit an error here, but we know it's safe.
+https://bugzilla.gnome.org/761550
+
+Upstream-Status: Backport
+
+Signed-off-by: Tim Orling <[email protected]>
+
+Index: git/glib/glib/gdate.c
+===================================================================
+--- git.orig/glib/glib/gdate.c
++++ git/glib/glib/gdate.c
+@@ -2439,6 +2439,8 @@ win32_strftime_helper (const GDate     *
+  *
+  * Returns: number of characters written to the buffer, or 0 the buffer was too small
+  */
++#pragma GCC diagnostic push
++#pragma GCC diagnostic ignored "-Wformat-nonliteral"
+ gsize     
+ g_date_strftime (gchar       *s, 
+                  gsize        slen, 
+@@ -2549,3 +2551,5 @@ g_date_strftime (gchar       *s,
+   return retval;
+ #endif
+ }
++
++#pragma GCC diagnostic pop
meta/recipes-devtools/pkgconfig/pkgconfig_git.bb +1 -0
index d34f608..cd4dc8e 100644
@@ -18,6 +18,7 @@ PV = "0.29+git${SRCPV}"
 SRC_URI = "git://anongit.freedesktop.org/pkg-config \
            file://pkg-config-native.in \
            file://fix-glib-configure-libtool-usage.patch \
+	   file://0001-gdate-suppress-string-format-literal-warning.patch \
            "
 
 S = "${WORKDIR}/git"
#3 lore raw

Re: [krogoth][PATCH 1/8] pkgconfig: Fix build with gcc-6

Quoted 2 lines · On 15 July 2016 at 14:53, akuster808 <[email protected]> wrote:

So this is the host gcc not the one in OE?

Yes, the situation was host with gcc6 building krogoth.

Ross

#4 lore raw

Re: [krogoth][PATCH 1/8] pkgconfig: Fix build with gcc-6

Quoted 6 lines · Ross
Quoted 2 lines · On 15 July 2016 at 14:53, akuster808 <[email protected]> wrote:

So this is the host gcc not the one in OE?

Yes, the situation was host with gcc6 building krogoth.

Thanks. After looking further down the queue I found the PATCH 0/8 and it explained.

The original master commits are cryptic on which GCC 6 has the issue.

thanks,
- Armin

Quoted 3 lines

Ross

#5 lore raw

Re: [krogoth][PATCH 1/8] pkgconfig: Fix build with gcc-6

Quoted 8 lines · On Fri, Jul 15, 2016 at 7:27 AM, akuster808 <[email protected]> wrote:
Quoted 5 lines · Ross
Quoted 2 lines · On 15 July 2016 at 14:53, akuster808 <[email protected]> wrote:

So this is the host gcc not the one in OE?

Quoted 8 lines
Quoted 1 line

Yes, the situation was host with gcc6 building krogoth.

Thanks. After looking further down the queue I found the PATCH 0/8 and it explained.

The original master commits are cryptic on which GCC 6 has the issue.

Sorry. I wasn't thinking about that when I did the cherry-picks. This was all for gcc-6 on host only, but those commits have no indication of that. And of course the cover-letter will not be in the git history.

I probably should have done rebase reword on them for clarity.

Cheers.

--Tim

Quoted 11 lines

thanks,
- Armin

Quoted 3 lines

Ross

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

author
#6 lore raw

PATCH 2/8 elfutils-0.148: Fix build with gcc6

In reply to Tim Orling

From: Khem Raj <[email protected]>

(From OE-Core rev: c2668171f5d76bfea085ecf2fa7dfe1e42df1e63)

---
 .../elfutils/elfutils-0.148/gcc6.patch             | 23 ++++++++++++++++++++++
 meta/recipes-devtools/elfutils/elfutils_0.148.bb   |  1 +
 2 files changed, 24 insertions(+)
 create mode 100644 meta/recipes-devtools/elfutils/elfutils-0.148/gcc6.patch
meta/recipes-devtools/elfutils/elfutils-0.148/gcc6.patch new file +23 -0
new file mode 100644
index 0000000..b56a754
@@ -0,0 +1,23 @@
+Fix warnings found with gcc6
+
+| ../../elfutils-0.148/libdw/dwarf_siblingof.c: In function 'dwarf_siblingof':
+| ../../elfutils-0.148/libdw/dwarf_siblingof.c:69:6: error: nonnull argument 'result' compared to NULL [-Werror=nonnull-compare]
+|    if (result == NULL)
+|       ^
+
+Signed-off-by: Khem Raj <[email protected]>
+Upstream-Status: Inappropriate [ unmaintained ]
+Index: elfutils-0.148/libdw/dwarf_siblingof.c
+===================================================================
+--- elfutils-0.148.orig/libdw/dwarf_siblingof.c
++++ elfutils-0.148/libdw/dwarf_siblingof.c
+@@ -66,9 +66,6 @@ dwarf_siblingof (die, result)
+   if (die == NULL)
+     return -1;
+ 
+-  if (result == NULL)
+-    return -1;
+-
+   if (result != die)
+     result->addr = NULL;
+ 
meta/recipes-devtools/elfutils/elfutils_0.148.bb +1 -0
index ff53257..6080c17 100644
@@ -34,6 +34,7 @@ SRC_URI += "\
         file://Fix_elf_cvt_gunhash.patch \
         file://elf_begin.c-CVE-2014-9447-fix.patch \
         file://fix-build-gcc-4.8.patch \
+        file://gcc6.patch \
 "
 # Only apply when building uclibc based target recipe
 SRC_URI_append_libc-uclibc = " file://uclibc-support-for-elfutils-0.148.patch"
Signature · 1 line
2.7.4
author
#7 lore raw

PATCH 3/8 elfutils: Fix build for gcc-6

In reply to Tim Orling

Backport patch from upstream.

[YOCTO #9897] (Fedora-24)

---
 ...missing-brackets-around-if-statement-body.patch | 419 +++++++++++++++++++++
 meta/recipes-devtools/elfutils/elfutils_0.164.bb   |   1 +
 2 files changed, 420 insertions(+)
 create mode 100644 meta/recipes-devtools/elfutils/elfutils-0.164/libebl-Fix-missing-brackets-around-if-statement-body.patch
meta/recipes-devtools/elfutils/elfutils-0.164/libebl-Fix-missing-brackets-around-if-statement-body.patch new file +419 -0
new file mode 100644
index 0000000..8399133
@@ -0,0 +1,419 @@
+The upstream patch libebl/Changelog does not apply cleanly.
+Modify the patch to skip that change only.
+
+Upstream-Status: Backport
+
+Signed-off-by: Tim Orling <[email protected]>
+
+From c5da7c9e08c2bdb6dba8e115dcc09ed51a07f0e4 Mon Sep 17 00:00:00 2001
+From: Mark Wielaard <[email protected]>
+Date: Sat, 9 Jan 2016 22:09:48 +0100
+Subject: libebl: Fix missing brackets around if statement body.
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+GCC6 [will have] a nice new warning that showed a real bug:
+
+elfutils/libebl/eblobjnote.c: In function ‘ebl_object_note’:
+elfutils/libebl/eblobjnote.c:135:5: error: statement is indented as if it were guarded by... [-Werror=misleading-indentation]
+     switch (type)
+     ^~~~~~
+
+elfutils/libebl/eblobjnote.c:45:3: note: ...this ‘if’ clause, but it is not
+   if (! ebl->object_note (name, type, descsz, desc))
+   ^~
+
+And indeed, it should have been under the if, but wasn't because of missing
+brackets. Added brackets (and reindent).
+
+Signed-off-by: Mark Wielaard <[email protected]>
+---
+ libebl/eblobjnote.c | 362 ++++++++++++++++++++++++++--------------------------
+ 2 files changed, 187 insertions(+), 180 deletions(-)
+
+diff --git a/libebl/eblobjnote.c b/libebl/eblobjnote.c
+index fa1eb93..f80a1a5 100644
+--- a/libebl/eblobjnote.c
++++ b/libebl/eblobjnote.c
+@@ -1,5 +1,5 @@
+ /* Print contents of object file note.
+-   Copyright (C) 2002, 2007, 2009, 2011, 2015 Red Hat, Inc.
++   Copyright (C) 2002, 2007, 2009, 2011, 2015, 2016 Red Hat, Inc.
+    This file is part of elfutils.
+    Written by Ulrich Drepper <[email protected]>, 2002.
+ 
+@@ -43,189 +43,191 @@ ebl_object_note (Ebl *ebl, const char *name, uint32_t type,
+ 		 uint32_t descsz, const char *desc)
+ {
+   if (! ebl->object_note (name, type, descsz, desc))
+-    /* The machine specific function did not know this type.  */
++    {
++      /* The machine specific function did not know this type.  */
+ 
+-    if (strcmp ("stapsdt", name) == 0)
+-      {
+-	if (type != 3)
+-	  {
+-	    printf (gettext ("unknown SDT version %u\n"), type);
+-	    return;
+-	  }
+-
+-	/* Descriptor starts with three addresses, pc, base ref and
+-	   semaphore.  Then three zero terminated strings provider,
+-	   name and arguments.  */
+-
+-	union
++      if (strcmp ("stapsdt", name) == 0)
+ 	{
+-	  Elf64_Addr a64[3];
+-	  Elf32_Addr a32[3];
+-	} addrs;
++	  if (type != 3)
++	    {
++	      printf (gettext ("unknown SDT version %u\n"), type);
++	      return;
++	    }
+ 
+-	size_t addrs_size = gelf_fsize (ebl->elf, ELF_T_ADDR, 3, EV_CURRENT);
+-	if (descsz < addrs_size + 3)
+-	  {
+-	  invalid_sdt:
+-	    printf (gettext ("invalid SDT probe descriptor\n"));
+-	    return;
+-	  }
++	  /* Descriptor starts with three addresses, pc, base ref and
++	     semaphore.  Then three zero terminated strings provider,
++	     name and arguments.  */
+ 
+-	Elf_Data src =
++	  union
+ 	  {
+-	    .d_type = ELF_T_ADDR, .d_version = EV_CURRENT,
+-	    .d_buf = (void *) desc, .d_size = addrs_size
+-	  };
+-
+-	Elf_Data dst =
+-	  {
+-	    .d_type = ELF_T_ADDR, .d_version = EV_CURRENT,
+-	    .d_buf = &addrs, .d_size = addrs_size
+-	  };
+-
+-	if (gelf_xlatetom (ebl->elf, &dst, &src,
+-			   elf_getident (ebl->elf, NULL)[EI_DATA]) == NULL)
+-	  {
+-	    printf ("%s\n", elf_errmsg (-1));
+-	    return;
+-	  }
+-
+-	const char *provider = desc + addrs_size;
+-	const char *pname = memchr (provider, '\0', desc + descsz - provider);
+-	if (pname == NULL)
+-	  goto invalid_sdt;
+-
+-	++pname;
+-	const char *args = memchr (pname, '\0', desc + descsz - pname);
+-	if (args == NULL ||
+-	    memchr (++args, '\0', desc + descsz - pname) != desc + descsz - 1)
+-	  goto invalid_sdt;
+-
+-	GElf_Addr pc;
+-	GElf_Addr base;
+-	GElf_Addr sem;
+-	if (gelf_getclass (ebl->elf) == ELFCLASS32)
+-	  {
+-	    pc = addrs.a32[0];
+-	    base = addrs.a32[1];
+-	    sem = addrs.a32[2];
+-	  }
+-	else
+-	  {
+-	    pc = addrs.a64[0];
+-	    base = addrs.a64[1];
+-	    sem = addrs.a64[2];
+-	  }
+-
+-	printf (gettext ("    PC: "));
+-	printf ("%#" PRIx64 ",", pc);
+-	printf (gettext (" Base: "));
+-	printf ("%#" PRIx64 ",", base);
+-	printf (gettext (" Semaphore: "));
+-	printf ("%#" PRIx64 "\n", sem);
+-	printf (gettext ("    Provider: "));
+-	printf ("%s,", provider);
+-	printf (gettext (" Name: "));
+-	printf ("%s,", pname);
+-	printf (gettext (" Args: "));
+-	printf ("'%s'\n", args);
+-	return;
+-      }
+-
+-    switch (type)
+-      {
+-      case NT_GNU_BUILD_ID:
+-	if (strcmp (name, "GNU") == 0 && descsz > 0)
+-	  {
+-	    printf (gettext ("    Build ID: "));
+-	    uint_fast32_t i;
+-	    for (i = 0; i < descsz - 1; ++i)
+-	      printf ("%02" PRIx8, (uint8_t) desc[i]);
+-	    printf ("%02" PRIx8 "\n", (uint8_t) desc[i]);
+-	  }
+-	break;
+-
+-      case NT_GNU_GOLD_VERSION:
+-	if (strcmp (name, "GNU") == 0 && descsz > 0)
+-	  /* A non-null terminated version string.  */
+-	  printf (gettext ("    Linker version: %.*s\n"),
+-		  (int) descsz, desc);
+-	break;
+-
+-      case NT_GNU_ABI_TAG:
+-	if (strcmp (name, "GNU") == 0 && descsz >= 8 && descsz % 4 == 0)
+-	  {
+-	    Elf_Data in =
+-	      {
+-		.d_version = EV_CURRENT,
+-		.d_type = ELF_T_WORD,
+-		.d_size = descsz,
+-		.d_buf = (void *) desc
+-	      };
+-	    /* Normally NT_GNU_ABI_TAG is just 4 words (16 bytes).  If it
+-	       is much (4*) larger dynamically allocate memory to convert.  */
++	    Elf64_Addr a64[3];
++	    Elf32_Addr a32[3];
++	  } addrs;
++
++	  size_t addrs_size = gelf_fsize (ebl->elf, ELF_T_ADDR, 3, EV_CURRENT);
++	  if (descsz < addrs_size + 3)
++	    {
++	    invalid_sdt:
++	      printf (gettext ("invalid SDT probe descriptor\n"));
++	      return;
++	    }
++
++	  Elf_Data src =
++	    {
++	      .d_type = ELF_T_ADDR, .d_version = EV_CURRENT,
++	      .d_buf = (void *) desc, .d_size = addrs_size
++	    };
++
++	  Elf_Data dst =
++	    {
++	      .d_type = ELF_T_ADDR, .d_version = EV_CURRENT,
++	      .d_buf = &addrs, .d_size = addrs_size
++	    };
++
++	  if (gelf_xlatetom (ebl->elf, &dst, &src,
++			     elf_getident (ebl->elf, NULL)[EI_DATA]) == NULL)
++	    {
++	      printf ("%s\n", elf_errmsg (-1));
++	      return;
++	    }
++
++	  const char *provider = desc + addrs_size;
++	  const char *pname = memchr (provider, '\0', desc + descsz - provider);
++	  if (pname == NULL)
++	    goto invalid_sdt;
++
++	  ++pname;
++	  const char *args = memchr (pname, '\0', desc + descsz - pname);
++	  if (args == NULL ||
++	      memchr (++args, '\0', desc + descsz - pname) != desc + descsz - 1)
++	    goto invalid_sdt;
++
++	  GElf_Addr pc;
++	  GElf_Addr base;
++	  GElf_Addr sem;
++	  if (gelf_getclass (ebl->elf) == ELFCLASS32)
++	    {
++	      pc = addrs.a32[0];
++	      base = addrs.a32[1];
++	      sem = addrs.a32[2];
++	    }
++	  else
++	    {
++	      pc = addrs.a64[0];
++	      base = addrs.a64[1];
++	      sem = addrs.a64[2];
++	    }
++
++	  printf (gettext ("    PC: "));
++	  printf ("%#" PRIx64 ",", pc);
++	  printf (gettext (" Base: "));
++	  printf ("%#" PRIx64 ",", base);
++	  printf (gettext (" Semaphore: "));
++	  printf ("%#" PRIx64 "\n", sem);
++	  printf (gettext ("    Provider: "));
++	  printf ("%s,", provider);
++	  printf (gettext (" Name: "));
++	  printf ("%s,", pname);
++	  printf (gettext (" Args: "));
++	  printf ("'%s'\n", args);
++	  return;
++	}
++
++      switch (type)
++	{
++	case NT_GNU_BUILD_ID:
++	  if (strcmp (name, "GNU") == 0 && descsz > 0)
++	    {
++	      printf (gettext ("    Build ID: "));
++	      uint_fast32_t i;
++	      for (i = 0; i < descsz - 1; ++i)
++		printf ("%02" PRIx8, (uint8_t) desc[i]);
++	      printf ("%02" PRIx8 "\n", (uint8_t) desc[i]);
++	    }
++	  break;
++
++	case NT_GNU_GOLD_VERSION:
++	  if (strcmp (name, "GNU") == 0 && descsz > 0)
++	    /* A non-null terminated version string.  */
++	    printf (gettext ("    Linker version: %.*s\n"),
++		    (int) descsz, desc);
++	  break;
++
++	case NT_GNU_ABI_TAG:
++	  if (strcmp (name, "GNU") == 0 && descsz >= 8 && descsz % 4 == 0)
++	    {
++	      Elf_Data in =
++		{
++		  .d_version = EV_CURRENT,
++		  .d_type = ELF_T_WORD,
++		  .d_size = descsz,
++		  .d_buf = (void *) desc
++		};
++	      /* Normally NT_GNU_ABI_TAG is just 4 words (16 bytes).  If it
++		 is much (4*) larger dynamically allocate memory to convert.  */
+ #define FIXED_TAG_BYTES 16
+-	    uint32_t sbuf[FIXED_TAG_BYTES];
+-	    uint32_t *buf;
+-	    if (unlikely (descsz / 4 > FIXED_TAG_BYTES))
+-	      {
+-	        buf = malloc (descsz);
+-		if (unlikely (buf == NULL))
+-		  return;
+-	      }
+-	    else
+-	      buf = sbuf;
+-	    Elf_Data out =
+-	      {
+-		.d_version = EV_CURRENT,
+-		.d_type = ELF_T_WORD,
+-		.d_size = descsz,
+-		.d_buf = buf
+-	      };
+-
+-	    if (elf32_xlatetom (&out, &in, ebl->data) != NULL)
+-	      {
+-		const char *os;
+-		switch (buf[0])
+-		  {
+-		  case ELF_NOTE_OS_LINUX:
+-		    os = "Linux";
+-		    break;
+-
+-		  case ELF_NOTE_OS_GNU:
+-		    os = "GNU";
+-		    break;
+-
+-		  case ELF_NOTE_OS_SOLARIS2:
+-		    os = "Solaris";
+-		    break;
+-
+-		  case ELF_NOTE_OS_FREEBSD:
+-		    os = "FreeBSD";
+-		    break;
+-
+-		  default:
+-		    os = "???";
+-		    break;
+-		  }
+-
+-		printf (gettext ("    OS: %s, ABI: "), os);
+-		for (size_t cnt = 1; cnt < descsz / 4; ++cnt)
+-		  {
+-		    if (cnt > 1)
+-		      putchar_unlocked ('.');
+-		    printf ("%" PRIu32, buf[cnt]);
+-		  }
+-		putchar_unlocked ('\n');
+-	      }
+-	    if (descsz / 4 > FIXED_TAG_BYTES)
+-	      free (buf);
+-	    break;
+-	  }
+-	/* FALLTHROUGH */
+-
+-      default:
+-	/* Unknown type.  */
+-	break;
+-      }
++	      uint32_t sbuf[FIXED_TAG_BYTES];
++	      uint32_t *buf;
++	      if (unlikely (descsz / 4 > FIXED_TAG_BYTES))
++		{
++		  buf = malloc (descsz);
++		  if (unlikely (buf == NULL))
++		    return;
++		}
++	      else
++		buf = sbuf;
++	      Elf_Data out =
++		{
++		  .d_version = EV_CURRENT,
++		  .d_type = ELF_T_WORD,
++		  .d_size = descsz,
++		  .d_buf = buf
++		};
++
++	      if (elf32_xlatetom (&out, &in, ebl->data) != NULL)
++		{
++		  const char *os;
++		  switch (buf[0])
++		    {
++		    case ELF_NOTE_OS_LINUX:
++		      os = "Linux";
++		      break;
++
++		    case ELF_NOTE_OS_GNU:
++		      os = "GNU";
++		      break;
++
++		    case ELF_NOTE_OS_SOLARIS2:
++		      os = "Solaris";
++		      break;
++
++		    case ELF_NOTE_OS_FREEBSD:
++		      os = "FreeBSD";
++		      break;
++
++		    default:
++		      os = "???";
++		      break;
++		    }
++
++		  printf (gettext ("    OS: %s, ABI: "), os);
++		  for (size_t cnt = 1; cnt < descsz / 4; ++cnt)
++		    {
++		      if (cnt > 1)
++			putchar_unlocked ('.');
++		      printf ("%" PRIu32, buf[cnt]);
++		    }
++		  putchar_unlocked ('\n');
++		}
++	      if (descsz / 4 > FIXED_TAG_BYTES)
++		free (buf);
++	      break;
++	    }
++	  /* FALLTHROUGH */
++
++	default:
++	  /* Unknown type.  */
++	  break;
++	}
++    }
+ }
+-- 
+cgit v0.12
+
meta/recipes-devtools/elfutils/elfutils_0.164.bb +1 -0
index 4964c05..2b23025 100644
@@ -20,6 +20,7 @@ SRC_URI += "\
         file://0001-fix-a-stack-usage-warning.patch \
         file://aarch64_uio.patch \
         file://shadow.patch \
+	file://libebl-Fix-missing-brackets-around-if-statement-body.patch \
 "
 
 # pick the patch from debian
Signature · 1 line
2.7.4
author
#8 lore raw

PATCH 4/8 rpm: Fix build with gcc6

In reply to Tim Orling

From: Khem Raj <[email protected]>

(From OE-Core rev: e9c86d85460f45011bd978e1495a2b802d733020)

---
 meta/recipes-devtools/rpm/rpm/gcc6-stdlib.patch | 54 +++++++++++++++++++++++++
 meta/recipes-devtools/rpm/rpm_5.4.16.bb         |  3 +-
 2 files changed, 56 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-devtools/rpm/rpm/gcc6-stdlib.patch
meta/recipes-devtools/rpm/rpm/gcc6-stdlib.patch new file +54 -0
new file mode 100644
index 0000000..0a372c6
@@ -0,0 +1,54 @@
+gcc6 has fixed a long standing c++ include issue where <cheader>
+was different from <header.h> inclusion via
+
+https://gcc.gnu.org/ml/libstdc++/2016-01/msg00025.html
+
+and its also descibed in https://gcc.gnu.org/gcc-6/porting_to.html
+rpmio component uses some .cpp and .cc fies which need to use
+C stdlib.h from C library and not the C++ libstdc++ header
+therefore we pass _GLIBCXX_INCLUDE_NEXT_C_HEADERS so that it
+keeps the old behavior
+
+/a/build/tmp/sysroots/raspberrypi2/usr/include/c++/6.0.1/cstdlib:143:11: error: '::getenv' has not been declared
+   using ::getenv;
+           ^~~~~~
+In file included from ../../rpm-5.4.15/system.h:201:0,
+                 from ../../rpm-5.4.15/rpmio/rpmjs.cpp:1:
+/a/build/tmp/sysroots/raspberrypi2/usr/include/c++/6.0.1/stdlib.h:62:12: error: 'std::getenv' has not been declared
+ using std::getenv;
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <[email protected]>
+
+Index: rpm-5.4.15/rpmio/Makefile.am
+===================================================================
+--- rpm-5.4.15.orig/rpmio/Makefile.am
++++ rpm-5.4.15/rpmio/Makefile.am
+@@ -151,7 +151,7 @@ librpmio_la_SOURCES = \
+ 	groestl.c hamsi.c jh.c keccak.c lane.c luffa.c md2.c md6.c radiogatun.c\
+ 	salsa10.c salsa20.c shabal.c shavite3.c simd.c skein.c tib3.c tiger.c \
+ 	rpmgit.c rpmio-stub.c \
+-	rpmjs.cpp rpmjsio.c rpmkeyring.c \
++	rpmjni.cc rpmjs.cpp rpmjsio.c rpmkeyring.c \
+ 	rpmnix.c rpmodbc.c rpmsql.c set.c \
+ 	ar.c \
+ 	argv.c \
+@@ -195,7 +195,6 @@ librpmio_la_SOURCES = \
+ 	rpmhook.c \
+ 	rpmio.c \
+ 	rpmiob.c \
+-	rpmjni.cc \
+ 	rpmku.c \
+ 	rpmlog.c \
+ 	rpmltc.c \
+@@ -279,7 +278,9 @@ keccak.lo: $(top_srcdir)/rpmio/keccak.c
+ #rpmjs.lo: $(top_srcdir)/rpmio/rpmjs.c
+ #	@$(LTCOMPILE) -O0 -c $<
+ rpmjs.lo: $(top_srcdir)/rpmio/rpmjs.cpp
+-	@$(LTCOMPILE) -O0 -c $<
++	@$(LTCOMPILE) -O0 -c -D_GLIBCXX_INCLUDE_NEXT_C_HEADERS $<
++rpmjni.lo: $(top_srcdir)/rpmio/rpmjni.cc
++	@$(LTCOMPILE) -O0 -c -D_GLIBCXX_INCLUDE_NEXT_C_HEADERS $<
+ 
+ YACC = byacc -d
+ getdate.c: getdate.y
meta/recipes-devtools/rpm/rpm_5.4.16.bb +2 -1
index f2c12d2..7ebd5e9 100644
@@ -116,6 +116,7 @@ SRC_URI += " \
 	   file://rpm-fix-lua-tests-compilation-failure.patch \
 	   file://rpmqv.c-check-_gpg_passphrase-before-ask-for-input.patch \
 	   file://0001-Disable-__sync_add_and_fetch_8-on-nios2.patch \
+	   file://gcc6-stdlib.patch \
 "
 
 # OE specific changes
@@ -344,7 +345,7 @@ EXTRA_OECONF += "--verbose \
 		--program-prefix= \
 		YACC=byacc"
 
-CFLAGS_append = " -DRPM_VENDOR_WINDRIVER -DRPM_VENDOR_POKY -DRPM_VENDOR_OE"
+CFLAGS_append = " -DRPM_VENDOR_WINDRIVER -DRPM_VENDOR_POKY -DRPM_VENDOR_OE -D_GLIBCXX_INCLUDE_NEXT_C_HEADERS"
 
 LDFLAGS_append_libc-uclibc = "-lrt -lpthread"
 
Signature · 1 line
2.7.4
author
#9 lore raw

PATCH 5/8 glib-2.0: Ignore useless warning found with gcc-6

In reply to Tim Orling

From: Khem Raj <[email protected]>

../../glib-2.46.2/glib/gdate.c:2497:7: error: format not a string literal, format string not checked [-Werror=format-nonliteral]

       tmplen = strftime (tmpbuf, tmpbufsize, locale_format, &tm);
       ^~~~~~
| ../../../../../../../../workspace/sources/glib-2.0/glib/tests/gdatetime.c: In function 'test_strftime':
| ../../../../../../../../workspace/sources/glib-2.0/glib/tests/gdatetime.c:1338:3: error: '%c' yields only last 2 digits of year in some locales [-Werror=format-y2k]
|    "a%a A%A b%b B%B c%c C%C d%d e%e F%F g%g G%G h%h H%H I%I j%j m%m M%M " \

Additionally fix the problem seen where write() return code is ignored

(From OE-Core rev: 3fdecff96dd7516605ec9248b2a39de4db81306f)

---
 .../0001-Do-not-ignore-return-value-of-write.patch | 42 ++++++++++++++++++++++
 .../glib-2.0/0002-tests-Ignore-y2k-warnings.patch  | 42 ++++++++++++++++++++++
 .../ignore-format-nonliteral-warning.patch         | 39 ++++++++++++++++++++
 meta/recipes-core/glib-2.0/glib-2.0_2.46.2.bb      |  7 ++--
 4 files changed, 128 insertions(+), 2 deletions(-)
 create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/0001-Do-not-ignore-return-value-of-write.patch
 create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/0002-tests-Ignore-y2k-warnings.patch
 create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/ignore-format-nonliteral-warning.patch
meta/recipes-core/glib-2.0/glib-2.0/0001-Do-not-ignore-return-value-of-write.patch new file +42 -0
new file mode 100644
index 0000000..aee96aa
@@ -0,0 +1,42 @@
+From d6501b107940e9f548c89236d773c6d33c15a5c9 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Sat, 16 Apr 2016 13:28:59 -0700
+Subject: [PATCH 1/2] Do not ignore return value of write()
+
+gcc warns about ignoring return value when compiling
+with fortify turned on.
+
+assert when write() fails
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+Upstream-Status: Submitted
+
+ glib/tests/unix.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/glib/tests/unix.c b/glib/tests/unix.c
+index 3543458..4e7ed85 100644
+--- a/glib/tests/unix.c
++++ b/glib/tests/unix.c
+@@ -32,14 +32,15 @@ test_pipe (void)
+   GError *error = NULL;
+   int pipefd[2];
+   char buf[1024];
+-  ssize_t bytes_read;
++  ssize_t bytes_read, bytes_written;
+   gboolean res;
+ 
+   res = g_unix_open_pipe (pipefd, FD_CLOEXEC, &error);
+   g_assert (res);
+   g_assert_no_error (error);
+ 
+-  write (pipefd[1], "hello", sizeof ("hello"));
++  bytes_written = write (pipefd[1], "hello", sizeof ("hello"));
++  g_assert (bytes_written != -1 && "write() failed");
+   memset (buf, 0, sizeof (buf));
+   bytes_read = read (pipefd[0], buf, sizeof(buf) - 1);
+   g_assert_cmpint (bytes_read, >, 0);
+-- 
+2.8.0
+
meta/recipes-core/glib-2.0/glib-2.0/0002-tests-Ignore-y2k-warnings.patch new file +42 -0

42 lines not on this page · raw message

meta/recipes-core/glib-2.0/glib-2.0/ignore-format-nonliteral-warning.patch new file +39 -0
new file mode 100644
index 0000000..d533975
@@ -0,0 +1,39 @@
+From 8cdbc7fb2c8c876902e457abe46ee18a0b134486 Mon Sep 17 00:00:00 2001
+From: coypu <[email protected]>
+Date: Wed, 2 Mar 2016 19:38:48 +0200
+Subject: gdate: Move warning pragma outside of function
+
+Commit 0817af40e8c74c721c30f6ef482b1f53d12044c7 breaks the build on
+older versions of GCC, which don't allow pragma inside functions.
+
+https://bugzilla.gnome.org/761550
+---
+Upstream-Status: Backport
+Signed-off-by: Khem Raj <[email protected]>
+
+ glib/gdate.c | 8 +++++---
+ 1 file changed, 5 insertions(+), 3 deletions(-)
+
+diff --git a/glib/gdate.c b/glib/gdate.c
+index cdc735c..92c34d2 100644
+--- a/glib/gdate.c
++++ b/glib/gdate.c
+@@ -2439,6 +2439,9 @@ win32_strftime_helper (const GDate     *d,
+  *
+  * Returns: number of characters written to the buffer, or 0 the buffer was too small
+  */
++#pragma GCC diagnostic push
++#pragma GCC diagnostic ignored "-Wformat-nonliteral"
++
+ gsize     
+ g_date_strftime (gchar       *s, 
+                  gsize        slen, 
+@@ -2552,3 +2552,5 @@ g_date_strftime (gchar       *s,
+   return retval;
+ #endif
+ }
++
++#pragma GCC diagnostic pop
+-- 
+cgit v0.12
+
meta/recipes-core/glib-2.0/glib-2.0_2.46.2.bb +5 -2
index 8e445b4..9e95149 100644
@@ -13,11 +13,14 @@ SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \
            file://uclibc_musl_translation.patch \
            file://0001-configure.ac-Do-not-use-readlink-when-cross-compilin.patch \
            file://allow-run-media-sdX-drive-mount-if-username-root.patch \
-	   file://0001-Remove-the-warning-about-deprecated-paths-in-schemas.patch \
+           file://0001-Remove-the-warning-about-deprecated-paths-in-schemas.patch \
            file://Enable-more-tests-while-cross-compiling.patch \
            file://gi-exclude.patch \
            file://0001-Install-gio-querymodules-as-libexec_PROGRAM.patch \
-          "
+           file://ignore-format-nonliteral-warning.patch \
+           file://0001-Do-not-ignore-return-value-of-write.patch \
+           file://0002-tests-Ignore-y2k-warnings.patch \
+           "
 
 SRC_URI_append_class-native = " file://glib-gettextize-dir.patch \
                                 file://relocate-modules.patch"
Signature · 1 line
2.7.4
author
#10 lore raw

PATCH 6/8 binutils: disable werror on native build

In reply to Tim Orling

From: Dan McGregor <[email protected]>

It's disabled on cross builds, and it's needed for gcc 6

(From OE-Core rev: ce1b37e29dc89b67dc698e856007b59faa16c4df)

---
 meta/recipes-devtools/binutils/binutils_2.26.bb | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
meta/recipes-devtools/binutils/binutils_2.26.bb +2 -1
index b70ffbf..e976bad 100644
@@ -13,7 +13,8 @@ EXTRA_OECONF += "--with-sysroot=/ \
 EXTRA_OECONF_class-native = "--enable-targets=all \
                              --enable-64-bit-bfd \
                              --enable-install-libiberty \
-                             --enable-install-libbfd"
+                             --enable-install-libbfd \
+                             --disable-werror"
 
 do_install_class-native () {
 	autotools_do_install
Signature · 1 line
2.7.4
#11 lore raw

Re: [krogoth][PATCH 6/8] binutils: disable werror on native build

Quoted 20 lines · Tim Orling

From: Dan McGregor <[email protected]>

It's disabled on cross builds, and it's needed for gcc 6

(From OE-Core rev: ce1b37e29dc89b67dc698e856007b59faa16c4df)

---
meta/recipes-devtools/binutils/binutils_2.26.bb | 3 ++-

1 file changed, 2 insertions(+), 1 deletion(-)
meta/recipes-devtools/binutils/binutils_2.26.bb +0 -0
index b70ffbf..e976bad 100644

meta/recipes-devtools/binutils/binutils_2.26.bb EXTRA_OECONF += "--with-sysroot=/ \ · line 17

Quoted 6 lines
meta/recipes-devtools/binutils/binutils_2.26.bb +2 -1
@@ -13,7 +13,8 @@ EXTRA_OECONF += "--with-sysroot=/ \
 EXTRA_OECONF_class-native = "--enable-targets=all \
                             --enable-64-bit-bfd \
                             --enable-install-libiberty \
-                             --enable-install-libbfd"
+                             --enable-install-libbfd \
+                             --disable-werror”

How about other flavors of binutils ?

Quoted 11 lines
meta/recipes-devtools/binutils/binutils_2.26.bb +0 -1
 do_install_class-native () {
 	autotools_do_install
--

2.7.4

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#12 lore raw

Re: [krogoth][PATCH 6/8] binutils: disable werror on native build

Hi Khem,

Can you elaborate? What am I missing or unaware of? Happy to keep digging!

--Tim

Quoted 45 lines · Khem Raj
Quoted 2 lines

On Jul 14, 2016, at 6:49 PM, Tim Orling <

Quoted 9 lines · [email protected] <javascript:;>> wrote:

From: Dan McGregor <[email protected] <javascript:;>>

It's disabled on cross builds, and it's needed for gcc 6

(From OE-Core rev: ce1b37e29dc89b67dc698e856007b59faa16c4df)

Signed-off-by Dan McGregor <[email protected] <javascript:;>>

<javascript:;>>

Review

Quoted 5 lines

---
meta/recipes-devtools/binutils/binutils_2.26.bb | 3 ++-

1 file changed, 2 insertions(+), 1 deletion(-)
(quoted diff) +0 -0

b/meta/recipes-devtools/binutils/binutils_2.26.bb

meta/recipes-devtools/binutils/binutils_2.26.bb EXTRA_OECONF += "--with-sysroot=/ \ · line 17

Quoted 10 lines

index b70ffbf..e976bad 100644

meta/recipes-devtools/binutils/binutils_2.26.bb +2 -1
@@ -13,7 +13,8 @@ EXTRA_OECONF += "--with-sysroot=/ \
 EXTRA_OECONF_class-native = "--enable-targets=all \
                             --enable-64-bit-bfd \
                             --enable-install-libiberty \
-                             --enable-install-libbfd"
+                             --enable-install-libbfd \
+                             --disable-werror”

How about other flavors of binutils ?

Quoted 11 lines
meta/recipes-devtools/binutils/binutils_2.26.bb +0 -1
 do_install_class-native () {
      autotools_do_install
--

2.7.4

--
_______________________________________________
Openembedded-core mailing list [email protected] <javascript:;>
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#13 lore raw

Re: [krogoth][PATCH 6/8] binutils: disable werror on native build

Quoted 6 lines · Tim Orling

Hi Khem,

Can you elaborate? What am I missing or unaware of? Happy to keep digging!

Can you try building an SDK ?

Quoted 45 lines

--Tim

Quoted 19 lines · On Thursday, July 14, 2016, Khem Raj <[email protected]…

On Jul 14, 2016, at 6:49 PM, Tim Orling <[email protected] <javascript:;>> wrote:

From: Dan McGregor <[email protected] <javascript:;>>

It's disabled on cross builds, and it's needed for gcc 6

(From OE-Core rev: ce1b37e29dc89b67dc698e856007b59faa16c4df)

Signed-off-by Dan McGregor <[email protected] <javascript:;>>
Signed-off-by Richard Purdie <[email protected] <javascript:;>>

---
meta/recipes-devtools/binutils/binutils_2.26.bb <http://binutils_2.26.bb/> | 3 ++-

1 file changed, 2 insertions(+), 1 deletion(-)
meta/recipes-devtools/binutils/binutils_2.26.bb <http://binutils_2.26.bb/> +0 -0
index b70ffbf..e976bad 100644

meta/recipes-devtools/binutils/binutils_2.26.bb <http://binutils_2.26.bb/> EXTRA_OECONF += "--with-sysroot=/ \ · line 17

Quoted 6 lines
meta/recipes-devtools/binutils/binutils_2.26.bb <http://binutils_2.26.bb/> +2 -1
@@ -13,7 +13,8 @@ EXTRA_OECONF += "--with-sysroot=/ \
 EXTRA_OECONF_class-native = "--enable-targets=all \
                             --enable-64-bit-bfd \
                             --enable-install-libiberty \
-                             --enable-install-libbfd"
+                             --enable-install-libbfd \
+                             --disable-werror”

How about other flavors of binutils ?

Quoted 11 lines
meta/recipes-devtools/binutils/binutils_2.26.bb <http://binutils_2.26.bb/> +0 -1
 do_install_class-native () {
      autotools_do_install
--

2.7.4

--
_______________________________________________
Openembedded-core mailing list
[email protected] <javascript:;>
http://lists.openembedded.org/mailman/listinfo/openembedded-core <http://lists.openembedded.org/mailman/listinfo/openembedded-core>

author
#14 lore raw

PATCH 7/8 openjade-native: work around bug exposed by GCC 6

In reply to Tim Orling

From: Daniel McGregor <[email protected]>

Simply turn off the optimzation that is causing this breakage. I had originally used -fno-lifetime-dse, but -fno-tree-dse works at least going back as far as gcc 4.8.

This isn't a real fix, but it allows openjade to work enough to complete a build.

(From OE-Core rev: 39e7dd90878325158c143dfec8234d563b841b86)

---
 meta/recipes-devtools/openjade/openjade-native_1.3.2.bb | 1 +
 1 file changed, 1 insertion(+)
meta/recipes-devtools/openjade/openjade-native_1.3.2.bb +1 -0
index bc25008..afcb8ca 100644
@@ -44,6 +44,7 @@ CONFIGUREOPTS := "${@d.getVar('CONFIGUREOPTS', True).replace('--datadir=${datadi
 oe_runconf[vardepsexclude] += "CONFIGUREOPTS"
 
 CFLAGS =+ "-I${S}/include"
+CXXFLAGS += "-fno-tree-dse"
 
 SSTATEPOSTINSTFUNCS += "openjade_sstate_postinst"
 SYSROOT_PREPROCESS_FUNCS += "openjade_sysroot_preprocess"
Signature · 1 line
2.7.4
author
#15 lore raw

PATCH 8/8 gcc-5.3: fix build for gcc-6

In reply to Tim Orling

Backport upstream patch.
It had been applied to 4.9, but not 5.3.

[YOCTO #9897] (Fedora-24)

---
 meta/recipes-devtools/gcc/gcc-5.3.inc              |   1 +
 .../gcc-5.3/0060-fix-build-when-using-gcc6.patch   | 157 +++++++++++++++++++++
 2 files changed, 158 insertions(+)
 create mode 100644 meta/recipes-devtools/gcc/gcc-5.3/0060-fix-build-when-using-gcc6.patch
meta/recipes-devtools/gcc/gcc-5.3.inc +1 -0
index d18ad79..4815384 100644
@@ -89,6 +89,7 @@ SRC_URI = "\
            file://0057-unwind-fix-for-musl.patch \
            file://0058-fdebug-prefix-map-support-to-remap-relative-path.patch \
            file://0059-libgcc-use-ldflags.patch \
+	   file://0060-fix-build-when-using-gcc6.patch \
            file://CVE-2016-4488.patch \
            file://CVE-2016-4489.patch \
            file://CVE-2016-2226.patch \
meta/recipes-devtools/gcc/gcc-5.3/0060-fix-build-when-using-gcc6.patch new file +157 -0

157 lines not on this page · raw message

Signature · 1 line
2.7.4
#16 lore raw
In reply to Tim Orling
Quoted 3 lines · Tim Orling

[YOCTO #9897]

Fedora-24 only has gcc-6.1.1.

thanks,

pulled into staging.

- armin

Quoted 70 lines

This has caused a number of failures in -native recipes and gcc-cross.

This series either cherry-picks commits from master or applies known good patches from upstream.

Fixes broken build for:
- pkgconfig-native
- elfutils-native
- rpm-native
- binutils-native
- glib-2.0-native
- docbook-utils-native (actually openjade-native was the culprit)
- gcc-cross (gcc-cross-arm build tested for beaglebone)

Other problems may be lurking and only a world build on Fedora-24 AB will tell for sure.

The following changes since commit 98c57bb512ea6790db8604fcf0b88c81651d2ab4:

build-appliance-image: Update to krogoth head revision (2016-07-06 17:28:04 +0100)

are available in the git repository at:

git://git.yoctoproject.org/poky-contrib timo/krogoth-9897
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=timo/krogoth-9897

Dan McGregor (1):
binutils: disable werror on native build

Daniel McGregor (1):
openjade-native: work around bug exposed by GCC 6

Khem Raj (3):
elfutils-0.148: Fix build with gcc6
rpm: Fix build with gcc6
glib-2.0: Ignore useless warning found with gcc-6

Tim Orling (3):
pkgconfig: Fix build with gcc-6
elfutils: Fix build for gcc-6
gcc-5.3: fix build for gcc-6

 .../0001-Do-not-ignore-return-value-of-write.patch |  42 +++
 .../glib-2.0/0002-tests-Ignore-y2k-warnings.patch  |  42 +++
 .../ignore-format-nonliteral-warning.patch         |  39 ++
 meta/recipes-core/glib-2.0/glib-2.0_2.46.2.bb      |   7 +-
 meta/recipes-devtools/binutils/binutils_2.26.bb    |   3 +-
 .../elfutils/elfutils-0.148/gcc6.patch             |  23 ++
 ...missing-brackets-around-if-statement-body.patch | 419 +++++++++++++++++++++
 meta/recipes-devtools/elfutils/elfutils_0.148.bb   |   1 +
 meta/recipes-devtools/elfutils/elfutils_0.164.bb   |   1 +
 meta/recipes-devtools/gcc/gcc-5.3.inc              |   1 +
 .../gcc-5.3/0060-fix-build-when-using-gcc6.patch   | 157 ++++++++
 .../openjade/openjade-native_1.3.2.bb              |   1 +
 ...te-suppress-string-format-literal-warning.patch |  34 ++
 meta/recipes-devtools/pkgconfig/pkgconfig_git.bb   |   1 +
 meta/recipes-devtools/rpm/rpm/gcc6-stdlib.patch    |  54 +++
 meta/recipes-devtools/rpm/rpm_5.4.16.bb            |   3 +-
 16 files changed, 824 insertions(+), 4 deletions(-)
 create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/0001-Do-not-ignore-return-value-of-write.patch
 create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/0002-tests-Ignore-y2k-warnings.patch
 create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/ignore-format-nonliteral-warning.patch
 create mode 100644 meta/recipes-devtools/elfutils/elfutils-0.148/gcc6.patch
 create mode 100644 meta/recipes-devtools/elfutils/elfutils-0.164/libebl-Fix-missing-brackets-around-if-statement-body.patch
 create mode 100644 meta/recipes-devtools/gcc/gcc-5.3/0060-fix-build-when-using-gcc6.patch
 create mode 100644 meta/recipes-devtools/pkgconfig/pkgconfig/0001-gdate-suppress-string-format-literal-warning.patch
 create mode 100644 meta/recipes-devtools/rpm/rpm/gcc6-stdlib.patch