PR82575, lto debugobj references __gnu_lto_slim, ld test liblto-17 fails
If __gnu_lto_slim is global, undefined, default visibility in the
early debug object, then it finds its way into .dynsym when creating
shared libraries. __gnu_lto_slim in a symbol table (.dynsym or
.symtab) signals nm and other binutils that the object is an LTO
object needing a plugin, but that isn't the case for the ld liblti-17
tests. So, make __gnu_lto_slim hidden to prevent it becoming
dynamic. Further, make it weak because some linkers may warn on
finding an undefined global non-default visibility symbol.
PR lto/82575
* simple-object-elf.c (simple_object_elf_copy_lto_debug_sections):
Make discarded non-local symbols weak and hidden.
From-SVN: r253914