Commit | Line | Data |
---|---|---|
5d031c16 AC |
1 | #! /bin/sh |
2 | ||
3 | ||
4 | ||
5 | ||
6 | ||
7 | ||
8 | ||
9 | ||
10 | ||
11 | ||
12 | ||
13 | ||
14 | ||
15 | ||
16 | ||
17 | ||
18 | ||
19 | ||
20 | ||
21 | ||
22 | ||
23 | ||
24 | ||
25 | ||
26 | ||
27 | ||
28 | ||
29 | ||
30 | ||
31 | ||
32 | ||
33 | ||
34 | ||
35 | ||
36 | ||
37 | ||
38 | ||
39 | ||
40 | ||
41 | ||
42 | ||
43 | ||
44 | ||
45 | sim_inline="-DDEFAULT_INLINE=0" | |
46 | ||
47 | ||
48 | ||
49 | ||
50 | ||
51 | ||
52 | ||
53 | ||
54 | ||
55 | ||
56 | ||
57 | ||
58 | ||
59 | ||
60 | ||
61 | ||
62 | ||
63 | ||
64 | ||
65 | ||
66 | ||
67 | ||
68 | ||
69 | ||
70 | ||
71 | ||
72 | ||
73 | ||
74 | ||
75 | ||
76 | ||
77 | ||
78 | ||
79 | ||
80 | ||
81 | ||
82 | # This file is derived from `gettext.m4'. The difference is that the | |
83 | # included macros assume Cygnus-style source and build trees. | |
84 | ||
85 | # Macro to add for using GNU gettext. | |
86 | # Ulrich Drepper <drepper@cygnus.com>, 1995. | |
87 | # | |
88 | # This file file be copied and used freely without restrictions. It can | |
89 | # be used in projects which are not available under the GNU Public License | |
90 | # but which still want to provide support for the GNU gettext functionality. | |
91 | # Please note that the actual code is *not* freely available. | |
92 | ||
93 | # serial 3 | |
94 | ||
95 | ||
96 | ||
97 | ||
98 | ||
99 | # Search path for a program which passes the given test. | |
100 | # Ulrich Drepper <drepper@cygnus.com>, 1996. | |
101 | # | |
102 | # This file file be copied and used freely without restrictions. It can | |
103 | # be used in projects which are not available under the GNU Public License | |
104 | # but which still want to provide support for the GNU gettext functionality. | |
105 | # Please note that the actual code is *not* freely available. | |
106 | ||
107 | # serial 1 | |
108 | ||
109 | ||
110 | ||
111 | # Check whether LC_MESSAGES is available in <locale.h>. | |
112 | # Ulrich Drepper <drepper@cygnus.com>, 1995. | |
113 | # | |
114 | # This file file be copied and used freely without restrictions. It can | |
115 | # be used in projects which are not available under the GNU Public License | |
116 | # but which still want to provide support for the GNU gettext functionality. | |
117 | # Please note that the actual code is *not* freely available. | |
118 | ||
119 | # serial 1 | |
120 | ||
121 | ||
122 | ||
123 | ||
124 | ||
125 | ||
126 | # Guess values for system-dependent variables and create Makefiles. | |
127 | # Generated automatically using autoconf version 2.13 | |
128 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. | |
129 | # | |
130 | # This configure script is free software; the Free Software Foundation | |
131 | # gives unlimited permission to copy, distribute and modify it. | |
132 | ||
133 | # Defaults: | |
134 | ac_help= | |
135 | ac_default_prefix=/usr/local | |
136 | # Any additions from configure.in: | |
137 | ac_help="$ac_help | |
138 | --disable-nls do not use Native Language Support" | |
139 | ac_help="$ac_help | |
140 | --with-included-gettext use the GNU gettext library included here" | |
141 | ac_help="$ac_help | |
142 | --enable-maintainer-mode Enable developer functionality." | |
143 | ac_help="$ac_help | |
144 | --enable-sim-bswap Use Host specific BSWAP instruction." | |
145 | ac_help="$ac_help | |
146 | --enable-sim-cflags=opts Extra CFLAGS for use in building simulator" | |
147 | ac_help="$ac_help | |
148 | --enable-sim-debug=opts Enable debugging flags" | |
149 | ac_help="$ac_help | |
150 | --enable-sim-stdio Specify whether to use stdio for console input/output." | |
151 | ac_help="$ac_help | |
152 | --enable-sim-trace=opts Enable tracing flags" | |
153 | ac_help="$ac_help | |
154 | --enable-sim-profile=opts Enable profiling flags" | |
155 | ac_help="$ac_help | |
156 | --enable-sim-inline=inlines Specify which functions should be inlined." | |
157 | ac_help="$ac_help | |
158 | --enable-sim-alignment=align Specify strict, nonstrict or forced alignment of memory accesses." | |
159 | ac_help="$ac_help | |
160 | --enable-sim-hostendian=end Specify host byte endian orientation." | |
161 | ac_help="$ac_help | |
162 | --enable-build-warnings[=LIST] Enable build-time compiler warnings" | |
163 | ac_help="$ac_help | |
164 | --enable-sim-hardware=LIST Specify the hardware to be included in the build." | |
165 | ||
166 | # Initialize some variables set by options. | |
167 | # The variables have the same names as the options, with | |
168 | # dashes changed to underlines. | |
169 | build=NONE | |
170 | cache_file=./config.cache | |
171 | exec_prefix=NONE | |
172 | host=NONE | |
173 | no_create= | |
174 | nonopt=NONE | |
175 | no_recursion= | |
176 | prefix=NONE | |
177 | program_prefix=NONE | |
178 | program_suffix=NONE | |
179 | program_transform_name=s,x,x, | |
180 | silent= | |
181 | site= | |
182 | sitefile= | |
183 | srcdir= | |
184 | target=NONE | |
185 | verbose= | |
186 | x_includes=NONE | |
187 | x_libraries=NONE | |
188 | bindir='${exec_prefix}/bin' | |
189 | sbindir='${exec_prefix}/sbin' | |
190 | libexecdir='${exec_prefix}/libexec' | |
191 | datadir='${prefix}/share' | |
192 | sysconfdir='${prefix}/etc' | |
193 | sharedstatedir='${prefix}/com' | |
194 | localstatedir='${prefix}/var' | |
195 | libdir='${exec_prefix}/lib' | |
196 | includedir='${prefix}/include' | |
197 | oldincludedir='/usr/include' | |
198 | infodir='${prefix}/info' | |
199 | mandir='${prefix}/man' | |
200 | ||
201 | # Initialize some other variables. | |
202 | subdirs= | |
203 | MFLAGS= MAKEFLAGS= | |
204 | SHELL=${CONFIG_SHELL-/bin/sh} | |
205 | # Maximum number of lines to put in a shell here document. | |
206 | ac_max_here_lines=12 | |
207 | ||
208 | ac_prev= | |
209 | for ac_option | |
210 | do | |
211 | ||
212 | # If the previous option needs an argument, assign it. | |
213 | if test -n "$ac_prev"; then | |
214 | eval "$ac_prev=\$ac_option" | |
215 | ac_prev= | |
216 | continue | |
217 | fi | |
218 | ||
219 | case "$ac_option" in | |
220 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; | |
221 | *) ac_optarg= ;; | |
222 | esac | |
223 | ||
224 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
225 | ||
226 | case "$ac_option" in | |
227 | ||
228 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
229 | ac_prev=bindir ;; | |
230 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
231 | bindir="$ac_optarg" ;; | |
232 | ||
233 | -build | --build | --buil | --bui | --bu) | |
234 | ac_prev=build ;; | |
235 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) | |
236 | build="$ac_optarg" ;; | |
237 | ||
238 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
239 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
240 | ac_prev=cache_file ;; | |
241 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
242 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
243 | cache_file="$ac_optarg" ;; | |
244 | ||
245 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) | |
246 | ac_prev=datadir ;; | |
247 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ | |
248 | | --da=*) | |
249 | datadir="$ac_optarg" ;; | |
250 | ||
251 | -disable-* | --disable-*) | |
252 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` | |
253 | # Reject names that are not valid shell variable names. | |
254 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
255 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
256 | fi | |
257 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
258 | eval "enable_${ac_feature}=no" ;; | |
259 | ||
260 | -enable-* | --enable-*) | |
261 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` | |
262 | # Reject names that are not valid shell variable names. | |
263 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
264 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } | |
265 | fi | |
266 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` | |
267 | case "$ac_option" in | |
268 | *=*) ;; | |
269 | *) ac_optarg=yes ;; | |
270 | esac | |
271 | eval "enable_${ac_feature}='$ac_optarg'" ;; | |
272 | ||
273 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
274 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
275 | | --exec | --exe | --ex) | |
276 | ac_prev=exec_prefix ;; | |
277 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
278 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
279 | | --exec=* | --exe=* | --ex=*) | |
280 | exec_prefix="$ac_optarg" ;; | |
281 | ||
282 | -gas | --gas | --ga | --g) | |
283 | # Obsolete; use --with-gas. | |
284 | with_gas=yes ;; | |
285 | ||
286 | -help | --help | --hel | --he) | |
287 | # Omit some internal or obsolete options to make the list less imposing. | |
288 | # This message is too long to be a string in the A/UX 3.1 sh. | |
289 | cat << EOF | |
290 | Usage: configure [options] [host] | |
291 | Options: [defaults in brackets after descriptions] | |
292 | Configuration: | |
293 | --cache-file=FILE cache test results in FILE | |
294 | --help print this message | |
295 | --no-create do not create output files | |
296 | --quiet, --silent do not print \`checking...' messages | |
297 | --site-file=FILE use FILE as the site file | |
298 | --version print the version of autoconf that created configure | |
299 | Directory and file names: | |
300 | --prefix=PREFIX install architecture-independent files in PREFIX | |
301 | [$ac_default_prefix] | |
302 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX | |
303 | [same as prefix] | |
304 | --bindir=DIR user executables in DIR [EPREFIX/bin] | |
305 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] | |
306 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] | |
307 | --datadir=DIR read-only architecture-independent data in DIR | |
308 | [PREFIX/share] | |
309 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] | |
310 | --sharedstatedir=DIR modifiable architecture-independent data in DIR | |
311 | [PREFIX/com] | |
312 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] | |
313 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] | |
314 | --includedir=DIR C header files in DIR [PREFIX/include] | |
315 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] | |
316 | --infodir=DIR info documentation in DIR [PREFIX/info] | |
317 | --mandir=DIR man documentation in DIR [PREFIX/man] | |
318 | --srcdir=DIR find the sources in DIR [configure dir or ..] | |
319 | --program-prefix=PREFIX prepend PREFIX to installed program names | |
320 | --program-suffix=SUFFIX append SUFFIX to installed program names | |
321 | --program-transform-name=PROGRAM | |
322 | run sed PROGRAM on installed program names | |
323 | EOF | |
324 | cat << EOF | |
325 | Host type: | |
326 | --build=BUILD configure for building on BUILD [BUILD=HOST] | |
327 | --host=HOST configure for HOST [guessed] | |
328 | --target=TARGET configure for TARGET [TARGET=HOST] | |
329 | Features and packages: | |
330 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) | |
331 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
332 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
333 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
334 | --x-includes=DIR X include files are in DIR | |
335 | --x-libraries=DIR X library files are in DIR | |
336 | EOF | |
337 | if test -n "$ac_help"; then | |
338 | echo "--enable and --with options recognized:$ac_help" | |
339 | fi | |
340 | exit 0 ;; | |
341 | ||
342 | -host | --host | --hos | --ho) | |
343 | ac_prev=host ;; | |
344 | -host=* | --host=* | --hos=* | --ho=*) | |
345 | host="$ac_optarg" ;; | |
346 | ||
347 | -includedir | --includedir | --includedi | --included | --include \ | |
348 | | --includ | --inclu | --incl | --inc) | |
349 | ac_prev=includedir ;; | |
350 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
351 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
352 | includedir="$ac_optarg" ;; | |
353 | ||
354 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
355 | ac_prev=infodir ;; | |
356 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
357 | infodir="$ac_optarg" ;; | |
358 | ||
359 | -libdir | --libdir | --libdi | --libd) | |
360 | ac_prev=libdir ;; | |
361 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
362 | libdir="$ac_optarg" ;; | |
363 | ||
364 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
365 | | --libexe | --libex | --libe) | |
366 | ac_prev=libexecdir ;; | |
367 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
368 | | --libexe=* | --libex=* | --libe=*) | |
369 | libexecdir="$ac_optarg" ;; | |
370 | ||
371 | -localstatedir | --localstatedir | --localstatedi | --localstated \ | |
372 | | --localstate | --localstat | --localsta | --localst \ | |
373 | | --locals | --local | --loca | --loc | --lo) | |
374 | ac_prev=localstatedir ;; | |
375 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
376 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ | |
377 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) | |
378 | localstatedir="$ac_optarg" ;; | |
379 | ||
380 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
381 | ac_prev=mandir ;; | |
382 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
383 | mandir="$ac_optarg" ;; | |
384 | ||
385 | -nfp | --nfp | --nf) | |
386 | # Obsolete; use --without-fp. | |
387 | with_fp=no ;; | |
388 | ||
389 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
390 | | --no-cr | --no-c) | |
391 | no_create=yes ;; | |
392 | ||
393 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
394 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
395 | no_recursion=yes ;; | |
396 | ||
397 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
398 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
399 | | --oldin | --oldi | --old | --ol | --o) | |
400 | ac_prev=oldincludedir ;; | |
401 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
402 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
403 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
404 | oldincludedir="$ac_optarg" ;; | |
405 | ||
406 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
407 | ac_prev=prefix ;; | |
408 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
409 | prefix="$ac_optarg" ;; | |
410 | ||
411 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
412 | | --program-pre | --program-pr | --program-p) | |
413 | ac_prev=program_prefix ;; | |
414 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
415 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
416 | program_prefix="$ac_optarg" ;; | |
417 | ||
418 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
419 | | --program-suf | --program-su | --program-s) | |
420 | ac_prev=program_suffix ;; | |
421 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
422 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
423 | program_suffix="$ac_optarg" ;; | |
424 | ||
425 | -program-transform-name | --program-transform-name \ | |
426 | | --program-transform-nam | --program-transform-na \ | |
427 | | --program-transform-n | --program-transform- \ | |
428 | | --program-transform | --program-transfor \ | |
429 | | --program-transfo | --program-transf \ | |
430 | | --program-trans | --program-tran \ | |
431 | | --progr-tra | --program-tr | --program-t) | |
432 | ac_prev=program_transform_name ;; | |
433 | -program-transform-name=* | --program-transform-name=* \ | |
434 | | --program-transform-nam=* | --program-transform-na=* \ | |
435 | | --program-transform-n=* | --program-transform-=* \ | |
436 | | --program-transform=* | --program-transfor=* \ | |
437 | | --program-transfo=* | --program-transf=* \ | |
438 | | --program-trans=* | --program-tran=* \ | |
439 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
440 | program_transform_name="$ac_optarg" ;; | |
441 | ||
442 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
443 | | -silent | --silent | --silen | --sile | --sil) | |
444 | silent=yes ;; | |
445 | ||
446 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
447 | ac_prev=sbindir ;; | |
448 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
449 | | --sbi=* | --sb=*) | |
450 | sbindir="$ac_optarg" ;; | |
451 | ||
452 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
453 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
454 | | --sharedst | --shareds | --shared | --share | --shar \ | |
455 | | --sha | --sh) | |
456 | ac_prev=sharedstatedir ;; | |
457 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
458 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
459 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
460 | | --sha=* | --sh=*) | |
461 | sharedstatedir="$ac_optarg" ;; | |
462 | ||
463 | -site | --site | --sit) | |
464 | ac_prev=site ;; | |
465 | -site=* | --site=* | --sit=*) | |
466 | site="$ac_optarg" ;; | |
467 | ||
468 | -site-file | --site-file | --site-fil | --site-fi | --site-f) | |
469 | ac_prev=sitefile ;; | |
470 | -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*) | |
471 | sitefile="$ac_optarg" ;; | |
472 | ||
473 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
474 | ac_prev=srcdir ;; | |
475 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
476 | srcdir="$ac_optarg" ;; | |
477 | ||
478 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
479 | | --syscon | --sysco | --sysc | --sys | --sy) | |
480 | ac_prev=sysconfdir ;; | |
481 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
482 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
483 | sysconfdir="$ac_optarg" ;; | |
484 | ||
485 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
486 | ac_prev=target ;; | |
487 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) | |
488 | target="$ac_optarg" ;; | |
489 | ||
490 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
491 | verbose=yes ;; | |
492 | ||
493 | -version | --version | --versio | --versi | --vers) | |
494 | echo "configure generated by autoconf version 2.13" | |
495 | exit 0 ;; | |
496 | ||
497 | -with-* | --with-*) | |
498 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` | |
499 | # Reject names that are not valid shell variable names. | |
500 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then | |
501 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
502 | fi | |
503 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
504 | case "$ac_option" in | |
505 | *=*) ;; | |
506 | *) ac_optarg=yes ;; | |
507 | esac | |
508 | eval "with_${ac_package}='$ac_optarg'" ;; | |
509 | ||
510 | -without-* | --without-*) | |
511 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` | |
512 | # Reject names that are not valid shell variable names. | |
513 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then | |
514 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } | |
515 | fi | |
516 | ac_package=`echo $ac_package| sed 's/-/_/g'` | |
517 | eval "with_${ac_package}=no" ;; | |
518 | ||
519 | --x) | |
520 | # Obsolete; use --with-x. | |
521 | with_x=yes ;; | |
522 | ||
523 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
524 | | --x-incl | --x-inc | --x-in | --x-i) | |
525 | ac_prev=x_includes ;; | |
526 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
527 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
528 | x_includes="$ac_optarg" ;; | |
529 | ||
530 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
531 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
532 | ac_prev=x_libraries ;; | |
533 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
534 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
535 | x_libraries="$ac_optarg" ;; | |
536 | ||
537 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } | |
538 | ;; | |
539 | ||
540 | *) | |
541 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then | |
542 | echo "configure: warning: $ac_option: invalid host type" 1>&2 | |
543 | fi | |
544 | if test "x$nonopt" != xNONE; then | |
545 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } | |
546 | fi | |
547 | nonopt="$ac_option" | |
548 | ;; | |
549 | ||
550 | esac | |
551 | done | |
552 | ||
553 | if test -n "$ac_prev"; then | |
554 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } | |
555 | fi | |
556 | ||
557 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
558 | ||
559 | # File descriptor usage: | |
560 | # 0 standard input | |
561 | # 1 file creation | |
562 | # 2 errors and warnings | |
563 | # 3 some systems may open it to /dev/tty | |
564 | # 4 used on the Kubota Titan | |
565 | # 6 checking for... messages and results | |
566 | # 5 compiler messages saved in config.log | |
567 | if test "$silent" = yes; then | |
568 | exec 6>/dev/null | |
569 | else | |
570 | exec 6>&1 | |
571 | fi | |
572 | exec 5>./config.log | |
573 | ||
574 | echo "\ | |
575 | This file contains any messages produced by compilers while | |
576 | running configure, to aid debugging if configure makes a mistake. | |
577 | " 1>&5 | |
578 | ||
579 | # Strip out --no-create and --no-recursion so they do not pile up. | |
580 | # Also quote any args containing shell metacharacters. | |
581 | ac_configure_args= | |
582 | for ac_arg | |
583 | do | |
584 | case "$ac_arg" in | |
585 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
586 | | --no-cr | --no-c) ;; | |
587 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
588 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; | |
589 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) | |
590 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; | |
591 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; | |
592 | esac | |
593 | done | |
594 | ||
595 | # NLS nuisances. | |
596 | # Only set these to C if already set. These must not be set unconditionally | |
597 | # because not all systems understand e.g. LANG=C (notably SCO). | |
598 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! | |
599 | # Non-C LC_CTYPE values break the ctype check. | |
600 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi | |
601 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi | |
602 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi | |
603 | if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi | |
604 | ||
605 | # confdefs.h avoids OS command line length limits that DEFS can exceed. | |
606 | rm -rf conftest* confdefs.h | |
607 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. | |
608 | echo > confdefs.h | |
609 | ||
610 | # A filename unique to this package, relative to the directory that | |
611 | # configure is in, which we can look for to find out if srcdir is correct. | |
612 | ac_unique_file=Makefile.in | |
613 | ||
614 | # Find the source files, if location was not specified. | |
615 | if test -z "$srcdir"; then | |
616 | ac_srcdir_defaulted=yes | |
617 | # Try the directory containing this script, then its parent. | |
618 | ac_prog=$0 | |
619 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` | |
620 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. | |
621 | srcdir=$ac_confdir | |
622 | if test ! -r $srcdir/$ac_unique_file; then | |
623 | srcdir=.. | |
624 | fi | |
625 | else | |
626 | ac_srcdir_defaulted=no | |
627 | fi | |
628 | if test ! -r $srcdir/$ac_unique_file; then | |
629 | if test "$ac_srcdir_defaulted" = yes; then | |
630 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } | |
631 | else | |
632 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } | |
633 | fi | |
634 | fi | |
635 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` | |
636 | ||
637 | # Prefer explicitly selected file to automatically selected ones. | |
638 | if test -z "$sitefile"; then | |
639 | if test -z "$CONFIG_SITE"; then | |
640 | if test "x$prefix" != xNONE; then | |
641 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" | |
642 | else | |
643 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" | |
644 | fi | |
645 | fi | |
646 | else | |
647 | CONFIG_SITE="$sitefile" | |
648 | fi | |
649 | for ac_site_file in $CONFIG_SITE; do | |
650 | if test -r "$ac_site_file"; then | |
651 | echo "loading site script $ac_site_file" | |
652 | . "$ac_site_file" | |
653 | fi | |
654 | done | |
655 | ||
656 | if test -r "$cache_file"; then | |
657 | echo "loading cache $cache_file" | |
658 | . $cache_file | |
659 | else | |
660 | echo "creating cache $cache_file" | |
661 | > $cache_file | |
662 | fi | |
663 | ||
664 | ac_ext=c | |
665 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
666 | ac_cpp='$CPP $CPPFLAGS' | |
667 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
668 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
669 | cross_compiling=$ac_cv_prog_cc_cross | |
670 | ||
671 | ac_exeext= | |
672 | ac_objext=o | |
673 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then | |
674 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. | |
675 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then | |
676 | ac_n= ac_c=' | |
677 | ' ac_t=' ' | |
678 | else | |
679 | ac_n=-n ac_c= ac_t= | |
680 | fi | |
681 | else | |
682 | ac_n= ac_c='\c' ac_t= | |
683 | fi | |
684 | ||
685 | ||
686 | ||
687 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 | |
688 | echo "configure:689: checking how to run the C preprocessor" >&5 | |
689 | # On Suns, sometimes $CPP names a directory. | |
690 | if test -n "$CPP" && test -d "$CPP"; then | |
691 | CPP= | |
692 | fi | |
693 | if test -z "$CPP"; then | |
694 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then | |
695 | echo $ac_n "(cached) $ac_c" 1>&6 | |
696 | else | |
697 | # This must be in double quotes, not single quotes, because CPP may get | |
698 | # substituted into the Makefile and "${CC-cc}" will confuse make. | |
699 | CPP="${CC-cc} -E" | |
700 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
701 | # not just through cpp. | |
702 | cat > conftest.$ac_ext <<EOF | |
703 | #line 704 "configure" | |
704 | #include "confdefs.h" | |
705 | #include <assert.h> | |
706 | Syntax Error | |
707 | EOF | |
708 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
709 | { (eval echo configure:710: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
710 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
711 | if test -z "$ac_err"; then | |
712 | : | |
713 | else | |
714 | echo "$ac_err" >&5 | |
715 | echo "configure: failed program was:" >&5 | |
716 | cat conftest.$ac_ext >&5 | |
717 | rm -rf conftest* | |
718 | CPP="${CC-cc} -E -traditional-cpp" | |
719 | cat > conftest.$ac_ext <<EOF | |
720 | #line 721 "configure" | |
721 | #include "confdefs.h" | |
722 | #include <assert.h> | |
723 | Syntax Error | |
724 | EOF | |
725 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
726 | { (eval echo configure:727: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
727 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
728 | if test -z "$ac_err"; then | |
729 | : | |
730 | else | |
731 | echo "$ac_err" >&5 | |
732 | echo "configure: failed program was:" >&5 | |
733 | cat conftest.$ac_ext >&5 | |
734 | rm -rf conftest* | |
735 | CPP="${CC-cc} -nologo -E" | |
736 | cat > conftest.$ac_ext <<EOF | |
737 | #line 738 "configure" | |
738 | #include "confdefs.h" | |
739 | #include <assert.h> | |
740 | Syntax Error | |
741 | EOF | |
742 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
743 | { (eval echo configure:744: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
744 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
745 | if test -z "$ac_err"; then | |
746 | : | |
747 | else | |
748 | echo "$ac_err" >&5 | |
749 | echo "configure: failed program was:" >&5 | |
750 | cat conftest.$ac_ext >&5 | |
751 | rm -rf conftest* | |
752 | CPP=/lib/cpp | |
753 | fi | |
754 | rm -f conftest* | |
755 | fi | |
756 | rm -f conftest* | |
757 | fi | |
758 | rm -f conftest* | |
759 | ac_cv_prog_CPP="$CPP" | |
760 | fi | |
761 | CPP="$ac_cv_prog_CPP" | |
762 | else | |
763 | ac_cv_prog_CPP="$CPP" | |
764 | fi | |
765 | echo "$ac_t""$CPP" 1>&6 | |
766 | ||
767 | echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 | |
768 | echo "configure:769: checking whether ${MAKE-make} sets \${MAKE}" >&5 | |
769 | set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` | |
770 | if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then | |
771 | echo $ac_n "(cached) $ac_c" 1>&6 | |
772 | else | |
773 | cat > conftestmake <<\EOF | |
774 | all: | |
775 | @echo 'ac_maketemp="${MAKE}"' | |
776 | EOF | |
777 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | |
778 | eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` | |
779 | if test -n "$ac_maketemp"; then | |
780 | eval ac_cv_prog_make_${ac_make}_set=yes | |
781 | else | |
782 | eval ac_cv_prog_make_${ac_make}_set=no | |
783 | fi | |
784 | rm -f conftestmake | |
785 | fi | |
786 | if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then | |
787 | echo "$ac_t""yes" 1>&6 | |
788 | SET_MAKE= | |
789 | else | |
790 | echo "$ac_t""no" 1>&6 | |
791 | SET_MAKE="MAKE=${MAKE-make}" | |
792 | fi | |
793 | ||
794 | echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6 | |
795 | echo "configure:796: checking for POSIXized ISC" >&5 | |
796 | if test -d /etc/conf/kconfig.d && | |
797 | grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1 | |
798 | then | |
799 | echo "$ac_t""yes" 1>&6 | |
800 | ISC=yes # If later tests want to check for ISC. | |
801 | cat >> confdefs.h <<\EOF | |
802 | #define _POSIX_SOURCE 1 | |
803 | EOF | |
804 | ||
805 | if test "$GCC" = yes; then | |
806 | CC="$CC -posix" | |
807 | else | |
808 | CC="$CC -Xp" | |
809 | fi | |
810 | else | |
811 | echo "$ac_t""no" 1>&6 | |
812 | ISC= | |
813 | fi | |
814 | ||
815 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 | |
816 | echo "configure:817: checking for ANSI C header files" >&5 | |
817 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then | |
818 | echo $ac_n "(cached) $ac_c" 1>&6 | |
819 | else | |
820 | cat > conftest.$ac_ext <<EOF | |
821 | #line 822 "configure" | |
822 | #include "confdefs.h" | |
823 | #include <stdlib.h> | |
824 | #include <stdarg.h> | |
825 | #include <string.h> | |
826 | #include <float.h> | |
827 | EOF | |
828 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
829 | { (eval echo configure:830: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
830 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
831 | if test -z "$ac_err"; then | |
832 | rm -rf conftest* | |
833 | ac_cv_header_stdc=yes | |
834 | else | |
835 | echo "$ac_err" >&5 | |
836 | echo "configure: failed program was:" >&5 | |
837 | cat conftest.$ac_ext >&5 | |
838 | rm -rf conftest* | |
839 | ac_cv_header_stdc=no | |
840 | fi | |
841 | rm -f conftest* | |
842 | ||
843 | if test $ac_cv_header_stdc = yes; then | |
844 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
845 | cat > conftest.$ac_ext <<EOF | |
846 | #line 847 "configure" | |
847 | #include "confdefs.h" | |
848 | #include <string.h> | |
849 | EOF | |
850 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
851 | egrep "memchr" >/dev/null 2>&1; then | |
852 | : | |
853 | else | |
854 | rm -rf conftest* | |
855 | ac_cv_header_stdc=no | |
856 | fi | |
857 | rm -f conftest* | |
858 | ||
859 | fi | |
860 | ||
861 | if test $ac_cv_header_stdc = yes; then | |
862 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
863 | cat > conftest.$ac_ext <<EOF | |
864 | #line 865 "configure" | |
865 | #include "confdefs.h" | |
866 | #include <stdlib.h> | |
867 | EOF | |
868 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
869 | egrep "free" >/dev/null 2>&1; then | |
870 | : | |
871 | else | |
872 | rm -rf conftest* | |
873 | ac_cv_header_stdc=no | |
874 | fi | |
875 | rm -f conftest* | |
876 | ||
877 | fi | |
878 | ||
879 | if test $ac_cv_header_stdc = yes; then | |
880 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
881 | if test "$cross_compiling" = yes; then | |
882 | : | |
883 | else | |
884 | cat > conftest.$ac_ext <<EOF | |
885 | #line 886 "configure" | |
886 | #include "confdefs.h" | |
887 | #include <ctype.h> | |
888 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
889 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
890 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
891 | int main () { int i; for (i = 0; i < 256; i++) | |
892 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); | |
893 | exit (0); } | |
894 | ||
895 | EOF | |
896 | if { (eval echo configure:897: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null | |
897 | then | |
898 | : | |
899 | else | |
900 | echo "configure: failed program was:" >&5 | |
901 | cat conftest.$ac_ext >&5 | |
902 | rm -fr conftest* | |
903 | ac_cv_header_stdc=no | |
904 | fi | |
905 | rm -fr conftest* | |
906 | fi | |
907 | ||
908 | fi | |
909 | fi | |
910 | ||
911 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 | |
912 | if test $ac_cv_header_stdc = yes; then | |
913 | cat >> confdefs.h <<\EOF | |
914 | #define STDC_HEADERS 1 | |
915 | EOF | |
916 | ||
917 | fi | |
918 | ||
919 | echo $ac_n "checking for working const""... $ac_c" 1>&6 | |
920 | echo "configure:921: checking for working const" >&5 | |
921 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then | |
922 | echo $ac_n "(cached) $ac_c" 1>&6 | |
923 | else | |
924 | cat > conftest.$ac_ext <<EOF | |
925 | #line 926 "configure" | |
926 | #include "confdefs.h" | |
927 | ||
928 | int main() { | |
929 | ||
930 | /* Ultrix mips cc rejects this. */ | |
931 | typedef int charset[2]; const charset x; | |
932 | /* SunOS 4.1.1 cc rejects this. */ | |
933 | char const *const *ccp; | |
934 | char **p; | |
935 | /* NEC SVR4.0.2 mips cc rejects this. */ | |
936 | struct point {int x, y;}; | |
937 | static struct point const zero = {0,0}; | |
938 | /* AIX XL C 1.02.0.0 rejects this. | |
939 | It does not let you subtract one const X* pointer from another in an arm | |
940 | of an if-expression whose if-part is not a constant expression */ | |
941 | const char *g = "string"; | |
942 | ccp = &g + (g ? g-g : 0); | |
943 | /* HPUX 7.0 cc rejects these. */ | |
944 | ++ccp; | |
945 | p = (char**) ccp; | |
946 | ccp = (char const *const *) p; | |
947 | { /* SCO 3.2v4 cc rejects this. */ | |
948 | char *t; | |
949 | char const *s = 0 ? (char *) 0 : (char const *) 0; | |
950 | ||
951 | *t++ = 0; | |
952 | } | |
953 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
954 | int x[] = {25, 17}; | |
955 | const int *foo = &x[0]; | |
956 | ++foo; | |
957 | } | |
958 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
959 | typedef const int *iptr; | |
960 | iptr p = 0; | |
961 | ++p; | |
962 | } | |
963 | { /* AIX XL C 1.02.0.0 rejects this saying | |
964 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ | |
965 | struct s { int j; const int *ap[3]; }; | |
966 | struct s *b; b->j = 5; | |
967 | } | |
968 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
969 | const int foo = 10; | |
970 | } | |
971 | ||
972 | ; return 0; } | |
973 | EOF | |
974 | if { (eval echo configure:975: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | |
975 | rm -rf conftest* | |
976 | ac_cv_c_const=yes | |
977 | else | |
978 | echo "configure: failed program was:" >&5 | |
979 | cat conftest.$ac_ext >&5 | |
980 | rm -rf conftest* | |
981 | ac_cv_c_const=no | |
982 | fi | |
983 | rm -f conftest* | |
984 | fi | |
985 | ||
986 | echo "$ac_t""$ac_cv_c_const" 1>&6 | |
987 | if test $ac_cv_c_const = no; then | |
988 | cat >> confdefs.h <<\EOF | |
989 | #define const | |
990 | EOF | |
991 | ||
992 | fi | |
993 | ||
994 | echo $ac_n "checking for inline""... $ac_c" 1>&6 | |
995 | echo "configure:996: checking for inline" >&5 | |
996 | if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then | |
997 | echo $ac_n "(cached) $ac_c" 1>&6 | |
998 | else | |
999 | ac_cv_c_inline=no | |
1000 | for ac_kw in inline __inline__ __inline; do | |
1001 | cat > conftest.$ac_ext <<EOF | |
1002 | #line 1003 "configure" | |
1003 | #include "confdefs.h" | |
1004 | ||
1005 | int main() { | |
1006 | } $ac_kw foo() { | |
1007 | ; return 0; } | |
1008 | EOF | |
1009 | if { (eval echo configure:1010: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | |
1010 | rm -rf conftest* | |
1011 | ac_cv_c_inline=$ac_kw; break | |
1012 | else | |
1013 | echo "configure: failed program was:" >&5 | |
1014 | cat conftest.$ac_ext >&5 | |
1015 | fi | |
1016 | rm -f conftest* | |
1017 | done | |
1018 | ||
1019 | fi | |
1020 | ||
1021 | echo "$ac_t""$ac_cv_c_inline" 1>&6 | |
1022 | case "$ac_cv_c_inline" in | |
1023 | inline | yes) ;; | |
1024 | no) cat >> confdefs.h <<\EOF | |
1025 | #define inline | |
1026 | EOF | |
1027 | ;; | |
1028 | *) cat >> confdefs.h <<EOF | |
1029 | #define inline $ac_cv_c_inline | |
1030 | EOF | |
1031 | ;; | |
1032 | esac | |
1033 | ||
1034 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 | |
1035 | echo "configure:1036: checking for off_t" >&5 | |
1036 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then | |
1037 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1038 | else | |
1039 | cat > conftest.$ac_ext <<EOF | |
1040 | #line 1041 "configure" | |
1041 | #include "confdefs.h" | |
1042 | #include <sys/types.h> | |
1043 | #if STDC_HEADERS | |
1044 | #include <stdlib.h> | |
1045 | #include <stddef.h> | |
1046 | #endif | |
1047 | EOF | |
1048 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1049 | egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
1050 | rm -rf conftest* | |
1051 | ac_cv_type_off_t=yes | |
1052 | else | |
1053 | rm -rf conftest* | |
1054 | ac_cv_type_off_t=no | |
1055 | fi | |
1056 | rm -f conftest* | |
1057 | ||
1058 | fi | |
1059 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 | |
1060 | if test $ac_cv_type_off_t = no; then | |
1061 | cat >> confdefs.h <<\EOF | |
1062 | #define off_t long | |
1063 | EOF | |
1064 | ||
1065 | fi | |
1066 | ||
1067 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 | |
1068 | echo "configure:1069: checking for size_t" >&5 | |
1069 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then | |
1070 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1071 | else | |
1072 | cat > conftest.$ac_ext <<EOF | |
1073 | #line 1074 "configure" | |
1074 | #include "confdefs.h" | |
1075 | #include <sys/types.h> | |
1076 | #if STDC_HEADERS | |
1077 | #include <stdlib.h> | |
1078 | #include <stddef.h> | |
1079 | #endif | |
1080 | EOF | |
1081 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1082 | egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then | |
1083 | rm -rf conftest* | |
1084 | ac_cv_type_size_t=yes | |
1085 | else | |
1086 | rm -rf conftest* | |
1087 | ac_cv_type_size_t=no | |
1088 | fi | |
1089 | rm -f conftest* | |
1090 | ||
1091 | fi | |
1092 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 | |
1093 | if test $ac_cv_type_size_t = no; then | |
1094 | cat >> confdefs.h <<\EOF | |
1095 | #define size_t unsigned | |
1096 | EOF | |
1097 | ||
1098 | fi | |
1099 | ||
1100 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works | |
1101 | # for constant arguments. Useless! | |
1102 | echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 | |
1103 | echo "configure:1104: checking for working alloca.h" >&5 | |
1104 | if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then | |
1105 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1106 | else | |
1107 | cat > conftest.$ac_ext <<EOF | |
1108 | #line 1109 "configure" | |
1109 | #include "confdefs.h" | |
1110 | #include <alloca.h> | |
1111 | int main() { | |
1112 | char *p = alloca(2 * sizeof(int)); | |
1113 | ; return 0; } | |
1114 | EOF | |
1115 | if { (eval echo configure:1116: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
1116 | rm -rf conftest* | |
1117 | ac_cv_header_alloca_h=yes | |
1118 | else | |
1119 | echo "configure: failed program was:" >&5 | |
1120 | cat conftest.$ac_ext >&5 | |
1121 | rm -rf conftest* | |
1122 | ac_cv_header_alloca_h=no | |
1123 | fi | |
1124 | rm -f conftest* | |
1125 | fi | |
1126 | ||
1127 | echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 | |
1128 | if test $ac_cv_header_alloca_h = yes; then | |
1129 | cat >> confdefs.h <<\EOF | |
1130 | #define HAVE_ALLOCA_H 1 | |
1131 | EOF | |
1132 | ||
1133 | fi | |
1134 | ||
1135 | echo $ac_n "checking for alloca""... $ac_c" 1>&6 | |
1136 | echo "configure:1137: checking for alloca" >&5 | |
1137 | if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then | |
1138 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1139 | else | |
1140 | cat > conftest.$ac_ext <<EOF | |
1141 | #line 1142 "configure" | |
1142 | #include "confdefs.h" | |
1143 | ||
1144 | #ifdef __GNUC__ | |
1145 | # define alloca __builtin_alloca | |
1146 | #else | |
1147 | # ifdef _MSC_VER | |
1148 | # include <malloc.h> | |
1149 | # define alloca _alloca | |
1150 | # else | |
1151 | # if HAVE_ALLOCA_H | |
1152 | # include <alloca.h> | |
1153 | # else | |
1154 | # ifdef _AIX | |
1155 | #pragma alloca | |
1156 | # else | |
1157 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
1158 | char *alloca (); | |
1159 | # endif | |
1160 | # endif | |
1161 | # endif | |
1162 | # endif | |
1163 | #endif | |
1164 | ||
1165 | int main() { | |
1166 | char *p = (char *) alloca(1); | |
1167 | ; return 0; } | |
1168 | EOF | |
1169 | if { (eval echo configure:1170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
1170 | rm -rf conftest* | |
1171 | ac_cv_func_alloca_works=yes | |
1172 | else | |
1173 | echo "configure: failed program was:" >&5 | |
1174 | cat conftest.$ac_ext >&5 | |
1175 | rm -rf conftest* | |
1176 | ac_cv_func_alloca_works=no | |
1177 | fi | |
1178 | rm -f conftest* | |
1179 | fi | |
1180 | ||
1181 | echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 | |
1182 | if test $ac_cv_func_alloca_works = yes; then | |
1183 | cat >> confdefs.h <<\EOF | |
1184 | #define HAVE_ALLOCA 1 | |
1185 | EOF | |
1186 | ||
1187 | fi | |
1188 | ||
1189 | if test $ac_cv_func_alloca_works = no; then | |
1190 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
1191 | # that cause trouble. Some versions do not even contain alloca or | |
1192 | # contain a buggy version. If you still want to use their alloca, | |
1193 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
1194 | ALLOCA=alloca.${ac_objext} | |
1195 | cat >> confdefs.h <<\EOF | |
1196 | #define C_ALLOCA 1 | |
1197 | EOF | |
1198 | ||
1199 | ||
1200 | echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 | |
1201 | echo "configure:1202: checking whether alloca needs Cray hooks" >&5 | |
1202 | if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then | |
1203 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1204 | else | |
1205 | cat > conftest.$ac_ext <<EOF | |
1206 | #line 1207 "configure" | |
1207 | #include "confdefs.h" | |
1208 | #if defined(CRAY) && ! defined(CRAY2) | |
1209 | webecray | |
1210 | #else | |
1211 | wenotbecray | |
1212 | #endif | |
1213 | ||
1214 | EOF | |
1215 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1216 | egrep "webecray" >/dev/null 2>&1; then | |
1217 | rm -rf conftest* | |
1218 | ac_cv_os_cray=yes | |
1219 | else | |
1220 | rm -rf conftest* | |
1221 | ac_cv_os_cray=no | |
1222 | fi | |
1223 | rm -f conftest* | |
1224 | ||
1225 | fi | |
1226 | ||
1227 | echo "$ac_t""$ac_cv_os_cray" 1>&6 | |
1228 | if test $ac_cv_os_cray = yes; then | |
1229 | for ac_func in _getb67 GETB67 getb67; do | |
1230 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
1231 | echo "configure:1232: checking for $ac_func" >&5 | |
1232 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then | |
1233 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1234 | else | |
1235 | cat > conftest.$ac_ext <<EOF | |
1236 | #line 1237 "configure" | |
1237 | #include "confdefs.h" | |
1238 | /* System header to define __stub macros and hopefully few prototypes, | |
1239 | which can conflict with char $ac_func(); below. */ | |
1240 | #include <assert.h> | |
1241 | /* Override any gcc2 internal prototype to avoid an error. */ | |
1242 | /* We use char because int might match the return type of a gcc2 | |
1243 | builtin and then its argument prototype would still apply. */ | |
1244 | char $ac_func(); | |
1245 | ||
1246 | int main() { | |
1247 | ||
1248 | /* The GNU C library defines this for functions which it implements | |
1249 | to always fail with ENOSYS. Some functions are actually named | |
1250 | something starting with __ and the normal name is an alias. */ | |
1251 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
1252 | choke me | |
1253 | #else | |
1254 | $ac_func(); | |
1255 | #endif | |
1256 | ||
1257 | ; return 0; } | |
1258 | EOF | |
1259 | if { (eval echo configure:1260: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
1260 | rm -rf conftest* | |
1261 | eval "ac_cv_func_$ac_func=yes" | |
1262 | else | |
1263 | echo "configure: failed program was:" >&5 | |
1264 | cat conftest.$ac_ext >&5 | |
1265 | rm -rf conftest* | |
1266 | eval "ac_cv_func_$ac_func=no" | |
1267 | fi | |
1268 | rm -f conftest* | |
1269 | fi | |
1270 | ||
1271 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
1272 | echo "$ac_t""yes" 1>&6 | |
1273 | cat >> confdefs.h <<EOF | |
1274 | #define CRAY_STACKSEG_END $ac_func | |
1275 | EOF | |
1276 | ||
1277 | break | |
1278 | else | |
1279 | echo "$ac_t""no" 1>&6 | |
1280 | fi | |
1281 | ||
1282 | done | |
1283 | fi | |
1284 | ||
1285 | echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 | |
1286 | echo "configure:1287: checking stack direction for C alloca" >&5 | |
1287 | if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then | |
1288 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1289 | else | |
1290 | if test "$cross_compiling" = yes; then | |
1291 | ac_cv_c_stack_direction=0 | |
1292 | else | |
1293 | cat > conftest.$ac_ext <<EOF | |
1294 | #line 1295 "configure" | |
1295 | #include "confdefs.h" | |
1296 | find_stack_direction () | |
1297 | { | |
1298 | static char *addr = 0; | |
1299 | auto char dummy; | |
1300 | if (addr == 0) | |
1301 | { | |
1302 | addr = &dummy; | |
1303 | return find_stack_direction (); | |
1304 | } | |
1305 | else | |
1306 | return (&dummy > addr) ? 1 : -1; | |
1307 | } | |
1308 | main () | |
1309 | { | |
1310 | exit (find_stack_direction() < 0); | |
1311 | } | |
1312 | EOF | |
1313 | if { (eval echo configure:1314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null | |
1314 | then | |
1315 | ac_cv_c_stack_direction=1 | |
1316 | else | |
1317 | echo "configure: failed program was:" >&5 | |
1318 | cat conftest.$ac_ext >&5 | |
1319 | rm -fr conftest* | |
1320 | ac_cv_c_stack_direction=-1 | |
1321 | fi | |
1322 | rm -fr conftest* | |
1323 | fi | |
1324 | ||
1325 | fi | |
1326 | ||
1327 | echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 | |
1328 | cat >> confdefs.h <<EOF | |
1329 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
1330 | EOF | |
1331 | ||
1332 | fi | |
1333 | ||
1334 | for ac_hdr in unistd.h | |
1335 | do | |
1336 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
1337 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
1338 | echo "configure:1339: checking for $ac_hdr" >&5 | |
1339 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
1340 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1341 | else | |
1342 | cat > conftest.$ac_ext <<EOF | |
1343 | #line 1344 "configure" | |
1344 | #include "confdefs.h" | |
1345 | #include <$ac_hdr> | |
1346 | EOF | |
1347 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
1348 | { (eval echo configure:1349: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
1349 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
1350 | if test -z "$ac_err"; then | |
1351 | rm -rf conftest* | |
1352 | eval "ac_cv_header_$ac_safe=yes" | |
1353 | else | |
1354 | echo "$ac_err" >&5 | |
1355 | echo "configure: failed program was:" >&5 | |
1356 | cat conftest.$ac_ext >&5 | |
1357 | rm -rf conftest* | |
1358 | eval "ac_cv_header_$ac_safe=no" | |
1359 | fi | |
1360 | rm -f conftest* | |
1361 | fi | |
1362 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
1363 | echo "$ac_t""yes" 1>&6 | |
1364 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
1365 | cat >> confdefs.h <<EOF | |
1366 | #define $ac_tr_hdr 1 | |
1367 | EOF | |
1368 | ||
1369 | else | |
1370 | echo "$ac_t""no" 1>&6 | |
1371 | fi | |
1372 | done | |
1373 | ||
1374 | for ac_func in getpagesize | |
1375 | do | |
1376 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
1377 | echo "configure:1378: checking for $ac_func" >&5 | |
1378 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then | |
1379 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1380 | else | |
1381 | cat > conftest.$ac_ext <<EOF | |
1382 | #line 1383 "configure" | |
1383 | #include "confdefs.h" | |
1384 | /* System header to define __stub macros and hopefully few prototypes, | |
1385 | which can conflict with char $ac_func(); below. */ | |
1386 | #include <assert.h> | |
1387 | /* Override any gcc2 internal prototype to avoid an error. */ | |
1388 | /* We use char because int might match the return type of a gcc2 | |
1389 | builtin and then its argument prototype would still apply. */ | |
1390 | char $ac_func(); | |
1391 | ||
1392 | int main() { | |
1393 | ||
1394 | /* The GNU C library defines this for functions which it implements | |
1395 | to always fail with ENOSYS. Some functions are actually named | |
1396 | something starting with __ and the normal name is an alias. */ | |
1397 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
1398 | choke me | |
1399 | #else | |
1400 | $ac_func(); | |
1401 | #endif | |
1402 | ||
1403 | ; return 0; } | |
1404 | EOF | |
1405 | if { (eval echo configure:1406: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
1406 | rm -rf conftest* | |
1407 | eval "ac_cv_func_$ac_func=yes" | |
1408 | else | |
1409 | echo "configure: failed program was:" >&5 | |
1410 | cat conftest.$ac_ext >&5 | |
1411 | rm -rf conftest* | |
1412 | eval "ac_cv_func_$ac_func=no" | |
1413 | fi | |
1414 | rm -f conftest* | |
1415 | fi | |
1416 | ||
1417 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
1418 | echo "$ac_t""yes" 1>&6 | |
1419 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
1420 | cat >> confdefs.h <<EOF | |
1421 | #define $ac_tr_func 1 | |
1422 | EOF | |
1423 | ||
1424 | else | |
1425 | echo "$ac_t""no" 1>&6 | |
1426 | fi | |
1427 | done | |
1428 | ||
1429 | echo $ac_n "checking for working mmap""... $ac_c" 1>&6 | |
1430 | echo "configure:1431: checking for working mmap" >&5 | |
1431 | if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then | |
1432 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1433 | else | |
1434 | if test "$cross_compiling" = yes; then | |
1435 | ac_cv_func_mmap_fixed_mapped=no | |
1436 | else | |
1437 | cat > conftest.$ac_ext <<EOF | |
1438 | #line 1439 "configure" | |
1439 | #include "confdefs.h" | |
1440 | ||
1441 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
1442 | Here is a matrix of mmap possibilities: | |
1443 | mmap private not fixed | |
1444 | mmap private fixed at somewhere currently unmapped | |
1445 | mmap private fixed at somewhere already mapped | |
1446 | mmap shared not fixed | |
1447 | mmap shared fixed at somewhere currently unmapped | |
1448 | mmap shared fixed at somewhere already mapped | |
1449 | For private mappings, we should verify that changes cannot be read() | |
1450 | back from the file, nor mmap's back from the file at a different | |
1451 | address. (There have been systems where private was not correctly | |
1452 | implemented like the infamous i386 svr4.0, and systems where the | |
1453 | VM page cache was not coherent with the filesystem buffer cache | |
1454 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
1455 | For shared mappings, we should conversely verify that changes get | |
1456 | propogated back to all the places they're supposed to be. | |
1457 | ||
1458 | Grep wants private fixed already mapped. | |
1459 | The main things grep needs to know about mmap are: | |
1460 | * does it exist and is it safe to write into the mmap'd area | |
1461 | * how to use it (BSD variants) */ | |
1462 | #include <sys/types.h> | |
1463 | #include <fcntl.h> | |
1464 | #include <sys/mman.h> | |
1465 | ||
1466 | /* This mess was copied from the GNU getpagesize.h. */ | |
1467 | #ifndef HAVE_GETPAGESIZE | |
1468 | # ifdef HAVE_UNISTD_H | |
1469 | # include <unistd.h> | |
1470 | # endif | |
1471 | ||
1472 | /* Assume that all systems that can run configure have sys/param.h. */ | |
1473 | # ifndef HAVE_SYS_PARAM_H | |
1474 | # define HAVE_SYS_PARAM_H 1 | |
1475 | # endif | |
1476 | ||
1477 | # ifdef _SC_PAGESIZE | |
1478 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
1479 | # else /* no _SC_PAGESIZE */ | |
1480 | # ifdef HAVE_SYS_PARAM_H | |
1481 | # include <sys/param.h> | |
1482 | # ifdef EXEC_PAGESIZE | |
1483 | # define getpagesize() EXEC_PAGESIZE | |
1484 | # else /* no EXEC_PAGESIZE */ | |
1485 | # ifdef NBPG | |
1486 | # define getpagesize() NBPG * CLSIZE | |
1487 | # ifndef CLSIZE | |
1488 | # define CLSIZE 1 | |
1489 | # endif /* no CLSIZE */ | |
1490 | # else /* no NBPG */ | |
1491 | # ifdef NBPC | |
1492 | # define getpagesize() NBPC | |
1493 | # else /* no NBPC */ | |
1494 | # ifdef PAGESIZE | |
1495 | # define getpagesize() PAGESIZE | |
1496 | # endif /* PAGESIZE */ | |
1497 | # endif /* no NBPC */ | |
1498 | # endif /* no NBPG */ | |
1499 | # endif /* no EXEC_PAGESIZE */ | |
1500 | # else /* no HAVE_SYS_PARAM_H */ | |
1501 | # define getpagesize() 8192 /* punt totally */ | |
1502 | # endif /* no HAVE_SYS_PARAM_H */ | |
1503 | # endif /* no _SC_PAGESIZE */ | |
1504 | ||
1505 | #endif /* no HAVE_GETPAGESIZE */ | |
1506 | ||
1507 | #ifdef __cplusplus | |
1508 | extern "C" { void *malloc(unsigned); } | |
1509 | #else | |
1510 | char *malloc(); | |
1511 | #endif | |
1512 | ||
1513 | int | |
1514 | main() | |
1515 | { | |
1516 | char *data, *data2, *data3; | |
1517 | int i, pagesize; | |
1518 | int fd; | |
1519 | ||
1520 | pagesize = getpagesize(); | |
1521 | ||
1522 | /* | |
1523 | * First, make a file with some known garbage in it. | |
1524 | */ | |
1525 | data = malloc(pagesize); | |
1526 | if (!data) | |
1527 | exit(1); | |
1528 | for (i = 0; i < pagesize; ++i) | |
1529 | *(data + i) = rand(); | |
1530 | umask(0); | |
1531 | fd = creat("conftestmmap", 0600); | |
1532 | if (fd < 0) | |
1533 | exit(1); | |
1534 | if (write(fd, data, pagesize) != pagesize) | |
1535 | exit(1); | |
1536 | close(fd); | |
1537 | ||
1538 | /* | |
1539 | * Next, try to mmap the file at a fixed address which | |
1540 | * already has something else allocated at it. If we can, | |
1541 | * also make sure that we see the same garbage. | |
1542 | */ | |
1543 | fd = open("conftestmmap", O_RDWR); | |
1544 | if (fd < 0) | |
1545 | exit(1); | |
1546 | data2 = malloc(2 * pagesize); | |
1547 | if (!data2) | |
1548 | exit(1); | |
1549 | data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); | |
1550 | if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, | |
1551 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
1552 | exit(1); | |
1553 | for (i = 0; i < pagesize; ++i) | |
1554 | if (*(data + i) != *(data2 + i)) | |
1555 | exit(1); | |
1556 | ||
1557 | /* | |
1558 | * Finally, make sure that changes to the mapped area | |
1559 | * do not percolate back to the file as seen by read(). | |
1560 | * (This is a bug on some variants of i386 svr4.0.) | |
1561 | */ | |
1562 | for (i = 0; i < pagesize; ++i) | |
1563 | *(data2 + i) = *(data2 + i) + 1; | |
1564 | data3 = malloc(pagesize); | |
1565 | if (!data3) | |
1566 | exit(1); | |
1567 | if (read(fd, data3, pagesize) != pagesize) | |
1568 | exit(1); | |
1569 | for (i = 0; i < pagesize; ++i) | |
1570 | if (*(data + i) != *(data3 + i)) | |
1571 | exit(1); | |
1572 | close(fd); | |
1573 | unlink("conftestmmap"); | |
1574 | exit(0); | |
1575 | } | |
1576 | ||
1577 | EOF | |
1578 | if { (eval echo configure:1579: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null | |
1579 | then | |
1580 | ac_cv_func_mmap_fixed_mapped=yes | |
1581 | else | |
1582 | echo "configure: failed program was:" >&5 | |
1583 | cat conftest.$ac_ext >&5 | |
1584 | rm -fr conftest* | |
1585 | ac_cv_func_mmap_fixed_mapped=no | |
1586 | fi | |
1587 | rm -fr conftest* | |
1588 | fi | |
1589 | ||
1590 | fi | |
1591 | ||
1592 | echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 | |
1593 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
1594 | cat >> confdefs.h <<\EOF | |
1595 | #define HAVE_MMAP 1 | |
1596 | EOF | |
1597 | ||
1598 | fi | |
1599 | ||
1600 | echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6 | |
1601 | echo "configure:1602: checking for Cygwin environment" >&5 | |
1602 | if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then | |
1603 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1604 | else | |
1605 | cat > conftest.$ac_ext <<EOF | |
1606 | #line 1607 "configure" | |
1607 | #include "confdefs.h" | |
1608 | ||
1609 | int main() { | |
1610 | ||
1611 | #ifndef __CYGWIN__ | |
1612 | #define __CYGWIN__ __CYGWIN32__ | |
1613 | #endif | |
1614 | return __CYGWIN__; | |
1615 | ; return 0; } | |
1616 | EOF | |
1617 | if { (eval echo configure:1618: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | |
1618 | rm -rf conftest* | |
1619 | ac_cv_cygwin=yes | |
1620 | else | |
1621 | echo "configure: failed program was:" >&5 | |
1622 | cat conftest.$ac_ext >&5 | |
1623 | rm -rf conftest* | |
1624 | ac_cv_cygwin=no | |
1625 | fi | |
1626 | rm -f conftest* | |
1627 | rm -f conftest* | |
1628 | fi | |
1629 | ||
1630 | echo "$ac_t""$ac_cv_cygwin" 1>&6 | |
1631 | CYGWIN= | |
1632 | test "$ac_cv_cygwin" = yes && CYGWIN=yes | |
1633 | echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6 | |
1634 | echo "configure:1635: checking for mingw32 environment" >&5 | |
1635 | if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then | |
1636 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1637 | else | |
1638 | cat > conftest.$ac_ext <<EOF | |
1639 | #line 1640 "configure" | |
1640 | #include "confdefs.h" | |
1641 | ||
1642 | int main() { | |
1643 | return __MINGW32__; | |
1644 | ; return 0; } | |
1645 | EOF | |
1646 | if { (eval echo configure:1647: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | |
1647 | rm -rf conftest* | |
1648 | ac_cv_mingw32=yes | |
1649 | else | |
1650 | echo "configure: failed program was:" >&5 | |
1651 | cat conftest.$ac_ext >&5 | |
1652 | rm -rf conftest* | |
1653 | ac_cv_mingw32=no | |
1654 | fi | |
1655 | rm -f conftest* | |
1656 | rm -f conftest* | |
1657 | fi | |
1658 | ||
1659 | echo "$ac_t""$ac_cv_mingw32" 1>&6 | |
1660 | MINGW32= | |
1661 | test "$ac_cv_mingw32" = yes && MINGW32=yes | |
1662 | ||
1663 | # autoconf.info says this should be called right after AC_INIT. | |
1664 | ||
1665 | ||
1666 | ac_aux_dir= | |
1667 | for ac_dir in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../..; do | |
1668 | if test -f $ac_dir/install-sh; then | |
1669 | ac_aux_dir=$ac_dir | |
1670 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
1671 | break | |
1672 | elif test -f $ac_dir/install.sh; then | |
1673 | ac_aux_dir=$ac_dir | |
1674 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
1675 | break | |
1676 | fi | |
1677 | done | |
1678 | if test -z "$ac_aux_dir"; then | |
1679 | { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../.." 1>&2; exit 1; } | |
1680 | fi | |
1681 | ac_config_guess=$ac_aux_dir/config.guess | |
1682 | ac_config_sub=$ac_aux_dir/config.sub | |
1683 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. | |
1684 | ||
1685 | ||
1686 | # Do some error checking and defaulting for the host and target type. | |
1687 | # The inputs are: | |
1688 | # configure --host=HOST --target=TARGET --build=BUILD NONOPT | |
1689 | # | |
1690 | # The rules are: | |
1691 | # 1. You are not allowed to specify --host, --target, and nonopt at the | |
1692 | # same time. | |
1693 | # 2. Host defaults to nonopt. | |
1694 | # 3. If nonopt is not specified, then host defaults to the current host, | |
1695 | # as determined by config.guess. | |
1696 | # 4. Target and build default to nonopt. | |
1697 | # 5. If nonopt is not specified, then target and build default to host. | |
1698 | ||
1699 | # The aliases save the names the user supplied, while $host etc. | |
1700 | # will get canonicalized. | |
1701 | case $host---$target---$nonopt in | |
1702 | NONE---*---* | *---NONE---* | *---*---NONE) ;; | |
1703 | *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;; | |
1704 | esac | |
1705 | ||
1706 | ||
1707 | # Make sure we can run config.sub. | |
1708 | if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then : | |
1709 | else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } | |
1710 | fi | |
1711 | ||
1712 | echo $ac_n "checking host system type""... $ac_c" 1>&6 | |
1713 | echo "configure:1714: checking host system type" >&5 | |
1714 | ||
1715 | host_alias=$host | |
1716 | case "$host_alias" in | |
1717 | NONE) | |
1718 | case $nonopt in | |
1719 | NONE) | |
1720 | if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then : | |
1721 | else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } | |
1722 | fi ;; | |
1723 | *) host_alias=$nonopt ;; | |
1724 | esac ;; | |
1725 | esac | |
1726 | ||
1727 | host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias` | |
1728 | host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
1729 | host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
1730 | host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
1731 | echo "$ac_t""$host" 1>&6 | |
1732 | ||
1733 | echo $ac_n "checking target system type""... $ac_c" 1>&6 | |
1734 | echo "configure:1735: checking target system type" >&5 | |
1735 | ||
1736 | target_alias=$target | |
1737 | case "$target_alias" in | |
1738 | NONE) | |
1739 | case $nonopt in | |
1740 | NONE) target_alias=$host_alias ;; | |
1741 | *) target_alias=$nonopt ;; | |
1742 | esac ;; | |
1743 | esac | |
1744 | ||
1745 | target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias` | |
1746 | target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
1747 | target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
1748 | target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
1749 | echo "$ac_t""$target" 1>&6 | |
1750 | ||
1751 | echo $ac_n "checking build system type""... $ac_c" 1>&6 | |
1752 | echo "configure:1753: checking build system type" >&5 | |
1753 | ||
1754 | build_alias=$build | |
1755 | case "$build_alias" in | |
1756 | NONE) | |
1757 | case $nonopt in | |
1758 | NONE) build_alias=$host_alias ;; | |
1759 | *) build_alias=$nonopt ;; | |
1760 | esac ;; | |
1761 | esac | |
1762 | ||
1763 | build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias` | |
1764 | build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` | |
1765 | build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` | |
1766 | build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` | |
1767 | echo "$ac_t""$build" 1>&6 | |
1768 | ||
1769 | test "$host_alias" != "$target_alias" && | |
1770 | test "$program_prefix$program_suffix$program_transform_name" = \ | |
1771 | NONENONEs,x,x, && | |
1772 | program_prefix=${target_alias}- | |
1773 | ||
1774 | if test "$program_transform_name" = s,x,x,; then | |
1775 | program_transform_name= | |
1776 | else | |
1777 | # Double any \ or $. echo might interpret backslashes. | |
1778 | cat <<\EOF_SED > conftestsed | |
1779 | s,\\,\\\\,g; s,\$,$$,g | |
1780 | EOF_SED | |
1781 | program_transform_name="`echo $program_transform_name|sed -f conftestsed`" | |
1782 | rm -f conftestsed | |
1783 | fi | |
1784 | test "$program_prefix" != NONE && | |
1785 | program_transform_name="s,^,${program_prefix},; $program_transform_name" | |
1786 | # Use a double $ so make ignores it. | |
1787 | test "$program_suffix" != NONE && | |
1788 | program_transform_name="s,\$\$,${program_suffix},; $program_transform_name" | |
1789 | ||
1790 | # sed with no file args requires a program. | |
1791 | test "$program_transform_name" = "" && program_transform_name="s,x,x," | |
1792 | ||
1793 | # Extract the first word of "gcc", so it can be a program name with args. | |
1794 | set dummy gcc; ac_word=$2 | |
1795 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
1796 | echo "configure:1797: checking for $ac_word" >&5 | |
1797 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | |
1798 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1799 | else | |
1800 | if test -n "$CC"; then | |
1801 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
1802 | else | |
1803 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1804 | ac_dummy="$PATH" | |
1805 | for ac_dir in $ac_dummy; do | |
1806 | test -z "$ac_dir" && ac_dir=. | |
1807 | if test -f $ac_dir/$ac_word; then | |
1808 | ac_cv_prog_CC="gcc" | |
1809 | break | |
1810 | fi | |
1811 | done | |
1812 | IFS="$ac_save_ifs" | |
1813 | fi | |
1814 | fi | |
1815 | CC="$ac_cv_prog_CC" | |
1816 | if test -n "$CC"; then | |
1817 | echo "$ac_t""$CC" 1>&6 | |
1818 | else | |
1819 | echo "$ac_t""no" 1>&6 | |
1820 | fi | |
1821 | ||
1822 | if test -z "$CC"; then | |
1823 | # Extract the first word of "cc", so it can be a program name with args. | |
1824 | set dummy cc; ac_word=$2 | |
1825 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
1826 | echo "configure:1827: checking for $ac_word" >&5 | |
1827 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | |
1828 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1829 | else | |
1830 | if test -n "$CC"; then | |
1831 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
1832 | else | |
1833 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1834 | ac_prog_rejected=no | |
1835 | ac_dummy="$PATH" | |
1836 | for ac_dir in $ac_dummy; do | |
1837 | test -z "$ac_dir" && ac_dir=. | |
1838 | if test -f $ac_dir/$ac_word; then | |
1839 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then | |
1840 | ac_prog_rejected=yes | |
1841 | continue | |
1842 | fi | |
1843 | ac_cv_prog_CC="cc" | |
1844 | break | |
1845 | fi | |
1846 | done | |
1847 | IFS="$ac_save_ifs" | |
1848 | if test $ac_prog_rejected = yes; then | |
1849 | # We found a bogon in the path, so make sure we never use it. | |
1850 | set dummy $ac_cv_prog_CC | |
1851 | shift | |
1852 | if test $# -gt 0; then | |
1853 | # We chose a different compiler from the bogus one. | |
1854 | # However, it has the same basename, so the bogon will be chosen | |
1855 | # first if we set CC to just the basename; use the full file name. | |
1856 | shift | |
1857 | set dummy "$ac_dir/$ac_word" "$@" | |
1858 | shift | |
1859 | ac_cv_prog_CC="$@" | |
1860 | fi | |
1861 | fi | |
1862 | fi | |
1863 | fi | |
1864 | CC="$ac_cv_prog_CC" | |
1865 | if test -n "$CC"; then | |
1866 | echo "$ac_t""$CC" 1>&6 | |
1867 | else | |
1868 | echo "$ac_t""no" 1>&6 | |
1869 | fi | |
1870 | ||
1871 | if test -z "$CC"; then | |
1872 | case "`uname -s`" in | |
1873 | *win32* | *WIN32*) | |
1874 | # Extract the first word of "cl", so it can be a program name with args. | |
1875 | set dummy cl; ac_word=$2 | |
1876 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
1877 | echo "configure:1878: checking for $ac_word" >&5 | |
1878 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then | |
1879 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1880 | else | |
1881 | if test -n "$CC"; then | |
1882 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
1883 | else | |
1884 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
1885 | ac_dummy="$PATH" | |
1886 | for ac_dir in $ac_dummy; do | |
1887 | test -z "$ac_dir" && ac_dir=. | |
1888 | if test -f $ac_dir/$ac_word; then | |
1889 | ac_cv_prog_CC="cl" | |
1890 | break | |
1891 | fi | |
1892 | done | |
1893 | IFS="$ac_save_ifs" | |
1894 | fi | |
1895 | fi | |
1896 | CC="$ac_cv_prog_CC" | |
1897 | if test -n "$CC"; then | |
1898 | echo "$ac_t""$CC" 1>&6 | |
1899 | else | |
1900 | echo "$ac_t""no" 1>&6 | |
1901 | fi | |
1902 | ;; | |
1903 | esac | |
1904 | fi | |
1905 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } | |
1906 | fi | |
1907 | ||
1908 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 | |
1909 | echo "configure:1910: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 | |
1910 | ||
1911 | ac_ext=c | |
1912 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
1913 | ac_cpp='$CPP $CPPFLAGS' | |
1914 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
1915 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
1916 | cross_compiling=$ac_cv_prog_cc_cross | |
1917 | ||
1918 | cat > conftest.$ac_ext << EOF | |
1919 | ||
1920 | #line 1921 "configure" | |
1921 | #include "confdefs.h" | |
1922 | ||
1923 | main(){return(0);} | |
1924 | EOF | |
1925 | if { (eval echo configure:1926: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
1926 | ac_cv_prog_cc_works=yes | |
1927 | # If we can't run a trivial program, we are probably using a cross compiler. | |
1928 | if (./conftest; exit) 2>/dev/null; then | |
1929 | ac_cv_prog_cc_cross=no | |
1930 | else | |
1931 | ac_cv_prog_cc_cross=yes | |
1932 | fi | |
1933 | else | |
1934 | echo "configure: failed program was:" >&5 | |
1935 | cat conftest.$ac_ext >&5 | |
1936 | ac_cv_prog_cc_works=no | |
1937 | fi | |
1938 | rm -fr conftest* | |
1939 | ac_ext=c | |
1940 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. | |
1941 | ac_cpp='$CPP $CPPFLAGS' | |
1942 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' | |
1943 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' | |
1944 | cross_compiling=$ac_cv_prog_cc_cross | |
1945 | ||
1946 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 | |
1947 | if test $ac_cv_prog_cc_works = no; then | |
1948 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } | |
1949 | fi | |
1950 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 | |
1951 | echo "configure:1952: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 | |
1952 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 | |
1953 | cross_compiling=$ac_cv_prog_cc_cross | |
1954 | ||
1955 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 | |
1956 | echo "configure:1957: checking whether we are using GNU C" >&5 | |
1957 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then | |
1958 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1959 | else | |
1960 | cat > conftest.c <<EOF | |
1961 | #ifdef __GNUC__ | |
1962 | yes; | |
1963 | #endif | |
1964 | EOF | |
1965 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1966: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then | |
1966 | ac_cv_prog_gcc=yes | |
1967 | else | |
1968 | ac_cv_prog_gcc=no | |
1969 | fi | |
1970 | fi | |
1971 | ||
1972 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 | |
1973 | ||
1974 | if test $ac_cv_prog_gcc = yes; then | |
1975 | GCC=yes | |
1976 | else | |
1977 | GCC= | |
1978 | fi | |
1979 | ||
1980 | ac_test_CFLAGS="${CFLAGS+set}" | |
1981 | ac_save_CFLAGS="$CFLAGS" | |
1982 | CFLAGS= | |
1983 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 | |
1984 | echo "configure:1985: checking whether ${CC-cc} accepts -g" >&5 | |
1985 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then | |
1986 | echo $ac_n "(cached) $ac_c" 1>&6 | |
1987 | else | |
1988 | echo 'void f(){}' > conftest.c | |
1989 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then | |
1990 | ac_cv_prog_cc_g=yes | |
1991 | else | |
1992 | ac_cv_prog_cc_g=no | |
1993 | fi | |
1994 | rm -f conftest* | |
1995 | ||
1996 | fi | |
1997 | ||
1998 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 | |
1999 | if test "$ac_test_CFLAGS" = set; then | |
2000 | CFLAGS="$ac_save_CFLAGS" | |
2001 | elif test $ac_cv_prog_cc_g = yes; then | |
2002 | if test "$GCC" = yes; then | |
2003 | CFLAGS="-g -O2" | |
2004 | else | |
2005 | CFLAGS="-g" | |
2006 | fi | |
2007 | else | |
2008 | if test "$GCC" = yes; then | |
2009 | CFLAGS="-O2" | |
2010 | else | |
2011 | CFLAGS= | |
2012 | fi | |
2013 | fi | |
2014 | ||
2015 | # Find a good install program. We prefer a C program (faster), | |
2016 | # so one script is as good as another. But avoid the broken or | |
2017 | # incompatible versions: | |
2018 | # SysV /etc/install, /usr/sbin/install | |
2019 | # SunOS /usr/etc/install | |
2020 | # IRIX /sbin/install | |
2021 | # AIX /bin/install | |
2022 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | |
2023 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
2024 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
2025 | # ./install, which can be erroneously created by make from ./install.sh. | |
2026 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 | |
2027 | echo "configure:2028: checking for a BSD compatible install" >&5 | |
2028 | if test -z "$INSTALL"; then | |
2029 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then | |
2030 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2031 | else | |
2032 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" | |
2033 | for ac_dir in $PATH; do | |
2034 | # Account for people who put trailing slashes in PATH elements. | |
2035 | case "$ac_dir/" in | |
2036 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; | |
2037 | *) | |
2038 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
2039 | # Don't use installbsd from OSF since it installs stuff as root | |
2040 | # by default. | |
2041 | for ac_prog in ginstall scoinst install; do | |
2042 | if test -f $ac_dir/$ac_prog; then | |
2043 | if test $ac_prog = install && | |
2044 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then | |
2045 | # AIX install. It has an incompatible calling convention. | |
2046 | : | |
2047 | else | |
2048 | ac_cv_path_install="$ac_dir/$ac_prog -c" | |
2049 | break 2 | |
2050 | fi | |
2051 | fi | |
2052 | done | |
2053 | ;; | |
2054 | esac | |
2055 | done | |
2056 | IFS="$ac_save_IFS" | |
2057 | ||
2058 | fi | |
2059 | if test "${ac_cv_path_install+set}" = set; then | |
2060 | INSTALL="$ac_cv_path_install" | |
2061 | else | |
2062 | # As a last resort, use the slow shell script. We don't cache a | |
2063 | # path for INSTALL within a source directory, because that will | |
2064 | # break other packages using the cache if that directory is | |
2065 | # removed, or if the path is relative. | |
2066 | INSTALL="$ac_install_sh" | |
2067 | fi | |
2068 | fi | |
2069 | echo "$ac_t""$INSTALL" 1>&6 | |
2070 | ||
2071 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
2072 | # It thinks the first close brace ends the variable substitution. | |
2073 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
2074 | ||
2075 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' | |
2076 | ||
2077 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | |
2078 | ||
2079 | ||
2080 | # Put a plausible default for CC_FOR_BUILD in Makefile. | |
2081 | if test "x$cross_compiling" = "xno"; then | |
2082 | CC_FOR_BUILD='$(CC)' | |
2083 | else | |
2084 | CC_FOR_BUILD=gcc | |
2085 | fi | |
2086 | ||
2087 | ||
2088 | ||
2089 | ||
2090 | AR=${AR-ar} | |
2091 | ||
2092 | # Extract the first word of "ranlib", so it can be a program name with args. | |
2093 | set dummy ranlib; ac_word=$2 | |
2094 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
2095 | echo "configure:2096: checking for $ac_word" >&5 | |
2096 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then | |
2097 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2098 | else | |
2099 | if test -n "$RANLIB"; then | |
2100 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
2101 | else | |
2102 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2103 | ac_dummy="$PATH" | |
2104 | for ac_dir in $ac_dummy; do | |
2105 | test -z "$ac_dir" && ac_dir=. | |
2106 | if test -f $ac_dir/$ac_word; then | |
2107 | ac_cv_prog_RANLIB="ranlib" | |
2108 | break | |
2109 | fi | |
2110 | done | |
2111 | IFS="$ac_save_ifs" | |
2112 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" | |
2113 | fi | |
2114 | fi | |
2115 | RANLIB="$ac_cv_prog_RANLIB" | |
2116 | if test -n "$RANLIB"; then | |
2117 | echo "$ac_t""$RANLIB" 1>&6 | |
2118 | else | |
2119 | echo "$ac_t""no" 1>&6 | |
2120 | fi | |
2121 | ||
2122 | ||
2123 | ALL_LINGUAS= | |
2124 | ||
2125 | for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \ | |
2126 | unistd.h values.h sys/param.h | |
2127 | do | |
2128 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
2129 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
2130 | echo "configure:2131: checking for $ac_hdr" >&5 | |
2131 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
2132 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2133 | else | |
2134 | cat > conftest.$ac_ext <<EOF | |
2135 | #line 2136 "configure" | |
2136 | #include "confdefs.h" | |
2137 | #include <$ac_hdr> | |
2138 | EOF | |
2139 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
2140 | { (eval echo configure:2141: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
2141 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
2142 | if test -z "$ac_err"; then | |
2143 | rm -rf conftest* | |
2144 | eval "ac_cv_header_$ac_safe=yes" | |
2145 | else | |
2146 | echo "$ac_err" >&5 | |
2147 | echo "configure: failed program was:" >&5 | |
2148 | cat conftest.$ac_ext >&5 | |
2149 | rm -rf conftest* | |
2150 | eval "ac_cv_header_$ac_safe=no" | |
2151 | fi | |
2152 | rm -f conftest* | |
2153 | fi | |
2154 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
2155 | echo "$ac_t""yes" 1>&6 | |
2156 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
2157 | cat >> confdefs.h <<EOF | |
2158 | #define $ac_tr_hdr 1 | |
2159 | EOF | |
2160 | ||
2161 | else | |
2162 | echo "$ac_t""no" 1>&6 | |
2163 | fi | |
2164 | done | |
2165 | ||
2166 | for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \ | |
2167 | __argz_count __argz_stringify __argz_next | |
2168 | do | |
2169 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
2170 | echo "configure:2171: checking for $ac_func" >&5 | |
2171 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then | |
2172 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2173 | else | |
2174 | cat > conftest.$ac_ext <<EOF | |
2175 | #line 2176 "configure" | |
2176 | #include "confdefs.h" | |
2177 | /* System header to define __stub macros and hopefully few prototypes, | |
2178 | which can conflict with char $ac_func(); below. */ | |
2179 | #include <assert.h> | |
2180 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2181 | /* We use char because int might match the return type of a gcc2 | |
2182 | builtin and then its argument prototype would still apply. */ | |
2183 | char $ac_func(); | |
2184 | ||
2185 | int main() { | |
2186 | ||
2187 | /* The GNU C library defines this for functions which it implements | |
2188 | to always fail with ENOSYS. Some functions are actually named | |
2189 | something starting with __ and the normal name is an alias. */ | |
2190 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
2191 | choke me | |
2192 | #else | |
2193 | $ac_func(); | |
2194 | #endif | |
2195 | ||
2196 | ; return 0; } | |
2197 | EOF | |
2198 | if { (eval echo configure:2199: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
2199 | rm -rf conftest* | |
2200 | eval "ac_cv_func_$ac_func=yes" | |
2201 | else | |
2202 | echo "configure: failed program was:" >&5 | |
2203 | cat conftest.$ac_ext >&5 | |
2204 | rm -rf conftest* | |
2205 | eval "ac_cv_func_$ac_func=no" | |
2206 | fi | |
2207 | rm -f conftest* | |
2208 | fi | |
2209 | ||
2210 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
2211 | echo "$ac_t""yes" 1>&6 | |
2212 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
2213 | cat >> confdefs.h <<EOF | |
2214 | #define $ac_tr_func 1 | |
2215 | EOF | |
2216 | ||
2217 | else | |
2218 | echo "$ac_t""no" 1>&6 | |
2219 | fi | |
2220 | done | |
2221 | ||
2222 | ||
2223 | if test "${ac_cv_func_stpcpy+set}" != "set"; then | |
2224 | for ac_func in stpcpy | |
2225 | do | |
2226 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
2227 | echo "configure:2228: checking for $ac_func" >&5 | |
2228 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then | |
2229 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2230 | else | |
2231 | cat > conftest.$ac_ext <<EOF | |
2232 | #line 2233 "configure" | |
2233 | #include "confdefs.h" | |
2234 | /* System header to define __stub macros and hopefully few prototypes, | |
2235 | which can conflict with char $ac_func(); below. */ | |
2236 | #include <assert.h> | |
2237 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2238 | /* We use char because int might match the return type of a gcc2 | |
2239 | builtin and then its argument prototype would still apply. */ | |
2240 | char $ac_func(); | |
2241 | ||
2242 | int main() { | |
2243 | ||
2244 | /* The GNU C library defines this for functions which it implements | |
2245 | to always fail with ENOSYS. Some functions are actually named | |
2246 | something starting with __ and the normal name is an alias. */ | |
2247 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
2248 | choke me | |
2249 | #else | |
2250 | $ac_func(); | |
2251 | #endif | |
2252 | ||
2253 | ; return 0; } | |
2254 | EOF | |
2255 | if { (eval echo configure:2256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
2256 | rm -rf conftest* | |
2257 | eval "ac_cv_func_$ac_func=yes" | |
2258 | else | |
2259 | echo "configure: failed program was:" >&5 | |
2260 | cat conftest.$ac_ext >&5 | |
2261 | rm -rf conftest* | |
2262 | eval "ac_cv_func_$ac_func=no" | |
2263 | fi | |
2264 | rm -f conftest* | |
2265 | fi | |
2266 | ||
2267 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
2268 | echo "$ac_t""yes" 1>&6 | |
2269 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
2270 | cat >> confdefs.h <<EOF | |
2271 | #define $ac_tr_func 1 | |
2272 | EOF | |
2273 | ||
2274 | else | |
2275 | echo "$ac_t""no" 1>&6 | |
2276 | fi | |
2277 | done | |
2278 | ||
2279 | fi | |
2280 | if test "${ac_cv_func_stpcpy}" = "yes"; then | |
2281 | cat >> confdefs.h <<\EOF | |
2282 | #define HAVE_STPCPY 1 | |
2283 | EOF | |
2284 | ||
2285 | fi | |
2286 | ||
2287 | if test $ac_cv_header_locale_h = yes; then | |
2288 | echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6 | |
2289 | echo "configure:2290: checking for LC_MESSAGES" >&5 | |
2290 | if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then | |
2291 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2292 | else | |
2293 | cat > conftest.$ac_ext <<EOF | |
2294 | #line 2295 "configure" | |
2295 | #include "confdefs.h" | |
2296 | #include <locale.h> | |
2297 | int main() { | |
2298 | return LC_MESSAGES | |
2299 | ; return 0; } | |
2300 | EOF | |
2301 | if { (eval echo configure:2302: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
2302 | rm -rf conftest* | |
2303 | am_cv_val_LC_MESSAGES=yes | |
2304 | else | |
2305 | echo "configure: failed program was:" >&5 | |
2306 | cat conftest.$ac_ext >&5 | |
2307 | rm -rf conftest* | |
2308 | am_cv_val_LC_MESSAGES=no | |
2309 | fi | |
2310 | rm -f conftest* | |
2311 | fi | |
2312 | ||
2313 | echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6 | |
2314 | if test $am_cv_val_LC_MESSAGES = yes; then | |
2315 | cat >> confdefs.h <<\EOF | |
2316 | #define HAVE_LC_MESSAGES 1 | |
2317 | EOF | |
2318 | ||
2319 | fi | |
2320 | fi | |
2321 | echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6 | |
2322 | echo "configure:2323: checking whether NLS is requested" >&5 | |
2323 | # Check whether --enable-nls or --disable-nls was given. | |
2324 | if test "${enable_nls+set}" = set; then | |
2325 | enableval="$enable_nls" | |
2326 | USE_NLS=$enableval | |
2327 | else | |
2328 | USE_NLS=yes | |
2329 | fi | |
2330 | ||
2331 | echo "$ac_t""$USE_NLS" 1>&6 | |
2332 | ||
2333 | ||
2334 | USE_INCLUDED_LIBINTL=no | |
2335 | ||
2336 | if test "$USE_NLS" = "yes"; then | |
2337 | cat >> confdefs.h <<\EOF | |
2338 | #define ENABLE_NLS 1 | |
2339 | EOF | |
2340 | ||
2341 | echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6 | |
2342 | echo "configure:2343: checking whether included gettext is requested" >&5 | |
2343 | # Check whether --with-included-gettext or --without-included-gettext was given. | |
2344 | if test "${with_included_gettext+set}" = set; then | |
2345 | withval="$with_included_gettext" | |
2346 | nls_cv_force_use_gnu_gettext=$withval | |
2347 | else | |
2348 | nls_cv_force_use_gnu_gettext=no | |
2349 | fi | |
2350 | ||
2351 | echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6 | |
2352 | ||
2353 | nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" | |
2354 | if test "$nls_cv_force_use_gnu_gettext" != "yes"; then | |
2355 | nls_cv_header_intl= | |
2356 | nls_cv_header_libgt= | |
2357 | CATOBJEXT=NONE | |
2358 | ||
2359 | ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'` | |
2360 | echo $ac_n "checking for libintl.h""... $ac_c" 1>&6 | |
2361 | echo "configure:2362: checking for libintl.h" >&5 | |
2362 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
2363 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2364 | else | |
2365 | cat > conftest.$ac_ext <<EOF | |
2366 | #line 2367 "configure" | |
2367 | #include "confdefs.h" | |
2368 | #include <libintl.h> | |
2369 | EOF | |
2370 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
2371 | { (eval echo configure:2372: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
2372 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
2373 | if test -z "$ac_err"; then | |
2374 | rm -rf conftest* | |
2375 | eval "ac_cv_header_$ac_safe=yes" | |
2376 | else | |
2377 | echo "$ac_err" >&5 | |
2378 | echo "configure: failed program was:" >&5 | |
2379 | cat conftest.$ac_ext >&5 | |
2380 | rm -rf conftest* | |
2381 | eval "ac_cv_header_$ac_safe=no" | |
2382 | fi | |
2383 | rm -f conftest* | |
2384 | fi | |
2385 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
2386 | echo "$ac_t""yes" 1>&6 | |
2387 | echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6 | |
2388 | echo "configure:2389: checking for gettext in libc" >&5 | |
2389 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then | |
2390 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2391 | else | |
2392 | cat > conftest.$ac_ext <<EOF | |
2393 | #line 2394 "configure" | |
2394 | #include "confdefs.h" | |
2395 | #include <libintl.h> | |
2396 | int main() { | |
2397 | return (int) gettext ("") | |
2398 | ; return 0; } | |
2399 | EOF | |
2400 | if { (eval echo configure:2401: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
2401 | rm -rf conftest* | |
2402 | gt_cv_func_gettext_libc=yes | |
2403 | else | |
2404 | echo "configure: failed program was:" >&5 | |
2405 | cat conftest.$ac_ext >&5 | |
2406 | rm -rf conftest* | |
2407 | gt_cv_func_gettext_libc=no | |
2408 | fi | |
2409 | rm -f conftest* | |
2410 | fi | |
2411 | ||
2412 | echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6 | |
2413 | ||
2414 | if test "$gt_cv_func_gettext_libc" != "yes"; then | |
2415 | echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6 | |
2416 | echo "configure:2417: checking for bindtextdomain in -lintl" >&5 | |
2417 | ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'` | |
2418 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
2419 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2420 | else | |
2421 | ac_save_LIBS="$LIBS" | |
2422 | LIBS="-lintl $LIBS" | |
2423 | cat > conftest.$ac_ext <<EOF | |
2424 | #line 2425 "configure" | |
2425 | #include "confdefs.h" | |
2426 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2427 | /* We use char because int might match the return type of a gcc2 | |
2428 | builtin and then its argument prototype would still apply. */ | |
2429 | char bindtextdomain(); | |
2430 | ||
2431 | int main() { | |
2432 | bindtextdomain() | |
2433 | ; return 0; } | |
2434 | EOF | |
2435 | if { (eval echo configure:2436: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
2436 | rm -rf conftest* | |
2437 | eval "ac_cv_lib_$ac_lib_var=yes" | |
2438 | else | |
2439 | echo "configure: failed program was:" >&5 | |
2440 | cat conftest.$ac_ext >&5 | |
2441 | rm -rf conftest* | |
2442 | eval "ac_cv_lib_$ac_lib_var=no" | |
2443 | fi | |
2444 | rm -f conftest* | |
2445 | LIBS="$ac_save_LIBS" | |
2446 | ||
2447 | fi | |
2448 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
2449 | echo "$ac_t""yes" 1>&6 | |
2450 | echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6 | |
2451 | echo "configure:2452: checking for gettext in libintl" >&5 | |
2452 | if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then | |
2453 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2454 | else | |
2455 | cat > conftest.$ac_ext <<EOF | |
2456 | #line 2457 "configure" | |
2457 | #include "confdefs.h" | |
2458 | ||
2459 | int main() { | |
2460 | return (int) gettext ("") | |
2461 | ; return 0; } | |
2462 | EOF | |
2463 | if { (eval echo configure:2464: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
2464 | rm -rf conftest* | |
2465 | gt_cv_func_gettext_libintl=yes | |
2466 | else | |
2467 | echo "configure: failed program was:" >&5 | |
2468 | cat conftest.$ac_ext >&5 | |
2469 | rm -rf conftest* | |
2470 | gt_cv_func_gettext_libintl=no | |
2471 | fi | |
2472 | rm -f conftest* | |
2473 | fi | |
2474 | ||
2475 | echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6 | |
2476 | else | |
2477 | echo "$ac_t""no" 1>&6 | |
2478 | fi | |
2479 | ||
2480 | fi | |
2481 | ||
2482 | if test "$gt_cv_func_gettext_libc" = "yes" \ | |
2483 | || test "$gt_cv_func_gettext_libintl" = "yes"; then | |
2484 | cat >> confdefs.h <<\EOF | |
2485 | #define HAVE_GETTEXT 1 | |
2486 | EOF | |
2487 | ||
2488 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
2489 | set dummy msgfmt; ac_word=$2 | |
2490 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
2491 | echo "configure:2492: checking for $ac_word" >&5 | |
2492 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then | |
2493 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2494 | else | |
2495 | case "$MSGFMT" in | |
2496 | /*) | |
2497 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
2498 | ;; | |
2499 | *) | |
2500 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2501 | for ac_dir in $PATH; do | |
2502 | test -z "$ac_dir" && ac_dir=. | |
2503 | if test -f $ac_dir/$ac_word; then | |
2504 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
2505 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
2506 | break | |
2507 | fi | |
2508 | fi | |
2509 | done | |
2510 | IFS="$ac_save_ifs" | |
2511 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" | |
2512 | ;; | |
2513 | esac | |
2514 | fi | |
2515 | MSGFMT="$ac_cv_path_MSGFMT" | |
2516 | if test -n "$MSGFMT"; then | |
2517 | echo "$ac_t""$MSGFMT" 1>&6 | |
2518 | else | |
2519 | echo "$ac_t""no" 1>&6 | |
2520 | fi | |
2521 | if test "$MSGFMT" != "no"; then | |
2522 | for ac_func in dcgettext | |
2523 | do | |
2524 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
2525 | echo "configure:2526: checking for $ac_func" >&5 | |
2526 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then | |
2527 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2528 | else | |
2529 | cat > conftest.$ac_ext <<EOF | |
2530 | #line 2531 "configure" | |
2531 | #include "confdefs.h" | |
2532 | /* System header to define __stub macros and hopefully few prototypes, | |
2533 | which can conflict with char $ac_func(); below. */ | |
2534 | #include <assert.h> | |
2535 | /* Override any gcc2 internal prototype to avoid an error. */ | |
2536 | /* We use char because int might match the return type of a gcc2 | |
2537 | builtin and then its argument prototype would still apply. */ | |
2538 | char $ac_func(); | |
2539 | ||
2540 | int main() { | |
2541 | ||
2542 | /* The GNU C library defines this for functions which it implements | |
2543 | to always fail with ENOSYS. Some functions are actually named | |
2544 | something starting with __ and the normal name is an alias. */ | |
2545 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
2546 | choke me | |
2547 | #else | |
2548 | $ac_func(); | |
2549 | #endif | |
2550 | ||
2551 | ; return 0; } | |
2552 | EOF | |
2553 | if { (eval echo configure:2554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
2554 | rm -rf conftest* | |
2555 | eval "ac_cv_func_$ac_func=yes" | |
2556 | else | |
2557 | echo "configure: failed program was:" >&5 | |
2558 | cat conftest.$ac_ext >&5 | |
2559 | rm -rf conftest* | |
2560 | eval "ac_cv_func_$ac_func=no" | |
2561 | fi | |
2562 | rm -f conftest* | |
2563 | fi | |
2564 | ||
2565 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
2566 | echo "$ac_t""yes" 1>&6 | |
2567 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
2568 | cat >> confdefs.h <<EOF | |
2569 | #define $ac_tr_func 1 | |
2570 | EOF | |
2571 | ||
2572 | else | |
2573 | echo "$ac_t""no" 1>&6 | |
2574 | fi | |
2575 | done | |
2576 | ||
2577 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
2578 | set dummy gmsgfmt; ac_word=$2 | |
2579 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
2580 | echo "configure:2581: checking for $ac_word" >&5 | |
2581 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then | |
2582 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2583 | else | |
2584 | case "$GMSGFMT" in | |
2585 | /*) | |
2586 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
2587 | ;; | |
2588 | ?:/*) | |
2589 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. | |
2590 | ;; | |
2591 | *) | |
2592 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2593 | ac_dummy="$PATH" | |
2594 | for ac_dir in $ac_dummy; do | |
2595 | test -z "$ac_dir" && ac_dir=. | |
2596 | if test -f $ac_dir/$ac_word; then | |
2597 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
2598 | break | |
2599 | fi | |
2600 | done | |
2601 | IFS="$ac_save_ifs" | |
2602 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
2603 | ;; | |
2604 | esac | |
2605 | fi | |
2606 | GMSGFMT="$ac_cv_path_GMSGFMT" | |
2607 | if test -n "$GMSGFMT"; then | |
2608 | echo "$ac_t""$GMSGFMT" 1>&6 | |
2609 | else | |
2610 | echo "$ac_t""no" 1>&6 | |
2611 | fi | |
2612 | ||
2613 | # Extract the first word of "xgettext", so it can be a program name with args. | |
2614 | set dummy xgettext; ac_word=$2 | |
2615 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
2616 | echo "configure:2617: checking for $ac_word" >&5 | |
2617 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then | |
2618 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2619 | else | |
2620 | case "$XGETTEXT" in | |
2621 | /*) | |
2622 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
2623 | ;; | |
2624 | *) | |
2625 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2626 | for ac_dir in $PATH; do | |
2627 | test -z "$ac_dir" && ac_dir=. | |
2628 | if test -f $ac_dir/$ac_word; then | |
2629 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
2630 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
2631 | break | |
2632 | fi | |
2633 | fi | |
2634 | done | |
2635 | IFS="$ac_save_ifs" | |
2636 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
2637 | ;; | |
2638 | esac | |
2639 | fi | |
2640 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
2641 | if test -n "$XGETTEXT"; then | |
2642 | echo "$ac_t""$XGETTEXT" 1>&6 | |
2643 | else | |
2644 | echo "$ac_t""no" 1>&6 | |
2645 | fi | |
2646 | ||
2647 | cat > conftest.$ac_ext <<EOF | |
2648 | #line 2649 "configure" | |
2649 | #include "confdefs.h" | |
2650 | ||
2651 | int main() { | |
2652 | extern int _nl_msg_cat_cntr; | |
2653 | return _nl_msg_cat_cntr | |
2654 | ; return 0; } | |
2655 | EOF | |
2656 | if { (eval echo configure:2657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
2657 | rm -rf conftest* | |
2658 | CATOBJEXT=.gmo | |
2659 | DATADIRNAME=share | |
2660 | else | |
2661 | echo "configure: failed program was:" >&5 | |
2662 | cat conftest.$ac_ext >&5 | |
2663 | rm -rf conftest* | |
2664 | CATOBJEXT=.mo | |
2665 | DATADIRNAME=lib | |
2666 | fi | |
2667 | rm -f conftest* | |
2668 | INSTOBJEXT=.mo | |
2669 | fi | |
2670 | fi | |
2671 | ||
2672 | else | |
2673 | echo "$ac_t""no" 1>&6 | |
2674 | fi | |
2675 | ||
2676 | ||
2677 | ||
2678 | if test "$CATOBJEXT" = "NONE"; then | |
2679 | nls_cv_use_gnu_gettext=yes | |
2680 | fi | |
2681 | fi | |
2682 | ||
2683 | if test "$nls_cv_use_gnu_gettext" = "yes"; then | |
2684 | INTLOBJS="\$(GETTOBJS)" | |
2685 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
2686 | set dummy msgfmt; ac_word=$2 | |
2687 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
2688 | echo "configure:2689: checking for $ac_word" >&5 | |
2689 | if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then | |
2690 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2691 | else | |
2692 | case "$MSGFMT" in | |
2693 | /*) | |
2694 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
2695 | ;; | |
2696 | *) | |
2697 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2698 | for ac_dir in $PATH; do | |
2699 | test -z "$ac_dir" && ac_dir=. | |
2700 | if test -f $ac_dir/$ac_word; then | |
2701 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then | |
2702 | ac_cv_path_MSGFMT="$ac_dir/$ac_word" | |
2703 | break | |
2704 | fi | |
2705 | fi | |
2706 | done | |
2707 | IFS="$ac_save_ifs" | |
2708 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt" | |
2709 | ;; | |
2710 | esac | |
2711 | fi | |
2712 | MSGFMT="$ac_cv_path_MSGFMT" | |
2713 | if test -n "$MSGFMT"; then | |
2714 | echo "$ac_t""$MSGFMT" 1>&6 | |
2715 | else | |
2716 | echo "$ac_t""no" 1>&6 | |
2717 | fi | |
2718 | ||
2719 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
2720 | set dummy gmsgfmt; ac_word=$2 | |
2721 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
2722 | echo "configure:2723: checking for $ac_word" >&5 | |
2723 | if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then | |
2724 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2725 | else | |
2726 | case "$GMSGFMT" in | |
2727 | /*) | |
2728 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
2729 | ;; | |
2730 | ?:/*) | |
2731 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path. | |
2732 | ;; | |
2733 | *) | |
2734 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" | |
2735 | ac_dummy="$PATH" | |
2736 | for ac_dir in $ac_dummy; do | |
2737 | test -z "$ac_dir" && ac_dir=. | |
2738 | if test -f $ac_dir/$ac_word; then | |
2739 | ac_cv_path_GMSGFMT="$ac_dir/$ac_word" | |
2740 | break | |
2741 | fi | |
2742 | done | |
2743 | IFS="$ac_save_ifs" | |
2744 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
2745 | ;; | |
2746 | esac | |
2747 | fi | |
2748 | GMSGFMT="$ac_cv_path_GMSGFMT" | |
2749 | if test -n "$GMSGFMT"; then | |
2750 | echo "$ac_t""$GMSGFMT" 1>&6 | |
2751 | else | |
2752 | echo "$ac_t""no" 1>&6 | |
2753 | fi | |
2754 | ||
2755 | # Extract the first word of "xgettext", so it can be a program name with args. | |
2756 | set dummy xgettext; ac_word=$2 | |
2757 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 | |
2758 | echo "configure:2759: checking for $ac_word" >&5 | |
2759 | if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then | |
2760 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2761 | else | |
2762 | case "$XGETTEXT" in | |
2763 | /*) | |
2764 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
2765 | ;; | |
2766 | *) | |
2767 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" | |
2768 | for ac_dir in $PATH; do | |
2769 | test -z "$ac_dir" && ac_dir=. | |
2770 | if test -f $ac_dir/$ac_word; then | |
2771 | if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then | |
2772 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word" | |
2773 | break | |
2774 | fi | |
2775 | fi | |
2776 | done | |
2777 | IFS="$ac_save_ifs" | |
2778 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
2779 | ;; | |
2780 | esac | |
2781 | fi | |
2782 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
2783 | if test -n "$XGETTEXT"; then | |
2784 | echo "$ac_t""$XGETTEXT" 1>&6 | |
2785 | else | |
2786 | echo "$ac_t""no" 1>&6 | |
2787 | fi | |
2788 | ||
2789 | ||
2790 | USE_INCLUDED_LIBINTL=yes | |
2791 | CATOBJEXT=.gmo | |
2792 | INSTOBJEXT=.mo | |
2793 | DATADIRNAME=share | |
2794 | INTLDEPS='$(top_builddir)/../intl/libintl.a' | |
2795 | INTLLIBS=$INTLDEPS | |
2796 | LIBS=`echo $LIBS | sed -e 's/-lintl//'` | |
2797 | nls_cv_header_intl=libintl.h | |
2798 | nls_cv_header_libgt=libgettext.h | |
2799 | fi | |
2800 | ||
2801 | if test "$XGETTEXT" != ":"; then | |
2802 | if $XGETTEXT --omit-header /dev/null 2> /dev/null; then | |
2803 | : ; | |
2804 | else | |
2805 | echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6 | |
2806 | XGETTEXT=":" | |
2807 | fi | |
2808 | fi | |
2809 | ||
2810 | # We need to process the po/ directory. | |
2811 | POSUB=po | |
2812 | else | |
2813 | DATADIRNAME=share | |
2814 | nls_cv_header_intl=libintl.h | |
2815 | nls_cv_header_libgt=libgettext.h | |
2816 | fi | |
2817 | ||
2818 | # If this is used in GNU gettext we have to set USE_NLS to `yes' | |
2819 | # because some of the sources are only built for this goal. | |
2820 | if test "$PACKAGE" = gettext; then | |
2821 | USE_NLS=yes | |
2822 | USE_INCLUDED_LIBINTL=yes | |
2823 | fi | |
2824 | ||
2825 | for lang in $ALL_LINGUAS; do | |
2826 | GMOFILES="$GMOFILES $lang.gmo" | |
2827 | POFILES="$POFILES $lang.po" | |
2828 | done | |
2829 | ||
2830 | ||
2831 | ||
2832 | ||
2833 | ||
2834 | ||
2835 | ||
2836 | ||
2837 | ||
2838 | ||
2839 | ||
2840 | ||
2841 | ||
2842 | ||
2843 | if test "x$CATOBJEXT" != "x"; then | |
2844 | if test "x$ALL_LINGUAS" = "x"; then | |
2845 | LINGUAS= | |
2846 | else | |
2847 | echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6 | |
2848 | echo "configure:2849: checking for catalogs to be installed" >&5 | |
2849 | NEW_LINGUAS= | |
2850 | for lang in ${LINGUAS=$ALL_LINGUAS}; do | |
2851 | case "$ALL_LINGUAS" in | |
2852 | *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;; | |
2853 | esac | |
2854 | done | |
2855 | LINGUAS=$NEW_LINGUAS | |
2856 | echo "$ac_t""$LINGUAS" 1>&6 | |
2857 | fi | |
2858 | ||
2859 | if test -n "$LINGUAS"; then | |
2860 | for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done | |
2861 | fi | |
2862 | fi | |
2863 | ||
2864 | if test $ac_cv_header_locale_h = yes; then | |
2865 | INCLUDE_LOCALE_H="#include <locale.h>" | |
2866 | else | |
2867 | INCLUDE_LOCALE_H="\ | |
2868 | /* The system does not provide the header <locale.h>. Take care yourself. */" | |
2869 | fi | |
2870 | ||
2871 | ||
2872 | if test -f $srcdir/po2tbl.sed.in; then | |
2873 | if test "$CATOBJEXT" = ".cat"; then | |
2874 | ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'` | |
2875 | echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6 | |
2876 | echo "configure:2877: checking for linux/version.h" >&5 | |
2877 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
2878 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2879 | else | |
2880 | cat > conftest.$ac_ext <<EOF | |
2881 | #line 2882 "configure" | |
2882 | #include "confdefs.h" | |
2883 | #include <linux/version.h> | |
2884 | EOF | |
2885 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
2886 | { (eval echo configure:2887: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
2887 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
2888 | if test -z "$ac_err"; then | |
2889 | rm -rf conftest* | |
2890 | eval "ac_cv_header_$ac_safe=yes" | |
2891 | else | |
2892 | echo "$ac_err" >&5 | |
2893 | echo "configure: failed program was:" >&5 | |
2894 | cat conftest.$ac_ext >&5 | |
2895 | rm -rf conftest* | |
2896 | eval "ac_cv_header_$ac_safe=no" | |
2897 | fi | |
2898 | rm -f conftest* | |
2899 | fi | |
2900 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
2901 | echo "$ac_t""yes" 1>&6 | |
2902 | msgformat=linux | |
2903 | else | |
2904 | echo "$ac_t""no" 1>&6 | |
2905 | msgformat=xopen | |
2906 | fi | |
2907 | ||
2908 | ||
2909 | sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed | |
2910 | fi | |
2911 | sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \ | |
2912 | $srcdir/po2tbl.sed.in > po2tbl.sed | |
2913 | fi | |
2914 | ||
2915 | if test "$PACKAGE" = "gettext"; then | |
2916 | GT_NO="#NO#" | |
2917 | GT_YES= | |
2918 | else | |
2919 | GT_NO= | |
2920 | GT_YES="#YES#" | |
2921 | fi | |
2922 | ||
2923 | ||
2924 | ||
2925 | MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs" | |
2926 | ||
2927 | ||
2928 | l= | |
2929 | ||
2930 | ||
2931 | if test -d $srcdir/po; then | |
2932 | test -d po || mkdir po | |
2933 | if test "x$srcdir" != "x."; then | |
2934 | if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then | |
2935 | posrcprefix="$srcdir/" | |
2936 | else | |
2937 | posrcprefix="../$srcdir/" | |
2938 | fi | |
2939 | else | |
2940 | posrcprefix="../" | |
2941 | fi | |
2942 | rm -f po/POTFILES | |
2943 | sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ | |
2944 | < $srcdir/po/POTFILES.in > po/POTFILES | |
2945 | fi | |
2946 | ||
2947 | ||
2948 | # Check for common headers. | |
2949 | # FIXME: Seems to me this can cause problems for i386-windows hosts. | |
2950 | # At one point there were hardcoded AC_DEFINE's if ${host} = i386-*-windows*. | |
2951 | for ac_hdr in stdlib.h string.h strings.h unistd.h time.h | |
2952 | do | |
2953 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
2954 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
2955 | echo "configure:2956: checking for $ac_hdr" >&5 | |
2956 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
2957 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2958 | else | |
2959 | cat > conftest.$ac_ext <<EOF | |
2960 | #line 2961 "configure" | |
2961 | #include "confdefs.h" | |
2962 | #include <$ac_hdr> | |
2963 | EOF | |
2964 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
2965 | { (eval echo configure:2966: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
2966 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
2967 | if test -z "$ac_err"; then | |
2968 | rm -rf conftest* | |
2969 | eval "ac_cv_header_$ac_safe=yes" | |
2970 | else | |
2971 | echo "$ac_err" >&5 | |
2972 | echo "configure: failed program was:" >&5 | |
2973 | cat conftest.$ac_ext >&5 | |
2974 | rm -rf conftest* | |
2975 | eval "ac_cv_header_$ac_safe=no" | |
2976 | fi | |
2977 | rm -f conftest* | |
2978 | fi | |
2979 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
2980 | echo "$ac_t""yes" 1>&6 | |
2981 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
2982 | cat >> confdefs.h <<EOF | |
2983 | #define $ac_tr_hdr 1 | |
2984 | EOF | |
2985 | ||
2986 | else | |
2987 | echo "$ac_t""no" 1>&6 | |
2988 | fi | |
2989 | done | |
2990 | ||
2991 | for ac_hdr in sys/time.h sys/resource.h | |
2992 | do | |
2993 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
2994 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
2995 | echo "configure:2996: checking for $ac_hdr" >&5 | |
2996 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
2997 | echo $ac_n "(cached) $ac_c" 1>&6 | |
2998 | else | |
2999 | cat > conftest.$ac_ext <<EOF | |
3000 | #line 3001 "configure" | |
3001 | #include "confdefs.h" | |
3002 | #include <$ac_hdr> | |
3003 | EOF | |
3004 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
3005 | { (eval echo configure:3006: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
3006 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
3007 | if test -z "$ac_err"; then | |
3008 | rm -rf conftest* | |
3009 | eval "ac_cv_header_$ac_safe=yes" | |
3010 | else | |
3011 | echo "$ac_err" >&5 | |
3012 | echo "configure: failed program was:" >&5 | |
3013 | cat conftest.$ac_ext >&5 | |
3014 | rm -rf conftest* | |
3015 | eval "ac_cv_header_$ac_safe=no" | |
3016 | fi | |
3017 | rm -f conftest* | |
3018 | fi | |
3019 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3020 | echo "$ac_t""yes" 1>&6 | |
3021 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3022 | cat >> confdefs.h <<EOF | |
3023 | #define $ac_tr_hdr 1 | |
3024 | EOF | |
3025 | ||
3026 | else | |
3027 | echo "$ac_t""no" 1>&6 | |
3028 | fi | |
3029 | done | |
3030 | ||
3031 | for ac_hdr in fcntl.h fpu_control.h | |
3032 | do | |
3033 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
3034 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
3035 | echo "configure:3036: checking for $ac_hdr" >&5 | |
3036 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
3037 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3038 | else | |
3039 | cat > conftest.$ac_ext <<EOF | |
3040 | #line 3041 "configure" | |
3041 | #include "confdefs.h" | |
3042 | #include <$ac_hdr> | |
3043 | EOF | |
3044 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
3045 | { (eval echo configure:3046: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
3046 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
3047 | if test -z "$ac_err"; then | |
3048 | rm -rf conftest* | |
3049 | eval "ac_cv_header_$ac_safe=yes" | |
3050 | else | |
3051 | echo "$ac_err" >&5 | |
3052 | echo "configure: failed program was:" >&5 | |
3053 | cat conftest.$ac_ext >&5 | |
3054 | rm -rf conftest* | |
3055 | eval "ac_cv_header_$ac_safe=no" | |
3056 | fi | |
3057 | rm -f conftest* | |
3058 | fi | |
3059 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3060 | echo "$ac_t""yes" 1>&6 | |
3061 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3062 | cat >> confdefs.h <<EOF | |
3063 | #define $ac_tr_hdr 1 | |
3064 | EOF | |
3065 | ||
3066 | else | |
3067 | echo "$ac_t""no" 1>&6 | |
3068 | fi | |
3069 | done | |
3070 | ||
3071 | for ac_hdr in dlfcn.h errno.h sys/stat.h | |
3072 | do | |
3073 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
3074 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
3075 | echo "configure:3076: checking for $ac_hdr" >&5 | |
3076 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
3077 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3078 | else | |
3079 | cat > conftest.$ac_ext <<EOF | |
3080 | #line 3081 "configure" | |
3081 | #include "confdefs.h" | |
3082 | #include <$ac_hdr> | |
3083 | EOF | |
3084 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
3085 | { (eval echo configure:3086: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
3086 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
3087 | if test -z "$ac_err"; then | |
3088 | rm -rf conftest* | |
3089 | eval "ac_cv_header_$ac_safe=yes" | |
3090 | else | |
3091 | echo "$ac_err" >&5 | |
3092 | echo "configure: failed program was:" >&5 | |
3093 | cat conftest.$ac_ext >&5 | |
3094 | rm -rf conftest* | |
3095 | eval "ac_cv_header_$ac_safe=no" | |
3096 | fi | |
3097 | rm -f conftest* | |
3098 | fi | |
3099 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3100 | echo "$ac_t""yes" 1>&6 | |
3101 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3102 | cat >> confdefs.h <<EOF | |
3103 | #define $ac_tr_hdr 1 | |
3104 | EOF | |
3105 | ||
3106 | else | |
3107 | echo "$ac_t""no" 1>&6 | |
3108 | fi | |
3109 | done | |
3110 | ||
3111 | for ac_func in getrusage time sigaction __setfpucw | |
3112 | do | |
3113 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 | |
3114 | echo "configure:3115: checking for $ac_func" >&5 | |
3115 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then | |
3116 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3117 | else | |
3118 | cat > conftest.$ac_ext <<EOF | |
3119 | #line 3120 "configure" | |
3120 | #include "confdefs.h" | |
3121 | /* System header to define __stub macros and hopefully few prototypes, | |
3122 | which can conflict with char $ac_func(); below. */ | |
3123 | #include <assert.h> | |
3124 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3125 | /* We use char because int might match the return type of a gcc2 | |
3126 | builtin and then its argument prototype would still apply. */ | |
3127 | char $ac_func(); | |
3128 | ||
3129 | int main() { | |
3130 | ||
3131 | /* The GNU C library defines this for functions which it implements | |
3132 | to always fail with ENOSYS. Some functions are actually named | |
3133 | something starting with __ and the normal name is an alias. */ | |
3134 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) | |
3135 | choke me | |
3136 | #else | |
3137 | $ac_func(); | |
3138 | #endif | |
3139 | ||
3140 | ; return 0; } | |
3141 | EOF | |
3142 | if { (eval echo configure:3143: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
3143 | rm -rf conftest* | |
3144 | eval "ac_cv_func_$ac_func=yes" | |
3145 | else | |
3146 | echo "configure: failed program was:" >&5 | |
3147 | cat conftest.$ac_ext >&5 | |
3148 | rm -rf conftest* | |
3149 | eval "ac_cv_func_$ac_func=no" | |
3150 | fi | |
3151 | rm -f conftest* | |
3152 | fi | |
3153 | ||
3154 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then | |
3155 | echo "$ac_t""yes" 1>&6 | |
3156 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
3157 | cat >> confdefs.h <<EOF | |
3158 | #define $ac_tr_func 1 | |
3159 | EOF | |
3160 | ||
3161 | else | |
3162 | echo "$ac_t""no" 1>&6 | |
3163 | fi | |
3164 | done | |
3165 | ||
3166 | ||
3167 | # Check for socket libraries | |
3168 | echo $ac_n "checking for bind in -lsocket""... $ac_c" 1>&6 | |
3169 | echo "configure:3170: checking for bind in -lsocket" >&5 | |
3170 | ac_lib_var=`echo socket'_'bind | sed 'y%./+-%__p_%'` | |
3171 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
3172 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3173 | else | |
3174 | ac_save_LIBS="$LIBS" | |
3175 | LIBS="-lsocket $LIBS" | |
3176 | cat > conftest.$ac_ext <<EOF | |
3177 | #line 3178 "configure" | |
3178 | #include "confdefs.h" | |
3179 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3180 | /* We use char because int might match the return type of a gcc2 | |
3181 | builtin and then its argument prototype would still apply. */ | |
3182 | char bind(); | |
3183 | ||
3184 | int main() { | |
3185 | bind() | |
3186 | ; return 0; } | |
3187 | EOF | |
3188 | if { (eval echo configure:3189: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
3189 | rm -rf conftest* | |
3190 | eval "ac_cv_lib_$ac_lib_var=yes" | |
3191 | else | |
3192 | echo "configure: failed program was:" >&5 | |
3193 | cat conftest.$ac_ext >&5 | |
3194 | rm -rf conftest* | |
3195 | eval "ac_cv_lib_$ac_lib_var=no" | |
3196 | fi | |
3197 | rm -f conftest* | |
3198 | LIBS="$ac_save_LIBS" | |
3199 | ||
3200 | fi | |
3201 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
3202 | echo "$ac_t""yes" 1>&6 | |
3203 | ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/[^a-zA-Z0-9_]/_/g' \ | |
3204 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` | |
3205 | cat >> confdefs.h <<EOF | |
3206 | #define $ac_tr_lib 1 | |
3207 | EOF | |
3208 | ||
3209 | LIBS="-lsocket $LIBS" | |
3210 | ||
3211 | else | |
3212 | echo "$ac_t""no" 1>&6 | |
3213 | fi | |
3214 | ||
3215 | echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 | |
3216 | echo "configure:3217: checking for gethostbyname in -lnsl" >&5 | |
3217 | ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` | |
3218 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then | |
3219 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3220 | else | |
3221 | ac_save_LIBS="$LIBS" | |
3222 | LIBS="-lnsl $LIBS" | |
3223 | cat > conftest.$ac_ext <<EOF | |
3224 | #line 3225 "configure" | |
3225 | #include "confdefs.h" | |
3226 | /* Override any gcc2 internal prototype to avoid an error. */ | |
3227 | /* We use char because int might match the return type of a gcc2 | |
3228 | builtin and then its argument prototype would still apply. */ | |
3229 | char gethostbyname(); | |
3230 | ||
3231 | int main() { | |
3232 | gethostbyname() | |
3233 | ; return 0; } | |
3234 | EOF | |
3235 | if { (eval echo configure:3236: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
3236 | rm -rf conftest* | |
3237 | eval "ac_cv_lib_$ac_lib_var=yes" | |
3238 | else | |
3239 | echo "configure: failed program was:" >&5 | |
3240 | cat conftest.$ac_ext >&5 | |
3241 | rm -rf conftest* | |
3242 | eval "ac_cv_lib_$ac_lib_var=no" | |
3243 | fi | |
3244 | rm -f conftest* | |
3245 | LIBS="$ac_save_LIBS" | |
3246 | ||
3247 | fi | |
3248 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then | |
3249 | echo "$ac_t""yes" 1>&6 | |
3250 | ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ | |
3251 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` | |
3252 | cat >> confdefs.h <<EOF | |
3253 | #define $ac_tr_lib 1 | |
3254 | EOF | |
3255 | ||
3256 | LIBS="-lnsl $LIBS" | |
3257 | ||
3258 | else | |
3259 | echo "$ac_t""no" 1>&6 | |
3260 | fi | |
3261 | ||
3262 | ||
3263 | . ${srcdir}/../../bfd/configure.host | |
3264 | ||
3265 | ||
3266 | ||
3267 | USE_MAINTAINER_MODE=no | |
3268 | # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. | |
3269 | if test "${enable_maintainer_mode+set}" = set; then | |
3270 | enableval="$enable_maintainer_mode" | |
3271 | case "${enableval}" in | |
3272 | yes) MAINT="" USE_MAINTAINER_MODE=yes ;; | |
3273 | no) MAINT="#" ;; | |
3274 | *) { echo "configure: error: "--enable-maintainer-mode does not take a value"" 1>&2; exit 1; }; MAINT="#" ;; | |
3275 | esac | |
3276 | if test x"$silent" != x"yes" && test x"$MAINT" = x""; then | |
3277 | echo "Setting maintainer mode" 6>&1 | |
3278 | fi | |
3279 | else | |
3280 | MAINT="#" | |
3281 | fi | |
3282 | ||
3283 | ||
3284 | ||
3285 | # Check whether --enable-sim-bswap or --disable-sim-bswap was given. | |
3286 | if test "${enable_sim_bswap+set}" = set; then | |
3287 | enableval="$enable_sim_bswap" | |
3288 | case "${enableval}" in | |
3289 | yes) sim_bswap="-DWITH_BSWAP=1 -DUSE_BSWAP=1";; | |
3290 | no) sim_bswap="-DWITH_BSWAP=0";; | |
3291 | *) { echo "configure: error: "--enable-sim-bswap does not take a value"" 1>&2; exit 1; }; sim_bswap="";; | |
3292 | esac | |
3293 | if test x"$silent" != x"yes" && test x"$sim_bswap" != x""; then | |
3294 | echo "Setting bswap flags = $sim_bswap" 6>&1 | |
3295 | fi | |
3296 | else | |
3297 | sim_bswap="" | |
3298 | fi | |
3299 | ||
3300 | ||
3301 | ||
3302 | # Check whether --enable-sim-cflags or --disable-sim-cflags was given. | |
3303 | if test "${enable_sim_cflags+set}" = set; then | |
3304 | enableval="$enable_sim_cflags" | |
3305 | case "${enableval}" in | |
3306 | yes) sim_cflags="-O2 -fomit-frame-pointer";; | |
3307 | trace) { echo "configure: error: "Please use --enable-sim-debug instead."" 1>&2; exit 1; }; sim_cflags="";; | |
3308 | no) sim_cflags="";; | |
3309 | *) sim_cflags=`echo "${enableval}" | sed -e "s/,/ /g"`;; | |
3310 | esac | |
3311 | if test x"$silent" != x"yes" && test x"$sim_cflags" != x""; then | |
3312 | echo "Setting sim cflags = $sim_cflags" 6>&1 | |
3313 | fi | |
3314 | else | |
3315 | sim_cflags="" | |
3316 | fi | |
3317 | ||
3318 | ||
3319 | ||
3320 | # Check whether --enable-sim-debug or --disable-sim-debug was given. | |
3321 | if test "${enable_sim_debug+set}" = set; then | |
3322 | enableval="$enable_sim_debug" | |
3323 | case "${enableval}" in | |
3324 | yes) sim_debug="-DDEBUG=7 -DWITH_DEBUG=7";; | |
3325 | no) sim_debug="-DDEBUG=0 -DWITH_DEBUG=0";; | |
3326 | *) sim_debug="-DDEBUG='(${enableval})' -DWITH_DEBUG='(${enableval})'";; | |
3327 | esac | |
3328 | if test x"$silent" != x"yes" && test x"$sim_debug" != x""; then | |
3329 | echo "Setting sim debug = $sim_debug" 6>&1 | |
3330 | fi | |
3331 | else | |
3332 | sim_debug="" | |
3333 | fi | |
3334 | ||
3335 | ||
3336 | ||
3337 | # Check whether --enable-sim-stdio or --disable-sim-stdio was given. | |
3338 | if test "${enable_sim_stdio+set}" = set; then | |
3339 | enableval="$enable_sim_stdio" | |
3340 | case "${enableval}" in | |
3341 | yes) sim_stdio="-DWITH_STDIO=DO_USE_STDIO";; | |
3342 | no) sim_stdio="-DWITH_STDIO=DONT_USE_STDIO";; | |
3343 | *) { echo "configure: error: "Unknown value $enableval passed to --enable-sim-stdio"" 1>&2; exit 1; }; sim_stdio="";; | |
3344 | esac | |
3345 | if test x"$silent" != x"yes" && test x"$sim_stdio" != x""; then | |
3346 | echo "Setting stdio flags = $sim_stdio" 6>&1 | |
3347 | fi | |
3348 | else | |
3349 | sim_stdio="" | |
3350 | fi | |
3351 | ||
3352 | ||
3353 | ||
3354 | # Check whether --enable-sim-trace or --disable-sim-trace was given. | |
3355 | if test "${enable_sim_trace+set}" = set; then | |
3356 | enableval="$enable_sim_trace" | |
3357 | case "${enableval}" in | |
3358 | yes) sim_trace="-DTRACE=1 -DWITH_TRACE=-1";; | |
3359 | no) sim_trace="-DTRACE=0 -DWITH_TRACE=0";; | |
3360 | [-0-9]*) | |
3361 | sim_trace="-DTRACE='(${enableval})' -DWITH_TRACE='(${enableval})'";; | |
3362 | [a-z]*) | |
3363 | sim_trace="" | |
3364 | for x in `echo "$enableval" | sed -e "s/,/ /g"`; do | |
3365 | if test x"$sim_trace" = x; then | |
3366 | sim_trace="-DWITH_TRACE='(TRACE_$x" | |
3367 | else | |
3368 | sim_trace="${sim_trace}|TRACE_$x" | |
3369 | fi | |
3370 | done | |
3371 | sim_trace="$sim_trace)'" ;; | |
3372 | esac | |
3373 | if test x"$silent" != x"yes" && test x"$sim_trace" != x""; then | |
3374 | echo "Setting sim trace = $sim_trace" 6>&1 | |
3375 | fi | |
3376 | else | |
3377 | sim_trace="" | |
3378 | fi | |
3379 | ||
3380 | ||
3381 | ||
3382 | # Check whether --enable-sim-profile or --disable-sim-profile was given. | |
3383 | if test "${enable_sim_profile+set}" = set; then | |
3384 | enableval="$enable_sim_profile" | |
3385 | case "${enableval}" in | |
3386 | yes) sim_profile="-DPROFILE=1 -DWITH_PROFILE=-1";; | |
3387 | no) sim_profile="-DPROFILE=0 -DWITH_PROFILE=0";; | |
3388 | [-0-9]*) | |
3389 | sim_profile="-DPROFILE='(${enableval})' -DWITH_PROFILE='(${enableval})'";; | |
3390 | [a-z]*) | |
3391 | sim_profile="" | |
3392 | for x in `echo "$enableval" | sed -e "s/,/ /g"`; do | |
3393 | if test x"$sim_profile" = x; then | |
3394 | sim_profile="-DWITH_PROFILE='(PROFILE_$x" | |
3395 | else | |
3396 | sim_profile="${sim_profile}|PROFILE_$x" | |
3397 | fi | |
3398 | done | |
3399 | sim_profile="$sim_profile)'" ;; | |
3400 | esac | |
3401 | if test x"$silent" != x"yes" && test x"$sim_profile" != x""; then | |
3402 | echo "Setting sim profile = $sim_profile" 6>&1 | |
3403 | fi | |
3404 | else | |
3405 | sim_profile="-DPROFILE=1 -DWITH_PROFILE=-1" | |
3406 | fi | |
3407 | ||
3408 | ||
3409 | ||
3410 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 | |
3411 | echo "configure:3412: checking return type of signal handlers" >&5 | |
3412 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then | |
3413 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3414 | else | |
3415 | cat > conftest.$ac_ext <<EOF | |
3416 | #line 3417 "configure" | |
3417 | #include "confdefs.h" | |
3418 | #include <sys/types.h> | |
3419 | #include <signal.h> | |
3420 | #ifdef signal | |
3421 | #undef signal | |
3422 | #endif | |
3423 | #ifdef __cplusplus | |
3424 | extern "C" void (*signal (int, void (*)(int)))(int); | |
3425 | #else | |
3426 | void (*signal ()) (); | |
3427 | #endif | |
3428 | ||
3429 | int main() { | |
3430 | int i; | |
3431 | ; return 0; } | |
3432 | EOF | |
3433 | if { (eval echo configure:3434: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | |
3434 | rm -rf conftest* | |
3435 | ac_cv_type_signal=void | |
3436 | else | |
3437 | echo "configure: failed program was:" >&5 | |
3438 | cat conftest.$ac_ext >&5 | |
3439 | rm -rf conftest* | |
3440 | ac_cv_type_signal=int | |
3441 | fi | |
3442 | rm -f conftest* | |
3443 | fi | |
3444 | ||
3445 | echo "$ac_t""$ac_cv_type_signal" 1>&6 | |
3446 | cat >> confdefs.h <<EOF | |
3447 | #define RETSIGTYPE $ac_cv_type_signal | |
3448 | EOF | |
3449 | ||
3450 | ||
3451 | ||
3452 | ||
3453 | ||
3454 | echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 | |
3455 | echo "configure:3456: checking for executable suffix" >&5 | |
3456 | if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then | |
3457 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3458 | else | |
3459 | if test "$CYGWIN" = yes || test "$MINGW32" = yes; then | |
3460 | ac_cv_exeext=.exe | |
3461 | else | |
3462 | rm -f conftest* | |
3463 | echo 'int main () { return 0; }' > conftest.$ac_ext | |
3464 | ac_cv_exeext= | |
3465 | if { (eval echo configure:3466: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then | |
3466 | for file in conftest.*; do | |
3467 | case $file in | |
3468 | *.c | *.o | *.obj | *.ilk | *.pdb) ;; | |
3469 | *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;; | |
3470 | esac | |
3471 | done | |
3472 | else | |
3473 | { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; } | |
3474 | fi | |
3475 | rm -f conftest* | |
3476 | test x"${ac_cv_exeext}" = x && ac_cv_exeext=no | |
3477 | fi | |
3478 | fi | |
3479 | ||
3480 | EXEEXT="" | |
3481 | test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext} | |
3482 | echo "$ac_t""${ac_cv_exeext}" 1>&6 | |
3483 | ac_exeext=$EXEEXT | |
3484 | ||
3485 | ||
3486 | sim_link_files= | |
3487 | sim_link_links= | |
3488 | ||
3489 | sim_link_links=tconfig.h | |
3490 | if test -f ${srcdir}/tconfig.in | |
3491 | then | |
3492 | sim_link_files=tconfig.in | |
3493 | else | |
3494 | sim_link_files=../common/tconfig.in | |
3495 | fi | |
3496 | ||
3497 | # targ-vals.def points to the libc macro description file. | |
3498 | case "${target}" in | |
3499 | *-*-*) TARG_VALS_DEF=../common/nltvals.def ;; | |
3500 | esac | |
3501 | sim_link_files="${sim_link_files} ${TARG_VALS_DEF}" | |
3502 | sim_link_links="${sim_link_links} targ-vals.def" | |
3503 | ||
3504 | ||
3505 | ||
3506 | ||
3507 | default_sim_inline="" | |
3508 | # Check whether --enable-sim-inline or --disable-sim-inline was given. | |
3509 | if test "${enable_sim_inline+set}" = set; then | |
3510 | enableval="$enable_sim_inline" | |
3511 | sim_inline="" | |
3512 | case "$enableval" in | |
3513 | no) sim_inline="-DDEFAULT_INLINE=0";; | |
3514 | 0) sim_inline="-DDEFAULT_INLINE=0";; | |
3515 | yes | 2) sim_inline="-DDEFAULT_INLINE=ALL_C_INLINE";; | |
3516 | 1) sim_inline="-DDEFAULT_INLINE=INLINE_LOCALS";; | |
3517 | *) for x in `echo "$enableval" | sed -e "s/,/ /g"`; do | |
3518 | new_flag="" | |
3519 | case "$x" in | |
3520 | *_INLINE=*) new_flag="-D$x";; | |
3521 | *=*) new_flag=`echo "$x" | sed -e "s/=/_INLINE=/" -e "s/^/-D/"`;; | |
3522 | *_INLINE) new_flag="-D$x=ALL_C_INLINE";; | |
3523 | *) new_flag="-D$x""_INLINE=ALL_C_INLINE";; | |
3524 | esac | |
3525 | if test x"$sim_inline" = x""; then | |
3526 | sim_inline="$new_flag" | |
3527 | else | |
3528 | sim_inline="$sim_inline $new_flag" | |
3529 | fi | |
3530 | done;; | |
3531 | esac | |
3532 | if test x"$silent" != x"yes" && test x"$sim_inline" != x""; then | |
3533 | echo "Setting inline flags = $sim_inline" 6>&1 | |
3534 | fi | |
3535 | else | |
3536 | ||
3537 | if test "x$cross_compiling" = "xno"; then | |
3538 | if test x"$GCC" != "x" -a x"${default_sim_inline}" != "x" ; then | |
3539 | sim_inline="${default_sim_inline}" | |
3540 | if test x"$silent" != x"yes"; then | |
3541 | echo "Setting inline flags = $sim_inline" 6>&1 | |
3542 | fi | |
3543 | else | |
3544 | sim_inline="" | |
3545 | fi | |
3546 | else | |
3547 | sim_inline="-DDEFAULT_INLINE=0" | |
3548 | fi | |
3549 | fi | |
3550 | ||
3551 | wire_alignment="NONSTRICT_ALIGNMENT" | |
3552 | default_alignment="" | |
3553 | ||
3554 | # Check whether --enable-sim-alignment or --disable-sim-alignment was given. | |
3555 | if test "${enable_sim_alignment+set}" = set; then | |
3556 | enableval="$enable_sim_alignment" | |
3557 | case "${enableval}" in | |
3558 | strict | STRICT) sim_alignment="-DWITH_ALIGNMENT=STRICT_ALIGNMENT";; | |
3559 | nonstrict | NONSTRICT) sim_alignment="-DWITH_ALIGNMENT=NONSTRICT_ALIGNMENT";; | |
3560 | forced | FORCED) sim_alignment="-DWITH_ALIGNMENT=FORCED_ALIGNMENT";; | |
3561 | yes) if test x"$wire_alignment" != x; then | |
3562 | sim_alignment="-DWITH_ALIGNMENT=${wire_alignment}" | |
3563 | else | |
3564 | if test x"$default_alignment" != x; then | |
3565 | sim_alignment="-DWITH_ALIGNMENT=${default_alignment}" | |
3566 | else | |
3567 | echo "No hard-wired alignment for target $target" 1>&6 | |
3568 | sim_alignment="-DWITH_ALIGNMENT=0" | |
3569 | fi | |
3570 | fi;; | |
3571 | no) if test x"$default_alignment" != x; then | |
3572 | sim_alignment="-DWITH_DEFAULT_ALIGNMENT=${default_alignment}" | |
3573 | else | |
3574 | if test x"$wire_alignment" != x; then | |
3575 | sim_alignment="-DWITH_DEFAULT_ALIGNMENT=${wire_alignment}" | |
3576 | else | |
3577 | echo "No default alignment for target $target" 1>&6 | |
3578 | sim_alignment="-DWITH_DEFAULT_ALIGNMENT=0" | |
3579 | fi | |
3580 | fi;; | |
3581 | *) { echo "configure: error: "Unknown value $enableval passed to --enable-sim-alignment"" 1>&2; exit 1; }; sim_alignment="";; | |
3582 | esac | |
3583 | if test x"$silent" != x"yes" && test x"$sim_alignment" != x""; then | |
3584 | echo "Setting alignment flags = $sim_alignment" 6>&1 | |
3585 | fi | |
3586 | else | |
3587 | if test x"$default_alignment" != x; then | |
3588 | sim_alignment="-DWITH_DEFAULT_ALIGNMENT=${default_alignment}" | |
3589 | else | |
3590 | if test x"$wire_alignment" != x; then | |
3591 | sim_alignment="-DWITH_ALIGNMENT=${wire_alignment}" | |
3592 | else | |
3593 | sim_alignment= | |
3594 | fi | |
3595 | fi | |
3596 | fi | |
3597 | ||
3598 | ||
3599 | # Check whether --enable-sim-hostendian or --disable-sim-hostendian was given. | |
3600 | if test "${enable_sim_hostendian+set}" = set; then | |
3601 | enableval="$enable_sim_hostendian" | |
3602 | case "${enableval}" in | |
3603 | no) sim_hostendian="-DWITH_HOST_BYTE_ORDER=0";; | |
3604 | b*|B*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN";; | |
3605 | l*|L*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN";; | |
3606 | *) { echo "configure: error: "Unknown value $enableval for --enable-sim-hostendian"" 1>&2; exit 1; }; sim_hostendian="";; | |
3607 | esac | |
3608 | if test x"$silent" != x"yes" && test x"$sim_hostendian" != x""; then | |
3609 | echo "Setting hostendian flags = $sim_hostendian" 6>&1 | |
3610 | fi | |
3611 | else | |
3612 | ||
3613 | if test "x$cross_compiling" = "xno"; then | |
3614 | echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 | |
3615 | echo "configure:3616: checking whether byte ordering is bigendian" >&5 | |
3616 | if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then | |
3617 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3618 | else | |
3619 | ac_cv_c_bigendian=unknown | |
3620 | # See if sys/param.h defines the BYTE_ORDER macro. | |
3621 | cat > conftest.$ac_ext <<EOF | |
3622 | #line 3623 "configure" | |
3623 | #include "confdefs.h" | |
3624 | #include <sys/types.h> | |
3625 | #include <sys/param.h> | |
3626 | int main() { | |
3627 | ||
3628 | #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN | |
3629 | bogus endian macros | |
3630 | #endif | |
3631 | ; return 0; } | |
3632 | EOF | |
3633 | if { (eval echo configure:3634: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | |
3634 | rm -rf conftest* | |
3635 | # It does; now see whether it defined to BIG_ENDIAN or not. | |
3636 | cat > conftest.$ac_ext <<EOF | |
3637 | #line 3638 "configure" | |
3638 | #include "confdefs.h" | |
3639 | #include <sys/types.h> | |
3640 | #include <sys/param.h> | |
3641 | int main() { | |
3642 | ||
3643 | #if BYTE_ORDER != BIG_ENDIAN | |
3644 | not big endian | |
3645 | #endif | |
3646 | ; return 0; } | |
3647 | EOF | |
3648 | if { (eval echo configure:3649: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then | |
3649 | rm -rf conftest* | |
3650 | ac_cv_c_bigendian=yes | |
3651 | else | |
3652 | echo "configure: failed program was:" >&5 | |
3653 | cat conftest.$ac_ext >&5 | |
3654 | rm -rf conftest* | |
3655 | ac_cv_c_bigendian=no | |
3656 | fi | |
3657 | rm -f conftest* | |
3658 | else | |
3659 | echo "configure: failed program was:" >&5 | |
3660 | cat conftest.$ac_ext >&5 | |
3661 | fi | |
3662 | rm -f conftest* | |
3663 | if test $ac_cv_c_bigendian = unknown; then | |
3664 | if test "$cross_compiling" = yes; then | |
3665 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } | |
3666 | else | |
3667 | cat > conftest.$ac_ext <<EOF | |
3668 | #line 3669 "configure" | |
3669 | #include "confdefs.h" | |
3670 | main () { | |
3671 | /* Are we little or big endian? From Harbison&Steele. */ | |
3672 | union | |
3673 | { | |
3674 | long l; | |
3675 | char c[sizeof (long)]; | |
3676 | } u; | |
3677 | u.l = 1; | |
3678 | exit (u.c[sizeof (long) - 1] == 1); | |
3679 | } | |
3680 | EOF | |
3681 | if { (eval echo configure:3682: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null | |
3682 | then | |
3683 | ac_cv_c_bigendian=no | |
3684 | else | |
3685 | echo "configure: failed program was:" >&5 | |
3686 | cat conftest.$ac_ext >&5 | |
3687 | rm -fr conftest* | |
3688 | ac_cv_c_bigendian=yes | |
3689 | fi | |
3690 | rm -fr conftest* | |
3691 | fi | |
3692 | ||
3693 | fi | |
3694 | fi | |
3695 | ||
3696 | echo "$ac_t""$ac_cv_c_bigendian" 1>&6 | |
3697 | if test $ac_cv_c_bigendian = yes; then | |
3698 | cat >> confdefs.h <<\EOF | |
3699 | #define WORDS_BIGENDIAN 1 | |
3700 | EOF | |
3701 | ||
3702 | fi | |
3703 | ||
3704 | if test $ac_cv_c_bigendian = yes; then | |
3705 | sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN" | |
3706 | else | |
3707 | sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN" | |
3708 | fi | |
3709 | else | |
3710 | sim_hostendian="-DWITH_HOST_BYTE_ORDER=0" | |
3711 | fi | |
3712 | fi | |
3713 | ||
3714 | ||
3715 | # Check whether --enable-build-warnings or --disable-build-warnings was given. | |
3716 | if test "${enable_build_warnings+set}" = set; then | |
3717 | enableval="$enable_build_warnings" | |
3718 | build_warnings="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations" | |
3719 | case "${enableval}" in | |
3720 | yes) ;; | |
3721 | no) build_warnings="-w";; | |
3722 | ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
3723 | build_warnings="${build_warnings} ${t}";; | |
3724 | *,) t=`echo "${enableval}" | sed -e "s/,/ /g"` | |
3725 | build_warnings="${t} ${build_warnings}";; | |
3726 | *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;; | |
3727 | esac | |
3728 | if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then | |
3729 | echo "Setting warning flags = $build_warnings" 6>&1 | |
3730 | fi | |
3731 | WARN_CFLAGS="" | |
3732 | WERROR_CFLAGS="" | |
3733 | if test "x${build_warnings}" != x -a "x$GCC" = xyes | |
3734 | then | |
3735 | # Separate out the -Werror flag as some files just cannot be | |
3736 | # compiled with it enabled. | |
3737 | for w in ${build_warnings}; do | |
3738 | case $w in | |
3739 | -Werr*) WERROR_CFLAGS=-Werror ;; | |
3740 | *) WARN_CFLAGS="${WARN_CFLAGS} $w" | |
3741 | esac | |
3742 | done | |
3743 | fi | |
3744 | else | |
3745 | build_warnings="" | |
3746 | fi | |
3747 | ||
3748 | ||
3749 | # | |
3750 | # Add simulated hardware devices | |
3751 | # | |
3752 | hw_enabled=no | |
3753 | case "${target}" in | |
3754 | m68hc11-*-*|m6811-*-*) | |
3755 | hw_enabled=yes | |
3756 | hw_extra_devices="m68hc11 m68hc11sio m68hc11eepr m68hc11tim m68hc11spi nvram" | |
3757 | m68hc11_extra_objs="dv-sockser.o" | |
3758 | SIM_SUBTARGET="$SIM_SUBTARGET -DTARGET_M68HC11=1" | |
3759 | ;; | |
3760 | *) | |
3761 | m68hc11_extra_objs="" | |
3762 | ;; | |
3763 | esac | |
3764 | ||
3765 | if test x"$hw_enabled" = x"yes"; then | |
3766 | sim_hw_p=yes | |
3767 | else | |
3768 | sim_hw_p=no | |
3769 | fi | |
3770 | if test "$hw_devices"; then | |
3771 | hardware="core pal glue" | |
3772 | else | |
3773 | hardware="core pal glue $hw_extra_devices" | |
3774 | fi | |
3775 | sim_hw_cflags="-DWITH_HW=1" | |
3776 | sim_hw="$hardware" | |
3777 | sim_hw_objs="\$(SIM_COMMON_HW_OBJS) `echo $sim_hw | sed -e 's/\([^ ][^ ]*\)/dv-\1.o/g'`" | |
3778 | # Check whether --enable-sim-hardware or --disable-sim-hardware was given. | |
3779 | if test "${enable_sim_hardware+set}" = set; then | |
3780 | enableval="$enable_sim_hardware" | |
3781 | ||
3782 | case "${enableval}" in | |
3783 | yes) sim_hw_p=yes;; | |
3784 | no) sim_hw_p=no;; | |
3785 | ,*) sim_hw_p=yes; hardware="${hardware} `echo ${enableval} | sed -e 's/,/ /'`";; | |
3786 | *,) sim_hw_p=yes; hardware="`echo ${enableval} | sed -e 's/,/ /'` ${hardware}";; | |
3787 | *) sim_hw_p=yes; hardware="`echo ${enableval} | sed -e 's/,/ /'`"'';; | |
3788 | esac | |
3789 | if test "$sim_hw_p" != yes; then | |
3790 | sim_hw_objs= | |
3791 | sim_hw_cflags="-DWITH_HW=0" | |
3792 | sim_hw= | |
3793 | else | |
3794 | sim_hw_cflags="-DWITH_HW=1" | |
3795 | # remove duplicates | |
3796 | sim_hw="" | |
3797 | sim_hw_objs="\$(SIM_COMMON_HW_OBJS)" | |
3798 | for i in x $hardware ; do | |
3799 | case " $f " in | |
3800 | x) ;; | |
3801 | *" $i "*) ;; | |
3802 | *) sim_hw="$sim_hw $i" ; sim_hw_objs="$sim_hw_objs dv-$i.o";; | |
3803 | esac | |
3804 | done | |
3805 | fi | |
3806 | if test x"$silent" != x"yes" && test "$sim_hw_p" = "yes"; then | |
3807 | echo "Setting hardware to $sim_hw_cflags, $sim_hw, $sim_hw_objs" | |
3808 | fi | |
3809 | else | |
3810 | ||
3811 | if test "$sim_hw_p" != yes; then | |
3812 | sim_hw_objs= | |
3813 | sim_hw_cflags="-DWITH_HW=0" | |
3814 | sim_hw= | |
3815 | fi | |
3816 | if test x"$silent" != x"yes"; then | |
3817 | echo "Setting hardware to $sim_hw_cflags, $sim_hw, $sim_hw_objs" | |
3818 | fi | |
3819 | fi | |
3820 | ||
3821 | ||
3822 | for ac_hdr in string.h strings.h stdlib.h stdlib.h fcntl.h | |
3823 | do | |
3824 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` | |
3825 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 | |
3826 | echo "configure:3827: checking for $ac_hdr" >&5 | |
3827 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then | |
3828 | echo $ac_n "(cached) $ac_c" 1>&6 | |
3829 | else | |
3830 | cat > conftest.$ac_ext <<EOF | |
3831 | #line 3832 "configure" | |
3832 | #include "confdefs.h" | |
3833 | #include <$ac_hdr> | |
3834 | EOF | |
3835 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" | |
3836 | { (eval echo configure:3837: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } | |
3837 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` | |
3838 | if test -z "$ac_err"; then | |
3839 | rm -rf conftest* | |
3840 | eval "ac_cv_header_$ac_safe=yes" | |
3841 | else | |
3842 | echo "$ac_err" >&5 | |
3843 | echo "configure: failed program was:" >&5 | |
3844 | cat conftest.$ac_ext >&5 | |
3845 | rm -rf conftest* | |
3846 | eval "ac_cv_header_$ac_safe=no" | |
3847 | fi | |
3848 | rm -f conftest* | |
3849 | fi | |
3850 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then | |
3851 | echo "$ac_t""yes" 1>&6 | |
3852 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` | |
3853 | cat >> confdefs.h <<EOF | |
3854 | #define $ac_tr_hdr 1 | |
3855 | EOF | |
3856 | ||
3857 | else | |
3858 | echo "$ac_t""no" 1>&6 | |
3859 | fi | |
3860 | done | |
3861 | ||
3862 | ||
3863 | ||
3864 | ||
3865 | ||
3866 | ||
3867 | trap '' 1 2 15 | |
3868 | cat > confcache <<\EOF | |
3869 | # This file is a shell script that caches the results of configure | |
3870 | # tests run on this system so they can be shared between configure | |
3871 | # scripts and configure runs. It is not useful on other systems. | |
3872 | # If it contains results you don't want to keep, you may remove or edit it. | |
3873 | # | |
3874 | # By default, configure uses ./config.cache as the cache file, | |
3875 | # creating it if it does not exist already. You can give configure | |
3876 | # the --cache-file=FILE option to use a different cache file; that is | |
3877 | # what configure does when it calls configure scripts in | |
3878 | # subdirectories, so they share the cache. | |
3879 | # Giving --cache-file=/dev/null disables caching, for debugging configure. | |
3880 | # config.status only pays attention to the cache file if you give it the | |
3881 | # --recheck option to rerun configure. | |
3882 | # | |
3883 | EOF | |
3884 | # The following way of writing the cache mishandles newlines in values, | |
3885 | # but we know of no workaround that is simple, portable, and efficient. | |
3886 | # So, don't put newlines in cache variables' values. | |
3887 | # Ultrix sh set writes to stderr and can't be redirected directly, | |
3888 | # and sets the high bit in the cache file unless we assign to the vars. | |
3889 | (set) 2>&1 | | |
3890 | case `(ac_space=' '; set | grep ac_space) 2>&1` in | |
3891 | *ac_space=\ *) | |
3892 | # `set' does not quote correctly, so add quotes (double-quote substitution | |
3893 | # turns \\\\ into \\, and sed turns \\ into \). | |
3894 | sed -n \ | |
3895 | -e "s/'/'\\\\''/g" \ | |
3896 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" | |
3897 | ;; | |
3898 | *) | |
3899 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
3900 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' | |
3901 | ;; | |
3902 | esac >> confcache | |
3903 | if cmp -s $cache_file confcache; then | |
3904 | : | |
3905 | else | |
3906 | if test -w $cache_file; then | |
3907 | echo "updating cache $cache_file" | |
3908 | cat confcache > $cache_file | |
3909 | else | |
3910 | echo "not updating unwritable cache $cache_file" | |
3911 | fi | |
3912 | fi | |
3913 | rm -f confcache | |
3914 | ||
3915 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 | |
3916 | ||
3917 | test "x$prefix" = xNONE && prefix=$ac_default_prefix | |
3918 | # Let make expand exec_prefix. | |
3919 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
3920 | ||
3921 | # Any assignment to VPATH causes Sun make to only execute | |
3922 | # the first set of double-colon rules, so remove it if not needed. | |
3923 | # If there is a colon in the path, we need to keep it. | |
3924 | if test "x$srcdir" = x.; then | |
3925 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' | |
3926 | fi | |
3927 | ||
3928 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 | |
3929 | ||
3930 | DEFS=-DHAVE_CONFIG_H | |
3931 | ||
3932 | # Without the "./", some shells look in PATH for config.status. | |
3933 | : ${CONFIG_STATUS=./config.status} | |
3934 | ||
3935 | echo creating $CONFIG_STATUS | |
3936 | rm -f $CONFIG_STATUS | |
3937 | cat > $CONFIG_STATUS <<EOF | |
3938 | #! /bin/sh | |
3939 | # Generated automatically by configure. | |
3940 | # Run this file to recreate the current configuration. | |
3941 | # This directory was configured as follows, | |
3942 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: | |
3943 | # | |
3944 | # $0 $ac_configure_args | |
3945 | # | |
3946 | # Compiler output produced by configure, useful for debugging | |
3947 | # configure, is in ./config.log if it exists. | |
3948 | ||
3949 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" | |
3950 | for ac_option | |
3951 | do | |
3952 | case "\$ac_option" in | |
3953 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) | |
3954 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" | |
3955 | exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; | |
3956 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) | |
3957 | echo "$CONFIG_STATUS generated by autoconf version 2.13" | |
3958 | exit 0 ;; | |
3959 | -help | --help | --hel | --he | --h) | |
3960 | echo "\$ac_cs_usage"; exit 0 ;; | |
3961 | *) echo "\$ac_cs_usage"; exit 1 ;; | |
3962 | esac | |
3963 | done | |
3964 | ||
3965 | ac_given_srcdir=$srcdir | |
3966 | ac_given_INSTALL="$INSTALL" | |
3967 | ||
3968 | 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 | |
3969 | EOF | |
3970 | cat >> $CONFIG_STATUS <<EOF | |
3971 | ||
3972 | # Protect against being on the right side of a sed subst in config.status. | |
3973 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; | |
3974 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF | |
3975 | $ac_vpsub | |
3976 | $extrasub | |
3977 | s%@sim_environment@%$sim_environment%g | |
3978 | s%@sim_alignment@%$sim_alignment%g | |
3979 | s%@sim_assert@%$sim_assert%g | |
3980 | s%@sim_bitsize@%$sim_bitsize%g | |
3981 | s%@sim_endian@%$sim_endian%g | |
3982 | s%@sim_hostendian@%$sim_hostendian%g | |
3983 | s%@sim_float@%$sim_float%g | |
3984 | s%@sim_scache@%$sim_scache%g | |
3985 | s%@sim_default_model@%$sim_default_model%g | |
3986 | s%@sim_hw_cflags@%$sim_hw_cflags%g | |
3987 | s%@sim_hw_objs@%$sim_hw_objs%g | |
3988 | s%@sim_hw@%$sim_hw%g | |
3989 | s%@sim_inline@%$sim_inline%g | |
3990 | s%@sim_packages@%$sim_packages%g | |
3991 | s%@sim_regparm@%$sim_regparm%g | |
3992 | s%@sim_reserved_bits@%$sim_reserved_bits%g | |
3993 | s%@sim_smp@%$sim_smp%g | |
3994 | s%@sim_stdcall@%$sim_stdcall%g | |
3995 | s%@sim_xor_endian@%$sim_xor_endian%g | |
3996 | s%@WARN_CFLAGS@%$WARN_CFLAGS%g | |
3997 | s%@WERROR_CFLAGS@%$WERROR_CFLAGS%g | |
3998 | s%@SHELL@%$SHELL%g | |
3999 | s%@CFLAGS@%$CFLAGS%g | |
4000 | s%@CPPFLAGS@%$CPPFLAGS%g | |
4001 | s%@CXXFLAGS@%$CXXFLAGS%g | |
4002 | s%@FFLAGS@%$FFLAGS%g | |
4003 | s%@DEFS@%$DEFS%g | |
4004 | s%@LDFLAGS@%$LDFLAGS%g | |
4005 | s%@LIBS@%$LIBS%g | |
4006 | s%@exec_prefix@%$exec_prefix%g | |
4007 | s%@prefix@%$prefix%g | |
4008 | s%@program_transform_name@%$program_transform_name%g | |
4009 | s%@bindir@%$bindir%g | |
4010 | s%@sbindir@%$sbindir%g | |
4011 | s%@libexecdir@%$libexecdir%g | |
4012 | s%@datadir@%$datadir%g | |
4013 | s%@sysconfdir@%$sysconfdir%g | |
4014 | s%@sharedstatedir@%$sharedstatedir%g | |
4015 | s%@localstatedir@%$localstatedir%g | |
4016 | s%@libdir@%$libdir%g | |
4017 | s%@includedir@%$includedir%g | |
4018 | s%@oldincludedir@%$oldincludedir%g | |
4019 | s%@infodir@%$infodir%g | |
4020 | s%@mandir@%$mandir%g | |
4021 | s%@host@%$host%g | |
4022 | s%@host_alias@%$host_alias%g | |
4023 | s%@host_cpu@%$host_cpu%g | |
4024 | s%@host_vendor@%$host_vendor%g | |
4025 | s%@host_os@%$host_os%g | |
4026 | s%@target@%$target%g | |
4027 | s%@target_alias@%$target_alias%g | |
4028 | s%@target_cpu@%$target_cpu%g | |
4029 | s%@target_vendor@%$target_vendor%g | |
4030 | s%@target_os@%$target_os%g | |
4031 | s%@build@%$build%g | |
4032 | s%@build_alias@%$build_alias%g | |
4033 | s%@build_cpu@%$build_cpu%g | |
4034 | s%@build_vendor@%$build_vendor%g | |
4035 | s%@build_os@%$build_os%g | |
4036 | s%@CC@%$CC%g | |
4037 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g | |
4038 | s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g | |
4039 | s%@INSTALL_DATA@%$INSTALL_DATA%g | |
4040 | s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g | |
4041 | s%@HDEFINES@%$HDEFINES%g | |
4042 | s%@AR@%$AR%g | |
4043 | s%@RANLIB@%$RANLIB%g | |
4044 | s%@SET_MAKE@%$SET_MAKE%g | |
4045 | s%@CPP@%$CPP%g | |
4046 | s%@ALLOCA@%$ALLOCA%g | |
4047 | s%@USE_NLS@%$USE_NLS%g | |
4048 | s%@MSGFMT@%$MSGFMT%g | |
4049 | s%@GMSGFMT@%$GMSGFMT%g | |
4050 | s%@XGETTEXT@%$XGETTEXT%g | |
4051 | s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g | |
4052 | s%@CATALOGS@%$CATALOGS%g | |
4053 | s%@CATOBJEXT@%$CATOBJEXT%g | |
4054 | s%@DATADIRNAME@%$DATADIRNAME%g | |
4055 | s%@GMOFILES@%$GMOFILES%g | |
4056 | s%@INSTOBJEXT@%$INSTOBJEXT%g | |
4057 | s%@INTLDEPS@%$INTLDEPS%g | |
4058 | s%@INTLLIBS@%$INTLLIBS%g | |
4059 | s%@INTLOBJS@%$INTLOBJS%g | |
4060 | s%@POFILES@%$POFILES%g | |
4061 | s%@POSUB@%$POSUB%g | |
4062 | s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g | |
4063 | s%@GT_NO@%$GT_NO%g | |
4064 | s%@GT_YES@%$GT_YES%g | |
4065 | s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g | |
4066 | s%@l@%$l%g | |
4067 | s%@MAINT@%$MAINT%g | |
4068 | s%@sim_bswap@%$sim_bswap%g | |
4069 | s%@sim_cflags@%$sim_cflags%g | |
4070 | s%@sim_debug@%$sim_debug%g | |
4071 | s%@sim_stdio@%$sim_stdio%g | |
4072 | s%@sim_trace@%$sim_trace%g | |
4073 | s%@sim_profile@%$sim_profile%g | |
4074 | s%@EXEEXT@%$EXEEXT%g | |
4075 | s%@m68hc11_extra_objs@%$m68hc11_extra_objs%g | |
4076 | ||
4077 | CEOF | |
4078 | EOF | |
4079 | ||
4080 | cat >> $CONFIG_STATUS <<\EOF | |
4081 | ||
4082 | # Split the substitutions into bite-sized pieces for seds with | |
4083 | # small command number limits, like on Digital OSF/1 and HP-UX. | |
4084 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. | |
4085 | ac_file=1 # Number of current file. | |
4086 | ac_beg=1 # First line for current file. | |
4087 | ac_end=$ac_max_sed_cmds # Line after last line for current file. | |
4088 | ac_more_lines=: | |
4089 | ac_sed_cmds="" | |
4090 | while $ac_more_lines; do | |
4091 | if test $ac_beg -gt 1; then | |
4092 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file | |
4093 | else | |
4094 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file | |
4095 | fi | |
4096 | if test ! -s conftest.s$ac_file; then | |
4097 | ac_more_lines=false | |
4098 | rm -f conftest.s$ac_file | |
4099 | else | |
4100 | if test -z "$ac_sed_cmds"; then | |
4101 | ac_sed_cmds="sed -f conftest.s$ac_file" | |
4102 | else | |
4103 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" | |
4104 | fi | |
4105 | ac_file=`expr $ac_file + 1` | |
4106 | ac_beg=$ac_end | |
4107 | ac_end=`expr $ac_end + $ac_max_sed_cmds` | |
4108 | fi | |
4109 | done | |
4110 | if test -z "$ac_sed_cmds"; then | |
4111 | ac_sed_cmds=cat | |
4112 | fi | |
4113 | EOF | |
4114 | ||
4115 | cat >> $CONFIG_STATUS <<EOF | |
4116 | ||
4117 | CONFIG_FILES=\${CONFIG_FILES-"Makefile.sim:Makefile.in Make-common.sim:../common/Make-common.in .gdbinit:../common/gdbinit.in"} | |
4118 | EOF | |
4119 | cat >> $CONFIG_STATUS <<\EOF | |
4120 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then | |
4121 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". | |
4122 | case "$ac_file" in | |
4123 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` | |
4124 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
4125 | *) ac_file_in="${ac_file}.in" ;; | |
4126 | esac | |
4127 | ||
4128 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. | |
4129 | ||
4130 | # Remove last slash and all that follows it. Not all systems have dirname. | |
4131 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
4132 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
4133 | # The file is in a subdirectory. | |
4134 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
4135 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" | |
4136 | # A "../" for each directory in $ac_dir_suffix. | |
4137 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` | |
4138 | else | |
4139 | ac_dir_suffix= ac_dots= | |
4140 | fi | |
4141 | ||
4142 | case "$ac_given_srcdir" in | |
4143 | .) srcdir=. | |
4144 | if test -z "$ac_dots"; then top_srcdir=. | |
4145 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; | |
4146 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; | |
4147 | *) # Relative path. | |
4148 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" | |
4149 | top_srcdir="$ac_dots$ac_given_srcdir" ;; | |
4150 | esac | |
4151 | ||
4152 | case "$ac_given_INSTALL" in | |
4153 | [/$]*) INSTALL="$ac_given_INSTALL" ;; | |
4154 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; | |
4155 | esac | |
4156 | ||
4157 | echo creating "$ac_file" | |
4158 | rm -f "$ac_file" | |
4159 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." | |
4160 | case "$ac_file" in | |
4161 | *Makefile*) ac_comsub="1i\\ | |
4162 | # $configure_input" ;; | |
4163 | *) ac_comsub= ;; | |
4164 | esac | |
4165 | ||
4166 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` | |
4167 | sed -e "$ac_comsub | |
4168 | s%@configure_input@%$configure_input%g | |
4169 | s%@srcdir@%$srcdir%g | |
4170 | s%@top_srcdir@%$top_srcdir%g | |
4171 | s%@INSTALL@%$INSTALL%g | |
4172 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file | |
4173 | fi; done | |
4174 | rm -f conftest.s* | |
4175 | ||
4176 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where | |
4177 | # NAME is the cpp macro being defined and VALUE is the value it is being given. | |
4178 | # | |
4179 | # ac_d sets the value in "#define NAME VALUE" lines. | |
4180 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' | |
4181 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' | |
4182 | ac_dC='\3' | |
4183 | ac_dD='%g' | |
4184 | # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". | |
4185 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
4186 | ac_uB='\([ ]\)%\1#\2define\3' | |
4187 | ac_uC=' ' | |
4188 | ac_uD='\4%g' | |
4189 | # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". | |
4190 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' | |
4191 | ac_eB='$%\1#\2define\3' | |
4192 | ac_eC=' ' | |
4193 | ac_eD='%g' | |
4194 | ||
4195 | if test "${CONFIG_HEADERS+set}" != set; then | |
4196 | EOF | |
4197 | cat >> $CONFIG_STATUS <<EOF | |
4198 | CONFIG_HEADERS="config.h:config.in" | |
4199 | EOF | |
4200 | cat >> $CONFIG_STATUS <<\EOF | |
4201 | fi | |
4202 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then | |
4203 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". | |
4204 | case "$ac_file" in | |
4205 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` | |
4206 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
4207 | *) ac_file_in="${ac_file}.in" ;; | |
4208 | esac | |
4209 | ||
4210 | echo creating $ac_file | |
4211 | ||
4212 | rm -f conftest.frag conftest.in conftest.out | |
4213 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` | |
4214 | cat $ac_file_inputs > conftest.in | |
4215 | ||
4216 | EOF | |
4217 | ||
4218 | # Transform confdefs.h into a sed script conftest.vals that substitutes | |
4219 | # the proper values into config.h.in to produce config.h. And first: | |
4220 | # Protect against being on the right side of a sed subst in config.status. | |
4221 | # Protect against being in an unquoted here document in config.status. | |
4222 | rm -f conftest.vals | |
4223 | cat > conftest.hdr <<\EOF | |
4224 | s/[\\&%]/\\&/g | |
4225 | s%[\\$`]%\\&%g | |
4226 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp | |
4227 | s%ac_d%ac_u%gp | |
4228 | s%ac_u%ac_e%gp | |
4229 | EOF | |
4230 | sed -n -f conftest.hdr confdefs.h > conftest.vals | |
4231 | rm -f conftest.hdr | |
4232 | ||
4233 | # This sed command replaces #undef with comments. This is necessary, for | |
4234 | # example, in the case of _POSIX_SOURCE, which is predefined and required | |
4235 | # on some systems where configure will not decide to define it. | |
4236 | cat >> conftest.vals <<\EOF | |
4237 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% | |
4238 | EOF | |
4239 | ||
4240 | # Break up conftest.vals because some shells have a limit on | |
4241 | # the size of here documents, and old seds have small limits too. | |
4242 | ||
4243 | rm -f conftest.tail | |
4244 | while : | |
4245 | do | |
4246 | ac_lines=`grep -c . conftest.vals` | |
4247 | # grep -c gives empty output for an empty file on some AIX systems. | |
4248 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi | |
4249 | # Write a limited-size here document to conftest.frag. | |
4250 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS | |
4251 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS | |
4252 | echo 'CEOF | |
4253 | sed -f conftest.frag conftest.in > conftest.out | |
4254 | rm -f conftest.in | |
4255 | mv conftest.out conftest.in | |
4256 | ' >> $CONFIG_STATUS | |
4257 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail | |
4258 | rm -f conftest.vals | |
4259 | mv conftest.tail conftest.vals | |
4260 | done | |
4261 | rm -f conftest.vals | |
4262 | ||
4263 | cat >> $CONFIG_STATUS <<\EOF | |
4264 | rm -f conftest.frag conftest.h | |
4265 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h | |
4266 | cat conftest.in >> conftest.h | |
4267 | rm -f conftest.in | |
4268 | if cmp -s $ac_file conftest.h 2>/dev/null; then | |
4269 | echo "$ac_file is unchanged" | |
4270 | rm -f conftest.h | |
4271 | else | |
4272 | # Remove last slash and all that follows it. Not all systems have dirname. | |
4273 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` | |
4274 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then | |
4275 | # The file is in a subdirectory. | |
4276 | test ! -d "$ac_dir" && mkdir "$ac_dir" | |
4277 | fi | |
4278 | rm -f $ac_file | |
4279 | mv conftest.h $ac_file | |
4280 | fi | |
4281 | fi; done | |
4282 | ||
4283 | EOF | |
4284 | ||
4285 | cat >> $CONFIG_STATUS <<EOF | |
4286 | ac_sources="$sim_link_files" | |
4287 | ac_dests="$sim_link_links" | |
4288 | EOF | |
4289 | ||
4290 | cat >> $CONFIG_STATUS <<\EOF | |
4291 | srcdir=$ac_given_srcdir | |
4292 | while test -n "$ac_sources"; do | |
4293 | set $ac_dests; ac_dest=$1; shift; ac_dests=$* | |
4294 | set $ac_sources; ac_source=$1; shift; ac_sources=$* | |
4295 | ||
4296 | echo "linking $srcdir/$ac_source to $ac_dest" | |
4297 | ||
4298 | if test ! -r $srcdir/$ac_source; then | |
4299 | { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; } | |
4300 | fi | |
4301 | rm -f $ac_dest | |
4302 | ||
4303 | # Make relative symlinks. | |
4304 | # Remove last slash and all that follows it. Not all systems have dirname. | |
4305 | ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'` | |
4306 | if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then | |
4307 | # The dest file is in a subdirectory. | |
4308 | test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir" | |
4309 | ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`" | |
4310 | # A "../" for each directory in $ac_dest_dir_suffix. | |
4311 | ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'` | |
4312 | else | |
4313 | ac_dest_dir_suffix= ac_dots= | |
4314 | fi | |
4315 | ||
4316 | case "$srcdir" in | |
4317 | [/$]*) ac_rel_source="$srcdir/$ac_source" ;; | |
4318 | *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;; | |
4319 | esac | |
4320 | ||
4321 | # Make a symlink if possible; otherwise try a hard link. | |
4322 | if ln -s $ac_rel_source $ac_dest 2>/dev/null || | |
4323 | ln $srcdir/$ac_source $ac_dest; then : | |
4324 | else | |
4325 | { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; } | |
4326 | fi | |
4327 | done | |
4328 | EOF | |
4329 | cat >> $CONFIG_STATUS <<EOF | |
4330 | ||
4331 | EOF | |
4332 | cat >> $CONFIG_STATUS <<\EOF | |
4333 | case "x$CONFIG_FILES" in | |
4334 | xMakefile*) | |
4335 | echo "Merging Makefile.sim+Make-common.sim into Makefile ..." | |
4336 | rm -f Makesim1.tmp Makesim2.tmp Makefile | |
4337 | sed -n -e '/^## COMMON_PRE_/,/^## End COMMON_PRE_/ p' <Make-common.sim >Makesim1.tmp | |
4338 | sed -n -e '/^## COMMON_POST_/,/^## End COMMON_POST_/ p' <Make-common.sim >Makesim2.tmp | |
4339 | sed -e '/^## COMMON_PRE_/ r Makesim1.tmp' \ | |
4340 | -e '/^## COMMON_POST_/ r Makesim2.tmp' \ | |
4341 | <Makefile.sim >Makefile | |
4342 | rm -f Makefile.sim Make-common.sim Makesim1.tmp Makesim2.tmp | |
4343 | ;; | |
4344 | esac | |
4345 | case "x$CONFIG_HEADERS" in xconfig.h:config.in) echo > stamp-h ;; esac | |
4346 | ||
4347 | exit 0 | |
4348 | EOF | |
4349 | chmod +x $CONFIG_STATUS | |
4350 | rm -fr confdefs* $ac_clean_files | |
4351 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 | |
4352 | ||
4353 |