check to see if '-Wl,-pie' is supported before using it
This commit is contained in:
parent
6ebf4030f8
commit
9c9d1edf74
11
configure.ac
11
configure.ac
@ -159,10 +159,13 @@ AS_CASE([$host_os], [cygwin*|mingw*|msys|pw32*|cegcc*], [ ], [
|
|||||||
|
|
||||||
AS_IF([test "$enable_pie" != "no"],[
|
AS_IF([test "$enable_pie" != "no"],[
|
||||||
AX_CHECK_COMPILE_FLAG([-fPIE], [
|
AX_CHECK_COMPILE_FLAG([-fPIE], [
|
||||||
AX_CHECK_LINK_FLAG([-fPIE],
|
AX_CHECK_LINK_FLAG([-fPIE], [
|
||||||
[AX_CHECK_LINK_FLAG([-pie],
|
CFLAGS="$CFLAGS -fPIE"
|
||||||
[CFLAGS="$CFLAGS -fPIE"
|
AX_CHECK_COMPILE_FLAG(["-Wl,-pie"], [
|
||||||
LDFLAGS="$LDFLAGS -Wl,-pie"])
|
LDFLAGS="$LDFLAGS -Wl,-pie"
|
||||||
|
], [
|
||||||
|
LDFLAGS="$LDFLAGS -pie"
|
||||||
|
])
|
||||||
])
|
])
|
||||||
])
|
])
|
||||||
])
|
])
|
||||||
|
Loading…
Reference in New Issue
Block a user