aboutsummaryrefslogtreecommitdiff
path: root/ld/configure.ac
diff options
context:
space:
mode:
authorSlava Barinov <v.barinov@samsung.com>2017-06-05 09:27:38 +0930
committerAlan Modra <amodra@gmail.com>2017-06-05 09:58:05 +0930
commit6734f10ae9af6cfd47e70baa2cd3e326afabe5ed (patch)
treeafa7629a0be2b40664ddffb5550cf929a24c0995 /ld/configure.ac
parent3ea0007c8ca3ec851df6ab5391a98467b4021f92 (diff)
downloadgdb-6734f10ae9af6cfd47e70baa2cd3e326afabe5ed.zip
gdb-6734f10ae9af6cfd47e70baa2cd3e326afabe5ed.tar.gz
gdb-6734f10ae9af6cfd47e70baa2cd3e326afabe5ed.tar.bz2
Introduce --enable-new-dtags configure option.
This option switches on ld.bfd --enable-new-dtags by default. * configure.ac: Add --enable-new-dtags option. * ldmain.c: Set link_info.new_dtags to 1 if when --enable-new-dtags is switched on. * configure: Regenerate. * config.in: Regenerate.
Diffstat (limited to 'ld/configure.ac')
-rw-r--r--ld/configure.ac18
1 files changed, 18 insertions, 0 deletions
diff --git a/ld/configure.ac b/ld/configure.ac
index f3a7f54..4e2dc86 100644
--- a/ld/configure.ac
+++ b/ld/configure.ac
@@ -155,6 +155,17 @@ AC_ARG_ENABLE(compressed_debug_sections,
,no, | ,none,) ac_default_compressed_debug_sections=no ;;
esac])dnl
+# Decide setting DT_RUNPATH instead of DT_RPATH by default
+ac_default_new_dtags=unset
+# Provide a configure time option to override our default.
+AC_ARG_ENABLE(new_dtags,
+ AS_HELP_STRING([--enable-new-dtags],
+ [set DT_RUNPATH instead of DT_RPATH by default])],
+[case "${enableval}" in
+ yes) ac_default_new_dtags=1 ;;
+ no) ac_default_new_dtags=0 ;;
+esac])dnl
+
# Decide if -z relro should be enabled in ELF linker by default.
ac_default_ld_z_relro=unset
# Provide a configure time option to override our default.
@@ -383,6 +394,13 @@ if test x$ac_default_compressed_debug_sections = xyes ; then
AC_DEFINE(DEFAULT_FLAG_COMPRESS_DEBUG, 1, [Define if you want compressed debug sections by default.])
fi
+if test "${ac_default_new_dtags}" = unset; then
+ ac_default_new_dtags=0
+fi
+AC_DEFINE_UNQUOTED(DEFAULT_NEW_DTAGS,
+ $ac_default_new_dtags,
+ [Define to 1 if you want to set DT_RUNPATH instead of DT_RPATH by default.])
+
if test "${ac_default_ld_z_relro}" = unset; then
ac_default_ld_z_relro=0
fi