From: Ruben Kerkhof Date: Tue, 27 Jan 2015 21:48:12 +0000 (+0000) Subject: Simplify check X-Git-Tag: rec-3.7.0-rc2~19^2~1 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=dced89b1b0f3c43dff0d4a2183d5e50bf3949cde;p=pdns Simplify check If we can link with -pie or -Wl,pie, -fPIE works too --- diff --git a/m4/pdns_pie.m4 b/m4/pdns_pie.m4 index 1f1f71d0e..98d392374 100644 --- a/m4/pdns_pie.m4 +++ b/m4/pdns_pie.m4 @@ -27,7 +27,6 @@ AC_DEFUN([AC_CC_PIE],[ *-*-mingw* | *-*-msvc* | *-*-cygwin* ) ;; dnl All code is position independent on Win32 target *) - gl_COMPILER_OPTION_IF([-fPIE -DPIE], [ CXXFLAGS="-fPIE -DPIE" gl_COMPILER_OPTION_IF([-pie], [ PIE_CFLAGS="-fPIE -DPIE" @@ -48,13 +47,7 @@ __thread unsigned int t_id; #include __thread unsigned int t_id; ]], [[t_id = 1;]])] - )], - [], - [AC_LANG_PROGRAM([[ -#include -__thread unsigned int t_id; - ]], [[t_id = 1;]])] - ) + ) esac CXXFLAGS=$OLD_CXXFLAGS AC_SUBST([PIE_CFLAGS])