summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2018-07-04 10:15:12 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-07-05 00:22:08 +0100
commit740b931d39ae597010e5911a7a07aca17d711428 (patch)
tree91c279ef399ca68af8128024527d4c3216ad6887 /meta
parent32320709311af076bb58399d9bb9299446d65f04 (diff)
downloadpoky-740b931d39ae597010e5911a7a07aca17d711428.tar.gz
elfutils: clean up patches
In the upgrade a large number of Upstream-Status tags were dropped, so add them back. I'm taking the stand that copying a patch Debian is carrying doesn't count as a backport. Remove two Debian-specific patches (one for Hurd, one for kfreebsd) so we're not carrying useless patches. Remove two patches that are no longer applied. (From OE-Core rev: b039b26958655aab496b588f4e41a5dea1bfaac1) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/recipes-devtools/elfutils/elfutils_0.172.bb2
-rw-r--r--meta/recipes-devtools/elfutils/files/0001-Ensure-that-packed-structs-follow-the-gcc-memory-lay.patch34
-rw-r--r--meta/recipes-devtools/elfutils/files/0001-Use-fallthrough-attribute.patch791
-rw-r--r--meta/recipes-devtools/elfutils/files/0001-libasm-may-link-with-libbz2-if-found.patch1
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0001-Ignore-differences-between-mips-machine-identifiers.patch3
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0001-arm_backend.patch2
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0001-disable_werror.patch2
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0001-fix-gcc7-ftbfs.patch2
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0001-hppa_backend.patch2
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0001-mips_backend.patch2
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0001-mips_readelf_w.patch2
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0001-testsuite-ignore-elflint.patch2
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch3
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/0003-Add-mips-n64-relocation-format-hack.patch3
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/hurd_path.patch14
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/ignore_strmerge.diff3
-rw-r--r--meta/recipes-devtools/elfutils/files/debian/kfreebsd_path.patch17
17 files changed, 20 insertions, 865 deletions
diff --git a/meta/recipes-devtools/elfutils/elfutils_0.172.bb b/meta/recipes-devtools/elfutils/elfutils_0.172.bb
index 04f6709d5a..9d02211d49 100644
--- a/meta/recipes-devtools/elfutils/elfutils_0.172.bb
+++ b/meta/recipes-devtools/elfutils/elfutils_0.172.bb
@@ -21,11 +21,9 @@ SRC_URI = "https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \
21 file://debian/0001-mips_backend.patch \ 21 file://debian/0001-mips_backend.patch \
22 file://debian/0001-testsuite-ignore-elflint.patch \ 22 file://debian/0001-testsuite-ignore-elflint.patch \
23 file://debian/0001-mips_readelf_w.patch \ 23 file://debian/0001-mips_readelf_w.patch \
24 file://debian/kfreebsd_path.patch \
25 file://debian/0001-Ignore-differences-between-mips-machine-identifiers.patch \ 24 file://debian/0001-Ignore-differences-between-mips-machine-identifiers.patch \
26 file://debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch \ 25 file://debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch \
27 file://debian/0003-Add-mips-n64-relocation-format-hack.patch \ 26 file://debian/0003-Add-mips-n64-relocation-format-hack.patch \
28 file://debian/hurd_path.patch \
29 file://debian/ignore_strmerge.diff \ 27 file://debian/ignore_strmerge.diff \
30 file://debian/0001-fix-gcc7-ftbfs.patch \ 28 file://debian/0001-fix-gcc7-ftbfs.patch \
31 file://debian/0001-disable_werror.patch \ 29 file://debian/0001-disable_werror.patch \
diff --git a/meta/recipes-devtools/elfutils/files/0001-Ensure-that-packed-structs-follow-the-gcc-memory-lay.patch b/meta/recipes-devtools/elfutils/files/0001-Ensure-that-packed-structs-follow-the-gcc-memory-lay.patch
deleted file mode 100644
index cf4d1dfe75..0000000000
--- a/meta/recipes-devtools/elfutils/files/0001-Ensure-that-packed-structs-follow-the-gcc-memory-lay.patch
+++ /dev/null
@@ -1,34 +0,0 @@
1From 732913a8c35c7b25c0cbf6903cab1ad6b602b525 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Thu, 22 Mar 2018 22:44:03 -0700
4Subject: [PATCH] Ensure that packed structs follow the gcc memory layout
5
6Partial backport of
7https://sourceware.org/git/?p=elfutils.git;a=commit;h=17d7194d291bf91d130b78e06cbe27b290e0376d
8
9Helps fixing alignment errors e.g.
10linux-core-note.c:116:1: error: alignment 2 of 'struct m68k_prstatus
11' is less than 4 [-Werror=packed-not-aligned]
12 ;
13 ^
14
15Upstream-Status: Backport [https://sourceware.org/git/?p=elfutils.git;a=commit;h=17d7194d291bf91d130b78e06cbe27b290e0376d]
16
17Signed-off-by: Khem Raj <raj.khem@gmail.com>
18---
19 backends/linux-core-note.c | 2 +-
20 1 file changed, 1 insertion(+), 1 deletion(-)
21
22diff --git a/backends/linux-core-note.c b/backends/linux-core-note.c
23index 5f06c896..9faae4c3 100644
24--- a/backends/linux-core-note.c
25+++ b/backends/linux-core-note.c
26@@ -111,7 +111,7 @@ struct EBLHOOK(prstatus)
27 FIELD (INT, pr_fpvalid);
28 }
29 #ifdef ALIGN_PRSTATUS
30- __attribute__ ((packed, aligned (ALIGN_PRSTATUS)))
31+ attribute_packed __attribute__ ((aligned (ALIGN_PRSTATUS)))
32 #endif
33 ;
34
diff --git a/meta/recipes-devtools/elfutils/files/0001-Use-fallthrough-attribute.patch b/meta/recipes-devtools/elfutils/files/0001-Use-fallthrough-attribute.patch
deleted file mode 100644
index 5e2155b3c6..0000000000
--- a/meta/recipes-devtools/elfutils/files/0001-Use-fallthrough-attribute.patch
+++ /dev/null
@@ -1,791 +0,0 @@
1From 5cb883f67d00a63531ef195c242763d36b1905ca Mon Sep 17 00:00:00 2001
2From: Joshua Watt <Joshua.Watt@garmin.com>
3Date: Fri, 9 Feb 2018 12:46:38 -0600
4Subject: [PATCH] Use fallthrough attribute
5
6Use __attribute__ ((fallthrough)) to indicate switch case fall through
7instead of a comment. This ensure that the fallthrough warning is not
8triggered even if the file is pre-processed (hence stripping the
9comments) before it is compiled.
10
11The actual fallback implementation is hidden behind a FALLBACK macro in
12case the compiler doesn't support it.
13
14Finally, the -Wimplict-fallthrough warning was upgraded to only allow
15the attribute to satisfy it; a comment alone is no longer sufficient.
16
17Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
18
19Upstream-Status: Submitted [1]
20
21[1] https://sourceware.org/ml/elfutils-devel/2018-q1/msg00027.html
22---
23 backends/aarch64_retval.c | 2 +-
24 backends/alpha_retval.c | 4 ++--
25 backends/arm_regs.c | 2 +-
26 backends/arm_retval.c | 2 +-
27 backends/i386_regs.c | 2 +-
28 backends/i386_retval.c | 4 ++--
29 backends/ia64_retval.c | 2 +-
30 backends/linux-core-note.c | 2 +-
31 backends/m68k_retval.c | 4 ++--
32 backends/mips_retval.c | 4 ++--
33 backends/parisc_retval.c | 5 +++--
34 backends/ppc64_retval.c | 6 +++---
35 backends/ppc_regs.c | 2 +-
36 backends/ppc_retval.c | 4 ++--
37 backends/s390_retval.c | 4 ++--
38 backends/sh_retval.c | 2 +-
39 backends/sparc_retval.c | 2 +-
40 backends/tilegx_retval.c | 4 ++--
41 backends/x86_64_regs.c | 2 +-
42 backends/x86_64_retval.c | 2 +-
43 config/eu.am | 4 +++-
44 configure.ac | 6 ++++++
45 lib/eu-config.h | 7 +++++++
46 libcpu/i386_disasm.c | 2 +-
47 libcpu/i386_parse.c | 4 ++--
48 libdw/cfi.c | 4 ++--
49 libdw/dwarf_frame_register.c | 2 +-
50 libdwfl/dwfl_report_elf.c | 2 +-
51 libdwfl/frame_unwind.c | 2 +-
52 libebl/eblobjnote.c | 2 +-
53 libelf/elf32_updatenull.c | 2 +-
54 libelf/elf_begin.c | 4 ++--
55 libelf/elf_cntl.c | 2 +-
56 src/addr2line.c | 2 +-
57 src/elfcompress.c | 2 +-
58 src/elflint.c | 8 ++++----
59 src/objdump.c | 2 +-
60 src/readelf.c | 8 ++++----
61 src/strings.c | 2 +-
62 tests/backtrace.c | 2 +-
63 tests/elfstrmerge.c | 3 ++-
64 41 files changed, 75 insertions(+), 58 deletions(-)
65
66diff --git a/backends/aarch64_retval.c b/backends/aarch64_retval.c
67index 68de307..1308340 100644
68--- a/backends/aarch64_retval.c
69+++ b/backends/aarch64_retval.c
70@@ -292,7 +292,7 @@ aarch64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
71 assert (count > 0);
72 if (count <= 4)
73 return pass_hfa (locp, base_size, count);
74- /* Fall through. */
75+ FALLTHROUGH;
76
77 case 1:
78 /* Not a HFA. */
79diff --git a/backends/alpha_retval.c b/backends/alpha_retval.c
80index 53dbfa4..d9bae3b 100644
81--- a/backends/alpha_retval.c
82+++ b/backends/alpha_retval.c
83@@ -85,7 +85,7 @@ alpha_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
84 typedie = dwarf_formref_die (attr, &die_mem);
85 tag = DWARF_TAG_OR_RETURN (typedie);
86 }
87- /* Fall through. */
88+ FALLTHROUGH;
89
90 case DW_TAG_base_type:
91 case DW_TAG_enumeration_type:
92@@ -131,7 +131,7 @@ alpha_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
93 }
94 }
95
96- /* Else fall through. */
97+ FALLTHROUGH;
98
99 case DW_TAG_structure_type:
100 case DW_TAG_class_type:
101diff --git a/backends/arm_regs.c b/backends/arm_regs.c
102index 4ee1039..418c931 100644
103--- a/backends/arm_regs.c
104+++ b/backends/arm_regs.c
105@@ -81,7 +81,7 @@ arm_register_info (Ebl *ebl __attribute__ ((unused)),
106 * but gcc maps FPA registers here
107 */
108 regno += 96 - 16;
109- /* Fall through. */
110+ FALLTHROUGH;
111 case 96 + 0 ... 96 + 7:
112 *setname = "FPA";
113 *type = DW_ATE_float;
114diff --git a/backends/arm_retval.c b/backends/arm_retval.c
115index 8687eab..313e4eb 100644
116--- a/backends/arm_retval.c
117+++ b/backends/arm_retval.c
118@@ -90,7 +90,7 @@ arm_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp,
119 typedie = dwarf_formref_die (attr, &die_mem);
120 tag = DWARF_TAG_OR_RETURN (typedie);
121 }
122- /* Fall through. */
123+ FALLTHROUGH;
124
125 case DW_TAG_base_type:
126 case DW_TAG_enumeration_type:
127diff --git a/backends/i386_regs.c b/backends/i386_regs.c
128index fd963a6..7ec93bb 100644
129--- a/backends/i386_regs.c
130+++ b/backends/i386_regs.c
131@@ -92,7 +92,7 @@ i386_register_info (Ebl *ebl __attribute__ ((unused)),
132 case 5:
133 case 8:
134 *type = DW_ATE_address;
135- /* Fallthrough */
136+ FALLTHROUGH;
137 case 0 ... 3:
138 case 6 ... 7:
139 name[0] = 'e';
140diff --git a/backends/i386_retval.c b/backends/i386_retval.c
141index 4aa646f..32fec72 100644
142--- a/backends/i386_retval.c
143+++ b/backends/i386_retval.c
144@@ -85,7 +85,7 @@ i386_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
145 typedie = dwarf_formref_die (attr, &die_mem);
146 tag = DWARF_TAG_OR_RETURN (typedie);
147 }
148- /* Fall through. */
149+ FALLTHROUGH;
150
151 case DW_TAG_base_type:
152 case DW_TAG_enumeration_type:
153@@ -123,7 +123,7 @@ i386_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
154 if (size <= 8)
155 return nloc_intregpair;
156 }
157- /* Fallthrough */
158+ FALLTHROUGH;
159
160 case DW_TAG_structure_type:
161 case DW_TAG_class_type:
162diff --git a/backends/ia64_retval.c b/backends/ia64_retval.c
163index dcd5f28..03ea4d8 100644
164--- a/backends/ia64_retval.c
165+++ b/backends/ia64_retval.c
166@@ -260,7 +260,7 @@ ia64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
167 typedie = dwarf_formref_die (attr, &die_mem);
168 tag = DWARF_TAG_OR_RETURN (typedie);
169 }
170- /* Fall through. */
171+ FALLTHROUGH;
172
173 case DW_TAG_base_type:
174 case DW_TAG_enumeration_type:
175diff --git a/backends/linux-core-note.c b/backends/linux-core-note.c
176index 67638d7..5f06c89 100644
177--- a/backends/linux-core-note.c
178+++ b/backends/linux-core-note.c
179@@ -226,7 +226,7 @@ EBLHOOK(core_note) (const GElf_Nhdr *nhdr, const char *name,
180 if (memcmp (name, "CORE", nhdr->n_namesz) == 0)
181 break;
182 /* Buggy old Linux kernels didn't terminate "LINUX". */
183- /* Fall through. */
184+ FALLTHROUGH;
185
186 case sizeof "LINUX":
187 if (memcmp (name, "LINUX", nhdr->n_namesz) == 0)
188diff --git a/backends/m68k_retval.c b/backends/m68k_retval.c
189index c68ed02..a653ba3 100644
190--- a/backends/m68k_retval.c
191+++ b/backends/m68k_retval.c
192@@ -92,7 +92,7 @@ m68k_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
193 typedie = dwarf_formref_die (attr, &die_mem);
194 tag = DWARF_TAG_OR_RETURN (typedie);
195 }
196- /* Fall through. */
197+ FALLTHROUGH;
198
199 case DW_TAG_base_type:
200 case DW_TAG_enumeration_type:
201@@ -135,7 +135,7 @@ m68k_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
202 if (size <= 8)
203 return nloc_intregpair;
204 }
205- /* Fallthrough */
206+ FALLTHROUGH;
207 case DW_TAG_structure_type:
208 case DW_TAG_class_type:
209 case DW_TAG_union_type:
210diff --git a/backends/mips_retval.c b/backends/mips_retval.c
211index 57487bb..c6e1ffe 100644
212--- a/backends/mips_retval.c
213+++ b/backends/mips_retval.c
214@@ -306,7 +306,7 @@ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
215 typedie = dwarf_formref_die (attr, &die_mem);
216 tag = dwarf_tag (typedie);
217 }
218- /* Fall through. */
219+ FALLTHROUGH;
220
221 case DW_TAG_base_type:
222 case DW_TAG_enumeration_type:
223@@ -389,7 +389,7 @@ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
224 }
225 }
226
227- /* Fallthrough to handle large types */
228+ FALLTHROUGH; /* Fallthrough to handle large types */
229
230 case DW_TAG_array_type:
231 large:
232diff --git a/backends/parisc_retval.c b/backends/parisc_retval.c
233index df7ec3a..1f1e91a 100644
234--- a/backends/parisc_retval.c
235+++ b/backends/parisc_retval.c
236@@ -116,7 +116,7 @@ parisc_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp, in
237 typedie = dwarf_formref_die (attr, &die_mem);
238 tag = dwarf_tag (typedie);
239 }
240- /* Fall through. */
241+ FALLTHROUGH;
242
243 case DW_TAG_base_type:
244 case DW_TAG_enumeration_type:
245@@ -167,6 +167,7 @@ parisc_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp, in
246
247 /* Else fall through. */
248 }
249+ FALLTHROUGH;
250
251 case DW_TAG_structure_type:
252 case DW_TAG_class_type:
253@@ -189,7 +190,7 @@ parisc_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp, in
254 *locp = loc_aggregate;
255 return nloc_aggregate;
256 #endif
257- /* fall through. */
258+ FALLTHROUGH;
259 }
260 }
261
262diff --git a/backends/ppc64_retval.c b/backends/ppc64_retval.c
263index a251983..eb1c11e 100644
264--- a/backends/ppc64_retval.c
265+++ b/backends/ppc64_retval.c
266@@ -96,7 +96,7 @@ ppc64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
267 typedie = dwarf_formref_die (attr, &die_mem);
268 tag = DWARF_TAG_OR_RETURN (typedie);
269 }
270- /* Fall through. */
271+ FALLTHROUGH;
272
273 case DW_TAG_base_type:
274 case DW_TAG_enumeration_type:
275@@ -141,7 +141,7 @@ ppc64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
276 return nloc_intreg;
277 }
278
279- /* Else fall through. */
280+ FALLTHROUGH;
281 case DW_TAG_structure_type:
282 case DW_TAG_class_type:
283 case DW_TAG_union_type:
284@@ -161,7 +161,7 @@ ppc64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
285 return nloc_vmxreg;
286 }
287 }
288- /* Fall through. */
289+ FALLTHROUGH;
290
291 case DW_TAG_string_type:
292 if (dwarf_aggregate_size (typedie, &size) == 0 && size <= 8)
293diff --git a/backends/ppc_regs.c b/backends/ppc_regs.c
294index c2d5011..43d2534 100644
295--- a/backends/ppc_regs.c
296+++ b/backends/ppc_regs.c
297@@ -140,7 +140,7 @@ ppc_register_info (Ebl *ebl __attribute__ ((unused)),
298 case 100:
299 if (*bits == 32)
300 return stpcpy (name, "mq") + 1 - name;
301- /* Fallthrough */
302+ FALLTHROUGH;
303 case 102 ... 107:
304 name[0] = 's';
305 name[1] = 'p';
306diff --git a/backends/ppc_retval.c b/backends/ppc_retval.c
307index b14a99f..39b42da 100644
308--- a/backends/ppc_retval.c
309+++ b/backends/ppc_retval.c
310@@ -108,7 +108,7 @@ ppc_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
311 typedie = dwarf_formref_die (attr, &die_mem);
312 tag = DWARF_TAG_OR_RETURN (typedie);
313 }
314- /* Fall through. */
315+ FALLTHROUGH;
316
317 case DW_TAG_base_type:
318 case DW_TAG_enumeration_type:
319@@ -172,7 +172,7 @@ ppc_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
320 return nloc_intregquad;
321 }
322 }
323- /* Fall through. */
324+ FALLTHROUGH;
325
326 case DW_TAG_structure_type:
327 case DW_TAG_class_type:
328diff --git a/backends/s390_retval.c b/backends/s390_retval.c
329index a927d46..2043f98 100644
330--- a/backends/s390_retval.c
331+++ b/backends/s390_retval.c
332@@ -87,7 +87,7 @@ s390_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
333 typedie = dwarf_formref_die (attr, &die_mem);
334 tag = DWARF_TAG_OR_RETURN (typedie);
335 }
336- /* Fall through. */
337+ FALLTHROUGH;
338
339 case DW_TAG_base_type:
340 case DW_TAG_enumeration_type:
341@@ -127,7 +127,7 @@ s390_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
342 return size <= asize ? nloc_intreg : nloc_intregpair;
343 }
344 }
345- /* Fall through. */
346+ FALLTHROUGH;
347
348 case DW_TAG_structure_type:
349 case DW_TAG_class_type:
350diff --git a/backends/sh_retval.c b/backends/sh_retval.c
351index d44f260..33d7d96 100644
352--- a/backends/sh_retval.c
353+++ b/backends/sh_retval.c
354@@ -84,7 +84,7 @@ sh_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
355 typedie = dwarf_formref_die (attr, &die_mem);
356 tag = DWARF_TAG_OR_RETURN (typedie);
357 }
358- /* Fall through. */
359+ FALLTHROUGH;
360
361 case DW_TAG_base_type:
362 case DW_TAG_enumeration_type:
363diff --git a/backends/sparc_retval.c b/backends/sparc_retval.c
364index e1b1775..fb81cdc 100644
365--- a/backends/sparc_retval.c
366+++ b/backends/sparc_retval.c
367@@ -91,7 +91,7 @@ sparc_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
368 typedie = dwarf_formref_die (attr, &die_mem);
369 tag = DWARF_TAG_OR_RETURN (typedie);
370 }
371- /* Fall through. */
372+ FALLTHROUGH;
373
374 case DW_TAG_base_type:
375 case DW_TAG_enumeration_type:
376diff --git a/backends/tilegx_retval.c b/backends/tilegx_retval.c
377index db81a20..7f7d24b 100644
378--- a/backends/tilegx_retval.c
379+++ b/backends/tilegx_retval.c
380@@ -79,7 +79,7 @@ tilegx_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
381 typedie = dwarf_formref_die (attr, &die_mem);
382 tag = DWARF_TAG_OR_RETURN (typedie);
383 }
384- /* Fall through. */
385+ FALLTHROUGH;
386
387 case DW_TAG_base_type:
388 case DW_TAG_enumeration_type:
389@@ -113,7 +113,7 @@ tilegx_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
390 return nloc_intreg;
391 }
392
393- /* Else fall through. */
394+ FALLTHROUGH;
395 case DW_TAG_structure_type:
396 case DW_TAG_class_type:
397 case DW_TAG_union_type:
398diff --git a/backends/x86_64_regs.c b/backends/x86_64_regs.c
399index 8430440..ef987da 100644
400--- a/backends/x86_64_regs.c
401+++ b/backends/x86_64_regs.c
402@@ -87,7 +87,7 @@ x86_64_register_info (Ebl *ebl __attribute__ ((unused)),
403
404 case 6 ... 7:
405 *type = DW_ATE_address;
406- /* Fallthrough */
407+ FALLTHROUGH;
408 case 0 ... 5:
409 name[0] = 'r';
410 name[1] = baseregs[regno][0];
411diff --git a/backends/x86_64_retval.c b/backends/x86_64_retval.c
412index b3799ae..f9114cb 100644
413--- a/backends/x86_64_retval.c
414+++ b/backends/x86_64_retval.c
415@@ -100,7 +100,7 @@ x86_64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
416 typedie = dwarf_formref_die (attr, &die_mem);
417 tag = DWARF_TAG_OR_RETURN (typedie);
418 }
419- /* Fall through. */
420+ FALLTHROUGH;
421
422 case DW_TAG_base_type:
423 case DW_TAG_enumeration_type:
424diff --git a/config/eu.am b/config/eu.am
425index 8fe1e25..b6ec581 100644
426--- a/config/eu.am
427+++ b/config/eu.am
428@@ -62,7 +62,9 @@ NULL_DEREFERENCE_WARNING=
429 endif
430
431 if HAVE_IMPLICIT_FALLTHROUGH_WARNING
432-IMPLICIT_FALLTHROUGH_WARNING=-Wimplicit-fallthrough
433+# Use strict fallthrough. Only __attribute__((fallthrough)) will prevent the
434+# warning
435+IMPLICIT_FALLTHROUGH_WARNING=-Wimplicit-fallthrough=5
436 else
437 IMPLICIT_FALLTHROUGH_WARNING=
438 endif
439diff --git a/configure.ac b/configure.ac
440index 1f1856d..698efbb 100644
441--- a/configure.ac
442+++ b/configure.ac
443@@ -360,6 +360,12 @@ CFLAGS="$old_CFLAGS"])
444 AM_CONDITIONAL(HAVE_IMPLICIT_FALLTHROUGH_WARNING,
445 [test "x$ac_cv_implicit_fallthrough" != "xno"])
446
447+# Assume the fallthrough attribute is supported if -Wimplict-fallthrough is supported
448+if test "$ac_cv_implicit_fallthrough" = "yes"; then
449+ AC_DEFINE([HAVE_FALLTHROUGH], [1],
450+ [Defined if __attribute__((fallthrough)) is supported])
451+fi
452+
453 dnl Check if we have argp available from our libc
454 AC_LINK_IFELSE(
455 [AC_LANG_PROGRAM(
456diff --git a/lib/eu-config.h b/lib/eu-config.h
457index 400cdc6..e8d4ec2 100644
458--- a/lib/eu-config.h
459+++ b/lib/eu-config.h
460@@ -186,5 +186,12 @@ asm (".section predict_data, \"aw\"; .previous\n"
461 # define COMPAT_VERSION(name, version, prefix) error "should use #ifdef SYMBOL_VERSIONING"
462 #endif
463
464+#ifndef FALLTHROUGH
465+# ifdef HAVE_FALLTHROUGH
466+# define FALLTHROUGH __attribute__ ((fallthrough))
467+# else
468+# define FALLTHROUGH ((void) 0)
469+# endif
470+#endif
471
472 #endif /* eu-config.h */
473diff --git a/libcpu/i386_disasm.c b/libcpu/i386_disasm.c
474index 60fd6d4..837a3a8 100644
475--- a/libcpu/i386_disasm.c
476+++ b/libcpu/i386_disasm.c
477@@ -819,7 +819,7 @@ i386_disasm (Ebl *ebl __attribute__((unused)),
478 ++param_start;
479 break;
480 }
481- /* Fallthrough */
482+ FALLTHROUGH;
483 default:
484 str = "";
485 assert (! "INVALID not handled");
486diff --git a/libcpu/i386_parse.c b/libcpu/i386_parse.c
487index ef1ac35..6fa7ce3 100644
488--- a/libcpu/i386_parse.c
489+++ b/libcpu/i386_parse.c
490@@ -1047,7 +1047,7 @@ yytnamerr (char *yyres, const char *yystr)
491 case '\\':
492 if (*++yyp != '\\')
493 goto do_not_strip_quotes;
494- /* Fall through. */
495+ FALLTHROUGH;
496 default:
497 if (yyres)
498 yyres[yyn] = *yyp;
499@@ -2042,7 +2042,7 @@ yyabortlab:
500 yyexhaustedlab:
501 yyerror (YY_("memory exhausted"));
502 yyresult = 2;
503- /* Fall through. */
504+ FALLTHROUGH;
505 #endif
506
507 yyreturn:
508diff --git a/libdw/cfi.c b/libdw/cfi.c
509index daa845f..341e055 100644
510--- a/libdw/cfi.c
511+++ b/libdw/cfi.c
512@@ -138,7 +138,7 @@ execute_cfi (Dwarf_CFI *cache,
513
514 case DW_CFA_advance_loc1:
515 operand = *program++;
516- /* Fallthrough */
517+ FALLTHROUGH;
518 case DW_CFA_advance_loc + 0 ... DW_CFA_advance_loc + CFI_PRIMARY_MAX:
519 advance_loc:
520 loc += operand * cie->code_alignment_factor;
521@@ -301,7 +301,7 @@ execute_cfi (Dwarf_CFI *cache,
522
523 case DW_CFA_restore_extended:
524 get_uleb128 (operand, program, end);
525- /* Fallthrough */
526+ FALLTHROUGH;
527 case DW_CFA_restore + 0 ... DW_CFA_restore + CFI_PRIMARY_MAX:
528
529 if (unlikely (abi_cfi) && likely (opcode == DW_CFA_restore))
530diff --git a/libdw/dwarf_frame_register.c b/libdw/dwarf_frame_register.c
531index 37e8e91..d0159fb 100644
532--- a/libdw/dwarf_frame_register.c
533+++ b/libdw/dwarf_frame_register.c
534@@ -62,7 +62,7 @@ dwarf_frame_register (Dwarf_Frame *fs, int regno, Dwarf_Op *ops_mem,
535 /* Use the default rule for registers not yet mentioned in CFI. */
536 if (fs->cache->default_same_value)
537 goto same_value;
538- /*FALLTHROUGH*/
539+ FALLTHROUGH;
540 case reg_undefined:
541 /* The value is known to be unavailable. */
542 break;
543diff --git a/libdwfl/dwfl_report_elf.c b/libdwfl/dwfl_report_elf.c
544index 6950a37..3fc9384 100644
545--- a/libdwfl/dwfl_report_elf.c
546+++ b/libdwfl/dwfl_report_elf.c
547@@ -174,7 +174,7 @@ __libdwfl_elf_address_range (Elf *elf, GElf_Addr base, bool add_p_vaddr,
548 /* An assigned base address is meaningless for these. */
549 base = 0;
550 add_p_vaddr = true;
551- /* Fallthrough. */
552+ FALLTHROUGH;
553 case ET_DYN:
554 default:;
555 size_t phnum;
556diff --git a/libdwfl/frame_unwind.c b/libdwfl/frame_unwind.c
557index 4dc9c43..eaea495 100644
558--- a/libdwfl/frame_unwind.c
559+++ b/libdwfl/frame_unwind.c
560@@ -442,7 +442,7 @@ expr_eval (Dwfl_Frame *state, Dwarf_Frame *frame, const Dwarf_Op *ops,
561 }
562 if (val1 == 0)
563 break;
564- /* FALLTHRU */
565+ FALLTHROUGH;
566 case DW_OP_skip:;
567 Dwarf_Word offset = op->offset + 1 + 2 + (int16_t) op->number;
568 const Dwarf_Op *found = bsearch ((void *) (uintptr_t) offset, ops, nops,
569diff --git a/libebl/eblobjnote.c b/libebl/eblobjnote.c
570index f80a1a5..ca4f155 100644
571--- a/libebl/eblobjnote.c
572+++ b/libebl/eblobjnote.c
573@@ -223,7 +223,7 @@ ebl_object_note (Ebl *ebl, const char *name, uint32_t type,
574 free (buf);
575 break;
576 }
577- /* FALLTHROUGH */
578+ FALLTHROUGH;
579
580 default:
581 /* Unknown type. */
582diff --git a/libelf/elf32_updatenull.c b/libelf/elf32_updatenull.c
583index a51bf70..5351518 100644
584--- a/libelf/elf32_updatenull.c
585+++ b/libelf/elf32_updatenull.c
586@@ -232,7 +232,7 @@ __elfw2(LIBELFBITS,updatenull_wrlock) (Elf *elf, int *change_bop, size_t shnum)
587 __libelf_seterrno (ELF_E_GROUP_NOT_REL);
588 return -1;
589 }
590- /* FALLTHROUGH */
591+ FALLTHROUGH;
592 case SHT_SYMTAB_SHNDX:
593 sh_entsize = elf_typesize (32, ELF_T_WORD, 1);
594 break;
595diff --git a/libelf/elf_begin.c b/libelf/elf_begin.c
596index 6f85038..6de206a 100644
597--- a/libelf/elf_begin.c
598+++ b/libelf/elf_begin.c
599@@ -582,7 +582,7 @@ read_unmmaped_file (int fildes, off_t offset, size_t maxsize, Elf_Cmd cmd,
600 ? sizeof (Elf32_Ehdr) : sizeof (Elf64_Ehdr)))
601 return file_read_elf (fildes, NULL, mem.header, offset, maxsize, cmd,
602 parent);
603- /* FALLTHROUGH */
604+ FALLTHROUGH;
605
606 default:
607 break;
608@@ -1097,7 +1097,7 @@ elf_begin (int fildes, Elf_Cmd cmd, Elf *ref)
609 retval = NULL;
610 break;
611 }
612- /* FALLTHROUGH */
613+ FALLTHROUGH;
614
615 case ELF_C_READ:
616 case ELF_C_READ_MMAP:
617diff --git a/libelf/elf_cntl.c b/libelf/elf_cntl.c
618index ab13ffb..fd68178 100644
619--- a/libelf/elf_cntl.c
620+++ b/libelf/elf_cntl.c
621@@ -62,7 +62,7 @@ elf_cntl (Elf *elf, Elf_Cmd cmd)
622 result = -1;
623 break;
624 }
625- /* FALLTHROUGH */
626+ FALLTHROUGH;
627
628 case ELF_C_FDDONE:
629 /* Mark the file descriptor as not usable. */
630diff --git a/src/addr2line.c b/src/addr2line.c
631index ba414a7..444ee52 100644
632--- a/src/addr2line.c
633+++ b/src/addr2line.c
634@@ -618,7 +618,7 @@ handle_address (const char *string, Dwfl *dwfl)
635 case 1:
636 addr = 0;
637 j = i;
638- /* Fallthrough */
639+ FALLTHROUGH;
640 case 2:
641 if (string[j] != '\0')
642 break;
643diff --git a/src/elfcompress.c b/src/elfcompress.c
644index 8e0d5c5..25378a4 100644
645--- a/src/elfcompress.c
646+++ b/src/elfcompress.c
647@@ -149,7 +149,7 @@ parse_opt (int key, char *arg __attribute__ ((unused)),
648 N_("Only one input file allowed together with '-o'"));
649 /* We only use this for checking the number of arguments, we don't
650 actually want to consume them. */
651- /* Fallthrough */
652+ FALLTHROUGH;
653 default:
654 return ARGP_ERR_UNKNOWN;
655 }
656diff --git a/src/elflint.c b/src/elflint.c
657index 51e53c2..df1b3a0 100644
658--- a/src/elflint.c
659+++ b/src/elflint.c
660@@ -1764,7 +1764,7 @@ section [%2d] '%s': entry %zu: pointer does not match address of section [%2d] '
661 if (dyn->d_tag < DT_ADDRRNGLO || dyn->d_tag > DT_ADDRRNGHI)
662 /* Value is no pointer. */
663 break;
664- /* FALLTHROUGH */
665+ FALLTHROUGH;
666
667 case DT_AUXILIARY:
668 case DT_FILTER:
669@@ -3993,7 +3993,7 @@ section [%2zu] '%s': merge flag set but entry size is zero\n"),
670 case SHT_NOBITS:
671 if (is_debuginfo)
672 break;
673- /* Fallthrough */
674+ FALLTHROUGH;
675 default:
676 ERROR (gettext ("\
677 section [%2zu] '%s' has unexpected type %d for an executable section\n"),
678@@ -4137,7 +4137,7 @@ section [%2zu] '%s': ELF header says this is the section header string table but
679 ERROR (gettext ("\
680 section [%2zu] '%s': relocatable files cannot have dynamic symbol tables\n"),
681 cnt, section_name (ebl, cnt));
682- /* FALLTHROUGH */
683+ FALLTHROUGH;
684 case SHT_SYMTAB:
685 check_symtab (ebl, ehdr, shdr, cnt);
686 break;
687@@ -4336,7 +4336,7 @@ section [%2d] '%s': unknown core file note type %" PRIu32
688 if (nhdr.n_namesz == sizeof "Linux"
689 && !memcmp (data->d_buf + name_offset, "Linux", sizeof "Linux"))
690 break;
691- /* Fallthrough */
692+ FALLTHROUGH;
693 default:
694 if (shndx == 0)
695 ERROR (gettext ("\
696diff --git a/src/objdump.c b/src/objdump.c
697index 860cfac..0dd9a6a 100644
698--- a/src/objdump.c
699+++ b/src/objdump.c
700@@ -223,7 +223,7 @@ parse_opt (int key, char *arg,
701 }
702 /* We only use this for checking the number of arguments, we don't
703 actually want to consume them. */
704- /* Fallthrough */
705+ FALLTHROUGH;
706 default:
707 return ARGP_ERR_UNKNOWN;
708 }
709diff --git a/src/readelf.c b/src/readelf.c
710index 346eccd..6a27e7e 100644
711--- a/src/readelf.c
712+++ b/src/readelf.c
713@@ -465,7 +465,7 @@ parse_opt (int key, char *arg,
714 print_string_sections = true;
715 break;
716 }
717- /* Fall through. */
718+ FALLTHROUGH;
719 case 'x':
720 add_dump_section (arg, false);
721 any_control_option = true;
722@@ -6029,7 +6029,7 @@ attr_callback (Dwarf_Attribute *attrp, void *arg)
723 dwarf_form_name (form), (uintmax_t) num);
724 return DWARF_CB_OK;
725 }
726- /* else fallthrough */
727+ FALLTHROUGH;
728
729 /* These cases always take a loclistptr and no constant. */
730 case DW_AT_location:
731@@ -6195,7 +6195,7 @@ attr_callback (Dwarf_Attribute *attrp, void *arg)
732 print_block (block.length, block.data);
733 break;
734 }
735- /* Fall through. */
736+ FALLTHROUGH;
737
738 case DW_AT_location:
739 case DW_AT_data_location:
740@@ -9227,7 +9227,7 @@ handle_auxv_note (Ebl *ebl, Elf *core, GElf_Word descsz, GElf_Off desc_pos)
741 printf (" %s\n", name);
742 break;
743 }
744- /* Fall through */
745+ FALLTHROUGH;
746 case 'x': /* hex */
747 case 'p': /* address */
748 case 's': /* address of string */
749diff --git a/src/strings.c b/src/strings.c
750index d214356..03d0f13 100644
751--- a/src/strings.c
752+++ b/src/strings.c
753@@ -246,7 +246,7 @@ parse_opt (int key, char *arg,
754 case 'b':
755 case 'B':
756 big_endian = true;
757- /* FALLTHROUGH */
758+ FALLTHROUGH;
759
760 case 'l':
761 case 'L':
762diff --git a/tests/backtrace.c b/tests/backtrace.c
763index 21abe8a..f5dd761 100644
764--- a/tests/backtrace.c
765+++ b/tests/backtrace.c
766@@ -127,7 +127,7 @@ callback_verify (pid_t tid, unsigned frameno, Dwarf_Addr pc,
767 assert (symname2 == NULL || strcmp (symname2, "jmp") != 0);
768 break;
769 }
770- /* FALLTHRU */
771+ FALLTHROUGH;
772 case 4:
773 /* Some simple frame unwinders get this wrong and think sigusr2
774 is calling itself again. Allow it and just pretend there is
775diff --git a/tests/elfstrmerge.c b/tests/elfstrmerge.c
776index 8d5b53c..62c549d 100644
777--- a/tests/elfstrmerge.c
778+++ b/tests/elfstrmerge.c
779@@ -578,7 +578,8 @@ main (int argc, char **argv)
780 break;
781
782 case SHT_DYNAMIC:
783- /* Fallthrough. There are string indexes in here, but
784+ FALLTHROUGH;
785+ /* There are string indexes in here, but
786 they (should) point to a allocated string table,
787 which we don't alter. */
788 default:
789--
7902.14.3
791
diff --git a/meta/recipes-devtools/elfutils/files/0001-libasm-may-link-with-libbz2-if-found.patch b/meta/recipes-devtools/elfutils/files/0001-libasm-may-link-with-libbz2-if-found.patch
index a8e9e50d15..c342053aac 100644
--- a/meta/recipes-devtools/elfutils/files/0001-libasm-may-link-with-libbz2-if-found.patch
+++ b/meta/recipes-devtools/elfutils/files/0001-libasm-may-link-with-libbz2-if-found.patch
@@ -9,6 +9,7 @@ where indirect libraries may be not found by linker
9| /mnt/a/oe/build/tmp/work/riscv64-bec-linux/elfutils/0.170-r0/recipe-sysroot/usr/lib/libbz2.so.1: error adding symbols: DSO missing from command line 9| /mnt/a/oe/build/tmp/work/riscv64-bec-linux/elfutils/0.170-r0/recipe-sysroot/usr/lib/libbz2.so.1: error adding symbols: DSO missing from command line
10| collect2: error: ld returned 1 exit status 10| collect2: error: ld returned 1 exit status
11 11
12Upstream-Status: Pending
12Signed-off-by: Khem Raj <raj.khem@gmail.com> 13Signed-off-by: Khem Raj <raj.khem@gmail.com>
13--- 14---
14 src/Makefile.am | 4 ++-- 15 src/Makefile.am | 4 ++--
diff --git a/meta/recipes-devtools/elfutils/files/debian/0001-Ignore-differences-between-mips-machine-identifiers.patch b/meta/recipes-devtools/elfutils/files/debian/0001-Ignore-differences-between-mips-machine-identifiers.patch
index a9a7210031..8c48f4d1b1 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0001-Ignore-differences-between-mips-machine-identifiers.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0001-Ignore-differences-between-mips-machine-identifiers.patch
@@ -1,3 +1,6 @@
1Upstream-Status: Pending [from debian]
2Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
3
1From 77cb4a53c270d5854d3af24f19547bc3de825233 Mon Sep 17 00:00:00 2001 4From 77cb4a53c270d5854d3af24f19547bc3de825233 Mon Sep 17 00:00:00 2001
2From: James Cowgill <james410@cowgill.org.uk> 5From: James Cowgill <james410@cowgill.org.uk>
3Date: Mon, 5 Jan 2015 15:16:58 +0000 6Date: Mon, 5 Jan 2015 15:16:58 +0000
diff --git a/meta/recipes-devtools/elfutils/files/debian/0001-arm_backend.patch b/meta/recipes-devtools/elfutils/files/debian/0001-arm_backend.patch
index 540ba95e0e..4ed81194b3 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0001-arm_backend.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0001-arm_backend.patch
@@ -3,7 +3,7 @@ From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Fri, 29 Jun 2018 15:42:39 +0800 3Date: Fri, 29 Jun 2018 15:42:39 +0800
4Subject: [PATCH] arm_backend 4Subject: [PATCH] arm_backend
5 5
6Upstream-Status: Backport from debian 6Upstream-Status: Pending [from debian]
7arm_backend.diff and rebase to 0.172 7arm_backend.diff and rebase to 0.172
8 8
9http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz 9http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
diff --git a/meta/recipes-devtools/elfutils/files/debian/0001-disable_werror.patch b/meta/recipes-devtools/elfutils/files/debian/0001-disable_werror.patch
index 66de238418..0f32b8742c 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0001-disable_werror.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0001-disable_werror.patch
@@ -8,7 +8,7 @@ Last-Update: 2018-01-01
8 8
9Signed-off-by: Helmut Grohne <helmut@subdivi.de> 9Signed-off-by: Helmut Grohne <helmut@subdivi.de>
10 10
11Upstream-Status: Backport from debian 11Upstream-Status: Pending [from debian]
12mdisable_werror.patc and rebase to 0.172 12mdisable_werror.patc and rebase to 0.172
13 13
14http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz 14http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
diff --git a/meta/recipes-devtools/elfutils/files/debian/0001-fix-gcc7-ftbfs.patch b/meta/recipes-devtools/elfutils/files/debian/0001-fix-gcc7-ftbfs.patch
index 226ec7f530..26869a3a7d 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0001-fix-gcc7-ftbfs.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0001-fix-gcc7-ftbfs.patch
@@ -3,7 +3,7 @@ From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Fri, 29 Jun 2018 15:59:57 +0800 3Date: Fri, 29 Jun 2018 15:59:57 +0800
4Subject: [PATCH] fix gcc7 ftbfs 4Subject: [PATCH] fix gcc7 ftbfs
5 5
6Upstream-Status: Backport from debian 6Upstream-Status: Pending [from debian]
7fix-gcc7-ftbfs.diff and rebase to 0.172 7fix-gcc7-ftbfs.diff and rebase to 0.172
8 8
9http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz 9http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
diff --git a/meta/recipes-devtools/elfutils/files/debian/0001-hppa_backend.patch b/meta/recipes-devtools/elfutils/files/debian/0001-hppa_backend.patch
index c0dbed798d..2c5d4fa4ba 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0001-hppa_backend.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0001-hppa_backend.patch
@@ -3,7 +3,7 @@ From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Fri, 29 Jun 2018 15:39:46 +0800 3Date: Fri, 29 Jun 2018 15:39:46 +0800
4Subject: [PATCH] hppa_backend 4Subject: [PATCH] hppa_backend
5 5
6Upstream-Status: Backport from debian 6Upstream-Status: Pending [from debian]
7hppa_backend.diff and rebase to 0.172 7hppa_backend.diff and rebase to 0.172
8 8
9http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz 9http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
diff --git a/meta/recipes-devtools/elfutils/files/debian/0001-mips_backend.patch b/meta/recipes-devtools/elfutils/files/debian/0001-mips_backend.patch
index 3004e19828..d04da72cc5 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0001-mips_backend.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0001-mips_backend.patch
@@ -3,7 +3,7 @@ From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Fri, 29 Jun 2018 15:45:58 +0800 3Date: Fri, 29 Jun 2018 15:45:58 +0800
4Subject: [PATCH] mips_backend 4Subject: [PATCH] mips_backend
5 5
6Upstream-Status: Backport from debian 6Upstream-Status: Pending [from debian]
7mips_backend.diff and rebase to 0.172 7mips_backend.diff and rebase to 0.172
8 8
9http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz 9http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
diff --git a/meta/recipes-devtools/elfutils/files/debian/0001-mips_readelf_w.patch b/meta/recipes-devtools/elfutils/files/debian/0001-mips_readelf_w.patch
index 294944ea54..f3ab3da8d2 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0001-mips_readelf_w.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0001-mips_readelf_w.patch
@@ -11,7 +11,7 @@ to be filled in by the backend for the arch.
11 11
12Signed-off-by: Kurt Roeckx <kurt@roeckx.be> 12Signed-off-by: Kurt Roeckx <kurt@roeckx.be>
13 13
14Upstream-Status: Backport from debian 14Upstream-Status: Pending [from debian]
15mips_readelf_w.patch and rebase to 0.172 15mips_readelf_w.patch and rebase to 0.172
16 16
17http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz 17http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
diff --git a/meta/recipes-devtools/elfutils/files/debian/0001-testsuite-ignore-elflint.patch b/meta/recipes-devtools/elfutils/files/debian/0001-testsuite-ignore-elflint.patch
index 14f6909378..f4c6f40fc5 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0001-testsuite-ignore-elflint.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0001-testsuite-ignore-elflint.patch
@@ -9,7 +9,7 @@ binutils don't pass elflint. However elfutils shouldn't FTBFS because of this.
9So we run the tests on all archs to see what breaks, but if it breaks we ignore 9So we run the tests on all archs to see what breaks, but if it breaks we ignore
10the result (exitcode 77 means: this test was skipped). 10the result (exitcode 77 means: this test was skipped).
11 11
12Upstream-Status: Backport from debian 12Upstream-Status: Pending [from debian]
13testsuite-ignore-elflint.diff and rebase to 0.172 13testsuite-ignore-elflint.diff and rebase to 0.172
14 14
15Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> 15Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
diff --git a/meta/recipes-devtools/elfutils/files/debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch b/meta/recipes-devtools/elfutils/files/debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch
index 72125c9ff0..4bdb1ff3cf 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch
@@ -1,3 +1,6 @@
1Upstream-Status: Pending [from debian]
2Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
3
1From fdaab18a65ed2529656baa64cb6169f34d7e507b Mon Sep 17 00:00:00 2001 4From fdaab18a65ed2529656baa64cb6169f34d7e507b Mon Sep 17 00:00:00 2001
2From: James Cowgill <james410@cowgill.org.uk> 5From: James Cowgill <james410@cowgill.org.uk>
3Date: Mon, 5 Jan 2015 15:17:01 +0000 6Date: Mon, 5 Jan 2015 15:17:01 +0000
diff --git a/meta/recipes-devtools/elfutils/files/debian/0003-Add-mips-n64-relocation-format-hack.patch b/meta/recipes-devtools/elfutils/files/debian/0003-Add-mips-n64-relocation-format-hack.patch
index 6c0ae37fea..d27ce6dc9c 100644
--- a/meta/recipes-devtools/elfutils/files/debian/0003-Add-mips-n64-relocation-format-hack.patch
+++ b/meta/recipes-devtools/elfutils/files/debian/0003-Add-mips-n64-relocation-format-hack.patch
@@ -1,3 +1,6 @@
1Upstream-Status: Pending [from debian]
2Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
3
1From 59d4b8c48e5040af7e02b34eb26ea602ec82a38e Mon Sep 17 00:00:00 2001 4From 59d4b8c48e5040af7e02b34eb26ea602ec82a38e Mon Sep 17 00:00:00 2001
2From: James Cowgill <james410@cowgill.org.uk> 5From: James Cowgill <james410@cowgill.org.uk>
3Date: Mon, 5 Jan 2015 15:17:02 +0000 6Date: Mon, 5 Jan 2015 15:17:02 +0000
diff --git a/meta/recipes-devtools/elfutils/files/debian/hurd_path.patch b/meta/recipes-devtools/elfutils/files/debian/hurd_path.patch
deleted file mode 100644
index 4440e39e0a..0000000000
--- a/meta/recipes-devtools/elfutils/files/debian/hurd_path.patch
+++ /dev/null
@@ -1,14 +0,0 @@
1Index: elfutils-0.165/tests/run-native-test.sh
2===================================================================
3--- elfutils-0.165.orig/tests/run-native-test.sh
4+++ elfutils-0.165/tests/run-native-test.sh
5@@ -83,6 +83,9 @@ native_test()
6 # "cannot attach to process: Function not implemented".
7 [ "$(uname)" = "GNU/kFreeBSD" ] && exit 77
8
9+# hurd's /proc/$PID/maps does not give paths yet.
10+[ "$(uname)" = "GNU" ] && exit 77
11+
12 native_test ${abs_builddir}/allregs
13 native_test ${abs_builddir}/funcretval
14
diff --git a/meta/recipes-devtools/elfutils/files/debian/ignore_strmerge.diff b/meta/recipes-devtools/elfutils/files/debian/ignore_strmerge.diff
index 1e6d7a2de6..55513eeddc 100644
--- a/meta/recipes-devtools/elfutils/files/debian/ignore_strmerge.diff
+++ b/meta/recipes-devtools/elfutils/files/debian/ignore_strmerge.diff
@@ -1,3 +1,6 @@
1Upstream-Status: Pending [from debian]
2Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
3
1--- elfutils-0.165.orig/tests/run-strip-strmerge.sh 4--- elfutils-0.165.orig/tests/run-strip-strmerge.sh
2+++ elfutils-0.165/tests/run-strip-strmerge.sh 5+++ elfutils-0.165/tests/run-strip-strmerge.sh
3@@ -30,7 +30,7 @@ remerged=remerged.elf 6@@ -30,7 +30,7 @@ remerged=remerged.elf
diff --git a/meta/recipes-devtools/elfutils/files/debian/kfreebsd_path.patch b/meta/recipes-devtools/elfutils/files/debian/kfreebsd_path.patch
deleted file mode 100644
index 9a19b58b50..0000000000
--- a/meta/recipes-devtools/elfutils/files/debian/kfreebsd_path.patch
+++ /dev/null
@@ -1,17 +0,0 @@
1Index: b/tests/run-native-test.sh
2===================================================================
3--- a/tests/run-native-test.sh
4+++ b/tests/run-native-test.sh
5@@ -77,6 +77,12 @@ native_test()
6 test $native -eq 0 || testrun "$@" -p $native > /dev/null
7 }
8
9+# On the Debian buildds, GNU/kFreeBSD linprocfs /proc/$PID/maps does
10+# not give absolute paths due to sbuild's bind mounts (bug #570805)
11+# therefore the next two test programs are expected to fail with
12+# "cannot attach to process: Function not implemented".
13+[ "$(uname)" = "GNU/kFreeBSD" ] && exit 77
14+
15 native_test ${abs_builddir}/allregs
16 native_test ${abs_builddir}/funcretval
17