X-Git-Url: http://git.sourceforge.jp/view?p=pf3gnuchains%2Fgcc-fork.git;a=blobdiff_plain;f=configure;h=bc2792722f7a9e4f37ab62aecefda1818a6f47f7;hp=8edfde3da4d753dd410214c5e75f5b53b91b9f3d;hb=248a4715105961832c4c9373d0bb331c923ba589;hpb=e43107a9e53d283f5c4ebefb96f042bca7da8ceb diff --git a/configure b/configure index 8edfde3da4d..bc2792722f7 100755 --- a/configure +++ b/configure @@ -6015,7 +6015,95 @@ fi -ac_ext=c + + +target_elf=no +case $target in + *-darwin* | *-aix* | *-cygwin* | *-mingw* | *-aout* | *-*coff* | \ + *-msdosdjgpp* | *-netware* | *-vms* | *-wince* | *-*-pe* | \ + alpha*-dec-osf* | *-interix* | hppa[12]*-*-hpux*) + target_elf=no + ;; + *) + target_elf=yes + ;; +esac + +if test $target_elf = yes; then : + +else + if test x"$default_enable_lto" = x"yes" ; then + enable_lto=no +else + if test x"$enable_lto" = x"yes"; then + as_fn_error "LTO support requires an ELF target." "$LINENO" 5 + fi +fi +default_enable_lto=no +fi + + +if test x"$enable_lto" = x"yes" ; then + # Make sure that libelf.h and gelf.h are available. + +# Check whether --with-libelf was given. +if test "${with_libelf+set}" = set; then : + withval=$with_libelf; +fi + + + +# Check whether --with-libelf_include was given. +if test "${with_libelf_include+set}" = set; then : + withval=$with_libelf_include; +fi + + + +# Check whether --with-libelf_lib was given. +if test "${with_libelf_lib+set}" = set; then : + withval=$with_libelf_lib; +fi + + + saved_CFLAGS="$CFLAGS" + saved_CPPFLAGS="$CPPFLAGS" + saved_LIBS="$LIBS" + + case $with_libelf in + "") + libelflibs="-lelf" + libelfinc="-I/usr/include/libelf" + ;; + *) + libelflibs="-L$with_libelf/lib -lelf" + libelfinc="-I$with_libelf/include -I$with_libelf/include/libelf" + LIBS="$libelflibs $LIBS" + ;; + esac + + if test "x$with_libelf_include" != x; then + libelfinc="-I$with_libelf_include" + fi + + if test "x$with_libelf_lib" != x; then + libelflibs="-L$with_libelf_lib -lelf" + LIBS="$libelflibs $LIBS" + fi + + if test "x$with_libelf$with_libelf_include$with_libelf_lib" = x \ + && test -d ${srcdir}/libelf; then + libelflibs='-L$$r/$(HOST_SUBDIR)/libelf/lib -lelf ' + libelfinc='-D__LIBELF_INTERNAL__ -I$$r/$(HOST_SUBDIR)/libelf/lib -I$$s/libelf/lib' + LIBS="$libelflibs $LIBS" + + else + + CFLAGS="$CFLAGS $libelfinc" + CPPFLAGS="$CPPFLAGS $libelfinc" + LIBS="$LIBS $libelflibs" + + ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' @@ -7996,7 +8084,7 @@ case " $target_configdirs " in # to it. This is right: we don't want to search that directory # for binaries, but we want the header files in there, so add # them explicitly. - FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/$(HOST_SUBDIR)/gcc/include' + FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/$(HOST_SUBDIR)/gcc/include -isystem $$r/$(HOST_SUBDIR)/gcc/include-fixed' # Someone might think of using the pre-installed headers on # Canadian crosses, in case the installed compiler is not fully