mirror of git://gcc.gnu.org/git/gcc.git
acinclude.m4: Use -Wl,-z,relro if possible.
2006-01-11 Benjamin Kosnik <bkoz@redhat.com> * acinclude.m4: Use -Wl,-z,relro if possible. * configure: Regenerate. From-SVN: r109618
This commit is contained in:
parent
257c8aec25
commit
a429affe7d
|
@ -1,3 +1,8 @@
|
||||||
|
2006-01-11 Benjamin Kosnik <bkoz@redhat.com>
|
||||||
|
|
||||||
|
* acinclude.m4: Use -Wl,-z,relro if possible.
|
||||||
|
* configure: Regenerate.
|
||||||
|
|
||||||
2006-01-10 Paolo Carlini <pcarlini@suse.de>
|
2006-01-10 Paolo Carlini <pcarlini@suse.de>
|
||||||
|
|
||||||
* include/tr1/complex: New file, hosts the additions to header
|
* include/tr1/complex: New file, hosts the additions to header
|
||||||
|
|
|
@ -187,7 +187,7 @@ dnl safe (like an empty string).
|
||||||
dnl
|
dnl
|
||||||
dnl Defines:
|
dnl Defines:
|
||||||
dnl SECTION_LDFLAGS='-Wl,--gc-sections' if possible
|
dnl SECTION_LDFLAGS='-Wl,--gc-sections' if possible
|
||||||
dnl OPT_LDFLAGS='-Wl,-O1' if possible
|
dnl OPT_LDFLAGS='-Wl,-O1' and '-z,relro' if possible
|
||||||
dnl LD (as a side effect of testing)
|
dnl LD (as a side effect of testing)
|
||||||
dnl Sets:
|
dnl Sets:
|
||||||
dnl with_gnu_ld
|
dnl with_gnu_ld
|
||||||
|
@ -267,6 +267,19 @@ AC_DEFUN([GLIBCXX_CHECK_LINKER_FEATURES], [
|
||||||
AC_MSG_RESULT($ac_sectionLDflags)
|
AC_MSG_RESULT($ac_sectionLDflags)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
AC_MSG_CHECKING([for ld that supports -Wl,-z,relro])
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
AC_MSG_RESULT($ac_ld_relro)
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
|
|
@ -8279,6 +8279,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
@ -53103,6 +53118,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
@ -74420,6 +74450,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
@ -75900,6 +75945,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
@ -77256,6 +77316,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
@ -79399,6 +79474,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
@ -80708,6 +80798,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
@ -82066,6 +82171,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
@ -83804,6 +83924,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
@ -85875,6 +86010,21 @@ fi
|
||||||
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
echo "${ECHO_T}$ac_sectionLDflags" >&6
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Set -z,relro.
|
||||||
|
# Note this is only for shared objects
|
||||||
|
ac_ld_relro=no
|
||||||
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
|
echo "$as_me:$LINENO: checking for ld that supports -Wl,-z,relro" >&5
|
||||||
|
echo $ECHO_N "checking for ld that supports -Wl,-z,relro... $ECHO_C" >&6
|
||||||
|
cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
|
||||||
|
if test -n "$cxx_z_relo"; then
|
||||||
|
OPT_LDFLAGS="-Wl,-z,relro"
|
||||||
|
ac_ld_relro=yes
|
||||||
|
fi
|
||||||
|
echo "$as_me:$LINENO: result: $ac_ld_relro" >&5
|
||||||
|
echo "${ECHO_T}$ac_ld_relro" >&6
|
||||||
|
fi
|
||||||
|
|
||||||
# Set linker optimization flags.
|
# Set linker optimization flags.
|
||||||
if test x"$with_gnu_ld" = x"yes"; then
|
if test x"$with_gnu_ld" = x"yes"; then
|
||||||
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS"
|
||||||
|
|
Loading…
Reference in New Issue