PR27128, nm -P portable output format regression
authorAlan Modra <amodra@gmail.com>
Sat, 27 Feb 2021 05:09:05 +0000 (15:39 +1030)
committerAlan Modra <amodra@gmail.com>
Mon, 1 Mar 2021 03:56:39 +0000 (14:26 +1030)
commit6a1224ec762f7dd59d7abd2e5dc3be26bb157cd1
tree1e35d6d43b5efe25d4b7fc5e5ee818eb38e0742b
parentcf850febf6d2e3945670386c707a86363919e9ee
PR27128, nm -P portable output format regression

Add nm --without-symbol-versions.

binutils/
PR 27128
* doc/binutils.texi: Add nm --with-symbol-versions and
--without-symbol-versions documentation.
* nm.c (with_symbol_versions): New variable.
(enum long_option_values): Delete OPTION_WITH_SYMBOL_VERSIONS.
(long_options): Make --with-symbol-versions entry twiddle the flag.
Add --without-symbol-versions.
(print_symname): Strip version when !with_symbol_versions.  Add
dynamic version info under control of with_symbol_versions.
(main): Remove OPTION_WITH_SYMBOL_VERSIONS case.
ld/
* testsuite/ld-elf/pr25708.d: Add --with-symbol-versions to nm.
* testsuite/ld-elf/pr27128a.d: Likewise.
* testsuite/ld-elf/pr27128b.d: Likewise.
* testsuite/ld-elf/pr27128c.d: Likewise.
* testsuite/ld-elf/pr27128d.d: Likewise.
* testsuite/ld-elf/pr27128e.d: Likewise.
binutils/ChangeLog
binutils/doc/binutils.texi
binutils/nm.c
ld/ChangeLog
ld/testsuite/ld-elf/pr25708.d
ld/testsuite/ld-elf/pr27128a.d
ld/testsuite/ld-elf/pr27128b.d
ld/testsuite/ld-elf/pr27128c.d
ld/testsuite/ld-elf/pr27128d.d
ld/testsuite/ld-elf/pr27128e.d