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