relro.m4 353 B

123456789101112
  1. # Set -z,relro.
  2. # Note this is only for shared objects.
  3. ac_ld_relro=no
  4. if test x"$with_gnu_ld" = x"yes"; then
  5. AC_MSG_CHECKING([for ld that supports -Wl,-z,relro])
  6. cxx_z_relo=`$LD -v --help 2>/dev/null | grep "z relro"`
  7. if test -n "$cxx_z_relo"; then
  8. LDFLAGS="$LDFLAGS -z relro -z now"
  9. ac_ld_relro=yes
  10. fi
  11. AC_MSG_RESULT($ac_ld_relro)
  12. fi