[PATCH] elf/x86: Issue an error on discarded output .plt section

H.J. Lu hjl.tools@gmail.com
Mon Nov 22 00:33:20 GMT 2021


On Sun, Nov 21, 2021 at 4:09 PM Alan Modra <amodra@gmail.com> wrote:
>
> On Thu, Nov 18, 2021 at 07:58:11AM -0800, H.J. Lu via Binutils wrote:
> > Issue an error, instead of crash, on discarded output .plt section.
>
> Are you sure you want an error?  There may be uses of the linker where
> discarding the .plt via a linker script is deliberate.  Obviously it
> wouldn't be to create a runnable executable, but ld output is used in
> weird ways.
>

Yes, an error is appropriate here. If one doesn't want a .plt section,
she/he should discard sections which require a .plt section.

-- 
H.J.


More information about the Binutils mailing list