https://sourceware.org/bugzilla/show_bug.cgi?id=24267

--- Comment #11 from Martin Liška <marxin.liska at gmail dot com> ---
I've got a patch candidate that can solve it:

diff --git a/bfd/coffgen.c b/bfd/coffgen.c
index 309e1249ac..1d200b066b 100644
--- a/bfd/coffgen.c
+++ b/bfd/coffgen.c
@@ -2678,9 +2678,9 @@ _bfd_coff_section_already_linked (bfd *abfd,
         and match any comdat section with comdat name of <key>, and
         any linkonce section with the same suffix, ie.
         .gnu.linkonce.*.<key>.  */
-      if (((s_comdat != NULL) == (l_comdat != NULL)
-          && strcmp (name, l->sec->name) == 0)
-         || (l->sec->owner->flags & BFD_PLUGIN) != 0)
+      if (((s_comdat != NULL) == (l_comdat != NULL))
+          && ((strcmp (name, l->sec->name) == 0)
+            || (l->sec->owner->flags & BFD_PLUGIN) != 0))
        {
          /* The section has already been linked.  See if we should
             issue a warning.  */

However, Honza is still thinking that LDPR_PREVAILING_DEF_IRONLY should be used
for the symbol. If I see correctly it's set in ld/plugin.c base on
 else if (owner_sec->owner == abfd).

Can you please help me where sections are set for each symbol? Is it a COFF
specific code?

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to