daily update
[binutils.git] / bfd / configure.in
blobe6b4f9c9592cc7dddc1389eb84baf63e74ea09d8
1 dnl Process this file with autoconf to produce a configure script.
2 dnl
4 AC_PREREQ(2.13)
5 AC_INIT(libbfd.c)
7 AC_CANONICAL_SYSTEM
8 AC_ISC_POSIX
10 AM_INIT_AUTOMAKE(bfd, 2.13.90)
11 # Uncomment the next line to remove the date from the reported bfd version
12 #is_release=y
14 changequote(,)dnl
15 bfd_version=`echo "${VERSION}" | sed -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$/\1\2\3\4\5/'`
16 changequote([,])dnl
18 bfd_version_string="\"${VERSION}\""
19 bfd_version_date=`sed -e 's/.*DATE //' < ${srcdir}/version.h`
20 if test x${is_release} = x; then
21 dnl Sad, but we can't use XSTRING here to pick up the date from version.h
22 dnl because traditional C doesn't allow it.
23   bfd_version_string="\"${VERSION} ${bfd_version_date}\""
25 dnl Since we need to edit bfd-in3.h to get the date for bfd_version_string,
26 dnl we may as well substitute for bfd_version_date too.  That way we don't
27 dnl need to #include version.h
28 AC_SUBST(bfd_version)
29 AC_SUBST(bfd_version_date)
30 AC_SUBST(bfd_version_string)
32 dnl These must be called before AM_PROG_LIBTOOL, because it may want
33 dnl to call AC_CHECK_PROG.
34 AC_CHECK_TOOL(AR, ar)
35 AC_CHECK_TOOL(RANLIB, ranlib, :)
37 dnl Default to a non shared library.  This may be overridden by the
38 dnl configure option --enable-shared.
39 AM_DISABLE_SHARED
41 AM_PROG_LIBTOOL
43 AC_ARG_ENABLE(64-bit-bfd,
44 [  --enable-64-bit-bfd     64-bit support (on hosts with narrower word sizes)],
45 [case "${enableval}" in
46   yes)  want64=true  ;;
47   no)   want64=false ;;
48   *)    AC_MSG_ERROR(bad value ${enableval} for 64-bit-bfd option) ;;
49 esac],[want64=false])dnl
50 AC_ARG_ENABLE(targets,
51 [  --enable-targets        alternative target configurations],
52 [case "${enableval}" in
53   yes | "") AC_ERROR(enable-targets option must specify target names or 'all')
54             ;;
55   no)       enable_targets= ;;
56   *)        enable_targets=$enableval ;;
57 esac])dnl
58 AC_ARG_ENABLE(commonbfdlib,
59 [  --enable-commonbfdlib   build shared BFD/opcodes/libiberty library],
60 [case "${enableval}" in
61   yes) commonbfdlib=true ;;
62   no)  commonbfdlib=false ;;
63   *)   AC_MSG_ERROR([bad value ${enableval} for BFD commonbfdlib option]) ;;
64 esac])dnl
65 AC_ARG_WITH(mmap,
66 [  --with-mmap             try using mmap for BFD input files if available],
67 [case "${withval}" in
68   yes)  want_mmap=true ;;
69   no)   want_mmap=false ;;
70   *)    AC_MSG_ERROR(bad value ${withval} for BFD with-mmap option) ;;
71 esac],[want_mmap=false])dnl
73 build_warnings="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
74 AC_ARG_ENABLE(build-warnings,
75 [  --enable-build-warnings Enable build-time compiler warnings if gcc is used],
76 [case "${enableval}" in
77   yes)  ;;
78   no)   build_warnings="-w";;
79   ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
80         build_warnings="${build_warnings} ${t}";;
81   *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
82         build_warnings="${t} ${build_warnings}";;
83   *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
84 esac
85 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
86   echo "Setting warning flags = $build_warnings" 6>&1
87 fi])dnl
88 WARN_CFLAGS=""
89 if test "x${build_warnings}" != x -a "x$GCC" = xyes ; then
90     WARN_CFLAGS="${build_warnings}"
92 AC_SUBST(WARN_CFLAGS)
94 AM_CONFIG_HEADER(config.h:config.in)
96 if test -z "$target" ; then
97     AC_MSG_ERROR(Unrecognized target system type; please check config.sub.)
100 AM_MAINTAINER_MODE
101 AM_INSTALL_LIBBFD
102 AC_EXEEXT
104 host64=false
105 target64=false
106 bfd_default_target_size=32
108 # host stuff:
110 AC_PROG_CC
112 ALL_LINGUAS="fr tr ja es sv da"
113 CY_GNU_GETTEXT
115 # Permit host specific settings.
116 . ${srcdir}/configure.host
118 AC_SUBST(HDEFINES)
119 AC_PROG_INSTALL
121 BFD_HOST_64BIT_LONG=0
122 BFD_HOST_64_BIT_DEFINED=0
123 BFD_HOST_64_BIT=
124 BFD_HOST_U_64_BIT=
125 if test "x${HOST_64BIT_TYPE}" = "xlong"; then
126   BFD_HOST_64BIT_LONG=1
127 elif test "x${HOST_64BIT_TYPE}" != "x"; then
128   BFD_HOST_64_BIT_DEFINED=1
129   BFD_HOST_64_BIT=${HOST_64BIT_TYPE}
130   BFD_HOST_U_64_BIT=${HOST_U_64BIT_TYPE}
132 AC_SUBST(BFD_HOST_64BIT_LONG)
133 AC_SUBST(BFD_HOST_64_BIT_DEFINED)
134 AC_SUBST(BFD_HOST_64_BIT)
135 AC_SUBST(BFD_HOST_U_64_BIT)
137 BFD_CC_FOR_BUILD
139 AC_CHECK_HEADERS(stddef.h string.h strings.h stdlib.h time.h unistd.h)
140 AC_CHECK_HEADERS(fcntl.h sys/file.h sys/time.h)
141 AC_HEADER_TIME
142 AC_HEADER_DIRENT
143 AC_CHECK_FUNCS(fcntl getpagesize setitimer sysconf fdopen getuid getgid)
145 BFD_BINARY_FOPEN
147 BFD_NEED_DECLARATION(strstr)
148 BFD_NEED_DECLARATION(malloc)
149 BFD_NEED_DECLARATION(realloc)
150 BFD_NEED_DECLARATION(free)
151 BFD_NEED_DECLARATION(getenv)
153 # If we are configured native, pick a core file support file.
154 COREFILE=
155 COREFLAG=
156 TRAD_HEADER=
157 if test "${target}" = "${host}"; then
158   case "${host}" in
159   alpha*-*-freebsd*)
160         COREFILE=''
161         ;;
162   alpha*-*-linux-gnu*)
163         COREFILE=trad-core.lo
164         TRAD_HEADER='"hosts/alphalinux.h"'
165         ;;
166   alpha*-*-netbsd* | alpha*-*-openbsd*)
167         COREFILE=netbsd-core.lo
168         ;;
169   alpha*-*-*)           COREFILE=osf-core.lo ;;
170   arm-*-freebsd*)       COREFILE='' ;;
171   arm-*-netbsd*)        COREFILE=netbsd-core.lo ;;
172   arm-*-riscix)         COREFILE=trad-core.lo ;;
173   hppa*-*-hpux*)        COREFILE=hpux-core.lo ;;
174   hppa*-*-hiux*)        COREFILE=hpux-core.lo ;;
175   hppa*-*-mpeix*)       COREFILE=hpux-core.lo ;;
176   hppa*-*-bsd*)         COREFILE="hpux-core.lo hppabsd-core.lo"
177                         COREFLAG="-DHPUX_CORE -DHPPABSD_CORE" ;;
178   i370-*-*)
179         COREFILE=trad-core.lo
180         TRAD_HEADER='"hosts/i370linux.h"'
181         ;;
183 changequote(,)dnl
184   i[3456]86-sequent-bsd*)
185 changequote([,])dnl
186         COREFILE=trad-core.lo
187         TRAD_HEADER='"hosts/symmetry.h"'
188         ;;
189 changequote(,)dnl
190   i[3456]86-sequent-sysv4*) ;;
191   i[3456]86-sequent-sysv*)
192 changequote([,])dnl
193         COREFILE=trad-core.lo
194         TRAD_HEADER='"hosts/symmetry.h"'
195         ;;
196 changequote(,)dnl
197   i[3456]86-*-bsdi)
198 changequote([,])dnl
199         COREFILE=
200         ;;
201 changequote(,)dnl
202   i[3456]86-*-bsd* | i[34567]86-*-freebsd[123] | i[34567]86-*-freebsd[123]\.* | i[34567]86-*-freebsd4\.[01234]* | i[34567]86-*-freebsd*aout*)
203 changequote([,])dnl
204         COREFILE=trad-core.lo
205         TRAD_HEADER='"hosts/i386bsd.h"'
206         ;;
207 changequote(,)dnl
208   i[3456]86-*-freebsd*)
209 changequote([,])dnl
210         COREFILE=''
211         TRAD_HEADER='"hosts/i386bsd.h"'
212         ;;
213 changequote(,)dnl
214   i[3456]86-*-netbsd* | i[3456]86-*-openbsd*)
215 changequote([,])dnl
216         COREFILE=netbsd-core.lo
217         ;;
218 changequote(,)dnl
219   i[3456]86-esix-sysv3*)
220 changequote([,])dnl
221         COREFILE=trad-core.lo
222         TRAD_HEADER='"hosts/esix.h"'
223         ;;
224 changequote(,)dnl
225   i[3456]86-*-sco3.2v5*)
226 changequote([,])dnl
227         COREFILE=sco5-core.lo
228         ;;
229 changequote(,)dnl
230   i[3456]86-*-sco* | i[3456]86-*-isc*)
231 changequote([,])dnl
232         COREFILE=trad-core.lo
233         TRAD_HEADER='"hosts/i386sco.h"'
234         ;;
235 changequote(,)dnl
236   i[3456]86-*-mach3*)
237 changequote([,])dnl
238         COREFILE=trad-core.lo
239         TRAD_HEADER='"hosts/i386mach3.h"'
240         ;;
241 changequote(,)dnl
242   i[3456]86-*-linux-gnu*)
243 changequote([,])dnl
244         COREFILE=trad-core.lo
245         TRAD_HEADER='"hosts/i386linux.h"'
246         ;;
247 changequote(,)dnl
248   i[3456]86-*-isc*)     COREFILE=trad-core.lo ;;
249   i[3456]86-*-aix*)     COREFILE=aix386-core.lo ;;
250 changequote([,])dnl
251   i860-*-mach3* | i860-*-osf1*)
252         COREFILE=trad-core.lo
253         TRAD_HEADER='"hosts/i860mach3.h"'
254         ;;
255   mips-dec-bsd*)
256         COREFILE=trad-core.lo
257         TRAD_HEADER='"hosts/mipsbsd.h"'
258         ;;
259   mips-dec-mach3*)
260         COREFILE=trad-core.lo
261         TRAD_HEADER='"hosts/mipsmach3.h"'
262         ;;
263   mips-*-netbsd* | mips*-*-openbsd*)
264         COREFILE=netbsd-core.lo
265         ;;
266   mips-dec-*)
267         COREFILE=trad-core.lo
268         TRAD_HEADER='"hosts/decstation.h"'
269         ;;
270   mips-sgi-irix4*)      COREFILE=irix-core.lo ;;
271   mips-sgi-irix5*)      COREFILE=irix-core.lo ;;
272   mips-sgi-irix6*)      COREFILE=irix-core.lo ;;
273   mips-*-mach3*)
274         COREFILE=trad-core.lo
275         TRAD_HEADER='"hosts/mipsmach3.h"'
276         ;;
277   mips-*-sysv4*)        ;;
278   mips-*-sysv* | mips-*-riscos*)
279         COREFILE=trad-core.lo
280         TRAD_HEADER='"hosts/riscos.h"'
281         ;;
282   mips-sony-bsd*)
283         COREFILE=trad-core.lo
284         TRAD_HEADER='"hosts/news-mips.h"'
285         ;;
286   m68*-bull*-sysv*)
287         COREFILE=trad-core.lo
288         TRAD_HEADER='"hosts/dpx2.h"'
289         ;;
290   m68*-hp-hpux*)        COREFILE=hpux-core.lo ;;
291   m68*-hp-bsd*)
292         COREFILE=trad-core.lo
293         TRAD_HEADER='"hosts/hp300bsd.h"'
294         ;;
295   m68*-*-linux-gnu*)
296         COREFILE=trad-core.lo
297         TRAD_HEADER='"hosts/m68klinux.h"'
298         ;;
299   m68*-motorola-sysv*)
300         COREFILE=trad-core.lo
301         TRAD_HEADER='"hosts/delta68.h"'
302         ;;
303   m68*-sony-*)
304         COREFILE=trad-core.lo
305         TRAD_HEADER='"hosts/news.h"'
306         ;;
307   m68*-*-netbsd* | m68*-*-openbsd*)
308         COREFILE=netbsd-core.lo
309         ;;
310   m68*-apple-aux*)
311         COREFILE=trad-core.lo
312         TRAD_HEADER='"hosts/m68kaux.h"'
313         ;;
314   m88*-*-sysv4*)
315         ;;
316   m88*-motorola-sysv*)
317         COREFILE=ptrace-core.lo
318         ;;
319   m88*-*-mach3*)
320         COREFILE=trad-core.lo
321         TRAD_HEADER='"hosts/m88kmach3.h"'
322         ;;
323   ns32k-pc532-mach)
324         COREFILE=trad-core.lo
325         TRAD_HEADER='"hosts/pc532mach.h"'
326         ;;
327   ns32k-*-netbsd* | ns32k-*-openbsd*)
328         COREFILE=netbsd-core.lo
329         ;;
330   rs6000-*-lynx*)
331         COREFILE=lynx-core.lo
332         ;;
333   rs6000-*-aix5.* | powerpc-*-aix5.*)
334         COREFILE=rs6000-core.lo
335         COREFLAG="$COREFLAG -DAIX_5_CORE -DAIX_CORE_DUMPX_CORE"
336         ;;
337 changequote(,)dnl
338   rs6000-*-aix4.[3-9]* | powerpc-*-aix4.[3-9]*)
339 changequote([,])dnl
340         COREFILE=rs6000-core.lo
341         COREFLAG="$COREFLAG -DAIX_CORE_DUMPX_CORE"
342         # Not all versions of AIX with -DAIX_CORE_DUMPX_CORE
343         # have c_impl as a member of struct core_dumpx
344         AC_MSG_CHECKING([for c_impl in struct core_dumpx])
345         AC_TRY_COMPILE([#include <core.h>],
346           [struct core_dumpx c; c.c_impl = 0;],
347           [AC_DEFINE(HAVE_ST_C_IMPL, 1,
348             [Define if struct core_dumpx has member c_impl])
349           AC_MSG_RESULT(yes)],[AC_MSG_RESULT(no)])
350         ;;
351   rs6000-*-aix4*)       COREFILE=rs6000-core.lo ;;
352   rs6000-*-*)           COREFILE=rs6000-core.lo ;;
353   powerpc-*-aix4*)      COREFILE=rs6000-core.lo ;;
354   powerpc-*-aix*)       COREFILE=rs6000-core.lo ;;
355   powerpc-*-beos*)      ;;
356   powerpc-*-freebsd*)   COREFILE='' ;;
357   powerpc-*-netbsd*)    COREFILE=netbsd-core.lo ;;
358   powerpc-*-*bsd*)      COREFILE=netbsd-core.lo ;;
359   s390*-*-*)            COREFILE=trad-core.lo ;;
360   sh*-*-netbsd*)        COREFILE=netbsd-core.lo ;;
361   sparc-*-netbsd* | sparc*-*-openbsd*)
362         COREFILE=netbsd-core.lo
363         ;;
364   tahoe-*-*)
365         COREFILE=trad-core.lo
366         TRAD_HEADER='"hosts/tahoe.h"'
367         ;;
368   vax-*-netbsd*)        COREFILE=netbsd-core.lo ;;
369   vax-*-ultrix2*)
370         COREFILE=trad-core.lo
371         TRAD_HEADER='"hosts/vaxult2.h"'
372         ;;
373   vax-*-ultrix*)
374         COREFILE=trad-core.lo
375         TRAD_HEADER='"hosts/vaxult2.h"'
376         ;;
377   vax-*-*)
378         COREFILE=trad-core.lo
379         TRAD_HEADER='"hosts/vaxbsd.h"'
380         ;;
381   x86_64-*-netbsd*)     COREFILE=netbsd-core.lo ;;
382   esac
384   case "$COREFILE" in
385   aix386-core.lo)       COREFLAG=-DAIX386_CORE ;;
386   hppabsd-core.lo)      COREFLAG=-DHPPABSD_CORE ;;
387   hpux-core.lo)         COREFLAG=-DHPUX_CORE ;;
388   irix-core.lo)         COREFLAG=-DIRIX_CORE ;;
389   lynx-core.lo)         COREFLAG=-DLYNX_CORE ;;
390   netbsd-core.lo)       COREFLAG=-DNETBSD_CORE ;;
391   osf-core.lo)          COREFLAG=-DOSF_CORE ;;
392   ptrace-core.lo)       COREFLAG=-DPTRACE_CORE ;;
393   rs6000-core.lo)       COREFLAG="$COREFLAG -DAIX_CORE" ;;
394   sco5-core.lo)         COREFLAG="$COREFLAG -DSCO5_CORE" ;;
395   trad-core.lo)         COREFLAG="$COREFLAG -DTRAD_CORE" ;;
396   esac
398   # ELF corefile support has several flavors, but all of
399   # them use something called <sys/procfs.h>
400   AC_CHECK_HEADERS(sys/procfs.h)
401   if test "$ac_cv_header_sys_procfs_h" = yes; then
402     BFD_HAVE_SYS_PROCFS_TYPE(prstatus_t)
403     BFD_HAVE_SYS_PROCFS_TYPE(prstatus32_t)
404     BFD_HAVE_SYS_PROCFS_TYPE_MEMBER(prstatus_t, pr_who)
405     BFD_HAVE_SYS_PROCFS_TYPE_MEMBER(prstatus32_t, pr_who)
406     BFD_HAVE_SYS_PROCFS_TYPE(pstatus_t)
407     BFD_HAVE_SYS_PROCFS_TYPE(pxstatus_t)
408     BFD_HAVE_SYS_PROCFS_TYPE(pstatus32_t)
409     BFD_HAVE_SYS_PROCFS_TYPE(prpsinfo_t)
410     BFD_HAVE_SYS_PROCFS_TYPE(prpsinfo32_t)
411     BFD_HAVE_SYS_PROCFS_TYPE(psinfo_t)
412     BFD_HAVE_SYS_PROCFS_TYPE(psinfo32_t)
413     BFD_HAVE_SYS_PROCFS_TYPE(lwpstatus_t)
414     BFD_HAVE_SYS_PROCFS_TYPE(lwpxstatus_t)
415     BFD_HAVE_SYS_PROCFS_TYPE_MEMBER(lwpstatus_t, pr_context)
416     BFD_HAVE_SYS_PROCFS_TYPE_MEMBER(lwpstatus_t, pr_reg)
417     BFD_HAVE_SYS_PROCFS_TYPE(win32_pstatus_t)
418   fi
420 AC_SUBST(COREFILE)
421 AC_SUBST(COREFLAG)
422 if test -n "$TRAD_HEADER"; then
423   AC_DEFINE_UNQUOTED(TRAD_HEADER, $TRAD_HEADER,
424     [Name of host specific header file to include in trad-core.c.])
427 # Horrible hacks to build DLLs on Windows.
428 WIN32LDFLAGS=
429 WIN32LIBADD=
430 case "${host}" in
431 *-*-cygwin*)
432   if test "$enable_shared" = "yes"; then
433     WIN32LDFLAGS="-no-undefined"
434     WIN32LIBADD="-L`pwd`/../libiberty -liberty -L`pwd`/../intl -lintl -lcygwin -lkernel32"
435   fi
436   ;;
437 *-*-linux*)
438   # We borrow WIN32LIBADD so that the shared libbfd won't depend on
439   # libiberty.a.
440   case "${host}" in
441   mips*-*-linux*)
442     # Linux/MIPS uses PIC by default.
443     if test "$enable_shared" = "yes"; then
444       WIN32LIBADD="-L../libiberty -liberty"
445     fi
446     ;;
447   *)
448 changequote(,)dnl
449     x=`sed -n -e 's/^[  ]*PICFLAG[      ]*=[    ]*//p' < ../libiberty/Makefile | tail -1`
450 changequote([,])dnl
451     if test -n "$x"; then
452       WIN32LIBADD="-L../libiberty/pic -liberty"
453     fi
454   ;;
455   esac
456   ;;
457 esac
458 AC_SUBST(WIN32LDFLAGS)
459 AC_SUBST(WIN32LIBADD)
461 # target stuff:
463 # Canonicalize the secondary target names.
464 if test -n "$enable_targets" ; then
465     for targ in `echo $enable_targets | sed 's/,/ /g'`
466     do
467         result=`$ac_config_sub $targ 2>/dev/null`
468         if test -n "$result" ; then
469             canon_targets="$canon_targets $result"
470         else
471             # Allow targets that config.sub doesn't recognize, like "all".
472             canon_targets="$canon_targets $targ"
473         fi
474     done
477 all_targets=false
478 defvec=
479 selvecs=
480 selarchs=
481 TDEFINES=
482 for targ in $target $canon_targets
484     if test "x$targ" = "xall"; then
485         all_targets=true
486     else
487         . $srcdir/config.bfd
488         if test "x$targ" = "x$target"; then
489             defvec=$targ_defvec
490         fi
491         selvecs="$selvecs $targ_defvec $targ_selvecs"
492         selarchs="$selarchs $targ_archs"
493         TDEFINES="$TDEFINES $targ_cflags"
494     fi
495 done
496 AC_SUBST(TDEFINES)
498 # This processing still needs to be done if we're to decide properly whether
499 # 64-bit support needs to be compiled in.  Currently, it will be included if
500 # the default or any other explicitly requested target requires it; it
501 # will not be included on a 32-bit host if no 64-bit target is requested, and
502 # no "--with-64-bit-bfd" option is given, even if "--enable-targets=all" is
503 # used.
505 # uniq the default and selected vectors in all the configured targets.
506 f=""
507 for i in $selvecs ; do
508     case " $f " in
509     *" $i "*) ;;
510     *) f="$f $i" ;;
511     esac
512 done
513 selvecs="$f"
516 # uniq the architectures in all the configured targets.
517 f=""
518 for i in $selarchs ; do
519     case " $f " in
520     *" $i "*) ;;
521     *) f="$f $i" ;;
522     esac
523 done
524 selarchs="$f"
526 # Target backend .o files.
529 elf="elf.lo elflink.lo elf-strtab.lo elf-eh-frame.lo dwarf1.lo"
531 for vec in $selvecs
533     target_size=32
534     case "$vec" in
535     # This list is alphabetized to make it easy to compare
536     # with the two vector lists in targets.c.  For the same reason,
537     # use one entry per line, even though this leads to long lines.
538     a29kcoff_big_vec)           tb="$tb coff-a29k.lo cofflink.lo" ;;
539     a_out_adobe_vec)            tb="$tb aout-adobe.lo aout32.lo" ;;
540     aix5coff64_vec)             tb="$tb coff64-rs6000.lo xcofflink.lo aix5ppc-core.lo"; target_size=64 ;;
541     aout0_big_vec)              tb="$tb aout0.lo aout32.lo" ;;
542     aout_arm_big_vec)           tb="$tb aout-arm.lo aout32.lo" ;;
543     aout_arm_little_vec)        tb="$tb aout-arm.lo aout32.lo" ;;
544     aout_mips_big_vec)          tb="$tb mipsbsd.lo aout32.lo" ;;
545     aout_mips_little_vec)       tb="$tb mipsbsd.lo aout32.lo" ;;
546     apollocoff_vec)             tb="$tb coff-apollo.lo" ;;
547     arm_epoc_pe_big_vec)        tb="$tb epoc-pe-arm.lo peigen.lo cofflink.lo " ;;
548     arm_epoc_pe_little_vec)     tb="$tb epoc-pe-arm.lo peigen.lo cofflink.lo " ;;
549     arm_epoc_pei_big_vec)       tb="$tb epoc-pei-arm.lo peigen.lo cofflink.lo " ;;
550     arm_epoc_pei_little_vec)    tb="$tb epoc-pei-arm.lo peigen.lo cofflink.lo " ;;
551     armcoff_big_vec)            tb="$tb coff-arm.lo cofflink.lo " ;;
552     armcoff_little_vec)         tb="$tb coff-arm.lo cofflink.lo " ;;
553     armnetbsd_vec)              tb="$tb armnetbsd.lo aout32.lo" ;;
554     armpe_big_vec)              tb="$tb pe-arm.lo peigen.lo cofflink.lo " ;;
555     armpe_little_vec)           tb="$tb pe-arm.lo peigen.lo cofflink.lo " ;;
556     armpei_big_vec)             tb="$tb pei-arm.lo peigen.lo cofflink.lo " ;;
557     armpei_little_vec)          tb="$tb pei-arm.lo peigen.lo cofflink.lo " ;;
558     b_out_vec_big_host)         tb="$tb bout.lo aout32.lo" ;;
559     b_out_vec_little_host)      tb="$tb bout.lo aout32.lo" ;;
560     bfd_efi_app_ia32_vec)       tb="$tb efi-app-ia32.lo peigen.lo cofflink.lo" ;;
561     bfd_efi_app_ia64_vec)       tb="$tb efi-app-ia64.lo pepigen.lo cofflink.lo"; target_size=64 ;;
562     bfd_elf32_avr_vec)          tb="$tb elf32-avr.lo elf32.lo $elf" ;;
563     bfd_elf32_big_generic_vec)  tb="$tb elf32-gen.lo elf32.lo $elf" ;;
564     bfd_elf32_bigarc_vec)       tb="$tb elf32-arc.lo elf32.lo $elf" ;;
565     bfd_elf32_bigarm_oabi_vec)  tb="$tb elfarm-oabi.lo elf32.lo $elf" ;;
566     bfd_elf32_bigarm_vec)       tb="$tb elfarm-nabi.lo elf32.lo $elf" ;;
567     bfd_elf32_bigarmqnx_vec)    tb="$tb elfarmqnx-nabi.lo elfarm-nabi.lo elf32.lo $elf" ;;
568     bfd_elf32_bigmips_vec)      tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
569     bfd_elf32_cris_vec)         tb="$tb elf32-cris.lo elf32.lo $elf" ;;
570     bfd_elf32_d10v_vec)         tb="$tb elf32-d10v.lo elf32.lo $elf" ;;
571     bfd_elf32_d30v_vec)         tb="$tb elf32-d30v.lo elf32.lo $elf" ;;
572     bfd_elf32_dlx_big_vec)      tb="$tb elf32-dlx.lo elf32.lo $elf" ;;
573     bfd_elf32_fr30_vec)         tb="$tb elf32-fr30.lo elf32.lo $elf" ;;
574     bfd_elf32_frv_vec)          tb="$tb elf32-frv.lo elf32.lo $elf" ;;
575     bfd_elf32_h8300_vec)        tb="$tb elf32-h8300.lo elf32.lo $elf" ;;
576     bfd_elf32_hppa_linux_vec)   tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
577     bfd_elf32_hppa_vec)         tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
578     bfd_elf32_i370_vec)         tb="$tb elf32-i370.lo elf32.lo $elf" ;;
579     bfd_elf32_i386_freebsd_vec) tb="$tb elf32-i386-fbsd.lo elf32.lo $elf" ;;
580     bfd_elf32_i386_vec)         tb="$tb elf32-i386.lo elf32.lo $elf" ;;
581     bfd_elf32_i386qnx_vec)      tb="$tb elf32-i386qnx.lo elf32.lo $elf" ;;
582     bfd_elf32_i860_little_vec)  tb="$tb elf32-i860.lo elf32.lo $elf" ;;
583     bfd_elf32_i860_vec)         tb="$tb elf32-i860.lo elf32.lo $elf" ;;
584     bfd_elf32_i960_vec)         tb="$tb elf32-i960.lo elf32.lo $elf" ;;
585     bfd_elf32_ia64_big_vec)     tb="$tb elf32-ia64.lo elf32.lo $elf" ;;
586     bfd_elf32_ia64_hpux_big_vec) tb="$tb elf32-ia64.lo elf32.lo $elf";;
587     bfd_elf32_ip2k_vec)         tb="$tb elf32-ip2k.lo elf32.lo $elf" ;;
588     bfd_elf32_little_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
589     bfd_elf32_littlearc_vec)    tb="$tb elf32-arc.lo elf32.lo $elf" ;;
590     bfd_elf32_littlearm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo $elf" ;;
591     bfd_elf32_littlearm_vec)    tb="$tb elfarm-nabi.lo elf32.lo $elf" ;;
592     bfd_elf32_littlearmqnx_vec) tb="$tb elfarmqnx-nabi.lo elfarm-nabi.lo elf32.lo $elf" ;;
593     bfd_elf32_littlemips_vec)   tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
594     bfd_elf32_m32r_vec)         tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
595     bfd_elf32_m68hc11_vec)      tb="$tb elf32-m68hc11.lo elf32.lo $elf" ;;
596     bfd_elf32_m68hc12_vec)      tb="$tb elf32-m68hc12.lo elf32.lo $elf" ;;
597     bfd_elf32_m68k_vec)         tb="$tb elf32-m68k.lo elf32.lo $elf" ;;
598     bfd_elf32_m88k_vec)         tb="$tb elf32-m88k.lo elf32.lo $elf" ;;
599     bfd_elf32_mcore_big_vec)    tb="$tb elf32-mcore.lo elf32.lo $elf" ;;
600     bfd_elf32_mcore_little_vec) tb="$tb elf32-mcore.lo elf32.lo $elf" ;;
601     bfd_elf32_mn10200_vec)      tb="$tb elf-m10200.lo elf32.lo $elf" ;;
602     bfd_elf32_mn10300_vec)      tb="$tb elf-m10300.lo elf32.lo $elf" ;;
603     bfd_elf32_nbigmips_vec)     tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
604     bfd_elf32_nlittlemips_vec)  tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
605     bfd_elf32_ntradbigmips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
606     bfd_elf32_ntradlittlemips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
607     bfd_elf32_openrisc_vec)     tb="$tb elf32-openrisc.lo elf32.lo $elf" ;;
608     bfd_elf32_or32_big_vec)     tb="$tb elf32-or32.lo elf32.lo $elf" ;;
609     bfd_elf32_pj_vec)           tb="$tb elf32-pj.lo elf32.lo $elf";;
610     bfd_elf32_pjl_vec)          tb="$tb elf32-pj.lo elf32.lo $elf";;
611     bfd_elf32_powerpc_vec)      tb="$tb elf32-ppc.lo elf32.lo $elf" ;;
612     bfd_elf32_powerpcle_vec)    tb="$tb elf32-ppc.lo elf32.lo $elf" ;;
613     bfd_elf32_powerpcleqnx_vec) tb="$tb elf32-ppcqnx.lo elf32-ppc.lo elf32.lo $elf" ;;
614     bfd_elf32_powerpcqnx_vec)   tb="$tb elf32-ppcqnx.lo elf32-ppc.lo elf32.lo $elf" ;;
615     bfd_elf32_s390_vec)         tb="$tb elf32-s390.lo elf32.lo $elf" ;;
616     # FIXME: We include cofflink.lo not because it's needed for
617     # bfd_elf32_sh64[l]_vec, but because we include bfd_elf32_sh[l]_vec
618     # which needs it but does not list it.  Should be fixed in right place.
619     bfd_elf32_sh64_vec)         tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
620     bfd_elf32_sh64l_vec)        tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
621     bfd_elf32_sh64lin_vec)      tb="$tb elf32-sh64-lin.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
622     bfd_elf32_sh64blin_vec)     tb="$tb elf32-sh64-lin.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
623     bfd_elf32_sh64lnbsd_vec)    tb="$tb elf32-sh64-nbsd.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
624     bfd_elf32_sh64nbsd_vec)     tb="$tb elf32-sh64-nbsd.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
625     bfd_elf32_sh_vec)           tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo" ;;
626     bfd_elf32_shblin_vec)       tb="$tb elf32-sh-lin.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
627     bfd_elf32_shl_vec)          tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo" ;;
628     bfd_elf32_shlin_vec)        tb="$tb elf32-sh-lin.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
629     bfd_elf32_shlnbsd_vec)      tb="$tb elf32-sh-nbsd.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
630     bfd_elf32_shlqnx_vec)       tb="$tb elf32-shqnx.lo elf32-sh.lo elf32.lo $elf coff-sh.lo" ;;
631     bfd_elf32_shnbsd_vec)       tb="$tb elf32-sh-nbsd.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
632     bfd_elf32_shqnx_vec)        tb="$tb elf32-shqnx.lo elf32-sh.lo elf32.lo $elf coff-sh.lo" ;;
633     bfd_elf32_sparc_vec)        tb="$tb elf32-sparc.lo elf32.lo $elf" ;;
634     bfd_elf32_tradbigmips_vec)  tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
635     bfd_elf32_tradlittlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
636     bfd_elf32_us_cris_vec)      tb="$tb elf32-cris.lo elf32.lo $elf" ;;
637     bfd_elf32_v850_vec)         tb="$tb elf32-v850.lo elf32.lo $elf" ;;
638     bfd_elf32_vax_vec)          tb="$tb elf32-vax.lo elf32.lo $elf" ;;
639     bfd_elf32_xstormy16_vec)    tb="$tb elf32-xstormy16.lo elf32.lo $elf" ;;
640     bfd_elf64_alpha_freebsd_vec) tb="$tb elf64-alpha-fbsd.lo elf64.lo $elf"; target_size=64 ;;
641     bfd_elf64_alpha_vec)        tb="$tb elf64-alpha.lo elf64.lo $elf"; target_size=64 ;;
642     bfd_elf64_big_generic_vec)  tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
643     bfd_elf64_bigmips_vec)      tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
644     bfd_elf64_hppa_linux_vec)   tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;;
645     bfd_elf64_hppa_vec)         tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;;
646     bfd_elf64_ia64_aix_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
647     bfd_elf64_ia64_aix_little_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
648     bfd_elf64_ia64_big_vec)     tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
649     bfd_elf64_ia64_hpux_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
650     bfd_elf64_ia64_little_vec)  tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
651     bfd_elf64_little_generic_vec) tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
652     bfd_elf64_littlemips_vec)   tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
653     bfd_elf64_mmix_vec)         tb="$tb elf64-mmix.lo elf64.lo $elf" target_size=64 ;;
654     bfd_elf64_powerpc_vec)      tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
655     bfd_elf64_powerpcle_vec)    tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf" target_size=64 ;;
656     bfd_elf64_s390_vec)         tb="$tb elf64-s390.lo elf64.lo $elf"; target_size=64 ;;
657     bfd_elf64_sh64_vec)         tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
658     bfd_elf64_sh64l_vec)        tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
659     bfd_elf64_sh64lin_vec)      tb="$tb elf64-sh64-lin.lo elf64.lo $elf" target_size=64 ;;
660     bfd_elf64_sh64blin_vec)     tb="$tb elf64-sh64-lin.lo elf64.lo $elf" target_size=64 ;;
661     bfd_elf64_sh64lnbsd_vec)    tb="$tb elf64-sh64-nbsd.lo elf64.lo $elf" target_size=64 ;;
662     bfd_elf64_sh64nbsd_vec)     tb="$tb elf64-sh64-nbsd.lo elf64.lo $elf" target_size=64 ;;
663     bfd_elf64_sparc_vec)        tb="$tb elf64-sparc.lo elf64.lo $elf"; target_size=64 ;;
664     bfd_elf64_tradbigmips_vec)  tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
665     bfd_elf64_tradlittlemips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
666     bfd_elf64_x86_64_vec)       tb="$tb elf64-x86-64.lo elf64.lo $elf"; target_size=64 ;;
667     bfd_mmo_vec)                tb="$tb mmo.lo" target_size=64 ;;
668     bfd_powerpc_pe_vec)         tb="$tb pe-ppc.lo peigen.lo cofflink.lo" ;;
669     bfd_powerpc_pei_vec)        tb="$tb pei-ppc.lo peigen.lo cofflink.lo" ;;
670     bfd_powerpcle_pe_vec)       tb="$tb pe-ppc.lo peigen.lo cofflink.lo" ;;
671     bfd_powerpcle_pei_vec)      tb="$tb pei-ppc.lo peigen.lo cofflink.lo" ;;
672     cris_aout_vec)              tb="$tb aout-cris.lo" ;;
673     demo_64_vec)                tb="$tb demo64.lo aout64.lo"; target_size=64 ;;
674     ecoff_big_vec)              tb="$tb coff-mips.lo ecoff.lo ecofflink.lo" ;;
675     ecoff_biglittle_vec)        tb="$tb coff-mips.lo ecoff.lo ecofflink.lo" ;;
676     ecoff_little_vec)           tb="$tb coff-mips.lo ecoff.lo ecofflink.lo" ;;
677     ecoffalpha_little_vec)      tb="$tb coff-alpha.lo ecoff.lo ecofflink.lo"; target_size=64 ;;
678     go32coff_vec)               tb="$tb coff-go32.lo cofflink.lo" ;;
679     go32stubbedcoff_vec)        tb="$tb coff-stgo32.lo cofflink.lo" ;;
680     h8300coff_vec)              tb="$tb coff-h8300.lo reloc16.lo" ;;
681     h8500coff_vec)              tb="$tb coff-h8500.lo reloc16.lo" ;;
682     host_aout_vec)              tb="$tb host-aout.lo aout32.lo" ;;
683     hp300bsd_vec)               tb="$tb hp300bsd.lo aout32.lo" ;;
684     hp300hpux_vec)              tb="$tb hp300hpux.lo aout32.lo" ;;
685     i386aout_vec)               tb="$tb i386aout.lo aout32.lo" ;;
686     i386bsd_vec)                tb="$tb i386bsd.lo aout32.lo" ;;
687     i386coff_vec)               tb="$tb coff-i386.lo cofflink.lo" ;;
688     i386dynix_vec)              tb="$tb i386dynix.lo aout32.lo" ;;
689     i386freebsd_vec)            tb="$tb i386freebsd.lo aout32.lo" ;;
690     i386linux_vec)              tb="$tb i386linux.lo aout32.lo" ;;
691     i386lynx_aout_vec)          tb="$tb i386lynx.lo lynx-core.lo aout32.lo" ;;
692     i386lynx_coff_vec)          tb="$tb cf-i386lynx.lo cofflink.lo lynx-core.lo" ;;
693     i386mach3_vec)              tb="$tb i386mach3.lo aout32.lo" ;;
694     i386msdos_vec)              tb="$tb i386msdos.lo" ;;
695     i386netbsd_vec)             tb="$tb i386netbsd.lo aout32.lo" ;;
696     i386os9k_vec)               tb="$tb i386os9k.lo aout32.lo" ;;
697     i386pe_vec)                 tb="$tb pe-i386.lo peigen.lo cofflink.lo" ;;
698     i386pei_vec)                tb="$tb pei-i386.lo peigen.lo cofflink.lo" ;;
699     i860coff_vec)               tb="$tb coff-i860.lo cofflink.lo" ;;
700     icoff_big_vec)              tb="$tb coff-i960.lo cofflink.lo" ;;
701     icoff_little_vec)           tb="$tb coff-i960.lo cofflink.lo" ;;
702     ieee_vec)                   tb="$tb ieee.lo" ;;
703     m68k4knetbsd_vec)           tb="$tb m68k4knetbsd.lo aout32.lo" ;;
704     m68kaux_coff_vec)           tb="$tb coff-aux.lo coff-m68k.lo cofflink.lo" ;;
705     m68kcoff_vec)               tb="$tb coff-m68k.lo cofflink.lo" ;;
706     m68kcoffun_vec)             tb="$tb coff-u68k.lo coff-m68k.lo cofflink.lo" ;;
707     m68klinux_vec)              tb="$tb m68klinux.lo aout32.lo" ;;
708     m68klynx_aout_vec)          tb="$tb m68klynx.lo lynx-core.lo aout32.lo" ;;
709     m68klynx_coff_vec)          tb="$tb cf-m68klynx.lo coff-m68k.lo cofflink.lo lynx-core.lo" ;;
710     m68knetbsd_vec)             tb="$tb m68knetbsd.lo aout32.lo" ;;
711     m68ksysvcoff_vec)           tb="$tb coff-svm68k.lo cofflink.lo" ;;
712     m88kbcs_vec)                tb="$tb coff-m88k.lo" ;;
713     m88kmach3_vec)              tb="$tb m88kmach3.lo aout32.lo" ;;
714     mcore_pe_big_vec)           tb="$tb pe-mcore.lo peigen.lo cofflink.lo" ;;
715     mcore_pe_little_vec)        tb="$tb pe-mcore.lo peigen.lo cofflink.lo" ;;
716     mcore_pei_big_vec)          tb="$tb pei-mcore.lo peigen.lo cofflink.lo" ;;
717     mcore_pei_little_vec)       tb="$tb pei-mcore.lo peigen.lo cofflink.lo" ;;
718     mipslpe_vec)                tb="$tb pe-mips.lo peigen.lo cofflink.lo" ;;
719     mipslpei_vec)               tb="$tb pei-mips.lo peigen.lo cofflink.lo" ;;
720     newsos3_vec)                tb="$tb newsos3.lo aout32.lo" ;;
721     nlm32_alpha_vec)            tb="$tb nlm32-alpha.lo nlm32.lo nlm.lo"; target_size=64 ;;
722     nlm32_i386_vec)             tb="$tb nlm32-i386.lo nlm32.lo nlm.lo" ;;
723     nlm32_powerpc_vec)          tb="$tb nlm32-ppc.lo nlm32.lo nlm.lo" ;;
724     nlm32_sparc_vec)            tb="$tb nlm32-sparc.lo nlm32.lo nlm.lo" ;;
725     or32coff_big_vec)           tb="$tb coff-or32.lo cofflink.lo" ;;
726     pc532machaout_vec)          tb="$tb pc532-mach.lo aout-ns32k.lo" ;;
727     pc532netbsd_vec)            tb="$tb ns32knetbsd.lo aout-ns32k.lo" ;;
728     pdp11_aout_vec)             tb="$tb pdp11.lo" ;;
729     pmac_xcoff_vec)             tb="$tb coff-rs6000.lo xcofflink.lo" ;;
730     ppcboot_vec)                tb="$tb ppcboot.lo" ;;
731     riscix_vec)                 tb="$tb aout32.lo riscix.lo" ;;
732     rs6000coff64_vec)           tb="$tb coff64-rs6000.lo xcofflink.lo aix5ppc-core.lo"; target_size=64 ;;
733     rs6000coff_vec)             tb="$tb coff-rs6000.lo xcofflink.lo" ;;
734     shcoff_small_vec)           tb="$tb coff-sh.lo cofflink.lo" ;;
735     shcoff_vec)                 tb="$tb coff-sh.lo cofflink.lo" ;;
736     shlcoff_small_vec)          tb="$tb coff-sh.lo cofflink.lo" ;;
737     shlcoff_vec)                tb="$tb coff-sh.lo cofflink.lo" ;;
738     shlpe_vec)                  tb="$tb pe-sh.lo coff-sh.lo peigen.lo cofflink.lo" ;;
739     shlpei_vec)                 tb="$tb pei-sh.lo coff-sh.lo peigen.lo cofflink.lo" ;;
740     som_vec)                    tb="$tb som.lo" ;;
741     sparccoff_vec)              tb="$tb coff-sparc.lo" ;;
742     sparcle_aout_vec)           tb="$tb aout-sparcle.lo aout32.lo" ;;
743     sparclinux_vec)             tb="$tb sparclinux.lo aout32.lo" ;;
744     sparclynx_aout_vec)         tb="$tb sparclynx.lo lynx-core.lo aout32.lo" ;;
745     sparclynx_coff_vec)         tb="$tb cf-sparclynx.lo lynx-core.lo" ;;
746     sparcnetbsd_vec)            tb="$tb sparcnetbsd.lo aout32.lo" ;;
747     sunos_big_vec)              tb="$tb sunos.lo aout32.lo" ;;
748     tic30_aout_vec)             tb="$tb aout-tic30.lo" ;;
749     tic30_coff_vec)             tb="$tb coff-tic30.lo" ;;
750     tic4x_coff0_vec)            tb="$tb coff-tic4x.lo" ;;
751     tic4x_coff0_beh_vec)        tb="$tb coff-tic4x.lo" ;;
752     tic4x_coff1_vec)            tb="$tb coff-tic4x.lo" ;;
753     tic4x_coff1_beh_vec)        tb="$tb coff-tic4x.lo" ;;
754     tic4x_coff2_vec)            tb="$tb coff-tic4x.lo" ;;
755     tic4x_coff2_beh_vec)        tb="$tb coff-tic4x.lo" ;;
756     tic54x_coff0_beh_vec)       tb="$tb coff-tic54x.lo" ;;
757     tic54x_coff0_vec)           tb="$tb coff-tic54x.lo" ;;
758     tic54x_coff1_beh_vec)       tb="$tb coff-tic54x.lo" ;;
759     tic54x_coff1_vec)           tb="$tb coff-tic54x.lo" ;;
760     tic54x_coff2_beh_vec)       tb="$tb coff-tic54x.lo" ;;
761     tic54x_coff2_vec)           tb="$tb coff-tic54x.lo" ;;
762     tic80coff_vec)              tb="$tb coff-tic80.lo cofflink.lo" ;;
763     vaxnetbsd_vec)              tb="$tb vaxnetbsd.lo aout32.lo" ;;
764     vax1knetbsd_vec)            tb="$tb vax1knetbsd.lo aout32.lo" ;;
765     vaxbsd_vec)                 tb="$tb vaxbsd.lo aout32.lo" ;;
766     versados_vec)               tb="$tb versados.lo" ;;
767     vms_alpha_vec)              tb="$tb vms.lo vms-hdr.lo vms-gsd.lo vms-tir.lo vms-misc.lo"; target_size=64 ;;
768     vms_vax_vec)                tb="$tb vms.lo vms-hdr.lo vms-gsd.lo vms-tir.lo vms-misc.lo" ;;
769     w65_vec)                    tb="$tb coff-w65.lo reloc16.lo" ;;
770     we32kcoff_vec)              tb="$tb coff-we32k.lo" ;;
771     z8kcoff_vec)                tb="$tb coff-z8k.lo reloc16.lo" ;;
773     # These appear out of order in targets.c
774     srec_vec)                   tb="$tb srec.lo" ;;
775     symbolsrec_vec)             tb="$tb srec.lo" ;;
776     tekhex_vec)                 tb="$tb tekhex.lo" ;;
777     cisco_core_big_vec)         tb="$tb cisco-core.lo" ;;
778     cisco_core_little_vec)      tb="$tb cisco-core.lo" ;;
780     "")                 ;;
781     *) AC_MSG_ERROR(*** unknown target vector $vec) ;;
782     esac
784     if test ${target_size} = 64; then
785         target64=true
786     fi
787     if test x"${vec}" = x"${defvec}"; then
788         bfd_default_target_size=${target_size}
789     fi
790 done
792 # Target architecture .o files.
793 # A couple of CPUs use shorter file names to avoid problems on DOS
794 # filesystems.
795 ta=`echo $selarchs | sed -e s/bfd_/cpu-/g -e s/_arch/.lo/g -e s/mn10200/m10200/ -e s/mn10300/m10300/`
797 # Weed out duplicate .o files.
798 f=""
799 for i in $tb ; do
800     case " $f " in
801     *" $i "*) ;;
802     *) f="$f $i" ;;
803     esac
804 done
805 tb="$f"
807 f=""
808 for i in $ta ; do
809     case " $f " in
810     *" $i "*) ;;
811     *) f="$f $i" ;;
812     esac
813 done
814 ta="$f"
816 bfd_backends="$tb"
817 bfd_machines="$ta"
819 if test x${all_targets} = xtrue ; then
820   bfd_backends="${bfd_backends}"' $(ALL_BACKENDS)'
821   bfd_machines="${bfd_machines}"' $(ALL_MACHINES)'
822   selvecs=
823   havevecs=
824   selarchs=
825 else    # all_targets is true
826   # Only set these if they will be nonempty, for the clever echo.
827   havevecs=
828   test -n "$selvecs" &&
829     havevecs=`echo $selvecs | sed -e 's/^/-DHAVE_/' -e 's/ \(.\)/ -DHAVE_\1/g'`
830   test -n "$selvecs" &&
831     selvecs=`echo $selvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
832   test -n "$selarchs" &&
833     selarchs=`echo $selarchs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
834 fi      # all_targets is true
836 case ${host64}-${target64}-${want64} in
837   *true*)
838     wordsize=64
839     bfd_libs='$(BFD64_LIBS) $(BFD32_LIBS)'
840     all_backends='$(BFD64_BACKENDS) $(BFD32_BACKENDS)'
841     if test -z "$GCC" && test "$BFD_HOST_64BIT_LONG" = "0" && test "$BFD_HOST_64_BIT_DEFINED" = "0"; then
842       AC_MSG_WARN([You have requested a 64 bit BFD configuration, but])
843       AC_MSG_WARN([your compiler may not have a 64 bit integral type])
844     fi
845     if test -n "$GCC" ; then
846        bad_64bit_gcc=no;
847        AC_MSG_CHECKING([for gcc version with buggy 64-bit support])
848        # Add more tests for gcc versions with non-working 64-bit support here.
849        AC_EGREP_CPP([: 2 : 91 : 1 :],[:__GNUC__:__GNUC_MINOR__:__i386__:],
850                     bad_64bit_gcc=yes;
851                     AC_MSG_RESULT([yes: egcs-1.1.2 on ix86 spotted]),
852                     AC_MSG_RESULT(no))
853        if test $bad_64bit_gcc = yes ; then
854          AC_ERROR([A newer version of gcc is needed for the requested 64-bit BFD configuration])
855        fi
856     fi
857     ;;
858   false-false-false)
859     wordsize=32
860     bfd_libs='$(BFD32_LIBS)'
861     all_backends='$(BFD32_BACKENDS)'
862     ;;
863 esac
865 AC_SUBST(wordsize)
866 AC_SUBST(bfd_libs)
867 AC_SUBST(all_backends)
868 AC_SUBST(bfd_backends)
869 AC_SUBST(bfd_machines)
870 AC_SUBST(bfd_default_target_size)
872 tdefaults=""
873 test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}"
874 test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'"
875 test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'"
876 test -n "${havevecs}" && tdefaults="${tdefaults} ${havevecs}"
877 AC_SUBST(tdefaults)
879 dnl AC_CHECK_HEADERS(sys/mman.h)
880 AC_FUNC_MMAP
881 AC_CHECK_FUNCS(madvise mprotect)
882 case ${want_mmap}+${ac_cv_func_mmap_fixed_mapped} in
883   true+yes )  AC_DEFINE(USE_MMAP, 1, [Use mmap if it's available?]) ;;
884 esac
886 rm -f doc/config.status
887 AC_OUTPUT(Makefile doc/Makefile bfd-in3.h:bfd-in2.h po/Makefile.in:po/Make-in,
888 [sed -e '/SRC-POTFILES =/r po/SRC-POTFILES' -e '/BLD-POTFILES =/r po/BLD-POTFILES' po/Makefile.in > po/Makefile])