freebsd-skq/stand
Ed Maste bcf99d2d99 Add WITH_PIE knob to build Position Independent Executables
Building binaries as PIE allows the executable itself to be loaded at a
random address when ASLR is enabled (not just its shared libraries).

With this change PIE objects have a .pieo extension and INTERNALLIB
libraries libXXX_pie.a.

MK_PIE is disabled for some kerberos5 tools, Clang, and Subversion, as
they explicitly reference .a libraries in their Makefiles.  These can
be addressed on an individual basis later.  MK_PIE is also disabled for
rtld-elf because it is already position-independent using bespoke
Makefile rules.

Currently only dynamically linked binaries will be built as PIE.

Discussed with:	dim
Reviewed by:	kib
MFC after:	1 month
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D18423
2019-02-15 22:22:38 +00:00
..
arm
arm64
common stand: dev_net: correct net_open's interpretation of params 2019-02-15 18:28:51 +00:00
defaults Enable lualoader's kernel autodetection, disabled on install media 2018-10-11 17:17:54 +00:00
efi Allow reading the UEFI variable size 2019-02-08 14:56:28 +00:00
fdt stand: fdt: Drop some write-only assignments/variables and leaked bits 2018-08-23 18:01:34 +00:00
ficl
ficl32
forth Regularize the Netflix copyright 2019-02-04 21:28:25 +00:00
i386 Add WITH_PIE knob to build Position Independent Executables 2019-02-15 22:22:38 +00:00
kshim
liblua Create new EINTEGRITY error with message "Integrity check failed". 2019-01-17 06:35:45 +00:00
liblua32
libsa Regularize the Netflix copyright 2019-02-04 21:28:25 +00:00
libsa32
lua lualoader: Add chainload menu entry 2018-11-05 16:20:07 +00:00
man
mips Unbreak mip64 build after r328437 2019-01-20 21:09:44 +00:00
ofw
powerpc powerpc/ubldr: Teach powerpc's ubldr to boot 64-bit kernels 2018-12-10 01:52:39 +00:00
sparc64 MK_ZFS -> {MK_ZFS|MK_LOADER_ZFS}, this is so we can diable userland / kernel 2019-01-05 22:45:20 +00:00
uboot ubldr: Force 'usefdt' variable to 1 for powerpc 2018-12-02 02:20:35 +00:00
usb
userboot MK_ZFS -> {MK_ZFS|MK_LOADER_ZFS}, this is so we can diable userland / kernel 2019-01-05 22:45:20 +00:00
defs.mk Move inclusion of src.opts.mk later. 2018-12-03 17:51:10 +00:00
fdt.mk
ficl.mk
loader.mk Create MK_LOADER_VERBOSE and connect it to ELF_VERBOSE in the loader 2019-01-07 05:49:27 +00:00
lua.mk
Makefile
Makefile.amd64
Makefile.inc
uboot.mk