summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Jansa <martin.jansa@gmail.com>2015-04-10 13:34:29 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-04-20 12:36:29 +0100
commita04380fd0f8f86c47e31376410182b52a670ea41 (patch)
tree93f0bd542da7b6a91a34985079830919d94bd601
parent6e08651e39392b19612806f6e2a3271091ba0787 (diff)
downloadpoky-a04380fd0f8f86c47e31376410182b52a670ea41.tar.gz
binutils: backport patch to fix build with gcc-4.9
* backported from 2.23.2, fixes: work/x86_64-linux/binutils-native/2.23.1-r3/binutils-2.23.1/gas/write.c:409:24: error: 'dummy.fr_type' may be used uninitialized in this function [-Werror=maybe-uninitialized] gas_assert (prev_frag->fr_type != 0); ^ work/x86_64-linux/binutils-native/2.23.1-r3/binutils-2.23.1/gas/write.c:392:9: note: 'dummy' was declared here fragS dummy, *prev_frag = &dummy; ^ (From OE-Core rev: 8c5396bd3b7f1eef3d53ebf0404189fd75f1d5e1) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-devtools/binutils/binutils-2.23.1.inc1
-rw-r--r--meta/recipes-devtools/binutils/binutils/0001-write.c-chain_frchains_together_1-Reorder-assertion-.patch30
2 files changed, 31 insertions, 0 deletions
diff --git a/meta/recipes-devtools/binutils/binutils-2.23.1.inc b/meta/recipes-devtools/binutils/binutils-2.23.1.inc
index 7b3366aeac..6a6811b87d 100644
--- a/meta/recipes-devtools/binutils/binutils-2.23.1.inc
+++ b/meta/recipes-devtools/binutils/binutils-2.23.1.inc
@@ -31,6 +31,7 @@ SRC_URI = "\
31 file://binutils-fix-over-array-bounds-issue.patch \ 31 file://binutils-fix-over-array-bounds-issue.patch \
32 file://replace_macros_with_static_inline.patch \ 32 file://replace_macros_with_static_inline.patch \
33 file://0001-Fix-MMIX-build-breakage-from-bfd_set_section_vma-cha.patch \ 33 file://0001-Fix-MMIX-build-breakage-from-bfd_set_section_vma-cha.patch \
34 file://0001-write.c-chain_frchains_together_1-Reorder-assertion-.patch \
34 " 35 "
35 36
36BACKPORT = "\ 37BACKPORT = "\
diff --git a/meta/recipes-devtools/binutils/binutils/0001-write.c-chain_frchains_together_1-Reorder-assertion-.patch b/meta/recipes-devtools/binutils/binutils/0001-write.c-chain_frchains_together_1-Reorder-assertion-.patch
new file mode 100644
index 0000000000..ffe6852dff
--- /dev/null
+++ b/meta/recipes-devtools/binutils/binutils/0001-write.c-chain_frchains_together_1-Reorder-assertion-.patch
@@ -0,0 +1,30 @@
1From c50d883cb61ff9917464cb695a0fd83fdb0f9c20 Mon Sep 17 00:00:00 2001
2From: Alan Modra <amodra@bigpond.net.au>
3Date: Mon, 21 Jan 2013 13:48:31 +0000
4Subject: [PATCH] write.c (chain_frchains_together_1): Reorder assertion to
5 avoid uninit warning.
6
7Upstream-Status: Backport from 2.23.2
8Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
9---
10 gas/write.c | 4 ++--
11 1 file changed, 2 insertions(+), 2 deletions(-)
12
13diff --git a/gas/write.c b/gas/write.c
14index a467147..56ebb6c 100644
15--- a/gas/write.c
16+++ b/gas/write.c
17@@ -406,8 +406,8 @@ chain_frchains_together_1 (segT section, struct frchain *frchp)
18 prev_fix = frchp->fix_tail;
19 }
20 }
21- gas_assert (prev_frag->fr_type != 0);
22- gas_assert (prev_frag != &dummy);
23+ gas_assert (prev_frag != &dummy
24+ && prev_frag->fr_type != 0);
25 prev_frag->fr_next = 0;
26 return prev_frag;
27 }
28--
292.3.5
30