]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - sim/common/configure
Add a number of per-simulator options: hostendian, endian, inline, warnings.
[thirdparty/binutils-gdb.git] / sim / common / 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-sim-bswap Use Host specific BSWAP instruction."
16 ac_help="$ac_help
17 --enable-sim-cflags=opts Extra CFLAGS for use in building simulator"
18 ac_help="$ac_help
19 --enable-sim-debug=opts Enable debugging flags"
20 ac_help="$ac_help
21 --enable-sim-trace=opts Enable tracing flags"
22
23 # Initialize some variables set by options.
24 # The variables have the same names as the options, with
25 # dashes changed to underlines.
26 build=NONE
27 cache_file=./config.cache
28 exec_prefix=NONE
29 host=NONE
30 no_create=
31 nonopt=NONE
32 no_recursion=
33 prefix=NONE
34 program_prefix=NONE
35 program_suffix=NONE
36 program_transform_name=s,x,x,
37 silent=
38 site=
39 srcdir=
40 target=NONE
41 verbose=
42 x_includes=NONE
43 x_libraries=NONE
44 bindir='${exec_prefix}/bin'
45 sbindir='${exec_prefix}/sbin'
46 libexecdir='${exec_prefix}/libexec'
47 datadir='${prefix}/share'
48 sysconfdir='${prefix}/etc'
49 sharedstatedir='${prefix}/com'
50 localstatedir='${prefix}/var'
51 libdir='${exec_prefix}/lib'
52 includedir='${prefix}/include'
53 oldincludedir='/usr/include'
54 infodir='${prefix}/info'
55 mandir='${prefix}/man'
56
57 # Initialize some other variables.
58 subdirs=
59 MFLAGS= MAKEFLAGS=
60
61 ac_prev=
62 for ac_option
63 do
64
65 # If the previous option needs an argument, assign it.
66 if test -n "$ac_prev"; then
67 eval "$ac_prev=\$ac_option"
68 ac_prev=
69 continue
70 fi
71
72 case "$ac_option" in
73 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
74 *) ac_optarg= ;;
75 esac
76
77 # Accept the important Cygnus configure options, so we can diagnose typos.
78
79 case "$ac_option" in
80
81 -bindir | --bindir | --bindi | --bind | --bin | --bi)
82 ac_prev=bindir ;;
83 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
84 bindir="$ac_optarg" ;;
85
86 -build | --build | --buil | --bui | --bu)
87 ac_prev=build ;;
88 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
89 build="$ac_optarg" ;;
90
91 -cache-file | --cache-file | --cache-fil | --cache-fi \
92 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
93 ac_prev=cache_file ;;
94 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
95 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
96 cache_file="$ac_optarg" ;;
97
98 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
99 ac_prev=datadir ;;
100 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
101 | --da=*)
102 datadir="$ac_optarg" ;;
103
104 -disable-* | --disable-*)
105 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
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 eval "enable_${ac_feature}=no" ;;
112
113 -enable-* | --enable-*)
114 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
115 # Reject names that are not valid shell variable names.
116 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
117 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
118 fi
119 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
120 case "$ac_option" in
121 *=*) ;;
122 *) ac_optarg=yes ;;
123 esac
124 eval "enable_${ac_feature}='$ac_optarg'" ;;
125
126 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
127 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
128 | --exec | --exe | --ex)
129 ac_prev=exec_prefix ;;
130 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
131 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
132 | --exec=* | --exe=* | --ex=*)
133 exec_prefix="$ac_optarg" ;;
134
135 -gas | --gas | --ga | --g)
136 # Obsolete; use --with-gas.
137 with_gas=yes ;;
138
139 -help | --help | --hel | --he)
140 # Omit some internal or obsolete options to make the list less imposing.
141 # This message is too long to be a string in the A/UX 3.1 sh.
142 cat << EOF
143 Usage: configure [options] [host]
144 Options: [defaults in brackets after descriptions]
145 Configuration:
146 --cache-file=FILE cache test results in FILE
147 --help print this message
148 --no-create do not create output files
149 --quiet, --silent do not print \`checking...' messages
150 --version print the version of autoconf that created configure
151 Directory and file names:
152 --prefix=PREFIX install architecture-independent files in PREFIX
153 [$ac_default_prefix]
154 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
155 [same as prefix]
156 --bindir=DIR user executables in DIR [EPREFIX/bin]
157 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
158 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
159 --datadir=DIR read-only architecture-independent data in DIR
160 [PREFIX/share]
161 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
162 --sharedstatedir=DIR modifiable architecture-independent data in DIR
163 [PREFIX/com]
164 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
165 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
166 --includedir=DIR C header files in DIR [PREFIX/include]
167 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
168 --infodir=DIR info documentation in DIR [PREFIX/info]
169 --mandir=DIR man documentation in DIR [PREFIX/man]
170 --srcdir=DIR find the sources in DIR [configure dir or ..]
171 --program-prefix=PREFIX prepend PREFIX to installed program names
172 --program-suffix=SUFFIX append SUFFIX to installed program names
173 --program-transform-name=PROGRAM
174 run sed PROGRAM on installed program names
175 EOF
176 cat << EOF
177 Host type:
178 --build=BUILD configure for building on BUILD [BUILD=HOST]
179 --host=HOST configure for HOST [guessed]
180 --target=TARGET configure for TARGET [TARGET=HOST]
181 Features and packages:
182 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
183 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
184 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
185 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
186 --x-includes=DIR X include files are in DIR
187 --x-libraries=DIR X library files are in DIR
188 EOF
189 if test -n "$ac_help"; then
190 echo "--enable and --with options recognized:$ac_help"
191 fi
192 exit 0 ;;
193
194 -host | --host | --hos | --ho)
195 ac_prev=host ;;
196 -host=* | --host=* | --hos=* | --ho=*)
197 host="$ac_optarg" ;;
198
199 -includedir | --includedir | --includedi | --included | --include \
200 | --includ | --inclu | --incl | --inc)
201 ac_prev=includedir ;;
202 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
203 | --includ=* | --inclu=* | --incl=* | --inc=*)
204 includedir="$ac_optarg" ;;
205
206 -infodir | --infodir | --infodi | --infod | --info | --inf)
207 ac_prev=infodir ;;
208 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
209 infodir="$ac_optarg" ;;
210
211 -libdir | --libdir | --libdi | --libd)
212 ac_prev=libdir ;;
213 -libdir=* | --libdir=* | --libdi=* | --libd=*)
214 libdir="$ac_optarg" ;;
215
216 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
217 | --libexe | --libex | --libe)
218 ac_prev=libexecdir ;;
219 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
220 | --libexe=* | --libex=* | --libe=*)
221 libexecdir="$ac_optarg" ;;
222
223 -localstatedir | --localstatedir | --localstatedi | --localstated \
224 | --localstate | --localstat | --localsta | --localst \
225 | --locals | --local | --loca | --loc | --lo)
226 ac_prev=localstatedir ;;
227 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
228 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
229 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
230 localstatedir="$ac_optarg" ;;
231
232 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
233 ac_prev=mandir ;;
234 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
235 mandir="$ac_optarg" ;;
236
237 -nfp | --nfp | --nf)
238 # Obsolete; use --without-fp.
239 with_fp=no ;;
240
241 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
242 | --no-cr | --no-c)
243 no_create=yes ;;
244
245 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
246 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
247 no_recursion=yes ;;
248
249 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
250 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
251 | --oldin | --oldi | --old | --ol | --o)
252 ac_prev=oldincludedir ;;
253 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
254 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
255 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
256 oldincludedir="$ac_optarg" ;;
257
258 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
259 ac_prev=prefix ;;
260 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
261 prefix="$ac_optarg" ;;
262
263 -program-prefix | --program-prefix | --program-prefi | --program-pref \
264 | --program-pre | --program-pr | --program-p)
265 ac_prev=program_prefix ;;
266 -program-prefix=* | --program-prefix=* | --program-prefi=* \
267 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
268 program_prefix="$ac_optarg" ;;
269
270 -program-suffix | --program-suffix | --program-suffi | --program-suff \
271 | --program-suf | --program-su | --program-s)
272 ac_prev=program_suffix ;;
273 -program-suffix=* | --program-suffix=* | --program-suffi=* \
274 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
275 program_suffix="$ac_optarg" ;;
276
277 -program-transform-name | --program-transform-name \
278 | --program-transform-nam | --program-transform-na \
279 | --program-transform-n | --program-transform- \
280 | --program-transform | --program-transfor \
281 | --program-transfo | --program-transf \
282 | --program-trans | --program-tran \
283 | --progr-tra | --program-tr | --program-t)
284 ac_prev=program_transform_name ;;
285 -program-transform-name=* | --program-transform-name=* \
286 | --program-transform-nam=* | --program-transform-na=* \
287 | --program-transform-n=* | --program-transform-=* \
288 | --program-transform=* | --program-transfor=* \
289 | --program-transfo=* | --program-transf=* \
290 | --program-trans=* | --program-tran=* \
291 | --progr-tra=* | --program-tr=* | --program-t=*)
292 program_transform_name="$ac_optarg" ;;
293
294 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
295 | -silent | --silent | --silen | --sile | --sil)
296 silent=yes ;;
297
298 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
299 ac_prev=sbindir ;;
300 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
301 | --sbi=* | --sb=*)
302 sbindir="$ac_optarg" ;;
303
304 -sharedstatedir | --sharedstatedir | --sharedstatedi \
305 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
306 | --sharedst | --shareds | --shared | --share | --shar \
307 | --sha | --sh)
308 ac_prev=sharedstatedir ;;
309 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
310 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
311 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
312 | --sha=* | --sh=*)
313 sharedstatedir="$ac_optarg" ;;
314
315 -site | --site | --sit)
316 ac_prev=site ;;
317 -site=* | --site=* | --sit=*)
318 site="$ac_optarg" ;;
319
320 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
321 ac_prev=srcdir ;;
322 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
323 srcdir="$ac_optarg" ;;
324
325 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
326 | --syscon | --sysco | --sysc | --sys | --sy)
327 ac_prev=sysconfdir ;;
328 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
329 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
330 sysconfdir="$ac_optarg" ;;
331
332 -target | --target | --targe | --targ | --tar | --ta | --t)
333 ac_prev=target ;;
334 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
335 target="$ac_optarg" ;;
336
337 -v | -verbose | --verbose | --verbos | --verbo | --verb)
338 verbose=yes ;;
339
340 -version | --version | --versio | --versi | --vers)
341 echo "configure generated by autoconf version 2.10"
342 exit 0 ;;
343
344 -with-* | --with-*)
345 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
346 # Reject names that are not valid shell variable names.
347 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
348 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
349 fi
350 ac_package=`echo $ac_package| sed 's/-/_/g'`
351 case "$ac_option" in
352 *=*) ;;
353 *) ac_optarg=yes ;;
354 esac
355 eval "with_${ac_package}='$ac_optarg'" ;;
356
357 -without-* | --without-*)
358 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
359 # Reject names that are not valid shell variable names.
360 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
361 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
362 fi
363 ac_package=`echo $ac_package| sed 's/-/_/g'`
364 eval "with_${ac_package}=no" ;;
365
366 --x)
367 # Obsolete; use --with-x.
368 with_x=yes ;;
369
370 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
371 | --x-incl | --x-inc | --x-in | --x-i)
372 ac_prev=x_includes ;;
373 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
374 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
375 x_includes="$ac_optarg" ;;
376
377 -x-libraries | --x-libraries | --x-librarie | --x-librari \
378 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
379 ac_prev=x_libraries ;;
380 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
381 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
382 x_libraries="$ac_optarg" ;;
383
384 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
385 ;;
386
387 *)
388 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
389 echo "configure: warning: $ac_option: invalid host type" 1>&2
390 fi
391 if test "x$nonopt" != xNONE; then
392 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
393 fi
394 nonopt="$ac_option"
395 ;;
396
397 esac
398 done
399
400 if test -n "$ac_prev"; then
401 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
402 fi
403
404 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
405
406 # File descriptor usage:
407 # 0 standard input
408 # 1 file creation
409 # 2 errors and warnings
410 # 3 some systems may open it to /dev/tty
411 # 4 used on the Kubota Titan
412 # 6 checking for... messages and results
413 # 5 compiler messages saved in config.log
414 if test "$silent" = yes; then
415 exec 6>/dev/null
416 else
417 exec 6>&1
418 fi
419 exec 5>./config.log
420
421 echo "\
422 This file contains any messages produced by compilers while
423 running configure, to aid debugging if configure makes a mistake.
424 " 1>&5
425
426 # Strip out --no-create and --no-recursion so they do not pile up.
427 # Also quote any args containing shell metacharacters.
428 ac_configure_args=
429 for ac_arg
430 do
431 case "$ac_arg" in
432 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
433 | --no-cr | --no-c) ;;
434 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
435 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
436 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
437 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
438 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
439 esac
440 done
441
442 # NLS nuisances.
443 # Only set LANG and LC_ALL to C if already set.
444 # These must not be set unconditionally because not all systems understand
445 # e.g. LANG=C (notably SCO).
446 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
447 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
448
449 # confdefs.h avoids OS command line length limits that DEFS can exceed.
450 rm -rf conftest* confdefs.h
451 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
452 echo > confdefs.h
453
454 # A filename unique to this package, relative to the directory that
455 # configure is in, which we can look for to find out if srcdir is correct.
456 ac_unique_file=Makefile.in
457
458 # Find the source files, if location was not specified.
459 if test -z "$srcdir"; then
460 ac_srcdir_defaulted=yes
461 # Try the directory containing this script, then its parent.
462 ac_prog=$0
463 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
464 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
465 srcdir=$ac_confdir
466 if test ! -r $srcdir/$ac_unique_file; then
467 srcdir=..
468 fi
469 else
470 ac_srcdir_defaulted=no
471 fi
472 if test ! -r $srcdir/$ac_unique_file; then
473 if test "$ac_srcdir_defaulted" = yes; then
474 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
475 else
476 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
477 fi
478 fi
479 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
480
481 # Prefer explicitly selected file to automatically selected ones.
482 if test -z "$CONFIG_SITE"; then
483 if test "x$prefix" != xNONE; then
484 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
485 else
486 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
487 fi
488 fi
489 for ac_site_file in $CONFIG_SITE; do
490 if test -r "$ac_site_file"; then
491 echo "loading site script $ac_site_file"
492 . "$ac_site_file"
493 fi
494 done
495
496 if test -r "$cache_file"; then
497 echo "loading cache $cache_file"
498 . $cache_file
499 else
500 echo "creating cache $cache_file"
501 > $cache_file
502 fi
503
504 ac_ext=c
505 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
506 ac_cpp='$CPP $CPPFLAGS'
507 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
508 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
509
510 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
511 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
512 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
513 ac_n= ac_c='
514 ' ac_t=' '
515 else
516 ac_n=-n ac_c= ac_t=
517 fi
518 else
519 ac_n= ac_c='\c' ac_t=
520 fi
521
522
523
524 # This is intended for use by the target specific directories, and by us.
525
526 # autoconf.info says this should be called right after AC_INIT.
527
528
529 ac_aux_dir=
530 for ac_dir in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../..; do
531 if test -f $ac_dir/install-sh; then
532 ac_aux_dir=$ac_dir
533 ac_install_sh="$ac_aux_dir/install-sh -c"
534 break
535 elif test -f $ac_dir/install.sh; then
536 ac_aux_dir=$ac_dir
537 ac_install_sh="$ac_aux_dir/install.sh -c"
538 break
539 fi
540 done
541 if test -z "$ac_aux_dir"; then
542 { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../.." 1>&2; exit 1; }
543 fi
544 ac_config_guess=$ac_aux_dir/config.guess
545 ac_config_sub=$ac_aux_dir/config.sub
546 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
547
548
549 # Do some error checking and defaulting for the host and target type.
550 # The inputs are:
551 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
552 #
553 # The rules are:
554 # 1. You are not allowed to specify --host, --target, and nonopt at the
555 # same time.
556 # 2. Host defaults to nonopt.
557 # 3. If nonopt is not specified, then host defaults to the current host,
558 # as determined by config.guess.
559 # 4. Target and build default to nonopt.
560 # 5. If nonopt is not specified, then target and build default to host.
561
562 # The aliases save the names the user supplied, while $host etc.
563 # will get canonicalized.
564 case $host---$target---$nonopt in
565 NONE---*---* | *---NONE---* | *---*---NONE) ;;
566 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
567 esac
568
569
570 # Make sure we can run config.sub.
571 if $ac_config_sub sun4 >/dev/null 2>&1; then :
572 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
573 fi
574
575 echo $ac_n "checking host system type""... $ac_c" 1>&6
576
577 host_alias=$host
578 case "$host_alias" in
579 NONE)
580 case $nonopt in
581 NONE)
582 if host_alias=`$ac_config_guess`; then :
583 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
584 fi ;;
585 *) host_alias=$nonopt ;;
586 esac ;;
587 esac
588
589 host=`$ac_config_sub $host_alias`
590 host_cpu=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
591 host_vendor=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
592 host_os=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
593 echo "$ac_t""$host" 1>&6
594
595 echo $ac_n "checking target system type""... $ac_c" 1>&6
596
597 target_alias=$target
598 case "$target_alias" in
599 NONE)
600 case $nonopt in
601 NONE) target_alias=$host_alias ;;
602 *) target_alias=$nonopt ;;
603 esac ;;
604 esac
605
606 target=`$ac_config_sub $target_alias`
607 target_cpu=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
608 target_vendor=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
609 target_os=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
610 echo "$ac_t""$target" 1>&6
611
612 echo $ac_n "checking build system type""... $ac_c" 1>&6
613
614 build_alias=$build
615 case "$build_alias" in
616 NONE)
617 case $nonopt in
618 NONE) build_alias=$host_alias ;;
619 *) build_alias=$nonopt ;;
620 esac ;;
621 esac
622
623 build=`$ac_config_sub $build_alias`
624 build_cpu=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
625 build_vendor=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
626 build_os=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
627 echo "$ac_t""$build" 1>&6
628
629 test "$host_alias" != "$target_alias" &&
630 test "$program_prefix$program_suffix$program_transform_name" = \
631 NONENONEs,x,x, &&
632 program_prefix=${target_alias}-
633
634 if test "$program_transform_name" = s,x,x,; then
635 program_transform_name=
636 else
637 # Double any \ or $. echo might interpret backslashes.
638 cat <<\EOF_SED > conftestsed
639 s,\\,\\\\,g; s,\$,$$,g
640 EOF_SED
641 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
642 rm -f conftestsed
643 fi
644 test "$program_prefix" != NONE &&
645 program_transform_name="s,^,${program_prefix},; $program_transform_name"
646 # Use a double $ so make ignores it.
647 test "$program_suffix" != NONE &&
648 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
649
650 # sed with no file args requires a program.
651 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
652
653 # Extract the first word of "gcc", so it can be a program name with args.
654 set dummy gcc; ac_word=$2
655 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
656 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
657 echo $ac_n "(cached) $ac_c" 1>&6
658 else
659 if test -n "$CC"; then
660 ac_cv_prog_CC="$CC" # Let the user override the test.
661 else
662 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
663 for ac_dir in $PATH; do
664 test -z "$ac_dir" && ac_dir=.
665 if test -f $ac_dir/$ac_word; then
666 ac_cv_prog_CC="gcc"
667 break
668 fi
669 done
670 IFS="$ac_save_ifs"
671 fi
672 fi
673 CC="$ac_cv_prog_CC"
674 if test -n "$CC"; then
675 echo "$ac_t""$CC" 1>&6
676 else
677 echo "$ac_t""no" 1>&6
678 fi
679
680 if test -z "$CC"; then
681 # Extract the first word of "cc", so it can be a program name with args.
682 set dummy cc; ac_word=$2
683 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
684 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
685 echo $ac_n "(cached) $ac_c" 1>&6
686 else
687 if test -n "$CC"; then
688 ac_cv_prog_CC="$CC" # Let the user override the test.
689 else
690 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
691 ac_prog_rejected=no
692 for ac_dir in $PATH; do
693 test -z "$ac_dir" && ac_dir=.
694 if test -f $ac_dir/$ac_word; then
695 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
696 ac_prog_rejected=yes
697 continue
698 fi
699 ac_cv_prog_CC="cc"
700 break
701 fi
702 done
703 IFS="$ac_save_ifs"
704 if test $ac_prog_rejected = yes; then
705 # We found a bogon in the path, so make sure we never use it.
706 set dummy $ac_cv_prog_CC
707 shift
708 if test $# -gt 0; then
709 # We chose a different compiler from the bogus one.
710 # However, it has the same basename, so the bogon will be chosen
711 # first if we set CC to just the basename; use the full file name.
712 shift
713 set dummy "$ac_dir/$ac_word" "$@"
714 shift
715 ac_cv_prog_CC="$@"
716 fi
717 fi
718 fi
719 fi
720 CC="$ac_cv_prog_CC"
721 if test -n "$CC"; then
722 echo "$ac_t""$CC" 1>&6
723 else
724 echo "$ac_t""no" 1>&6
725 fi
726
727 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
728 fi
729
730 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
731 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
732 echo $ac_n "(cached) $ac_c" 1>&6
733 else
734 cat > conftest.c <<EOF
735 #ifdef __GNUC__
736 yes;
737 #endif
738 EOF
739 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:740: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
740 ac_cv_prog_gcc=yes
741 else
742 ac_cv_prog_gcc=no
743 fi
744 fi
745
746 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
747 if test $ac_cv_prog_gcc = yes; then
748 GCC=yes
749 if test "${CFLAGS+set}" != set; then
750 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
751 if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then
752 echo $ac_n "(cached) $ac_c" 1>&6
753 else
754 echo 'void f(){}' > conftest.c
755 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
756 ac_cv_prog_gcc_g=yes
757 else
758 ac_cv_prog_gcc_g=no
759 fi
760 rm -f conftest*
761
762 fi
763
764 echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6
765 if test $ac_cv_prog_gcc_g = yes; then
766 CFLAGS="-g -O"
767 else
768 CFLAGS="-O"
769 fi
770 fi
771 else
772 GCC=
773 test "${CFLAGS+set}" = set || CFLAGS="-g"
774 fi
775
776 # Find a good install program. We prefer a C program (faster),
777 # so one script is as good as another. But avoid the broken or
778 # incompatible versions:
779 # SysV /etc/install, /usr/sbin/install
780 # SunOS /usr/etc/install
781 # IRIX /sbin/install
782 # AIX /bin/install
783 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
784 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
785 # ./install, which can be erroneously created by make from ./install.sh.
786 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
787 if test -z "$INSTALL"; then
788 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
789 echo $ac_n "(cached) $ac_c" 1>&6
790 else
791 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
792 for ac_dir in $PATH; do
793 # Account for people who put trailing slashes in PATH elements.
794 case "$ac_dir/" in
795 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
796 *)
797 # OSF1 and SCO ODT 3.0 have their own names for install.
798 for ac_prog in ginstall installbsd scoinst install; do
799 if test -f $ac_dir/$ac_prog; then
800 if test $ac_prog = install &&
801 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
802 # AIX install. It has an incompatible calling convention.
803 # OSF/1 installbsd also uses dspmsg, but is usable.
804 :
805 else
806 ac_cv_path_install="$ac_dir/$ac_prog -c"
807 break 2
808 fi
809 fi
810 done
811 ;;
812 esac
813 done
814 IFS="$ac_save_ifs"
815
816 fi
817 if test "${ac_cv_path_install+set}" = set; then
818 INSTALL="$ac_cv_path_install"
819 else
820 # As a last resort, use the slow shell script. We don't cache a
821 # path for INSTALL within a source directory, because that will
822 # break other packages using the cache if that directory is
823 # removed, or if the path is relative.
824 INSTALL="$ac_install_sh"
825 fi
826 fi
827 echo "$ac_t""$INSTALL" 1>&6
828
829 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
830 # It thinks the first close brace ends the variable substitution.
831 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
832
833 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
834
835
836 # Put a plausible default for CC_FOR_BUILD in Makefile.
837 # If we cannot run a trivial program, we must be cross compiling.
838 echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6
839 if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then
840 echo $ac_n "(cached) $ac_c" 1>&6
841 else
842 if test "$cross_compiling" = yes; then
843 ac_cv_c_cross=yes
844 else
845 cat > conftest.$ac_ext <<EOF
846 #line 847 "configure"
847 #include "confdefs.h"
848 main(){return(0);}
849 EOF
850 { (eval echo configure:851: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }
851 if test -s conftest && (./conftest; exit) 2>/dev/null; then
852 ac_cv_c_cross=no
853 else
854 ac_cv_c_cross=yes
855 fi
856 fi
857 rm -fr conftest*
858 fi
859
860 echo "$ac_t""$ac_cv_c_cross" 1>&6
861 cross_compiling=$ac_cv_c_cross
862
863 if test "x$cross_compiling" = "xno"; then
864 CC_FOR_BUILD='$(CC)'
865 else
866 CC_FOR_BUILD=gcc
867 fi
868
869
870
871
872 AR=${AR-ar}
873
874 # Extract the first word of "ranlib", so it can be a program name with args.
875 set dummy ranlib; ac_word=$2
876 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
877 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
878 echo $ac_n "(cached) $ac_c" 1>&6
879 else
880 if test -n "$RANLIB"; then
881 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
882 else
883 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
884 for ac_dir in $PATH; do
885 test -z "$ac_dir" && ac_dir=.
886 if test -f $ac_dir/$ac_word; then
887 ac_cv_prog_RANLIB="ranlib"
888 break
889 fi
890 done
891 IFS="$ac_save_ifs"
892 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
893 fi
894 fi
895 RANLIB="$ac_cv_prog_RANLIB"
896 if test -n "$RANLIB"; then
897 echo "$ac_t""$RANLIB" 1>&6
898 else
899 echo "$ac_t""no" 1>&6
900 fi
901
902
903 . ${srcdir}/../../bfd/configure.host
904
905
906
907 # Check whether --enable-sim-bswap or --disable-sim-bswap was given.
908 if test "${enable_sim_bswap+set}" = set; then
909 enableval="$enable_sim_bswap"
910 case "${enableval}" in
911 yes) sim_bswap="-DWITH_BSWAP=1 -DUSE_BSWAP";;
912 no) sim_bswap="-DWITH_BSWAP=0";;
913 *) { echo "configure: error: "--enable-sim-bswap does not take a value"" 1>&2; exit 1; }; sim_bswap="";;
914 esac
915 if test x"$silent" != x"yes" && test x"$sim_bswap" != x""; then
916 echo "Setting bswap flags = $sim_bswap" 6>&1
917 fi
918 else
919 sim_bswap=""
920 fi
921
922
923
924 # Check whether --enable-sim-cflags or --disable-sim-cflags was given.
925 if test "${enable_sim_cflags+set}" = set; then
926 enableval="$enable_sim_cflags"
927 case "${enableval}" in
928 yes) sim_cflags="-O2";;
929 trace) { echo "configure: error: "Please use --enable-sim-debug instead."" 1>&2; exit 1; }; sim_cflags="";;
930 no) sim_cflags="";;
931 *) sim_cflags=`echo "${enableval}" | sed -e "s/,/ /g"`;;
932 esac
933 if test x"$silent" != x"yes" && test x"$sim_cflags" != x""; then
934 echo "Setting sim cflags = $sim_cflags" 6>&1
935 fi
936 else
937 sim_cflags=""
938 fi
939
940
941
942 # Check whether --enable-sim-debug or --disable-sim-debug was given.
943 if test "${enable_sim_debug+set}" = set; then
944 enableval="$enable_sim_debug"
945 case "${enableval}" in
946 yes) sim_debug="-DDEBUG=7";;
947 no) sim_debug="-DDEBUG=0";;
948 *) sim_debug="-DDEBUG='(${enableval})'";;
949 esac
950 if test x"$silent" != x"yes" && test x"$sim_debug" != x""; then
951 echo "Setting sim debug = $sim_debug" 6>&1
952 fi
953 else
954 sim_debug=""
955 fi
956
957
958
959 # Check whether --enable-sim-trace or --disable-sim-trace was given.
960 if test "${enable_sim_trace+set}" = set; then
961 enableval="$enable_sim_trace"
962 case "${enableval}" in
963 yes) sim_trace="-DTRACE=1";;
964 no) sim_trace="-DTRACE=0";;
965 *) sim_trace="-DTRACE='(${enableval})'";;
966 esac
967 if test x"$silent" != x"yes" && test x"$sim_trace" != x""; then
968 echo "Setting sim trace = $sim_trace" 6>&1
969 fi
970 else
971 sim_trace=""
972 fi
973
974
975
976 sim_link_files=
977 sim_link_links=
978
979 sim_link_links=tconfig.h
980 if test -f ${srcdir}/tconfig.in
981 then
982 sim_link_files=tconfig.in
983 else
984 sim_link_files=../common/tconfig.in
985 fi
986
987 # targ-vals.def points to the libc macro description file.
988 case "${target}" in
989 *-*-*) TARG_VALS_DEF=../common/nltvals.def ;;
990 esac
991 sim_link_files="${sim_link_files} ${TARG_VALS_DEF}"
992 sim_link_links="${sim_link_links} targ-vals.def"
993
994
995
996 # Put a useful copy of CPP_FOR_TARGET in Makefile.
997 # This is only used to build the target values header files. These files are
998 # shipped with distributions so CPP_FOR_TARGET only needs to work in
999 # developer's trees. This value is borrowed from ../../Makefile.in.
1000 CPP_FOR_TARGET="\` \
1001 if test -f \$\${rootme}/../../gcc/Makefile ; then \
1002 if test -f \$\${rootme}/../../\$(TARGET_SUBDIR)/newlib/Makefile ; then \
1003 echo \$\${rootme}/../../gcc/xgcc -B\$\${rootme}/../../gcc/ -idirafter \$\${rootme}/../../\$(TARGET_SUBDIR)/newlib/targ-include -idirafter \$(srcroot)/newlib/libc/include -nostdinc; \
1004 else \
1005 echo \$\${rootme}/../../gcc/xgcc -B\$\${rootme}/../../gcc/; \
1006 fi; \
1007 else \
1008 if test '\$(host_canonical)' = '\$(target_canonical)' ; then \
1009 echo \$(CC); \
1010 else \
1011 t='\$(program_transform_name)'; echo gcc | sed -e 's/x/x/' \$\$t; \
1012 fi; \
1013 fi\` -E"
1014
1015
1016 # Set TARGET_SUBDIR, needed by CPP_FOR_TARGET.
1017 if test x"${host}" = x"${target}" ; then
1018 TARGET_SUBDIR="."
1019 else
1020 TARGET_SUBDIR=${target_alias}
1021 fi
1022
1023
1024 # These aren't all needed yet, but will be eventually.
1025 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1026 # On Suns, sometimes $CPP names a directory.
1027 if test -n "$CPP" && test -d "$CPP"; then
1028 CPP=
1029 fi
1030 if test -z "$CPP"; then
1031 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1032 echo $ac_n "(cached) $ac_c" 1>&6
1033 else
1034 # This must be in double quotes, not single quotes, because CPP may get
1035 # substituted into the Makefile and "${CC-cc}" will confuse make.
1036 CPP="${CC-cc} -E"
1037 # On the NeXT, cc -E runs the code through the compiler's parser,
1038 # not just through cpp.
1039 cat > conftest.$ac_ext <<EOF
1040 #line 1041 "configure"
1041 #include "confdefs.h"
1042 #include <assert.h>
1043 Syntax Error
1044 EOF
1045 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1046 { (eval echo configure:1047: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1047 ac_err=`grep -v '^ *+' conftest.out`
1048 if test -z "$ac_err"; then
1049 :
1050 else
1051 echo "$ac_err" >&5
1052 rm -rf conftest*
1053 CPP="${CC-cc} -E -traditional-cpp"
1054 cat > conftest.$ac_ext <<EOF
1055 #line 1056 "configure"
1056 #include "confdefs.h"
1057 #include <assert.h>
1058 Syntax Error
1059 EOF
1060 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1061 { (eval echo configure:1062: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1062 ac_err=`grep -v '^ *+' conftest.out`
1063 if test -z "$ac_err"; then
1064 :
1065 else
1066 echo "$ac_err" >&5
1067 rm -rf conftest*
1068 CPP=/lib/cpp
1069 fi
1070 rm -f conftest*
1071 fi
1072 rm -f conftest*
1073 ac_cv_prog_CPP="$CPP"
1074 fi
1075 CPP="$ac_cv_prog_CPP"
1076 else
1077 ac_cv_prog_CPP="$CPP"
1078 fi
1079 echo "$ac_t""$CPP" 1>&6
1080
1081 for ac_hdr in stdlib.h string.h strings.h time.h sys/times.h
1082 do
1083 ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
1084 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1085 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1086 echo $ac_n "(cached) $ac_c" 1>&6
1087 else
1088 cat > conftest.$ac_ext <<EOF
1089 #line 1090 "configure"
1090 #include "confdefs.h"
1091 #include <$ac_hdr>
1092 EOF
1093 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1094 { (eval echo configure:1095: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1095 ac_err=`grep -v '^ *+' conftest.out`
1096 if test -z "$ac_err"; then
1097 rm -rf conftest*
1098 eval "ac_cv_header_$ac_safe=yes"
1099 else
1100 echo "$ac_err" >&5
1101 rm -rf conftest*
1102 eval "ac_cv_header_$ac_safe=no"
1103 fi
1104 rm -f conftest*
1105 fi
1106 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1107 echo "$ac_t""yes" 1>&6
1108 ac_tr_hdr=HAVE_`echo $ac_hdr | tr 'abcdefghijklmnopqrstuvwxyz./\055' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ___'`
1109 cat >> confdefs.h <<EOF
1110 #define $ac_tr_hdr 1
1111 EOF
1112
1113 else
1114 echo "$ac_t""no" 1>&6
1115 fi
1116 done
1117
1118
1119 trap '' 1 2 15
1120 cat > confcache <<\EOF
1121 # This file is a shell script that caches the results of configure
1122 # tests run on this system so they can be shared between configure
1123 # scripts and configure runs. It is not useful on other systems.
1124 # If it contains results you don't want to keep, you may remove or edit it.
1125 #
1126 # By default, configure uses ./config.cache as the cache file,
1127 # creating it if it does not exist already. You can give configure
1128 # the --cache-file=FILE option to use a different cache file; that is
1129 # what configure does when it calls configure scripts in
1130 # subdirectories, so they share the cache.
1131 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1132 # config.status only pays attention to the cache file if you give it the
1133 # --recheck option to rerun configure.
1134 #
1135 EOF
1136 # Ultrix sh set writes to stderr and can't be redirected directly,
1137 # and sets the high bit in the cache file unless we assign to the vars.
1138 (set) 2>&1 |
1139 sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \
1140 >> confcache
1141 if cmp -s $cache_file confcache; then
1142 :
1143 else
1144 if test -w $cache_file; then
1145 echo "updating cache $cache_file"
1146 cat confcache > $cache_file
1147 else
1148 echo "not updating unwritable cache $cache_file"
1149 fi
1150 fi
1151 rm -f confcache
1152
1153 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
1154
1155 test "x$prefix" = xNONE && prefix=$ac_default_prefix
1156 # Let make expand exec_prefix.
1157 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1158
1159 # Any assignment to VPATH causes Sun make to only execute
1160 # the first set of double-colon rules, so remove it if not needed.
1161 # If there is a colon in the path, we need to keep it.
1162 if test "x$srcdir" = x.; then
1163 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
1164 fi
1165
1166 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1167
1168 DEFS=-DHAVE_CONFIG_H
1169
1170 # Without the "./", some shells look in PATH for config.status.
1171 : ${CONFIG_STATUS=./config.status}
1172
1173 echo creating $CONFIG_STATUS
1174 rm -f $CONFIG_STATUS
1175 cat > $CONFIG_STATUS <<EOF
1176 #! /bin/sh
1177 # Generated automatically by configure.
1178 # Run this file to recreate the current configuration.
1179 # This directory was configured as follows,
1180 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1181 #
1182 # $0 $ac_configure_args
1183 #
1184 # Compiler output produced by configure, useful for debugging
1185 # configure, is in ./config.log if it exists.
1186
1187 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1188 for ac_option
1189 do
1190 case "\$ac_option" in
1191 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1192 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1193 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1194 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
1195 echo "$CONFIG_STATUS generated by autoconf version 2.10"
1196 exit 0 ;;
1197 -help | --help | --hel | --he | --h)
1198 echo "\$ac_cs_usage"; exit 0 ;;
1199 *) echo "\$ac_cs_usage"; exit 1 ;;
1200 esac
1201 done
1202
1203 ac_given_srcdir=$srcdir
1204 ac_given_INSTALL="$INSTALL"
1205
1206 trap 'rm -fr `echo "Makefile config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
1207 EOF
1208 cat >> $CONFIG_STATUS <<EOF
1209
1210 # Protect against being on the right side of a sed subst in config.status.
1211 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
1212 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
1213 $ac_vpsub
1214 $extrasub
1215 s%@CFLAGS@%$CFLAGS%g
1216 s%@CPPFLAGS@%$CPPFLAGS%g
1217 s%@CXXFLAGS@%$CXXFLAGS%g
1218 s%@DEFS@%$DEFS%g
1219 s%@LDFLAGS@%$LDFLAGS%g
1220 s%@LIBS@%$LIBS%g
1221 s%@exec_prefix@%$exec_prefix%g
1222 s%@prefix@%$prefix%g
1223 s%@program_transform_name@%$program_transform_name%g
1224 s%@bindir@%$bindir%g
1225 s%@sbindir@%$sbindir%g
1226 s%@libexecdir@%$libexecdir%g
1227 s%@datadir@%$datadir%g
1228 s%@sysconfdir@%$sysconfdir%g
1229 s%@sharedstatedir@%$sharedstatedir%g
1230 s%@localstatedir@%$localstatedir%g
1231 s%@libdir@%$libdir%g
1232 s%@includedir@%$includedir%g
1233 s%@oldincludedir@%$oldincludedir%g
1234 s%@infodir@%$infodir%g
1235 s%@mandir@%$mandir%g
1236 s%@host@%$host%g
1237 s%@host_alias@%$host_alias%g
1238 s%@host_cpu@%$host_cpu%g
1239 s%@host_vendor@%$host_vendor%g
1240 s%@host_os@%$host_os%g
1241 s%@target@%$target%g
1242 s%@target_alias@%$target_alias%g
1243 s%@target_cpu@%$target_cpu%g
1244 s%@target_vendor@%$target_vendor%g
1245 s%@target_os@%$target_os%g
1246 s%@build@%$build%g
1247 s%@build_alias@%$build_alias%g
1248 s%@build_cpu@%$build_cpu%g
1249 s%@build_vendor@%$build_vendor%g
1250 s%@build_os@%$build_os%g
1251 s%@CC@%$CC%g
1252 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
1253 s%@INSTALL_DATA@%$INSTALL_DATA%g
1254 s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
1255 s%@HDEFINES@%$HDEFINES%g
1256 s%@AR@%$AR%g
1257 s%@RANLIB@%$RANLIB%g
1258 s%@sim_bswap@%$sim_bswap%g
1259 s%@sim_cflags@%$sim_cflags%g
1260 s%@sim_debug@%$sim_debug%g
1261 s%@sim_trace@%$sim_trace%g
1262 s%@CPP_FOR_TARGET@%$CPP_FOR_TARGET%g
1263 s%@TARGET_SUBDIR@%$TARGET_SUBDIR%g
1264 s%@CPP@%$CPP%g
1265
1266 CEOF
1267 EOF
1268 cat >> $CONFIG_STATUS <<EOF
1269
1270 CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
1271 EOF
1272 cat >> $CONFIG_STATUS <<\EOF
1273 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
1274 # Support "outfile[:infile]", defaulting infile="outfile.in".
1275 case "$ac_file" in
1276 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
1277 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1278 *) ac_file_in="${ac_file}.in" ;;
1279 esac
1280
1281 # Adjust relative srcdir, etc. for subdirectories.
1282
1283 # Remove last slash and all that follows it. Not all systems have dirname.
1284 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1285 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1286 # The file is in a subdirectory.
1287 test ! -d "$ac_dir" && mkdir "$ac_dir"
1288 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
1289 # A "../" for each directory in $ac_dir_suffix.
1290 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
1291 else
1292 ac_dir_suffix= ac_dots=
1293 fi
1294
1295 case "$ac_given_srcdir" in
1296 .) srcdir=.
1297 if test -z "$ac_dots"; then top_srcdir=.
1298 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
1299 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
1300 *) # Relative path.
1301 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
1302 top_srcdir="$ac_dots$ac_given_srcdir" ;;
1303 esac
1304
1305 case "$ac_given_INSTALL" in
1306 [/$]*) INSTALL="$ac_given_INSTALL" ;;
1307 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
1308 esac
1309 echo creating "$ac_file"
1310 rm -f "$ac_file"
1311 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1312 case "$ac_file" in
1313 *Makefile*) ac_comsub="1i\\
1314 # $configure_input" ;;
1315 *) ac_comsub= ;;
1316 esac
1317 sed -e "$ac_comsub
1318 s%@configure_input@%$configure_input%g
1319 s%@srcdir@%$srcdir%g
1320 s%@top_srcdir@%$top_srcdir%g
1321 s%@INSTALL@%$INSTALL%g
1322 " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
1323 fi; done
1324 rm -f conftest.subs
1325
1326 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
1327 # NAME is the cpp macro being defined and VALUE is the value it is being given.
1328 #
1329 # ac_d sets the value in "#define NAME VALUE" lines.
1330 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
1331 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
1332 ac_dC='\3'
1333 ac_dD='%g'
1334 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
1335 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1336 ac_uB='\([ ]\)%\1#\2define\3'
1337 ac_uC=' '
1338 ac_uD='\4%g'
1339 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
1340 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1341 ac_eB='$%\1#\2define\3'
1342 ac_eC=' '
1343 ac_eD='%g'
1344
1345 CONFIG_HEADERS=${CONFIG_HEADERS-"config.h:config.in"}
1346 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
1347 # Support "outfile[:infile]", defaulting infile="outfile.in".
1348 case "$ac_file" in
1349 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
1350 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1351 *) ac_file_in="${ac_file}.in" ;;
1352 esac
1353
1354 echo creating $ac_file
1355
1356 rm -f conftest.frag conftest.in conftest.out
1357 cp $ac_given_srcdir/$ac_file_in conftest.in
1358
1359 EOF
1360
1361 # Transform confdefs.h into a sed script conftest.vals that substitutes
1362 # the proper values into config.h.in to produce config.h. And first:
1363 # Protect against being on the right side of a sed subst in config.status.
1364 # Protect against being in an unquoted here document in config.status.
1365 rm -f conftest.vals
1366 cat > conftest.hdr <<\EOF
1367 s/[\\&%]/\\&/g
1368 s%[\\$`]%\\&%g
1369 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
1370 s%ac_d%ac_u%gp
1371 s%ac_u%ac_e%gp
1372 EOF
1373 sed -n -f conftest.hdr confdefs.h > conftest.vals
1374 rm -f conftest.hdr
1375
1376 # This sed command replaces #undef with comments. This is necessary, for
1377 # example, in the case of _POSIX_SOURCE, which is predefined and required
1378 # on some systems where configure will not decide to define it.
1379 cat >> conftest.vals <<\EOF
1380 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
1381 EOF
1382
1383 # Break up conftest.vals because some shells have a limit on
1384 # the size of here documents, and old seds have small limits too.
1385 # Maximum number of lines to put in a single here document.
1386 ac_max_here_lines=12
1387
1388 rm -f conftest.tail
1389 while :
1390 do
1391 ac_lines=`grep -c . conftest.vals`
1392 # grep -c gives empty output for an empty file on some AIX systems.
1393 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
1394 # Write a limited-size here document to conftest.frag.
1395 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
1396 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
1397 echo 'CEOF
1398 sed -f conftest.frag conftest.in > conftest.out
1399 rm -f conftest.in
1400 mv conftest.out conftest.in
1401 ' >> $CONFIG_STATUS
1402 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
1403 rm -f conftest.vals
1404 mv conftest.tail conftest.vals
1405 done
1406 rm -f conftest.vals
1407
1408 cat >> $CONFIG_STATUS <<\EOF
1409 rm -f conftest.frag conftest.h
1410 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
1411 cat conftest.in >> conftest.h
1412 rm -f conftest.in
1413 if cmp -s $ac_file conftest.h 2>/dev/null; then
1414 echo "$ac_file is unchanged"
1415 rm -f conftest.h
1416 else
1417 # Remove last slash and all that follows it. Not all systems have dirname.
1418 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1419 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1420 # The file is in a subdirectory.
1421 test ! -d "$ac_dir" && mkdir "$ac_dir"
1422 fi
1423 rm -f $ac_file
1424 mv conftest.h $ac_file
1425 fi
1426 fi; done
1427
1428
1429 case x$CONFIG_HEADERS in xconfig.h:config.in) echo > stamp-h ;; esac
1430 exit 0
1431 EOF
1432 chmod +x $CONFIG_STATUS
1433 rm -fr confdefs* $ac_clean_files
1434 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
1435