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