diff options
author | Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> | 2010-04-16 13:45:25 +0000 |
---|---|---|
committer | Rainer Orth <ro@gcc.gnu.org> | 2010-04-16 13:45:25 +0000 |
commit | 8ccb78f2d06ac9c06f49b8bdf1527bd7ebeadf06 (patch) | |
tree | d9a473d88d703aacdf7e3191ba2b717abcb59e6d /configure | |
parent | bc9c331d4320ff1e3b8258fcaf87f45bf3c4f2bf (diff) | |
download | gcc-8ccb78f2d06ac9c06f49b8bdf1527bd7ebeadf06.zip gcc-8ccb78f2d06ac9c06f49b8bdf1527bd7ebeadf06.tar.gz gcc-8ccb78f2d06ac9c06f49b8bdf1527bd7ebeadf06.tar.bz2 |
configure.ac: Check for elf_getshdrstrndx or elf_getshstrndx separately.
toplevel:
* configure.ac: Check for elf_getshdrstrndx or elf_getshstrndx
separately.
* configure: Regenerate.
gcc:
* configure.ac: Check for elf_getshdrstrndx or elf_getshstrndx
flavor.
* configure: Regenerate.
* config.in: Regenerate.
* doc/install.texi (Prerequisites): Document that Solaris 2 libelf
works.
gcc/lto:
* lto-elf.c [!HAVE_ELF_GETSHDRSTRNDX] (elf_getshdrstrndx): New
function.
From-SVN: r158423
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 56 |
1 files changed, 55 insertions, 1 deletions
@@ -6574,7 +6574,6 @@ main () elf_nextscn (0, 0); elf_strptr (0, 0, 0); elf_getident (0, 0); - elf_getshdrstrndx (0, 0); elf_begin (0, 0, 0); elf_ndxscn (0); elf_end (0); @@ -6594,6 +6593,61 @@ fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext + # Check for elf_getshdrstrndx or elf_getshstrndx. The latter's flavor + # is determined in gcc/configure.ac. + if test x"$enable_lto" = x"yes" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_getshdrstrndx" >&5 +$as_echo_n "checking for elf_getshdrstrndx... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <libelf.h> +int +main () +{ + + elf_getshdrstrndx (0, 0); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; }; +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; }; + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_getshstrndx" >&5 +$as_echo_n "checking for elf_getshstrndx... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <libelf.h> +int +main () +{ + + elf_getshstrndx (0, 0); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; }; +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; }; enable_lto=no; libelflibs= ; libelfinc= + +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + fi + # If we couldn't enable LTO and the user forced it, emit an error. if test x"$enable_lto" = x"no" \ && test x"$default_enable_lto" != x"yes" ; then |