Make executables position-independent
Pass -pie to the linker
before:
ruben@yourmomma: pdns (master %=)$ checksec --file pdns/pdns_server
RELRO STACK CANARY NX PIE RPATH RUNPATH FILE
Full RELRO Canary found NX enabled No PIE No RPATH No RUNPATH pdns/pdns_server
ruben@yourmomma: pdns (master %=)$ checksec --file pdns/pdns_control
RELRO STACK CANARY NX PIE RPATH RUNPATH FILE
Full RELRO Canary found NX enabled No PIE No RPATH No RUNPATH pdns/pdns_control
after:
ruben@yourmomma: pdns (master *%=)$ checksec --file pdns/pdns_control
RELRO STACK CANARY NX PIE RPATH RUNPATH FILE
Full RELRO Canary found NX enabled PIE enabled No RPATH No RUNPATH pdns/pdns_control
ruben@yourmomma: pdns (master *%=)$ checksec --file pdns/pdns_server
RELRO STACK CANARY NX PIE RPATH RUNPATH FILE
Full RELRO Canary found NX enabled PIE enabled No RPATH No RUNPATH pdns/pdns_server
(cherry picked from commit
c116f5d4a4e0d7a0cc22844cbd2a3cf267fb1a8e)
Conflicts:
configure.ac