OSDN Git Service

* g++.old-deja/g++.pt/static11.C: Add xtensa-*-elf* to the
[pf3gnuchains/gcc-fork.git] / gcc / aclocal.m4
index 90fdb69..0c4b5c6 100644 (file)
@@ -321,7 +321,7 @@ for cand in ${ac_tool_prefix}$user_adac     $user_adac      \
   # has not been installed.  This is fixed in 2.95.4, 3.0.2, and 3.1.
   # Therefore we must check for the error message as well as an
   # unsuccessful exit.
-  errors=`$cand -c conftest.adb 2>&1 || echo failure`
+  errors=`($cand -c conftest.adb) 2>&1 || echo failure`
   if test x"$errors" = x; then
     gcc_cv_prog_adac=$cand
     break
@@ -1101,11 +1101,12 @@ AC_DEFUN([AM_ICONV],
   dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and
   dnl those with the standalone portable GNU libiconv installed).
 
+  am_cv_lib_iconv_ldpath=
   AC_ARG_WITH([libiconv-prefix],
 [  --with-libiconv-prefix=DIR  search for libiconv in DIR/include and DIR/lib], [
     for dir in `echo "$withval" | tr : ' '`; do
       if test -d $dir/include; then CPPFLAGS="$CPPFLAGS -I$dir/include"; fi
-      if test -d $dir/lib; then LDFLAGS="$LDFLAGS -L$dir/lib"; fi
+      if test -d $dir/lib; then am_cv_lib_iconv_ldpath="-L$dir/lib"; fi
     done
    ])
 
@@ -1120,7 +1121,7 @@ AC_DEFUN([AM_ICONV],
       am_cv_func_iconv=yes)
     if test "$am_cv_func_iconv" != yes; then
       am_save_LIBS="$LIBS"
-      LIBS="$LIBS -liconv"
+      LIBS="$LIBS $am_cv_libiconv_ldpath -liconv"
       AC_TRY_LINK([#include <stdlib.h>
 #include <iconv.h>],
         [iconv_t cd = iconv_open("","");
@@ -1157,7 +1158,7 @@ size_t iconv();
   fi
   LIBICONV=
   if test "$am_cv_lib_iconv" = yes; then
-    LIBICONV="-liconv"
+    LIBICONV="$am_cv_lib_iconv_ldpath -liconv"
   fi
   AC_SUBST(LIBICONV)
 ])