[PATCH] MIPS: Set has_local_dynsyms to true

YunQiang Su yunqiang@isrc.iscas.ac.cn
Wed Jan 14 06:00:01 GMT 2026


From: YunQiang Su <syq@gcc.gnu.org>

    commit 54fbc12d6404b645363f901110a21f4410067df5
    Author: H.J. Lu <hjl.tools@gmail.com>
    Date:   Fri Nov 28 16:07:57 2025 +0800

        elf: Renumber local dynamic symbols only if needed

While MIPS depends on this behaviour.
If not so, we meet a problem when build glibc:
  mips-linux-gnu-ld: BFD (GNU Binutils) 2.45.50.20260113 assertion fail ../../bfd/elfxx-mips.c:4038
when link
  test-run-command
---
 bfd/elfxx-mips.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
index 34f58c311c1..ae4b8871202 100644
--- a/bfd/elfxx-mips.c
+++ b/bfd/elfxx-mips.c
@@ -14493,6 +14493,7 @@ _bfd_mips_elf_link_hash_table_create (bfd *abfd)
     }
   ret->root.init_plt_refcount.plist = NULL;
   ret->root.init_plt_offset.plist = NULL;
+  ret->root.has_local_dynsyms = true;
 
   return &ret->root.root;
 }
-- 
2.52.0



More information about the Binutils mailing list