diff options
author | Alan Modra <amodra@gmail.com> | 2021-11-11 20:21:32 +1030 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2021-11-12 14:33:31 +1030 |
commit | 0d64622696e02ad649d048f4af3a3f293481f89f (patch) | |
tree | c25c5549ac2a3d6d9ad70a1a73cb12a1df6f2b13 /binutils/objdump.c | |
parent | d31028e8ccfa9dbc76c3c7f5dc8fadbe8af11e6b (diff) | |
download | gdb-0d64622696e02ad649d048f4af3a3f293481f89f.zip gdb-0d64622696e02ad649d048f4af3a3f293481f89f.tar.gz gdb-0d64622696e02ad649d048f4af3a3f293481f89f.tar.bz2 |
Fix demangle style usage info
Extract allowed styles from libiberty, so we don't have to worry about
our help messages getting out of date. The function probably belongs
in libiberty/cplus-dem.c but it can be here for a while to iron out
bugs.
PR 28581
* demanguse.c: New file.
* demanguse.h: New file.
* nm.c (usage): Break up output. Use display_demangler_styles.
* objdump.c (usage): Use display_demangler_styles.
* readelf.c (usage): Likewise.
* Makefile.am: Add demanguse.c and demanguse.h.
* Makefile.in: Regenerate.
* po/POTFILESin: Regenerate.
Diffstat (limited to 'binutils/objdump.c')
-rw-r--r-- | binutils/objdump.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/binutils/objdump.c b/binutils/objdump.c index cf9cedc..1811e70 100644 --- a/binutils/objdump.c +++ b/binutils/objdump.c @@ -55,6 +55,7 @@ #include "progress.h" #include "bucomm.h" #include "elfcomm.h" +#include "demanguse.h" #include "dwarf.h" #include "ctf-api.h" #include "getopt.h" @@ -330,10 +331,9 @@ usage (FILE *stream, int status) fprintf (stream, _("\ -F, --file-offsets Include file offsets when displaying information\n")); fprintf (stream, _("\ - -C, --demangle[=STYLE] Decode mangled/processed symbol names\n\ - The STYLE, if specified, can be `auto', `gnu',\n\ - `lucid', `arm', `hp', `edg', `gnu-v3', `java'\n\ - or `gnat'\n")); + -C, --demangle[=STYLE] Decode mangled/processed symbol names\n")); + display_demangler_styles (stream, _("\ + STYLE can be ")); fprintf (stream, _("\ --recurse-limit Enable a limit on recursion whilst demangling\n\ (default)\n")); |