No longer need to sanitize away h8s stuff.
[deliverable/binutils-gdb.git] / sim / sh / configure
CommitLineData
c632873c
C
1#! /bin/sh
2
3# Guess values for system-dependent variables and create Makefiles.
4# Generated automatically using autoconf version 2.4.2
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:
14
15# Initialize some variables set by options.
16# The variables have the same names as the options, with
17# dashes changed to underlines.
18build=NONE
19cache_file=./config.cache
20exec_prefix=NONE
21host=NONE
22no_create=
23nonopt=NONE
24no_recursion=
25prefix=NONE
26program_prefix=NONE
27program_suffix=NONE
28program_transform_name=s,x,x,
29silent=
30site=
31srcdir=
32target=NONE
33verbose=
34x_includes=NONE
35x_libraries=NONE
36bindir='${exec_prefix}/bin'
37sbindir='${exec_prefix}/sbin'
38libexecdir='${exec_prefix}/libexec'
39datadir='${prefix}/share'
40sysconfdir='${prefix}/etc'
41sharedstatedir='${prefix}/com'
42localstatedir='${prefix}/var'
43libdir='${exec_prefix}/lib'
44includedir='${prefix}/include'
45oldincludedir='/usr/include'
46infodir='${prefix}/info'
47mandir='${prefix}/man'
48
49# Initialize some other variables.
50subdirs=
51
52ac_prev=
53for ac_option
54do
55
56 # If the previous option needs an argument, assign it.
57 if test -n "$ac_prev"; then
58 eval "$ac_prev=\$ac_option"
59 ac_prev=
60 continue
61 fi
62
63 case "$ac_option" in
64 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
65 *) ac_optarg= ;;
66 esac
67
68 # Accept the important Cygnus configure options, so we can diagnose typos.
69
70 case "$ac_option" in
71
72 -bindir | --bindir | --bindi | --bind | --bin | --bi)
73 ac_prev=bindir ;;
74 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
75 bindir="$ac_optarg" ;;
76
77 -build | --build | --buil | --bui | --bu)
78 ac_prev=build ;;
79 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
80 build="$ac_optarg" ;;
81
82 -cache-file | --cache-file | --cache-fil | --cache-fi \
83 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
84 ac_prev=cache_file ;;
85 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
86 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
87 cache_file="$ac_optarg" ;;
88
89 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
90 ac_prev=datadir ;;
91 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
92 | --da=*)
93 datadir="$ac_optarg" ;;
94
95 -disable-* | --disable-*)
96 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
97 # Reject names that are not valid shell variable names.
98 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
99 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
100 fi
101 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
102 eval "enable_${ac_feature}=no" ;;
103
104 -enable-* | --enable-*)
105 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
106 # Reject names that are not valid shell variable names.
107 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
108 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
109 fi
110 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
111 case "$ac_option" in
112 *=*) ;;
113 *) ac_optarg=yes ;;
114 esac
115 eval "enable_${ac_feature}='$ac_optarg'" ;;
116
117 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
118 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
119 | --exec | --exe | --ex)
120 ac_prev=exec_prefix ;;
121 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
122 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
123 | --exec=* | --exe=* | --ex=*)
124 exec_prefix="$ac_optarg" ;;
125
126 -gas | --gas | --ga | --g)
127 # Obsolete; use --with-gas.
128 with_gas=yes ;;
129
130 -help | --help | --hel | --he)
131 # Omit some internal or obsolete options to make the list less imposing.
132 # This message is too long to be a string in the A/UX 3.1 sh.
133 cat << EOF
134Usage: configure [options] [host]
135Options: [defaults in brackets after descriptions]
136Configuration:
137 --cache-file=FILE cache test results in FILE
138 --help print this message
139 --no-create do not create output files
140 --quiet, --silent do not print \`checking...' messages
141 --version print the version of autoconf that created configure
142Directory and file names:
143 --prefix=PREFIX install architecture-independent files in PREFIX
144 [$ac_default_prefix]
145 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
146 [same as prefix]
147 --bindir=DIR user executables in DIR [EPREFIX/bin]
148 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
149 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
150 --datadir=DIR read-only architecture-independent data in DIR [PREFIX/share]
151 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
152 --sharedstatedir=DIR modifiable architecture-independent data in DIR [PREFIX/com]
153 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
154 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
155 --includedir=DIR C header files in DIR [PREFIX/include]
156 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
157 --infodir=DIR info documentation in DIR [PREFIX/info]
158 --mandir=DIR man documentation in DIR [PREFIX/man]
159 --srcdir=DIR find the sources in DIR [configure dir or ..]
160 --program-prefix=PREFIX prepend PREFIX to installed program names
161 --program-suffix=SUFFIX append SUFFIX to installed program names
162 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
163EOF
164 cat << EOF
165Host type:
166 --build=BUILD configure for building on BUILD [BUILD=HOST]
167 --host=HOST configure for HOST [guessed]
168 --target=TARGET configure for TARGET [TARGET=HOST]
169Features and packages:
170 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
171 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
172 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
173 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
174 --x-includes=DIR X include files are in DIR
175 --x-libraries=DIR X library files are in DIR
176--enable and --with options recognized:$ac_help
177EOF
178 exit 0 ;;
179
180 -host | --host | --hos | --ho)
181 ac_prev=host ;;
182 -host=* | --host=* | --hos=* | --ho=*)
183 host="$ac_optarg" ;;
184
185 -includedir | --includedir | --includedi | --included | --include \
186 | --includ | --inclu | --incl | --inc)
187 ac_prev=includedir ;;
188 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
189 | --includ=* | --inclu=* | --incl=* | --inc=*)
190 includedir="$ac_optarg" ;;
191
192 -infodir | --infodir | --infodi | --infod | --info | --inf)
193 ac_prev=infodir ;;
194 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
195 infodir="$ac_optarg" ;;
196
197 -libdir | --libdir | --libdi | --libd)
198 ac_prev=libdir ;;
199 -libdir=* | --libdir=* | --libdi=* | --libd=*)
200 libdir="$ac_optarg" ;;
201
202 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
203 | --libexe | --libex | --libe)
204 ac_prev=libexecdir ;;
205 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
206 | --libexe=* | --libex=* | --libe=*)
207 libexecdir="$ac_optarg" ;;
208
209 -localstatedir | --localstatedir | --localstatedi | --localstated \
210 | --localstate | --localstat | --localsta | --localst \
211 | --locals | --local | --loca | --loc | --lo)
212 ac_prev=localstatedir ;;
213 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
214 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
215 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
216 localstatedir="$ac_optarg" ;;
217
218 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
219 ac_prev=mandir ;;
220 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
221 mandir="$ac_optarg" ;;
222
223 -nfp | --nfp | --nf)
224 # Obsolete; use --without-fp.
225 with_fp=no ;;
226
227 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
228 | --no-cr | --no-c)
229 no_create=yes ;;
230
231 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
232 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
233 no_recursion=yes ;;
234
235 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
236 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
237 | --oldin | --oldi | --old | --ol | --o)
238 ac_prev=oldincludedir ;;
239 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
240 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
241 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
242 oldincludedir="$ac_optarg" ;;
243
244 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
245 ac_prev=prefix ;;
246 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
247 prefix="$ac_optarg" ;;
248
249 -program-prefix | --program-prefix | --program-prefi | --program-pref \
250 | --program-pre | --program-pr | --program-p)
251 ac_prev=program_prefix ;;
252 -program-prefix=* | --program-prefix=* | --program-prefi=* \
253 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
254 program_prefix="$ac_optarg" ;;
255
256 -program-suffix | --program-suffix | --program-suffi | --program-suff \
257 | --program-suf | --program-su | --program-s)
258 ac_prev=program_suffix ;;
259 -program-suffix=* | --program-suffix=* | --program-suffi=* \
260 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
261 program_suffix="$ac_optarg" ;;
262
263 -program-transform-name | --program-transform-name \
264 | --program-transform-nam | --program-transform-na \
265 | --program-transform-n | --program-transform- \
266 | --program-transform | --program-transfor \
267 | --program-transfo | --program-transf \
268 | --program-trans | --program-tran \
269 | --progr-tra | --program-tr | --program-t)
270 ac_prev=program_transform_name ;;
271 -program-transform-name=* | --program-transform-name=* \
272 | --program-transform-nam=* | --program-transform-na=* \
273 | --program-transform-n=* | --program-transform-=* \
274 | --program-transform=* | --program-transfor=* \
275 | --program-transfo=* | --program-transf=* \
276 | --program-trans=* | --program-tran=* \
277 | --progr-tra=* | --program-tr=* | --program-t=*)
278 program_transform_name="$ac_optarg" ;;
279
280 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
281 | -silent | --silent | --silen | --sile | --sil)
282 silent=yes ;;
283
284 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
285 ac_prev=sbindir ;;
286 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
287 | --sbi=* | --sb=*)
288 sbindir="$ac_optarg" ;;
289
290 -sharedstatedir | --sharedstatedir | --sharedstatedi \
291 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
292 | --sharedst | --shareds | --shared | --share | --shar \
293 | --sha | --sh)
294 ac_prev=sharedstatedir ;;
295 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
296 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
297 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
298 | --sha=* | --sh=*)
299 sharedstatedir="$ac_optarg" ;;
300
301 -site | --site | --sit)
302 ac_prev=site ;;
303 -site=* | --site=* | --sit=*)
304 site="$ac_optarg" ;;
305
306 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
307 ac_prev=srcdir ;;
308 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
309 srcdir="$ac_optarg" ;;
310
311 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
312 | --syscon | --sysco | --sysc | --sys | --sy)
313 ac_prev=sysconfdir ;;
314 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
315 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
316 sysconfdir="$ac_optarg" ;;
317
318 -target | --target | --targe | --targ | --tar | --ta | --t)
319 ac_prev=target ;;
320 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
321 target="$ac_optarg" ;;
322
323 -v | -verbose | --verbose | --verbos | --verbo | --verb)
324 verbose=yes ;;
325
326 -version | --version | --versio | --versi | --vers)
327 echo "configure generated by autoconf version 2.4.2"
328 exit 0 ;;
329
330 -with-* | --with-*)
331 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
332 # Reject names that are not valid shell variable names.
333 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
334 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
335 fi
336 ac_package=`echo $ac_package| sed 's/-/_/g'`
337 case "$ac_option" in
338 *=*) ;;
339 *) ac_optarg=yes ;;
340 esac
341 eval "with_${ac_package}='$ac_optarg'" ;;
342
343 -without-* | --without-*)
344 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
345 # Reject names that are not valid shell variable names.
346 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
347 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
348 fi
349 ac_package=`echo $ac_package| sed 's/-/_/g'`
350 eval "with_${ac_package}=no" ;;
351
352 --x)
353 # Obsolete; use --with-x.
354 with_x=yes ;;
355
356 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
357 | --x-incl | --x-inc | --x-in | --x-i)
358 ac_prev=x_includes ;;
359 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
360 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
361 x_includes="$ac_optarg" ;;
362
363 -x-libraries | --x-libraries | --x-librarie | --x-librari \
364 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
365 ac_prev=x_libraries ;;
366 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
367 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
368 x_libraries="$ac_optarg" ;;
369
370 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
371 ;;
372
373 *)
374 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
375 echo "configure: warning: $ac_option: invalid host type" 1>&2
376 fi
377 if test "x$nonopt" != xNONE; then
378 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
379 fi
380 nonopt="$ac_option"
381 ;;
382
383 esac
384done
385
386if test -n "$ac_prev"; then
387 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
388fi
389
390trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
391
392# File descriptor usage:
393# 0 standard input
394# 1 file creation
395# 2 errors and warnings
396# 3 some systems may open it to /dev/tty
397# 4 used on the Kubota Titan
398# 6 checking for... messages and results
399# 5 compiler messages saved in config.log
400if test "$silent" = yes; then
401 exec 6>/dev/null
402else
403 exec 6>&1
404fi
405exec 5>./config.log
406
407echo "\
408This file contains any messages produced by compilers while
409running configure, to aid debugging if configure makes a mistake.
410" 1>&5
411
412# Strip out --no-create and --no-recursion so they do not pile up.
413# Also quote any args containing shell metacharacters.
414ac_configure_args=
415for ac_arg
416do
417 case "$ac_arg" in
418 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
419 | --no-cr | --no-c) ;;
420 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
421 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
422 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
423 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
424 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
425 esac
426done
427
428# NLS nuisances.
429# Only set LANG and LC_ALL to C if already set.
430# These must not be set unconditionally because not all systems understand
431# e.g. LANG=C (notably SCO).
432if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
433if test "${LANG+set}" = set; then LANG=C; export LANG; fi
434
435# confdefs.h avoids OS command line length limits that DEFS can exceed.
436rm -rf conftest* confdefs.h
437# AIX cpp loses on an empty file, so make sure it contains at least a newline.
438echo > confdefs.h
439
440# A filename unique to this package, relative to the directory that
441# configure is in, which we can look for to find out if srcdir is correct.
442ac_unique_file=Makefile.in
443
444# Find the source files, if location was not specified.
445if test -z "$srcdir"; then
446 ac_srcdir_defaulted=yes
447 # Try the directory containing this script, then its parent.
448 ac_prog=$0
449 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
450 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
451 srcdir=$ac_confdir
452 if test ! -r $srcdir/$ac_unique_file; then
453 srcdir=..
454 fi
455else
456 ac_srcdir_defaulted=no
457fi
458if test ! -r $srcdir/$ac_unique_file; then
459 if test "$ac_srcdir_defaulted" = yes; then
460 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
461 else
462 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
463 fi
464fi
465srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
466
467# Prefer explicitly selected file to automatically selected ones.
468if test -z "$CONFIG_SITE"; then
469 if test "x$prefix" != xNONE; then
470 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
471 else
472 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
473 fi
474fi
475for ac_site_file in $CONFIG_SITE; do
476 if test -r "$ac_site_file"; then
477 echo "loading site script $ac_site_file"
478 . "$ac_site_file"
479 fi
480done
481
482if test -r "$cache_file"; then
483 echo "loading cache $cache_file"
484 . $cache_file
485else
486 echo "creating cache $cache_file"
487 > $cache_file
488fi
489
490ac_ext=c
491# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
492ac_cpp='echo $CPP $CPPFLAGS 1>&5;
493$CPP $CPPFLAGS'
494ac_compile='echo ${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5;
495${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5 2>&5'
496ac_link='echo ${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5;
497${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5 2>&5'
498
499if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
500 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
501 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
502 ac_n= ac_c='
503' ac_t=' '
504 else
505 ac_n=-n ac_c= ac_t=
506 fi
507else
508 ac_n= ac_c='\c' ac_t=
509fi
510
511
512
513ac_aux_dir=
514for ac_dir in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../..; do
515 if test -f $ac_dir/install-sh; then
516 ac_aux_dir=$ac_dir
517 ac_install_sh="$ac_aux_dir/install-sh -c"
518 break
519 elif test -f $ac_dir/install.sh; then
520 ac_aux_dir=$ac_dir
521 ac_install_sh="$ac_aux_dir/install.sh -c"
522 break
523 fi
524done
525if test -z "$ac_aux_dir"; then
526 { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../.." 1>&2; exit 1; }
527fi
528ac_config_guess=$ac_aux_dir/config.guess
529ac_config_sub=$ac_aux_dir/config.sub
530ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
531
532
533# Do some error checking and defaulting for the host and target type.
534# The inputs are:
535# configure --host=HOST --target=TARGET --build=BUILD NONOPT
536#
537# The rules are:
538# 1. You are not allowed to specify --host, --target, and nonopt at the
539# same time.
540# 2. Host defaults to nonopt.
541# 3. If nonopt is not specified, then host defaults to the current host,
542# as determined by config.guess.
543# 4. Target and build default to nonopt.
544# 5. If nonopt is not specified, then target and build default to host.
545
546# The aliases save the names the user supplied, while $host etc.
547# will get canonicalized.
548case $host---$target---$nonopt in
549NONE---*---* | *---NONE---* | *---*---NONE) ;;
550*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
551esac
552
553
554# Make sure we can run config.sub.
555if $ac_config_sub sun4 >/dev/null 2>&1; then :
556else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
557fi
558
559echo $ac_n "checking host system type""... $ac_c" 1>&6
560
561host_alias=$host
562case "$host_alias" in
563NONE)
564 case $nonopt in
565 NONE)
566 if host_alias=`$ac_config_guess`; then :
567 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
568 fi ;;
569 *) host_alias=$nonopt ;;
570 esac ;;
571esac
572
573host=`$ac_config_sub $host_alias`
574host_cpu=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
575host_vendor=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
576host_os=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
577echo "$ac_t""$host" 1>&6
578
579echo $ac_n "checking target system type""... $ac_c" 1>&6
580
581target_alias=$target
582case "$target_alias" in
583NONE)
584 case $nonopt in
585 NONE) target_alias=$host_alias ;;
586 *) target_alias=$nonopt ;;
587 esac ;;
588esac
589
590target=`$ac_config_sub $target_alias`
591target_cpu=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
592target_vendor=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
593target_os=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
594echo "$ac_t""$target" 1>&6
595
596echo $ac_n "checking build system type""... $ac_c" 1>&6
597
598build_alias=$build
599case "$build_alias" in
600NONE)
601 case $nonopt in
602 NONE) build_alias=$host_alias ;;
603 *) build_alias=$nonopt ;;
604 esac ;;
605esac
606
607build=`$ac_config_sub $build_alias`
608build_cpu=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
609build_vendor=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
610build_os=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
611echo "$ac_t""$build" 1>&6
612
613test "$host_alias" != "$target_alias" &&
614 test "$program_prefix$program_suffix$program_transform_name" = \
615 NONENONEs,x,x, &&
616 program_prefix=${target_alias}-
617
618if test "$program_transform_name" = s,x,x,; then
619 program_transform_name=
620else
621 # Double any \ or $.
622 echo 's,\\,\\\\,g; s,\$,$$,g' > conftestsed
623 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
624 rm -f conftestsed
625fi
626test "$program_prefix" != NONE &&
627 program_transform_name="s,^,${program_prefix},; $program_transform_name"
628# Use a double $ so make ignores it.
629test "$program_suffix" != NONE &&
630 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
631
632# sed with no file args requires a program.
633test "$program_transform_name" = "" && program_transform_name="s,x,x,"
634
635
636. ${srcdir}/../../bfd/configure.host
637
638# Extract the first word of "gcc", so it can be a program name with args.
639set dummy gcc; ac_word=$2
640echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
641if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
642 echo $ac_n "(cached) $ac_c" 1>&6
643else
644 if test -n "$CC"; then
645 ac_cv_prog_CC="$CC" # Let the user override the test.
646else
647 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
648 for ac_dir in cc; do
649 test -z "$ac_dir" && ac_dir=.
650 if test -f $ac_dir/$ac_word; then
651 ac_cv_prog_CC="gcc"
652 break
653 fi
654 done
655 IFS="$ac_save_ifs"
656 test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc"
657fi
658fi
659CC="$ac_cv_prog_CC"
660if test -n "$CC"; then
661 echo "$ac_t""$CC" 1>&6
662else
663 echo "$ac_t""no" 1>&6
664fi
665
666
667echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
668if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
669 echo $ac_n "(cached) $ac_c" 1>&6
670else
671 cat > conftest.c <<EOF
672#ifdef __GNUC__
673 yes;
674#endif
675EOF
676if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then
677 ac_cv_prog_gcc=yes
678else
679 ac_cv_prog_gcc=no
680fi
681fi
682
683echo "$ac_t""$ac_cv_prog_gcc" 1>&6
684if test $ac_cv_prog_gcc = yes; then
685 GCC=yes
686 if test "${CFLAGS+set}" != set; then
687 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
688if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then
689 echo $ac_n "(cached) $ac_c" 1>&6
690else
691 echo 'void f(){}' > conftest.c
692if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
693 ac_cv_prog_gcc_g=yes
694else
695 ac_cv_prog_gcc_g=no
696fi
697rm -f conftest*
698
699fi
700
701echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6
702 if test $ac_cv_prog_gcc_g = yes; then
703 CFLAGS="-g -O"
704 else
705 CFLAGS="-O"
706 fi
707 fi
708else
709 GCC=
710 test "${CFLAGS+set}" = set || CFLAGS="-g"
711fi
712
713
714
715AR=${AR-ar}
716
717# Extract the first word of "ranlib", so it can be a program name with args.
718set dummy ranlib; ac_word=$2
719echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
720if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
721 echo $ac_n "(cached) $ac_c" 1>&6
722else
723 if test -n "$RANLIB"; then
724 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
725else
726 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
727 for ac_dir in :; do
728 test -z "$ac_dir" && ac_dir=.
729 if test -f $ac_dir/$ac_word; then
730 ac_cv_prog_RANLIB="ranlib"
731 break
732 fi
733 done
734 IFS="$ac_save_ifs"
735 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
736fi
737fi
738RANLIB="$ac_cv_prog_RANLIB"
739if test -n "$RANLIB"; then
740 echo "$ac_t""$RANLIB" 1>&6
741else
742 echo "$ac_t""no" 1>&6
743fi
744
745# Find a good install program. We prefer a C program (faster),
746# so one script is as good as another. But avoid the broken or
747# incompatible versions:
748# SysV /etc/install, /usr/sbin/install
749# SunOS /usr/etc/install
750# IRIX /sbin/install
751# AIX /bin/install
752# AFS /usr/afsws/bin/install, which mishandles nonexistent args
753# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
754# ./install, which can be erroneously created by make from ./install.sh.
755echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
756if test -z "$INSTALL"; then
757if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
758 echo $ac_n "(cached) $ac_c" 1>&6
759else
760 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
761 for ac_dir in $PATH; do
762 # Account for people who put trailing slashes in PATH elements.
763 case "$ac_dir/" in
764 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
765 *)
766 # OSF1 and SCO ODT 3.0 have their own names for install.
767 for ac_prog in ginstall installbsd scoinst install; do
768 if test -f $ac_dir/$ac_prog; then
769 if test $ac_prog = install &&
770 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
771 # AIX install. It has an incompatible calling convention.
772 # OSF/1 installbsd also uses dspmsg, but is usable.
773 :
774 else
775 ac_cv_path_install="$ac_dir/$ac_prog -c"
776 break 2
777 fi
778 fi
779 done
780 ;;
781 esac
782 done
783 IFS="$ac_save_ifs"
784
785fi
786 if test "${ac_cv_path_install+set}" = set; then
787 INSTALL="$ac_cv_path_install"
788 else
789 # As a last resort, use the slow shell script. We don't cache a
790 # path for INSTALL within a source directory, because that will
791 # break other packages using the cache if that directory is
792 # removed, or if the path is relative.
793 INSTALL="$ac_install_sh"
794 fi
795fi
796echo "$ac_t""$INSTALL" 1>&6
797
798# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
799# It thinks the first close brace ends the variable substitution.
800test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
801
802test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
803
804
805trap '' 1 2 15
806cat > confcache <<\EOF
807# This file is a shell script that caches the results of configure
808# tests run on this system so they can be shared between configure
809# scripts and configure runs. It is not useful on other systems.
810# If it contains results you don't want to keep, you may remove or edit it.
811#
812# By default, configure uses ./config.cache as the cache file,
813# creating it if it does not exist already. You can give configure
814# the --cache-file=FILE option to use a different cache file; that is
815# what configure does when it calls configure scripts in
816# subdirectories, so they share the cache.
817# Giving --cache-file=/dev/null disables caching, for debugging configure.
818# config.status only pays attention to the cache file if you give it the
819# --recheck option to rerun configure.
820#
821EOF
822# Ultrix sh set writes to stderr and can't be redirected directly,
823# and sets the high bit in the cache file unless we assign to the vars.
824(set) 2>&1 |
825 sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \
826 >> confcache
827if cmp -s $cache_file confcache; then
828 :
829else
830 if test -w $cache_file; then
831 echo "updating cache $cache_file"
832 cat confcache > $cache_file
833 else
834 echo "not updating unwritable cache $cache_file"
835 fi
836fi
837rm -f confcache
838
839trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
840
841test "x$prefix" = xNONE && prefix=$ac_default_prefix
842# Let make expand exec_prefix.
843test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
844
845# Any assignment to VPATH causes Sun make to only execute
846# the first set of double-colon rules, so remove it if not needed.
847# If there is a colon in the path, we need to keep it.
848if test "x$srcdir" = x.; then
849 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
850fi
851
852trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
853
854# Transform confdefs.h into DEFS.
855# Protect against shell expansion while executing Makefile rules.
856# Protect against Makefile macro expansion.
857cat > conftest.defs <<\EOF
858s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%-D\1=\2%g
859s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
860s%\[%\\&%g
861s%\]%\\&%g
862s%\$%$$%g
863EOF
864DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
865rm -f conftest.defs
866
867
868# Without the "./", some shells look in PATH for config.status.
869: ${CONFIG_STATUS=./config.status}
870
871echo creating $CONFIG_STATUS
872rm -f $CONFIG_STATUS
873cat > $CONFIG_STATUS <<EOF
874#! /bin/sh
875# Generated automatically by configure.
876# Run this file to recreate the current configuration.
877# This directory was configured as follows,
878# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
879#
880# $0 $ac_configure_args
881#
882# Compiler output produced by configure, useful for debugging
883# configure, is in ./config.log if it exists.
884
885ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
886for ac_option
887do
888 case "\$ac_option" in
889 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
890 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
891 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
892 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
893 echo "$CONFIG_STATUS generated by autoconf version 2.4.2"
894 exit 0 ;;
895 -help | --help | --hel | --he | --h)
896 echo "\$ac_cs_usage"; exit 0 ;;
897 *) echo "\$ac_cs_usage"; exit 1 ;;
898 esac
899done
900
901ac_given_srcdir=$srcdir
902ac_given_INSTALL="$INSTALL"
903
904trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
905
906# Protect against being on the right side of a sed subst in config.status.
907sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g;
908 s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF
909$ac_vpsub
910$extrasub
911s%@CFLAGS@%$CFLAGS%g
912s%@CPPFLAGS@%$CPPFLAGS%g
913s%@CXXFLAGS@%$CXXFLAGS%g
914s%@DEFS@%$DEFS%g
915s%@LDFLAGS@%$LDFLAGS%g
916s%@LIBS@%$LIBS%g
917s%@exec_prefix@%$exec_prefix%g
918s%@prefix@%$prefix%g
919s%@program_transform_name@%$program_transform_name%g
920s%@bindir@%$bindir%g
921s%@sbindir@%$sbindir%g
922s%@libexecdir@%$libexecdir%g
923s%@datadir@%$datadir%g
924s%@sysconfdir@%$sysconfdir%g
925s%@sharedstatedir@%$sharedstatedir%g
926s%@localstatedir@%$localstatedir%g
927s%@libdir@%$libdir%g
928s%@includedir@%$includedir%g
929s%@oldincludedir@%$oldincludedir%g
930s%@infodir@%$infodir%g
931s%@mandir@%$mandir%g
932s%@host@%$host%g
933s%@host_alias@%$host_alias%g
934s%@host_cpu@%$host_cpu%g
935s%@host_vendor@%$host_vendor%g
936s%@host_os@%$host_os%g
937s%@target@%$target%g
938s%@target_alias@%$target_alias%g
939s%@target_cpu@%$target_cpu%g
940s%@target_vendor@%$target_vendor%g
941s%@target_os@%$target_os%g
942s%@build@%$build%g
943s%@build_alias@%$build_alias%g
944s%@build_cpu@%$build_cpu%g
945s%@build_vendor@%$build_vendor%g
946s%@build_os@%$build_os%g
947s%@CC@%$CC%g
948s%@HDEFINES@%$HDEFINES%g
949s%@AR@%$AR%g
950s%@RANLIB@%$RANLIB%g
951s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
952s%@INSTALL_DATA@%$INSTALL_DATA%g
953
954CEOF
955EOF
956cat >> $CONFIG_STATUS <<EOF
957
958CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
959EOF
960cat >> $CONFIG_STATUS <<\EOF
961for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
962 # Support "outfile[:infile]", defaulting infile="outfile.in".
963 case "$ac_file" in
964 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
965 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
966 *) ac_file_in="${ac_file}.in" ;;
967 esac
968
969 # Adjust relative srcdir, etc. for subdirectories.
970
971 # Remove last slash and all that follows it. Not all systems have dirname.
972 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
973 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
974 # The file is in a subdirectory.
975 test ! -d "$ac_dir" && mkdir "$ac_dir"
976 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
977 # A "../" for each directory in $ac_dir_suffix.
978 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
979 else
980 ac_dir_suffix= ac_dots=
981 fi
982
983 case "$ac_given_srcdir" in
984 .) srcdir=.
985 if test -z "$ac_dots"; then top_srcdir=.
986 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
987 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
988 *) # Relative path.
989 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
990 top_srcdir="$ac_dots$ac_given_srcdir" ;;
991 esac
992
993 case "$ac_given_INSTALL" in
994 [/$]*) INSTALL="$ac_given_INSTALL" ;;
995 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
996 esac
997 echo creating "$ac_file"
998 rm -f "$ac_file"
999 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1000 case "$ac_file" in
1001 *Makefile*) ac_comsub="1i\\
1002# $configure_input" ;;
1003 *) ac_comsub= ;;
1004 esac
1005 sed -e "$ac_comsub
1006s%@configure_input@%$configure_input%g
1007s%@srcdir@%$srcdir%g
1008s%@top_srcdir@%$top_srcdir%g
1009s%@INSTALL@%$INSTALL%g
1010" -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
1011fi; done
1012rm -f conftest.subs
1013
1014
1015
1016exit 0
1017EOF
1018chmod +x $CONFIG_STATUS
1019rm -fr confdefs* $ac_clean_files
1020test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
1021
This page took 0.116108 seconds and 4 git commands to generate.