Description of problem:
There are two cases then ld.bfd does not insert veneers on aarch64:
- "the target symbol and relocated place are in separate sections"
- if you are building a shared library and a function call goes through PLT stub. PLT stub ends up outside of +/-128MB range.
Version-Release number of selected component (if applicable):
The problems are present in trunk (last tested July 13) of binutils.
All the details are in referenced PR in sourceware bugzilla.
Fixes for both issues are now posted for review:
[AArch64] PR18668, Generate long branch veneer if call to plt stub is out of range
[AArch64] Long branch veneer support far symbol defined by --defsym
Created attachment 1096127 [details]
Once the 7.3 branch is created, this patch can be used to fix this BZ...
binutils-2.25.1-7.el7 now contains the full patch.
Verified for build binutils-2.25.1-19.base.el7.
*** Bug 1360941 has been marked as a duplicate of this bug. ***
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.