aboutsummaryrefslogtreecommitdiff
path: root/ld/configure.ac
diff options
context:
space:
mode:
authorChung-Lin Tang <cltang@codesourcery.com>2015-05-14 18:40:57 +0800
committerAlan Modra <amodra@gmail.com>2015-05-17 14:25:24 +0930
commit68880f311c1d5629c47c3ab9749061fe3138be63 (patch)
treea19437f424b6fefa1eebbe97e3b1e60524182071 /ld/configure.ac
parent20ef91414ed2272cc379dcf8364f5f48eeff6362 (diff)
downloadgdb-68880f311c1d5629c47c3ab9749061fe3138be63.zip
gdb-68880f311c1d5629c47c3ab9749061fe3138be63.tar.gz
gdb-68880f311c1d5629c47c3ab9749061fe3138be63.tar.bz2
ELF options may be missing from `ld --help' output
nios2-linux has an emulation named "nios2linux", and happens to not include another extra emulation with a name matching *elf*. This makes nios2-linux left out of the ELF options printing targets, which is unintended. * configure.ac (AC_PROG_GREP): Check for grep program. (elf_list_options,elf_shlib_list_options,elf_plt_unwind_list_options): Enable ELF option printing for emulations containing 'TEMPLATE_NAME=elf32'. * configure: Regenerate.
Diffstat (limited to 'ld/configure.ac')
-rw-r--r--ld/configure.ac12
1 files changed, 10 insertions, 2 deletions
diff --git a/ld/configure.ac b/ld/configure.ac
index e120a05..62aed09 100644
--- a/ld/configure.ac
+++ b/ld/configure.ac
@@ -31,6 +31,7 @@ AM_MAINTAINER_MODE
AC_PROG_CC
AC_PROG_CXX
+AC_PROG_GREP
AC_GNU_SOURCE
AC_USE_SYSTEM_EXTENSIONS
AC_PROG_INSTALL
@@ -326,6 +327,14 @@ do
case "${i}" in
*elf*)
elf_list_options=TRUE
+ ;;
+ *)
+ if $GREP "TEMPLATE_NAME=elf32" ${srcdir}/emulparams/${i}.sh >/dev/null 2>/dev/null; then
+ elf_list_options=TRUE
+ fi
+ ;;
+ esac
+ if test "$elf_list_options" = "TRUE"; then
. ${srcdir}/emulparams/${i}.sh
if test x${GENERATE_SHLIB_SCRIPT} = xyes; then
elf_shlib_list_options=TRUE
@@ -333,8 +342,7 @@ do
if test x${PLT_UNWIND} = xyes; then
elf_plt_unwind_list_options=TRUE
fi
- ;;
- esac
+ fi
;;
esac
done