public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* Re: ld: Always output local symbol for relocatable link
@ 2022-11-21 21:21 Alan Modra
  0 siblings, 0 replies; only message in thread
From: Alan Modra @ 2022-11-21 21:21 UTC (permalink / raw)
  To: binutils; +Cc: H.J. Lu

Remove this code dating back to commit 98790d3a95fc entirely, what it
was trying to do is done elsewhere.

	PR ld/29761
	* elflink.c (elf_link_output_symstrtab): Don't handle symbols
	in SEC_EXCLUDE sections here.

diff --git a/bfd/elflink.c b/bfd/elflink.c
index 81b34129463..a141c9eb0e8 100644
--- a/bfd/elflink.c
+++ b/bfd/elflink.c
@@ -9995,10 +9995,7 @@ elf_link_output_symstrtab (void *finf,
   if (ELF_ST_BIND (elfsym->st_info) == STB_GNU_UNIQUE)
     elf_tdata (flinfo->output_bfd)->has_gnu_osabi |= elf_gnu_osabi_unique;
 
-  if (name == NULL
-      || *name == '\0'
-      || (!bfd_link_relocatable (flinfo->info)
-	  && (input_sec->flags & SEC_EXCLUDE)))
+  if (name == NULL || *name == '\0')
     elfsym->st_name = (unsigned long) -1;
   else
     {

-- 
Alan Modra
Australia Development Lab, IBM

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-11-21 21:21 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-21 21:21 ld: Always output local symbol for relocatable link Alan Modra

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).