Disable --eh-frame-hdr with -pie or -shared on nios2-linux-gnu.
authorSandra Loosemore <sandra@codesourcery.com>
Thu, 5 Dec 2019 21:36:22 +0000 (16:36 -0500)
committerSandra Loosemore <sandra@gcc.gnu.org>
Thu, 5 Dec 2019 21:36:22 +0000 (16:36 -0500)
commit38e078da6c4f4e0c21f5973eb9d8f8a87cabbc5e
tree0223e7bf6a44cc595519d9653bcc9a65dcb3613d
parenta414fd426346558d7a913af3ed82bcc1121fc880
Disable --eh-frame-hdr with -pie or -shared on nios2-linux-gnu.

2019-12-05  Sandra Loosemore  <sandra@codesourcery.com>

Disable --eh-frame-hdr with -pie or -shared on nios2-linux-gnu.

The nios2 ABI doesn't have appropriate relocations to support
--eh-frame-hdr with -pie or -shared, so we need to override the
default specs that add that link option.  Otherwise we get linker
warnings about invalid FDE encodings.

gcc/
* config/nios2/linux.h (LINK_EH_SPEC): Define.

gcc/testsuite/
* g++.target/nios2/hello-pie.C: New.
* g++.target/nios2/nios2.exp: New.

From-SVN: r279023
gcc/ChangeLog
gcc/config/nios2/linux.h
gcc/testsuite/ChangeLog
gcc/testsuite/g++.target/nios2/hello-pie.C [new file with mode: 0644]
gcc/testsuite/g++.target/nios2/nios2.exp [new file with mode: 0644]