*** empty log message ***
[deliverable/binutils-gdb.git] / configure.in
index b3d28b97155d6bead865f5f852c17ae339d9d0b8..2569cc2ecfc00d05176969333f8f221f3ae85de9 100644 (file)
 
 # these libraries are used by various programs built for the host environment
 #
-host_libs="intl mmalloc libiberty opcodes bfd readline gash db tcl tk tcl8.1 tk8.1 tclX itcl tix libgui zlib"
-
-if [ "${enable_gdbgui}" = "yes" ] ; then
-       host_libs="${host_libs} libgui"
-fi
+host_libs="intl mmalloc libiberty opcodes bfd readline db tcl tk tcl8.1 tk8.1 tclX itcl tix libgui zlib"
 
 libstdcxx_version="target-libstdc++-v3"
 # Don't use libstdc++-v3's flags to configure/build itself.
@@ -97,7 +93,7 @@ target_tools="target-examples target-groff target-gperf"
 #
 # This must be a single line because of the way it is searched by grep in
 # the code below.
-native_only="autoconf automake libtool cvssrc emacs emacs19 fileutils find gawk gettext grep gzip hello indent ispell m4 rcs recode sed shellutils tar textutils gash uudecode wdiff gprof target-groff guile perl apache inet time ash bash bzip2 prms snavigator gnuserv target-gperf"
+native_only="autoconf automake libtool cvssrc emacs emacs19 fileutils find gawk gettext grep gzip hello indent ispell m4 rcs recode sed shellutils tar textutils uudecode wdiff gprof target-groff guile perl apache inet time ash bash bzip2 prms snavigator gnuserv target-gperf"
 
 # directories to be built in a cross environment only
 #
@@ -123,30 +119,47 @@ appdirs=""
 # per-host:
 
 # Work in distributions that contain no compiler tools, like Autoconf.
-if [ -d ${srcdir}/config ]; then
+tentative_cc=""
+if test -d ${srcdir}/config ; then
 case "${host}" in
   m68k-hp-hpux*)
+    # Avoid "too much defining" errors from HPUX compiler.
+    tentative_cc="cc -Wp,-H256000"
     host_makefile_frag="${host_makefile_frag} config/mh-hp300"
     ;;
   m68k-apollo-sysv*)
+    tentative_cc="cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DUSG"
     host_makefile_frag="${host_makefile_frag} config/mh-apollo68"
     ;;
   m68k-apollo-bsd*)
+    #None of the Apollo compilers can compile gas or binutils.  The preprocessor
+    # chokes on bfd, the compiler won't let you assign integers to enums, and
+    # other problems.  Defining CC to gcc is a questionable way to say "don't use
+    # the apollo compiler" (the preferred version of GCC could be called cc,
+    # or whatever), but I'm not sure leaving CC as cc is any better...
+    #CC=cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DNO_STDARG
+    tentative_cc=gcc
     host_makefile_frag="${host_makefile_frag} config/mh-a68bsd"
     ;;
   m88k-dg-dgux*)
+    tentative_cc="gcc -Wall -ansi -D__using_DGUX"
     host_makefile_frag="${host_makefile_frag} config/mh-dgux"
     ;;
   m88k-harris-cxux*)
+    # Under CX/UX, we want to tell the compiler to use ANSI mode.
+    tentative_cc="cc -Xa"
     host_makefile_frag="${host_makefile_frag} config/mh-cxux"
     ;;
   m88k-motorola-sysv*)
     host_makefile_frag="${host_makefile_frag} config/mh-delta88"
     ;;
   mips*-dec-ultrix*)
+    tentative_cc="cc -Wf,-XNg1000"
     host_makefile_frag="${host_makefile_frag} config/mh-decstation"
     ;;
   mips*-nec-sysv4*)
+    # The C compiler on NEC MIPS SVR4 needs bigger tables.
+    tentative_cc="cc -ZXNd=5000 -ZXNg=1000"
     host_makefile_frag="${host_makefile_frag} config/mh-necv4"
     ;;
   mips*-sgi-irix6*)
@@ -156,7 +169,10 @@ case "${host}" in
     host_makefile_frag="${host_makefile_frag} config/mh-irix5"
     ;;
   mips*-sgi-irix4*)
-    host_makefile_frag="${host_makefile_frag} config/mh-irix4"
+    # Tell compiler to use K&R C.  We can't compile under the SGI Ansi
+    # environment.  Also bump switch table size so that cp-parse will
+    # compile.  Bump string length limit so linker builds.
+    tentative_cc="cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000 -Wf,-XNl8192"
     ;;
   mips*-sgi-irix3*)
     host_makefile_frag="${host_makefile_frag} config/mh-sysv"
@@ -165,27 +181,54 @@ case "${host}" in
     host_makefile_frag="${host_makefile_frag} config/mh-sysv4"
     ;;
   mips*-*-sysv*)
+    # This is for a MIPS running RISC/os 4.52C.
+
+    # This is needed for GDB, but needs to be in the top-level make because
+    # if a library is compiled with the bsd headers and gets linked with the
+    # sysv system libraries all hell can break loose (e.g. a jmp_buf might be
+    # a different size).
+    # ptrace(2) apparently has problems in the BSD environment.  No workaround is
+    # known except to select the sysv environment.  Could we use /proc instead?
+    # These "sysv environments" and "bsd environments" often end up being a pain.
+    #
+    # This is not part of CFLAGS because perhaps not all C compilers have this
+    # option.
+    tentative_cc="cc -systype sysv"
     host_makefile_frag="${host_makefile_frag} config/mh-riscos"
     ;;
   i370-ibm-opened*)
+    tentative_cc="c89"
     host_makefile_frag="${host_makefile_frag} config/mh-openedition"
     ;;
   i[3456]86-*-sysv5*)
     host_makefile_frag="${host_makefile_frag} config/mh-sysv5"
     ;;
   i[3456]86-*-dgux*)
+    tentative_cc="gcc -Wall -ansi -D__using_DGUX"
     host_makefile_frag="${host_makefile_frag} config/mh-dgux386"
     ;;
   i[3456]86-ncr-sysv4.3*)
+    # The MetaWare compiler will generate a copyright message unless you
+    # turn it off by adding the -Hnocopyr flag.
+    tentative_cc="cc -Hnocopyr"
     host_makefile_frag="${host_makefile_frag} config/mh-ncrsvr43"
     ;;
   i[3456]86-ncr-sysv4*)
+    # for an NCR 3000 (i486/SVR4) system.
+    # The NCR 3000 ships with a MetaWare compiler installed as /bin/cc.
+    # This compiler not only emits obnoxious copyright messages every time
+    # you run it, but it chokes and dies on a whole bunch of GNU source
+    # files.  Default to using the AT&T compiler installed in /usr/ccs/ATT/cc.
+    tentative_cc="/usr/ccs/ATT/cc"
     host_makefile_frag="${host_makefile_frag} config/mh-ncr3000"
     ;;
   i[3456]86-*-sco3.2v5*)
     host_makefile_frag="${host_makefile_frag} config/mh-sysv"
     ;;
   i[3456]86-*-sco*)
+    # The native C compiler botches some simple uses of const.  Unfortunately,
+    # it doesn't defined anything like "__sco__" for us to test for in ansidecl.h.
+    tentative_cc="cc -Dconst="
     host_makefile_frag="${host_makefile_frag} config/mh-sco"
     ;;
   i[3456]86-*-udk*)
@@ -212,32 +255,38 @@ case "${host}" in
   *-interix*)
     host_makefile_frag="${host_makefile_frag} config/mh-interix"
     ;;
-  *-windows*)
-    host_makefile_frag="${host_makefile_frag} config/mh-windows"
-    ;;
   vax-*-ultrix2*)
-    host_makefile_frag="${host_makefile_frag} config/mh-vaxult2"
+    # The old BSD pcc isn't up to compiling parts of gdb so use gcc
+    tentative_cc=gcc
     ;;
   *-*-solaris2*)
     host_makefile_frag="${host_makefile_frag} config/mh-solaris"
     ;;
   m68k-sun-sunos*)
-    host_makefile_frag="${host_makefile_frag} config/mh-sun3"
+    # Sun's C compiler needs the -J flag to be able to compile cp-parse.c
+    # without overflowing the jump tables (-J says to use a 32 bit table)
+    tentative_cc="cc -J"
     ;;
   *-hp-hpux[78]*)
+    tentative_cc="cc -Wp,-H256000"
     host_makefile_frag="${host_makefile_frag} config/mh-hpux8"
     ;;
   *-hp-hpux*)
+    tentative_cc="cc -Wp,-H256000"
     host_makefile_frag="${host_makefile_frag} config/mh-hpux"
     ;;
   *-*-hiux*)
+    tentative_cc="cc -Wp,-H256000"
     host_makefile_frag="${host_makefile_frag} config/mh-hpux"
     ;;
   rs6000-*-lynxos*)
+    # /bin/cc is less than useful for our purposes.  Always use GCC
+    tentative_cc="/usr/cygnus/progressive/bin/gcc"
     host_makefile_frag="${host_makefile_frag} config/mh-lynxrs6k"
     ;;
   *-*-lynxos*)
-    host_makefile_frag="${host_makefile_frag} config/mh-lynxos"
+    # /bin/cc is less than useful for our purposes.  Always use GCC
+    tentative_cc="/bin/gcc"
     ;;
   *-*-sysv4*)
     host_makefile_frag="${host_makefile_frag} config/mh-sysv4"
@@ -250,7 +299,8 @@ fi
 
 # If we aren't going to be using gcc, see if we can extract a definition
 # of CC from the fragment.
-if [ -z "${CC}" ] && [ "${build}" = "${host}" ]; then
+# Actually, use the 'pre-extracted' version above.
+if test -z "${CC}" && test "${build}" = "${host}" ; then
   IFS="${IFS=  }"; save_ifs="$IFS"; IFS="${IFS}:"
   found=
   for dir in $PATH; do
@@ -261,17 +311,14 @@ if [ -z "${CC}" ] && [ "${build}" = "${host}" ]; then
     fi
   done
   IFS="$save_ifs"
-  if [ -z "${found}" ] && [ -n "${host_makefile_frag}" ] && [ -f "${srcdir}/${host_makefile_frag}" ]; then
-    xx=`sed -n -e 's/^[        ]*CC[   ]*=[    ]*\(.*\)$/\1/p' < ${srcdir}/${host_makefile_frag}`
-    if [ -n "${xx}" ] ; then
-      CC=$xx
-    fi
+  if test -z "${found}" && test -n "${tentative_cc}" ; then
+    CC=$tentative_cc
   fi
 fi
 
 # We default to --with-shared on platforms where -fpic is meaningless.
 # Well, we don't yet, but we will.
-if false && [ "${host}" = "${target}" ] && [ x${enable_shared} = x ]; then
+if false && test "${host}" = "${target}" && test x${enable_shared} = x ; then
   case "${target}" in
     alpha*-dec-osf*)   enable_shared=yes ;;
     alpha*-*-linux*)   enable_shared=yes ;;
@@ -295,51 +342,8 @@ case "${enable_shared}" in
   *) shared=yes ;;
 esac
 
-if [ x${shared} = xyes ]; then
-  case "${host}" in
-    alpha*-*-linux*)
-      host_makefile_frag="${host_makefile_frag} config/mh-elfalphapic"
-      ;;
-    arm*-*-*)
-      host_makefile_frag="${host_makefile_frag} config/mh-armpic"
-      ;;
-    parisc*-*-* | hppa*-*-*)
-      host_makefile_frag="${host_makefile_frag} config/mh-papic"
-      ;;
-    i[3456]86-*-cygwin*)
-      # We don't want -fPIC on Cygwin.
-      ;;
-    i[3456]86-*-*)
-      host_makefile_frag="${host_makefile_frag} config/mh-x86pic"
-      ;;
-    i370-*-*)
-      host_makefile_frag="${host_makefile_frag} config/mh-i370pic"
-      ;;
-    ia64-*-*)
-      host_makefile_frag="${host_makefile_frag} config/mh-ia64pic"
-      ;;
-    sparc64-*-*)
-      host_makefile_frag="${host_makefile_frag} config/mh-sparcpic"
-      ;;
-    powerpc*-*-aix*)
-      # We don't want -fPIC on AIX.
-      ;;
-    powerpc*-*-*)
-      host_makefile_frag="${host_makefile_frag} config/mh-ppcpic"
-      ;;
-    s390-* | s390x-*)
-      host_makefile_frag="${host_makefile_frag} config/mh-s390pic"
-      ;;
-    *-*-*)
-      if test -f ${srcdir}/config/mh-${host_cpu}pic; then
-        host_makefile_frag="${host_makefile_frag} config/mh-${host_cpu}pic"
-      fi
-      ;;
-  esac
-fi
-
 rm -f mh-frag
-if [ -n "${host_makefile_frag}" ] ; then
+if test -n "${host_makefile_frag}" ; then
   for f in ${host_makefile_frag}
   do
     cat ${srcdir}/$f >> mh-frag
@@ -409,7 +413,7 @@ case ${with_x} in
   yes | "")  # the default value for this tree is that X11 is available
        ;;
   no)
-       skipdirs="${skipdirs} tk libgui gash"
+       skipdirs="${skipdirs} tk libgui"
        ;;
   *)
        echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2
@@ -423,7 +427,7 @@ esac
 
 is_cross_compiler=
 
-if [ x"${host}" = x"${target}" ] ; then
+if test x"${host}" = x"${target}" ; then
        # when doing a native toolchain, don't build the targets
        # that are in the 'cross only' list
        skipdirs="${skipdirs} ${cross_only}"
@@ -439,7 +443,7 @@ fi
 # can reliably find it.
 target_subdir=${target_alias}
 
-if [ ! -d ${target_subdir} ] ; then
+if test ! -d ${target_subdir} ; then
   if mkdir ${target_subdir} ; then true
   else
     echo "'*** could not make ${PWD=`pwd`}/${target_subdir}" 1>&2
@@ -449,8 +453,8 @@ fi
 
 build_subdir=${build_alias}
 
-if [ x"${build_alias}" != x"${host}" ] ; then
-  if [ ! -d ${build_subdir} ] ; then
+if test x"${build_alias}" != x"${host}" ; then
+  if test ! -d ${build_subdir} ; then
     if mkdir ${build_subdir} ; then true
     else
       echo "'*** could not make ${PWD=`pwd`}/${build_subdir}" 1>&2
@@ -463,8 +467,8 @@ copy_dirs=
 
 # Handle --with-headers=XXX.  The contents of the named directory are
 # copied to $(tooldir)/sys-include.
-if [ x"${with_headers}" != x ]; then
-  if [ x${is_cross_compiler} = xno ]; then
+if test x"${with_headers}" != x ; then
+  if test x${is_cross_compiler} = xno ; then
     echo 1>&2 '***' --with-headers is only supported when cross compiling
     exit 1
   fi
@@ -477,8 +481,8 @@ fi
 
 # Handle --with-libs=XXX.  Multiple directories are permitted.  The
 # contents are copied to $(tooldir)/lib.
-if [ x"${with_libs}" != x ]; then
-  if [ x${is_cross_compiler} = xno ]; then
+if test x"${with_libs}" != x ; then
+  if test x${is_cross_compiler} = xno ; then
     echo 1>&2 '***' --with-libs is only supported when cross compiling
     exit 1
   fi
@@ -495,21 +499,21 @@ fi
 
 # If both --with-headers and --with-libs are specified, default to
 # --without-newlib.
-if [ x"${with_headers}" != x ] && [ x"${with_libs}" != x ]; then
-  if [ x"${with_newlib}" = x ]; then
+if test x"${with_headers}" != x && test x"${with_libs}" != x ; then
+  if test x"${with_newlib}" = x ; then
     with_newlib=no
   fi
 fi
 
 # Recognize --with-newlib/--without-newlib.
-if [ x${with_newlib} = xno ]; then
+if test x${with_newlib} = xno ; then
   skipdirs="${skipdirs} target-newlib"
-elif [ x${with_newlib} = xyes ]; then
+elif test x${with_newlib} = xyes ; then
   skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
 fi
 
 # Default to using --with-stabs for certain targets.
-if [ x${with_stabs} = x ]; then
+if test x${with_stabs} = x ; then
   case "${target}" in
   mips*-*-irix6*)
     ;;
@@ -523,15 +527,15 @@ fi
 # Handle ${copy_dirs}
 set fnord ${copy_dirs}
 shift
-while [ $# != 0 ]; do
-  if [ -f $2/COPIED ] && [ x"`cat $2/COPIED`" = x"$1" ]; then
+while test $# != 0 ; do
+  if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
     :
   else
     echo Copying $1 to $2
 
     # Use the install script to create the directory and all required
     # parent directories.
-    if [ -d $2 ]; then
+    if test -d $2 ; then
       :
     else
       echo >config.temp
@@ -639,6 +643,12 @@ case "${target}" in
     ;;
   *-*-rtems*)
     noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+    case ${target} in
+       h8300*-*-* | h8500-*-*)
+         noconfigdirs="$noconfigdirs target-libf2c"
+          ;;
+        *) ;;
+    esac
     ;;
   *-*-vxworks*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
@@ -738,7 +748,7 @@ case "${target}" in
     ;;
   fr30-*-elf*)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
           target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
     fi
     ;;
@@ -783,13 +793,33 @@ case "${target}" in
     ;;
   i[3456]86-*-coff | i[3456]86-*-elf)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
          target_configdirs="${target_configdirs} target-libstub target-cygmon"
     fi
     ;;
   i[34567]86-*-freebsd*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     ;;
+  s390*-*-linux*)
+    # The libffi port is not yet in the GCC tree
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+    # linux has rx in libc
+    skipdirs="$skipdirs target-librx"
+    ;;
+  i[3456]86-*-linux*)
+    # This section makes it possible to build newlib natively on linux.
+    # If we are using a cross compiler then don't configure newlib.
+    if test x${is_cross_compiler} != xno ; then
+         noconfigdirs="$noconfigdirs target-newlib"
+    fi
+    noconfigdirs="$noconfigdirs target-libgloss"
+    # If we are not using a cross compiler, do configure newlib.
+    # Note however, that newlib will only be configured in this situation
+    # if the --with-newlib option has been given, because otherwise
+    # 'target-newlib' will appear in skipdirs.
+    # linux has rx in libc
+    skipdirs="$skipdirs target-librx"
+    ;;
   *-*-linux*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     # linux has rx in libc
@@ -850,13 +880,13 @@ case "${target}" in
     ;;
   m68k-*-elf*)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
           target_configdirs="${target_configdirs} target-bsp target-cygmon"
     fi
     ;;
   m68k-*-coff*)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
           target_configdirs="${target_configdirs} target-bsp target-cygmon"
     fi
     ;;
@@ -870,13 +900,13 @@ case "${target}" in
     ;;
   mn10200-*-*)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
           target_configdirs="${target_configdirs} target-libstub target-cygmon"
     fi
     ;;
   mn10300-*-*)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
           target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
     fi
     ;;
@@ -900,7 +930,7 @@ case "${target}" in
     ;;
   powerpc-*-eabi)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
           target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
     fi
     ;;
@@ -964,39 +994,32 @@ case "${target}" in
     noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
   sparc-*-elf*)
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
           target_configdirs="${target_configdirs} target-libstub target-cygmon"
     fi
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
   sparc64-*-elf*)
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
           target_configdirs="${target_configdirs} target-libstub target-cygmon"
     fi
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
   sparclite-*-*)
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
           target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
     fi
     noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
   sparc-*-sunos4*)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if [ x${is_cross_compiler} != xno ] ; then
+    if test x${is_cross_compiler} != xno ; then
            noconfigdirs="$noconfigdirs gdb gdbtest target-newlib target-libgloss"
     else
            use_gnu_ld=no
     fi
     ;;
-  sparc-*-solaris*)
-    case "${host}" in
-    sparc-*-solaris2.8)
-      # According to Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>, libjava
-      # won't build correctly on Solaris 8 if there's a
-      # previously-installed version of GCC in the configured prefix.
-      # This problem does not show up on earlier versions of Solaris.
-      noconfigdirs="$noconfigdirs ${libgcj}"
-      ;;
-    esac
+  sparc-*-solaris* | sparc64-*-solaris* | sparcv9-*-solaris*)
     ;;
   v810-*-*)
     noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld ${libstdcxx_version} opcodes target-libgloss ${libgcj}"
@@ -1038,13 +1061,13 @@ case "${noconfigdirs}" in
 esac
 
 # Make sure we don't let GNU ld be added if we didn't want it.
-if [ x$with_gnu_ld = xno ]; then
+if test x$with_gnu_ld = xno ; then
   use_gnu_ld=no
   noconfigdirs="$noconfigdirs ld"
 fi
 
 # Make sure we don't let GNU as be added if we didn't want it.
-if [ x$with_gnu_as = xno ]; then
+if test x$with_gnu_as = xno ; then
   use_gnu_as=no
   noconfigdirs="$noconfigdirs gas"
 fi
@@ -1143,10 +1166,10 @@ done
 notsupp=""
 for dir in . $skipdirs $noconfigdirs ; do
   dirname=`echo $dir | sed -e s/target-//g`
-  if [ $dir != . ]  && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+  if test $dir != .  && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
     configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
-    if [ -r $srcdir/$dirname/configure ] \
-       || [ -r $srcdir/$dirname/configure.in ]; then
+    if test -r $srcdir/$dirname/configure \
+       || test -r $srcdir/$dirname/configure.in ; then
       if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
        true
       else
@@ -1154,10 +1177,10 @@ for dir in . $skipdirs $noconfigdirs ; do
       fi
     fi
   fi
-  if [ $dir != . ]  && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+  if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
     target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
-    if [ -r $srcdir/$dirname/configure ] \
-       || [ -r $srcdir/$dirname/configure.in ]; then
+    if test -r $srcdir/$dirname/configure \
+       || test -r $srcdir/$dirname/configure.in ; then
       if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
        true
       else
@@ -1169,17 +1192,17 @@ done
 
 # Sometimes the tools are distributed with libiberty but with no other
 # libraries.  In that case, we don't want to build target-libiberty.
-if [ -n "${target_configdirs}" ]; then
+if test -n "${target_configdirs}" ; then
   others=
   for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
-    if [ "$i" != "libiberty" ]; then
-      if [ -r $srcdir/$i/configure ] || [ -r $srcdir/$i/configure.in ]; then
+    if test "$i" != "libiberty" ; then
+      if test -r $srcdir/$i/configure || test -r $srcdir/$i/configure.in ; then
        others=yes;
        break;
       fi
     fi
   done
-  if [ -z "${others}" ]; then
+  if test -z "${others}" ; then
     target_configdirs=
   fi
 fi
@@ -1187,12 +1210,12 @@ fi
 # Deconfigure all subdirectories, in case we are changing the
 # configuration from one where a subdirectory is supported to one where it
 # is not.
-if [ -z "${norecursion}" ] && [ -n "${configdirs}" ]; then
+if test -z "${norecursion}" && test -n "${configdirs}" ; then
   for i in `echo ${configdirs} | sed -e s/target-//g` ; do
     rm -f $i/Makefile
   done
 fi
-if [ -z "${norecursion}" ] && [ -n "${target_configdirs}" ]; then
+if test -z "${norecursion}" && test -n "${target_configdirs}" ; then
   for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
     rm -f ${target_subdir}/$i/Makefile
   done
@@ -1222,14 +1245,14 @@ done
 # FSF releases, it's important to let people know when their machine isn't
 # supported by the one or two programs in a package.
 
-if [ -n "${notsupp}" ] && [ -z "${norecursion}" ]; then
+if test -n "${notsupp}" && test -z "${norecursion}" ; then
   # If $appdirs is non-empty, at least one of those directories must still
   # be configured, or we error out.  (E.g., if the gas release supports a
   # specified target in some subdirs but not the gas subdir, we shouldn't
   # pretend that all is well.)
-  if [ -n "$appdirs" ]; then
+  if test -n "$appdirs" ; then
     for dir in $appdirs ; do
-      if [ -r $dir/Makefile.in ]; then
+      if test -r $dir/Makefile.in ; then
        if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
          appdirs=""
          break
@@ -1240,7 +1263,7 @@ if [ -n "${notsupp}" ] && [ -z "${norecursion}" ]; then
        fi
       fi
     done
-    if [ -n "$appdirs" ]; then
+    if test -n "$appdirs" ; then
       echo "*** This configuration is not supported by this package." 1>&2
       exit 1
     fi
@@ -1265,15 +1288,15 @@ fi
 # want to do that, then you should use the --without-gnu-as and
 # --without-gnu-ld options for the configure script.
 
-if [ x${use_gnu_as} = x ] ; then
-  if [ x${with_gnu_as} != xno ] && echo " ${configdirs} " | grep " ${gasdir} " > /dev/null 2>&1 && [ -d ${srcdir}/${gasdir} ] ; then
+if test x${use_gnu_as} = x ; then
+  if test x${with_gnu_as} != xno && echo " ${configdirs} " | grep " ${gasdir} " > /dev/null 2>&1 && test -d ${srcdir}/${gasdir} ; then
     with_gnu_as=yes
     withoptions="$withoptions --with-gnu-as"
   fi
 fi
 
-if [ x${use_gnu_ld} = x ] ; then
-  if [ x${with_gnu_ld} != xno ] && echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 && [ -d ${srcdir}/ld ] ; then
+if test x${use_gnu_ld} = x ; then
+  if test x${with_gnu_ld} != xno && echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 && test -d ${srcdir}/ld ; then
     with_gnu_ld=yes
     withoptions="$withoptions --with-gnu-ld"
   fi
@@ -1282,41 +1305,13 @@ fi
 # If using newlib, add --with-newlib to the withoptions so that gcc/configure
 # can detect this case.
 
-if [ x${with_newlib} != xno ] && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 && [ -d ${srcdir}/newlib ] ; then
+if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
   with_newlib=yes
   withoptions="$withoptions --with-newlib"
 fi
 
-if [ x${shared} = xyes ]; then
-  case "${target}" in
-    hppa* | parisc*)
-      target_makefile_frag="${target_makefile_frag} config/mt-papic"
-      ;;
-    i[3456]86-*)
-      target_makefile_frag="${target_makefile_frag} config/mt-x86pic"
-      ;;
-    ia64-*)
-      target_makefile_frag="${target_makefile_frag} config/mt-ia64pic"
-      ;;
-    powerpc*-*-aix*)
-      # We don't want -fPIC on AIX.
-      ;;
-    powerpc*-*)
-      target_makefile_frag="${target_makefile_frag} config/mt-ppcpic"
-      ;;
-    alpha*-*-linux*)
-      target_makefile_frag="${target_makefile_frag} config/mt-elfalphapic"
-      ;;
-    *)
-      if test -f ${srcdir}/config/mt-${target_cpu}pic; then
-        target_makefile_frag="${target_makefile_frag} config/mt-${target_cpu}pic"
-      fi
-      ;;
-  esac
-fi
-
 rm -f mt-frag
-if [ -n "${target_makefile_frag}" ] ; then
+if test -n "${target_makefile_frag}" ; then
   for f in ${target_makefile_frag}
   do
     cat ${srcdir}/$f >> mt-frag
@@ -1330,33 +1325,39 @@ fi
 # can't, we are probably in trouble.  We don't care whether we can run the
 # executable--we might be using a cross compiler--we only care whether it
 # can be created.  At this point the main configure script has set CC.
+we_are_ok=no
 echo "int main () { return 0; }" > conftest.c
 ${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
-if [ $? = 0 ] && [ -s conftest -o -s conftest.exe ]; then
-  :
-else
-  echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
-  echo 1>&2 "*** You must set the environment variable CC to a working compiler."
-  rm -f conftest*
-  exit 1
-fi
+if test $? = 0 ; then
+  if test -s conftest || test -s conftest.exe ; then
+    we_are_ok=yes
+  fi
+fi 
+case $we_are_ok in
+  no)
+    echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
+    echo 1>&2 "*** You must set the environment variable CC to a working compiler."
+    rm -f conftest*
+    exit 1
+    ;;
+esac
 rm -f conftest*
 
 # The Solaris /usr/ucb/cc compiler does not appear to work.
 case "${host}" in
   sparc-sun-solaris2*)
       CCBASE="`echo ${CC-cc} | sed 's/ .*$//'`"
-      if [ "`type $CCBASE | sed 's/^[^/]*//'`" = "/usr/ucb/cc" ] ; then
+      if test "`type $CCBASE | sed 's/^[^/]*//'`" = "/usr/ucb/cc" ; then
           could_use=
-          [ -d /opt/SUNWspro/bin ] && could_use="/opt/SUNWspro/bin"
-          if [ -d /opt/cygnus/bin ] ; then
-              if [ "$could_use" = "" ] ; then
+          test -d /opt/SUNWspro/bin && could_use="/opt/SUNWspro/bin"
+          if test -d /opt/cygnus/bin ; then
+              if test "$could_use" = "" ; then
                   could_use="/opt/cygnus/bin"
               else
                   could_use="$could_use or /opt/cygnus/bin"
               fi
           fi
-        if [ "$could_use" = "" ] ; then
+        if test "$could_use" = "" ; then
             echo "Warning: compilation may fail because you're using"
             echo "/usr/ucb/cc.  You should change your PATH or CC "
             echo "variable and rerun configure."
@@ -1372,7 +1373,7 @@ esac
 
 # If --enable-shared was set, we must set LD_LIBRARY_PATH so that the
 # binutils tools will find libbfd.so.
-if [ "${shared}" = "yes" ]; then
+if test "${shared}" = "yes" ; then
   sed -e 's/^SET_LIB_PATH[     ]*=.*$/SET_LIB_PATH = $(REALLY_SET_LIB_PATH)/' \
       Makefile > Makefile.tem
   rm -f Makefile
@@ -1408,18 +1409,18 @@ buildargs="--cache-file=../config.cache --build=${build_alias} --host=${build_al
 # native.  However, it would be better to use other mechanisms to make the
 # sorts of decisions they want to make on this basis.  Please consider
 # this option to be deprecated.  FIXME.
-if [ x${is_cross_compiler} = xyes ]; then
+if test x${is_cross_compiler} = xyes ; then
   targargs="--with-cross-host=${host_alias} ${targargs}"
 fi
 
 # Default to --enable-multilib.
-if [ x${enable_multilib} = x ]; then
+if test x${enable_multilib} = x ; then
   targargs="--enable-multilib ${targargs}"
 fi
 
 # Pass --with-newlib if appropriate.  Note that target_configdirs has
 # changed from the earlier setting of with_newlib.
-if [ x${with_newlib} != xno ] && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && [ -d ${srcdir}/newlib ] ; then
+if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
   targargs="--with-newlib ${targargs}"
 fi
 
@@ -1492,11 +1493,10 @@ case " $skipdirs " in
    fi
 
    case "${target}-${is_cross_compiler}" in
-   i[3456]86-pc-linux*-no)
+   i[3456]86-*-linux*-no)
       # Here host == target, so we don't need to build gcc,
       # so we don't want to discard standard headers.
       FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
-      FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/newlib/'
       ;;
    *)
       # If we're building newlib, use its generic headers last, but search
This page took 0.033204 seconds and 4 git commands to generate.