mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-17 16:05:56 +08:00
PR27493, objcopy --weaken-symbol does not weaken undefined symbols
PR 27493 * objcopy.c (filter_symbols): Apply --weaken to undefined symbols. * NEWS: Mention feature.
This commit is contained in:
@ -1673,7 +1673,8 @@ filter_symbols (bfd *abfd, bfd *obfd, asymbol **osyms,
|
||||
|
||||
if (keep)
|
||||
{
|
||||
if ((flags & BSF_GLOBAL) != 0
|
||||
if (((flags & BSF_GLOBAL) != 0
|
||||
|| undefined)
|
||||
&& (weaken || is_specified_symbol (name, weaken_specific_htab)))
|
||||
{
|
||||
sym->flags &= ~ BSF_GLOBAL;
|
||||
|
Reference in New Issue
Block a user