Describe the bug
Patch bf6d7087de0a7351fd1dfd5f41522a7f4f576180 to binutils, applied to binutils 2.43.50, exposes a bad assumption in patchelf.
Binaries linked with this version of binutils crash when their rpath is modified with patchelf.
Steps To Reproduce
Steps to reproduce the behavior:
Ensure that the BFD linker has the referenced patch applied.
g++ -o hello hello.cpp
./hello
Hello, World!
patchelf --set-rpath '/usr/lib' ./hello # Any path fails
./hello
Segmentation fault (core dumped)
Expected behavior
Non-crashing binaries. The binutils maintainers have stated that they intend to keep this section re-order if possible, as it allows gdb to give more useful information when analyzing core dumps. (And there's not much activity on the patchelf bug tracker 😬 )
Screenshots
N/A
Additional context
https://bugzilla.redhat.com/show_bug.cgi?id=2319341
https://bugzilla.redhat.com/show_bug.cgi?id=2321588
NixOS/patchelf#568
microsoft/vcpkg#41576
LadybirdBrowser/ladybird#2149
Metadata
N/A
Notify maintainers
@Ericson2314 @lovesegfault
Note for maintainers: Please tag this issue in your PR.
Add a 👍 reaction to issues you find important.
Describe the bug
Patch bf6d7087de0a7351fd1dfd5f41522a7f4f576180 to binutils, applied to binutils 2.43.50, exposes a bad assumption in patchelf.
Binaries linked with this version of binutils crash when their rpath is modified with patchelf.
Steps To Reproduce
Steps to reproduce the behavior:
Ensure that the BFD linker has the referenced patch applied.
Expected behavior
Non-crashing binaries. The binutils maintainers have stated that they intend to keep this section re-order if possible, as it allows gdb to give more useful information when analyzing core dumps. (And there's not much activity on the patchelf bug tracker 😬 )
Screenshots
N/A
Additional context
https://bugzilla.redhat.com/show_bug.cgi?id=2319341
https://bugzilla.redhat.com/show_bug.cgi?id=2321588
NixOS/patchelf#568
microsoft/vcpkg#41576
LadybirdBrowser/ladybird#2149
Metadata
N/A
Notify maintainers
@Ericson2314 @lovesegfault
Note for maintainers: Please tag this issue in your PR.
Add a 👍 reaction to issues you find important.