aboutsummaryrefslogtreecommitdiff
path: root/binutils/nm.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2011-05-18 16:35:03 +0000
committerNick Clifton <nickc@redhat.com>2011-05-18 16:35:03 +0000
commit0ba0c2b3438846e98e254ea2019901ea42bd986f (patch)
tree1e2a0b65a39459341aac047551429acef698e949 /binutils/nm.c
parent1d06ead6876712e45010dae36b8e4745fa3321ea (diff)
downloadgdb-0ba0c2b3438846e98e254ea2019901ea42bd986f.zip
gdb-0ba0c2b3438846e98e254ea2019901ea42bd986f.tar.gz
gdb-0ba0c2b3438846e98e254ea2019901ea42bd986f.tar.bz2
PR binutils/12753
* nm.c (filter_symbols): Treat unique symbols as global symbols. * doc/binutils.texi (nm): Mention that some lowercase letters actually indicate global symbols. * lib/utils-lib.exp (run_dump_test): Allow nm as a program. * binutils-all/nm.exp: Test running "nm -g" on an object file containing a unique symbol.
Diffstat (limited to 'binutils/nm.c')
-rw-r--r--binutils/nm.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/binutils/nm.c b/binutils/nm.c
index 2c099aa..2fc13b4 100644
--- a/binutils/nm.c
+++ b/binutils/nm.c
@@ -436,6 +436,8 @@ filter_symbols (bfd *abfd, bfd_boolean is_dynamic, void *minisyms,
else if (external_only)
keep = ((sym->flags & BSF_GLOBAL) != 0
|| (sym->flags & BSF_WEAK) != 0
+ /* PR binutls/12753: Unique symbols are global too. */
+ || (sym->flags & BSF_GNU_UNIQUE) != 0
|| bfd_is_und_section (sym->section)
|| bfd_is_com_section (sym->section));
else