summaryrefslogtreecommitdiffstats
path: root/meta-xilinx-bsp/recipes-microblaze/binutils/binutils/0026-Patch-Microblaze-changes-of-PR22458-failure-to-choos.patch
blob: aef46b3f9eac6e1492c0c69b1e92537070641b00 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
From e7f43c3afe90faa42c09f368671972c26c2b7b38 Mon Sep 17 00:00:00 2001
From: Mahesh Bodapati <mbodapat@xilinx.com>
Date: Tue, 26 Feb 2019 17:31:41 +0530
Subject: [PATCH 26/43] [Patch,Microblaze] : changes of "PR22458, failure to
 choose a matching ELF target"     is causing "Multiple Prevailing definition
 errors",added check for best_match elf.

---
 bfd/format.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/bfd/format.c b/bfd/format.c
index 97a92291a8..3a74cc49d2 100644
--- a/bfd/format.c
+++ b/bfd/format.c
@@ -292,7 +292,12 @@ bfd_check_format_matches (bfd *abfd, bfd_format format, char ***matching)
 
       /* Don't check the default target twice.  */
       if (*target == &binary_vec
+#if !BFD_SUPPORTS_PLUGINS
 	  || (!abfd->target_defaulted && *target == save_targ))
+#else
+	  || (!abfd->target_defaulted && *target == save_targ)
+	  || (*target)->match_priority > best_match)
+#endif
 	continue;
 
       /* If we already tried a match, the bfd is modified and may
-- 
2.17.1