1 2006-12-06 H.J. Lu <hjl@gnu.org>
4 * elflink.c (elf_link_add_object_symbols): Keep symbol
5 visibility for symbols from discarded section.
7 --- binutils/bfd/elflink.c.merge 2006-12-06 06:43:24.000000000 -0800
8 +++ binutils/bfd/elflink.c 2006-12-06 07:10:18.000000000 -0800
9 @@ -3702,12 +3702,10 @@ elf_link_add_object_symbols (bfd *abfd,
10 sec = bfd_abs_section_ptr;
11 else if (sec->kept_section)
13 - /* Symbols from discarded section are undefined, and have
14 - default visibility. */
15 + /* Symbols from discarded section are undefined. We keep
17 sec = bfd_und_section_ptr;
18 isym->st_shndx = SHN_UNDEF;
19 - isym->st_other = (STV_DEFAULT
20 - | (isym->st_other & ~ ELF_ST_VISIBILITY (-1)));
22 else if ((abfd->flags & (EXEC_P | DYNAMIC)) != 0)