summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/recipes-devtools/binutils/binutils-2.24.inc1
-rw-r--r--meta/recipes-devtools/binutils/binutils/binutils-uninitialised-warning.patch50
2 files changed, 51 insertions, 0 deletions
diff --git a/meta/recipes-devtools/binutils/binutils-2.24.inc b/meta/recipes-devtools/binutils/binutils-2.24.inc
index ef6a4eb7b3..8f3216f2bf 100644
--- a/meta/recipes-devtools/binutils/binutils-2.24.inc
+++ b/meta/recipes-devtools/binutils/binutils-2.24.inc
@@ -31,6 +31,7 @@ SRC_URI = "\
31 file://fix-pr16428.patch \ 31 file://fix-pr16428.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://binutils-uninitialised-warning.patch \
34 " 35 "
35 36
36SRC_URI[md5sum] = "e0f71a7b2ddab0f8612336ac81d9636b" 37SRC_URI[md5sum] = "e0f71a7b2ddab0f8612336ac81d9636b"
diff --git a/meta/recipes-devtools/binutils/binutils/binutils-uninitialised-warning.patch b/meta/recipes-devtools/binutils/binutils/binutils-uninitialised-warning.patch
new file mode 100644
index 0000000000..2feb80c4d2
--- /dev/null
+++ b/meta/recipes-devtools/binutils/binutils/binutils-uninitialised-warning.patch
@@ -0,0 +1,50 @@
1From f9c316c4d75be236bbaa8464ef803ed2d3859d6d Mon Sep 17 00:00:00 2001
2From: H.J. Lu <hjl.tools@gmail.com>
3Date: Wed, 15 Jan 2014 07:43:19 -0800
4Subject: [PATCH 1/1] Silence uninitialized warning on ehdr_start_save
5
6Older GCC, like 4.1/4.2, will issue an uninitialized warning on
7ehdr_start_save. This patch silences by using
8
9struct bfd_link_hash_entry ehdr_start_save = ehdr_start_save;
10
11 * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
12 Silence uninitialized warning on ehdr_start_save with older
13 GCC.
14
15Upstream-Status: Backport
16---
17 ld/ChangeLog | 6 ++++++
18 ld/emultempl/elf32.em | 2 +-
19 2 files changed, 7 insertions(+), 1 deletions(-)
20
21#diff --git a/ld/ChangeLog b/ld/ChangeLog
22#index eaa6b93..91055de 100644
23#--- a/ld/ChangeLog
24#+++ b/ld/ChangeLog
25#@@ -1,3 +1,9 @@
26#+2014-01-15 H.J. Lu <hongjiu.lu@intel.com>
27#+
28#+ * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
29#+ Silence uninitialized warning on ehdr_start_save with older
30#+ GCC.
31#+
32# 2014-01-15 Alan Modra <amodra@gmail.com>
33#
34# * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation): Define
35diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em
36index 13f86f0..569c7f7 100644
37--- a/ld/emultempl/elf32.em
38+++ b/ld/emultempl/elf32.em
39@@ -1481,7 +1481,7 @@ gld${EMULATION_NAME}_before_allocation (void)
40 asection *sinterp;
41 bfd *abfd;
42 struct elf_link_hash_entry *ehdr_start = NULL;
43- struct bfd_link_hash_entry ehdr_start_save;
44+ struct bfd_link_hash_entry ehdr_start_save = ehdr_start_save;
45
46 if (is_elf_hash_table (link_info.hash))
47 {
48--
491.7.1
50