* elf.c (prep_headers): Add bfd_arch_alpha case.
[deliverable/binutils-gdb.git] / bfd / configure
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.10
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6 #
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15 --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)"
16 ac_help="$ac_help
17 --enable-targets alternative target configurations"
18 ac_help="$ac_help
19 --enable-shared build shared BFD library"
20 ac_help="$ac_help
21 --enable-commonbfdlib build shared BFD/opcodes/libiberty library"
22 ac_help="$ac_help
23 --with-mmap try using mmap for BFD input files if available"
24
25 # Initialize some variables set by options.
26 # The variables have the same names as the options, with
27 # dashes changed to underlines.
28 build=NONE
29 cache_file=./config.cache
30 exec_prefix=NONE
31 host=NONE
32 no_create=
33 nonopt=NONE
34 no_recursion=
35 prefix=NONE
36 program_prefix=NONE
37 program_suffix=NONE
38 program_transform_name=s,x,x,
39 silent=
40 site=
41 srcdir=
42 target=NONE
43 verbose=
44 x_includes=NONE
45 x_libraries=NONE
46 bindir='${exec_prefix}/bin'
47 sbindir='${exec_prefix}/sbin'
48 libexecdir='${exec_prefix}/libexec'
49 datadir='${prefix}/share'
50 sysconfdir='${prefix}/etc'
51 sharedstatedir='${prefix}/com'
52 localstatedir='${prefix}/var'
53 libdir='${exec_prefix}/lib'
54 includedir='${prefix}/include'
55 oldincludedir='/usr/include'
56 infodir='${prefix}/info'
57 mandir='${prefix}/man'
58
59 # Initialize some other variables.
60 subdirs=
61 MFLAGS= MAKEFLAGS=
62
63 ac_prev=
64 for ac_option
65 do
66
67 # If the previous option needs an argument, assign it.
68 if test -n "$ac_prev"; then
69 eval "$ac_prev=\$ac_option"
70 ac_prev=
71 continue
72 fi
73
74 case "$ac_option" in
75 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
76 *) ac_optarg= ;;
77 esac
78
79 # Accept the important Cygnus configure options, so we can diagnose typos.
80
81 case "$ac_option" in
82
83 -bindir | --bindir | --bindi | --bind | --bin | --bi)
84 ac_prev=bindir ;;
85 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
86 bindir="$ac_optarg" ;;
87
88 -build | --build | --buil | --bui | --bu)
89 ac_prev=build ;;
90 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
91 build="$ac_optarg" ;;
92
93 -cache-file | --cache-file | --cache-fil | --cache-fi \
94 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
95 ac_prev=cache_file ;;
96 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
97 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
98 cache_file="$ac_optarg" ;;
99
100 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
101 ac_prev=datadir ;;
102 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
103 | --da=*)
104 datadir="$ac_optarg" ;;
105
106 -disable-* | --disable-*)
107 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
108 # Reject names that are not valid shell variable names.
109 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
110 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
111 fi
112 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
113 eval "enable_${ac_feature}=no" ;;
114
115 -enable-* | --enable-*)
116 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
117 # Reject names that are not valid shell variable names.
118 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
119 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
120 fi
121 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
122 case "$ac_option" in
123 *=*) ;;
124 *) ac_optarg=yes ;;
125 esac
126 eval "enable_${ac_feature}='$ac_optarg'" ;;
127
128 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
129 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
130 | --exec | --exe | --ex)
131 ac_prev=exec_prefix ;;
132 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
133 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
134 | --exec=* | --exe=* | --ex=*)
135 exec_prefix="$ac_optarg" ;;
136
137 -gas | --gas | --ga | --g)
138 # Obsolete; use --with-gas.
139 with_gas=yes ;;
140
141 -help | --help | --hel | --he)
142 # Omit some internal or obsolete options to make the list less imposing.
143 # This message is too long to be a string in the A/UX 3.1 sh.
144 cat << EOF
145 Usage: configure [options] [host]
146 Options: [defaults in brackets after descriptions]
147 Configuration:
148 --cache-file=FILE cache test results in FILE
149 --help print this message
150 --no-create do not create output files
151 --quiet, --silent do not print \`checking...' messages
152 --version print the version of autoconf that created configure
153 Directory and file names:
154 --prefix=PREFIX install architecture-independent files in PREFIX
155 [$ac_default_prefix]
156 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
157 [same as prefix]
158 --bindir=DIR user executables in DIR [EPREFIX/bin]
159 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
160 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
161 --datadir=DIR read-only architecture-independent data in DIR
162 [PREFIX/share]
163 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
164 --sharedstatedir=DIR modifiable architecture-independent data in DIR
165 [PREFIX/com]
166 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
167 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
168 --includedir=DIR C header files in DIR [PREFIX/include]
169 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
170 --infodir=DIR info documentation in DIR [PREFIX/info]
171 --mandir=DIR man documentation in DIR [PREFIX/man]
172 --srcdir=DIR find the sources in DIR [configure dir or ..]
173 --program-prefix=PREFIX prepend PREFIX to installed program names
174 --program-suffix=SUFFIX append SUFFIX to installed program names
175 --program-transform-name=PROGRAM
176 run sed PROGRAM on installed program names
177 EOF
178 cat << EOF
179 Host type:
180 --build=BUILD configure for building on BUILD [BUILD=HOST]
181 --host=HOST configure for HOST [guessed]
182 --target=TARGET configure for TARGET [TARGET=HOST]
183 Features and packages:
184 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
185 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
186 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
187 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
188 --x-includes=DIR X include files are in DIR
189 --x-libraries=DIR X library files are in DIR
190 EOF
191 if test -n "$ac_help"; then
192 echo "--enable and --with options recognized:$ac_help"
193 fi
194 exit 0 ;;
195
196 -host | --host | --hos | --ho)
197 ac_prev=host ;;
198 -host=* | --host=* | --hos=* | --ho=*)
199 host="$ac_optarg" ;;
200
201 -includedir | --includedir | --includedi | --included | --include \
202 | --includ | --inclu | --incl | --inc)
203 ac_prev=includedir ;;
204 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
205 | --includ=* | --inclu=* | --incl=* | --inc=*)
206 includedir="$ac_optarg" ;;
207
208 -infodir | --infodir | --infodi | --infod | --info | --inf)
209 ac_prev=infodir ;;
210 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
211 infodir="$ac_optarg" ;;
212
213 -libdir | --libdir | --libdi | --libd)
214 ac_prev=libdir ;;
215 -libdir=* | --libdir=* | --libdi=* | --libd=*)
216 libdir="$ac_optarg" ;;
217
218 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
219 | --libexe | --libex | --libe)
220 ac_prev=libexecdir ;;
221 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
222 | --libexe=* | --libex=* | --libe=*)
223 libexecdir="$ac_optarg" ;;
224
225 -localstatedir | --localstatedir | --localstatedi | --localstated \
226 | --localstate | --localstat | --localsta | --localst \
227 | --locals | --local | --loca | --loc | --lo)
228 ac_prev=localstatedir ;;
229 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
230 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
231 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
232 localstatedir="$ac_optarg" ;;
233
234 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
235 ac_prev=mandir ;;
236 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
237 mandir="$ac_optarg" ;;
238
239 -nfp | --nfp | --nf)
240 # Obsolete; use --without-fp.
241 with_fp=no ;;
242
243 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
244 | --no-cr | --no-c)
245 no_create=yes ;;
246
247 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
248 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
249 no_recursion=yes ;;
250
251 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
252 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
253 | --oldin | --oldi | --old | --ol | --o)
254 ac_prev=oldincludedir ;;
255 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
256 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
257 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
258 oldincludedir="$ac_optarg" ;;
259
260 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
261 ac_prev=prefix ;;
262 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
263 prefix="$ac_optarg" ;;
264
265 -program-prefix | --program-prefix | --program-prefi | --program-pref \
266 | --program-pre | --program-pr | --program-p)
267 ac_prev=program_prefix ;;
268 -program-prefix=* | --program-prefix=* | --program-prefi=* \
269 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
270 program_prefix="$ac_optarg" ;;
271
272 -program-suffix | --program-suffix | --program-suffi | --program-suff \
273 | --program-suf | --program-su | --program-s)
274 ac_prev=program_suffix ;;
275 -program-suffix=* | --program-suffix=* | --program-suffi=* \
276 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
277 program_suffix="$ac_optarg" ;;
278
279 -program-transform-name | --program-transform-name \
280 | --program-transform-nam | --program-transform-na \
281 | --program-transform-n | --program-transform- \
282 | --program-transform | --program-transfor \
283 | --program-transfo | --program-transf \
284 | --program-trans | --program-tran \
285 | --progr-tra | --program-tr | --program-t)
286 ac_prev=program_transform_name ;;
287 -program-transform-name=* | --program-transform-name=* \
288 | --program-transform-nam=* | --program-transform-na=* \
289 | --program-transform-n=* | --program-transform-=* \
290 | --program-transform=* | --program-transfor=* \
291 | --program-transfo=* | --program-transf=* \
292 | --program-trans=* | --program-tran=* \
293 | --progr-tra=* | --program-tr=* | --program-t=*)
294 program_transform_name="$ac_optarg" ;;
295
296 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
297 | -silent | --silent | --silen | --sile | --sil)
298 silent=yes ;;
299
300 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
301 ac_prev=sbindir ;;
302 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
303 | --sbi=* | --sb=*)
304 sbindir="$ac_optarg" ;;
305
306 -sharedstatedir | --sharedstatedir | --sharedstatedi \
307 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
308 | --sharedst | --shareds | --shared | --share | --shar \
309 | --sha | --sh)
310 ac_prev=sharedstatedir ;;
311 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
312 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
313 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
314 | --sha=* | --sh=*)
315 sharedstatedir="$ac_optarg" ;;
316
317 -site | --site | --sit)
318 ac_prev=site ;;
319 -site=* | --site=* | --sit=*)
320 site="$ac_optarg" ;;
321
322 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
323 ac_prev=srcdir ;;
324 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
325 srcdir="$ac_optarg" ;;
326
327 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
328 | --syscon | --sysco | --sysc | --sys | --sy)
329 ac_prev=sysconfdir ;;
330 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
331 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
332 sysconfdir="$ac_optarg" ;;
333
334 -target | --target | --targe | --targ | --tar | --ta | --t)
335 ac_prev=target ;;
336 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
337 target="$ac_optarg" ;;
338
339 -v | -verbose | --verbose | --verbos | --verbo | --verb)
340 verbose=yes ;;
341
342 -version | --version | --versio | --versi | --vers)
343 echo "configure generated by autoconf version 2.10"
344 exit 0 ;;
345
346 -with-* | --with-*)
347 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
348 # Reject names that are not valid shell variable names.
349 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
350 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
351 fi
352 ac_package=`echo $ac_package| sed 's/-/_/g'`
353 case "$ac_option" in
354 *=*) ;;
355 *) ac_optarg=yes ;;
356 esac
357 eval "with_${ac_package}='$ac_optarg'" ;;
358
359 -without-* | --without-*)
360 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
361 # Reject names that are not valid shell variable names.
362 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
363 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
364 fi
365 ac_package=`echo $ac_package| sed 's/-/_/g'`
366 eval "with_${ac_package}=no" ;;
367
368 --x)
369 # Obsolete; use --with-x.
370 with_x=yes ;;
371
372 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
373 | --x-incl | --x-inc | --x-in | --x-i)
374 ac_prev=x_includes ;;
375 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
376 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
377 x_includes="$ac_optarg" ;;
378
379 -x-libraries | --x-libraries | --x-librarie | --x-librari \
380 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
381 ac_prev=x_libraries ;;
382 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
383 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
384 x_libraries="$ac_optarg" ;;
385
386 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
387 ;;
388
389 *)
390 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
391 echo "configure: warning: $ac_option: invalid host type" 1>&2
392 fi
393 if test "x$nonopt" != xNONE; then
394 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
395 fi
396 nonopt="$ac_option"
397 ;;
398
399 esac
400 done
401
402 if test -n "$ac_prev"; then
403 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
404 fi
405
406 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
407
408 # File descriptor usage:
409 # 0 standard input
410 # 1 file creation
411 # 2 errors and warnings
412 # 3 some systems may open it to /dev/tty
413 # 4 used on the Kubota Titan
414 # 6 checking for... messages and results
415 # 5 compiler messages saved in config.log
416 if test "$silent" = yes; then
417 exec 6>/dev/null
418 else
419 exec 6>&1
420 fi
421 exec 5>./config.log
422
423 echo "\
424 This file contains any messages produced by compilers while
425 running configure, to aid debugging if configure makes a mistake.
426 " 1>&5
427
428 # Strip out --no-create and --no-recursion so they do not pile up.
429 # Also quote any args containing shell metacharacters.
430 ac_configure_args=
431 for ac_arg
432 do
433 case "$ac_arg" in
434 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
435 | --no-cr | --no-c) ;;
436 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
437 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
438 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
439 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
440 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
441 esac
442 done
443
444 # NLS nuisances.
445 # Only set LANG and LC_ALL to C if already set.
446 # These must not be set unconditionally because not all systems understand
447 # e.g. LANG=C (notably SCO).
448 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
449 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
450
451 # confdefs.h avoids OS command line length limits that DEFS can exceed.
452 rm -rf conftest* confdefs.h
453 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
454 echo > confdefs.h
455
456 # A filename unique to this package, relative to the directory that
457 # configure is in, which we can look for to find out if srcdir is correct.
458 ac_unique_file=libbfd.c
459
460 # Find the source files, if location was not specified.
461 if test -z "$srcdir"; then
462 ac_srcdir_defaulted=yes
463 # Try the directory containing this script, then its parent.
464 ac_prog=$0
465 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
466 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
467 srcdir=$ac_confdir
468 if test ! -r $srcdir/$ac_unique_file; then
469 srcdir=..
470 fi
471 else
472 ac_srcdir_defaulted=no
473 fi
474 if test ! -r $srcdir/$ac_unique_file; then
475 if test "$ac_srcdir_defaulted" = yes; then
476 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
477 else
478 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
479 fi
480 fi
481 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
482
483 # Prefer explicitly selected file to automatically selected ones.
484 if test -z "$CONFIG_SITE"; then
485 if test "x$prefix" != xNONE; then
486 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
487 else
488 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
489 fi
490 fi
491 for ac_site_file in $CONFIG_SITE; do
492 if test -r "$ac_site_file"; then
493 echo "loading site script $ac_site_file"
494 . "$ac_site_file"
495 fi
496 done
497
498 if test -r "$cache_file"; then
499 echo "loading cache $cache_file"
500 . $cache_file
501 else
502 echo "creating cache $cache_file"
503 > $cache_file
504 fi
505
506 ac_ext=c
507 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
508 ac_cpp='$CPP $CPPFLAGS'
509 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
510 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
511
512 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
513 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
514 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
515 ac_n= ac_c='
516 ' ac_t=' '
517 else
518 ac_n=-n ac_c= ac_t=
519 fi
520 else
521 ac_n= ac_c='\c' ac_t=
522 fi
523
524
525
526 # Check whether --enable-64-bit-bfd or --disable-64-bit-bfd was given.
527 if test "${enable_64_bit_bfd+set}" = set; then
528 enableval="$enable_64_bit_bfd"
529 case "${enableval}" in
530 yes) want64=true ;;
531 no) want64=false ;;
532 *) { echo "configure: error: bad value ${enableval} for 64-bit-bfd option" 1>&2; exit 1; } ;;
533 esac
534 else
535 want64=false
536 fi
537 # Check whether --enable-targets or --disable-targets was given.
538 if test "${enable_targets+set}" = set; then
539 enableval="$enable_targets"
540 case "${enableval}" in
541 yes | "") { echo "configure: error: enable-targets option must specify target names or 'all'" 1>&2; exit 1; }
542 ;;
543 no) enable_targets= ;;
544 *) enable_targets=$enableval ;;
545 esac
546 fi
547 # Check whether --enable-shared or --disable-shared was given.
548 if test "${enable_shared+set}" = set; then
549 enableval="$enable_shared"
550 case "${enableval}" in
551 yes) shared=true ;;
552 no) shared=false ;;
553 *bfd*) shared=true ;;
554 *) shared=false ;;
555 esac
556 fi
557 # Check whether --enable-commonbfdlib or --disable-commonbfdlib was given.
558 if test "${enable_commonbfdlib+set}" = set; then
559 enableval="$enable_commonbfdlib"
560 case "${enableval}" in
561 yes) commonbfdlib=true ;;
562 no) commonbfdlib=false ;;
563 *) { echo "configure: error: bad value ${enableval} for BFD commonbfdlib option" 1>&2; exit 1; } ;;
564 esac
565 fi
566 # Check whether --with-mmap or --without-mmap was given.
567 if test "${with_mmap+set}" = set; then
568 withval="$with_mmap"
569 case "${withval}" in
570 yes) want_mmap=true ;;
571 no) want_mmap=false ;;
572 *) { echo "configure: error: bad value ${withval} for BFD with-mmap option" 1>&2; exit 1; } ;;
573 esac
574 else
575 want_mmap=false
576 fi
577
578
579
580 ac_aux_dir=
581 for ac_dir in `cd $srcdir/..;pwd` $srcdir/`cd $srcdir/..;pwd`; do
582 if test -f $ac_dir/install-sh; then
583 ac_aux_dir=$ac_dir
584 ac_install_sh="$ac_aux_dir/install-sh -c"
585 break
586 elif test -f $ac_dir/install.sh; then
587 ac_aux_dir=$ac_dir
588 ac_install_sh="$ac_aux_dir/install.sh -c"
589 break
590 fi
591 done
592 if test -z "$ac_aux_dir"; then
593 { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir/..;pwd` $srcdir/`cd $srcdir/..;pwd`" 1>&2; exit 1; }
594 fi
595 ac_config_guess=$ac_aux_dir/config.guess
596 ac_config_sub=$ac_aux_dir/config.sub
597 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
598
599
600 # Do some error checking and defaulting for the host and target type.
601 # The inputs are:
602 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
603 #
604 # The rules are:
605 # 1. You are not allowed to specify --host, --target, and nonopt at the
606 # same time.
607 # 2. Host defaults to nonopt.
608 # 3. If nonopt is not specified, then host defaults to the current host,
609 # as determined by config.guess.
610 # 4. Target and build default to nonopt.
611 # 5. If nonopt is not specified, then target and build default to host.
612
613 # The aliases save the names the user supplied, while $host etc.
614 # will get canonicalized.
615 case $host---$target---$nonopt in
616 NONE---*---* | *---NONE---* | *---*---NONE) ;;
617 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
618 esac
619
620
621 # Make sure we can run config.sub.
622 if $ac_config_sub sun4 >/dev/null 2>&1; then :
623 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
624 fi
625
626 echo $ac_n "checking host system type""... $ac_c" 1>&6
627
628 host_alias=$host
629 case "$host_alias" in
630 NONE)
631 case $nonopt in
632 NONE)
633 if host_alias=`$ac_config_guess`; then :
634 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
635 fi ;;
636 *) host_alias=$nonopt ;;
637 esac ;;
638 esac
639
640 host=`$ac_config_sub $host_alias`
641 host_cpu=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
642 host_vendor=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
643 host_os=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
644 echo "$ac_t""$host" 1>&6
645
646 echo $ac_n "checking target system type""... $ac_c" 1>&6
647
648 target_alias=$target
649 case "$target_alias" in
650 NONE)
651 case $nonopt in
652 NONE) target_alias=$host_alias ;;
653 *) target_alias=$nonopt ;;
654 esac ;;
655 esac
656
657 target=`$ac_config_sub $target_alias`
658 target_cpu=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
659 target_vendor=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
660 target_os=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
661 echo "$ac_t""$target" 1>&6
662
663 echo $ac_n "checking build system type""... $ac_c" 1>&6
664
665 build_alias=$build
666 case "$build_alias" in
667 NONE)
668 case $nonopt in
669 NONE) build_alias=$host_alias ;;
670 *) build_alias=$nonopt ;;
671 esac ;;
672 esac
673
674 build=`$ac_config_sub $build_alias`
675 build_cpu=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
676 build_vendor=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
677 build_os=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
678 echo "$ac_t""$build" 1>&6
679
680 test "$host_alias" != "$target_alias" &&
681 test "$program_prefix$program_suffix$program_transform_name" = \
682 NONENONEs,x,x, &&
683 program_prefix=${target_alias}-
684
685 if test -z "$target" ; then
686 { echo "configure: error: Unrecognized target system type; please check config.sub." 1>&2; exit 1; }
687 fi
688 if test "$program_transform_name" = s,x,x,; then
689 program_transform_name=
690 else
691 # Double any \ or $. echo might interpret backslashes.
692 cat <<\EOF_SED > conftestsed
693 s,\\,\\\\,g; s,\$,$$,g
694 EOF_SED
695 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
696 rm -f conftestsed
697 fi
698 test "$program_prefix" != NONE &&
699 program_transform_name="s,^,${program_prefix},; $program_transform_name"
700 # Use a double $ so make ignores it.
701 test "$program_suffix" != NONE &&
702 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
703
704 # sed with no file args requires a program.
705 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
706
707
708 host64=false
709 target64=false
710
711 # host stuff:
712
713 ALLLIBS='$(TARGETLIB)'
714 PICFLAG=
715 SHLIB=unused-shlib
716 SHLINK=unused-shlink
717 if test "${shared}" = "true"; then
718 PICFLAG=-fpic
719 if test "${commonbfdlib}" = "true"; then
720 ALLLIBS='$(TARGETLIB)'
721 else
722 ALLLIBS='$(TARGETLIB) $(SHLIB) $(SHLINK)'
723 SHLIB=libbfd.so.`sed -e 's/[^0-9]*\([0-9.]*\).*/\1/' ${srcdir}/VERSION`
724 SHLINK=libbfd.so
725 fi
726 fi
727
728 # Extract the first word of "gcc", so it can be a program name with args.
729 set dummy gcc; ac_word=$2
730 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
731 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
732 echo $ac_n "(cached) $ac_c" 1>&6
733 else
734 if test -n "$CC"; then
735 ac_cv_prog_CC="$CC" # Let the user override the test.
736 else
737 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
738 for ac_dir in $PATH; do
739 test -z "$ac_dir" && ac_dir=.
740 if test -f $ac_dir/$ac_word; then
741 ac_cv_prog_CC="gcc"
742 break
743 fi
744 done
745 IFS="$ac_save_ifs"
746 fi
747 fi
748 CC="$ac_cv_prog_CC"
749 if test -n "$CC"; then
750 echo "$ac_t""$CC" 1>&6
751 else
752 echo "$ac_t""no" 1>&6
753 fi
754
755 if test -z "$CC"; then
756 # Extract the first word of "cc", so it can be a program name with args.
757 set dummy cc; ac_word=$2
758 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
759 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
760 echo $ac_n "(cached) $ac_c" 1>&6
761 else
762 if test -n "$CC"; then
763 ac_cv_prog_CC="$CC" # Let the user override the test.
764 else
765 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
766 ac_prog_rejected=no
767 for ac_dir in $PATH; do
768 test -z "$ac_dir" && ac_dir=.
769 if test -f $ac_dir/$ac_word; then
770 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
771 ac_prog_rejected=yes
772 continue
773 fi
774 ac_cv_prog_CC="cc"
775 break
776 fi
777 done
778 IFS="$ac_save_ifs"
779 if test $ac_prog_rejected = yes; then
780 # We found a bogon in the path, so make sure we never use it.
781 set dummy $ac_cv_prog_CC
782 shift
783 if test $# -gt 0; then
784 # We chose a different compiler from the bogus one.
785 # However, it has the same basename, so the bogon will be chosen
786 # first if we set CC to just the basename; use the full file name.
787 shift
788 set dummy "$ac_dir/$ac_word" "$@"
789 shift
790 ac_cv_prog_CC="$@"
791 fi
792 fi
793 fi
794 fi
795 CC="$ac_cv_prog_CC"
796 if test -n "$CC"; then
797 echo "$ac_t""$CC" 1>&6
798 else
799 echo "$ac_t""no" 1>&6
800 fi
801
802 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
803 fi
804
805 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
806 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
807 echo $ac_n "(cached) $ac_c" 1>&6
808 else
809 cat > conftest.c <<EOF
810 #ifdef __GNUC__
811 yes;
812 #endif
813 EOF
814 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:815: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
815 ac_cv_prog_gcc=yes
816 else
817 ac_cv_prog_gcc=no
818 fi
819 fi
820
821 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
822 if test $ac_cv_prog_gcc = yes; then
823 GCC=yes
824 if test "${CFLAGS+set}" != set; then
825 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
826 if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then
827 echo $ac_n "(cached) $ac_c" 1>&6
828 else
829 echo 'void f(){}' > conftest.c
830 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
831 ac_cv_prog_gcc_g=yes
832 else
833 ac_cv_prog_gcc_g=no
834 fi
835 rm -f conftest*
836
837 fi
838
839 echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6
840 if test $ac_cv_prog_gcc_g = yes; then
841 CFLAGS="-g -O"
842 else
843 CFLAGS="-O"
844 fi
845 fi
846 else
847 GCC=
848 test "${CFLAGS+set}" = set || CFLAGS="-g"
849 fi
850
851
852 # Permit host specific settings.
853 . ${srcdir}/configure.host
854
855
856 if test $host != $build; then
857 ac_tool_prefix=${host_alias}-
858 else
859 ac_tool_prefix=
860 fi
861
862 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
863 set dummy ${ac_tool_prefix}ar; ac_word=$2
864 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
865 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
866 echo $ac_n "(cached) $ac_c" 1>&6
867 else
868 if test -n "$AR"; then
869 ac_cv_prog_AR="$AR" # Let the user override the test.
870 else
871 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
872 for ac_dir in $PATH; do
873 test -z "$ac_dir" && ac_dir=.
874 if test -f $ac_dir/$ac_word; then
875 ac_cv_prog_AR="${ac_tool_prefix}ar"
876 break
877 fi
878 done
879 IFS="$ac_save_ifs"
880 test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
881 fi
882 fi
883 AR="$ac_cv_prog_AR"
884 if test -n "$AR"; then
885 echo "$ac_t""$AR" 1>&6
886 else
887 echo "$ac_t""no" 1>&6
888 fi
889
890
891
892 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
893 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
894 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
895 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
896 echo $ac_n "(cached) $ac_c" 1>&6
897 else
898 if test -n "$RANLIB"; then
899 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
900 else
901 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
902 for ac_dir in $PATH; do
903 test -z "$ac_dir" && ac_dir=.
904 if test -f $ac_dir/$ac_word; then
905 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
906 break
907 fi
908 done
909 IFS="$ac_save_ifs"
910 fi
911 fi
912 RANLIB="$ac_cv_prog_RANLIB"
913 if test -n "$RANLIB"; then
914 echo "$ac_t""$RANLIB" 1>&6
915 else
916 echo "$ac_t""no" 1>&6
917 fi
918
919
920 if test -z "$ac_cv_prog_RANLIB"; then
921 if test -n "$ac_tool_prefix"; then
922 # Extract the first word of "ranlib", so it can be a program name with args.
923 set dummy ranlib; ac_word=$2
924 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
925 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
926 echo $ac_n "(cached) $ac_c" 1>&6
927 else
928 if test -n "$RANLIB"; then
929 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
930 else
931 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
932 for ac_dir in $PATH; do
933 test -z "$ac_dir" && ac_dir=.
934 if test -f $ac_dir/$ac_word; then
935 ac_cv_prog_RANLIB="ranlib"
936 break
937 fi
938 done
939 IFS="$ac_save_ifs"
940 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
941 fi
942 fi
943 RANLIB="$ac_cv_prog_RANLIB"
944 if test -n "$RANLIB"; then
945 echo "$ac_t""$RANLIB" 1>&6
946 else
947 echo "$ac_t""no" 1>&6
948 fi
949
950 else
951 RANLIB=":"
952 fi
953 fi
954
955 # Find a good install program. We prefer a C program (faster),
956 # so one script is as good as another. But avoid the broken or
957 # incompatible versions:
958 # SysV /etc/install, /usr/sbin/install
959 # SunOS /usr/etc/install
960 # IRIX /sbin/install
961 # AIX /bin/install
962 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
963 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
964 # ./install, which can be erroneously created by make from ./install.sh.
965 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
966 if test -z "$INSTALL"; then
967 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
968 echo $ac_n "(cached) $ac_c" 1>&6
969 else
970 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
971 for ac_dir in $PATH; do
972 # Account for people who put trailing slashes in PATH elements.
973 case "$ac_dir/" in
974 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
975 *)
976 # OSF1 and SCO ODT 3.0 have their own names for install.
977 for ac_prog in ginstall installbsd scoinst install; do
978 if test -f $ac_dir/$ac_prog; then
979 if test $ac_prog = install &&
980 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
981 # AIX install. It has an incompatible calling convention.
982 # OSF/1 installbsd also uses dspmsg, but is usable.
983 :
984 else
985 ac_cv_path_install="$ac_dir/$ac_prog -c"
986 break 2
987 fi
988 fi
989 done
990 ;;
991 esac
992 done
993 IFS="$ac_save_ifs"
994
995 fi
996 if test "${ac_cv_path_install+set}" = set; then
997 INSTALL="$ac_cv_path_install"
998 else
999 # As a last resort, use the slow shell script. We don't cache a
1000 # path for INSTALL within a source directory, because that will
1001 # break other packages using the cache if that directory is
1002 # removed, or if the path is relative.
1003 INSTALL="$ac_install_sh"
1004 fi
1005 fi
1006 echo "$ac_t""$INSTALL" 1>&6
1007
1008 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1009 # It thinks the first close brace ends the variable substitution.
1010 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1011
1012 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1013
1014
1015 if test "${shared}" = "true"; then
1016 if test "${GCC}" != "yes" && test "${shared_non_gcc}" != "yes"; then
1017 echo "configure: warning: BFD --enable-shared only supported when using gcc" 1>&2
1018 shared=false
1019 ALLLIBS='$(TARGETLIB)'
1020 PICFLAG=
1021 SHLIB=unused-shlib
1022 fi
1023 fi
1024
1025
1026
1027
1028
1029
1030 if test "${commonbfdlib}" = "true"; then
1031 COMMON_SHLIB=yes
1032 PICLIST=piclist
1033 else
1034 COMMON_SHLIB=
1035 PICLIST=
1036 fi
1037
1038
1039
1040
1041 HOST_64BIT_LONG=0
1042 if test "x${HOST_64BIT_TYPE}" = "xlong"; then
1043 HOST_64BIT_LONG=1
1044 fi
1045
1046
1047 # If we cannot run a trivial program, we must be cross compiling.
1048 echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6
1049 if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then
1050 echo $ac_n "(cached) $ac_c" 1>&6
1051 else
1052 if test "$cross_compiling" = yes; then
1053 ac_cv_c_cross=yes
1054 else
1055 cat > conftest.$ac_ext <<EOF
1056 #line 1057 "configure"
1057 #include "confdefs.h"
1058 main(){return(0);}
1059 EOF
1060 { (eval echo configure:1061: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }
1061 if test -s conftest && (./conftest; exit) 2>/dev/null; then
1062 ac_cv_c_cross=no
1063 else
1064 ac_cv_c_cross=yes
1065 fi
1066 fi
1067 rm -fr conftest*
1068 fi
1069
1070 echo "$ac_t""$ac_cv_c_cross" 1>&6
1071 cross_compiling=$ac_cv_c_cross
1072
1073 # Put a plausible default for CC_FOR_BUILD in Makefile.
1074 if test -z "$CC_FOR_BUILD"; then
1075 if test "x$cross_compiling" = "xno"; then
1076 CC_FOR_BUILD='$(CC)'
1077 else
1078 CC_FOR_BUILD=gcc
1079 fi
1080 fi
1081
1082
1083 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1084 # On Suns, sometimes $CPP names a directory.
1085 if test -n "$CPP" && test -d "$CPP"; then
1086 CPP=
1087 fi
1088 if test -z "$CPP"; then
1089 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1090 echo $ac_n "(cached) $ac_c" 1>&6
1091 else
1092 # This must be in double quotes, not single quotes, because CPP may get
1093 # substituted into the Makefile and "${CC-cc}" will confuse make.
1094 CPP="${CC-cc} -E"
1095 # On the NeXT, cc -E runs the code through the compiler's parser,
1096 # not just through cpp.
1097 cat > conftest.$ac_ext <<EOF
1098 #line 1099 "configure"
1099 #include "confdefs.h"
1100 #include <assert.h>
1101 Syntax Error
1102 EOF
1103 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1104 { (eval echo configure:1105: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1105 ac_err=`grep -v '^ *+' conftest.out`
1106 if test -z "$ac_err"; then
1107 :
1108 else
1109 echo "$ac_err" >&5
1110 rm -rf conftest*
1111 CPP="${CC-cc} -E -traditional-cpp"
1112 cat > conftest.$ac_ext <<EOF
1113 #line 1114 "configure"
1114 #include "confdefs.h"
1115 #include <assert.h>
1116 Syntax Error
1117 EOF
1118 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1119 { (eval echo configure:1120: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1120 ac_err=`grep -v '^ *+' conftest.out`
1121 if test -z "$ac_err"; then
1122 :
1123 else
1124 echo "$ac_err" >&5
1125 rm -rf conftest*
1126 CPP=/lib/cpp
1127 fi
1128 rm -f conftest*
1129 fi
1130 rm -f conftest*
1131 ac_cv_prog_CPP="$CPP"
1132 fi
1133 CPP="$ac_cv_prog_CPP"
1134 else
1135 ac_cv_prog_CPP="$CPP"
1136 fi
1137 echo "$ac_t""$CPP" 1>&6
1138
1139 for ac_hdr in stddef.h string.h strings.h stdlib.h time.h unistd.h
1140 do
1141 ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
1142 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1143 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1144 echo $ac_n "(cached) $ac_c" 1>&6
1145 else
1146 cat > conftest.$ac_ext <<EOF
1147 #line 1148 "configure"
1148 #include "confdefs.h"
1149 #include <$ac_hdr>
1150 EOF
1151 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1152 { (eval echo configure:1153: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1153 ac_err=`grep -v '^ *+' conftest.out`
1154 if test -z "$ac_err"; then
1155 rm -rf conftest*
1156 eval "ac_cv_header_$ac_safe=yes"
1157 else
1158 echo "$ac_err" >&5
1159 rm -rf conftest*
1160 eval "ac_cv_header_$ac_safe=no"
1161 fi
1162 rm -f conftest*
1163 fi
1164 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1165 echo "$ac_t""yes" 1>&6
1166 ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'`
1167 cat >> confdefs.h <<EOF
1168 #define $ac_tr_hdr 1
1169 EOF
1170
1171 else
1172 echo "$ac_t""no" 1>&6
1173 fi
1174 done
1175
1176 for ac_hdr in fcntl.h sys/file.h sys/time.h
1177 do
1178 ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
1179 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1180 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1181 echo $ac_n "(cached) $ac_c" 1>&6
1182 else
1183 cat > conftest.$ac_ext <<EOF
1184 #line 1185 "configure"
1185 #include "confdefs.h"
1186 #include <$ac_hdr>
1187 EOF
1188 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1189 { (eval echo configure:1190: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1190 ac_err=`grep -v '^ *+' conftest.out`
1191 if test -z "$ac_err"; then
1192 rm -rf conftest*
1193 eval "ac_cv_header_$ac_safe=yes"
1194 else
1195 echo "$ac_err" >&5
1196 rm -rf conftest*
1197 eval "ac_cv_header_$ac_safe=no"
1198 fi
1199 rm -f conftest*
1200 fi
1201 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1202 echo "$ac_t""yes" 1>&6
1203 ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'`
1204 cat >> confdefs.h <<EOF
1205 #define $ac_tr_hdr 1
1206 EOF
1207
1208 else
1209 echo "$ac_t""no" 1>&6
1210 fi
1211 done
1212
1213 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
1214 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
1215 echo $ac_n "(cached) $ac_c" 1>&6
1216 else
1217 cat > conftest.$ac_ext <<EOF
1218 #line 1219 "configure"
1219 #include "confdefs.h"
1220 #include <sys/types.h>
1221 #include <sys/time.h>
1222 #include <time.h>
1223 int main() { return 0; }
1224 int t() {
1225 struct tm *tp;
1226 ; return 0; }
1227 EOF
1228 if { (eval echo configure:1229: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1229 rm -rf conftest*
1230 ac_cv_header_time=yes
1231 else
1232 rm -rf conftest*
1233 ac_cv_header_time=no
1234 fi
1235 rm -f conftest*
1236
1237 fi
1238
1239 echo "$ac_t""$ac_cv_header_time" 1>&6
1240 if test $ac_cv_header_time = yes; then
1241 cat >> confdefs.h <<\EOF
1242 #define TIME_WITH_SYS_TIME 1
1243 EOF
1244
1245 fi
1246
1247 for ac_func in fcntl getpagesize
1248 do
1249 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1250 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1251 echo $ac_n "(cached) $ac_c" 1>&6
1252 else
1253 cat > conftest.$ac_ext <<EOF
1254 #line 1255 "configure"
1255 #include "confdefs.h"
1256 /* System header to define __stub macros and hopefully few prototypes,
1257 which can conflict with char $ac_func(); below. */
1258 #include <assert.h>
1259 /* Override any gcc2 internal prototype to avoid an error. */
1260 /* We use char because int might match the return type of a gcc2
1261 builtin and then its argument prototype would still apply. */
1262 char $ac_func();
1263
1264 int main() { return 0; }
1265 int t() {
1266
1267 /* The GNU C library defines this for functions which it implements
1268 to always fail with ENOSYS. Some functions are actually named
1269 something starting with __ and the normal name is an alias. */
1270 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1271 choke me
1272 #else
1273 $ac_func();
1274 #endif
1275
1276 ; return 0; }
1277 EOF
1278 if { (eval echo configure:1279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1279 rm -rf conftest*
1280 eval "ac_cv_func_$ac_func=yes"
1281 else
1282 rm -rf conftest*
1283 eval "ac_cv_func_$ac_func=no"
1284 fi
1285 rm -f conftest*
1286
1287 fi
1288 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1289 echo "$ac_t""yes" 1>&6
1290 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1291 cat >> confdefs.h <<EOF
1292 #define $ac_tr_func 1
1293 EOF
1294
1295 else
1296 echo "$ac_t""no" 1>&6
1297 fi
1298 done
1299
1300
1301
1302 case "${host}" in
1303 i[345]86-*-msdos* | i[345]86-*-go32* | *-*-cygwin32)
1304 cat >> confdefs.h <<\EOF
1305 #define USE_BINARY_FOPEN 1
1306 EOF
1307 ;;
1308 esac
1309
1310 echo $ac_n "checking whether malloc must be declared""... $ac_c" 1>&6
1311 if eval "test \"`echo '$''{'bfd_cv_decl_needed_malloc'+set}'`\" = set"; then
1312 echo $ac_n "(cached) $ac_c" 1>&6
1313 else
1314 cat > conftest.$ac_ext <<EOF
1315 #line 1316 "configure"
1316 #include "confdefs.h"
1317
1318 #include <stdio.h>
1319 #ifdef HAVE_STDLIB_H
1320 #include <stdlib.h>
1321 #endif
1322 #ifdef HAVE_UNISTD_H
1323 #include <unistd.h>
1324 #endif
1325 int main() { return 0; }
1326 int t() {
1327 char *(*pfn) = (char *(*)) malloc
1328 ; return 0; }
1329 EOF
1330 if { (eval echo configure:1331: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1331 rm -rf conftest*
1332 bfd_cv_decl_needed_malloc=no
1333 else
1334 rm -rf conftest*
1335 bfd_cv_decl_needed_malloc=yes
1336 fi
1337 rm -f conftest*
1338
1339 fi
1340
1341 echo "$ac_t""$bfd_cv_decl_needed_malloc" 1>&6
1342 if test $bfd_cv_decl_needed_malloc = yes; then
1343 bfd_tr_decl=NEED_DECLARATION_`echo malloc | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1344 cat >> confdefs.h <<EOF
1345 #define $bfd_tr_decl 1
1346 EOF
1347
1348 fi
1349
1350 echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6
1351 if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then
1352 echo $ac_n "(cached) $ac_c" 1>&6
1353 else
1354 cat > conftest.$ac_ext <<EOF
1355 #line 1356 "configure"
1356 #include "confdefs.h"
1357
1358 #include <stdio.h>
1359 #ifdef HAVE_STDLIB_H
1360 #include <stdlib.h>
1361 #endif
1362 #ifdef HAVE_UNISTD_H
1363 #include <unistd.h>
1364 #endif
1365 int main() { return 0; }
1366 int t() {
1367 char *(*pfn) = (char *(*)) free
1368 ; return 0; }
1369 EOF
1370 if { (eval echo configure:1371: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1371 rm -rf conftest*
1372 bfd_cv_decl_needed_free=no
1373 else
1374 rm -rf conftest*
1375 bfd_cv_decl_needed_free=yes
1376 fi
1377 rm -f conftest*
1378
1379 fi
1380
1381 echo "$ac_t""$bfd_cv_decl_needed_free" 1>&6
1382 if test $bfd_cv_decl_needed_free = yes; then
1383 bfd_tr_decl=NEED_DECLARATION_`echo free | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1384 cat >> confdefs.h <<EOF
1385 #define $bfd_tr_decl 1
1386 EOF
1387
1388 fi
1389
1390
1391 # If we are configured native, pick a core file support file.
1392 COREFILE=
1393 COREFLAG=
1394 if test "${target}" = "${host}"; then
1395 case "${host}" in
1396 alpha*-*-linux*)
1397 COREFILE=trad-core.o
1398 cat >> confdefs.h <<\EOF
1399 #define TRAD_HEADER "hosts/alphalinux.h"
1400 EOF
1401
1402 ;;
1403 alpha*-*-*) COREFILE=osf-core.o ;;
1404 arm-*-riscix) COREFILE=trad-core.o ;;
1405 hppa*-*-hpux*) COREFILE=hpux-core.o ;;
1406 hppa*-*-hiux*) COREFILE=hpux-core.o ;;
1407 hppa*-*-bsd*) COREFILE="hpux-core.o hppabsd-core.o"
1408 COREFLAG="-DHPUX_CORE -DHPPABSD_CORE" ;;
1409 i[345]86-sequent-bsd*)
1410 COREFILE=trad-core.o;
1411 cat >> confdefs.h <<\EOF
1412 #define TRAD_HEADER "hosts/symmetry.h"
1413 EOF
1414
1415 ;;
1416 i[345]86-sequent-sysv4*) ;;
1417 i[345]86-sequent-sysv*)
1418 COREFILE=trad-core.o
1419 cat >> confdefs.h <<\EOF
1420 #define TRAD_HEADER "hosts/symmetry.h"
1421 EOF
1422
1423 ;;
1424 i[345]86-*-bsd* | i[345]86-*-freebsd*)
1425 COREFILE=trad-core.o
1426 cat >> confdefs.h <<\EOF
1427 #define TRAD_HEADER "hosts/i386bsd.h"
1428 EOF
1429
1430 ;;
1431 i[345]86-*-netbsd*)
1432 COREFILE=netbsd-core.o
1433 ;;
1434 i[345]86-esix-sysv3*)
1435 COREFILE=trad-core.o
1436 cat >> confdefs.h <<\EOF
1437 #define TRAD_HEADER "hosts/esix.h"
1438 EOF
1439
1440 ;;
1441 i[345]86-*-sco* | i[345]86-*-isc*)
1442 COREFILE=trad-core.o
1443 cat >> confdefs.h <<\EOF
1444 #define TRAD_HEADER "hosts/i386sco.h"
1445 EOF
1446
1447 ;;
1448 i[345]86-*-mach3*)
1449 COREFILE=trad-core.o
1450 cat >> confdefs.h <<\EOF
1451 #define TRAD_HEADER "hosts/i386mach3.h"
1452 EOF
1453
1454 ;;
1455 i[345]86-*-linux*)
1456 COREFILE=trad-core.o
1457 cat >> confdefs.h <<\EOF
1458 #define TRAD_HEADER "hosts/i386linux.h"
1459 EOF
1460
1461 ;;
1462 i[345]86-*-isc*) COREFILE=trad-core.o ;;
1463 i[345]86-*-aix*) COREFILE=aix386-core.o ;;
1464 i860-*-mach3* | i860-*-osf1*)
1465 COREFILE=trad-core.o
1466 cat >> confdefs.h <<\EOF
1467 #define TRAD_HEADER "hosts/i860mach3.h"
1468 EOF
1469
1470 ;;
1471 mips-dec-bsd*)
1472 COREFILE=trad-core.o
1473 cat >> confdefs.h <<\EOF
1474 #define TRAD_HEADER "hosts/mipsbsd.h"
1475 EOF
1476
1477 ;;
1478 mips-dec-mach3*)
1479 COREFILE=trad-core.o
1480 cat >> confdefs.h <<\EOF
1481 #define TRAD_HEADER "hosts/mipsmach3.h"
1482 EOF
1483
1484 ;;
1485 mips-*-netbsd*)
1486 COREFILE=netbsd-core.o
1487 ;;
1488 mips-dec-*)
1489 COREFILE=trad-core.o
1490 cat >> confdefs.h <<\EOF
1491 #define TRAD_HEADER "hosts/decstation.h"
1492 EOF
1493
1494 ;;
1495 mips-sgi-irix4*) COREFILE=irix-core.o ;;
1496 mips-sgi-irix5*) COREFILE=irix-core.o ;;
1497 mips-*-mach3*)
1498 COREFILE=trad-core.o
1499 cat >> confdefs.h <<\EOF
1500 #define TRAD_HEADER "hosts/mipsmach3.h"
1501 EOF
1502
1503 ;;
1504 mips-*-sysv4*) ;;
1505 mips-*-sysv* | mips-*-riscos*)
1506 COREFILE=trad-core.o
1507 cat >> confdefs.h <<\EOF
1508 #define TRAD_HEADER "hosts/riscos.h"
1509 EOF
1510
1511 ;;
1512 mips-sony-bsd*)
1513 COREFILE=trad-core.o
1514 cat >> confdefs.h <<\EOF
1515 #define TRAD_HEADER "hosts/news-mips.h"
1516 EOF
1517
1518 ;;
1519 m68*-bull*-sysv*)
1520 COREFILE=trad-core.o
1521 cat >> confdefs.h <<\EOF
1522 #define TRAD_HEADER "hosts/dpx2.h"
1523 EOF
1524
1525 ;;
1526 m68*-hp-hpux*) COREFILE=hpux-core.o ;;
1527 m68*-hp-bsd*)
1528 COREFILE=trad-core.o
1529 cat >> confdefs.h <<\EOF
1530 #define TRAD_HEADER "hosts/hp300bsd.h"
1531 EOF
1532
1533 ;;
1534 m68*-*-linux*)
1535 COREFILE=trad-core.o
1536 cat >> confdefs.h <<\EOF
1537 #define TRAD_HEADER "hosts/m68klinux.h"
1538 EOF
1539
1540 ;;
1541 m68*-motorola-sysv*)
1542 COREFILE=trad-core.o
1543 cat >> confdefs.h <<\EOF
1544 #define TRAD_HEADER "hosts/delta68.h"
1545 EOF
1546
1547 ;;
1548 m68*-sony-*)
1549 COREFILE=trad-core.o
1550 cat >> confdefs.h <<\EOF
1551 #define TRAD_HEADER "hosts/news.h"
1552 EOF
1553
1554 ;;
1555 m68*-*-netbsd*)
1556 COREFILE=netbsd-core.o
1557 ;;
1558 m68*-apple-aux*)
1559 COREFILE=trad-core.o
1560 cat >> confdefs.h <<\EOF
1561 #define TRAD_HEADER "hosts/m68kaux.h"
1562 EOF
1563
1564 ;;
1565 m88*-*-sysv4*) ;;
1566 m88*-motorola-sysv*) COREFILE=ptrace-core.o ;;
1567 m88*-*-mach3*)
1568 COREFILE=trad-core.o
1569 cat >> confdefs.h <<\EOF
1570 #define TRAD_HEADER "hosts/m88kmach3.h"
1571 EOF
1572
1573 ;;
1574 ns32k-pc532-mach)
1575 COREFILE=trad-core.o
1576 cat >> confdefs.h <<\EOF
1577 #define TRAD_HEADER "hosts/pc532mach.h"
1578 EOF
1579
1580 ;;
1581 ns32k-*-netbsd*)
1582 COREFILE=netbsd-core.o
1583 ;;
1584 rs6000-*-lynx*) COREFILE=lynx-core.o ;;
1585 rs6000-*-aix4*) COREFILE=rs6000-core.o ;;
1586 rs6000-*-*) COREFILE=rs6000-core.o ;;
1587 powerpc-*-aix4*) COREFILE=rs6000-core.o ;;
1588 powerpc-*-aix*) COREFILE=rs6000-core.o ;;
1589 sparc-*-netbsd*)
1590 COREFILE=netbsd-core.o
1591 ;;
1592 tahoe-*-*)
1593 COREFILE=trad-core.o
1594 cat >> confdefs.h <<\EOF
1595 #define TRAD_HEADER "hosts/tahoe.h"
1596 EOF
1597
1598 ;;
1599 vax-*-ultrix2*)
1600 COREFILE=trad-core.o
1601 cat >> confdefs.h <<\EOF
1602 #define TRAD_HEADER "hosts/vaxult2.h"
1603 EOF
1604
1605 ;;
1606 vax-*-ultrix*)
1607 COREFILE=trad-core.o
1608 cat >> confdefs.h <<\EOF
1609 #define TRAD_HEADER "hosts/vaxult2.h"
1610 EOF
1611
1612 ;;
1613 vax-*-*)
1614 COREFILE=trad-core.o
1615 cat >> confdefs.h <<\EOF
1616 #define TRAD_HEADER "hosts/vaxbsd.h"
1617 EOF
1618
1619 ;;
1620 esac
1621
1622 case "$COREFILE" in
1623 aix386-core.o) COREFLAG=-DAIX386_CORE ;;
1624 hppabsd-core.o) COREFLAG=-DHPPABSD_CORE ;;
1625 hpux-core.o) COREFLAG=-DHPUX_CORE ;;
1626 irix-core.o) COREFLAG=-DIRIX_CORE ;;
1627 lynx-core.o) COREFLAG=-DLYNX_CORE ;;
1628 osf-core.o) COREFLAG=-DOSF_CORE ;;
1629 ptrace-core.o) COREFLAG=-DPTRACE_CORE ;;
1630 rs6000-core.o) COREFLAG="$COREFLAG -DAIX_CORE" ;;
1631 trad-core.o) COREFLAG="$COREFLAG -DTRAD_CORE" ;;
1632 esac
1633
1634 # The ELF code uses the native <sys/procfs.h> to handle core files.
1635 # Define HAVE_SYS_PROCFS_H if the file exists and defines
1636 # prstatus_t.
1637 echo $ac_n "checking for sys/procfs.h""... $ac_c" 1>&6
1638 if eval "test \"`echo '$''{'bfd_cv_header_sys_procfs_h'+set}'`\" = set"; then
1639 echo $ac_n "(cached) $ac_c" 1>&6
1640 else
1641 cat > conftest.$ac_ext <<EOF
1642 #line 1643 "configure"
1643 #include "confdefs.h"
1644 #include <sys/procfs.h>
1645 int main() { return 0; }
1646 int t() {
1647 prstatus_t t;
1648 ; return 0; }
1649 EOF
1650 if { (eval echo configure:1651: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1651 rm -rf conftest*
1652 bfd_cv_header_sys_procfs_h=yes
1653 else
1654 rm -rf conftest*
1655 bfd_cv_header_sys_procfs_h=no
1656 fi
1657 rm -f conftest*
1658
1659 fi
1660
1661 echo "$ac_t""$bfd_cv_header_sys_procfs_h" 1>&6
1662 if test $bfd_cv_header_sys_procfs_h = yes; then
1663 cat >> confdefs.h <<\EOF
1664 #define HAVE_SYS_PROCFS_H 1
1665 EOF
1666
1667 fi
1668
1669 fi
1670
1671
1672
1673 # target stuff:
1674
1675 # Canonicalize the secondary target names.
1676 if test -n "$enable_targets" ; then
1677 for targ in `echo $enable_targets | sed 's/,/ /g'`
1678 do
1679 result=`$ac_config_sub $targ 2>/dev/null`
1680 if test -n "$result" ; then
1681 canon_targets="$canon_targets $result"
1682 else
1683 # Allow targets that config.sub doesn't recognize, like "all".
1684 canon_targets="$canon_targets $targ"
1685 fi
1686 done
1687 fi
1688
1689 all_targets=false
1690 defvec=
1691 selvecs=
1692 selarchs=
1693 TDEFINES=
1694 for targ in $target $canon_targets
1695 do
1696 if test "x$targ" = "xall"; then
1697 all_targets=true
1698 else
1699 . $srcdir/config.bfd
1700 if test "x$targ" = "x$target"; then
1701 defvec=$targ_defvec
1702 fi
1703 selvecs="$selvecs $targ_defvec $targ_selvecs"
1704 selarchs="$selarchs $targ_archs"
1705 TDEFINES="$TDEFINES $targ_cflags"
1706 fi
1707 done
1708
1709
1710 # This processing still needs to be done if we're to decide properly whether
1711 # 64-bit support needs to be compiled in. Currently, it will be included if
1712 # the default or any other explicitly requested target requires it; it
1713 # will not be included on a 32-bit host if no 64-bit target is requested, and
1714 # no "--with-64-bit-bfd" option is given, even if "--with-targets=all" is
1715 # used.
1716
1717 # uniq the default and selected vectors in all the configured targets.
1718 f=""
1719 for i in $selvecs ; do
1720 case " $f " in
1721 *" $i "*) ;;
1722 *) f="$f $i" ;;
1723 esac
1724 done
1725 selvecs="$f"
1726
1727 # uniq the architectures in all the configured targets.
1728 f=""
1729 for i in $selarchs ; do
1730 case " $f " in
1731 *" $i "*) ;;
1732 *) f="$f $i" ;;
1733 esac
1734 done
1735 selarchs="$f"
1736
1737 # Target backend .o files.
1738 tb=
1739
1740 elf="elf.o elflink.o"
1741
1742 for vec in $selvecs
1743 do
1744 case "$vec" in
1745 # This list is alphabetized to make it easy to compare
1746 # with the two vector lists in targets.c.
1747 a29kcoff_big_vec) tb="$tb coff-a29k.o cofflink.o" ;;
1748 a_out_adobe_vec) tb="$tb aout-adobe.o aout32.o" ;;
1749 armcoff_little_vec) tb="$tb coff-arm.o cofflink.o " ;;
1750 armcoff_big_vec) tb="$tb coff-arm.o cofflink.o " ;;
1751 armpe_little_vec) tb="$tb pe-arm.o cofflink.o " ;;
1752 armpe_big_vec) tb="$tb pe-arm.o cofflink.o " ;;
1753 armpei_little_vec) tb="$tb pei-arm.o cofflink.o " ;;
1754 armpei_big_vec) tb="$tb pei-arm.o cofflink.o " ;;
1755 aout0_big_vec) tb="$tb aout0.o aout32.o" ;;
1756 aout_arm_big_vec) tb="$tb aout-arm.o aout32.o" ;;
1757 aout_arm_little_vec) tb="$tb aout-arm.o aout32.o" ;;
1758 aout_mips_big_vec) tb="$tb mipsbsd.o aout32.o" ;;
1759 aout_mips_little_vec) tb="$tb mipsbsd.o aout32.o" ;;
1760 apollocoff_vec) tb="$tb coff-apollo.o" ;;
1761 b_out_vec_big_host) tb="$tb bout.o aout32.o" ;;
1762 b_out_vec_little_host) tb="$tb bout.o aout32.o" ;;
1763 # start-sanitize-arc
1764 bfd_elf32_littlearc_vec) tb="$tb elf32-arc.o elf32.o $elf" ;;
1765 bfd_elf32_bigarc_vec) tb="$tb elf32-arc.o elf32.o $elf" ;;
1766 # end-sanitize-arc
1767 bfd_elf32_big_generic_vec) tb="$tb elf32-gen.o elf32.o $elf" ;;
1768 bfd_elf32_bigmips_vec) tb="$tb elf32-mips.o elf32.o $elf ecofflink.o" ;;
1769 bfd_elf64_bigmips_vec) tb="$tb elf64-mips.o elf64.o elf32-mips.o elf32.o $elf ecofflink.o"
1770 target64=true ;;
1771 bfd_elf32_hppa_vec) tb="$tb elf32-hppa.o elf32.o $elf" ;;
1772 bfd_elf32_i386_vec) tb="$tb elf32-i386.o elf32.o $elf" ;;
1773 bfd_elf32_i860_vec) tb="$tb elf32-i860.o elf32.o $elf" ;;
1774 bfd_elf32_little_generic_vec) tb="$tb elf32-gen.o elf32.o $elf" ;;
1775 bfd_elf32_littlemips_vec) tb="$tb elf32-mips.o elf32.o $elf ecofflink.o" ;;
1776 bfd_elf64_littlemips_vec) tb="$tb elf64-mips.o elf64.o elf32-mips.o elf32.o $elf ecofflink.o"
1777 target64=true ;;
1778 bfd_elf32_m68k_vec) tb="$tb elf32-m68k.o elf32.o $elf" ;;
1779 bfd_elf32_m88k_vec) tb="$tb elf32-m88k.o elf32.o $elf" ;;
1780 bfd_elf32_powerpc_vec) tb="$tb elf32-ppc.o elf32.o $elf" ;;
1781 bfd_elf32_powerpcle_vec) tb="$tb elf32-ppc.o elf32.o $elf" ;;
1782 bfd_elf32_sparc_vec) tb="$tb elf32-sparc.o elf32.o $elf" ;;
1783 bfd_elf64_big_generic_vec) tb="$tb elf64-gen.o elf64.o $elf"
1784 target64=true ;;
1785 bfd_elf64_little_generic_vec) tb="$tb elf64-gen.o elf64.o $elf"
1786 target64=true ;;
1787 bfd_elf64_sparc_vec) tb="$tb elf64-sparc.o elf64.o $elf"
1788 target64=true ;;
1789 cisco_core_vec) tb="$tb cisco-core.o" ;;
1790 demo_64_vec) tb="$tb demo64.o aout64.o"
1791 target64=true ;;
1792 ecoff_big_vec) tb="$tb coff-mips.o ecoff.o ecofflink.o" ;;
1793 ecoff_little_vec) tb="$tb coff-mips.o ecoff.o ecofflink.o" ;;
1794 ecoffalpha_little_vec) tb="$tb coff-alpha.o ecoff.o ecofflink.o"
1795 target64=true ;;
1796 h8300coff_vec) tb="$tb coff-h8300.o reloc16.o" ;;
1797 h8500coff_vec) tb="$tb coff-h8500.o reloc16.o" ;;
1798 host_aout_vec) tb="$tb host-aout.o aout32.o" ;;
1799 hp300bsd_vec) tb="$tb hp300bsd.o aout32.o" ;;
1800 hp300hpux_vec) tb="$tb hp300hpux.o aout32.o" ;;
1801 i386aout_vec) tb="$tb i386aout.o aout32.o" ;;
1802 i386bsd_vec) tb="$tb i386bsd.o aout32.o" ;;
1803 i386coff_vec) tb="$tb coff-i386.o cofflink.o" ;;
1804 i386dynix_vec) tb="$tb i386dynix.o aout32.o" ;;
1805 i386freebsd_vec) tb="$tb i386freebsd.o aout32.o" ;;
1806 i386msdos_vec) tb="$tb i386msdos.o" ;;
1807 i386pe_vec) tb="$tb pe-i386.o cofflink.o " ;;
1808 i386pei_vec) tb="$tb pei-i386.o cofflink.o" ;;
1809 i386linux_vec) tb="$tb i386linux.o aout32.o" ;;
1810 i386lynx_aout_vec) tb="$tb i386lynx.o lynx-core.o aout32.o" ;;
1811 i386lynx_coff_vec) tb="$tb cf-i386lynx.o cofflink.o lynx-core.o" ;;
1812 i386mach3_vec) tb="$tb i386mach3.o aout32.o" ;;
1813 i386netbsd_vec) tb="$tb i386netbsd.o aout32.o" ;;
1814 i386os9k_vec) tb="$tb i386os9k.o aout32.o" ;;
1815 i860coff_vec) tb="$tb coff-i860.o cofflink.o" ;;
1816 icoff_big_vec) tb="$tb coff-i960.o cofflink.o" ;;
1817 icoff_little_vec) tb="$tb coff-i960.o cofflink.o" ;;
1818 ieee_vec) tb="$tb ieee.o" ;;
1819 m68kcoff_vec) tb="$tb coff-m68k.o cofflink.o" ;;
1820 m68kcoffun_vec) tb="$tb coff-u68k.o coff-m68k.o cofflink.o" ;;
1821 m68klinux_vec) tb="$tb m68klinux.o aout32.o" ;;
1822 m68klynx_aout_vec) tb="$tb m68klynx.o lynx-core.o aout32.o" ;;
1823 m68klynx_coff_vec) tb="$tb cf-m68klynx.o coff-m68k.o cofflink.o lynx-core.o" ;;
1824 m68knetbsd_vec) tb="$tb m68knetbsd.o aout32.o" ;;
1825 m68k4knetbsd_vec) tb="$tb m68k4knetbsd.o aout32.o" ;;
1826 m68kaux_coff_vec) tb="$tb coff-aux.o coff-m68k.o cofflink.o" ;;
1827 m88kbcs_vec) tb="$tb coff-m88k.o" ;;
1828 newsos3_vec) tb="$tb newsos3.o aout32.o" ;;
1829 nlm32_i386_vec) tb="$tb nlm32-i386.o nlm32.o nlm.o" ;;
1830 nlm32_sparc_vec) tb="$tb nlm32-sparc.o nlm32.o nlm.o" ;;
1831 nlm32_alpha_vec) tb="$tb nlm32-alpha.o nlm32.o nlm.o"
1832 target64=true ;;
1833 riscix_vec) tb="$tb aout32.o riscix.o" ;;
1834 nlm32_powerpc_vec) tb="$tb nlm32-ppc.o nlm32.o nlm.o" ;;
1835 pc532netbsd_vec) tb="$tb ns32knetbsd.o aout-ns32k.o" ;;
1836 pc532machaout_vec) tb="$tb pc532-mach.o aout-ns32k.o" ;;
1837 pmac_xcoff_vec) tb="$tb coff-pmac.o xcofflink.o" ;;
1838 rs6000coff_vec) tb="$tb coff-rs6000.o xcofflink.o" ;;
1839 bfd_powerpc_pe_vec) tb="$tb pe-ppc.o cofflink.o" ;;
1840 bfd_powerpcle_pe_vec) tb="$tb pe-ppc.o cofflink.o" ;;
1841 bfd_powerpc_pei_vec) tb="$tb pei-ppc.o cofflink.o" ;;
1842 bfd_powerpcle_pei_vec) tb="$tb pei-ppc.o cofflink.o" ;;
1843 ppcboot_vec) tb="$tb ppcboot.o" ;;
1844 shcoff_vec) tb="$tb coff-sh.o cofflink.o" ;;
1845 # start-sanitize-rce
1846 rce_aout_vec) tb="$tb aout-rce.o aout32.o" ;;
1847 # end-sanitize-rce
1848 shlcoff_vec) tb="$tb coff-sh.o cofflink.o" ;;
1849 som_vec) tb="$tb som.o" ;;
1850 sparclynx_aout_vec) tb="$tb sparclynx.o lynx-core.o aout32.o" ;;
1851 sparclynx_coff_vec) tb="$tb cf-sparclynx.o lynx-core.o" ;;
1852 sparcnetbsd_vec) tb="$tb sparcnetbsd.o aout32.o" ;;
1853 sparccoff_vec) tb="$tb coff-sparc.o" ;;
1854 srec_vec) tb="$tb srec.o" ;;
1855 sunos_big_vec) tb="$tb sunos.o aout32.o" ;;
1856 symbolsrec_vec) tb="$tb srec.o" ;;
1857 tekhex_vec) tb="$tb tekhex.o" ;;
1858 we32kcoff_vec) tb="$tb coff-we32k.o" ;;
1859 z8kcoff_vec) tb="$tb coff-z8k.o reloc16.o" ;;
1860 w65_vec) tb="$tb coff-w65.o reloc16.o" ;;
1861 versados_vec) tb="$tb versados.o" ;;
1862
1863 "") ;;
1864 *) { echo "configure: error: *** unknown target vector $vec" 1>&2; exit 1; } ;;
1865 esac
1866 done
1867
1868 # Target architecture .o files.
1869 ta=`echo $selarchs | sed -e s/bfd_/cpu-/g -e s/_arch/.o/g`
1870
1871 # Weed out duplicate .o files.
1872 f=""
1873 for i in $tb ; do
1874 case " $f " in
1875 *" $i "*) ;;
1876 *) f="$f $i" ;;
1877 esac
1878 done
1879 tb="$f"
1880
1881 f=""
1882 for i in $ta ; do
1883 case " $f " in
1884 *" $i "*) ;;
1885 *) f="$f $i" ;;
1886 esac
1887 done
1888 ta="$f"
1889
1890 bfd_backends="$tb"
1891 bfd_machines="$ta"
1892
1893 if test x${all_targets} = xtrue ; then
1894 bfd_backends="${bfd_backends}"' $(ALL_BACKENDS)'
1895 bfd_machines="${bfd_machines}"' $(ALL_MACHINES)'
1896 selvecs=
1897 selarchs=
1898 else # all_targets is true
1899 # Only set these if they will be nonempty, for the clever echo.
1900 test -n "$selvecs" &&
1901 selvecs=`echo $selvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
1902 test -n "$selarchs" &&
1903 selarchs=`echo $selarchs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
1904 fi # all_targets is true
1905
1906 case ${host64}-${target64}-${want64} in
1907 *true*)
1908 wordsize=64
1909 all_backends='$(BFD64_BACKENDS) $(BFD32_BACKENDS)'
1910 ;;
1911 false-false-false)
1912 wordsize=32
1913 all_backends='$(BFD32_BACKENDS)'
1914 ;;
1915 esac
1916
1917
1918
1919
1920
1921
1922 tdefaults=""
1923 test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}"
1924 test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'"
1925 test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'"
1926
1927
1928 for ac_func in valloc getpagesize
1929 do
1930 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1931 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1932 echo $ac_n "(cached) $ac_c" 1>&6
1933 else
1934 cat > conftest.$ac_ext <<EOF
1935 #line 1936 "configure"
1936 #include "confdefs.h"
1937 /* System header to define __stub macros and hopefully few prototypes,
1938 which can conflict with char $ac_func(); below. */
1939 #include <assert.h>
1940 /* Override any gcc2 internal prototype to avoid an error. */
1941 /* We use char because int might match the return type of a gcc2
1942 builtin and then its argument prototype would still apply. */
1943 char $ac_func();
1944
1945 int main() { return 0; }
1946 int t() {
1947
1948 /* The GNU C library defines this for functions which it implements
1949 to always fail with ENOSYS. Some functions are actually named
1950 something starting with __ and the normal name is an alias. */
1951 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1952 choke me
1953 #else
1954 $ac_func();
1955 #endif
1956
1957 ; return 0; }
1958 EOF
1959 if { (eval echo configure:1960: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
1960 rm -rf conftest*
1961 eval "ac_cv_func_$ac_func=yes"
1962 else
1963 rm -rf conftest*
1964 eval "ac_cv_func_$ac_func=no"
1965 fi
1966 rm -f conftest*
1967
1968 fi
1969 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1970 echo "$ac_t""yes" 1>&6
1971 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1972 cat >> confdefs.h <<EOF
1973 #define $ac_tr_func 1
1974 EOF
1975
1976 else
1977 echo "$ac_t""no" 1>&6
1978 fi
1979 done
1980
1981 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
1982 if eval "test \"`echo '$''{'ac_cv_func_mmap'+set}'`\" = set"; then
1983 echo $ac_n "(cached) $ac_c" 1>&6
1984 else
1985 if test "$cross_compiling" = yes; then
1986 ac_cv_func_mmap=no
1987 else
1988 cat > conftest.$ac_ext <<EOF
1989 #line 1990 "configure"
1990 #include "confdefs.h"
1991
1992 /* Thanks to Mike Haertel and Jim Avera for this test. */
1993 #include <sys/types.h>
1994 #include <fcntl.h>
1995 #include <sys/mman.h>
1996
1997 #ifndef HAVE_GETPAGESIZE
1998 # include <sys/param.h>
1999 # ifdef EXEC_PAGESIZE
2000 # define getpagesize() EXEC_PAGESIZE
2001 # else
2002 # ifdef NBPG
2003 # define getpagesize() NBPG * CLSIZE
2004 # ifndef CLSIZE
2005 # define CLSIZE 1
2006 # endif
2007 # else
2008 # ifdef NBPC
2009 # define getpagesize() NBPC
2010 # else
2011 # define getpagesize() PAGESIZE /* SVR4 */
2012 # endif
2013 # endif
2014 # endif
2015 #endif
2016
2017 #ifndef HAVE_VALLOC
2018 # define valloc malloc
2019 #endif
2020
2021 #ifdef __cplusplus
2022 extern "C" { void *valloc(unsigned), *malloc(unsigned); }
2023 #else
2024 char *valloc(), *malloc();
2025 #endif
2026
2027 int
2028 main()
2029 {
2030 char *buf1, *buf2, *buf3;
2031 int i = getpagesize(), j;
2032 int i2 = i * 2;
2033 int fd;
2034
2035 buf1 = (char *)valloc(i2);
2036 buf2 = (char *)valloc(i);
2037 buf3 = (char *)malloc(i2);
2038 for (j = 0; j < i2; ++j)
2039 *(buf1 + j) = rand();
2040 fd = open("conftestmmap", O_CREAT | O_RDWR, 0666);
2041 write(fd, buf1, i2);
2042 mmap(buf2, i, PROT_READ | PROT_WRITE, MAP_FIXED | MAP_PRIVATE, fd, 0);
2043 for (j = 0; j < i; ++j)
2044 if (*(buf1 + j) != *(buf2 + j))
2045 exit(1);
2046 lseek(fd, (long)i, 0);
2047 read(fd, buf2, i); /* read into mapped memory -- file should not change */
2048 /* (it does in i386 SVR4.0 - Jim Avera, jima@netcom.com) */
2049 lseek(fd, (long)0, 0);
2050 read(fd, buf3, i2);
2051 for (j = 0; j < i2; ++j)
2052 if (*(buf1 + j) != *(buf3 + j))
2053 exit(1);
2054 exit(0);
2055 }
2056
2057 EOF
2058 { (eval echo configure:2059: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }
2059 if test -s conftest && (./conftest; exit) 2>/dev/null; then
2060 ac_cv_func_mmap=yes
2061 else
2062 ac_cv_func_mmap=no
2063 fi
2064 fi
2065 rm -fr conftest*
2066 fi
2067
2068 echo "$ac_t""$ac_cv_func_mmap" 1>&6
2069 if test $ac_cv_func_mmap = yes; then
2070 cat >> confdefs.h <<\EOF
2071 #define HAVE_MMAP 1
2072 EOF
2073
2074 fi
2075
2076 for ac_func in madvise mprotect
2077 do
2078 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2079 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2080 echo $ac_n "(cached) $ac_c" 1>&6
2081 else
2082 cat > conftest.$ac_ext <<EOF
2083 #line 2084 "configure"
2084 #include "confdefs.h"
2085 /* System header to define __stub macros and hopefully few prototypes,
2086 which can conflict with char $ac_func(); below. */
2087 #include <assert.h>
2088 /* Override any gcc2 internal prototype to avoid an error. */
2089 /* We use char because int might match the return type of a gcc2
2090 builtin and then its argument prototype would still apply. */
2091 char $ac_func();
2092
2093 int main() { return 0; }
2094 int t() {
2095
2096 /* The GNU C library defines this for functions which it implements
2097 to always fail with ENOSYS. Some functions are actually named
2098 something starting with __ and the normal name is an alias. */
2099 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2100 choke me
2101 #else
2102 $ac_func();
2103 #endif
2104
2105 ; return 0; }
2106 EOF
2107 if { (eval echo configure:2108: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
2108 rm -rf conftest*
2109 eval "ac_cv_func_$ac_func=yes"
2110 else
2111 rm -rf conftest*
2112 eval "ac_cv_func_$ac_func=no"
2113 fi
2114 rm -f conftest*
2115
2116 fi
2117 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2118 echo "$ac_t""yes" 1>&6
2119 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2120 cat >> confdefs.h <<EOF
2121 #define $ac_tr_func 1
2122 EOF
2123
2124 else
2125 echo "$ac_t""no" 1>&6
2126 fi
2127 done
2128
2129 case ${want_mmap}+${ac_cv_func_mmap} in
2130 true+yes ) cat >> confdefs.h <<\EOF
2131 #define USE_MMAP 1
2132 EOF
2133 ;;
2134 esac
2135
2136 rm -f doc/config.status
2137 trap '' 1 2 15
2138 cat > confcache <<\EOF
2139 # This file is a shell script that caches the results of configure
2140 # tests run on this system so they can be shared between configure
2141 # scripts and configure runs. It is not useful on other systems.
2142 # If it contains results you don't want to keep, you may remove or edit it.
2143 #
2144 # By default, configure uses ./config.cache as the cache file,
2145 # creating it if it does not exist already. You can give configure
2146 # the --cache-file=FILE option to use a different cache file; that is
2147 # what configure does when it calls configure scripts in
2148 # subdirectories, so they share the cache.
2149 # Giving --cache-file=/dev/null disables caching, for debugging configure.
2150 # config.status only pays attention to the cache file if you give it the
2151 # --recheck option to rerun configure.
2152 #
2153 EOF
2154 # Ultrix sh set writes to stderr and can't be redirected directly,
2155 # and sets the high bit in the cache file unless we assign to the vars.
2156 (set) 2>&1 |
2157 sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \
2158 >> confcache
2159 if cmp -s $cache_file confcache; then
2160 :
2161 else
2162 if test -w $cache_file; then
2163 echo "updating cache $cache_file"
2164 cat confcache > $cache_file
2165 else
2166 echo "not updating unwritable cache $cache_file"
2167 fi
2168 fi
2169 rm -f confcache
2170
2171 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2172
2173 test "x$prefix" = xNONE && prefix=$ac_default_prefix
2174 # Let make expand exec_prefix.
2175 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2176
2177 # Any assignment to VPATH causes Sun make to only execute
2178 # the first set of double-colon rules, so remove it if not needed.
2179 # If there is a colon in the path, we need to keep it.
2180 if test "x$srcdir" = x.; then
2181 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
2182 fi
2183
2184 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2185
2186 DEFS=-DHAVE_CONFIG_H
2187
2188 # Without the "./", some shells look in PATH for config.status.
2189 : ${CONFIG_STATUS=./config.status}
2190
2191 echo creating $CONFIG_STATUS
2192 rm -f $CONFIG_STATUS
2193 cat > $CONFIG_STATUS <<EOF
2194 #! /bin/sh
2195 # Generated automatically by configure.
2196 # Run this file to recreate the current configuration.
2197 # This directory was configured as follows,
2198 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2199 #
2200 # $0 $ac_configure_args
2201 #
2202 # Compiler output produced by configure, useful for debugging
2203 # configure, is in ./config.log if it exists.
2204
2205 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2206 for ac_option
2207 do
2208 case "\$ac_option" in
2209 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2210 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2211 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2212 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2213 echo "$CONFIG_STATUS generated by autoconf version 2.10"
2214 exit 0 ;;
2215 -help | --help | --hel | --he | --h)
2216 echo "\$ac_cs_usage"; exit 0 ;;
2217 *) echo "\$ac_cs_usage"; exit 1 ;;
2218 esac
2219 done
2220
2221 ac_given_srcdir=$srcdir
2222 ac_given_INSTALL="$INSTALL"
2223
2224 trap 'rm -fr `echo "Makefile doc/Makefile config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2225 EOF
2226 cat >> $CONFIG_STATUS <<EOF
2227
2228 # Protect against being on the right side of a sed subst in config.status.
2229 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2230 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2231 $ac_vpsub
2232 $extrasub
2233 s%@CFLAGS@%$CFLAGS%g
2234 s%@CPPFLAGS@%$CPPFLAGS%g
2235 s%@CXXFLAGS@%$CXXFLAGS%g
2236 s%@DEFS@%$DEFS%g
2237 s%@LDFLAGS@%$LDFLAGS%g
2238 s%@LIBS@%$LIBS%g
2239 s%@exec_prefix@%$exec_prefix%g
2240 s%@prefix@%$prefix%g
2241 s%@program_transform_name@%$program_transform_name%g
2242 s%@bindir@%$bindir%g
2243 s%@sbindir@%$sbindir%g
2244 s%@libexecdir@%$libexecdir%g
2245 s%@datadir@%$datadir%g
2246 s%@sysconfdir@%$sysconfdir%g
2247 s%@sharedstatedir@%$sharedstatedir%g
2248 s%@localstatedir@%$localstatedir%g
2249 s%@libdir@%$libdir%g
2250 s%@includedir@%$includedir%g
2251 s%@oldincludedir@%$oldincludedir%g
2252 s%@infodir@%$infodir%g
2253 s%@mandir@%$mandir%g
2254 s%@host@%$host%g
2255 s%@host_alias@%$host_alias%g
2256 s%@host_cpu@%$host_cpu%g
2257 s%@host_vendor@%$host_vendor%g
2258 s%@host_os@%$host_os%g
2259 s%@target@%$target%g
2260 s%@target_alias@%$target_alias%g
2261 s%@target_cpu@%$target_cpu%g
2262 s%@target_vendor@%$target_vendor%g
2263 s%@target_os@%$target_os%g
2264 s%@build@%$build%g
2265 s%@build_alias@%$build_alias%g
2266 s%@build_cpu@%$build_cpu%g
2267 s%@build_vendor@%$build_vendor%g
2268 s%@build_os@%$build_os%g
2269 s%@CC@%$CC%g
2270 s%@HDEFINES@%$HDEFINES%g
2271 s%@AR@%$AR%g
2272 s%@RANLIB@%$RANLIB%g
2273 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
2274 s%@INSTALL_DATA@%$INSTALL_DATA%g
2275 s%@ALLLIBS@%$ALLLIBS%g
2276 s%@PICFLAG@%$PICFLAG%g
2277 s%@SHLIB@%$SHLIB%g
2278 s%@SHLIB_CC@%$SHLIB_CC%g
2279 s%@SHLIB_CFLAGS@%$SHLIB_CFLAGS%g
2280 s%@COMMON_SHLIB@%$COMMON_SHLIB%g
2281 s%@PICLIST@%$PICLIST%g
2282 s%@SHLINK@%$SHLINK%g
2283 s%@HOST_64BIT_LONG@%$HOST_64BIT_LONG%g
2284 s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
2285 s%@CPP@%$CPP%g
2286 s%@COREFILE@%$COREFILE%g
2287 s%@COREFLAG@%$COREFLAG%g
2288 s%@TDEFINES@%$TDEFINES%g
2289 s%@wordsize@%$wordsize%g
2290 s%@all_backends@%$all_backends%g
2291 s%@bfd_backends@%$bfd_backends%g
2292 s%@bfd_machines@%$bfd_machines%g
2293 s%@tdefaults@%$tdefaults%g
2294
2295 CEOF
2296 EOF
2297 cat >> $CONFIG_STATUS <<EOF
2298
2299 CONFIG_FILES=\${CONFIG_FILES-"Makefile doc/Makefile"}
2300 EOF
2301 cat >> $CONFIG_STATUS <<\EOF
2302 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2303 # Support "outfile[:infile]", defaulting infile="outfile.in".
2304 case "$ac_file" in
2305 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
2306 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2307 *) ac_file_in="${ac_file}.in" ;;
2308 esac
2309
2310 # Adjust relative srcdir, etc. for subdirectories.
2311
2312 # Remove last slash and all that follows it. Not all systems have dirname.
2313 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2314 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2315 # The file is in a subdirectory.
2316 test ! -d "$ac_dir" && mkdir "$ac_dir"
2317 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2318 # A "../" for each directory in $ac_dir_suffix.
2319 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2320 else
2321 ac_dir_suffix= ac_dots=
2322 fi
2323
2324 case "$ac_given_srcdir" in
2325 .) srcdir=.
2326 if test -z "$ac_dots"; then top_srcdir=.
2327 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2328 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2329 *) # Relative path.
2330 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2331 top_srcdir="$ac_dots$ac_given_srcdir" ;;
2332 esac
2333
2334 case "$ac_given_INSTALL" in
2335 [/$]*) INSTALL="$ac_given_INSTALL" ;;
2336 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2337 esac
2338 echo creating "$ac_file"
2339 rm -f "$ac_file"
2340 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2341 case "$ac_file" in
2342 *Makefile*) ac_comsub="1i\\
2343 # $configure_input" ;;
2344 *) ac_comsub= ;;
2345 esac
2346 sed -e "$ac_comsub
2347 s%@configure_input@%$configure_input%g
2348 s%@srcdir@%$srcdir%g
2349 s%@top_srcdir@%$top_srcdir%g
2350 s%@INSTALL@%$INSTALL%g
2351 " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
2352 fi; done
2353 rm -f conftest.subs
2354
2355 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
2356 # NAME is the cpp macro being defined and VALUE is the value it is being given.
2357 #
2358 # ac_d sets the value in "#define NAME VALUE" lines.
2359 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
2360 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
2361 ac_dC='\3'
2362 ac_dD='%g'
2363 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
2364 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
2365 ac_uB='\([ ]\)%\1#\2define\3'
2366 ac_uC=' '
2367 ac_uD='\4%g'
2368 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
2369 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
2370 ac_eB='$%\1#\2define\3'
2371 ac_eC=' '
2372 ac_eD='%g'
2373
2374 CONFIG_HEADERS=${CONFIG_HEADERS-"config.h:config.in"}
2375 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
2376 # Support "outfile[:infile]", defaulting infile="outfile.in".
2377 case "$ac_file" in
2378 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
2379 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2380 *) ac_file_in="${ac_file}.in" ;;
2381 esac
2382
2383 echo creating $ac_file
2384
2385 rm -f conftest.frag conftest.in conftest.out
2386 cp $ac_given_srcdir/$ac_file_in conftest.in
2387
2388 EOF
2389
2390 # Transform confdefs.h into a sed script conftest.vals that substitutes
2391 # the proper values into config.h.in to produce config.h. And first:
2392 # Protect against being on the right side of a sed subst in config.status.
2393 # Protect against being in an unquoted here document in config.status.
2394 rm -f conftest.vals
2395 cat > conftest.hdr <<\EOF
2396 s/[\\&%]/\\&/g
2397 s%[\\$`]%\\&%g
2398 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
2399 s%ac_d%ac_u%gp
2400 s%ac_u%ac_e%gp
2401 EOF
2402 sed -n -f conftest.hdr confdefs.h > conftest.vals
2403 rm -f conftest.hdr
2404
2405 # This sed command replaces #undef with comments. This is necessary, for
2406 # example, in the case of _POSIX_SOURCE, which is predefined and required
2407 # on some systems where configure will not decide to define it.
2408 cat >> conftest.vals <<\EOF
2409 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
2410 EOF
2411
2412 # Break up conftest.vals because some shells have a limit on
2413 # the size of here documents, and old seds have small limits too.
2414 # Maximum number of lines to put in a single here document.
2415 ac_max_here_lines=12
2416
2417 rm -f conftest.tail
2418 while :
2419 do
2420 ac_lines=`grep -c . conftest.vals`
2421 # grep -c gives empty output for an empty file on some AIX systems.
2422 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
2423 # Write a limited-size here document to conftest.frag.
2424 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
2425 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
2426 echo 'CEOF
2427 sed -f conftest.frag conftest.in > conftest.out
2428 rm -f conftest.in
2429 mv conftest.out conftest.in
2430 ' >> $CONFIG_STATUS
2431 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
2432 rm -f conftest.vals
2433 mv conftest.tail conftest.vals
2434 done
2435 rm -f conftest.vals
2436
2437 cat >> $CONFIG_STATUS <<\EOF
2438 rm -f conftest.frag conftest.h
2439 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
2440 cat conftest.in >> conftest.h
2441 rm -f conftest.in
2442 if cmp -s $ac_file conftest.h 2>/dev/null; then
2443 echo "$ac_file is unchanged"
2444 rm -f conftest.h
2445 else
2446 # Remove last slash and all that follows it. Not all systems have dirname.
2447 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2448 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2449 # The file is in a subdirectory.
2450 test ! -d "$ac_dir" && mkdir "$ac_dir"
2451 fi
2452 rm -f $ac_file
2453 mv conftest.h $ac_file
2454 fi
2455 fi; done
2456
2457
2458 case x$CONFIG_HEADERS in xconfig.h:config.in) echo > stamp-h ;; esac
2459 exit 0
2460 EOF
2461 chmod +x $CONFIG_STATUS
2462 rm -fr confdefs* $ac_clean_files
2463 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2464
This page took 0.093047 seconds and 4 git commands to generate.