HomeFreeBSD

Fix the arm64 userland building with lld:

Description

Fix the arm64 userland building with lld:

MFC 308124:
On arm64 build the efi loader with -fPIC. Without this clang 3.9 will
generate relocation in the self relocation code.

MFC 316608:
Add -fPIC to the standalone build flags on arm64. This is needed as
loader.efi is position independend, however we were not building it as
such causing a build failure when building with lld.

MFC 315452:
Mark the EFI PE header as allocated. While ld.bfd doesn't seem to care
about not having this flag ld.lld fails to link without it.

Details

Provenance
andrewAuthored on
Parents
rS317139: Restore prototype accidently removed by r316811. Also remove $NetBSD$
Branches
Unknown
Tags
Unknown