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