SHA256
1
0
forked from pool/binutils
binutils/binutils-revert-nm-symversion.diff
Michael Matz 6c0b92b0e7 - Add binutils-revert-nm-symversion.diff to be compatible with old
output of nm relied on in scripts.
- Add binutils-fix-abierrormsg.diff to work around an eager (new)
  error message occuring without inputs and as-needed (affects
  nvme-cli build).

OBS-URL: https://build.opensuse.org/package/show/devel:gcc/binutils?expand=0&rev=339
2020-08-11 14:14:33 +00:00

35 lines
1.4 KiB
Diff

Some packages of ours rely on the output of nm to not contain
symversions. E.g. perf uses 'nm -D' to construct a linker input
file with symbol names. ld errors on the '@' characters. Until
those packages are fixed we use this patch. We have to carry it
for old code streams forever.
Index: binutils-2.35/binutils/nm.c
===================================================================
--- binutils-2.35.orig/binutils/nm.c 2020-07-24 11:12:19.000000000 +0200
+++ binutils-2.35/binutils/nm.c 2020-08-07 16:42:58.000000000 +0200
@@ -411,7 +411,7 @@ print_symname (const char *form, struct
}
printf (form, name);
- if (info != NULL && info->elfinfo)
+ if (info != NULL && info->elfinfo && 0)
{
const char *version_string;
bfd_boolean hidden;
Index: binutils-2.35/ld/testsuite/ld-elf/pr25708.d
===================================================================
--- binutils-2.35.orig/ld/testsuite/ld-elf/pr25708.d 2020-07-24 11:12:20.000000000 +0200
+++ binutils-2.35/ld/testsuite/ld-elf/pr25708.d 2020-08-07 16:44:50.000000000 +0200
@@ -2,8 +2,9 @@
#ld: -shared -version-script pr13195.t
#nm: -D
#target: *-*-linux* *-*-gnu* arm*-*-uclinuxfdpiceabi
-#xfail: hppa64-*-* ![check_shared_lib_support]
+#xfail: *-*-* ![check_shared_lib_support]
# h8300 doesn't support -shared, and hppa64 creates .foo
+# our binutils revert the printing of symversions with nm -D
#..
0+ A VERS_2.0