Update to reflect change to sim/common/aclocal.m4 (allow sim/common
[deliverable/binutils-gdb.git] / sim / tic80 / configure
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.12
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-stdio Specify whether to use stdio for console input/output."
22 ac_help="$ac_help
23 --enable-sim-trace=opts Enable tracing flags"
24 ac_help="$ac_help
25 --enable-sim-profile=opts Enable profiling flags"
26 ac_help="$ac_help
27 --enable-sim-inline=inlines Specify which functions should be inlined."
28 ac_help="$ac_help
29 --enable-sim-endian=endian Specify target byte endian orientation."
30 ac_help="$ac_help
31 --enable-sim-alignment=align Specify strict or nonstrict alignment."
32 ac_help="$ac_help
33 --enable-sim-hostendain=end Specify host byte endian orientation."
34 ac_help="$ac_help
35 --enable-sim-warnings=opts Extra CFLAGS for turning on compiler warnings"
36 ac_help="$ac_help
37 --enable-sim-reserved-bits Specify whether to check reserved bits in instruction."
38
39 # Initialize some variables set by options.
40 # The variables have the same names as the options, with
41 # dashes changed to underlines.
42 build=NONE
43 cache_file=./config.cache
44 exec_prefix=NONE
45 host=NONE
46 no_create=
47 nonopt=NONE
48 no_recursion=
49 prefix=NONE
50 program_prefix=NONE
51 program_suffix=NONE
52 program_transform_name=s,x,x,
53 silent=
54 site=
55 srcdir=
56 target=NONE
57 verbose=
58 x_includes=NONE
59 x_libraries=NONE
60 bindir='${exec_prefix}/bin'
61 sbindir='${exec_prefix}/sbin'
62 libexecdir='${exec_prefix}/libexec'
63 datadir='${prefix}/share'
64 sysconfdir='${prefix}/etc'
65 sharedstatedir='${prefix}/com'
66 localstatedir='${prefix}/var'
67 libdir='${exec_prefix}/lib'
68 includedir='${prefix}/include'
69 oldincludedir='/usr/include'
70 infodir='${prefix}/info'
71 mandir='${prefix}/man'
72
73 # Initialize some other variables.
74 subdirs=
75 MFLAGS= MAKEFLAGS=
76 # Maximum number of lines to put in a shell here document.
77 ac_max_here_lines=12
78
79 ac_prev=
80 for ac_option
81 do
82
83 # If the previous option needs an argument, assign it.
84 if test -n "$ac_prev"; then
85 eval "$ac_prev=\$ac_option"
86 ac_prev=
87 continue
88 fi
89
90 case "$ac_option" in
91 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
92 *) ac_optarg= ;;
93 esac
94
95 # Accept the important Cygnus configure options, so we can diagnose typos.
96
97 case "$ac_option" in
98
99 -bindir | --bindir | --bindi | --bind | --bin | --bi)
100 ac_prev=bindir ;;
101 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
102 bindir="$ac_optarg" ;;
103
104 -build | --build | --buil | --bui | --bu)
105 ac_prev=build ;;
106 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
107 build="$ac_optarg" ;;
108
109 -cache-file | --cache-file | --cache-fil | --cache-fi \
110 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
111 ac_prev=cache_file ;;
112 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
113 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
114 cache_file="$ac_optarg" ;;
115
116 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
117 ac_prev=datadir ;;
118 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
119 | --da=*)
120 datadir="$ac_optarg" ;;
121
122 -disable-* | --disable-*)
123 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
124 # Reject names that are not valid shell variable names.
125 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
126 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
127 fi
128 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
129 eval "enable_${ac_feature}=no" ;;
130
131 -enable-* | --enable-*)
132 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
133 # Reject names that are not valid shell variable names.
134 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
135 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
136 fi
137 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
138 case "$ac_option" in
139 *=*) ;;
140 *) ac_optarg=yes ;;
141 esac
142 eval "enable_${ac_feature}='$ac_optarg'" ;;
143
144 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
145 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
146 | --exec | --exe | --ex)
147 ac_prev=exec_prefix ;;
148 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
149 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
150 | --exec=* | --exe=* | --ex=*)
151 exec_prefix="$ac_optarg" ;;
152
153 -gas | --gas | --ga | --g)
154 # Obsolete; use --with-gas.
155 with_gas=yes ;;
156
157 -help | --help | --hel | --he)
158 # Omit some internal or obsolete options to make the list less imposing.
159 # This message is too long to be a string in the A/UX 3.1 sh.
160 cat << EOF
161 Usage: configure [options] [host]
162 Options: [defaults in brackets after descriptions]
163 Configuration:
164 --cache-file=FILE cache test results in FILE
165 --help print this message
166 --no-create do not create output files
167 --quiet, --silent do not print \`checking...' messages
168 --version print the version of autoconf that created configure
169 Directory and file names:
170 --prefix=PREFIX install architecture-independent files in PREFIX
171 [$ac_default_prefix]
172 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
173 [same as prefix]
174 --bindir=DIR user executables in DIR [EPREFIX/bin]
175 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
176 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
177 --datadir=DIR read-only architecture-independent data in DIR
178 [PREFIX/share]
179 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
180 --sharedstatedir=DIR modifiable architecture-independent data in DIR
181 [PREFIX/com]
182 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
183 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
184 --includedir=DIR C header files in DIR [PREFIX/include]
185 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
186 --infodir=DIR info documentation in DIR [PREFIX/info]
187 --mandir=DIR man documentation in DIR [PREFIX/man]
188 --srcdir=DIR find the sources in DIR [configure dir or ..]
189 --program-prefix=PREFIX prepend PREFIX to installed program names
190 --program-suffix=SUFFIX append SUFFIX to installed program names
191 --program-transform-name=PROGRAM
192 run sed PROGRAM on installed program names
193 EOF
194 cat << EOF
195 Host type:
196 --build=BUILD configure for building on BUILD [BUILD=HOST]
197 --host=HOST configure for HOST [guessed]
198 --target=TARGET configure for TARGET [TARGET=HOST]
199 Features and packages:
200 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
201 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
202 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
203 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
204 --x-includes=DIR X include files are in DIR
205 --x-libraries=DIR X library files are in DIR
206 EOF
207 if test -n "$ac_help"; then
208 echo "--enable and --with options recognized:$ac_help"
209 fi
210 exit 0 ;;
211
212 -host | --host | --hos | --ho)
213 ac_prev=host ;;
214 -host=* | --host=* | --hos=* | --ho=*)
215 host="$ac_optarg" ;;
216
217 -includedir | --includedir | --includedi | --included | --include \
218 | --includ | --inclu | --incl | --inc)
219 ac_prev=includedir ;;
220 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
221 | --includ=* | --inclu=* | --incl=* | --inc=*)
222 includedir="$ac_optarg" ;;
223
224 -infodir | --infodir | --infodi | --infod | --info | --inf)
225 ac_prev=infodir ;;
226 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
227 infodir="$ac_optarg" ;;
228
229 -libdir | --libdir | --libdi | --libd)
230 ac_prev=libdir ;;
231 -libdir=* | --libdir=* | --libdi=* | --libd=*)
232 libdir="$ac_optarg" ;;
233
234 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
235 | --libexe | --libex | --libe)
236 ac_prev=libexecdir ;;
237 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
238 | --libexe=* | --libex=* | --libe=*)
239 libexecdir="$ac_optarg" ;;
240
241 -localstatedir | --localstatedir | --localstatedi | --localstated \
242 | --localstate | --localstat | --localsta | --localst \
243 | --locals | --local | --loca | --loc | --lo)
244 ac_prev=localstatedir ;;
245 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
246 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
247 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
248 localstatedir="$ac_optarg" ;;
249
250 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
251 ac_prev=mandir ;;
252 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
253 mandir="$ac_optarg" ;;
254
255 -nfp | --nfp | --nf)
256 # Obsolete; use --without-fp.
257 with_fp=no ;;
258
259 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
260 | --no-cr | --no-c)
261 no_create=yes ;;
262
263 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
264 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
265 no_recursion=yes ;;
266
267 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
268 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
269 | --oldin | --oldi | --old | --ol | --o)
270 ac_prev=oldincludedir ;;
271 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
272 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
273 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
274 oldincludedir="$ac_optarg" ;;
275
276 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
277 ac_prev=prefix ;;
278 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
279 prefix="$ac_optarg" ;;
280
281 -program-prefix | --program-prefix | --program-prefi | --program-pref \
282 | --program-pre | --program-pr | --program-p)
283 ac_prev=program_prefix ;;
284 -program-prefix=* | --program-prefix=* | --program-prefi=* \
285 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
286 program_prefix="$ac_optarg" ;;
287
288 -program-suffix | --program-suffix | --program-suffi | --program-suff \
289 | --program-suf | --program-su | --program-s)
290 ac_prev=program_suffix ;;
291 -program-suffix=* | --program-suffix=* | --program-suffi=* \
292 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
293 program_suffix="$ac_optarg" ;;
294
295 -program-transform-name | --program-transform-name \
296 | --program-transform-nam | --program-transform-na \
297 | --program-transform-n | --program-transform- \
298 | --program-transform | --program-transfor \
299 | --program-transfo | --program-transf \
300 | --program-trans | --program-tran \
301 | --progr-tra | --program-tr | --program-t)
302 ac_prev=program_transform_name ;;
303 -program-transform-name=* | --program-transform-name=* \
304 | --program-transform-nam=* | --program-transform-na=* \
305 | --program-transform-n=* | --program-transform-=* \
306 | --program-transform=* | --program-transfor=* \
307 | --program-transfo=* | --program-transf=* \
308 | --program-trans=* | --program-tran=* \
309 | --progr-tra=* | --program-tr=* | --program-t=*)
310 program_transform_name="$ac_optarg" ;;
311
312 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
313 | -silent | --silent | --silen | --sile | --sil)
314 silent=yes ;;
315
316 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
317 ac_prev=sbindir ;;
318 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
319 | --sbi=* | --sb=*)
320 sbindir="$ac_optarg" ;;
321
322 -sharedstatedir | --sharedstatedir | --sharedstatedi \
323 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
324 | --sharedst | --shareds | --shared | --share | --shar \
325 | --sha | --sh)
326 ac_prev=sharedstatedir ;;
327 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
328 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
329 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
330 | --sha=* | --sh=*)
331 sharedstatedir="$ac_optarg" ;;
332
333 -site | --site | --sit)
334 ac_prev=site ;;
335 -site=* | --site=* | --sit=*)
336 site="$ac_optarg" ;;
337
338 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
339 ac_prev=srcdir ;;
340 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
341 srcdir="$ac_optarg" ;;
342
343 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
344 | --syscon | --sysco | --sysc | --sys | --sy)
345 ac_prev=sysconfdir ;;
346 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
347 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
348 sysconfdir="$ac_optarg" ;;
349
350 -target | --target | --targe | --targ | --tar | --ta | --t)
351 ac_prev=target ;;
352 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
353 target="$ac_optarg" ;;
354
355 -v | -verbose | --verbose | --verbos | --verbo | --verb)
356 verbose=yes ;;
357
358 -version | --version | --versio | --versi | --vers)
359 echo "configure generated by autoconf version 2.12"
360 exit 0 ;;
361
362 -with-* | --with-*)
363 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
364 # Reject names that are not valid shell variable names.
365 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
366 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
367 fi
368 ac_package=`echo $ac_package| sed 's/-/_/g'`
369 case "$ac_option" in
370 *=*) ;;
371 *) ac_optarg=yes ;;
372 esac
373 eval "with_${ac_package}='$ac_optarg'" ;;
374
375 -without-* | --without-*)
376 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
377 # Reject names that are not valid shell variable names.
378 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
379 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
380 fi
381 ac_package=`echo $ac_package| sed 's/-/_/g'`
382 eval "with_${ac_package}=no" ;;
383
384 --x)
385 # Obsolete; use --with-x.
386 with_x=yes ;;
387
388 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
389 | --x-incl | --x-inc | --x-in | --x-i)
390 ac_prev=x_includes ;;
391 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
392 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
393 x_includes="$ac_optarg" ;;
394
395 -x-libraries | --x-libraries | --x-librarie | --x-librari \
396 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
397 ac_prev=x_libraries ;;
398 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
399 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
400 x_libraries="$ac_optarg" ;;
401
402 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
403 ;;
404
405 *)
406 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
407 echo "configure: warning: $ac_option: invalid host type" 1>&2
408 fi
409 if test "x$nonopt" != xNONE; then
410 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
411 fi
412 nonopt="$ac_option"
413 ;;
414
415 esac
416 done
417
418 if test -n "$ac_prev"; then
419 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
420 fi
421
422 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
423
424 # File descriptor usage:
425 # 0 standard input
426 # 1 file creation
427 # 2 errors and warnings
428 # 3 some systems may open it to /dev/tty
429 # 4 used on the Kubota Titan
430 # 6 checking for... messages and results
431 # 5 compiler messages saved in config.log
432 if test "$silent" = yes; then
433 exec 6>/dev/null
434 else
435 exec 6>&1
436 fi
437 exec 5>./config.log
438
439 echo "\
440 This file contains any messages produced by compilers while
441 running configure, to aid debugging if configure makes a mistake.
442 " 1>&5
443
444 # Strip out --no-create and --no-recursion so they do not pile up.
445 # Also quote any args containing shell metacharacters.
446 ac_configure_args=
447 for ac_arg
448 do
449 case "$ac_arg" in
450 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
451 | --no-cr | --no-c) ;;
452 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
453 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
454 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
455 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
456 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
457 esac
458 done
459
460 # NLS nuisances.
461 # Only set these to C if already set. These must not be set unconditionally
462 # because not all systems understand e.g. LANG=C (notably SCO).
463 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
464 # Non-C LC_CTYPE values break the ctype check.
465 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
466 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
467 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
468 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
469
470 # confdefs.h avoids OS command line length limits that DEFS can exceed.
471 rm -rf conftest* confdefs.h
472 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
473 echo > confdefs.h
474
475 # A filename unique to this package, relative to the directory that
476 # configure is in, which we can look for to find out if srcdir is correct.
477 ac_unique_file=Makefile.in
478
479 # Find the source files, if location was not specified.
480 if test -z "$srcdir"; then
481 ac_srcdir_defaulted=yes
482 # Try the directory containing this script, then its parent.
483 ac_prog=$0
484 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
485 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
486 srcdir=$ac_confdir
487 if test ! -r $srcdir/$ac_unique_file; then
488 srcdir=..
489 fi
490 else
491 ac_srcdir_defaulted=no
492 fi
493 if test ! -r $srcdir/$ac_unique_file; then
494 if test "$ac_srcdir_defaulted" = yes; then
495 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
496 else
497 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
498 fi
499 fi
500 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
501
502 # Prefer explicitly selected file to automatically selected ones.
503 if test -z "$CONFIG_SITE"; then
504 if test "x$prefix" != xNONE; then
505 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
506 else
507 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
508 fi
509 fi
510 for ac_site_file in $CONFIG_SITE; do
511 if test -r "$ac_site_file"; then
512 echo "loading site script $ac_site_file"
513 . "$ac_site_file"
514 fi
515 done
516
517 if test -r "$cache_file"; then
518 echo "loading cache $cache_file"
519 . $cache_file
520 else
521 echo "creating cache $cache_file"
522 > $cache_file
523 fi
524
525 ac_ext=c
526 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
527 ac_cpp='$CPP $CPPFLAGS'
528 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
529 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
530 cross_compiling=$ac_cv_prog_cc_cross
531
532 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
533 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
534 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
535 ac_n= ac_c='
536 ' ac_t=' '
537 else
538 ac_n=-n ac_c= ac_t=
539 fi
540 else
541 ac_n= ac_c='\c' ac_t=
542 fi
543
544
545
546 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
547 echo "configure:548: checking how to run the C preprocessor" >&5
548 # On Suns, sometimes $CPP names a directory.
549 if test -n "$CPP" && test -d "$CPP"; then
550 CPP=
551 fi
552 if test -z "$CPP"; then
553 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
554 echo $ac_n "(cached) $ac_c" 1>&6
555 else
556 # This must be in double quotes, not single quotes, because CPP may get
557 # substituted into the Makefile and "${CC-cc}" will confuse make.
558 CPP="${CC-cc} -E"
559 # On the NeXT, cc -E runs the code through the compiler's parser,
560 # not just through cpp.
561 cat > conftest.$ac_ext <<EOF
562 #line 563 "configure"
563 #include "confdefs.h"
564 #include <assert.h>
565 Syntax Error
566 EOF
567 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
568 { (eval echo configure:569: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
569 ac_err=`grep -v '^ *+' conftest.out`
570 if test -z "$ac_err"; then
571 :
572 else
573 echo "$ac_err" >&5
574 echo "configure: failed program was:" >&5
575 cat conftest.$ac_ext >&5
576 rm -rf conftest*
577 CPP="${CC-cc} -E -traditional-cpp"
578 cat > conftest.$ac_ext <<EOF
579 #line 580 "configure"
580 #include "confdefs.h"
581 #include <assert.h>
582 Syntax Error
583 EOF
584 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
585 { (eval echo configure:586: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
586 ac_err=`grep -v '^ *+' conftest.out`
587 if test -z "$ac_err"; then
588 :
589 else
590 echo "$ac_err" >&5
591 echo "configure: failed program was:" >&5
592 cat conftest.$ac_ext >&5
593 rm -rf conftest*
594 CPP=/lib/cpp
595 fi
596 rm -f conftest*
597 fi
598 rm -f conftest*
599 ac_cv_prog_CPP="$CPP"
600 fi
601 CPP="$ac_cv_prog_CPP"
602 else
603 ac_cv_prog_CPP="$CPP"
604 fi
605 echo "$ac_t""$CPP" 1>&6
606
607
608 # autoconf.info says this should be called right after AC_INIT.
609
610
611 ac_aux_dir=
612 for ac_dir in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../..; do
613 if test -f $ac_dir/install-sh; then
614 ac_aux_dir=$ac_dir
615 ac_install_sh="$ac_aux_dir/install-sh -c"
616 break
617 elif test -f $ac_dir/install.sh; then
618 ac_aux_dir=$ac_dir
619 ac_install_sh="$ac_aux_dir/install.sh -c"
620 break
621 fi
622 done
623 if test -z "$ac_aux_dir"; then
624 { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../.." 1>&2; exit 1; }
625 fi
626 ac_config_guess=$ac_aux_dir/config.guess
627 ac_config_sub=$ac_aux_dir/config.sub
628 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
629
630
631 # Do some error checking and defaulting for the host and target type.
632 # The inputs are:
633 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
634 #
635 # The rules are:
636 # 1. You are not allowed to specify --host, --target, and nonopt at the
637 # same time.
638 # 2. Host defaults to nonopt.
639 # 3. If nonopt is not specified, then host defaults to the current host,
640 # as determined by config.guess.
641 # 4. Target and build default to nonopt.
642 # 5. If nonopt is not specified, then target and build default to host.
643
644 # The aliases save the names the user supplied, while $host etc.
645 # will get canonicalized.
646 case $host---$target---$nonopt in
647 NONE---*---* | *---NONE---* | *---*---NONE) ;;
648 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
649 esac
650
651
652 # Make sure we can run config.sub.
653 if $ac_config_sub sun4 >/dev/null 2>&1; then :
654 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
655 fi
656
657 echo $ac_n "checking host system type""... $ac_c" 1>&6
658 echo "configure:659: checking host system type" >&5
659
660 host_alias=$host
661 case "$host_alias" in
662 NONE)
663 case $nonopt in
664 NONE)
665 if host_alias=`$ac_config_guess`; then :
666 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
667 fi ;;
668 *) host_alias=$nonopt ;;
669 esac ;;
670 esac
671
672 host=`$ac_config_sub $host_alias`
673 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
674 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
675 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
676 echo "$ac_t""$host" 1>&6
677
678 echo $ac_n "checking target system type""... $ac_c" 1>&6
679 echo "configure:680: checking target system type" >&5
680
681 target_alias=$target
682 case "$target_alias" in
683 NONE)
684 case $nonopt in
685 NONE) target_alias=$host_alias ;;
686 *) target_alias=$nonopt ;;
687 esac ;;
688 esac
689
690 target=`$ac_config_sub $target_alias`
691 target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
692 target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
693 target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
694 echo "$ac_t""$target" 1>&6
695
696 echo $ac_n "checking build system type""... $ac_c" 1>&6
697 echo "configure:698: checking build system type" >&5
698
699 build_alias=$build
700 case "$build_alias" in
701 NONE)
702 case $nonopt in
703 NONE) build_alias=$host_alias ;;
704 *) build_alias=$nonopt ;;
705 esac ;;
706 esac
707
708 build=`$ac_config_sub $build_alias`
709 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
710 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
711 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
712 echo "$ac_t""$build" 1>&6
713
714 test "$host_alias" != "$target_alias" &&
715 test "$program_prefix$program_suffix$program_transform_name" = \
716 NONENONEs,x,x, &&
717 program_prefix=${target_alias}-
718
719 if test "$program_transform_name" = s,x,x,; then
720 program_transform_name=
721 else
722 # Double any \ or $. echo might interpret backslashes.
723 cat <<\EOF_SED > conftestsed
724 s,\\,\\\\,g; s,\$,$$,g
725 EOF_SED
726 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
727 rm -f conftestsed
728 fi
729 test "$program_prefix" != NONE &&
730 program_transform_name="s,^,${program_prefix},; $program_transform_name"
731 # Use a double $ so make ignores it.
732 test "$program_suffix" != NONE &&
733 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
734
735 # sed with no file args requires a program.
736 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
737
738 # Extract the first word of "gcc", so it can be a program name with args.
739 set dummy gcc; ac_word=$2
740 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
741 echo "configure:742: checking for $ac_word" >&5
742 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
743 echo $ac_n "(cached) $ac_c" 1>&6
744 else
745 if test -n "$CC"; then
746 ac_cv_prog_CC="$CC" # Let the user override the test.
747 else
748 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
749 for ac_dir in $PATH; do
750 test -z "$ac_dir" && ac_dir=.
751 if test -f $ac_dir/$ac_word; then
752 ac_cv_prog_CC="gcc"
753 break
754 fi
755 done
756 IFS="$ac_save_ifs"
757 fi
758 fi
759 CC="$ac_cv_prog_CC"
760 if test -n "$CC"; then
761 echo "$ac_t""$CC" 1>&6
762 else
763 echo "$ac_t""no" 1>&6
764 fi
765
766 if test -z "$CC"; then
767 # Extract the first word of "cc", so it can be a program name with args.
768 set dummy cc; ac_word=$2
769 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
770 echo "configure:771: checking for $ac_word" >&5
771 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
772 echo $ac_n "(cached) $ac_c" 1>&6
773 else
774 if test -n "$CC"; then
775 ac_cv_prog_CC="$CC" # Let the user override the test.
776 else
777 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
778 ac_prog_rejected=no
779 for ac_dir in $PATH; do
780 test -z "$ac_dir" && ac_dir=.
781 if test -f $ac_dir/$ac_word; then
782 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
783 ac_prog_rejected=yes
784 continue
785 fi
786 ac_cv_prog_CC="cc"
787 break
788 fi
789 done
790 IFS="$ac_save_ifs"
791 if test $ac_prog_rejected = yes; then
792 # We found a bogon in the path, so make sure we never use it.
793 set dummy $ac_cv_prog_CC
794 shift
795 if test $# -gt 0; then
796 # We chose a different compiler from the bogus one.
797 # However, it has the same basename, so the bogon will be chosen
798 # first if we set CC to just the basename; use the full file name.
799 shift
800 set dummy "$ac_dir/$ac_word" "$@"
801 shift
802 ac_cv_prog_CC="$@"
803 fi
804 fi
805 fi
806 fi
807 CC="$ac_cv_prog_CC"
808 if test -n "$CC"; then
809 echo "$ac_t""$CC" 1>&6
810 else
811 echo "$ac_t""no" 1>&6
812 fi
813
814 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
815 fi
816
817 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
818 echo "configure:819: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
819
820 ac_ext=c
821 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
822 ac_cpp='$CPP $CPPFLAGS'
823 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
824 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
825 cross_compiling=$ac_cv_prog_cc_cross
826
827 cat > conftest.$ac_ext <<EOF
828 #line 829 "configure"
829 #include "confdefs.h"
830 main(){return(0);}
831 EOF
832 if { (eval echo configure:833: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
833 ac_cv_prog_cc_works=yes
834 # If we can't run a trivial program, we are probably using a cross compiler.
835 if (./conftest; exit) 2>/dev/null; then
836 ac_cv_prog_cc_cross=no
837 else
838 ac_cv_prog_cc_cross=yes
839 fi
840 else
841 echo "configure: failed program was:" >&5
842 cat conftest.$ac_ext >&5
843 ac_cv_prog_cc_works=no
844 fi
845 rm -fr conftest*
846
847 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
848 if test $ac_cv_prog_cc_works = no; then
849 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
850 fi
851 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
852 echo "configure:853: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
853 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
854 cross_compiling=$ac_cv_prog_cc_cross
855
856 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
857 echo "configure:858: checking whether we are using GNU C" >&5
858 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
859 echo $ac_n "(cached) $ac_c" 1>&6
860 else
861 cat > conftest.c <<EOF
862 #ifdef __GNUC__
863 yes;
864 #endif
865 EOF
866 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:867: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
867 ac_cv_prog_gcc=yes
868 else
869 ac_cv_prog_gcc=no
870 fi
871 fi
872
873 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
874
875 if test $ac_cv_prog_gcc = yes; then
876 GCC=yes
877 ac_test_CFLAGS="${CFLAGS+set}"
878 ac_save_CFLAGS="$CFLAGS"
879 CFLAGS=
880 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
881 echo "configure:882: checking whether ${CC-cc} accepts -g" >&5
882 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
883 echo $ac_n "(cached) $ac_c" 1>&6
884 else
885 echo 'void f(){}' > conftest.c
886 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
887 ac_cv_prog_cc_g=yes
888 else
889 ac_cv_prog_cc_g=no
890 fi
891 rm -f conftest*
892
893 fi
894
895 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
896 if test "$ac_test_CFLAGS" = set; then
897 CFLAGS="$ac_save_CFLAGS"
898 elif test $ac_cv_prog_cc_g = yes; then
899 CFLAGS="-g -O2"
900 else
901 CFLAGS="-O2"
902 fi
903 else
904 GCC=
905 test "${CFLAGS+set}" = set || CFLAGS="-g"
906 fi
907
908 # Find a good install program. We prefer a C program (faster),
909 # so one script is as good as another. But avoid the broken or
910 # incompatible versions:
911 # SysV /etc/install, /usr/sbin/install
912 # SunOS /usr/etc/install
913 # IRIX /sbin/install
914 # AIX /bin/install
915 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
916 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
917 # ./install, which can be erroneously created by make from ./install.sh.
918 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
919 echo "configure:920: checking for a BSD compatible install" >&5
920 if test -z "$INSTALL"; then
921 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
922 echo $ac_n "(cached) $ac_c" 1>&6
923 else
924 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
925 for ac_dir in $PATH; do
926 # Account for people who put trailing slashes in PATH elements.
927 case "$ac_dir/" in
928 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
929 *)
930 # OSF1 and SCO ODT 3.0 have their own names for install.
931 for ac_prog in ginstall installbsd scoinst install; do
932 if test -f $ac_dir/$ac_prog; then
933 if test $ac_prog = install &&
934 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
935 # AIX install. It has an incompatible calling convention.
936 # OSF/1 installbsd also uses dspmsg, but is usable.
937 :
938 else
939 ac_cv_path_install="$ac_dir/$ac_prog -c"
940 break 2
941 fi
942 fi
943 done
944 ;;
945 esac
946 done
947 IFS="$ac_save_IFS"
948
949 fi
950 if test "${ac_cv_path_install+set}" = set; then
951 INSTALL="$ac_cv_path_install"
952 else
953 # As a last resort, use the slow shell script. We don't cache a
954 # path for INSTALL within a source directory, because that will
955 # break other packages using the cache if that directory is
956 # removed, or if the path is relative.
957 INSTALL="$ac_install_sh"
958 fi
959 fi
960 echo "$ac_t""$INSTALL" 1>&6
961
962 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
963 # It thinks the first close brace ends the variable substitution.
964 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
965
966 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
967
968
969 # Put a plausible default for CC_FOR_BUILD in Makefile.
970 if test "x$cross_compiling" = "xno"; then
971 CC_FOR_BUILD='$(CC)'
972 else
973 CC_FOR_BUILD=gcc
974 fi
975
976
977
978
979 AR=${AR-ar}
980
981 # Extract the first word of "ranlib", so it can be a program name with args.
982 set dummy ranlib; ac_word=$2
983 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
984 echo "configure:985: checking for $ac_word" >&5
985 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
986 echo $ac_n "(cached) $ac_c" 1>&6
987 else
988 if test -n "$RANLIB"; then
989 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
990 else
991 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
992 for ac_dir in $PATH; do
993 test -z "$ac_dir" && ac_dir=.
994 if test -f $ac_dir/$ac_word; then
995 ac_cv_prog_RANLIB="ranlib"
996 break
997 fi
998 done
999 IFS="$ac_save_ifs"
1000 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1001 fi
1002 fi
1003 RANLIB="$ac_cv_prog_RANLIB"
1004 if test -n "$RANLIB"; then
1005 echo "$ac_t""$RANLIB" 1>&6
1006 else
1007 echo "$ac_t""no" 1>&6
1008 fi
1009
1010
1011 # Check for common headers.
1012 # FIXME: Seems to me this can cause problems for i386-windows hosts.
1013 # At one point there were hardcoded AC_DEFINE's if ${host} = i386-*-windows*.
1014 for ac_hdr in stdlib.h string.h strings.h unistd.h time.h sys/time.h sys/resource.h
1015 do
1016 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1017 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1018 echo "configure:1019: checking for $ac_hdr" >&5
1019 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1020 echo $ac_n "(cached) $ac_c" 1>&6
1021 else
1022 cat > conftest.$ac_ext <<EOF
1023 #line 1024 "configure"
1024 #include "confdefs.h"
1025 #include <$ac_hdr>
1026 EOF
1027 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1028 { (eval echo configure:1029: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1029 ac_err=`grep -v '^ *+' conftest.out`
1030 if test -z "$ac_err"; then
1031 rm -rf conftest*
1032 eval "ac_cv_header_$ac_safe=yes"
1033 else
1034 echo "$ac_err" >&5
1035 echo "configure: failed program was:" >&5
1036 cat conftest.$ac_ext >&5
1037 rm -rf conftest*
1038 eval "ac_cv_header_$ac_safe=no"
1039 fi
1040 rm -f conftest*
1041 fi
1042 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1043 echo "$ac_t""yes" 1>&6
1044 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1045 cat >> confdefs.h <<EOF
1046 #define $ac_tr_hdr 1
1047 EOF
1048
1049 else
1050 echo "$ac_t""no" 1>&6
1051 fi
1052 done
1053
1054 for ac_func in getrusage time
1055 do
1056 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1057 echo "configure:1058: checking for $ac_func" >&5
1058 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1059 echo $ac_n "(cached) $ac_c" 1>&6
1060 else
1061 cat > conftest.$ac_ext <<EOF
1062 #line 1063 "configure"
1063 #include "confdefs.h"
1064 /* System header to define __stub macros and hopefully few prototypes,
1065 which can conflict with char $ac_func(); below. */
1066 #include <assert.h>
1067 /* Override any gcc2 internal prototype to avoid an error. */
1068 /* We use char because int might match the return type of a gcc2
1069 builtin and then its argument prototype would still apply. */
1070 char $ac_func();
1071
1072 int main() {
1073
1074 /* The GNU C library defines this for functions which it implements
1075 to always fail with ENOSYS. Some functions are actually named
1076 something starting with __ and the normal name is an alias. */
1077 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1078 choke me
1079 #else
1080 $ac_func();
1081 #endif
1082
1083 ; return 0; }
1084 EOF
1085 if { (eval echo configure:1086: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1086 rm -rf conftest*
1087 eval "ac_cv_func_$ac_func=yes"
1088 else
1089 echo "configure: failed program was:" >&5
1090 cat conftest.$ac_ext >&5
1091 rm -rf conftest*
1092 eval "ac_cv_func_$ac_func=no"
1093 fi
1094 rm -f conftest*
1095 fi
1096
1097 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1098 echo "$ac_t""yes" 1>&6
1099 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1100 cat >> confdefs.h <<EOF
1101 #define $ac_tr_func 1
1102 EOF
1103
1104 else
1105 echo "$ac_t""no" 1>&6
1106 fi
1107 done
1108
1109
1110 . ${srcdir}/../../bfd/configure.host
1111
1112
1113
1114 # Check whether --enable-sim-bswap or --disable-sim-bswap was given.
1115 if test "${enable_sim_bswap+set}" = set; then
1116 enableval="$enable_sim_bswap"
1117 case "${enableval}" in
1118 yes) sim_bswap="-DWITH_BSWAP=1 -DUSE_BSWAP=1";;
1119 no) sim_bswap="-DWITH_BSWAP=0";;
1120 *) { echo "configure: error: "--enable-sim-bswap does not take a value"" 1>&2; exit 1; }; sim_bswap="";;
1121 esac
1122 if test x"$silent" != x"yes" && test x"$sim_bswap" != x""; then
1123 echo "Setting bswap flags = $sim_bswap" 6>&1
1124 fi
1125 else
1126 sim_bswap=""
1127 fi
1128
1129
1130
1131 # Check whether --enable-sim-cflags or --disable-sim-cflags was given.
1132 if test "${enable_sim_cflags+set}" = set; then
1133 enableval="$enable_sim_cflags"
1134 case "${enableval}" in
1135 yes) sim_cflags="-O2";;
1136 trace) { echo "configure: error: "Please use --enable-sim-debug instead."" 1>&2; exit 1; }; sim_cflags="";;
1137 no) sim_cflags="";;
1138 *) sim_cflags=`echo "${enableval}" | sed -e "s/,/ /g"`;;
1139 esac
1140 if test x"$silent" != x"yes" && test x"$sim_cflags" != x""; then
1141 echo "Setting sim cflags = $sim_cflags" 6>&1
1142 fi
1143 else
1144 sim_cflags=""
1145 fi
1146
1147
1148
1149 # Check whether --enable-sim-debug or --disable-sim-debug was given.
1150 if test "${enable_sim_debug+set}" = set; then
1151 enableval="$enable_sim_debug"
1152 case "${enableval}" in
1153 yes) sim_debug="-DDEBUG=7 -DWITH_DEBUG=7";;
1154 no) sim_debug="-DDEBUG=0 -DWITH_DEBUG=0";;
1155 *) sim_debug="-DDEBUG='(${enableval})' -DWITH_DEBUG='(${enableval})'";;
1156 esac
1157 if test x"$silent" != x"yes" && test x"$sim_debug" != x""; then
1158 echo "Setting sim debug = $sim_debug" 6>&1
1159 fi
1160 else
1161 sim_debug=""
1162 fi
1163
1164
1165
1166 # Check whether --enable-sim-stdio or --disable-sim-stdio was given.
1167 if test "${enable_sim_stdio+set}" = set; then
1168 enableval="$enable_sim_stdio"
1169 case "${enableval}" in
1170 yes) sim_stdio="-DWITH_STDIO=DO_USE_STDIO";;
1171 no) sim_stdio="-DWITH_STDIO=DONT_USE_STDIO";;
1172 *) { echo "configure: error: "Unknown value $enableval passed to --enable-sim-stdio"" 1>&2; exit 1; }; sim_stdio="";;
1173 esac
1174 if test x"$silent" != x"yes" && test x"$sim_stdio" != x""; then
1175 echo "Setting stdio flags = $sim_stdio" 6>&1
1176 fi
1177 else
1178 sim_stdio=""
1179 fi
1180
1181
1182
1183 # Check whether --enable-sim-trace or --disable-sim-trace was given.
1184 if test "${enable_sim_trace+set}" = set; then
1185 enableval="$enable_sim_trace"
1186 case "${enableval}" in
1187 yes) sim_trace="-DTRACE=1 -DWITH_TRACE=-1";;
1188 no) sim_trace="-DTRACE=0 -DWITH_TRACE=0";;
1189 [-0-9]*)
1190 sim_trace="-DTRACE='(${enableval})' -DWITH_TRACE='(${enableval})'";;
1191 [a-z]*)
1192 sim_trace=""
1193 for x in `echo "$enableval" | sed -e "s/,/ /g"`; do
1194 if test x"$sim_trace" = x; then
1195 sim_trace="-DWITH_TRACE='(TRACE_$x"
1196 else
1197 sim_trace="${sim_trace}|TRACE_$x"
1198 fi
1199 done
1200 sim_trace="$sim_trace)'" ;;
1201 esac
1202 if test x"$silent" != x"yes" && test x"$sim_trace" != x""; then
1203 echo "Setting sim trace = $sim_trace" 6>&1
1204 fi
1205 else
1206 sim_trace=""
1207 fi
1208
1209
1210
1211 # Check whether --enable-sim-profile or --disable-sim-profile was given.
1212 if test "${enable_sim_profile+set}" = set; then
1213 enableval="$enable_sim_profile"
1214 case "${enableval}" in
1215 yes) sim_profile="-DPROFILE=1 -DWITH_PROFILE=-1";;
1216 no) sim_profile="-DPROFILE=0 -DWITH_PROFILE=0";;
1217 [-0-9]*)
1218 sim_profile="-DPROFILE='(${enableval})' -DWITH_PROFILE='(${enableval})'";;
1219 [a-z]*)
1220 sim_profile=""
1221 for x in `echo "$enableval" | sed -e "s/,/ /g"`; do
1222 if test x"$sim_profile" = x; then
1223 sim_profile="-DWITH_PROFILE='(PROFILE_$x"
1224 else
1225 sim_profile="${sim_profile}|PROFILE_$x"
1226 fi
1227 done
1228 sim_profile="$sim_profile)'" ;;
1229 esac
1230 if test x"$silent" != x"yes" && test x"$sim_profile" != x""; then
1231 echo "Setting sim profile = $sim_profile" 6>&1
1232 fi
1233 else
1234 sim_profile=""
1235 fi
1236
1237
1238
1239 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
1240 echo "configure:1241: checking return type of signal handlers" >&5
1241 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
1242 echo $ac_n "(cached) $ac_c" 1>&6
1243 else
1244 cat > conftest.$ac_ext <<EOF
1245 #line 1246 "configure"
1246 #include "confdefs.h"
1247 #include <sys/types.h>
1248 #include <signal.h>
1249 #ifdef signal
1250 #undef signal
1251 #endif
1252 #ifdef __cplusplus
1253 extern "C" void (*signal (int, void (*)(int)))(int);
1254 #else
1255 void (*signal ()) ();
1256 #endif
1257
1258 int main() {
1259 int i;
1260 ; return 0; }
1261 EOF
1262 if { (eval echo configure:1263: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1263 rm -rf conftest*
1264 ac_cv_type_signal=void
1265 else
1266 echo "configure: failed program was:" >&5
1267 cat conftest.$ac_ext >&5
1268 rm -rf conftest*
1269 ac_cv_type_signal=int
1270 fi
1271 rm -f conftest*
1272 fi
1273
1274 echo "$ac_t""$ac_cv_type_signal" 1>&6
1275 cat >> confdefs.h <<EOF
1276 #define RETSIGTYPE $ac_cv_type_signal
1277 EOF
1278
1279
1280
1281
1282 sim_link_files=
1283 sim_link_links=
1284
1285 sim_link_links=tconfig.h
1286 if test -f ${srcdir}/tconfig.in
1287 then
1288 sim_link_files=tconfig.in
1289 else
1290 sim_link_files=../common/tconfig.in
1291 fi
1292
1293 # targ-vals.def points to the libc macro description file.
1294 case "${target}" in
1295 *-*-*) TARG_VALS_DEF=../common/nltvals.def ;;
1296 esac
1297 sim_link_files="${sim_link_files} ${TARG_VALS_DEF}"
1298 sim_link_links="${sim_link_links} targ-vals.def"
1299
1300
1301
1302
1303 default_sim_inline="-DDEFAULT_INLINE=0"
1304 # Check whether --enable-sim-inline or --disable-sim-inline was given.
1305 if test "${enable_sim_inline+set}" = set; then
1306 enableval="$enable_sim_inline"
1307 sim_inline=""
1308 case "$enableval" in
1309 no) sim_inline="-DDEFAULT_INLINE=0";;
1310 0) sim_inline="-DDEFAULT_INLINE=0";;
1311 yes | 2) sim_inline="-DDEFAULT_INLINE=ALL_INLINE";;
1312 1) sim_inline="-DDEFAULT_INLINE=INLINE_LOCALS";;
1313 *) for x in `echo "$enableval" | sed -e "s/,/ /g"`; do
1314 new_flag=""
1315 case "$x" in
1316 *_INLINE=*) new_flag="-D$x";;
1317 *=*) new_flag=`echo "$x" | sed -e "s/=/_INLINE=/" -e "s/^/-D/"`;;
1318 *_INLINE) new_flag="-D$x=ALL_INLINE";;
1319 *) new_flag="-D$x""_INLINE=ALL_INLINE";;
1320 esac
1321 if test x"$sim_inline" = x""; then
1322 sim_inline="$new_flag"
1323 else
1324 sim_inline="$sim_inline $new_flag"
1325 fi
1326 done;;
1327 esac
1328 if test x"$silent" != x"yes" && test x"$sim_inline" != x""; then
1329 echo "Setting inline flags = $sim_inline" 6>&1
1330 fi
1331 else
1332 if test x"$GCC" != "x" -a x"${default_sim_inline}" != "x" ; then
1333 sim_inline="${default_sim_inline}"
1334 if test x"$silent" != x"yes"; then
1335 echo "Setting inline flags = $sim_inline" 6>&1
1336 fi
1337 else
1338 sim_inline=""
1339 fi
1340 fi
1341
1342
1343
1344 wire_endian="LITTLE_ENDIAN"
1345 default_endian="LITTLE_ENDIAN"
1346 default_sim_endian="-DWITH_TARGET_BYTE_ORDER=LITTLE_ENDIAN"
1347 # Check whether --enable-sim-endian or --disable-sim-endian was given.
1348 if test "${enable_sim_endian+set}" = set; then
1349 enableval="$enable_sim_endian"
1350 case "${enableval}" in
1351 b*|B*) sim_endian="-DWITH_TARGET_BYTE_ORDER=BIG_ENDIAN";;
1352 l*|L*) sim_endian="-DWITH_TARGET_BYTE_ORDER=LITTLE_ENDIAN";;
1353 yes) if test x"$wire_endian" != x; then
1354 sim_endian="-DWITH_TARGET_BYTE_ORDER=${wire_endian}"
1355 else
1356 echo "No hard-wired endian for target $target" 1>&6
1357 sim_endian="-DWITH_TARGET_BYTE_ORDER=0"
1358 fi;;
1359 no) if test x"$default_endian" != x; then
1360 sim_endian="-DWITH_DEFAULT_TARGET_BYTE_ORDER=${default_endian}"
1361 else
1362 echo "No default endian for target $target" 1>&6
1363 sim_endian="-DWITH_DEFAULT_TARGET_BYTE_ORDER=0"
1364 fi;;
1365 *) { echo "configure: error: "Unknown value $enableval for --enable-sim-endian"" 1>&2; exit 1; }; sim_endian="";;
1366 esac
1367 if test x"$silent" != x"yes" && test x"$sim_endian" != x""; then
1368 echo "Setting endian flags = $sim_endian" 6>&1
1369 fi
1370 else
1371 sim_endian="${default_sim_endian}"
1372 fi
1373
1374
1375
1376 # Check whether --enable-sim-alignment or --disable-sim-alignment was given.
1377 if test "${enable_sim_alignment+set}" = set; then
1378 enableval="$enable_sim_alignment"
1379 case "${enableval}" in
1380 yes | strict | STRICT) sim_alignment="-DWITH_ALIGNMENT=STRICT_ALIGNMENT";;
1381 no | nonstrict | NONSTRICT) sim_alignment="-DWITH_ALIGNMENT=NONSTRICT_ALIGNMENT";;
1382 0 | default | DEFAULT) sim_alignment="-DWITH_ALIGNMENT=0";;
1383 *) { echo "configure: error: "Unknown value $enableval passed to --enable-sim-alignment"" 1>&2; exit 1; }; sim_alignment="";;
1384 esac
1385 if test x"$silent" != x"yes" && test x"$sim_alignment" != x""; then
1386 echo "Setting alignment flags = $sim_alignment" 6>&1
1387 fi
1388 else
1389 sim_alignment=""
1390 fi
1391
1392
1393
1394 # Check whether --enable-sim-hostendian or --disable-sim-hostendian was given.
1395 if test "${enable_sim_hostendian+set}" = set; then
1396 enableval="$enable_sim_hostendian"
1397 case "${enableval}" in
1398 no) sim_hostendian="-DWITH_HOST_BYTE_ORDER=0";;
1399 b*|B*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN";;
1400 l*|L*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN";;
1401 *) { echo "configure: error: "Unknown value $enableval for --enable-sim-hostendian"" 1>&2; exit 1; }; sim_hostendian="";;
1402 esac
1403 if test x"$silent" != x"yes" && test x"$sim_hostendian" != x""; then
1404 echo "Setting hostendian flags = $sim_hostendian" 6>&1
1405 fi
1406 else
1407
1408 if test "x$cross_compiling" = "xno"; then
1409 echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
1410 echo "configure:1411: checking whether byte ordering is bigendian" >&5
1411 if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
1412 echo $ac_n "(cached) $ac_c" 1>&6
1413 else
1414 ac_cv_c_bigendian=unknown
1415 # See if sys/param.h defines the BYTE_ORDER macro.
1416 cat > conftest.$ac_ext <<EOF
1417 #line 1418 "configure"
1418 #include "confdefs.h"
1419 #include <sys/types.h>
1420 #include <sys/param.h>
1421 int main() {
1422
1423 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
1424 bogus endian macros
1425 #endif
1426 ; return 0; }
1427 EOF
1428 if { (eval echo configure:1429: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1429 rm -rf conftest*
1430 # It does; now see whether it defined to BIG_ENDIAN or not.
1431 cat > conftest.$ac_ext <<EOF
1432 #line 1433 "configure"
1433 #include "confdefs.h"
1434 #include <sys/types.h>
1435 #include <sys/param.h>
1436 int main() {
1437
1438 #if BYTE_ORDER != BIG_ENDIAN
1439 not big endian
1440 #endif
1441 ; return 0; }
1442 EOF
1443 if { (eval echo configure:1444: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1444 rm -rf conftest*
1445 ac_cv_c_bigendian=yes
1446 else
1447 echo "configure: failed program was:" >&5
1448 cat conftest.$ac_ext >&5
1449 rm -rf conftest*
1450 ac_cv_c_bigendian=no
1451 fi
1452 rm -f conftest*
1453 else
1454 echo "configure: failed program was:" >&5
1455 cat conftest.$ac_ext >&5
1456 fi
1457 rm -f conftest*
1458 if test $ac_cv_c_bigendian = unknown; then
1459 if test "$cross_compiling" = yes; then
1460 { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
1461 else
1462 cat > conftest.$ac_ext <<EOF
1463 #line 1464 "configure"
1464 #include "confdefs.h"
1465 main () {
1466 /* Are we little or big endian? From Harbison&Steele. */
1467 union
1468 {
1469 long l;
1470 char c[sizeof (long)];
1471 } u;
1472 u.l = 1;
1473 exit (u.c[sizeof (long) - 1] == 1);
1474 }
1475 EOF
1476 if { (eval echo configure:1477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
1477 then
1478 ac_cv_c_bigendian=no
1479 else
1480 echo "configure: failed program was:" >&5
1481 cat conftest.$ac_ext >&5
1482 rm -fr conftest*
1483 ac_cv_c_bigendian=yes
1484 fi
1485 rm -fr conftest*
1486 fi
1487
1488 fi
1489 fi
1490
1491 echo "$ac_t""$ac_cv_c_bigendian" 1>&6
1492 if test $ac_cv_c_bigendian = yes; then
1493 cat >> confdefs.h <<\EOF
1494 #define WORDS_BIGENDIAN 1
1495 EOF
1496
1497 fi
1498
1499 if test $ac_cv_c_bigendian = yes; then
1500 sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN"
1501 else
1502 sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN"
1503 fi
1504 else
1505 sim_hostendian="-DWITH_HOST_BYTE_ORDER=0"
1506 fi
1507 fi
1508
1509
1510
1511 # Check whether --enable-sim-warnings or --disable-sim-warnings was given.
1512 if test "${enable_sim_warnings+set}" = set; then
1513 enableval="$enable_sim_warnings"
1514 case "${enableval}" in
1515 yes) sim_warnings="-Werror -Wall -Wpointer-arith -Wmissing-prototypes -Wmissing-declarations ";;
1516 no) sim_warnings="-w";;
1517 *) sim_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
1518 esac
1519 if test x"$silent" != x"yes" && test x"$sim_warnings" != x""; then
1520 echo "Setting warning flags = $sim_warnings" 6>&1
1521 fi
1522 else
1523 sim_warnings=""
1524 fi
1525
1526
1527
1528 default_sim_reserved_bits="1"
1529 # Check whether --enable-sim-reserved-bits or --disable-sim-reserved-bits was given.
1530 if test "${enable_sim_reserved_bits+set}" = set; then
1531 enableval="$enable_sim_reserved_bits"
1532 case "${enableval}" in
1533 yes) sim_reserved_bits="-DWITH_RESERVED_BITS=1";;
1534 no) sim_reserved_bits="-DWITH_RESERVED_BITS=0";;
1535 *) { echo "configure: error: "--enable-sim-reserved-bits does not take a value"" 1>&2; exit 1; }; sim_reserved_bits="";;
1536 esac
1537 if test x"$silent" != x"yes" && test x"$sim_reserved_bits" != x""; then
1538 echo "Setting reserved flags = $sim_reserved_bits" 6>&1
1539 fi
1540 else
1541 sim_reserved_bits="-DWITH_RESERVED_BITS=${default_sim_reserved_bits}"
1542 fi
1543
1544
1545
1546 for ac_hdr in stdlib.h unistd.h string.h strings.h
1547 do
1548 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1549 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1550 echo "configure:1551: checking for $ac_hdr" >&5
1551 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1552 echo $ac_n "(cached) $ac_c" 1>&6
1553 else
1554 cat > conftest.$ac_ext <<EOF
1555 #line 1556 "configure"
1556 #include "confdefs.h"
1557 #include <$ac_hdr>
1558 EOF
1559 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1560 { (eval echo configure:1561: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1561 ac_err=`grep -v '^ *+' conftest.out`
1562 if test -z "$ac_err"; then
1563 rm -rf conftest*
1564 eval "ac_cv_header_$ac_safe=yes"
1565 else
1566 echo "$ac_err" >&5
1567 echo "configure: failed program was:" >&5
1568 cat conftest.$ac_ext >&5
1569 rm -rf conftest*
1570 eval "ac_cv_header_$ac_safe=no"
1571 fi
1572 rm -f conftest*
1573 fi
1574 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1575 echo "$ac_t""yes" 1>&6
1576 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1577 cat >> confdefs.h <<EOF
1578 #define $ac_tr_hdr 1
1579 EOF
1580
1581 else
1582 echo "$ac_t""no" 1>&6
1583 fi
1584 done
1585
1586 for ac_func in getpid kill
1587 do
1588 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1589 echo "configure:1590: checking for $ac_func" >&5
1590 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1591 echo $ac_n "(cached) $ac_c" 1>&6
1592 else
1593 cat > conftest.$ac_ext <<EOF
1594 #line 1595 "configure"
1595 #include "confdefs.h"
1596 /* System header to define __stub macros and hopefully few prototypes,
1597 which can conflict with char $ac_func(); below. */
1598 #include <assert.h>
1599 /* Override any gcc2 internal prototype to avoid an error. */
1600 /* We use char because int might match the return type of a gcc2
1601 builtin and then its argument prototype would still apply. */
1602 char $ac_func();
1603
1604 int main() {
1605
1606 /* The GNU C library defines this for functions which it implements
1607 to always fail with ENOSYS. Some functions are actually named
1608 something starting with __ and the normal name is an alias. */
1609 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1610 choke me
1611 #else
1612 $ac_func();
1613 #endif
1614
1615 ; return 0; }
1616 EOF
1617 if { (eval echo configure:1618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1618 rm -rf conftest*
1619 eval "ac_cv_func_$ac_func=yes"
1620 else
1621 echo "configure: failed program was:" >&5
1622 cat conftest.$ac_ext >&5
1623 rm -rf conftest*
1624 eval "ac_cv_func_$ac_func=no"
1625 fi
1626 rm -f conftest*
1627 fi
1628
1629 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1630 echo "$ac_t""yes" 1>&6
1631 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1632 cat >> confdefs.h <<EOF
1633 #define $ac_tr_func 1
1634 EOF
1635
1636 else
1637 echo "$ac_t""no" 1>&6
1638 fi
1639 done
1640
1641
1642
1643
1644 trap '' 1 2 15
1645 cat > confcache <<\EOF
1646 # This file is a shell script that caches the results of configure
1647 # tests run on this system so they can be shared between configure
1648 # scripts and configure runs. It is not useful on other systems.
1649 # If it contains results you don't want to keep, you may remove or edit it.
1650 #
1651 # By default, configure uses ./config.cache as the cache file,
1652 # creating it if it does not exist already. You can give configure
1653 # the --cache-file=FILE option to use a different cache file; that is
1654 # what configure does when it calls configure scripts in
1655 # subdirectories, so they share the cache.
1656 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1657 # config.status only pays attention to the cache file if you give it the
1658 # --recheck option to rerun configure.
1659 #
1660 EOF
1661 # The following way of writing the cache mishandles newlines in values,
1662 # but we know of no workaround that is simple, portable, and efficient.
1663 # So, don't put newlines in cache variables' values.
1664 # Ultrix sh set writes to stderr and can't be redirected directly,
1665 # and sets the high bit in the cache file unless we assign to the vars.
1666 (set) 2>&1 |
1667 case `(ac_space=' '; set) 2>&1` in
1668 *ac_space=\ *)
1669 # `set' does not quote correctly, so add quotes (double-quote substitution
1670 # turns \\\\ into \\, and sed turns \\ into \).
1671 sed -n \
1672 -e "s/'/'\\\\''/g" \
1673 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1674 ;;
1675 *)
1676 # `set' quotes correctly as required by POSIX, so do not add quotes.
1677 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1678 ;;
1679 esac >> confcache
1680 if cmp -s $cache_file confcache; then
1681 :
1682 else
1683 if test -w $cache_file; then
1684 echo "updating cache $cache_file"
1685 cat confcache > $cache_file
1686 else
1687 echo "not updating unwritable cache $cache_file"
1688 fi
1689 fi
1690 rm -f confcache
1691
1692 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
1693
1694 test "x$prefix" = xNONE && prefix=$ac_default_prefix
1695 # Let make expand exec_prefix.
1696 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1697
1698 # Any assignment to VPATH causes Sun make to only execute
1699 # the first set of double-colon rules, so remove it if not needed.
1700 # If there is a colon in the path, we need to keep it.
1701 if test "x$srcdir" = x.; then
1702 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
1703 fi
1704
1705 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1706
1707 DEFS=-DHAVE_CONFIG_H
1708
1709 # Without the "./", some shells look in PATH for config.status.
1710 : ${CONFIG_STATUS=./config.status}
1711
1712 echo creating $CONFIG_STATUS
1713 rm -f $CONFIG_STATUS
1714 cat > $CONFIG_STATUS <<EOF
1715 #! /bin/sh
1716 # Generated automatically by configure.
1717 # Run this file to recreate the current configuration.
1718 # This directory was configured as follows,
1719 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1720 #
1721 # $0 $ac_configure_args
1722 #
1723 # Compiler output produced by configure, useful for debugging
1724 # configure, is in ./config.log if it exists.
1725
1726 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1727 for ac_option
1728 do
1729 case "\$ac_option" in
1730 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1731 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1732 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1733 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
1734 echo "$CONFIG_STATUS generated by autoconf version 2.12"
1735 exit 0 ;;
1736 -help | --help | --hel | --he | --h)
1737 echo "\$ac_cs_usage"; exit 0 ;;
1738 *) echo "\$ac_cs_usage"; exit 1 ;;
1739 esac
1740 done
1741
1742 ac_given_srcdir=$srcdir
1743 ac_given_INSTALL="$INSTALL"
1744
1745 trap 'rm -fr `echo "Makefile.sim:Makefile.in Make-common.sim:../common/Make-common.in .gdbinit:../common/gdbinit.in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
1746 EOF
1747 cat >> $CONFIG_STATUS <<EOF
1748
1749 # Protect against being on the right side of a sed subst in config.status.
1750 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
1751 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
1752 $ac_vpsub
1753 $extrasub
1754 s%@CFLAGS@%$CFLAGS%g
1755 s%@CPPFLAGS@%$CPPFLAGS%g
1756 s%@CXXFLAGS@%$CXXFLAGS%g
1757 s%@DEFS@%$DEFS%g
1758 s%@LDFLAGS@%$LDFLAGS%g
1759 s%@LIBS@%$LIBS%g
1760 s%@exec_prefix@%$exec_prefix%g
1761 s%@prefix@%$prefix%g
1762 s%@program_transform_name@%$program_transform_name%g
1763 s%@bindir@%$bindir%g
1764 s%@sbindir@%$sbindir%g
1765 s%@libexecdir@%$libexecdir%g
1766 s%@datadir@%$datadir%g
1767 s%@sysconfdir@%$sysconfdir%g
1768 s%@sharedstatedir@%$sharedstatedir%g
1769 s%@localstatedir@%$localstatedir%g
1770 s%@libdir@%$libdir%g
1771 s%@includedir@%$includedir%g
1772 s%@oldincludedir@%$oldincludedir%g
1773 s%@infodir@%$infodir%g
1774 s%@mandir@%$mandir%g
1775 s%@host@%$host%g
1776 s%@host_alias@%$host_alias%g
1777 s%@host_cpu@%$host_cpu%g
1778 s%@host_vendor@%$host_vendor%g
1779 s%@host_os@%$host_os%g
1780 s%@target@%$target%g
1781 s%@target_alias@%$target_alias%g
1782 s%@target_cpu@%$target_cpu%g
1783 s%@target_vendor@%$target_vendor%g
1784 s%@target_os@%$target_os%g
1785 s%@build@%$build%g
1786 s%@build_alias@%$build_alias%g
1787 s%@build_cpu@%$build_cpu%g
1788 s%@build_vendor@%$build_vendor%g
1789 s%@build_os@%$build_os%g
1790 s%@CC@%$CC%g
1791 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
1792 s%@INSTALL_DATA@%$INSTALL_DATA%g
1793 s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
1794 s%@HDEFINES@%$HDEFINES%g
1795 s%@AR@%$AR%g
1796 s%@RANLIB@%$RANLIB%g
1797 s%@CPP@%$CPP%g
1798 s%@sim_bswap@%$sim_bswap%g
1799 s%@sim_cflags@%$sim_cflags%g
1800 s%@sim_debug@%$sim_debug%g
1801 s%@sim_stdio@%$sim_stdio%g
1802 s%@sim_trace@%$sim_trace%g
1803 s%@sim_profile@%$sim_profile%g
1804 s%@sim_inline@%$sim_inline%g
1805 s%@sim_endian@%$sim_endian%g
1806 s%@sim_alignment@%$sim_alignment%g
1807 s%@sim_hostendian@%$sim_hostendian%g
1808 s%@sim_warnings@%$sim_warnings%g
1809 s%@sim_reserved_bits@%$sim_reserved_bits%g
1810
1811 CEOF
1812 EOF
1813
1814 cat >> $CONFIG_STATUS <<\EOF
1815
1816 # Split the substitutions into bite-sized pieces for seds with
1817 # small command number limits, like on Digital OSF/1 and HP-UX.
1818 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
1819 ac_file=1 # Number of current file.
1820 ac_beg=1 # First line for current file.
1821 ac_end=$ac_max_sed_cmds # Line after last line for current file.
1822 ac_more_lines=:
1823 ac_sed_cmds=""
1824 while $ac_more_lines; do
1825 if test $ac_beg -gt 1; then
1826 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
1827 else
1828 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
1829 fi
1830 if test ! -s conftest.s$ac_file; then
1831 ac_more_lines=false
1832 rm -f conftest.s$ac_file
1833 else
1834 if test -z "$ac_sed_cmds"; then
1835 ac_sed_cmds="sed -f conftest.s$ac_file"
1836 else
1837 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
1838 fi
1839 ac_file=`expr $ac_file + 1`
1840 ac_beg=$ac_end
1841 ac_end=`expr $ac_end + $ac_max_sed_cmds`
1842 fi
1843 done
1844 if test -z "$ac_sed_cmds"; then
1845 ac_sed_cmds=cat
1846 fi
1847 EOF
1848
1849 cat >> $CONFIG_STATUS <<EOF
1850
1851 CONFIG_FILES=\${CONFIG_FILES-"Makefile.sim:Makefile.in Make-common.sim:../common/Make-common.in .gdbinit:../common/gdbinit.in"}
1852 EOF
1853 cat >> $CONFIG_STATUS <<\EOF
1854 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
1855 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
1856 case "$ac_file" in
1857 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
1858 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1859 *) ac_file_in="${ac_file}.in" ;;
1860 esac
1861
1862 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
1863
1864 # Remove last slash and all that follows it. Not all systems have dirname.
1865 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1866 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1867 # The file is in a subdirectory.
1868 test ! -d "$ac_dir" && mkdir "$ac_dir"
1869 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
1870 # A "../" for each directory in $ac_dir_suffix.
1871 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
1872 else
1873 ac_dir_suffix= ac_dots=
1874 fi
1875
1876 case "$ac_given_srcdir" in
1877 .) srcdir=.
1878 if test -z "$ac_dots"; then top_srcdir=.
1879 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
1880 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
1881 *) # Relative path.
1882 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
1883 top_srcdir="$ac_dots$ac_given_srcdir" ;;
1884 esac
1885
1886 case "$ac_given_INSTALL" in
1887 [/$]*) INSTALL="$ac_given_INSTALL" ;;
1888 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
1889 esac
1890
1891 echo creating "$ac_file"
1892 rm -f "$ac_file"
1893 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1894 case "$ac_file" in
1895 *Makefile*) ac_comsub="1i\\
1896 # $configure_input" ;;
1897 *) ac_comsub= ;;
1898 esac
1899
1900 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
1901 sed -e "$ac_comsub
1902 s%@configure_input@%$configure_input%g
1903 s%@srcdir@%$srcdir%g
1904 s%@top_srcdir@%$top_srcdir%g
1905 s%@INSTALL@%$INSTALL%g
1906 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
1907 fi; done
1908 rm -f conftest.s*
1909
1910 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
1911 # NAME is the cpp macro being defined and VALUE is the value it is being given.
1912 #
1913 # ac_d sets the value in "#define NAME VALUE" lines.
1914 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
1915 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
1916 ac_dC='\3'
1917 ac_dD='%g'
1918 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
1919 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1920 ac_uB='\([ ]\)%\1#\2define\3'
1921 ac_uC=' '
1922 ac_uD='\4%g'
1923 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
1924 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1925 ac_eB='$%\1#\2define\3'
1926 ac_eC=' '
1927 ac_eD='%g'
1928
1929 if test "${CONFIG_HEADERS+set}" != set; then
1930 EOF
1931 cat >> $CONFIG_STATUS <<EOF
1932 CONFIG_HEADERS="config.h:config.in"
1933 EOF
1934 cat >> $CONFIG_STATUS <<\EOF
1935 fi
1936 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
1937 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
1938 case "$ac_file" in
1939 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
1940 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1941 *) ac_file_in="${ac_file}.in" ;;
1942 esac
1943
1944 echo creating $ac_file
1945
1946 rm -f conftest.frag conftest.in conftest.out
1947 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
1948 cat $ac_file_inputs > conftest.in
1949
1950 EOF
1951
1952 # Transform confdefs.h into a sed script conftest.vals that substitutes
1953 # the proper values into config.h.in to produce config.h. And first:
1954 # Protect against being on the right side of a sed subst in config.status.
1955 # Protect against being in an unquoted here document in config.status.
1956 rm -f conftest.vals
1957 cat > conftest.hdr <<\EOF
1958 s/[\\&%]/\\&/g
1959 s%[\\$`]%\\&%g
1960 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
1961 s%ac_d%ac_u%gp
1962 s%ac_u%ac_e%gp
1963 EOF
1964 sed -n -f conftest.hdr confdefs.h > conftest.vals
1965 rm -f conftest.hdr
1966
1967 # This sed command replaces #undef with comments. This is necessary, for
1968 # example, in the case of _POSIX_SOURCE, which is predefined and required
1969 # on some systems where configure will not decide to define it.
1970 cat >> conftest.vals <<\EOF
1971 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
1972 EOF
1973
1974 # Break up conftest.vals because some shells have a limit on
1975 # the size of here documents, and old seds have small limits too.
1976
1977 rm -f conftest.tail
1978 while :
1979 do
1980 ac_lines=`grep -c . conftest.vals`
1981 # grep -c gives empty output for an empty file on some AIX systems.
1982 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
1983 # Write a limited-size here document to conftest.frag.
1984 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
1985 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
1986 echo 'CEOF
1987 sed -f conftest.frag conftest.in > conftest.out
1988 rm -f conftest.in
1989 mv conftest.out conftest.in
1990 ' >> $CONFIG_STATUS
1991 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
1992 rm -f conftest.vals
1993 mv conftest.tail conftest.vals
1994 done
1995 rm -f conftest.vals
1996
1997 cat >> $CONFIG_STATUS <<\EOF
1998 rm -f conftest.frag conftest.h
1999 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
2000 cat conftest.in >> conftest.h
2001 rm -f conftest.in
2002 if cmp -s $ac_file conftest.h 2>/dev/null; then
2003 echo "$ac_file is unchanged"
2004 rm -f conftest.h
2005 else
2006 # Remove last slash and all that follows it. Not all systems have dirname.
2007 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2008 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2009 # The file is in a subdirectory.
2010 test ! -d "$ac_dir" && mkdir "$ac_dir"
2011 fi
2012 rm -f $ac_file
2013 mv conftest.h $ac_file
2014 fi
2015 fi; done
2016
2017 EOF
2018
2019 cat >> $CONFIG_STATUS <<EOF
2020 ac_sources="$sim_link_files"
2021 ac_dests="$sim_link_links"
2022 EOF
2023
2024 cat >> $CONFIG_STATUS <<\EOF
2025 srcdir=$ac_given_srcdir
2026 while test -n "$ac_sources"; do
2027 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
2028 set $ac_sources; ac_source=$1; shift; ac_sources=$*
2029
2030 echo "linking $srcdir/$ac_source to $ac_dest"
2031
2032 if test ! -r $srcdir/$ac_source; then
2033 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
2034 fi
2035 rm -f $ac_dest
2036
2037 # Make relative symlinks.
2038 # Remove last slash and all that follows it. Not all systems have dirname.
2039 ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
2040 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
2041 # The dest file is in a subdirectory.
2042 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
2043 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
2044 # A "../" for each directory in $ac_dest_dir_suffix.
2045 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
2046 else
2047 ac_dest_dir_suffix= ac_dots=
2048 fi
2049
2050 case "$srcdir" in
2051 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
2052 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
2053 esac
2054
2055 # Make a symlink if possible; otherwise try a hard link.
2056 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
2057 ln $srcdir/$ac_source $ac_dest; then :
2058 else
2059 { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
2060 fi
2061 done
2062 EOF
2063 cat >> $CONFIG_STATUS <<EOF
2064
2065 EOF
2066 cat >> $CONFIG_STATUS <<\EOF
2067 case "x$CONFIG_FILES" in
2068 xMakefile*)
2069 echo "Merging Makefile.sim+Make-common.sim into Makefile ..."
2070 rm -f Makesim1.tmp Makesim2.tmp Makefile
2071 sed -n -e '/^## COMMON_PRE_/,/^## End COMMON_PRE_/ p' <Make-common.sim >Makesim1.tmp
2072 sed -n -e '/^## COMMON_POST_/,/^## End COMMON_POST_/ p' <Make-common.sim >Makesim2.tmp
2073 sed -e '/^## COMMON_PRE_/ r Makesim1.tmp' \
2074 -e '/^## COMMON_POST_/ r Makesim2.tmp' \
2075 <Makefile.sim >Makefile
2076 rm -f Makefile.sim Make-common.sim Makesim1.tmp Makesim2.tmp
2077 ;;
2078 esac
2079 case "x$CONFIG_HEADERS" in xconfig.h:config.in) echo > stamp-h ;; esac
2080
2081 exit 0
2082 EOF
2083 chmod +x $CONFIG_STATUS
2084 rm -fr confdefs* $ac_clean_files
2085 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2086
2087
This page took 0.081104 seconds and 4 git commands to generate.