1 Prevent default-fPIE from confusing configure into thinking
2 PIC code is default. This causes glibc to build both PIC and
3 non-PIC code as normal, which on the hardened compiler generates
6 Patch by Kevin F. Quinn <kevquinn@gentoo.org>
8 --- glibc-2.10.1/configure.in
9 +++ glibc-2.10.1/configure.in
11 # error PIC is default.
14 -if eval "${CC-cc} -S conftest.c 2>&AS_MESSAGE_LOG_FD 1>&AS_MESSAGE_LOG_FD"; then
15 +if eval "${CC-cc} -fno-PIE -S conftest.c 2>&AS_MESSAGE_LOG_FD 1>&AS_MESSAGE_LOG_FD"; then
16 libc_cv_pic_default=no
19 --- glibc-2.10.1/configure
20 +++ glibc-2.10.1/configure
22 # error PIC is default.
25 -if eval "${CC-cc} -S conftest.c 2>&5 1>&5"; then
26 +if eval "${CC-cc} -fno-PIE -S conftest.c 2>&5 1>&5"; then
27 libc_cv_pic_default=no