diff options
Diffstat (limited to 'contrib/binutils/gas/configure.in')
-rw-r--r-- | contrib/binutils/gas/configure.in | 134 |
1 files changed, 105 insertions, 29 deletions
diff --git a/contrib/binutils/gas/configure.in b/contrib/binutils/gas/configure.in index 1707acd..62c50dd 100644 --- a/contrib/binutils/gas/configure.in +++ b/contrib/binutils/gas/configure.in @@ -9,8 +9,9 @@ AC_PREREQ(2.13) AC_INIT(as.h) AC_CANONICAL_SYSTEM +AC_ISC_POSIX -AM_INIT_AUTOMAKE(gas, 2.10.1) +AM_INIT_AUTOMAKE(gas, 2.11) AM_PROG_LIBTOOL @@ -40,6 +41,27 @@ esac])dnl using_cgen=no +build_warnings="-W -Wall" +AC_ARG_ENABLE(build-warnings, +[ --enable-build-warnings Enable build-time compiler warnings if gcc is used], +[case "${enableval}" in + yes) ;; + no) build_warnings="-w";; + ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"` + build_warnings="${build_warnings} ${t}";; + *,) t=`echo "${enableval}" | sed -e "s/,/ /g"` + build_warnings="${t} ${build_warnings}";; + *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;; +esac +if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then + echo "Setting warning flags = $build_warnings" 6>&1 +fi])dnl +WARN_CFLAGS="" +if test "x${build_warnings}" != x -a "x$GCC" = xyes ; then + WARN_CFLAGS="${build_warnings}" +fi +AC_SUBST(WARN_CFLAGS) + # Generate a header file AM_CONFIG_HEADER(config.h:config.in) @@ -95,11 +117,15 @@ changequote([,])dnl armb*) cpu_type=arm endian=little ;; armv*l) cpu_type=arm endian=little ;; armv*b) cpu_type=arm endian=big ;; + xscale*) cpu_type=arm endian=little ;; strongarm*) cpu_type=arm endian=little ;; thumb*) cpu_type=arm endian=little ;; hppa*) cpu_type=hppa ;; changequote(,)dnl - i[456]86) cpu_type=i386 ;; + i[3456]86) cpu_type=i386 arch=i386;; + x86_64) cpu_type=i386 arch=x86_64;; + ia64) cpu_type=ia64 ;; + m6811|m6812|m68hc12) cpu_type=m68hc11 ;; m680[012346]0) cpu_type=m68k ;; changequote([,])dnl m68008) cpu_type=m68k ;; @@ -139,6 +165,7 @@ changequote([,])dnl a29k-amd-udi) fmt=coff ;; a29k-amd-ebmon) fmt=coff ;; a29k-nyu-sym1) fmt=coff ;; + a29k-*-rtems*) fmt=coff ;; a29k-*-vxworks*) fmt=coff ;; alpha*-*-*vms*) fmt=evax ;; @@ -147,42 +174,57 @@ changequote([,])dnl alpha*-*-osf*) fmt=ecoff ;; alpha*-*-linuxecoff*) fmt=ecoff ;; alpha*-*-linux-gnu*) fmt=elf em=linux ;; - alpha*-*-freebsd*) fmt=elf em=freebsd ;; alpha*-*-netbsd*) fmt=elf em=nbsd ;; arc-*-elf*) fmt=elf bfd_gas=yes ;; arm-*-aout) fmt=aout ;; arm-*-coff | thumb-*-coff) fmt=coff ;; + arm-*-rtems | thumb-*-rtems) fmt=elf ;; arm-*-elf | thumb-*-elf) fmt=elf ;; arm*-*-conix*) fmt=elf ;; arm-*-linux*aout*) fmt=aout em=linux ;; - arm*-*-linux-gnu*) fmt=elf em=linux ;; - arm-*-netbsd*) fmt=aout em=nbsd bfd_gas=yes ;; + arm*-*-linux-gnu* | arm*-*-uclinux*) + fmt=elf em=linux ;; + arm-*-netbsd*) fmt=aout em=nbsd ;; arm-*-oabi | thumb-*-oabi) fmt=elf ;; arm-epoc-pe | thumb-epoc-pe) fmt=coff em=epoc-pe ;; - arm-*-wince) fmt=coff em=wince-pe bfd_gas=yes;; + arm-*-wince) fmt=coff em=wince-pe ;; arm-*-pe | thumb-*-pe) fmt=coff em=pe ;; arm-*-riscix*) fmt=aout em=riscix ;; avr-*-*) fmt=elf bfd_gas=yes ;; + cris-*-*) fmt=multi bfd_gas=yes ;; + d10v-*-*) fmt=elf bfd_gas=yes ;; d30v-*-*) fmt=elf bfd_gas=yes ;; fr30-*-*) fmt=elf bfd_gas=yes ;; + hppa-*-linux-gnu*) case ${cpu} in + hppa*64*) + fmt=elf em=hppalinux64;; + hppa*) + fmt=elf em=linux;; + esac ;; hppa-*-*elf*) fmt=elf em=hppa ;; - hppa-*-linux-gnu*) fmt=elf em=hppa ;; hppa-*-lites*) fmt=elf em=hppa ;; hppa-*-osf*) fmt=som em=hppa ;; hppa-*-rtems*) fmt=elf em=hppa ;; + hppa-*-hpux11*) case ${cpu} in + hppa*64*) + fmt=elf em=hppa64 ;; + hppa*) + fmt=som em=hppa ;; + esac ;; hppa-*-hpux*) fmt=som em=hppa ;; hppa-*-mpeix*) fmt=som em=hppa ;; hppa-*-bsd*) fmt=som em=hppa ;; hppa-*-hiux*) fmt=som em=hppa ;; + h8300-*-rtems*) fmt=coff ;; h8300-*-coff) fmt=coff ;; i370-*-elf* | i370-*-linux*) fmt=elf ;; @@ -197,14 +239,14 @@ changequote([,])dnl i386-*-linux*aout* | i386-*-linuxoldld) fmt=aout em=linux ;; i386-*-linux*coff*) fmt=coff em=linux ;; i386-*-linux-gnu*) fmt=elf em=linux bfd_gas=yes ;; + x86_64-*-linux-gnu*) fmt=elf em=linux bfd_gas=yes ;; i386-*-lynxos*) fmt=coff em=lynx ;; - i386-*-sysv4* | i386-*-solaris* | i386-*-elf) - fmt=elf bfd_gas=yes ;; changequote(,)dnl + i386-*-sysv[45]* | i386-*-solaris* | i386-*-elf) + fmt=elf bfd_gas=yes ;; i386-*-freebsdaout* | i386-*-freebsd[12].* | i386-*-freebsd[12]) fmt=aout em=386bsd ;; changequote([,])dnl - i386-*-freebsd*) fmt=elf bfd_gas=yes ;; i386-*-coff | i386-*-sysv* | i386-*-sco3.2v5*coff | i386-*-isc*) fmt=coff ;; i386-*-sco3.2v5*) fmt=elf @@ -216,25 +258,28 @@ changequote([,])dnl i386-*-sco3.2*) fmt=coff ;; i386-*-vsta) fmt=aout ;; i386-*-msdosdjgpp* | i386-*-go32* | i386-go32-rtems*) - fmt=coff em=go32;; - i386-*-rtemscoff*) fmt=coff ;; + fmt=coff em=go32 bfd_gas=yes + AC_DEFINE(STRICTCOFF, 1, [Using strict COFF?]) + ;; i386-*-rtemself*) fmt=elf ;; - i386-*-rtems*) fmt=elf ;; + i386-*-rtems*) fmt=coff ;; i386-*-gnu*) fmt=elf ;; i386-*-mach*) fmt=aout em=mach bfd_gas=yes ;; i386-*-msdos*) fmt=aout ;; i386-*-moss*) fmt=elf ;; - i386-*-pe) fmt=coff em=pe ;; + i386-*-pe) fmt=coff em=pe bfd_gas=yes ;; i386-*-cygwin*) fmt=coff em=pe bfd_gas=yes ;; i386-*-interix*) fmt=coff em=interix bfd_gas=yes ;; i386-*-mingw32*) fmt=coff em=pe bfd_gas=yes ;; - i386-*-*nt*) fmt=coff em=pe ;; + i386-*-*nt*) fmt=coff em=pe bfd_gas=yes ;; i386-*-vxworks*) fmt=aout ;; + i386-*-chaos) fmt=elf ;; + i860-stardent-sysv4* | i860-stardent-elf*) + fmt=elf bfd_gas=yes endian=little + AC_MSG_WARN(GAS support for ${generic_target} is preliminary and a work in progress) ;; i960-*-bout) fmt=bout ;; i960-*-coff) fmt=coff em=ic960 ;; - i960-*-rtemscoff*) fmt=coff em=ic960 ;; - i960-*-rtemself*) fmt=elf ;; i960-*-rtems*) fmt=coff em=ic960 ;; i960-*-nindy*) fmt=bout ;; i960-*-vxworks4*) fmt=bout ;; @@ -243,8 +288,14 @@ changequote([,])dnl i960-*-vxworks*) fmt=bout ;; i960-*-elf*) fmt=elf ;; + ia64-*-elf*) fmt=elf ;; + ia64-*-linux-gnu*) fmt=elf em=linux ;; + ia64-*-hpux*) fmt=elf em=hpux ;; + m32r-*-*) fmt=elf bfd_gas=yes ;; + m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)fmt=elf bfd_gas=yes ;; + m68k-*-vxworks* | m68k-ericsson-ose | m68k-*-sunos*) fmt=aout em=sun3 ;; m68k-motorola-sysv*) fmt=coff em=delta ;; @@ -253,10 +304,7 @@ changequote([,])dnl m68k-*-sysv4*) # must be before -sysv* fmt=elf em=svr4 ;; m68k-*-elf*) fmt=elf ;; - m68k-*-rtemscoff*) fmt=coff ;; - m68k-*-rtemself*) fmt=elf ;; - m68k-*-rtems*) fmt=elf ;; - m68k-*-coff | m68k-*-sysv*) + m68k-*-coff | m68k-*-sysv* | m68k-*-rtems*) fmt=coff ;; m68k-*-hpux*) fmt=hp300 em=hp300 ;; m68k-*-linux*aout*) fmt=aout em=linux ;; @@ -290,6 +338,7 @@ changequote([,])dnl mips-*-irix*) fmt=ecoff ;; mips-*-lnews*) fmt=ecoff em=lnews ;; mips-*-riscos*) fmt=ecoff ;; + mips-*-sysv4*MP*) fmt=elf em=tmips ;; mips-*-sysv*) fmt=ecoff ;; mips-*-elf* | mips-*-rtems* | mips-*-linux-gnu* | mips-*-gnu* | mips-*-openbsd*) fmt=elf ;; @@ -327,12 +376,12 @@ changequote([,])dnl ppc-*-netware*) fmt=elf em=ppcnw ;; ppc-*-vxworks*) fmt=elf ;; + sh-*-linux*) fmt=elf em=linux ;; sh-*-elf*) fmt=elf ;; sh-*-coff*) fmt=coff ;; sh-*-pe*) fmt=coff em=pe bfd_gas=yes;; sh-*-rtemself*) fmt=elf ;; - sh-*-rtemscoff*) fmt=coff ;; - sh-*-rtems*) fmt=coff ;; + sh-*-rtems*) fmt=coff ;; ns32k-pc532-mach* | ns32k-pc532-ux*) fmt=aout em=pc532mach ;; ns32k-pc532-netbsd* | ns32k-pc532-lites*) fmt=aout em=nbsd532 ;; @@ -364,9 +413,13 @@ changequote([,])dnl strongarm-*-coff) fmt=coff ;; strongarm-*-elf) fmt=elf ;; + xscale-*-coff) fmt=coff ;; + xscale-*-elf) fmt=elf ;; tic30-*-*aout*) fmt=aout bfd_gas=yes ;; tic30-*-*coff*) fmt=coff bfd_gas=yes ;; + tic54x-*-* | c54x*-*-*) + fmt=coff bfd_gas=yes need_libm=yes;; tic80-*-*) fmt=coff ;; v850-*-*) fmt=elf bfd_gas=yes ;; @@ -383,6 +436,7 @@ changequote([,])dnl w65-*-*) fmt=coff ;; + *-*-freebsd*) fmt=elf bfd_gas=yes ;; *-*-aout | *-*-scout) fmt=aout ;; *-*-nindy*) @@ -417,11 +471,13 @@ changequote([,])dnl arm-*) bfd_gas=yes ;; # not yet # i386-aout) bfd_gas=preferred ;; + ia64*-*) bfd_gas=yes ;; mips-*) bfd_gas=yes ;; ns32k-*) bfd_gas=yes ;; ppc-*) bfd_gas=yes ;; sparc-*) bfd_gas=yes ;; strongarm-*) bfd_gas=yes ;; + xscale-*) bfd_gas=yes ;; *-elf) bfd_gas=yes ;; *-ecoff) bfd_gas=yes ;; *-som) bfd_gas=yes ;; @@ -484,6 +540,11 @@ changequote([,])dnl fi ;; + i386) + if test $this_target = $target ; then + AC_DEFINE_UNQUOTED(DEFAULT_ARCH, "${arch}", [Default architecture.]) + fi + ;; sparc) if test $this_target = $target ; then AC_DEFINE_UNQUOTED(DEFAULT_ARCH, "${arch}", [Default architecture.]) @@ -533,6 +594,9 @@ changequote([,])dnl big) emulation="mipsbelf mipslelf mipself" ;; *) emulation="mipslelf mipsbelf mipself" ;; esac ;; + mips-*-sysv4*MP*-*) emulation="mipsbelf mipslelf mipself mipsbecoff mipslecoff mipsecoff" ;; + # i386-pc-pe-coff != i386-pc-coff. + i386-*-pe-coff) ;; # Uncommenting the next line will turn on support for i386 AOUT # for the default linux configuration # i386-*-linux*-elf) emulation="i386elf i386aout" ;; @@ -540,6 +604,10 @@ changequote([,])dnl i386-*-aout) emulation="i386aout" ;; i386-*-coff) emulation="i386coff" ;; i386-*-elf) emulation="i386elf" ;; + + # Always all formats. The first stated emulation becomes the default. + cris-*-*aout*) emulation="crisaout criself" ;; + cris-*-*) emulation="criself crisaout" ;; esac emulations="$emulations $emulation" @@ -654,12 +722,12 @@ for em in . $emulations ; do fmt=elf file=mipself ;; mipsbecoff | mipslecoff) fmt=ecoff file=mipsecoff ;; - i386aout) - fmt=aout file=i386aout ;; - i386coff) - fmt=coff file=i386coff ;; - i386elf) - fmt=elf file=i386elf ;; + *coff) + fmt=coff file=$em ;; + *aout) + fmt=aout file=$em ;; + *elf) + fmt=elf file=$em ;; esac formats="$formats $fmt" emfiles="$emfiles e-$file.o" @@ -787,6 +855,14 @@ AC_CHECK_FUNCS(unlink remove, break) # Some systems don't have sbrk(). AC_CHECK_FUNCS(sbrk) +# do we need the math library? +case "${need_libm}" in +yes) + AC_CHECK_LIBM + AC_SUBST(LIBM) + ;; +esac + # Some non-ANSI preprocessors botch requoting inside strings. That's bad # enough, but on some of those systems, the assert macro relies on requoting # working properly! |