add comment
[deliverable/binutils-gdb.git] / bfd / configure
CommitLineData
8c693660
KR
1#! /bin/sh
2
3# Guess values for system-dependent variables and create Makefiles.
4# Generated automatically using autoconf version 2.4
5# Copyright (C) 1992, 1993, 1994 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:
11ac_help=
12ac_default_prefix=/usr/local
13# Any additions from configure.in:
14ac_help="$ac_help
e818c22e 15 --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)"
8c693660 16ac_help="$ac_help
e818c22e 17 --enable-targets alternative target configurations"
8c693660
KR
18
19# Initialize some variables set by options.
20# The variables have the same names as the options, with
21# dashes changed to underlines.
22build=NONE
23cache_file=./config.cache
24exec_prefix=NONE
25host=NONE
26no_create=
27nonopt=NONE
28no_recursion=
29prefix=NONE
30program_prefix=NONE
31program_suffix=NONE
32program_transform_name=s,x,x,
33silent=
34site=
35srcdir=
36target=NONE
37verbose=
38x_includes=NONE
39x_libraries=NONE
40
41# Initialize some other variables.
42subdirs=
43
44ac_prev=
45for ac_option
46do
47
48 # If the previous option needs an argument, assign it.
49 if test -n "$ac_prev"; then
50 eval "$ac_prev=\$ac_option"
51 ac_prev=
52 continue
53 fi
54
55 case "$ac_option" in
56 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
57 *) ac_optarg= ;;
58 esac
59
60 # Accept the important Cygnus configure options, so we can diagnose typos.
61
62 case "$ac_option" in
63
64 -build | --build | --buil | --bui | --bu | --b)
65 ac_prev=build ;;
66 -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
67 build="$ac_optarg" ;;
68
69 -cache-file | --cache-file | --cache-fil | --cache-fi \
70 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
71 ac_prev=cache_file ;;
72 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
73 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
74 cache_file="$ac_optarg" ;;
75
76 -disable-* | --disable-*)
77 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
78 # Reject names that are not valid shell variable names.
79 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
80 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
81 fi
82 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
83 eval "enable_${ac_feature}=no" ;;
84
85 -enable-* | --enable-*)
86 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
87 # Reject names that are not valid shell variable names.
88 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
89 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
90 fi
91 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
92 case "$ac_option" in
93 *=*) ;;
94 *) ac_optarg=yes ;;
95 esac
96 eval "enable_${ac_feature}='$ac_optarg'" ;;
97
98 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
99 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
100 | --exec | --exe | --ex)
101 ac_prev=exec_prefix ;;
102 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
103 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
104 | --exec=* | --exe=* | --ex=*)
105 exec_prefix="$ac_optarg" ;;
106
107 -gas | --gas | --ga | --g)
108 # Obsolete; use --with-gas.
109 with_gas=yes ;;
110
111 -help | --help | --hel | --he)
112 # Omit some internal or obsolete options to make the list less imposing.
113 # This message is too long to be a string in the A/UX 3.1 sh.
114 cat << EOF
115Usage: configure [options] [host]
116Options: [defaults in brackets after descriptions]
117Configuration:
118 --cache-file=FILE cache test results in FILE
119 --help print this message
120 --no-create do not create output files
121 --quiet, --silent do not print \`checking...' messages
122 --version print the version of autoconf that created configure
123Directory and file names:
124 --prefix=PREFIX install architecture-independent files in PREFIX
125 [$ac_default_prefix]
126 --exec-prefix=PREFIX install architecture-dependent files in PREFIX
127 [same as prefix]
128 --srcdir=DIR find the sources in DIR [configure dir or ..]
129 --program-prefix=PREFIX prepend PREFIX to installed program names
130 --program-suffix=SUFFIX append SUFFIX to installed program names
131 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
132Host type:
133 --build=BUILD configure for building on BUILD [BUILD=HOST]
134 --host=HOST configure for HOST [guessed]
135 --target=TARGET configure for TARGET [TARGET=HOST]
136Features and packages:
137 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
138 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
139 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
140 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
141 --x-includes=DIR X include files are in DIR
142 --x-libraries=DIR X library files are in DIR
143--enable and --with options recognized:$ac_help
144EOF
145 exit 0 ;;
146
147 -host | --host | --hos | --ho)
148 ac_prev=host ;;
149 -host=* | --host=* | --hos=* | --ho=*)
150 host="$ac_optarg" ;;
151
152 -nfp | --nfp | --nf)
153 # Obsolete; use --without-fp.
154 with_fp=no ;;
155
156 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
157 | --no-cr | --no-c)
158 no_create=yes ;;
159
160 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
161 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
162 no_recursion=yes ;;
163
164 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
165 ac_prev=prefix ;;
166 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
167 prefix="$ac_optarg" ;;
168
169 -program-prefix | --program-prefix | --program-prefi | --program-pref \
170 | --program-pre | --program-pr | --program-p)
171 ac_prev=program_prefix ;;
172 -program-prefix=* | --program-prefix=* | --program-prefi=* \
173 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
174 program_prefix="$ac_optarg" ;;
175
176 -program-suffix | --program-suffix | --program-suffi | --program-suff \
177 | --program-suf | --program-su | --program-s)
178 ac_prev=program_suffix ;;
179 -program-suffix=* | --program-suffix=* | --program-suffi=* \
180 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
181 program_suffix="$ac_optarg" ;;
182
183 -program-transform-name | --program-transform-name \
184 | --program-transform-nam | --program-transform-na \
185 | --program-transform-n | --program-transform- \
186 | --program-transform | --program-transfor \
187 | --program-transfo | --program-transf \
188 | --program-trans | --program-tran \
189 | --progr-tra | --program-tr | --program-t)
190 ac_prev=program_transform_name ;;
191 -program-transform-name=* | --program-transform-name=* \
192 | --program-transform-nam=* | --program-transform-na=* \
193 | --program-transform-n=* | --program-transform-=* \
194 | --program-transform=* | --program-transfor=* \
195 | --program-transfo=* | --program-transf=* \
196 | --program-trans=* | --program-tran=* \
197 | --progr-tra=* | --program-tr=* | --program-t=*)
198 program_transform_name="$ac_optarg" ;;
199
200 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
201 | -silent | --silent | --silen | --sile | --sil)
202 silent=yes ;;
203
204 -site | --site | --sit)
205 ac_prev=site ;;
206 -site=* | --site=* | --sit=*)
207 site="$ac_optarg" ;;
208
209 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
210 ac_prev=srcdir ;;
211 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
212 srcdir="$ac_optarg" ;;
213
214 -target | --target | --targe | --targ | --tar | --ta | --t)
215 ac_prev=target ;;
216 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
217 target="$ac_optarg" ;;
218
219 -v | -verbose | --verbose | --verbos | --verbo | --verb)
220 verbose=yes ;;
221
222 -version | --version | --versio | --versi | --vers)
223 echo "configure generated by autoconf version 2.4"
224 exit 0 ;;
225
226 -with-* | --with-*)
227 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
228 # Reject names that are not valid shell variable names.
229 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
230 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
231 fi
232 ac_package=`echo $ac_package| sed 's/-/_/g'`
233 case "$ac_option" in
234 *=*) ;;
235 *) ac_optarg=yes ;;
236 esac
237 eval "with_${ac_package}='$ac_optarg'" ;;
238
239 -without-* | --without-*)
240 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
241 # Reject names that are not valid shell variable names.
242 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
243 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
244 fi
245 ac_package=`echo $ac_package| sed 's/-/_/g'`
246 eval "with_${ac_package}=no" ;;
247
248 --x)
249 # Obsolete; use --with-x.
250 with_x=yes ;;
251
252 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
253 | --x-incl | --x-inc | --x-in | --x-i)
254 ac_prev=x_includes ;;
255 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
256 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
257 x_includes="$ac_optarg" ;;
258
259 -x-libraries | --x-libraries | --x-librarie | --x-librari \
260 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
261 ac_prev=x_libraries ;;
262 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
263 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
264 x_libraries="$ac_optarg" ;;
265
266 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
267 ;;
268
269 *)
270 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
271 echo "configure: warning: $ac_option: invalid host type" 1>&2
272 fi
273 if test "x$nonopt" != xNONE; then
274 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
275 fi
276 nonopt="$ac_option"
277 ;;
278
279 esac
280done
281
282if test -n "$ac_prev"; then
283 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
284fi
285
286trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
287
288# File descriptor usage:
289# 0 standard input
290# 1 file creation
291# 2 errors and warnings
292# 3 some systems may open it to /dev/tty
293# 4 used on the Kubota Titan
294# 6 checking for... messages and results
295# 5 compiler messages saved in config.log
296if test "$silent" = yes; then
297 exec 6>/dev/null
298else
299 exec 6>&1
300fi
301exec 5>./config.log
302
303echo "\
304This file contains any messages produced by compilers while
305running configure, to aid debugging if configure makes a mistake.
306" 1>&5
307
308# Strip out --no-create and --no-recursion so they do not pile up.
309# Also quote any args containing shell metacharacters.
310ac_configure_args=
311for ac_arg
312do
313 case "$ac_arg" in
314 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
315 | --no-cr | --no-c) ;;
316 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
317 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
318 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
319 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
320 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
321 esac
322done
323
324# NLS nuisances.
325# Only set LANG and LC_ALL to C if already set.
326# These must not be set unconditionally because not all systems understand
327# e.g. LANG=C (notably SCO).
328if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
329if test "${LANG+set}" = set; then LANG=C; export LANG; fi
330
331# confdefs.h avoids OS command line length limits that DEFS can exceed.
332rm -rf conftest* confdefs.h
333# AIX cpp loses on an empty file, so make sure it contains at least a newline.
334echo > confdefs.h
335
336# A filename unique to this package, relative to the directory that
337# configure is in, which we can look for to find out if srcdir is correct.
338ac_unique_file=libbfd.c
339
340# Find the source files, if location was not specified.
341if test -z "$srcdir"; then
342 ac_srcdir_defaulted=yes
343 # Try the directory containing this script, then its parent.
344 ac_prog=$0
345 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
346 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
347 srcdir=$ac_confdir
348 if test ! -r $srcdir/$ac_unique_file; then
349 srcdir=..
350 fi
351else
352 ac_srcdir_defaulted=no
353fi
354if test ! -r $srcdir/$ac_unique_file; then
355 if test "$ac_srcdir_defaulted" = yes; then
356 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
357 else
358 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
359 fi
360fi
361srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
362
363# Prefer explicitly selected file to automatically selected ones.
364if test -z "$CONFIG_SITE"; then
365 if test "x$prefix" != xNONE; then
366 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
367 else
368 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
369 fi
370fi
371for ac_site_file in $CONFIG_SITE; do
372 if test -r "$ac_site_file"; then
373 echo "loading site script $ac_site_file"
374 . "$ac_site_file"
375 fi
376done
377
378if test -r "$cache_file"; then
379 echo "loading cache $cache_file"
380 . $cache_file
381else
382 echo "creating cache $cache_file"
383 > $cache_file
384fi
385
386ac_ext=c
387# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
388ac_cpp='$CPP $CPPFLAGS'
389ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5 2>&5'
390ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5 2>&5'
391
392if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
393 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
394 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
395 ac_n= ac_c='
396' ac_t=' '
397 else
398 ac_n=-n ac_c= ac_t=
399 fi
400else
401 ac_n= ac_c='\c' ac_t=
402fi
403
404
405
406# Check whether --enable-64-bit-bfd or --disable-64-bit-bfd was given.
407enableval="$enable_64_bit_bfd"
408if test -n "$enableval"; then
a52a3ce8 409 case "${enableval}" in
8c693660
KR
410 yes) want64=true ;;
411 no) want64=false ;;
412 *) { echo "configure: error: bad value ${enableval} for 64-bit-bfd option" 1>&2; exit 1; } ;;
413esac
414else
415 want64=false
416fi
417# Check whether --enable-targets or --disable-targets was given.
418enableval="$enable_targets"
419if test -n "$enableval"; then
420 case "${enableval}" in
421 yes | "") { echo "configure: error: enable-targets option must specify target names or 'all'" 1>&2; exit 1; }
422 ;;
423 no) enable_targets= ;;
424 *) enable_targets=$enableval ;;
425esac
426fi
427
428ac_aux_dir=
429for ac_dir in `cd $srcdir/..;pwd` $srcdir/`cd $srcdir/..;pwd`; do
430 if test -f $ac_dir/install-sh; then
431 ac_aux_dir=$ac_dir
432 ac_install_sh="$ac_aux_dir/install-sh -c"
433 break
434 elif test -f $ac_dir/install.sh; then
435 ac_aux_dir=$ac_dir
436 ac_install_sh="$ac_aux_dir/install.sh -c"
437 break
438 fi
439done
440if test -z "$ac_aux_dir"; then
441 { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir/..;pwd` $srcdir/`cd $srcdir/..;pwd`" 1>&2; exit 1; }
442fi
443ac_config_guess=$ac_aux_dir/config.guess
444ac_config_sub=$ac_aux_dir/config.sub
445ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
446
447
448# Do some error checking and defaulting for the host and target type.
449# The inputs are:
450# configure --host=HOST --target=TARGET --build=BUILD NONOPT
451#
452# The rules are:
453# 1. You are not allowed to specify --host, --target, and nonopt at the
454# same time.
455# 2. Host defaults to nonopt.
456# 3. If nonopt is not specified, then host defaults to the current host,
457# as determined by config.guess.
458# 4. Target and build default to nonopt.
459# 5. If nonopt is not specified, then target and build default to host.
460
461# The aliases save the names the user supplied, while $host etc.
462# will get canonicalized.
463case $host---$target---$nonopt in
464NONE---*---* | *---NONE---* | *---*---NONE) ;;
465*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
466esac
467
468
469# Make sure we can run config.sub.
470if $ac_config_sub sun4 >/dev/null 2>&1; then :
471else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
472fi
473
474echo $ac_n "checking host system type""... $ac_c" 1>&6
475
476host_alias=$host
477case "$host_alias" in
478NONE)
479 case $nonopt in
480 NONE)
481 if host_alias=`$ac_config_guess`; then :
482 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
483 fi ;;
484 *) host_alias=$nonopt ;;
485 esac ;;
486esac
487
488host=`$ac_config_sub $host_alias`
489host_cpu=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
490host_vendor=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
491host_os=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
492echo "$ac_t""$host" 1>&6
493
494echo $ac_n "checking target system type""... $ac_c" 1>&6
495
496target_alias=$target
497case "$target_alias" in
498NONE)
499 case $nonopt in
500 NONE) target_alias=$host_alias ;;
501 *) target_alias=$nonopt ;;
502 esac ;;
503esac
504
505target=`$ac_config_sub $target_alias`
506target_cpu=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
507target_vendor=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
508target_os=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
509echo "$ac_t""$target" 1>&6
510
511echo $ac_n "checking build system type""... $ac_c" 1>&6
512
513build_alias=$build
514case "$build_alias" in
515NONE)
516 case $nonopt in
517 NONE) build_alias=$host_alias ;;
518 *) build_alias=$nonopt ;;
519 esac ;;
520esac
521
522build=`$ac_config_sub $build_alias`
523build_cpu=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
524build_vendor=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
525build_os=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
526echo "$ac_t""$build" 1>&6
527
528test "$host_alias" != "$target_alias" &&
529 test "$program_prefix$program_suffix$program_transform_name" = \
530 NONENONEs,x,x, &&
531 program_prefix=${target_alias}-
532
533if test -z "$target" ; then
534 { echo "configure: error: Unrecognized target system type; please check config.sub." 1>&2; exit 1; }
535fi
536if test "$program_transform_name" = s,x,x,; then
537 program_transform_name=
538else
539 # Double any \ or $.
540 echo 's,\\,\\\\,g; s,\$,$$,g' > conftestsed
541 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
542 rm -f conftestsed
543fi
544test "$program_prefix" != NONE &&
545 program_transform_name="s,^,${program_prefix},; $program_transform_name"
546# Use a double $ so make ignores it.
547test "$program_suffix" != NONE &&
548 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
549
550# sed with no file args requires a program.
551test "$program_transform_name" = "" && program_transform_name="s,x,x,"
552
553
554host64=false
555target64=false
556
557# host stuff:
558
f515fb2f
ILT
559HDEFINES=
560
561# Permit host specific settings.
8c693660
KR
562. ${srcdir}/configure.host
563
f515fb2f
ILT
564echo $ac_n "checking for CC""... $ac_c" 1>&6
565test -z "$CC" && CC=`egrep '^CC *=' ../Makefile | tail -1 | sed 's/^CC *= *//'`
566test -z "$CC" && CC=cc
567echo "$ac_t""setting CC to $CC" 1>&6
568
569cat > conftest.c <<EOF
570#ifdef __GNUC__
571 yes;
572#endif
573EOF
574if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then
575 GCC=yes
576 if test "${CFLAGS+set}" != set; then
577 echo 'void f(){}' > conftest.c
578 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
579 CFLAGS="-g -O"
580 else
581 CFLAGS="-O"
582 fi
583 fi
584else
585 GCC=
586 test "${CFLAGS+set}" = set || CFLAGS="-g"
587fi
588rm -f conftest*
589
590
591
592AR=${AR-ar}
593
8c693660
KR
594# Extract the first word of "ranlib", so it can be a program name with args.
595set dummy ranlib; ac_word=$2
596echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
597if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
598 echo $ac_n "(cached) $ac_c" 1>&6
599else
600 if test -n "$RANLIB"; then
601 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
602else
603 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
604 for ac_dir in $PATH; do
605 test -z "$ac_dir" && ac_dir=.
606 if test -f $ac_dir/$ac_word; then
607 ac_cv_prog_RANLIB="ranlib"
608 break
609 fi
610 done
611 IFS="$ac_save_ifs"
612 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
613fi
614fi
615RANLIB="$ac_cv_prog_RANLIB"
616if test -n "$RANLIB"; then
617 echo "$ac_t""$RANLIB" 1>&6
618else
619 echo "$ac_t""no" 1>&6
620fi
621
f515fb2f
ILT
622# Find a good install program. We prefer a C program (faster),
623# so one script is as good as another. But avoid the broken or
624# incompatible versions:
625# SysV /etc/install, /usr/sbin/install
626# SunOS /usr/etc/install
627# IRIX /sbin/install
628# AIX /bin/install
629# AFS /usr/afsws/bin/install, which mishandles nonexistent args
630# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
631# ./install, which can be erroneously created by make from ./install.sh.
632echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
633if test -z "$INSTALL"; then
634if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
635 echo $ac_n "(cached) $ac_c" 1>&6
636else
637 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
638 for ac_dir in $PATH; do
639 # Account for people who put trailing slashes in PATH elements.
640 case "$ac_dir/" in
641 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
642 *)
643 # OSF1 and SCO ODT 3.0 have their own names for install.
644 for ac_prog in ginstall installbsd scoinst install; do
645 if test -f $ac_dir/$ac_prog; then
646 if test $ac_prog = install &&
647 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
648 # AIX install. It has an incompatible calling convention.
649 # OSF/1 installbsd also uses dspmsg, but is usable.
650 :
651 else
652 ac_cv_path_install="$ac_dir/$ac_prog -c"
653 break 2
654 fi
655 fi
656 done
657 ;;
658 esac
659 done
660 IFS="$ac_save_ifs"
661 # As a last resort, use the slow shell script.
662 test -z "$ac_cv_path_install" && ac_cv_path_install="$ac_install_sh"
663fi
664 INSTALL="$ac_cv_path_install"
665fi
666echo "$ac_t""$INSTALL" 1>&6
8c693660 667
f515fb2f
ILT
668# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
669# It thinks the first close brace ends the variable substitution.
670test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
8c693660 671
f515fb2f 672test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
8c693660
KR
673
674
f515fb2f
ILT
675# Put a plausible default for CC_FOR_BUILD in Makefile.
676# If we cannot run a trivial program, we must be cross compiling.
677echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6
678if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then
679 echo $ac_n "(cached) $ac_c" 1>&6
680else
681 if test "$cross_compiling" = yes; then
682 ac_cv_c_cross=yes
683else
684cat > conftest.$ac_ext <<EOF
685#line 686 "configure"
686#include "confdefs.h"
687main(){return(0);}
688EOF
689eval $ac_link
690if test -s conftest && (./conftest; exit) 2>/dev/null; then
691 ac_cv_c_cross=no
692else
693 ac_cv_c_cross=yes
694fi
695fi
696rm -fr conftest*
697fi
698cross_compiling=$ac_cv_c_cross
699echo "$ac_t""$ac_cv_c_cross" 1>&6
8c693660 700
f515fb2f
ILT
701if test "x$cross_compiling" = "xno"; then
702 CC_FOR_BUILD='$(CC)'
8c693660 703else
f515fb2f 704 CC_FOR_BUILD=gcc
8c693660
KR
705fi
706
f515fb2f
ILT
707
708# Set up to make a link between the host's include file and "sysdep.h".
709files=hosts/${my_host}.h
710
711if test ! -f ${srcdir}/${files} ; then
712 files=../bfd/hosts/std-host.h
713 echo "configure: warning: BFD has no specific support for host ${host} -- using std-host" 1>&2
2b79a104
ILT
714fi
715
8c693660 716
f515fb2f 717
a52a3ce8
ILT
718# If we are configured native, pick a core file support file.
719COREFILE=
720COREFLAG=
721if test "${target}" = "${host}"; then
722 case "${host}" in
723 alpha-*-*) COREFILE=osf-core.o ;;
724 arm-*-riscix) COREFILE=trad-core.o ;;
725 hppa*-*-hpux*) COREFILE=hpux-core.o ;;
726 hppa*-*-hiux*) COREFILE=hpux-core.o ;;
727 hppa*-*-bsd*) COREFILE="hpux-core.o hppabsd-core.o"
728 COREFLAG="-DHPUX_CORE -DHPPABSD_CORE" ;;
2cb159a5
KR
729 i[345]86-sequent-bsd*) COREFILE=trad-core.o ;;
730 i[345]86-sequent-sysv4*) ;;
731 i[345]86-sequent-sysv*) COREFILE=trad-core.o ;;
732 i[345]86-*-bsd*) COREFILE=trad-core.o ;;
733 i[345]86-*-freebsd*) COREFILE=trad-core.o ;;
734 i[345]86-*-netbsd*) COREFILE=trad-core.o ;;
735 i[345]86-esix-sysv3*) COREFILE=trad-core.o ;;
736 i[345]86-*-sco*) COREFILE=trad-core.o ;;
737 i[345]86-*-mach3*) COREFILE=trad-core.o ;;
738 i[345]86-*-linux*) COREFILE=trad-core.o ;;
739 i[345]86-*-isc*) COREFILE=trad-core.o ;;
740 i[345]86-*-aix*) COREFILE=aix386-core.o ;;
a52a3ce8
ILT
741 mips-dec-bsd*) COREFILE=trad-core.o ;;
742 mips-dec-mach3*) COREFILE=trad-core.o ;;
743 mips-dec-*) COREFILE=trad-core.o ;;
744 mips-sgi-irix4*) COREFILE=irix-core.o ;;
745 mips-sgi-irix5*) COREFILE=irix-core.o ;;
746 mips-*-mach3*) COREFILE=trad-core.o ;;
747 mips-*-sysv4*) ;;
748 mips-*-sysv*) COREFILE=trad-core.o ;;
749 mips-*-riscos*) COREFILE=trad-core.o ;;
750 mips-sony-bsd*) COREFILE=trad-core.o ;;
751 m68*-bull*-sysv*) COREFILE=trad-core.o ;;
752 m68*-hp-hpux*) COREFILE=hpux-core.o ;;
753 m68*-hp-bsd*) COREFILE=trad-core.o ;;
754 m68*-motorola-sysv*) COREFILE=ptrace-core.o ;;
755 m68*-sony-*) COREFILE=trad-core.o ;;
756 m88*-*-sysv4*) ;;
757 m88*-motorola-sysv*) COREFILE=trad-core.o ;;
758 m88*-*-mach3*) COREFILE=trad-core.o ;;
759 ns32k-pc532-mach) COREFILE=trad-core.o ;;
760 rs6000-*-lynx*) COREFILE=lynx-core.o ;;
761 rs6000-*-aix4*) COREFILE=rs6000-core.o
762 COREFLAG=-DALTERNATE_AIX_CORE_FORMAT ;;
763 rs6000-*-*) COREFILE=rs6000-core.o ;;
764 powerpc-*-aix4*) COREFILE=rs6000-core.o
765 COREFLAG=-DALTERNATE_AIX_CORE_FORMAT ;;
766 powerpc-*-aix*) COREFILE=rs6000-core.o ;;
767 tahoe-*-*) COREFILE=trad-core.o ;;
768 vax-*-ultrix2*) COREFILE=trad-core.o ;;
769 vax-*-ultrix*) COREFILE=trad-core.o ;;
770 vax-*-*) COREFILE=trad-core.o ;;
771 esac
772
773 case "$COREFILE" in
774 aix386-core.o) COREFLAG=-DAIX386_CORE ;;
775 hppabsd-core.o) COREFLAG=-DHPPABSD_CORE ;;
776 hpux-core.o) COREFLAG=-DHPUX_CORE ;;
777 irix-core.o) COREFLAG=-DIRIX_CORE ;;
778 lynx-core.o) COREFLAG=-DLYNX_CORE ;;
779 osf-core.o) COREFLAG=-DOSF_CORE ;;
780 ptrace-core.o) COREFLAG=-DPTRACE_CORE ;;
781 rs6000-core.o) COREFLAG="$COREFLAG -DAIX_CORE" ;;
782 trad-core.o) COREFLAG=-DTRAD_CORE ;;
783 esac
784fi
785
786
787
8c693660
KR
788# target stuff:
789
790# Canonicalize the secondary target names.
791if test -n "$enable_targets" ; then
792 for targ in `echo $enable_targets | sed 's/,/ /g'`
793 do
9525b61b 794 result=`$ac_config_sub $targ 2>/dev/null`
8c693660
KR
795 if test -n "$result" ; then
796 canon_targets="$canon_targets $result"
797 else
798 # Allow targets that config.sub doesn't recognize, like "all".
799 canon_targets="$canon_targets $targ"
800 fi
801 done
802fi
803
804all_targets=false
2b79a104
ILT
805defvec=
806selvecs=
807selarchs=
808TDEFINES=
8c693660
KR
809for targ in $target $canon_targets
810do
2b79a104 811 if test "x$targ" = "xall"; then
8c693660
KR
812 all_targets=true
813 else
2b79a104
ILT
814 . $srcdir/config.bfd
815 if test "x$targ" = "x$target"; then
816 defvec=$targ_defvec
8c693660 817 fi
2b79a104
ILT
818 selvecs="$selvecs $targ_defvec $targ_selvecs"
819 selarchs="$selarchs $targ_archs"
820 TDEFINES="$TDEFINES $targ_cflags"
8c693660
KR
821 fi
822done
823
8c693660
KR
824
825# This processing still needs to be done if we're to decide properly whether
826# 64-bit support needs to be compiled in. Currently, it will be included if
827# the default or any other explicitly requested target requires it; it
828# will not be included on a 32-bit host if no 64-bit target is requested, and
829# no "--with-64-bit-bfd" option is given, even if "--with-targets=all" is
830# used.
831
2b79a104 832# uniq the default and selected vectors in all the configured targets.
8c693660 833f=""
2b79a104 834for i in $selvecs ; do
8c693660
KR
835 case " $f " in
836 *" $i "*) ;;
837 *) f="$f $i" ;;
838 esac
839done
2b79a104 840selvecs="$f"
8c693660 841
2b79a104 842# uniq the architectures in all the configured targets.
8c693660 843f=""
2b79a104 844for i in $selarchs ; do
8c693660
KR
845 case " $f " in
846 *" $i "*) ;;
847 *) f="$f $i" ;;
848 esac
849done
2b79a104 850selarchs="$f"
8c693660
KR
851
852# Target backend .o files.
853tb=
854
a52a3ce8
ILT
855elf="elf.o elflink.o"
856
2b79a104 857for vec in $selvecs
8c693660
KR
858do
859 case "$vec" in
860 # This list is alphabetized to make it easy to compare
861 # with the two vector lists in targets.c.
862 a29kcoff_big_vec) tb="$tb coff-a29k.o cofflink.o" ;;
863 a_out_adobe_vec) tb="$tb aout-adobe.o aout32.o stab-syms.o" ;;
a52a3ce8
ILT
864 armpe_little_vec) tb="$tb pe-arm.o cofflink.o " ;;
865 armpe_big_vec) tb="$tb pe-arm.o cofflink.o " ;;
866 armpei_little_vec) tb="$tb pei-arm.o cofflink.o " ;;
867 armpei_big_vec) tb="$tb pei-arm.o cofflink.o " ;;
8c693660
KR
868 aout0_big_vec) tb="$tb aout0.o aout32.o stab-syms.o" ;;
869 aout_arm_big_vec) tb="$tb aout-arm.o aout32.o stab-syms.o" ;;
870 aout_arm_little_vec) tb="$tb aout-arm.o aout32.o stab-syms.o" ;;
871 aout_mips_big_vec) tb="$tb mipsbsd.o aout32.o stab-syms.o" ;;
872 aout_mips_little_vec) tb="$tb mipsbsd.o aout32.o stab-syms.o" ;;
873 apollocoff_vec) tb="$tb coff-apollo.o" ;;
874 b_out_vec_big_host) tb="$tb bout.o aout32.o stab-syms.o" ;;
875 b_out_vec_little_host) tb="$tb bout.o aout32.o stab-syms.o" ;;
876# start-sanitize-arc
a52a3ce8
ILT
877 bfd_elf32_littlearc_vec) tb="$tb elf32-arc.o elf32.o $elf" ;;
878 bfd_elf32_bigarc_vec) tb="$tb elf32-arc.o elf32.o $elf" ;;
8c693660 879# end-sanitize-arc
a52a3ce8
ILT
880 bfd_elf32_big_generic_vec) tb="$tb elf32-gen.o elf32.o $elf" ;;
881 bfd_elf32_bigmips_vec) tb="$tb elf32-mips.o elf32.o $elf ecofflink.o" ;;
882 bfd_elf32_hppa_vec) tb="$tb elf32-hppa.o elf32.o $elf" ;;
883 bfd_elf32_i386_vec) tb="$tb elf32-i386.o elf32.o $elf" ;;
884 bfd_elf32_i860_vec) tb="$tb elf32-i860.o elf32.o $elf" ;;
885 bfd_elf32_little_generic_vec) tb="$tb elf32-gen.o elf32.o $elf" ;;
886 bfd_elf32_littlemips_vec) tb="$tb elf32-mips.o elf32.o $elf ecofflink.o" ;;
887 bfd_elf32_m68k_vec) tb="$tb elf32-m68k.o elf32.o $elf" ;;
888 bfd_elf32_m88k_vec) tb="$tb elf32-m88k.o elf32.o $elf" ;;
889 bfd_elf32_powerpc_vec) tb="$tb elf32-ppc.o elf32.o $elf" ;;
890 bfd_elf32_powerpcle_vec) tb="$tb elf32-ppc.o elf32.o $elf" ;;
891 bfd_elf32_sparc_vec) tb="$tb elf32-sparc.o elf32.o $elf" ;;
892 bfd_elf64_big_generic_vec) tb="$tb elf64-gen.o elf64.o $elf"
8c693660 893 target64=true ;;
a52a3ce8 894 bfd_elf64_little_generic_vec) tb="$tb elf64-gen.o elf64.o $elf"
8c693660 895 target64=true ;;
a52a3ce8 896 bfd_elf64_sparc_vec) tb="$tb elf64-sparc.o elf64.o $elf"
8c693660
KR
897 target64=true ;;
898 cisco_core_vec) tb="$tb cisco-core.o" ;;
899 demo_64_vec) tb="$tb demo64.o aout64.o stab-syms.o"
900 target64=true ;;
901 ecoff_big_vec) tb="$tb coff-mips.o ecoff.o ecofflink.o" ;;
902 ecoff_little_vec) tb="$tb coff-mips.o ecoff.o ecofflink.o" ;;
903 ecoffalpha_little_vec) tb="$tb coff-alpha.o ecoff.o ecofflink.o"
904 target64=true ;;
905 h8300coff_vec) tb="$tb coff-h8300.o reloc16.o" ;;
906 h8500coff_vec) tb="$tb coff-h8500.o reloc16.o" ;;
907 host_aout_vec) tb="$tb host-aout.o aout32.o stab-syms.o" ;;
908 hp300bsd_vec) tb="$tb hp300bsd.o aout32.o stab-syms.o" ;;
909 hp300hpux_vec) tb="$tb hp300hpux.o aout32.o stab-syms.o" ;;
910 i386aout_vec) tb="$tb i386aout.o aout32.o stab-syms.o" ;;
911 i386bsd_vec) tb="$tb i386bsd.o aout32.o stab-syms.o" ;;
912 i386dynix_vec) tb="$tb i386dynix.o aout32.o stab-syms.o" ;;
913 i386coff_vec) tb="$tb coff-i386.o cofflink.o" ;;
914 i386msdos_vec) tb="$tb i386msdos.o" ;;
915 i386pe_vec) tb="$tb pe-i386.o cofflink.o " ;;
916 i386pei_vec) tb="$tb pei-i386.o cofflink.o" ;;
917 i386linux_vec) tb="$tb i386linux.o aout32.o stab-syms.o" ;;
918 i386lynx_aout_vec) tb="$tb i386lynx.o lynx-core.o aout32.o stab-syms.o" ;;
919 i386lynx_coff_vec) tb="$tb cf-i386lynx.o cofflink.o lynx-core.o stab-syms.o" ;;
920 i386mach3_vec) tb="$tb i386mach3.o aout32.o stab-syms.o" ;;
921 i386netbsd_vec) tb="$tb i386netbsd.o aout32.o stab-syms.o" ;;
922 i386os9k_vec) tb="$tb i386os9k.o aout32.o stab-syms.o" ;;
923 icoff_big_vec) tb="$tb coff-i960.o" ;;
924 icoff_little_vec) tb="$tb coff-i960.o" ;;
925 ieee_vec) tb="$tb ieee.o" ;;
926 m68kcoff_vec) tb="$tb coff-m68k.o cofflink.o" ;;
927 m68kcoffun_vec) tb="$tb coff-u68k.o coff-m68k.o cofflink.o" ;;
928 m68klynx_aout_vec) tb="$tb m68klynx.o lynx-core.o aout32.o stab-syms.o" ;;
929 m68klynx_coff_vec) tb="$tb cf-m68klynx.o coff-m68k.o cofflink.o lynx-core.o stab-syms.o" ;;
930 m68knetbsd_vec) tb="$tb m68knetbsd.o aout32.o stab-syms.o" ;;
931 m88kbcs_vec) tb="$tb coff-m88k.o" ;;
932 newsos3_vec) tb="$tb newsos3.o aout32.o stab-syms.o" ;;
933 nlm32_i386_vec) tb="$tb nlm32-i386.o nlm32.o nlm.o" ;;
934 nlm32_sparc_vec) tb="$tb nlm32-sparc.o nlm32.o nlm.o" ;;
935 nlm32_alpha_vec) tb="$tb nlm32-alpha.o nlm32.o nlm.o"
936 target64=true ;;
937 riscix_vec) tb="$tb aout32.o riscix.o stab-syms.o" ;;
938 nlm32_powerpc_vec) tb="$tb nlm32-ppc.o nlm32.o nlm.o" ;;
939 pc532netbsd_vec) tb="$tb ns32knetbsd.o aout-ns32k.o stab-syms.o" ;;
940 pc532machaout_vec) tb="$tb pc532-mach.o aout-ns32k.o stab-syms.o" ;;
941 rs6000coff_vec) tb="$tb coff-rs6000.o" ;;
942 shcoff_vec) tb="$tb coff-sh.o cofflink.o" ;;
943# start-sanitize-rce
944 rce_aout_vec) tb="$tb aout-rce.o aout32.o stab-syms.o" ;;
945# end-sanitize-rce
946 shlcoff_vec) tb="$tb coff-sh.o cofflink.o" ;;
947 som_vec) tb="$tb som.o" ;;
948 sparclynx_aout_vec) tb="$tb sparclynx.o lynx-core.o aout32.o stab-syms.o" ;;
949 sparclynx_coff_vec) tb="$tb cf-sparclynx.o lynx-core.o stab-syms.o" ;;
950 sparcnetbsd_vec) tb="$tb sparcnetbsd.o aout32.o stab-syms.o" ;;
951 sparccoff_vec) tb="$tb coff-sparc.o" ;;
952 srec_vec) tb="$tb srec.o" ;;
953 sunos_big_vec) tb="$tb sunos.o aout32.o stab-syms.o" ;;
954 symbolsrec_vec) tb="$tb srec.o" ;;
955 tekhex_vec) tb="$tb tekhex.o" ;;
956 we32kcoff_vec) tb="$tb coff-we32k.o" ;;
957 z8kcoff_vec) tb="$tb coff-z8k.o reloc16.o" ;;
958 w65_vec) tb="$tb coff-w65.o reloc16.o" ;;
959 versados_vec) tb="$tb versados.o" ;;
960
961 "") ;;
962 *) { echo "configure: error: *** unknown target vector $vec" 1>&2; exit 1; } ;;
963 esac
964done
965
966# Target architecture .o files.
2b79a104 967ta=`echo $selarchs | sed -e s/bfd_/cpu-/g -e s/_arch/.o/g`
8c693660
KR
968
969# Weed out duplicate .o files.
970f=""
971for i in $tb ; do
972 case " $f " in
973 *" $i "*) ;;
974 *) f="$f $i" ;;
975 esac
976done
977tb="$f"
978
979f=""
980for i in $ta ; do
981 case " $f " in
982 *" $i "*) ;;
983 *) f="$f $i" ;;
984 esac
985done
986ta="$f"
987
988bfd_backends="$tb"
989bfd_machines="$ta"
990
991if test x${all_targets} = xtrue ; then
992 bfd_backends="${bfd_backends}"' $(ALL_BACKENDS)'
993 bfd_machines="${bfd_machines}"' $(ALL_MACHINES)'
2b79a104
ILT
994 selvecs=
995 selarchs=
8c693660
KR
996else # all_targets is true
997 # Only set these if they will be nonempty, for the clever echo.
2b79a104
ILT
998 test -n "$selvecs" &&
999 selvecs=`echo $selvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
1000 test -n "$selarchs" &&
1001 selarchs=`echo $selarchs | sed -e 's/ \(.\)/,\1/g'`
8c693660
KR
1002fi # all_targets is true
1003
1004case ${host64}-${target64}-${want64} in
1005 *true*)
1006 wordsize=64
1007 all_backends='$(BFD64_BACKENDS) $(BFD32_BACKENDS)'
1008 ;;
1009 false-false-false)
1010 wordsize=32
1011 all_backends='$(BFD32_BACKENDS)'
1012 ;;
1013esac
1014
1015
1016
1017
1018
1019
8c693660
KR
1020tdefaults=""
1021test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}"
1022test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'"
1023test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'"
1024
1025
1026rm -f doc/config.status
1027trap '' 1 2 15
1028cat > confcache <<\EOF
1029# This file is a shell script that caches the results of configure
1030# tests run on this system so they can be shared between configure
1031# scripts and configure runs. It is not useful on other systems.
1032# If it contains results you don't want to keep, you may remove or edit it.
1033#
1034# By default, configure uses ./config.cache as the cache file,
1035# creating it if it does not exist already. You can give configure
1036# the --cache-file=FILE option to use a different cache file; that is
1037# what configure does when it calls configure scripts in
1038# subdirectories, so they share the cache.
1039# Giving --cache-file=/dev/null disables caching, for debugging configure.
1040# config.status only pays attention to the cache file if you give it the
1041# --recheck option to rerun configure.
1042#
1043EOF
1044# Ultrix sh set writes to stderr and can't be redirected directly,
1045# and sets the high bit in the cache file unless we assign to the vars.
1046(set) 2>&1 |
1047 sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \
1048 >> confcache
1049if cmp -s $cache_file confcache; then
1050 :
1051else
1052 if test -w $cache_file; then
1053 echo "updating cache $cache_file"
1054 cat confcache > $cache_file
1055 else
1056 echo "not updating unwritable cache $cache_file"
1057 fi
1058fi
1059rm -f confcache
1060
1061trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
1062
1063test "x$prefix" = xNONE && prefix=$ac_default_prefix
1064# Let make expand exec_prefix.
1065test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1066
1067# Any assignment to VPATH causes Sun make to only execute
1068# the first set of double-colon rules, so remove it if not needed.
1069# If there is a colon in the path, we need to keep it.
1070if test "x$srcdir" = x.; then
1071 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
1072fi
1073
1074trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1075
1076# Transform confdefs.h into DEFS.
1077# Protect against shell expansion while executing Makefile rules.
1078# Protect against Makefile macro expansion.
1079cat > conftest.defs <<\EOF
1080s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%-D\1=\2%g
1081s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
1082s%\[%\\&%g
1083s%\]%\\&%g
1084s%\$%$$%g
1085EOF
1086DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
1087rm -f conftest.defs
1088
1089
1090# Without the "./", some shells look in PATH for config.status.
1091: ${CONFIG_STATUS=./config.status}
1092
1093echo creating $CONFIG_STATUS
1094rm -f $CONFIG_STATUS
1095cat > $CONFIG_STATUS <<EOF
1096#! /bin/sh
1097# Generated automatically by configure.
1098# Run this file to recreate the current configuration.
1099# This directory was configured as follows,
1100# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1101#
1102# $0 $ac_configure_args
1103#
1104# Compiler output produced by configure, useful for debugging
1105# configure, is in ./config.log if it exists.
1106
1107ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1108for ac_option
1109do
1110 case "\$ac_option" in
1111 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1112 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1113 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1114 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
1115 echo "$CONFIG_STATUS generated by autoconf version 2.4"
1116 exit 0 ;;
1117 -help | --help | --hel | --he | --h)
1118 echo "\$ac_cs_usage"; exit 0 ;;
1119 *) echo "\$ac_cs_usage"; exit 1 ;;
1120 esac
1121done
1122
1123ac_given_srcdir=$srcdir
f515fb2f 1124ac_given_INSTALL="$INSTALL"
8c693660
KR
1125
1126trap 'rm -fr `echo "Makefile doc/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
1127
1128# Protect against being on the right side of a sed subst in config.status.
1129sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g;
1130 s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF
1131$ac_vpsub
1132$extrasub
1133s%@CFLAGS@%$CFLAGS%g
1134s%@CPPFLAGS@%$CPPFLAGS%g
1135s%@CXXFLAGS@%$CXXFLAGS%g
1136s%@DEFS@%$DEFS%g
1137s%@LDFLAGS@%$LDFLAGS%g
1138s%@LIBS@%$LIBS%g
1139s%@exec_prefix@%$exec_prefix%g
1140s%@prefix@%$prefix%g
1141s%@program_transform_name@%$program_transform_name%g
1142s%@host@%$host%g
1143s%@host_alias@%$host_alias%g
1144s%@host_cpu@%$host_cpu%g
1145s%@host_vendor@%$host_vendor%g
1146s%@host_os@%$host_os%g
1147s%@target@%$target%g
1148s%@target_alias@%$target_alias%g
1149s%@target_cpu@%$target_cpu%g
1150s%@target_vendor@%$target_vendor%g
1151s%@target_os@%$target_os%g
1152s%@build@%$build%g
1153s%@build_alias@%$build_alias%g
1154s%@build_cpu@%$build_cpu%g
1155s%@build_vendor@%$build_vendor%g
1156s%@build_os@%$build_os%g
f515fb2f
ILT
1157s%@CC@%$CC%g
1158s%@HDEFINES@%$HDEFINES%g
1159s%@AR@%$AR%g
8c693660 1160s%@RANLIB@%$RANLIB%g
f515fb2f
ILT
1161s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
1162s%@INSTALL_DATA@%$INSTALL_DATA%g
1163s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
a52a3ce8
ILT
1164s%@COREFILE@%$COREFILE%g
1165s%@COREFLAG@%$COREFLAG%g
2b79a104 1166s%@TDEFINES@%$TDEFINES%g
8c693660
KR
1167s%@wordsize@%$wordsize%g
1168s%@all_backends@%$all_backends%g
1169s%@bfd_backends@%$bfd_backends%g
1170s%@bfd_machines@%$bfd_machines%g
1171s%@tdefaults@%$tdefaults%g
1172
1173CEOF
1174EOF
1175cat >> $CONFIG_STATUS <<EOF
1176
1177CONFIG_FILES=\${CONFIG_FILES-"Makefile doc/Makefile"}
1178EOF
1179cat >> $CONFIG_STATUS <<\EOF
1180for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
1181 # Support "outfile[:infile]", defaulting infile="outfile.in".
1182 case "$ac_file" in
1183 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
1184 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1185 *) ac_file_in="${ac_file}.in" ;;
1186 esac
1187
1188 # Adjust relative srcdir, etc. for subdirectories.
1189
1190 # Remove last slash and all that follows it. Not all systems have dirname.
1191 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1192 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1193 # The file is in a subdirectory.
1194 test ! -d "$ac_dir" && mkdir "$ac_dir"
1195 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
1196 # A "../" for each directory in $ac_dir_suffix.
1197 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
1198 else
1199 ac_dir_suffix= ac_dots=
1200 fi
1201
1202 case "$ac_given_srcdir" in
1203 .) srcdir=.
1204 if test -z "$ac_dots"; then top_srcdir=.
1205 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
1206 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
1207 *) # Relative path.
1208 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
1209 top_srcdir="$ac_dots$ac_given_srcdir" ;;
1210 esac
1211
f515fb2f
ILT
1212 case "$ac_given_INSTALL" in
1213 [/$]*) INSTALL="$ac_given_INSTALL" ;;
1214 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
1215 esac
8c693660
KR
1216 echo creating "$ac_file"
1217 rm -f "$ac_file"
1218 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1219 case "$ac_file" in
1220 *Makefile*) ac_comsub="1i\\
1221# $configure_input" ;;
1222 *) ac_comsub= ;;
1223 esac
1224 sed -e "$ac_comsub
1225s%@configure_input@%$configure_input%g
1226s%@srcdir@%$srcdir%g
1227s%@top_srcdir@%$top_srcdir%g
f515fb2f 1228s%@INSTALL@%$INSTALL%g
8c693660
KR
1229" -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
1230fi; done
1231rm -f conftest.subs
1232
1233EOF
1234
1235cat >> $CONFIG_STATUS <<EOF
1236ac_sources="$files"
1237ac_dests="sysdep.h"
1238EOF
1239
1240cat >> $CONFIG_STATUS <<\EOF
1241srcdir=$ac_given_srcdir
1242while test -n "$ac_sources"; do
1243 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
1244 set $ac_sources; ac_source=$1; shift; ac_sources=$*
1245
1246 echo "linking $srcdir/$ac_source to $ac_dest"
1247
1248 if test ! -r $srcdir/$ac_source; then
1249 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
1250 fi
1251 rm -f $ac_dest
1252
1253 # Make relative symlinks.
1254 # Remove last slash and all that follows it. Not all systems have dirname.
1255 ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
1256 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
1257 # The dest file is in a subdirectory.
1258 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
1259 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
1260 # A "../" for each directory in $ac_dest_dir_suffix.
1261 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
1262 else
1263 ac_dest_dir_suffix= ac_dots=
1264 fi
1265
1266 case "$srcdir" in
1267 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
1268 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
1269 esac
1270
1271 # Make a symlink if possible; otherwise try a hard link.
1272 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
1273 ln $srcdir/$ac_source $ac_dest; then :
1274 else
1275 { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
1276 fi
1277done
1278
1279
1280exit 0
1281EOF
1282chmod +x $CONFIG_STATUS
1283rm -fr confdefs* $ac_clean_files
1284test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
1285
This page took 0.106484 seconds and 4 git commands to generate.