Ignore:
Timestamp:
Aug 16, 2003, 6:59:22 PM (22 years ago)
Author:
bird
Message:

binutils v2.14 - offical sources.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/GNU/src/binutils/libiberty/configure

    • Property cvs2svn:cvs-rev changed from 1.1 to 1.1.1.2
    r608 r609  
    1313# Any additions from configure.in:
    1414ac_help="$ac_help
    15   --with-target-subdir=SUBDIR      Configuring in a subdirectory"
     15  --with-target-subdir=SUBDIR      Configuring in a subdirectory for target"
     16ac_help="$ac_help
     17  --with-build-subdir=SUBDIR       Configuring in a subdirectory for build"
    1618ac_help="$ac_help
    1719  --with-cross-host=HOST           Configuring with a cross compiler"
    1820ac_help="$ac_help
    1921  --with-newlib                    Configuring with newlib"
     22ac_help="$ac_help
     23  --enable-maintainer-mode
     24                          enable make rules and dependencies not useful
     25                          (and sometimes confusing) to the casual installer"
     26ac_help="$ac_help
     27  --enable-install-libiberty       Install headers for end users"
    2028
    2129# Initialize some variables set by options.
     
    458466# A filename unique to this package, relative to the directory that
    459467# configure is in, which we can look for to find out if srcdir is correct.
    460 ac_unique_file=pexecute.c
     468ac_unique_file=xmalloc.c
    461469
    462470# Find the source files, if location was not specified.
     
    529537
    530538
     539# This works around the fact that libtool configuration may change LD
     540# for this particular configuration, but some shells, instead of
     541# keeping the changes in LD private, export them just because LD is
     542# exported.  We don't use libtool yet, but some day we might, so...
     543ORIGINAL_LD_FOR_MULTILIBS=$LD
     544
    531545# Check whether --with-target-subdir or --without-target-subdir was given.
    532546if test "${with_target_subdir+set}" = set; then
     
    535549fi
    536550
     551# Check whether --with-build-subdir or --without-build-subdir was given.
     552if test "${with_build_subdir+set}" = set; then
     553  withval="$with_build_subdir"
     554  :
     555fi
     556
    537557# Check whether --with-cross-host or --without-cross-host was given.
    538558if test "${with_cross_host+set}" = set; then
     
    549569
    550570if test "${srcdir}" = "."; then
    551   if test -z "${with_target_subdir}"; then
     571  if test -n "${with_build_subdir}"; then
     572    libiberty_topdir="${srcdir}/../.."
     573    with_target_subdir=
     574  elif test -z "${with_target_subdir}"; then
    552575    libiberty_topdir="${srcdir}/.."
    553576  else
     
    561584  libiberty_topdir="${srcdir}/.."
    562585fi
     586
    563587ac_aux_dir=
    564588for ac_dir in $libiberty_topdir $srcdir/$libiberty_topdir; do
     
    582606
    583607
     608echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
     609echo "configure:610: checking whether to enable maintainer-specific portions of Makefiles" >&5
     610    # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
     611if test "${enable_maintainer_mode+set}" = set; then
     612  enableval="$enable_maintainer_mode"
     613  maintainer_mode=$enableval
     614else
     615  maintainer_mode=no
     616fi
     617
     618
     619echo "$ac_t""$maintainer_mode" 1>&6
     620
     621if test "$maintainer_mode" = "yes"; then
     622  MAINT=''
     623  NOTMAINT='#'
     624else
     625  MAINT='#'
     626  NOTMAINT=''
     627fi
     628
     629# Do we have a single-tree copy of texinfo?  Even if we do, we can't
     630# rely on it - libiberty is built before texinfo.
     631# Extract the first word of "makeinfo", so it can be a program name with args.
     632set dummy makeinfo; ac_word=$2
     633echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
     634echo "configure:635: checking for $ac_word" >&5
     635if eval "test \"`echo '$''{'ac_cv_prog_MAKEINFO'+set}'`\" = set"; then
     636  echo $ac_n "(cached) $ac_c" 1>&6
     637else
     638  if test -n "$MAKEINFO"; then
     639  ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
     640else
     641  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
     642  ac_dummy="$PATH"
     643  for ac_dir in $ac_dummy; do
     644    test -z "$ac_dir" && ac_dir=.
     645    if test -f $ac_dir/$ac_word; then
     646      ac_cv_prog_MAKEINFO="makeinfo"
     647      break
     648    fi
     649  done
     650  IFS="$ac_save_ifs"
     651fi
     652fi
     653MAKEINFO="$ac_cv_prog_MAKEINFO"
     654if test -n "$MAKEINFO"; then
     655  echo "$ac_t""$MAKEINFO" 1>&6
     656else
     657  echo "$ac_t""no" 1>&6
     658fi
     659
     660if test "x$MAKEINFO" = "x"; then
     661    MAKEINFO="@echo makeinfo missing; true"
     662    BUILD_INFO=
     663else
     664    BUILD_INFO=info
     665    case x"`$MAKEINFO --version | grep 'GNU texinfo'`" in
     666      x*\ [1-3].* )
     667        MAKEINFO="@echo $MAKEINFO is too old, 4.0 or newer required; true"
     668        BUILD_INFO=
     669        echo "configure: warning:
     670*** Makeinfo is too old. Info documentation will not be built." 1>&2
     671        ;;
     672    esac
     673fi
     674
     675
     676
     677# Extract the first word of "perl", so it can be a program name with args.
     678set dummy perl; ac_word=$2
     679echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
     680echo "configure:681: checking for $ac_word" >&5
     681if eval "test \"`echo '$''{'ac_cv_prog_PERL'+set}'`\" = set"; then
     682  echo $ac_n "(cached) $ac_c" 1>&6
     683else
     684  if test -n "$PERL"; then
     685  ac_cv_prog_PERL="$PERL" # Let the user override the test.
     686else
     687  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
     688  ac_dummy="$PATH"
     689  for ac_dir in $ac_dummy; do
     690    test -z "$ac_dir" && ac_dir=.
     691    if test -f $ac_dir/$ac_word; then
     692      ac_cv_prog_PERL="perl"
     693      break
     694    fi
     695  done
     696  IFS="$ac_save_ifs"
     697fi
     698fi
     699PERL="$ac_cv_prog_PERL"
     700if test -n "$PERL"; then
     701  echo "$ac_t""$PERL" 1>&6
     702else
     703  echo "$ac_t""no" 1>&6
     704fi
     705
     706if test x"$PERL" = x""; then
     707  HAVE_PERL='#'
     708else
     709  HAVE_PERL=''
     710fi
     711
     712
     713
    584714# Make sure we can run config.sub.
    585715if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
     
    588718
    589719echo $ac_n "checking host system type""... $ac_c" 1>&6
    590 echo "configure:591: checking host system type" >&5
     720echo "configure:721: checking host system type" >&5
    591721
    592722host_alias=$host
     
    611741
    612742echo $ac_n "checking build system type""... $ac_c" 1>&6
    613 echo "configure:614: checking build system type" >&5
     743echo "configure:744: checking build system type" >&5
    614744
    615745build_alias=$build
     
    637767set dummy ${ac_tool_prefix}ar; ac_word=$2
    638768echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
    639 echo "configure:640: checking for $ac_word" >&5
     769echo "configure:770: checking for $ac_word" >&5
    640770if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
    641771  echo $ac_n "(cached) $ac_c" 1>&6
     
    669799set dummy ${ac_tool_prefix}ranlib; ac_word=$2
    670800echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
    671 echo "configure:672: checking for $ac_word" >&5
     801echo "configure:802: checking for $ac_word" >&5
    672802if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
    673803  echo $ac_n "(cached) $ac_c" 1>&6
     
    701831set dummy ranlib; ac_word=$2
    702832echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
    703 echo "configure:704: checking for $ac_word" >&5
     833echo "configure:834: checking for $ac_word" >&5
    704834if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
    705835  echo $ac_n "(cached) $ac_c" 1>&6
     
    738868set dummy gcc; ac_word=$2
    739869echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
    740 echo "configure:741: checking for $ac_word" >&5
     870echo "configure:871: checking for $ac_word" >&5
    741871if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
    742872  echo $ac_n "(cached) $ac_c" 1>&6
     
    768898set dummy cc; ac_word=$2
    769899echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
    770 echo "configure:771: checking for $ac_word" >&5
     900echo "configure:901: checking for $ac_word" >&5
    771901if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
    772902  echo $ac_n "(cached) $ac_c" 1>&6
     
    817947
    818948echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
    819 echo "configure:820: checking whether we are using GNU C" >&5
     949echo "configure:950: checking whether we are using GNU C" >&5
    820950if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
    821951  echo $ac_n "(cached) $ac_c" 1>&6
     
    826956#endif
    827957EOF
    828 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:829: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
     958if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:959: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
    829959  ac_cv_prog_gcc=yes
    830960else
     
    842972  CFLAGS=
    843973  echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
    844 echo "configure:845: checking whether ${CC-cc} accepts -g" >&5
     974echo "configure:975: checking whether ${CC-cc} accepts -g" >&5
    845975if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
    846976  echo $ac_n "(cached) $ac_c" 1>&6
     
    8721002
    8731003
     1004if test "x$CC" != xcc; then
     1005  echo $ac_n "checking whether $CC and cc understand -c and -o together""... $ac_c" 1>&6
     1006echo "configure:1007: checking whether $CC and cc understand -c and -o together" >&5
     1007else
     1008  echo $ac_n "checking whether cc understands -c and -o together""... $ac_c" 1>&6
     1009echo "configure:1010: checking whether cc understands -c and -o together" >&5
     1010fi
     1011set dummy $CC; ac_cc="`echo $2 |
     1012                       sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`"
     1013if eval "test \"`echo '$''{'ac_cv_prog_cc_${ac_cc}_c_o'+set}'`\" = set"; then
     1014  echo $ac_n "(cached) $ac_c" 1>&6
     1015else
     1016  echo 'foo(){}' > conftest.c
     1017# Make sure it works both with $CC and with simple cc.
     1018# We do the test twice because some compilers refuse to overwrite an
     1019# existing .o file with -o, though they will create one.
     1020ac_try='${CC-cc} -c conftest.c -o conftest.o 1>&5'
     1021if { (eval echo configure:1022: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
     1022   test -f conftest.o && { (eval echo configure:1023: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
     1023then
     1024  eval ac_cv_prog_cc_${ac_cc}_c_o=yes
     1025  if test "x$CC" != xcc; then
     1026    # Test first that cc exists at all.
     1027    if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:1028: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
     1028      ac_try='cc -c conftest.c -o conftest.o 1>&5'
     1029      if { (eval echo configure:1030: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
     1030         test -f conftest.o && { (eval echo configure:1031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
     1031      then
     1032        # cc works too.
     1033        :
     1034      else
     1035        # cc exists but doesn't like -o.
     1036        eval ac_cv_prog_cc_${ac_cc}_c_o=no
     1037      fi
     1038    fi
     1039  fi
     1040else
     1041  eval ac_cv_prog_cc_${ac_cc}_c_o=no
     1042fi
     1043rm -f conftest*
     1044
     1045fi
     1046if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = yes"; then
     1047  echo "$ac_t""yes" 1>&6
     1048else
     1049  echo "$ac_t""no" 1>&6
     1050  cat >> confdefs.h <<\EOF
     1051#define NO_MINUS_C_MINUS_O 1
     1052EOF
     1053
     1054fi
     1055
     1056# autoconf is lame and doesn't give us any substitution variable for this.
     1057if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then
     1058  NO_MINUS_C_MINUS_O=yes
     1059else
     1060  OUTPUT_OPTION='-o $@'
     1061fi
     1062
     1063
     1064
    8741065echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
    875 echo "configure:876: checking for POSIXized ISC" >&5
     1066echo "configure:1067: checking for POSIXized ISC" >&5
    8761067if test -d /etc/conf/kconfig.d &&
    8771068  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
     
    8941085
    8951086echo $ac_n "checking for working const""... $ac_c" 1>&6
    896 echo "configure:897: checking for working const" >&5
     1087echo "configure:1088: checking for working const" >&5
    8971088if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
    8981089  echo $ac_n "(cached) $ac_c" 1>&6
    8991090else
    9001091  cat > conftest.$ac_ext <<EOF
    901 #line 902 "configure"
     1092#line 1093 "configure"
    9021093#include "confdefs.h"
    9031094
     
    9481139; return 0; }
    9491140EOF
    950 if { (eval echo configure:951: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     1141if { (eval echo configure:1142: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
    9511142  rm -rf conftest*
    9521143  ac_cv_c_const=yes
     
    9691160
    9701161echo $ac_n "checking for inline""... $ac_c" 1>&6
    971 echo "configure:972: checking for inline" >&5
     1162echo "configure:1163: checking for inline" >&5
    9721163if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
    9731164  echo $ac_n "(cached) $ac_c" 1>&6
     
    9761167for ac_kw in inline __inline__ __inline; do
    9771168  cat > conftest.$ac_ext <<EOF
    978 #line 979 "configure"
     1169#line 1170 "configure"
    9791170#include "confdefs.h"
    9801171
     
    9831174; return 0; }
    9841175EOF
    985 if { (eval echo configure:986: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     1176if { (eval echo configure:1177: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
    9861177  rm -rf conftest*
    9871178  ac_cv_c_inline=$ac_kw; break
     
    10261217# ./install, which can be erroneously created by make from ./install.sh.
    10271218echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
    1028 echo "configure:1029: checking for a BSD compatible install" >&5
     1219echo "configure:1220: checking for a BSD compatible install" >&5
    10291220if test -z "$INSTALL"; then
    10301221if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
     
    10871278# something.
    10881279echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
    1089 echo "configure:1090: checking how to run the C preprocessor" >&5
     1280echo "configure:1281: checking how to run the C preprocessor" >&5
    10901281# On Suns, sometimes $CPP names a directory.
    10911282if test -n "$CPP" && test -d "$CPP"; then
     
    11021293  # not just through cpp.
    11031294  cat > conftest.$ac_ext <<EOF
    1104 #line 1105 "configure"
     1295#line 1296 "configure"
    11051296#include "confdefs.h"
    11061297#include <assert.h>
     
    11081299EOF
    11091300ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
    1110 { (eval echo configure:1111: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     1301{ (eval echo configure:1302: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
    11111302ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
    11121303if test -z "$ac_err"; then
     
    11191310  CPP="${CC-cc} -E -traditional-cpp"
    11201311  cat > conftest.$ac_ext <<EOF
    1121 #line 1122 "configure"
     1312#line 1313 "configure"
    11221313#include "confdefs.h"
    11231314#include <assert.h>
     
    11251316EOF
    11261317ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
    1127 { (eval echo configure:1128: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     1318{ (eval echo configure:1319: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
    11281319ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
    11291320if test -z "$ac_err"; then
     
    11361327  CPP="${CC-cc} -nologo -E"
    11371328  cat > conftest.$ac_ext <<EOF
    1138 #line 1139 "configure"
     1329#line 1330 "configure"
    11391330#include "confdefs.h"
    11401331#include <assert.h>
     
    11421333EOF
    11431334ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
    1144 { (eval echo configure:1145: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     1335{ (eval echo configure:1336: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
    11451336ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
    11461337if test -z "$ac_err"; then
     
    11661357echo "$ac_t""$CPP" 1>&6
    11671358
    1168 for ac_hdr in sys/file.h sys/param.h limits.h stdlib.h string.h unistd.h strings.h sys/time.h time.h sys/resource.h sys/stat.h sys/mman.h fcntl.h
     1359for ac_hdr in sys/file.h sys/param.h limits.h stdlib.h string.h unistd.h strings.h sys/time.h time.h sys/resource.h sys/stat.h sys/mman.h fcntl.h alloca.h sys/pstat.h sys/sysmp.h sys/sysinfo.h machine/hal_sysinfo.h sys/table.h sys/sysctl.h sys/systemcfg.h
    11691360do
    11701361ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
    11711362echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
    1172 echo "configure:1173: checking for $ac_hdr" >&5
     1363echo "configure:1364: checking for $ac_hdr" >&5
    11731364if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
    11741365  echo $ac_n "(cached) $ac_c" 1>&6
    11751366else
    11761367  cat > conftest.$ac_ext <<EOF
    1177 #line 1178 "configure"
     1368#line 1369 "configure"
    11781369#include "confdefs.h"
    11791370#include <$ac_hdr>
    11801371EOF
    11811372ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
    1182 { (eval echo configure:1183: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     1373{ (eval echo configure:1374: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
    11831374ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
    11841375if test -z "$ac_err"; then
     
    12071398
    12081399echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
    1209 echo "configure:1210: checking for sys/wait.h that is POSIX.1 compatible" >&5
     1400echo "configure:1401: checking for sys/wait.h that is POSIX.1 compatible" >&5
    12101401if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
    12111402  echo $ac_n "(cached) $ac_c" 1>&6
    12121403else
    12131404  cat > conftest.$ac_ext <<EOF
    1214 #line 1215 "configure"
     1405#line 1406 "configure"
    12151406#include "confdefs.h"
    12161407#include <sys/types.h>
     
    12281419; return 0; }
    12291420EOF
    1230 if { (eval echo configure:1231: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     1421if { (eval echo configure:1422: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
    12311422  rm -rf conftest*
    12321423  ac_cv_header_sys_wait_h=yes
     
    12491440
    12501441echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
    1251 echo "configure:1252: checking whether time.h and sys/time.h may both be included" >&5
     1442echo "configure:1443: checking whether time.h and sys/time.h may both be included" >&5
    12521443if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
    12531444  echo $ac_n "(cached) $ac_c" 1>&6
    12541445else
    12551446  cat > conftest.$ac_ext <<EOF
    1256 #line 1257 "configure"
     1447#line 1448 "configure"
    12571448#include "confdefs.h"
    12581449#include <sys/types.h>
     
    12631454; return 0; }
    12641455EOF
    1265 if { (eval echo configure:1266: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     1456if { (eval echo configure:1457: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
    12661457  rm -rf conftest*
    12671458  ac_cv_header_time=yes
     
    12851476
    12861477echo $ac_n "checking whether errno must be declared""... $ac_c" 1>&6
    1287 echo "configure:1288: checking whether errno must be declared" >&5
     1478echo "configure:1479: checking whether errno must be declared" >&5
    12881479if eval "test \"`echo '$''{'libiberty_cv_declare_errno'+set}'`\" = set"; then
    12891480  echo $ac_n "(cached) $ac_c" 1>&6
    12901481else
    12911482  cat > conftest.$ac_ext <<EOF
    1292 #line 1293 "configure"
     1483#line 1484 "configure"
    12931484#include "confdefs.h"
    12941485#include <errno.h>
     
    12971488; return 0; }
    12981489EOF
    1299 if { (eval echo configure:1300: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     1490if { (eval echo configure:1491: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
    13001491  rm -rf conftest*
    13011492  libiberty_cv_declare_errno=no
     
    13131504then cat >> confdefs.h <<\EOF
    13141505#define NEED_DECLARATION_ERRNO 1
     1506EOF
     1507
     1508fi
     1509
     1510
     1511echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
     1512echo "configure:1513: checking for ANSI C header files" >&5
     1513if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
     1514  echo $ac_n "(cached) $ac_c" 1>&6
     1515else
     1516  cat > conftest.$ac_ext <<EOF
     1517#line 1518 "configure"
     1518#include "confdefs.h"
     1519#include <stdlib.h>
     1520#include <stdarg.h>
     1521#include <string.h>
     1522#include <float.h>
     1523EOF
     1524ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     1525{ (eval echo configure:1526: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     1526ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     1527if test -z "$ac_err"; then
     1528  rm -rf conftest*
     1529  ac_cv_header_stdc=yes
     1530else
     1531  echo "$ac_err" >&5
     1532  echo "configure: failed program was:" >&5
     1533  cat conftest.$ac_ext >&5
     1534  rm -rf conftest*
     1535  ac_cv_header_stdc=no
     1536fi
     1537rm -f conftest*
     1538
     1539if test $ac_cv_header_stdc = yes; then
     1540  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
     1541cat > conftest.$ac_ext <<EOF
     1542#line 1543 "configure"
     1543#include "confdefs.h"
     1544#include <string.h>
     1545EOF
     1546if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
     1547  egrep "memchr" >/dev/null 2>&1; then
     1548  :
     1549else
     1550  rm -rf conftest*
     1551  ac_cv_header_stdc=no
     1552fi
     1553rm -f conftest*
     1554
     1555fi
     1556
     1557if test $ac_cv_header_stdc = yes; then
     1558  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
     1559cat > conftest.$ac_ext <<EOF
     1560#line 1561 "configure"
     1561#include "confdefs.h"
     1562#include <stdlib.h>
     1563EOF
     1564if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
     1565  egrep "free" >/dev/null 2>&1; then
     1566  :
     1567else
     1568  rm -rf conftest*
     1569  ac_cv_header_stdc=no
     1570fi
     1571rm -f conftest*
     1572
     1573fi
     1574
     1575if test $ac_cv_header_stdc = yes; then
     1576  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
     1577if test "$cross_compiling" = yes; then
     1578  :
     1579else
     1580  cat > conftest.$ac_ext <<EOF
     1581#line 1582 "configure"
     1582#include "confdefs.h"
     1583#include <ctype.h>
     1584#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
     1585#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
     1586#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
     1587int main () { int i; for (i = 0; i < 256; i++)
     1588if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
     1589exit (0); }
     1590
     1591EOF
     1592if { (eval echo configure:1593: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     1593then
     1594  :
     1595else
     1596  echo "configure: failed program was:" >&5
     1597  cat conftest.$ac_ext >&5
     1598  rm -fr conftest*
     1599  ac_cv_header_stdc=no
     1600fi
     1601rm -fr conftest*
     1602fi
     1603
     1604fi
     1605fi
     1606
     1607echo "$ac_t""$ac_cv_header_stdc" 1>&6
     1608if test $ac_cv_header_stdc = yes; then
     1609  cat >> confdefs.h <<\EOF
     1610#define STDC_HEADERS 1
     1611EOF
     1612
     1613fi
     1614
     1615echo $ac_n "checking for uintptr_t""... $ac_c" 1>&6
     1616echo "configure:1617: checking for uintptr_t" >&5
     1617if eval "test \"`echo '$''{'ac_cv_type_uintptr_t'+set}'`\" = set"; then
     1618  echo $ac_n "(cached) $ac_c" 1>&6
     1619else
     1620  cat > conftest.$ac_ext <<EOF
     1621#line 1622 "configure"
     1622#include "confdefs.h"
     1623#include <sys/types.h>
     1624#if STDC_HEADERS
     1625#include <stdlib.h>
     1626#include <stddef.h>
     1627#endif
     1628EOF
     1629if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
     1630  egrep "(^|[^a-zA-Z_0-9])uintptr_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
     1631  rm -rf conftest*
     1632  ac_cv_type_uintptr_t=yes
     1633else
     1634  rm -rf conftest*
     1635  ac_cv_type_uintptr_t=no
     1636fi
     1637rm -f conftest*
     1638
     1639fi
     1640echo "$ac_t""$ac_cv_type_uintptr_t" 1>&6
     1641if test $ac_cv_type_uintptr_t = no; then
     1642  cat >> confdefs.h <<\EOF
     1643#define uintptr_t unsigned long
     1644EOF
     1645
     1646fi
     1647
     1648# Given the above check, we always have uintptr_t or a fallback
     1649# definition.  So define HAVE_UINTPTR_T in case any imported code
     1650# relies on it.
     1651cat >> confdefs.h <<\EOF
     1652#define HAVE_UINTPTR_T 1
     1653EOF
     1654
     1655
     1656echo $ac_n "checking for pid_t""... $ac_c" 1>&6
     1657echo "configure:1658: checking for pid_t" >&5
     1658if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
     1659  echo $ac_n "(cached) $ac_c" 1>&6
     1660else
     1661  cat > conftest.$ac_ext <<EOF
     1662#line 1663 "configure"
     1663#include "confdefs.h"
     1664#include <sys/types.h>
     1665#if STDC_HEADERS
     1666#include <stdlib.h>
     1667#include <stddef.h>
     1668#endif
     1669EOF
     1670if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
     1671  egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
     1672  rm -rf conftest*
     1673  ac_cv_type_pid_t=yes
     1674else
     1675  rm -rf conftest*
     1676  ac_cv_type_pid_t=no
     1677fi
     1678rm -f conftest*
     1679
     1680fi
     1681echo "$ac_t""$ac_cv_type_pid_t" 1>&6
     1682if test $ac_cv_type_pid_t = no; then
     1683  cat >> confdefs.h <<\EOF
     1684#define pid_t int
    13151685EOF
    13161686
     
    13301700funcs="$funcs calloc"
    13311701funcs="$funcs clock"
     1702funcs="$funcs ffs"
    13321703funcs="$funcs getcwd"
    13331704funcs="$funcs getpagesize"
     
    13381709funcs="$funcs memcpy"
    13391710funcs="$funcs memmove"
     1711funcs="$funcs mempcpy"
    13401712funcs="$funcs memset"
    13411713funcs="$funcs mkstemps"
     
    13451717funcs="$funcs rindex"
    13461718funcs="$funcs setenv"
     1719funcs="$funcs snprintf"
    13471720funcs="$funcs sigsetmask"
     1721funcs="$funcs stpcpy"
     1722funcs="$funcs stpncpy"
    13481723funcs="$funcs strcasecmp"
    13491724funcs="$funcs strchr"
     
    13591734funcs="$funcs vfprintf"
    13601735funcs="$funcs vprintf"
     1736funcs="$funcs vsnprintf"
    13611737funcs="$funcs vsprintf"
    13621738funcs="$funcs waitpid"
     
    13641740# Also in the old function.def file: alloca, vfork, getopt.
    13651741
    1366 vars="sys_errlist sys_nerr sys_siglist"
     1742vars="sys_errlist sys_nerr sys_siglist _system_configuration"
    13671743
    13681744checkfuncs="getrusage on_exit psignal strerror strsignal sysconf times sbrk gettimeofday"
     1745checkfuncs="$checkfuncs realpath canonicalize_file_name pstat_getstatic pstat_getdynamic sysmp"
     1746checkfuncs="$checkfuncs getsysinfo table sysctl"
    13691747
    13701748# These are neither executed nor required, but they help keep
     
    13741752do
    13751753echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    1376 echo "configure:1377: checking for $ac_func" >&5
     1754echo "configure:1755: checking for $ac_func" >&5
    13771755if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    13781756  echo $ac_n "(cached) $ac_c" 1>&6
    13791757else
    13801758  cat > conftest.$ac_ext <<EOF
    1381 #line 1382 "configure"
     1759#line 1760 "configure"
    13821760#include "confdefs.h"
    13831761/* System header to define __stub macros and hopefully few prototypes,
     
    14021780; return 0; }
    14031781EOF
    1404 if { (eval echo configure:1405: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     1782if { (eval echo configure:1783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    14051783  rm -rf conftest*
    14061784  eval "ac_cv_func_$ac_func=yes"
     
    14291807do
    14301808echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    1431 echo "configure:1432: checking for $ac_func" >&5
     1809echo "configure:1810: checking for $ac_func" >&5
    14321810if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    14331811  echo $ac_n "(cached) $ac_c" 1>&6
    14341812else
    14351813  cat > conftest.$ac_ext <<EOF
    1436 #line 1437 "configure"
     1814#line 1815 "configure"
    14371815#include "confdefs.h"
    14381816/* System header to define __stub macros and hopefully few prototypes,
     
    14571835; return 0; }
    14581836EOF
    1459 if { (eval echo configure:1460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     1837if { (eval echo configure:1838: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    14601838  rm -rf conftest*
    14611839  eval "ac_cv_func_$ac_func=yes"
     
    14811859done
    14821860
    1483   for ac_func in memmove memset putenv random rename rindex sigsetmask
     1861  for ac_func in memmove mempcpy memset putenv random rename rindex sigsetmask
    14841862do
    14851863echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    1486 echo "configure:1487: checking for $ac_func" >&5
     1864echo "configure:1865: checking for $ac_func" >&5
    14871865if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    14881866  echo $ac_n "(cached) $ac_c" 1>&6
    14891867else
    14901868  cat > conftest.$ac_ext <<EOF
    1491 #line 1492 "configure"
     1869#line 1870 "configure"
    14921870#include "confdefs.h"
    14931871/* System header to define __stub macros and hopefully few prototypes,
     
    15121890; return 0; }
    15131891EOF
    1514 if { (eval echo configure:1515: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     1892if { (eval echo configure:1893: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    15151893  rm -rf conftest*
    15161894  eval "ac_cv_func_$ac_func=yes"
     
    15361914done
    15371915
    1538   for ac_func in strcasecmp setenv strchr strdup strncasecmp strrchr strstr
     1916  for ac_func in strcasecmp setenv stpcpy stpncpy strchr strdup strncasecmp strrchr strstr
    15391917do
    15401918echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    1541 echo "configure:1542: checking for $ac_func" >&5
     1919echo "configure:1920: checking for $ac_func" >&5
    15421920if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    15431921  echo $ac_n "(cached) $ac_c" 1>&6
    15441922else
    15451923  cat > conftest.$ac_ext <<EOF
    1546 #line 1547 "configure"
     1924#line 1925 "configure"
    15471925#include "confdefs.h"
    15481926/* System header to define __stub macros and hopefully few prototypes,
     
    15671945; return 0; }
    15681946EOF
    1569 if { (eval echo configure:1570: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     1947if { (eval echo configure:1948: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    15701948  rm -rf conftest*
    15711949  eval "ac_cv_func_$ac_func=yes"
     
    15941972do
    15951973echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    1596 echo "configure:1597: checking for $ac_func" >&5
     1974echo "configure:1975: checking for $ac_func" >&5
    15971975if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    15981976  echo $ac_n "(cached) $ac_c" 1>&6
    15991977else
    16001978  cat > conftest.$ac_ext <<EOF
    1601 #line 1602 "configure"
     1979#line 1980 "configure"
    16021980#include "confdefs.h"
    16031981/* System header to define __stub macros and hopefully few prototypes,
     
    16222000; return 0; }
    16232001EOF
    1624 if { (eval echo configure:1625: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2002if { (eval echo configure:2003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    16252003  rm -rf conftest*
    16262004  eval "ac_cv_func_$ac_func=yes"
     
    16492027do
    16502028echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    1651 echo "configure:1652: checking for $ac_func" >&5
     2029echo "configure:2030: checking for $ac_func" >&5
    16522030if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    16532031  echo $ac_n "(cached) $ac_c" 1>&6
    16542032else
    16552033  cat > conftest.$ac_ext <<EOF
    1656 #line 1657 "configure"
     2034#line 2035 "configure"
    16572035#include "confdefs.h"
    16582036/* System header to define __stub macros and hopefully few prototypes,
     
    16772055; return 0; }
    16782056EOF
    1679 if { (eval echo configure:1680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2057if { (eval echo configure:2058: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    16802058  rm -rf conftest*
    16812059  eval "ac_cv_func_$ac_func=yes"
     
    17012079done
    17022080
    1703   for ac_func in sysconf times sbrk gettimeofday
     2081  for ac_func in sysconf times sbrk gettimeofday ffs snprintf vsnprintf
    17042082do
    17052083echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    1706 echo "configure:1707: checking for $ac_func" >&5
     2084echo "configure:2085: checking for $ac_func" >&5
    17072085if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    17082086  echo $ac_n "(cached) $ac_c" 1>&6
    17092087else
    17102088  cat > conftest.$ac_ext <<EOF
    1711 #line 1712 "configure"
     2089#line 2090 "configure"
    17122090#include "confdefs.h"
    17132091/* System header to define __stub macros and hopefully few prototypes,
     
    17322110; return 0; }
    17332111EOF
    1734 if { (eval echo configure:1735: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2112if { (eval echo configure:2113: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    17352113  rm -rf conftest*
    17362114  eval "ac_cv_func_$ac_func=yes"
     
    17562134done
    17572135
     2136  for ac_func in pstat_getstatic pstat_getdynamic sysmp getsysinfo table sysctl
     2137do
     2138echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
     2139echo "configure:2140: checking for $ac_func" >&5
     2140if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
     2141  echo $ac_n "(cached) $ac_c" 1>&6
     2142else
     2143  cat > conftest.$ac_ext <<EOF
     2144#line 2145 "configure"
     2145#include "confdefs.h"
     2146/* System header to define __stub macros and hopefully few prototypes,
     2147    which can conflict with char $ac_func(); below.  */
     2148#include <assert.h>
     2149/* Override any gcc2 internal prototype to avoid an error.  */
     2150/* We use char because int might match the return type of a gcc2
     2151    builtin and then its argument prototype would still apply.  */
     2152char $ac_func();
     2153
     2154int main() {
     2155
     2156/* The GNU C library defines this for functions which it implements
     2157    to always fail with ENOSYS.  Some functions are actually named
     2158    something starting with __ and the normal name is an alias.  */
     2159#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
     2160choke me
     2161#else
     2162$ac_func();
     2163#endif
     2164
     2165; return 0; }
     2166EOF
     2167if { (eval echo configure:2168: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2168  rm -rf conftest*
     2169  eval "ac_cv_func_$ac_func=yes"
     2170else
     2171  echo "configure: failed program was:" >&5
     2172  cat conftest.$ac_ext >&5
     2173  rm -rf conftest*
     2174  eval "ac_cv_func_$ac_func=no"
     2175fi
     2176rm -f conftest*
     2177fi
     2178
     2179if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
     2180  echo "$ac_t""yes" 1>&6
     2181    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
     2182  cat >> confdefs.h <<EOF
     2183#define $ac_tr_func 1
     2184EOF
     2185 
     2186else
     2187  echo "$ac_t""no" 1>&6
     2188fi
     2189done
     2190
     2191  for ac_func in realpath canonicalize_file_name
     2192do
     2193echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
     2194echo "configure:2195: checking for $ac_func" >&5
     2195if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
     2196  echo $ac_n "(cached) $ac_c" 1>&6
     2197else
     2198  cat > conftest.$ac_ext <<EOF
     2199#line 2200 "configure"
     2200#include "confdefs.h"
     2201/* System header to define __stub macros and hopefully few prototypes,
     2202    which can conflict with char $ac_func(); below.  */
     2203#include <assert.h>
     2204/* Override any gcc2 internal prototype to avoid an error.  */
     2205/* We use char because int might match the return type of a gcc2
     2206    builtin and then its argument prototype would still apply.  */
     2207char $ac_func();
     2208
     2209int main() {
     2210
     2211/* The GNU C library defines this for functions which it implements
     2212    to always fail with ENOSYS.  Some functions are actually named
     2213    something starting with __ and the normal name is an alias.  */
     2214#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
     2215choke me
     2216#else
     2217$ac_func();
     2218#endif
     2219
     2220; return 0; }
     2221EOF
     2222if { (eval echo configure:2223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2223  rm -rf conftest*
     2224  eval "ac_cv_func_$ac_func=yes"
     2225else
     2226  echo "configure: failed program was:" >&5
     2227  cat conftest.$ac_ext >&5
     2228  rm -rf conftest*
     2229  eval "ac_cv_func_$ac_func=no"
     2230fi
     2231rm -f conftest*
     2232fi
     2233
     2234if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
     2235  echo "$ac_t""yes" 1>&6
     2236    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
     2237  cat >> confdefs.h <<EOF
     2238#define $ac_tr_func 1
     2239EOF
     2240 
     2241else
     2242  echo "$ac_t""no" 1>&6
     2243fi
     2244done
     2245
    17582246  cat >> confdefs.h <<\EOF
    17592247#define HAVE_SYS_ERRLIST 1
     
    17682256EOF
    17692257
     2258  cat >> confdefs.h <<\EOF
     2259#define HAVE__SYSTEM_CONFIGURATION 1
     2260EOF
     2261
    17702262fi
    17712263
    17722264# For each of these functions, if the host does not provide the
    17732265# function we want to put FN.o in LIBOBJS, and if the host does
    1774 # provide the function, we want to define HAVE_FN in config.h.  Also,
    1775 # if the host does not provide alloca, we set ALLOCA to alloca.o
     2266# provide the function, we want to define HAVE_FN in config.h.
    17762267
    17772268setobjs=
    17782269CHECK=
     2270target_header_dir=
    17792271if test -n "${with_target_subdir}"; then
    17802272
     
    17882280
    17892281  if test "x${with_newlib}" = "xyes"; then
    1790     ALLOCA="alloca.o"
    17912282    LIBOBJS="asprintf.o basename.o insque.o random.o strdup.o vasprintf.o"
    17922283
     
    18182309  fi
    18192310
     2311  # We may wish to install the target headers somewhere.
     2312  # Check whether --enable-install-libiberty or --disable-install-libiberty was given.
     2313if test "${enable_install_libiberty+set}" = set; then
     2314  enableval="$enable_install_libiberty"
     2315  enable_install_libiberty=$enableval
     2316else
     2317  enable_install_libiberty=no
     2318fi
     2319 
     2320  # Option parsed, now set things appropriately.
     2321  case x"$enable_install_libiberty" in
     2322    xyes|x)
     2323      target_header_dir=libiberty
     2324      ;;
     2325    xno)   
     2326      target_header_dir=
     2327      ;;
     2328    *)
     2329      # This could be sanity-checked in various ways...
     2330      target_header_dir="${enable_install_libiberty}"
     2331      ;;
     2332  esac
     2333
     2334
    18202335else
    18212336
     
    18262341
    18272342
     2343
     2344
     2345case "${host}" in
     2346  *-*-cygwin* | *-*-mingw*)
     2347    cat >> confdefs.h <<\EOF
     2348#define HAVE_SYS_ERRLIST 1
     2349EOF
     2350
     2351    cat >> confdefs.h <<\EOF
     2352#define HAVE_SYS_NERR 1
     2353EOF
     2354
     2355    ;;
     2356esac
    18282357
    18292358if test -z "${setobjs}"; then
     
    19132442    ;;
    19142443
     2444  *-*-*vms*)
     2445    # Under VMS, vfork works very different than on Unix. The standard test
     2446    # won't work, and it isn't easily adaptable. It makes more sense to
     2447    # just force it.
     2448    ac_cv_func_vfork_works=yes
     2449    ;;
     2450
    19152451  esac
    19162452
     
    19182454  # tests.  This will only work if the compiler works.
    19192455  echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
    1920 echo "configure:1921: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
     2456echo "configure:2457: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
    19212457
    19222458ac_ext=c
     
    19292465cat > conftest.$ac_ext << EOF
    19302466
    1931 #line 1932 "configure"
     2467#line 2468 "configure"
    19322468#include "confdefs.h"
    19332469
    19342470main(){return(0);}
    19352471EOF
    1936 if { (eval echo configure:1937: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2472if { (eval echo configure:2473: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    19372473  ac_cv_prog_cc_works=yes
    19382474  # If we can't run a trivial program, we are probably using a cross compiler.
     
    19602496fi
    19612497echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
    1962 echo "configure:1963: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
     2498echo "configure:2499: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
    19632499echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
    19642500cross_compiling=$ac_cv_prog_cc_cross
     
    19672503do
    19682504echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    1969 echo "configure:1970: checking for $ac_func" >&5
     2505echo "configure:2506: checking for $ac_func" >&5
    19702506if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    19712507  echo $ac_n "(cached) $ac_c" 1>&6
    19722508else
    19732509  cat > conftest.$ac_ext <<EOF
    1974 #line 1975 "configure"
     2510#line 2511 "configure"
    19752511#include "confdefs.h"
    19762512/* System header to define __stub macros and hopefully few prototypes,
     
    19952531; return 0; }
    19962532EOF
    1997 if { (eval echo configure:1998: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2533if { (eval echo configure:2534: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    19982534  rm -rf conftest*
    19992535  eval "ac_cv_func_$ac_func=yes"
     
    20212557
    20222558
    2023 
    2024   case "${host}" in
    2025   *-*-interix)
    2026     # On Interix, it wrongly concludes that the MSVC compiler supports alloca.
    2027     # (MSVC does on Win32, not on Interix.)
    2028     # This should be temporary.
    2029 
    2030     ac_cv_header_alloca_h=no
    2031     ac_cv_func_alloca_works=no
    2032     ALLOCA=alloca.o
    2033     cat >> confdefs.h <<\EOF
    2034 #define C_ALLOCA 1
    2035 EOF
    2036     cat >> confdefs.h <<EOF
    2037 #define STACK_DIRECTION -1
    2038 EOF
    2039     ;;
    2040   *)
    2041     # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
    2042 # for constant arguments.  Useless!
    2043 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
    2044 echo "configure:2045: checking for working alloca.h" >&5
    2045 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
     2559  echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
     2560echo "configure:2561: checking whether alloca needs Cray hooks" >&5
     2561if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
    20462562  echo $ac_n "(cached) $ac_c" 1>&6
    20472563else
    20482564  cat > conftest.$ac_ext <<EOF
    2049 #line 2050 "configure"
    2050 #include "confdefs.h"
    2051 #include <alloca.h>
    2052 int main() {
    2053 char *p = alloca(2 * sizeof(int));
    2054 ; return 0; }
    2055 EOF
    2056 if { (eval echo configure:2057: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    2057   rm -rf conftest*
    2058   ac_cv_header_alloca_h=yes
    2059 else
    2060   echo "configure: failed program was:" >&5
    2061   cat conftest.$ac_ext >&5
    2062   rm -rf conftest*
    2063   ac_cv_header_alloca_h=no
    2064 fi
    2065 rm -f conftest*
    2066 fi
    2067 
    2068 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
    2069 if test $ac_cv_header_alloca_h = yes; then
    2070   cat >> confdefs.h <<\EOF
    2071 #define HAVE_ALLOCA_H 1
    2072 EOF
    2073 
    2074 fi
    2075 
    2076 echo $ac_n "checking for alloca""... $ac_c" 1>&6
    2077 echo "configure:2078: checking for alloca" >&5
    2078 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
    2079   echo $ac_n "(cached) $ac_c" 1>&6
    2080 else
    2081   cat > conftest.$ac_ext <<EOF
    2082 #line 2083 "configure"
    2083 #include "confdefs.h"
    2084 
    2085 #ifdef __GNUC__
    2086 # define alloca __builtin_alloca
    2087 #else
    2088 # ifdef _MSC_VER
    2089 #  include <malloc.h>
    2090 #  define alloca _alloca
    2091 # else
    2092 #  if HAVE_ALLOCA_H
    2093 #   include <alloca.h>
    2094 #  else
    2095 #   ifdef _AIX
    2096  #pragma alloca
    2097 #   else
    2098 #    ifndef alloca /* predefined by HP cc +Olibcalls */
    2099 char *alloca ();
    2100 #    endif
    2101 #   endif
    2102 #  endif
    2103 # endif
    2104 #endif
    2105 
    2106 int main() {
    2107 char *p = (char *) alloca(1);
    2108 ; return 0; }
    2109 EOF
    2110 if { (eval echo configure:2111: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    2111   rm -rf conftest*
    2112   ac_cv_func_alloca_works=yes
    2113 else
    2114   echo "configure: failed program was:" >&5
    2115   cat conftest.$ac_ext >&5
    2116   rm -rf conftest*
    2117   ac_cv_func_alloca_works=no
    2118 fi
    2119 rm -f conftest*
    2120 fi
    2121 
    2122 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
    2123 if test $ac_cv_func_alloca_works = yes; then
    2124   cat >> confdefs.h <<\EOF
    2125 #define HAVE_ALLOCA 1
    2126 EOF
    2127 
    2128 fi
    2129 
    2130 if test $ac_cv_func_alloca_works = no; then
    2131   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
    2132   # that cause trouble.  Some versions do not even contain alloca or
    2133   # contain a buggy version.  If you still want to use their alloca,
    2134   # use ar to extract alloca.o from them instead of compiling alloca.c.
    2135   ALLOCA=alloca.${ac_objext}
    2136   cat >> confdefs.h <<\EOF
    2137 #define C_ALLOCA 1
    2138 EOF
    2139 
    2140 
    2141 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
    2142 echo "configure:2143: checking whether alloca needs Cray hooks" >&5
    2143 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
    2144   echo $ac_n "(cached) $ac_c" 1>&6
    2145 else
    2146   cat > conftest.$ac_ext <<EOF
    2147 #line 2148 "configure"
     2565#line 2566 "configure"
    21482566#include "confdefs.h"
    21492567#if defined(CRAY) && ! defined(CRAY2)
     
    21682586echo "$ac_t""$ac_cv_os_cray" 1>&6
    21692587if test $ac_cv_os_cray = yes; then
    2170 for ac_func in _getb67 GETB67 getb67; do
    2171   echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    2172 echo "configure:2173: checking for $ac_func" >&5
     2588  for ac_func in _getb67 GETB67 getb67; do
     2589    echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
     2590echo "configure:2591: checking for $ac_func" >&5
    21732591if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    21742592  echo $ac_n "(cached) $ac_c" 1>&6
    21752593else
    21762594  cat > conftest.$ac_ext <<EOF
    2177 #line 2178 "configure"
     2595#line 2596 "configure"
    21782596#include "confdefs.h"
    21792597/* System header to define __stub macros and hopefully few prototypes,
     
    21982616; return 0; }
    21992617EOF
    2200 if { (eval echo configure:2201: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2618if { (eval echo configure:2619: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    22012619  rm -rf conftest*
    22022620  eval "ac_cv_func_$ac_func=yes"
     
    22152633#define CRAY_STACKSEG_END $ac_func
    22162634EOF
    2217 
    22182635  break
    22192636else
     
    22212638fi
    22222639
    2223 done
     2640  done
    22242641fi
    22252642
    22262643echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
    2227 echo "configure:2228: checking stack direction for C alloca" >&5
     2644echo "configure:2645: checking stack direction for C alloca" >&5
    22282645if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
    22292646  echo $ac_n "(cached) $ac_c" 1>&6
     
    22332650else
    22342651  cat > conftest.$ac_ext <<EOF
    2235 #line 2236 "configure"
     2652#line 2653 "configure"
    22362653#include "confdefs.h"
    22372654find_stack_direction ()
     
    22522669}
    22532670EOF
    2254 if { (eval echo configure:2255: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     2671if { (eval echo configure:2672: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
    22552672then
    22562673  ac_cv_c_stack_direction=1
     
    22712688EOF
    22722689
    2273 fi
    2274 
    2275     ;;
    2276   esac
    2277 
    2278   echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
    2279 echo "configure:2280: checking for ANSI C header files" >&5
    2280 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
     2690
     2691  ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
     2692echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
     2693echo "configure:2694: checking for vfork.h" >&5
     2694if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
    22812695  echo $ac_n "(cached) $ac_c" 1>&6
    22822696else
    22832697  cat > conftest.$ac_ext <<EOF
    2284 #line 2285 "configure"
    2285 #include "confdefs.h"
    2286 #include <stdlib.h>
    2287 #include <stdarg.h>
    2288 #include <string.h>
    2289 #include <float.h>
     2698#line 2699 "configure"
     2699#include "confdefs.h"
     2700#include <vfork.h>
    22902701EOF
    22912702ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
    2292 { (eval echo configure:2293: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
    2293 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
    2294 if test -z "$ac_err"; then
    2295   rm -rf conftest*
    2296   ac_cv_header_stdc=yes
    2297 else
    2298   echo "$ac_err" >&5
    2299   echo "configure: failed program was:" >&5
    2300   cat conftest.$ac_ext >&5
    2301   rm -rf conftest*
    2302   ac_cv_header_stdc=no
    2303 fi
    2304 rm -f conftest*
    2305 
    2306 if test $ac_cv_header_stdc = yes; then
    2307   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
    2308 cat > conftest.$ac_ext <<EOF
    2309 #line 2310 "configure"
    2310 #include "confdefs.h"
    2311 #include <string.h>
    2312 EOF
    2313 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
    2314   egrep "memchr" >/dev/null 2>&1; then
    2315   :
    2316 else
    2317   rm -rf conftest*
    2318   ac_cv_header_stdc=no
    2319 fi
    2320 rm -f conftest*
    2321 
    2322 fi
    2323 
    2324 if test $ac_cv_header_stdc = yes; then
    2325   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
    2326 cat > conftest.$ac_ext <<EOF
    2327 #line 2328 "configure"
    2328 #include "confdefs.h"
    2329 #include <stdlib.h>
    2330 EOF
    2331 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
    2332   egrep "free" >/dev/null 2>&1; then
    2333   :
    2334 else
    2335   rm -rf conftest*
    2336   ac_cv_header_stdc=no
    2337 fi
    2338 rm -f conftest*
    2339 
    2340 fi
    2341 
    2342 if test $ac_cv_header_stdc = yes; then
    2343   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
    2344 if test "$cross_compiling" = yes; then
    2345   :
    2346 else
    2347   cat > conftest.$ac_ext <<EOF
    2348 #line 2349 "configure"
    2349 #include "confdefs.h"
    2350 #include <ctype.h>
    2351 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
    2352 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
    2353 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
    2354 int main () { int i; for (i = 0; i < 256; i++)
    2355 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
    2356 exit (0); }
    2357 
    2358 EOF
    2359 if { (eval echo configure:2360: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
    2360 then
    2361   :
    2362 else
    2363   echo "configure: failed program was:" >&5
    2364   cat conftest.$ac_ext >&5
    2365   rm -fr conftest*
    2366   ac_cv_header_stdc=no
    2367 fi
    2368 rm -fr conftest*
    2369 fi
    2370 
    2371 fi
    2372 fi
    2373 
    2374 echo "$ac_t""$ac_cv_header_stdc" 1>&6
    2375 if test $ac_cv_header_stdc = yes; then
    2376   cat >> confdefs.h <<\EOF
    2377 #define STDC_HEADERS 1
    2378 EOF
    2379 
    2380 fi
    2381 
    2382 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
    2383 echo "configure:2384: checking for pid_t" >&5
    2384 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
    2385   echo $ac_n "(cached) $ac_c" 1>&6
    2386 else
    2387   cat > conftest.$ac_ext <<EOF
    2388 #line 2389 "configure"
    2389 #include "confdefs.h"
    2390 #include <sys/types.h>
    2391 #if STDC_HEADERS
    2392 #include <stdlib.h>
    2393 #include <stddef.h>
    2394 #endif
    2395 EOF
    2396 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
    2397   egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
    2398   rm -rf conftest*
    2399   ac_cv_type_pid_t=yes
    2400 else
    2401   rm -rf conftest*
    2402   ac_cv_type_pid_t=no
    2403 fi
    2404 rm -f conftest*
    2405 
    2406 fi
    2407 echo "$ac_t""$ac_cv_type_pid_t" 1>&6
    2408 if test $ac_cv_type_pid_t = no; then
    2409   cat >> confdefs.h <<\EOF
    2410 #define pid_t int
    2411 EOF
    2412 
    2413 fi
    2414 
    2415 ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
    2416 echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
    2417 echo "configure:2418: checking for vfork.h" >&5
    2418 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
    2419   echo $ac_n "(cached) $ac_c" 1>&6
    2420 else
    2421   cat > conftest.$ac_ext <<EOF
    2422 #line 2423 "configure"
    2423 #include "confdefs.h"
    2424 #include <vfork.h>
    2425 EOF
    2426 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
    2427 { (eval echo configure:2428: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     2703{ (eval echo configure:2704: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
    24282704ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
    24292705if test -z "$ac_err"; then
     
    24502726
    24512727echo $ac_n "checking for working vfork""... $ac_c" 1>&6
    2452 echo "configure:2453: checking for working vfork" >&5
     2728echo "configure:2729: checking for working vfork" >&5
    24532729if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
    24542730  echo $ac_n "(cached) $ac_c" 1>&6
     
    24562732  if test "$cross_compiling" = yes; then
    24572733  echo $ac_n "checking for vfork""... $ac_c" 1>&6
    2458 echo "configure:2459: checking for vfork" >&5
     2734echo "configure:2735: checking for vfork" >&5
    24592735if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
    24602736  echo $ac_n "(cached) $ac_c" 1>&6
    24612737else
    24622738  cat > conftest.$ac_ext <<EOF
    2463 #line 2464 "configure"
     2739#line 2740 "configure"
    24642740#include "confdefs.h"
    24652741/* System header to define __stub macros and hopefully few prototypes,
     
    24842760; return 0; }
    24852761EOF
    2486 if { (eval echo configure:2487: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2762if { (eval echo configure:2763: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    24872763  rm -rf conftest*
    24882764  eval "ac_cv_func_vfork=yes"
     
    25062782else
    25072783  cat > conftest.$ac_ext <<EOF
    2508 #line 2509 "configure"
     2784#line 2785 "configure"
    25092785#include "confdefs.h"
    25102786/* Thanks to Paul Eggert for this test.  */
     
    26012877}
    26022878EOF
    2603 if { (eval echo configure:2604: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     2879if { (eval echo configure:2880: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
    26042880then
    26052881  ac_cv_func_vfork_works=yes
     
    26262902    LIBOBJS="$LIBOBJS vfork.o"
    26272903  fi
    2628   for v in $vars; do
    2629     echo $ac_n "checking for $v""... $ac_c" 1>&6
    2630 echo "configure:2631: checking for $v" >&5
    2631     if eval "test \"`echo '$''{'libiberty_cv_var_$v'+set}'`\" = set"; then
    2632   echo $ac_n "(cached) $ac_c" 1>&6
    2633 else
    2634   cat > conftest.$ac_ext <<EOF
    2635 #line 2636 "configure"
    2636 #include "confdefs.h"
    2637 int *p;
    2638 int main() {
    2639 extern int $v; p = &$v;
    2640 ; return 0; }
    2641 EOF
    2642 if { (eval echo configure:2643: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    2643   rm -rf conftest*
    2644   eval "libiberty_cv_var_$v=yes"
    2645 else
    2646   echo "configure: failed program was:" >&5
    2647   cat conftest.$ac_ext >&5
    2648   rm -rf conftest*
    2649   eval "libiberty_cv_var_$v=no"
    2650 fi
    2651 rm -f conftest*
    2652 fi
    2653 
    2654     if eval "test \"`echo '$libiberty_cv_var_'$v`\" = yes"; then
    2655       echo "$ac_t""yes" 1>&6
    2656       n=HAVE_`echo $v | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
    2657       cat >> confdefs.h <<EOF
    2658 #define $n 1
    2659 EOF
    2660 
    2661     else
    2662       echo "$ac_t""no" 1>&6
    2663     fi
    2664   done
    2665   for ac_func in $checkfuncs
     2904  # We only need _doprnt if we might use it to implement v*printf.
     2905  if test $ac_cv_func_vprintf != yes \
     2906     || test $ac_cv_func_vfprintf != yes \
     2907     || test $ac_cv_func_vsprintf != yes; then
     2908    for ac_func in _doprnt
    26662909do
    26672910echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    2668 echo "configure:2669: checking for $ac_func" >&5
     2911echo "configure:2912: checking for $ac_func" >&5
    26692912if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    26702913  echo $ac_n "(cached) $ac_c" 1>&6
    26712914else
    26722915  cat > conftest.$ac_ext <<EOF
    2673 #line 2674 "configure"
     2916#line 2917 "configure"
    26742917#include "confdefs.h"
    26752918/* System header to define __stub macros and hopefully few prototypes,
     
    26942937; return 0; }
    26952938EOF
    2696 if { (eval echo configure:2697: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2939if { (eval echo configure:2940: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    26972940  rm -rf conftest*
    26982941  eval "ac_cv_func_$ac_func=yes"
     
    27152958else
    27162959  echo "$ac_t""no" 1>&6
     2960LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
    27172961fi
    27182962done
    27192963
    2720 fi
    2721 
    2722 for ac_hdr in unistd.h
    2723 do
    2724 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
    2725 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
    2726 echo "configure:2727: checking for $ac_hdr" >&5
    2727 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
    2728   echo $ac_n "(cached) $ac_c" 1>&6
    2729 else
    2730   cat > conftest.$ac_ext <<EOF
    2731 #line 2732 "configure"
    2732 #include "confdefs.h"
    2733 #include <$ac_hdr>
    2734 EOF
    2735 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
    2736 { (eval echo configure:2737: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
    2737 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
    2738 if test -z "$ac_err"; then
    2739   rm -rf conftest*
    2740   eval "ac_cv_header_$ac_safe=yes"
    2741 else
    2742   echo "$ac_err" >&5
    2743   echo "configure: failed program was:" >&5
    2744   cat conftest.$ac_ext >&5
    2745   rm -rf conftest*
    2746   eval "ac_cv_header_$ac_safe=no"
    2747 fi
    2748 rm -f conftest*
    2749 fi
    2750 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
    2751   echo "$ac_t""yes" 1>&6
    2752     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
    2753   cat >> confdefs.h <<EOF
    2754 #define $ac_tr_hdr 1
    2755 EOF
    2756  
    2757 else
    2758   echo "$ac_t""no" 1>&6
    2759 fi
    2760 done
    2761 
    2762 for ac_func in getpagesize
     2964
     2965  else
     2966    for ac_func in _doprnt
    27632967do
    27642968echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
    2765 echo "configure:2766: checking for $ac_func" >&5
     2969echo "configure:2970: checking for $ac_func" >&5
    27662970if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
    27672971  echo $ac_n "(cached) $ac_c" 1>&6
    27682972else
    27692973  cat > conftest.$ac_ext <<EOF
    2770 #line 2771 "configure"
     2974#line 2975 "configure"
    27712975#include "confdefs.h"
    27722976/* System header to define __stub macros and hopefully few prototypes,
     
    27912995; return 0; }
    27922996EOF
    2793 if { (eval echo configure:2794: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     2997if { (eval echo configure:2998: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
    27942998  rm -rf conftest*
    27952999  eval "ac_cv_func_$ac_func=yes"
     
    28153019done
    28163020
     3021  fi
     3022
     3023  for v in $vars; do
     3024    echo $ac_n "checking for $v""... $ac_c" 1>&6
     3025echo "configure:3026: checking for $v" >&5
     3026    if eval "test \"`echo '$''{'libiberty_cv_var_$v'+set}'`\" = set"; then
     3027  echo $ac_n "(cached) $ac_c" 1>&6
     3028else
     3029  cat > conftest.$ac_ext <<EOF
     3030#line 3031 "configure"
     3031#include "confdefs.h"
     3032int *p;
     3033int main() {
     3034extern int $v []; p = $v;
     3035; return 0; }
     3036EOF
     3037if { (eval echo configure:3038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     3038  rm -rf conftest*
     3039  eval "libiberty_cv_var_$v=yes"
     3040else
     3041  echo "configure: failed program was:" >&5
     3042  cat conftest.$ac_ext >&5
     3043  rm -rf conftest*
     3044  eval "libiberty_cv_var_$v=no"
     3045fi
     3046rm -f conftest*
     3047fi
     3048
     3049    if eval "test \"`echo '$libiberty_cv_var_'$v`\" = yes"; then
     3050      echo "$ac_t""yes" 1>&6
     3051      n=HAVE_`echo $v | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
     3052      cat >> confdefs.h <<EOF
     3053#define $n 1
     3054EOF
     3055
     3056    else
     3057      echo "$ac_t""no" 1>&6
     3058    fi
     3059  done
     3060  for ac_func in $checkfuncs
     3061do
     3062echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
     3063echo "configure:3064: checking for $ac_func" >&5
     3064if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
     3065  echo $ac_n "(cached) $ac_c" 1>&6
     3066else
     3067  cat > conftest.$ac_ext <<EOF
     3068#line 3069 "configure"
     3069#include "confdefs.h"
     3070/* System header to define __stub macros and hopefully few prototypes,
     3071    which can conflict with char $ac_func(); below.  */
     3072#include <assert.h>
     3073/* Override any gcc2 internal prototype to avoid an error.  */
     3074/* We use char because int might match the return type of a gcc2
     3075    builtin and then its argument prototype would still apply.  */
     3076char $ac_func();
     3077
     3078int main() {
     3079
     3080/* The GNU C library defines this for functions which it implements
     3081    to always fail with ENOSYS.  Some functions are actually named
     3082    something starting with __ and the normal name is an alias.  */
     3083#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
     3084choke me
     3085#else
     3086$ac_func();
     3087#endif
     3088
     3089; return 0; }
     3090EOF
     3091if { (eval echo configure:3092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     3092  rm -rf conftest*
     3093  eval "ac_cv_func_$ac_func=yes"
     3094else
     3095  echo "configure: failed program was:" >&5
     3096  cat conftest.$ac_ext >&5
     3097  rm -rf conftest*
     3098  eval "ac_cv_func_$ac_func=no"
     3099fi
     3100rm -f conftest*
     3101fi
     3102
     3103if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
     3104  echo "$ac_t""yes" 1>&6
     3105    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
     3106  cat >> confdefs.h <<EOF
     3107#define $ac_tr_func 1
     3108EOF
     3109 
     3110else
     3111  echo "$ac_t""no" 1>&6
     3112fi
     3113done
     3114
     3115  echo $ac_n "checking whether canonicalize_file_name must be declared""... $ac_c" 1>&6
     3116echo "configure:3117: checking whether canonicalize_file_name must be declared" >&5
     3117if eval "test \"`echo '$''{'libiberty_cv_decl_needed_canonicalize_file_name'+set}'`\" = set"; then
     3118  echo $ac_n "(cached) $ac_c" 1>&6
     3119else
     3120  cat > conftest.$ac_ext <<EOF
     3121#line 3122 "configure"
     3122#include "confdefs.h"
     3123
     3124#include "confdefs.h"
     3125#include <stdio.h>
     3126#ifdef HAVE_STRING_H
     3127#include <string.h>
     3128#else
     3129#ifdef HAVE_STRINGS_H
     3130#include <strings.h>
     3131#endif
     3132#endif
     3133#ifdef HAVE_STDLIB_H
     3134#include <stdlib.h>
     3135#endif
     3136#ifdef HAVE_UNISTD_H
     3137#include <unistd.h>
     3138#endif
     3139int main() {
     3140char *(*pfn) = (char *(*)) canonicalize_file_name
     3141; return 0; }
     3142EOF
     3143if { (eval echo configure:3144: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     3144  rm -rf conftest*
     3145  libiberty_cv_decl_needed_canonicalize_file_name=no
     3146else
     3147  echo "configure: failed program was:" >&5
     3148  cat conftest.$ac_ext >&5
     3149  rm -rf conftest*
     3150  libiberty_cv_decl_needed_canonicalize_file_name=yes
     3151fi
     3152rm -f conftest*
     3153fi
     3154
     3155echo "$ac_t""$libiberty_cv_decl_needed_canonicalize_file_name" 1>&6
     3156if test $libiberty_cv_decl_needed_canonicalize_file_name = yes; then
     3157  cat >> confdefs.h <<\EOF
     3158#define NEED_DECLARATION_CANONICALIZE_FILE_NAME 1
     3159EOF
     3160
     3161fi
     3162
     3163fi
     3164
     3165# Figure out which version of pexecute to use.
     3166case "${host}" in
     3167     *-*-mingw* | *-*-winnt*)   pexecute=pex-win32.o  ;;
     3168     *-*-msdosdjgpp*)           pexecute=pex-djgpp.o  ;;
     3169     *-*-msdos*)                pexecute=pex-msdos.o  ;;
     3170     *-*-os2-emx*)              pexecute=pex-os2.o    ;;
     3171     *)                         pexecute=pex-unix.o   ;;
     3172esac
     3173
     3174
     3175for ac_hdr in unistd.h
     3176do
     3177ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
     3178echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
     3179echo "configure:3180: checking for $ac_hdr" >&5
     3180if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
     3181  echo $ac_n "(cached) $ac_c" 1>&6
     3182else
     3183  cat > conftest.$ac_ext <<EOF
     3184#line 3185 "configure"
     3185#include "confdefs.h"
     3186#include <$ac_hdr>
     3187EOF
     3188ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     3189{ (eval echo configure:3190: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     3190ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     3191if test -z "$ac_err"; then
     3192  rm -rf conftest*
     3193  eval "ac_cv_header_$ac_safe=yes"
     3194else
     3195  echo "$ac_err" >&5
     3196  echo "configure: failed program was:" >&5
     3197  cat conftest.$ac_ext >&5
     3198  rm -rf conftest*
     3199  eval "ac_cv_header_$ac_safe=no"
     3200fi
     3201rm -f conftest*
     3202fi
     3203if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
     3204  echo "$ac_t""yes" 1>&6
     3205    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
     3206  cat >> confdefs.h <<EOF
     3207#define $ac_tr_hdr 1
     3208EOF
     3209 
     3210else
     3211  echo "$ac_t""no" 1>&6
     3212fi
     3213done
     3214
     3215for ac_func in getpagesize
     3216do
     3217echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
     3218echo "configure:3219: checking for $ac_func" >&5
     3219if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
     3220  echo $ac_n "(cached) $ac_c" 1>&6
     3221else
     3222  cat > conftest.$ac_ext <<EOF
     3223#line 3224 "configure"
     3224#include "confdefs.h"
     3225/* System header to define __stub macros and hopefully few prototypes,
     3226    which can conflict with char $ac_func(); below.  */
     3227#include <assert.h>
     3228/* Override any gcc2 internal prototype to avoid an error.  */
     3229/* We use char because int might match the return type of a gcc2
     3230    builtin and then its argument prototype would still apply.  */
     3231char $ac_func();
     3232
     3233int main() {
     3234
     3235/* The GNU C library defines this for functions which it implements
     3236    to always fail with ENOSYS.  Some functions are actually named
     3237    something starting with __ and the normal name is an alias.  */
     3238#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
     3239choke me
     3240#else
     3241$ac_func();
     3242#endif
     3243
     3244; return 0; }
     3245EOF
     3246if { (eval echo configure:3247: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     3247  rm -rf conftest*
     3248  eval "ac_cv_func_$ac_func=yes"
     3249else
     3250  echo "configure: failed program was:" >&5
     3251  cat conftest.$ac_ext >&5
     3252  rm -rf conftest*
     3253  eval "ac_cv_func_$ac_func=no"
     3254fi
     3255rm -f conftest*
     3256fi
     3257
     3258if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
     3259  echo "$ac_t""yes" 1>&6
     3260    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
     3261  cat >> confdefs.h <<EOF
     3262#define $ac_tr_func 1
     3263EOF
     3264 
     3265else
     3266  echo "$ac_t""no" 1>&6
     3267fi
     3268done
     3269
    28173270echo $ac_n "checking for working mmap""... $ac_c" 1>&6
    2818 echo "configure:2819: checking for working mmap" >&5
     3271echo "configure:3272: checking for working mmap" >&5
    28193272if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
    28203273  echo $ac_n "(cached) $ac_c" 1>&6
     
    28243277else
    28253278  cat > conftest.$ac_ext <<EOF
    2826 #line 2827 "configure"
     3279#line 3280 "configure"
    28273280#include "confdefs.h"
    28283281
     
    29643417
    29653418EOF
    2966 if { (eval echo configure:2967: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     3419if { (eval echo configure:3420: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
    29673420then
    29683421  ac_cv_func_mmap_fixed_mapped=yes
     
    29883441
    29893442echo $ac_n "checking for working strncmp""... $ac_c" 1>&6
    2990 echo "configure:2991: checking for working strncmp" >&5
     3443echo "configure:3444: checking for working strncmp" >&5
    29913444if eval "test \"`echo '$''{'ac_cv_func_strncmp_works'+set}'`\" = set"; then
    29923445  echo $ac_n "(cached) $ac_c" 1>&6
     
    29963449else
    29973450  cat > conftest.$ac_ext <<EOF
    2998 #line 2999 "configure"
     3451#line 3452 "configure"
    29993452#include "confdefs.h"
    30003453
     
    30413494                     MAP_ANON|MAP_PRIVATE, dev_zero, 0);
    30423495  if (p == (char *)-1)
     3496    p = (char *) mmap (0, MAP_LEN, PROT_READ|PROT_WRITE,
     3497                       MAP_ANON|MAP_PRIVATE, -1, 0);
     3498  if (p == (char *)-1)
    30433499    exit (2);
    30443500  else
     
    30573513
    30583514EOF
    3059 if { (eval echo configure:3060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     3515if { (eval echo configure:3516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
    30603516then
    30613517  ac_cv_func_strncmp_works=yes
     
    32213677s%@infodir@%$infodir%g
    32223678s%@mandir@%$mandir%g
     3679s%@libiberty_topdir@%$libiberty_topdir%g
     3680s%@MAINT@%$MAINT%g
     3681s%@NOTMAINT@%$NOTMAINT%g
     3682s%@MAKEINFO@%$MAKEINFO%g
     3683s%@BUILD_INFO@%$BUILD_INFO%g
     3684s%@PERL@%$PERL%g
     3685s%@HAVE_PERL@%$HAVE_PERL%g
    32233686s%@host@%$host%g
    32243687s%@host_alias@%$host_alias%g
     
    32353698s%@CC@%$CC%g
    32363699s%@ac_libiberty_warn_cflags@%$ac_libiberty_warn_cflags%g
     3700s%@NO_MINUS_C_MINUS_O@%$NO_MINUS_C_MINUS_O%g
     3701s%@OUTPUT_OPTION@%$OUTPUT_OPTION%g
    32373702s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
    32383703s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
     
    32423707s%@CPP@%$CPP%g
    32433708s%@CHECK@%$CHECK%g
     3709s%@target_header_dir@%$target_header_dir%g
    32443710s%@LIBOBJS@%$LIBOBJS%g
    3245 s%@ALLOCA@%$ALLOCA%g
     3711s%@pexecute@%$pexecute%g
    32463712s%@INSTALL_DEST@%$INSTALL_DEST%g
    32473713
     
    34583924target=${target}
    34593925with_target_subdir=${with_target_subdir}
     3926with_build_subdir=${with_build_subdir}
    34603927with_multisubdir=${with_multisubdir}
    34613928ac_configure_args="--enable-multilib ${ac_configure_args}"
    34623929CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
     3930ORIGINAL_LD_FOR_MULTILIBS="${ORIGINAL_LD_FOR_MULTILIBS}"
    34633931libiberty_topdir=${libiberty_topdir}
    34643932
     
    34673935test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
    34683936if test -n "$CONFIG_FILES"; then
    3469   if test -n "${with_target_subdir}"; then
     3937  if test -n "${with_build_subdir}" || test -n "${with_target_subdir}"; then
    34703938    # FIXME: We shouldn't need to set ac_file
    34713939    ac_file=Makefile
     3940    LD="${ORIGINAL_LD_FOR_MULTILIBS}"
    34723941    . ${libiberty_topdir}/config-ml.in
    34733942  fi
Note: See TracChangeset for help on using the changeset viewer.