Debian Codegraph @

configure

raw
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20250126.
4 #
5 # Copyright 2003-2022,2023 Thomas E. Dickey
6 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
7 # Free Software Foundation, Inc.
8 # This configure script is free software; the Free Software Foundation
9 # gives unlimited permission to copy, distribute and modify it.
10
11 # Avoid depending upon Character Ranges.
12 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
13 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
14 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
15 as_cr_digits='0123456789'
16 as_cr_alnum=$as_cr_Letters$as_cr_digits
17
18 # Sed expression to map a string onto a valid variable name.
19 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
20
21 # Sed expression to map a string onto a valid CPP name.
22 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
23
24 # Be Bourne compatible
25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
26 emulate sh
27 NULLCMD=:
28 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
29 set -o posix
30 fi
31
32 # Name of the executable.
33 as_me=`echo "$0" |sed 's,.*[\\/],,'`
34
35 if expr a : '\(a\)' >/dev/null 2>&1; then
36 as_expr="expr"
37 else
38 as_expr="false"
39 fi
40
41 rm -f conf$$ conf$$.exe conf$$.file
42 echo >conf$$.file
43 if ln -s conf$$.file conf$$ 2>/dev/null; then
44 # We could just check for DJGPP; but this test a) works b) is more generic
45 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
46 if test -f conf$$.exe; then
47 # Don't use ln at all; we don't have any links
48 as_ln_s='cp -p'
49 else
50 as_ln_s='ln -s'
51 fi
52 elif ln conf$$.file conf$$ 2>/dev/null; then
53 as_ln_s='ln'
54 else
55 as_ln_s='cp -p'
56 fi
57 rm -f conf$$ conf$$.exe conf$$.file
58
59 as_executable_p="test -f"
60
61 # Support unset when possible.
62 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
63 as_unset="unset"
64 else
65 as_unset="false"
66 fi
67
68 # NLS nuisances.
69 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
70 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
71 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
72 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
73 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
74 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
75 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
76 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
77
78 # IFS
79 # We need space, tab and new line, in precisely that order.
80 as_nl='
81 '
82 IFS=" $as_nl"
83
84 # CDPATH.
85 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
86
87 # Name of the host.
88 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
89 # so uname gets run too.
90 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
91
92 exec 6>&1
93
94 #
95 # Initializations.
96 #
97 ac_default_prefix=/usr/local
98 cross_compiling=no
99 subdirs=
100 MFLAGS=
101 MAKEFLAGS=
102 SHELL=${CONFIG_SHELL-/bin/sh}
103
104 # Maximum number of lines to put in a shell here document.
105 # This variable seems obsolete. It should probably be removed, and
106 # only ac_max_sed_lines should be used.
107 : "${ac_max_here_lines=38}"
108
109 ac_unique_file="mawk.h"
110 # Factoring default headers for most tests.
111 ac_includes_default="\
112 #include <stdio.h>
113 #if HAVE_SYS_TYPES_H
114 # include <sys/types.h>
115 #endif
116 #if HAVE_SYS_STAT_H
117 # include <sys/stat.h>
118 #endif
119 #if STDC_HEADERS
120 # include <stdlib.h>
121 # include <stddef.h>
122 #else
123 # if HAVE_STDLIB_H
124 # include <stdlib.h>
125 # endif
126 #endif
127 #if HAVE_STRING_H
128 # if !STDC_HEADERS && HAVE_MEMORY_H
129 # include <memory.h>
130 # endif
131 # include <string.h>
132 #endif
133 #if HAVE_STRINGS_H
134 # include <strings.h>
135 #endif
136 #if HAVE_INTTYPES_H
137 # include <inttypes.h>
138 #else
139 # if HAVE_STDINT_H
140 # include <stdint.h>
141 # endif
142 #endif
143 #if HAVE_UNISTD_H
144 # include <unistd.h>
145 #endif"
146
147 # Initialize some variables set by options.
148 ac_init_help=
149 ac_init_version=false
150 # The variables have the same names as the options, with
151 # dashes changed to underlines.
152 cache_file=/dev/null
153 exec_prefix=NONE
154 no_create=
155 no_recursion=
156 prefix=NONE
157 program_prefix=NONE
158 program_suffix=NONE
159 program_transform_name=s,x,x,
160 silent=
161 site=
162 srcdir=
163 verbose=
164 x_includes=NONE
165 x_libraries=NONE
166
167 # Installation directory options.
168 # These are left unexpanded so users can "make install exec_prefix=/foo"
169 # and all the variables that are supposed to be based on exec_prefix
170 # by default will actually change.
171 # Use braces instead of parens because sh, perl, etc. also accept them.
172 bindir='${exec_prefix}/bin'
173 sbindir='${exec_prefix}/sbin'
174 libexecdir='${exec_prefix}/libexec'
175 datarootdir='${prefix}/share'
176 datadir='${datarootdir}'
177 sysconfdir='${prefix}/etc'
178 sharedstatedir='${prefix}/com'
179 localstatedir='${prefix}/var'
180 runstatedir='${localstatedir}/run'
181 libdir='${exec_prefix}/lib'
182 includedir='${prefix}/include'
183 oldincludedir='/usr/include'
184 infodir='${datarootdir}/info'
185 mandir='${datarootdir}/man'
186
187 # Identity of this package.
188 PACKAGE_NAME=
189 PACKAGE_TARNAME=
190 PACKAGE_VERSION=
191 PACKAGE_STRING=
192 PACKAGE_BUGREPORT=
193
194 ac_prev=
195 for ac_option
196 do
197 # If the previous option needs an argument, assign it.
198 if test -n "$ac_prev"; then
199 eval "$ac_prev=\$ac_option"
200 ac_prev=
201 continue
202 fi
203
204 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
205
206 # Accept the important Cygnus configure options, so we can diagnose typos.
207
208 case "$ac_option" in
209
210 -bindir | --bindir | --bindi | --bind | --bin | --bi)
211 ac_prev=bindir ;;
212 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
213 bindir=$ac_optarg ;;
214
215 -build | --build | --buil | --bui | --bu)
216 ac_prev=build_alias ;;
217 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
218 build_alias=$ac_optarg ;;
219
220 -cache-file | --cache-file | --cache-fil | --cache-fi \
221 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
222 ac_prev=cache_file ;;
223 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
224 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
225 cache_file=$ac_optarg ;;
226
227 --config-cache | -C)
228 cache_file=config.cache ;;
229
230 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
231 ac_prev=datadir ;;
232 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
233 | --da=*)
234 datadir=$ac_optarg ;;
235
236 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
237 | --dataroo | --dataro | --datar)
238 ac_prev=datarootdir ;;
239 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
240 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
241 datarootdir=$ac_optarg ;;
242
243 -disable-* | --disable-*)
244 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
245 # Reject names that are not valid shell variable names.
246 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
247 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
248 { (exit 1); exit 1; }; }
249 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
250 eval "enable_$ac_feature=no" ;;
251
252 -enable-* | --enable-*)
253 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
254 # Reject names that are not valid shell variable names.
255 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
256 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
257 { (exit 1); exit 1; }; }
258 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
259 case "$ac_option" in
260 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
261 *) ac_optarg=yes ;;
262 esac
263 eval "enable_$ac_feature='$ac_optarg'" ;;
264
265 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
266 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
267 | --exec | --exe | --ex)
268 ac_prev=exec_prefix ;;
269 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
270 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
271 | --exec=* | --exe=* | --ex=*)
272 exec_prefix=$ac_optarg ;;
273
274 -gas | --gas | --ga | --g)
275 # Obsolete; use --with-gas.
276 with_gas=yes ;;
277
278 -help | --help | --hel | --he | -h)
279 ac_init_help=long ;;
280 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
281 ac_init_help=recursive ;;
282 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
283 ac_init_help=short ;;
284
285 -host | --host | --hos | --ho)
286 ac_prev=host_alias ;;
287 -host=* | --host=* | --hos=* | --ho=*)
288 host_alias=$ac_optarg ;;
289
290 -includedir | --includedir | --includedi | --included | --include \
291 | --includ | --inclu | --incl | --inc)
292 ac_prev=includedir ;;
293 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
294 | --includ=* | --inclu=* | --incl=* | --inc=*)
295 includedir=$ac_optarg ;;
296
297 -infodir | --infodir | --infodi | --infod | --info | --inf)
298 ac_prev=infodir ;;
299 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
300 infodir=$ac_optarg ;;
301
302 -libdir | --libdir | --libdi | --libd)
303 ac_prev=libdir ;;
304 -libdir=* | --libdir=* | --libdi=* | --libd=*)
305 libdir=$ac_optarg ;;
306
307 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
308 | --libexe | --libex | --libe)
309 ac_prev=libexecdir ;;
310 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
311 | --libexe=* | --libex=* | --libe=*)
312 libexecdir=$ac_optarg ;;
313
314 -localstatedir | --localstatedir | --localstatedi | --localstated \
315 | --localstate | --localstat | --localsta | --localst \
316 | --locals | --local | --loca | --loc | --lo)
317 ac_prev=localstatedir ;;
318 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
319 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
320 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
321 localstatedir=$ac_optarg ;;
322
323 -runstatedir | --runstatedir | --runstatedi | --runstated \
324 | --runstate | --runstat | --runsta | --runst \
325 | --runs | --run | --ru)
326 ac_prev=runstatedir ;;
327 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
328 | --runstate=* | --runstat=* | --runsta=* | --runst=* \
329 | --runs=* | --run=* | --ru=*)
330 runstatedir=$ac_optarg ;;
331
332 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
333 ac_prev=mandir ;;
334 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
335 mandir=$ac_optarg ;;
336
337 -nfp | --nfp | --nf)
338 # Obsolete; use --without-fp.
339 with_fp=no ;;
340
341 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
342 | --no-cr | --no-c)
343 no_create=yes ;;
344
345 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
346 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
347 no_recursion=yes ;;
348
349 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
350 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
351 | --oldin | --oldi | --old | --ol | --o)
352 ac_prev=oldincludedir ;;
353 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
354 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
355 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
356 oldincludedir=$ac_optarg ;;
357
358 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
359 ac_prev=prefix ;;
360 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
361 prefix=$ac_optarg ;;
362
363 -program-prefix | --program-prefix | --program-prefi | --program-pref \
364 | --program-pre | --program-pr | --program-p)
365 ac_prev=program_prefix ;;
366 -program-prefix=* | --program-prefix=* | --program-prefi=* \
367 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
368 program_prefix=$ac_optarg ;;
369
370 -program-suffix | --program-suffix | --program-suffi | --program-suff \
371 | --program-suf | --program-su | --program-s)
372 ac_prev=program_suffix ;;
373 -program-suffix=* | --program-suffix=* | --program-suffi=* \
374 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
375 program_suffix=$ac_optarg ;;
376
377 -program-transform-name | --program-transform-name \
378 | --program-transform-nam | --program-transform-na \
379 | --program-transform-n | --program-transform- \
380 | --program-transform | --program-transfor \
381 | --program-transfo | --program-transf \
382 | --program-trans | --program-tran \
383 | --progr-tra | --program-tr | --program-t)
384 ac_prev=program_transform_name ;;
385 -program-transform-name=* | --program-transform-name=* \
386 | --program-transform-nam=* | --program-transform-na=* \
387 | --program-transform-n=* | --program-transform-=* \
388 | --program-transform=* | --program-transfor=* \
389 | --program-transfo=* | --program-transf=* \
390 | --program-trans=* | --program-tran=* \
391 | --progr-tra=* | --program-tr=* | --program-t=*)
392 program_transform_name=$ac_optarg ;;
393
394 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
395 | -silent | --silent | --silen | --sile | --sil)
396 silent=yes ;;
397
398 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
399 ac_prev=sbindir ;;
400 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
401 | --sbi=* | --sb=*)
402 sbindir=$ac_optarg ;;
403
404 -sharedstatedir | --sharedstatedir | --sharedstatedi \
405 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
406 | --sharedst | --shareds | --shared | --share | --shar \
407 | --sha | --sh)
408 ac_prev=sharedstatedir ;;
409 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
410 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
411 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
412 | --sha=* | --sh=*)
413 sharedstatedir=$ac_optarg ;;
414
415 -site | --site | --sit)
416 ac_prev=site ;;
417 -site=* | --site=* | --sit=*)
418 site=$ac_optarg ;;
419
420 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
421 ac_prev=srcdir ;;
422 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
423 srcdir=$ac_optarg ;;
424
425 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
426 | --syscon | --sysco | --sysc | --sys | --sy)
427 ac_prev=sysconfdir ;;
428 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
429 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
430 sysconfdir=$ac_optarg ;;
431
432 -target | --target | --targe | --targ | --tar | --ta | --t)
433 ac_prev=target_alias ;;
434 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
435 target_alias=$ac_optarg ;;
436
437 -v | -verbose | --verbose | --verbos | --verbo | --verb)
438 verbose=yes ;;
439
440 -version | --version | --versio | --versi | --vers | -V)
441 ac_init_version=: ;;
442
443 -with-* | --with-*)
444 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
445 # Reject names that are not valid shell variable names.
446 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
447 { echo "$as_me: error: invalid package name: $ac_package" >&2
448 { (exit 1); exit 1; }; }
449 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
450 case "$ac_option" in
451 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
452 *) ac_optarg=yes ;;
453 esac
454 eval "with_$ac_package='$ac_optarg'" ;;
455
456 -without-* | --without-*)
457 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
458 # Reject names that are not valid shell variable names.
459 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
460 { echo "$as_me: error: invalid package name: $ac_package" >&2
461 { (exit 1); exit 1; }; }
462 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
463 eval "with_$ac_package=no" ;;
464
465 --x)
466 # Obsolete; use --with-x.
467 with_x=yes ;;
468
469 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
470 | --x-incl | --x-inc | --x-in | --x-i)
471 ac_prev=x_includes ;;
472 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
473 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
474 x_includes=$ac_optarg ;;
475
476 -x-libraries | --x-libraries | --x-librarie | --x-librari \
477 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
478 ac_prev=x_libraries ;;
479 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
480 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
481 x_libraries=$ac_optarg ;;
482
483 -*dir | -dvi* | -doc* | -html* | -local* | -pdf* | -ps* )
484 echo "$as_me: WARNING: unsupported option: $ac_option" >&2
485 ;;
486
487 -*) { echo "$as_me: error: unrecognized option: $ac_option
488 Try \`$0 --help' for more information." >&2
489 { (exit 1); exit 1; }; }
490 ;;
491
492 *=*)
493 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
494 # Reject names that are not valid shell variable names.
495 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
496 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
497 { (exit 1); exit 1; }; }
498 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
499 eval "$ac_envvar='$ac_optarg'"
500 export "$ac_envvar" ;;
501
502 *)
503 # FIXME: should be removed in autoconf 3.0.
504 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
505 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
506 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
507 : "${build_alias=$ac_option}" "${host_alias=$ac_option}" "${target_alias=$ac_option}"
508 ;;
509
510 esac
511 done
512
513 if test -n "$ac_prev"; then
514 ac_option=--`echo "$ac_prev" | sed 's/_/-/g'`
515 { echo "$as_me: error: missing argument to $ac_option" >&2
516 { (exit 1); exit 1; }; }
517 fi
518
519 # Be sure to have absolute paths.
520 for ac_var in exec_prefix prefix
521 do
522 eval ac_val=$`echo "$ac_var"`
523 case "$ac_val" in
524 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
525 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
526 { (exit 1); exit 1; }; };;
527 esac
528 done
529
530 # Be sure to have absolute paths.
531 for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
532 localstatedir libdir includedir oldincludedir infodir mandir
533 do
534 eval ac_val=$`echo "$ac_var"`
535 case "$ac_val" in
536 [\\/$]* | ?:[\\/]* ) ;;
537 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
538 { (exit 1); exit 1; }; };;
539 esac
540 done
541
542 # There might be people who depend on the old broken behavior: `$host'
543 # used to hold the argument of --host etc.
544 build=$build_alias
545 host=$host_alias
546 target=$target_alias
547
548 # FIXME: should be removed in autoconf 3.0.
549 if test "x$host_alias" != x; then
550 if test "x$build_alias" = x; then
551 cross_compiling=maybe
552 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
553 If a cross compiler is detected then cross compile mode will be used." >&2
554 elif test "x$build_alias" != "x$host_alias"; then
555 cross_compiling=yes
556 fi
557 fi
558
559 ac_tool_prefix=
560 test -n "$host_alias" && ac_tool_prefix=$host_alias-
561
562 test "$silent" = yes && exec 6>/dev/null
563
564 # Find the source files, if location was not specified.
565 if test -z "$srcdir"; then
566 ac_srcdir_defaulted=yes
567 # Try the directory containing this script, then its parent.
568 ac_prog=$0
569 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
570 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
571 srcdir=$ac_confdir
572 if test ! -r "$srcdir/$ac_unique_file"; then
573 srcdir=..
574 fi
575 else
576 ac_srcdir_defaulted=no
577 fi
578 if test ! -r "$srcdir/$ac_unique_file"; then
579 if test "$ac_srcdir_defaulted" = yes; then
580 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
581 { (exit 1); exit 1; }; }
582 else
583 { echo "$as_me: error: cannot find sources in $srcdir" >&2
584 { (exit 1); exit 1; }; }
585 fi
586 fi
587 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
588 ac_env_build_alias_set=${build_alias+set}
589 ac_env_build_alias_value=$build_alias
590 ac_cv_env_build_alias_set=${build_alias+set}
591 ac_cv_env_build_alias_value=$build_alias
592 ac_env_host_alias_set=${host_alias+set}
593 ac_env_host_alias_value=$host_alias
594 ac_cv_env_host_alias_set=${host_alias+set}
595 ac_cv_env_host_alias_value=$host_alias
596 ac_env_target_alias_set=${target_alias+set}
597 ac_env_target_alias_value=$target_alias
598 ac_cv_env_target_alias_set=${target_alias+set}
599 ac_cv_env_target_alias_value=$target_alias
600 ac_env_CC_set=${CC+set}
601 ac_env_CC_value=$CC
602 ac_cv_env_CC_set=${CC+set}
603 ac_cv_env_CC_value=$CC
604 ac_env_CFLAGS_set=${CFLAGS+set}
605 ac_env_CFLAGS_value=$CFLAGS
606 ac_cv_env_CFLAGS_set=${CFLAGS+set}
607 ac_cv_env_CFLAGS_value=$CFLAGS
608 ac_env_LDFLAGS_set=${LDFLAGS+set}
609 ac_env_LDFLAGS_value=$LDFLAGS
610 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
611 ac_cv_env_LDFLAGS_value=$LDFLAGS
612 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
613 ac_env_CPPFLAGS_value=$CPPFLAGS
614 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
615 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
616 ac_env_CPP_set=${CPP+set}
617 ac_env_CPP_value=$CPP
618 ac_cv_env_CPP_set=${CPP+set}
619 ac_cv_env_CPP_value=$CPP
620
621 #
622 # Report the --help message.
623 #
624 if test "$ac_init_help" = "long"; then
625 # Omit some internal or obsolete options to make the list less imposing.
626 # This message is too long to be a string in the A/UX 3.1 sh.
627 cat <<EOF
628 \`configure' configures this package to adapt to many kinds of systems.
629
630 Usage: $0 [OPTION]... [VAR=VALUE]...
631
632 To assign environment variables (e.g., CC, CFLAGS...), specify them as
633 VAR=VALUE. See below for descriptions of some of the useful variables.
634
635 Defaults for the options are specified in brackets.
636
637 Configuration:
638 -h, --help display this help and exit
639 --help=short display options specific to this package
640 --help=recursive display the short help of all the included packages
641 -V, --version display version information and exit
642 -q, --quiet, --silent do not print \`checking...' messages
643 --cache-file=FILE cache test results in FILE [disabled]
644 -C, --config-cache alias for \`--cache-file=config.cache'
645 -n, --no-create do not create output files
646 --srcdir=DIR find the sources in DIR [configure dir or \`..']
647
648 EOF
649
650 cat <<EOF
651 Installation directories:
652 --prefix=PREFIX install architecture-independent files in PREFIX
653 [$ac_default_prefix]
654 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
655 [PREFIX]
656
657 By default, \`make install' will install all the files in
658 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
659 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
660 for instance \`--prefix=\$HOME'.
661
662 For better control, use the options below.
663
664 Fine tuning of the installation directories:
665 --bindir=DIR user executables [EPREFIX/bin]
666 --sbindir=DIR system admin executables [EPREFIX/sbin]
667 --libexecdir=DIR program executables [EPREFIX/libexec]
668 --datarootdir=DIR read-only architecture-independent data [PREFIX/share]
669 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
670 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
671 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
672 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
673 --runstatedir=DIR extra definition of runtime data [LOCALSTATEDIR/run]
674 --libdir=DIR object code libraries [EPREFIX/lib]
675 --includedir=DIR C header files [PREFIX/include]
676 --oldincludedir=DIR C header files for non-gcc [/usr/include]
677 --infodir=DIR info documentation [DATAROOTDIR/info]
678 --mandir=DIR man documentation [DATAROOTDIR/man]
679 EOF
680
681 cat <<\EOF
682
683 Program names:
684 --program-prefix=PREFIX prepend PREFIX to installed program names
685 --program-suffix=SUFFIX append SUFFIX to installed program names
686 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
687
688 System types:
689 --build=BUILD configure for building on BUILD [guessed]
690 --host=HOST build programs to run on HOST [BUILD]
691 --target=TARGET configure for building compilers for TARGET [HOST]
692 EOF
693 fi
694
695 if test -n "$ac_init_help"; then
696
697 cat <<\EOF
698
699 Optional Features:
700 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
701 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
702
703 Optional Packages:
704 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
705 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
706
707 --disable-largefile omit support for large files
708 Cross-compiling
709 --with-build-cc=XXX the build C compiler ($BUILD_CC)
710 --with-build-cpp=XXX the build C preprocessor ($BUILD_CPP)
711 --with-build-cflags=XXX the build C compiler-flags ($BUILD_CFLAGS)
712 --with-build-cppflags=XXX the build C preprocessor-flags ($BUILD_CPPFLAGS)
713 --with-build-ldflags=XXX the build linker-flags ($BUILD_LDFLAGS)
714 --with-build-libs=XXX the build libraries (${BUILD_LIBS})
715 Miscellaneous options
716 --disable-echo do not display "compiling" commands
717 --enable-warnings test: turn on gcc compiler warnings
718 --enable-stdnoreturn enable C11 _Noreturn feature for diagnostics
719 --with-man2html[=XXX] use XXX rather than groff
720 --with-system-type=XXX test: override derived host system-type
721 --without-builtin-regex do not use mawk's own regular-expressions engine
722 --enable-builtin-srand use mawk's own srand/rand functions
723 --enable-arc4random enable arc4random if available
724 --disable-init-srand suppress automatic initialization of random numbers
725 --disable-interval-expr suppress regex interval expressions {m,n}
726 Testing-options
727 --with-dmalloc test: use Gray Watson's dmalloc library
728 --with-dbmalloc test: use Conor Cahill's dbmalloc library
729 --with-valgrind test: use valgrind
730 --disable-leaks test: free permanent memory, analyze leaks
731 --enable-trace test: turn on debug-tracing
732
733 Some influential environment variables:
734 CC C compiler command
735 CFLAGS C compiler flags
736 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
737 nonstandard directory <lib dir>
738 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
739 headers in a nonstandard directory <include dir>
740 CPP C preprocessor
741
742 Use these variables to override the choices made by `configure' or to help
743 it to find libraries and programs with nonstandard names/locations.
744
745 EOF
746 fi
747
748 if test "$ac_init_help" = "recursive"; then
749 # If there are subdirs, report their specific --help.
750 ac_popdir=`pwd`
751 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
752 cd "$ac_subdir"
753 # A "../" for each directory in /$ac_subdir.
754 ac_dots=`echo "$ac_subdir" |
755 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
756
757 case "$srcdir" in
758 .) # No --srcdir option. We are building in place.
759 ac_sub_srcdir="$srcdir" ;;
760 [\\/]* | ?:[\\/]* ) # Absolute path.
761 ac_sub_srcdir="$srcdir/$ac_subdir" ;;
762 *) # Relative path.
763 ac_sub_srcdir="$ac_dots$srcdir/$ac_subdir" ;;
764 esac
765
766 # Check for guested configure; otherwise get Cygnus style configure.
767 if test -f "$ac_sub_srcdir/configure.gnu"; then
768 echo
769 $SHELL "$ac_sub_srcdir/configure.gnu" --help=recursive
770 elif test -f "$ac_sub_srcdir/configure"; then
771 echo
772 $SHELL "$ac_sub_srcdir/configure" --help=recursive
773 elif test -f "$ac_sub_srcdir/configure.ac" ||
774 test -f "$ac_sub_srcdir/configure.in"; then
775 echo
776 "$ac_configure" --help
777 else
778 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
779 fi
780 cd "$ac_popdir"
781 done
782 fi
783
784 test -n "$ac_init_help" && exit 0
785 if "$ac_init_version"; then
786 cat <<\EOF
787
788 Copyright 2003-2022,2023 Thomas E. Dickey
789 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
790 Free Software Foundation, Inc.
791 This configure script is free software; the Free Software Foundation
792 gives unlimited permission to copy, distribute and modify it.
793 EOF
794 exit 0
795 fi
796 exec 5>config.log
797 cat >&5 <<EOF
798 This file contains any messages produced by compilers while
799 running configure, to aid debugging if configure makes a mistake.
800
801 It was created by $as_me, which was
802 generated by GNU Autoconf 2.52.20250126. Invocation command line was
803
804 $ $0 $@
805
806 EOF
807 {
808 cat <<_ASUNAME
809 ## ---------- ##
810 ## Platform. ##
811 ## ---------- ##
812
813 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
814 uname -m = `(uname -m) 2>/dev/null || echo unknown`
815 uname -r = `(uname -r) 2>/dev/null || echo unknown`
816 uname -s = `(uname -s) 2>/dev/null || echo unknown`
817 uname -v = `(uname -v) 2>/dev/null || echo unknown`
818
819 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
820 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
821
822 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
823 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
824 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
825 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
826 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
827 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
828 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
829
830 PATH = $PATH
831
832 _ASUNAME
833 } >&5
834
835 cat >&5 <<EOF
836 ## ------------ ##
837 ## Core tests. ##
838 ## ------------ ##
839
840 EOF
841
842 # Keep a trace of the command line.
843 # Strip out --no-create and --no-recursion so they do not pile up.
844 # Also quote any args containing shell meta-characters.
845 ac_configure_args=
846 ac_sep=
847 for ac_arg
848 do
849 case "$ac_arg" in
850 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
851 | --no-cr | --no-c) ;;
852 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
853 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
854 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
855 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
856 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
857 ac_sep=" " ;;
858 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
859 ac_sep=" " ;;
860 esac
861 # Get rid of the leading space.
862 done
863
864 # When interrupted or exit'd, cleanup temporary files, and complete
865 # config.log. We remove comments because anyway the quotes in there
866 # would cause problems or look ugly.
867 trap 'exit_status=$?
868 # Save into config.log some information that might help in debugging.
869 echo >&5
870 echo "## ----------------- ##" >&5
871 echo "## Cache variables. ##" >&5
872 echo "## ----------------- ##" >&5
873 echo >&5
874 # The following way of writing the cache mishandles newlines in values,
875 {
876 (set) 2>&1 |
877 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
878 *ac_space=\ *)
879 sed -n \
880 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
881 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
882 ;;
883 *)
884 sed -n \
885 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
886 ;;
887 esac;
888 } >&5
889 sed "/^$/d" confdefs.h >conftest.log
890 if test -s conftest.log; then
891 echo >&5
892 echo "## ------------ ##" >&5
893 echo "## confdefs.h. ##" >&5
894 echo "## ------------ ##" >&5
895 echo >&5
896 cat conftest.log >&5
897 fi
898 (echo; echo) >&5
899 test "$ac_signal" != 0 &&
900 echo "$as_me: caught signal $ac_signal" >&5
901 echo "$as_me: exit $exit_status" >&5
902 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
903 exit $exit_status
904 ' 0
905 for ac_signal in 1 2 13 15; do
906 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' "$ac_signal"
907 done
908 ac_signal=0
909
910 # confdefs.h avoids OS command line length limits that DEFS can exceed.
911 rm -rf conftest* confdefs.h
912 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
913 echo >confdefs.h
914
915 # Let the site file select an alternate cache file if it wants to.
916 # Prefer explicitly selected file to automatically selected ones.
917 if test -z "$CONFIG_SITE"; then
918 if test "x$prefix" != xNONE; then
919 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
920 else
921 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
922 fi
923 fi
924 for ac_site_file in $CONFIG_SITE; do
925 if test -r "$ac_site_file"; then
926 { echo "$as_me:926: loading site script $ac_site_file" >&5
927 echo "$as_me: loading site script $ac_site_file" >&6;}
928 cat "$ac_site_file" >&5
929 . "$ac_site_file"
930 fi
931 done
932
933 if test -r "$cache_file"; then
934 # Some versions of bash will fail to source /dev/null (special
935 # files actually), so we avoid doing that.
936 if test -f "$cache_file"; then
937 { echo "$as_me:937: loading cache $cache_file" >&5
938 echo "$as_me: loading cache $cache_file" >&6;}
939 case $cache_file in
940 [\\/]* | ?:[\\/]* ) . $cache_file;;
941 *) . ./$cache_file;;
942 esac
943 fi
944 else
945 { echo "$as_me:945: creating cache $cache_file" >&5
946 echo "$as_me: creating cache $cache_file" >&6;}
947 >$cache_file
948 fi
949
950 # Check that the precious variables saved in the cache have kept the same
951 # value.
952 ac_cache_corrupted=false
953 for ac_var in `(set) 2>&1 |
954 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
955 eval ac_old_set=\$ac_cv_env_${ac_var}_set
956 eval ac_new_set=\$ac_env_${ac_var}_set
957 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
958 eval ac_new_val="\$ac_env_${ac_var}_value"
959 case "$ac_old_set,$ac_new_set" in
960 set,)
961 { echo "$as_me:961: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
962 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
963 ac_cache_corrupted=: ;;
964 ,set)
965 { echo "$as_me:965: error: \`$ac_var' was not set in the previous run" >&5
966 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
967 ac_cache_corrupted=: ;;
968 ,);;
969 *)
970 if test "x$ac_old_val" != "x$ac_new_val"; then
971 { echo "$as_me:971: error: \`$ac_var' has changed since the previous run:" >&5
972 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
973 { echo "$as_me:973: former value: $ac_old_val" >&5
974 echo "$as_me: former value: $ac_old_val" >&2;}
975 { echo "$as_me:975: current value: $ac_new_val" >&5
976 echo "$as_me: current value: $ac_new_val" >&2;}
977 ac_cache_corrupted=:
978 fi;;
979 esac
980 # Pass precious variables to config.status. It doesn't matter if
981 # we pass some twice (in addition to the command line arguments).
982 if test "$ac_new_set" = set; then
983 case "$ac_new_val" in
984 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
985 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
986 ac_configure_args="$ac_configure_args '$ac_arg'"
987 ;;
988 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
989 ;;
990 esac
991 fi
992 done
993 if "$ac_cache_corrupted"; then
994 { echo "$as_me:994: error: changes in the environment can compromise the build" >&5
995 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
996 { { echo "$as_me:996: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
997 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
998 { (exit 1); exit 1; }; }
999 fi
1000
1001 ac_ext=c
1002 ac_cpp='$CPP $CPPFLAGS'
1003 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1004 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1005 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1006 ac_main_return="return"
1007
1008 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
1009 *c*,-n*) ECHO_N=
1010 ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
1011 ECHO_T=' '
1012 ;;
1013 *c*,* ) ECHO_N=-n
1014 ECHO_C=
1015 ECHO_T=
1016 ;;
1017 *) ECHO_N=
1018 ECHO_C='\c'
1019 ECHO_T=
1020 ;;
1021 esac
1022 echo "#! $SHELL" >conftest.sh
1023 echo "exit 0" >>conftest.sh
1024 chmod +x conftest.sh
1025 if { (echo "$as_me:1025: PATH=\".;.\"; conftest.sh") >&5
1026 (PATH=".;."; conftest.sh) 2>&5
1027 ac_status=$?
1028 echo "$as_me:1028: \$? = $ac_status" >&5
1029 (exit "$ac_status"); }; then
1030 ac_path_separator=';'
1031 else
1032 ac_path_separator=:
1033 fi
1034 PATH_SEPARATOR="$ac_path_separator"
1035 rm -f conftest.sh
1036
1037 ac_config_headers="$ac_config_headers config.h:config_h.in"
1038
1039 ac_aux_dir=
1040 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1041 if test -f "$ac_dir/install-sh"; then
1042 ac_aux_dir=$ac_dir
1043 ac_install_sh="$ac_aux_dir/install-sh -c"
1044 break
1045 elif test -f "$ac_dir/install.sh"; then
1046 ac_aux_dir=$ac_dir
1047 ac_install_sh="$ac_aux_dir/install.sh -c"
1048 break
1049 elif test -f "$ac_dir/shtool"; then
1050 ac_aux_dir=$ac_dir
1051 ac_install_sh="$ac_aux_dir/shtool install -c"
1052 break
1053 fi
1054 done
1055 if test -z "$ac_aux_dir"; then
1056 { { echo "$as_me:1056: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1057 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1058 { (exit 1); exit 1; }; }
1059 fi
1060 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1061 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1062 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1063
1064 # Make sure we can run config.sub.
1065 $ac_config_sub sun4 >/dev/null 2>&1 ||
1066 { { echo "$as_me:1066: error: cannot run $ac_config_sub" >&5
1067 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1068 { (exit 1); exit 1; }; }
1069
1070 echo "$as_me:1070: checking build system type" >&5
1071 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1072 if test "${ac_cv_build+set}" = set; then
1073 echo $ECHO_N "(cached) $ECHO_C" >&6
1074 else
1075 ac_cv_build_alias=$build_alias
1076 test -z "$ac_cv_build_alias" &&
1077 ac_cv_build_alias=`$ac_config_guess`
1078 test -z "$ac_cv_build_alias" &&
1079 { { echo "$as_me:1079: error: cannot guess build type; you must specify one" >&5
1080 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1081 { (exit 1); exit 1; }; }
1082 ac_cv_build=`$ac_config_sub "$ac_cv_build_alias"` ||
1083 { { echo "$as_me:1083: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1084 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1085 { (exit 1); exit 1; }; }
1086
1087 fi
1088 echo "$as_me:1088: result: $ac_cv_build" >&5
1089 echo "${ECHO_T}$ac_cv_build" >&6
1090 build=$ac_cv_build
1091 build_cpu=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1092 build_vendor=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1093 build_os=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1094
1095 if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
1096 echo "$as_me:1096: checking host system type" >&5
1097 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1098 if test "${ac_cv_host+set}" = set; then
1099 echo $ECHO_N "(cached) $ECHO_C" >&6
1100 else
1101 ac_cv_host_alias=$host_alias
1102 test -z "$ac_cv_host_alias" &&
1103 ac_cv_host_alias=$ac_cv_build_alias
1104 ac_cv_host=`$ac_config_sub "$ac_cv_host_alias"` ||
1105 { { echo "$as_me:1105: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1106 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1107 { (exit 1); exit 1; }; }
1108
1109 fi
1110 echo "$as_me:1110: result: $ac_cv_host" >&5
1111 echo "${ECHO_T}$ac_cv_host" >&6
1112 host=$ac_cv_host
1113 host_cpu=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1114 host_vendor=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1115 host_os=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1116
1117 system_name="$host_os"
1118 else
1119 system_name="`(uname -s -r) 2>/dev/null`"
1120 if test -z "$system_name" ; then
1121 system_name="`(hostname) 2>/dev/null`"
1122 fi
1123 fi
1124 test -n "$system_name" &&
1125 cat >>confdefs.h <<EOF
1126 #define SYSTEM_NAME "$system_name"
1127 EOF
1128
1129 if test "${cf_cv_system_name+set}" = set; then
1130 echo $ECHO_N "(cached) $ECHO_C" >&6
1131 else
1132 cf_cv_system_name="$system_name"
1133 fi
1134
1135 test -z "$system_name" && system_name="$cf_cv_system_name"
1136 test -n "$cf_cv_system_name" && echo "$as_me:1136: result: Configuring for $cf_cv_system_name" >&5
1137 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1138
1139 if test ".$system_name" != ".$cf_cv_system_name" ; then
1140 echo "$as_me:1140: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1141 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1142 { { echo "$as_me:1142: error: \"Please remove config.cache and try again.\"" >&5
1143 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1144 { (exit 1); exit 1; }; }
1145 fi
1146
1147 test "$program_prefix" != NONE &&
1148 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1149 # Use a double $ so make ignores it.
1150 test "$program_suffix" != NONE &&
1151 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1152 # Double any \ or $. echo might interpret backslashes.
1153 # By default was `s,x,x', remove it if useless.
1154 cat <<\_ACEOF >conftest.sed
1155 s/[\\$]/&&/g;s/;s,x,x,$//
1156 _ACEOF
1157 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1158 rm conftest.sed
1159
1160 ac_ext=c
1161 ac_cpp='$CPP $CPPFLAGS'
1162 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1163 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1164 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1165 ac_main_return="return"
1166 if test -n "$ac_tool_prefix"; then
1167 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1168 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1169 echo "$as_me:1169: checking for $ac_word" >&5
1170 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1171 if test "${ac_cv_prog_CC+set}" = set; then
1172 echo $ECHO_N "(cached) $ECHO_C" >&6
1173 else
1174 if test -n "$CC"; then
1175 ac_cv_prog_CC="$CC" # Let the user override the test.
1176 else
1177 ac_save_IFS=$IFS; IFS=$ac_path_separator
1178 ac_dummy="$PATH"
1179 for ac_dir in $ac_dummy; do
1180 IFS=$ac_save_IFS
1181 test -z "$ac_dir" && ac_dir=.
1182 $as_executable_p "$ac_dir/$ac_word" || continue
1183 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1184 echo "$as_me:1184: found $ac_dir/$ac_word" >&5
1185 break
1186 done
1187
1188 fi
1189 fi
1190 CC=$ac_cv_prog_CC
1191 if test -n "$CC"; then
1192 echo "$as_me:1192: result: $CC" >&5
1193 echo "${ECHO_T}$CC" >&6
1194 else
1195 echo "$as_me:1195: result: no" >&5
1196 echo "${ECHO_T}no" >&6
1197 fi
1198
1199 fi
1200 if test -z "$ac_cv_prog_CC"; then
1201 ac_ct_CC=$CC
1202 # Extract the first word of "gcc", so it can be a program name with args.
1203 set dummy gcc; ac_word=$2
1204 echo "$as_me:1204: checking for $ac_word" >&5
1205 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1206 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1207 echo $ECHO_N "(cached) $ECHO_C" >&6
1208 else
1209 if test -n "$ac_ct_CC"; then
1210 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1211 else
1212 ac_save_IFS=$IFS; IFS=$ac_path_separator
1213 ac_dummy="$PATH"
1214 for ac_dir in $ac_dummy; do
1215 IFS=$ac_save_IFS
1216 test -z "$ac_dir" && ac_dir=.
1217 $as_executable_p "$ac_dir/$ac_word" || continue
1218 ac_cv_prog_ac_ct_CC="gcc"
1219 echo "$as_me:1219: found $ac_dir/$ac_word" >&5
1220 break
1221 done
1222
1223 fi
1224 fi
1225 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1226 if test -n "$ac_ct_CC"; then
1227 echo "$as_me:1227: result: $ac_ct_CC" >&5
1228 echo "${ECHO_T}$ac_ct_CC" >&6
1229 else
1230 echo "$as_me:1230: result: no" >&5
1231 echo "${ECHO_T}no" >&6
1232 fi
1233
1234 CC=$ac_ct_CC
1235 else
1236 CC="$ac_cv_prog_CC"
1237 fi
1238
1239 if test -z "$CC"; then
1240 if test -n "$ac_tool_prefix"; then
1241 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1242 set dummy ${ac_tool_prefix}cc; ac_word=$2
1243 echo "$as_me:1243: checking for $ac_word" >&5
1244 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1245 if test "${ac_cv_prog_CC+set}" = set; then
1246 echo $ECHO_N "(cached) $ECHO_C" >&6
1247 else
1248 if test -n "$CC"; then
1249 ac_cv_prog_CC="$CC" # Let the user override the test.
1250 else
1251 ac_save_IFS=$IFS; IFS=$ac_path_separator
1252 ac_dummy="$PATH"
1253 for ac_dir in $ac_dummy; do
1254 IFS=$ac_save_IFS
1255 test -z "$ac_dir" && ac_dir=.
1256 $as_executable_p "$ac_dir/$ac_word" || continue
1257 ac_cv_prog_CC="${ac_tool_prefix}cc"
1258 echo "$as_me:1258: found $ac_dir/$ac_word" >&5
1259 break
1260 done
1261
1262 fi
1263 fi
1264 CC=$ac_cv_prog_CC
1265 if test -n "$CC"; then
1266 echo "$as_me:1266: result: $CC" >&5
1267 echo "${ECHO_T}$CC" >&6
1268 else
1269 echo "$as_me:1269: result: no" >&5
1270 echo "${ECHO_T}no" >&6
1271 fi
1272
1273 fi
1274 if test -z "$ac_cv_prog_CC"; then
1275 ac_ct_CC=$CC
1276 # Extract the first word of "cc", so it can be a program name with args.
1277 set dummy cc; ac_word=$2
1278 echo "$as_me:1278: checking for $ac_word" >&5
1279 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1280 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1281 echo $ECHO_N "(cached) $ECHO_C" >&6
1282 else
1283 if test -n "$ac_ct_CC"; then
1284 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1285 else
1286 ac_save_IFS=$IFS; IFS=$ac_path_separator
1287 ac_dummy="$PATH"
1288 for ac_dir in $ac_dummy; do
1289 IFS=$ac_save_IFS
1290 test -z "$ac_dir" && ac_dir=.
1291 $as_executable_p "$ac_dir/$ac_word" || continue
1292 ac_cv_prog_ac_ct_CC="cc"
1293 echo "$as_me:1293: found $ac_dir/$ac_word" >&5
1294 break
1295 done
1296
1297 fi
1298 fi
1299 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1300 if test -n "$ac_ct_CC"; then
1301 echo "$as_me:1301: result: $ac_ct_CC" >&5
1302 echo "${ECHO_T}$ac_ct_CC" >&6
1303 else
1304 echo "$as_me:1304: result: no" >&5
1305 echo "${ECHO_T}no" >&6
1306 fi
1307
1308 CC=$ac_ct_CC
1309 else
1310 CC="$ac_cv_prog_CC"
1311 fi
1312
1313 fi
1314 if test -z "$CC"; then
1315 # Extract the first word of "cc", so it can be a program name with args.
1316 set dummy cc; ac_word=$2
1317 echo "$as_me:1317: checking for $ac_word" >&5
1318 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1319 if test "${ac_cv_prog_CC+set}" = set; then
1320 echo $ECHO_N "(cached) $ECHO_C" >&6
1321 else
1322 if test -n "$CC"; then
1323 ac_cv_prog_CC="$CC" # Let the user override the test.
1324 else
1325 ac_prog_rejected=no
1326 ac_save_IFS=$IFS; IFS=$ac_path_separator
1327 ac_dummy="$PATH"
1328 for ac_dir in $ac_dummy; do
1329 IFS=$ac_save_IFS
1330 test -z "$ac_dir" && ac_dir=.
1331 $as_executable_p "$ac_dir/$ac_word" || continue
1332 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1333 ac_prog_rejected=yes
1334 continue
1335 fi
1336 ac_cv_prog_CC="cc"
1337 echo "$as_me:1337: found $ac_dir/$ac_word" >&5
1338 break
1339 done
1340
1341 if test "$ac_prog_rejected" = yes; then
1342 # We found a bogon in the path, so make sure we never use it.
1343 set dummy $ac_cv_prog_CC
1344 shift
1345 if test $# != 0; then
1346 # We chose a different compiler from the bogus one.
1347 # However, it has the same basename, so the bogon will be chosen
1348 # first if we set CC to just the basename; use the full file name.
1349 shift
1350 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1351 shift
1352 ac_cv_prog_CC="$@"
1353 fi
1354 fi
1355 fi
1356 fi
1357 CC=$ac_cv_prog_CC
1358 if test -n "$CC"; then
1359 echo "$as_me:1359: result: $CC" >&5
1360 echo "${ECHO_T}$CC" >&6
1361 else
1362 echo "$as_me:1362: result: no" >&5
1363 echo "${ECHO_T}no" >&6
1364 fi
1365
1366 fi
1367 if test -z "$CC"; then
1368 if test -n "$ac_tool_prefix"; then
1369 for ac_prog in cl
1370 do
1371 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1372 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1373 echo "$as_me:1373: checking for $ac_word" >&5
1374 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1375 if test "${ac_cv_prog_CC+set}" = set; then
1376 echo $ECHO_N "(cached) $ECHO_C" >&6
1377 else
1378 if test -n "$CC"; then
1379 ac_cv_prog_CC="$CC" # Let the user override the test.
1380 else
1381 ac_save_IFS=$IFS; IFS=$ac_path_separator
1382 ac_dummy="$PATH"
1383 for ac_dir in $ac_dummy; do
1384 IFS=$ac_save_IFS
1385 test -z "$ac_dir" && ac_dir=.
1386 $as_executable_p "$ac_dir/$ac_word" || continue
1387 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1388 echo "$as_me:1388: found $ac_dir/$ac_word" >&5
1389 break
1390 done
1391
1392 fi
1393 fi
1394 CC=$ac_cv_prog_CC
1395 if test -n "$CC"; then
1396 echo "$as_me:1396: result: $CC" >&5
1397 echo "${ECHO_T}$CC" >&6
1398 else
1399 echo "$as_me:1399: result: no" >&5
1400 echo "${ECHO_T}no" >&6
1401 fi
1402
1403 test -n "$CC" && break
1404 done
1405 fi
1406 if test -z "$CC"; then
1407 ac_ct_CC=$CC
1408 for ac_prog in cl
1409 do
1410 # Extract the first word of "$ac_prog", so it can be a program name with args.
1411 set dummy $ac_prog; ac_word=$2
1412 echo "$as_me:1412: checking for $ac_word" >&5
1413 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1414 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1415 echo $ECHO_N "(cached) $ECHO_C" >&6
1416 else
1417 if test -n "$ac_ct_CC"; then
1418 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1419 else
1420 ac_save_IFS=$IFS; IFS=$ac_path_separator
1421 ac_dummy="$PATH"
1422 for ac_dir in $ac_dummy; do
1423 IFS=$ac_save_IFS
1424 test -z "$ac_dir" && ac_dir=.
1425 $as_executable_p "$ac_dir/$ac_word" || continue
1426 ac_cv_prog_ac_ct_CC="$ac_prog"
1427 echo "$as_me:1427: found $ac_dir/$ac_word" >&5
1428 break
1429 done
1430
1431 fi
1432 fi
1433 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1434 if test -n "$ac_ct_CC"; then
1435 echo "$as_me:1435: result: $ac_ct_CC" >&5
1436 echo "${ECHO_T}$ac_ct_CC" >&6
1437 else
1438 echo "$as_me:1438: result: no" >&5
1439 echo "${ECHO_T}no" >&6
1440 fi
1441
1442 test -n "$ac_ct_CC" && break
1443 done
1444
1445 CC=$ac_ct_CC
1446 fi
1447
1448 fi
1449
1450 test -z "$CC" && { { echo "$as_me:1450: error: no acceptable cc found in \$PATH" >&5
1451 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1452 { (exit 1); exit 1; }; }
1453
1454 # Provide some information about the compiler.
1455 echo "$as_me:1455:" \
1456 "checking for C compiler version" >&5
1457 ac_compiler=`set X $ac_compile; echo "$2"`
1458 { (eval echo "$as_me:1458: \"$ac_compiler --version </dev/null >&5\"") >&5
1459 (eval $ac_compiler --version </dev/null >&5) 2>&5
1460 ac_status=$?
1461 echo "$as_me:1461: \$? = $ac_status" >&5
1462 (exit "$ac_status"); }
1463 { (eval echo "$as_me:1463: \"$ac_compiler -v </dev/null >&5\"") >&5
1464 (eval $ac_compiler -v </dev/null >&5) 2>&5
1465 ac_status=$?
1466 echo "$as_me:1466: \$? = $ac_status" >&5
1467 (exit "$ac_status"); }
1468 { (eval echo "$as_me:1468: \"$ac_compiler -V </dev/null >&5\"") >&5
1469 (eval $ac_compiler -V </dev/null >&5) 2>&5
1470 ac_status=$?
1471 echo "$as_me:1471: \$? = $ac_status" >&5
1472 (exit "$ac_status"); }
1473
1474 cat >"conftest.$ac_ext" <<_ACEOF
1475 #line 1475 "configure"
1476 #include "confdefs.h"
1477
1478 int
1479 main (void)
1480 {
1481
1482 ;
1483 return 0;
1484 }
1485 _ACEOF
1486 ac_clean_files_save=$ac_clean_files
1487 ac_clean_files="$ac_clean_files a.out a.exe"
1488 # Try to create an executable without -o first, disregard a.out.
1489 # It will help us diagnose broken compilers, and finding out an intuition
1490 # of exeext.
1491 echo "$as_me:1491: checking for C compiler default output" >&5
1492 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1493 ac_link_default=`echo "$ac_link" | sed 's/ -o *"conftest[^"]*"//'`
1494 if { (eval echo "$as_me:1494: \"$ac_link_default\"") >&5
1495 (eval $ac_link_default) 2>&5
1496 ac_status=$?
1497 echo "$as_me:1497: \$? = $ac_status" >&5
1498 (exit "$ac_status"); }; then
1499 # Find the output, starting from the most likely. This scheme is
1500 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1501 # resort.
1502 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1503 ls a.out conftest 2>/dev/null;
1504 ls a.* conftest.* 2>/dev/null`; do
1505 case $ac_file in
1506 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1507 a.out ) # We found the default executable, but exeext='' is most
1508 # certainly right.
1509 break;;
1510 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1511 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1512 export ac_cv_exeext
1513 break;;
1514 * ) break;;
1515 esac
1516 done
1517 else
1518 echo "$as_me: failed program was:" >&5
1519 cat "conftest.$ac_ext" >&5
1520 { { echo "$as_me:1520: error: C compiler cannot create executables" >&5
1521 echo "$as_me: error: C compiler cannot create executables" >&2;}
1522 { (exit 77); exit 77; }; }
1523 fi
1524
1525 ac_exeext=$ac_cv_exeext
1526 echo "$as_me:1526: result: $ac_file" >&5
1527 echo "${ECHO_T}$ac_file" >&6
1528
1529 # Check the compiler produces executables we can run. If not, either
1530 # the compiler is broken, or we cross compile.
1531 echo "$as_me:1531: checking whether the C compiler works" >&5
1532 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1533 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1534 # If not cross compiling, check that we can run a simple program.
1535 if test "$cross_compiling" != yes; then
1536 if { ac_try='./$ac_file'
1537 { (eval echo "$as_me:1537: \"$ac_try\"") >&5
1538 (eval $ac_try) 2>&5
1539 ac_status=$?
1540 echo "$as_me:1540: \$? = $ac_status" >&5
1541 (exit "$ac_status"); }; }; then
1542 cross_compiling=no
1543 else
1544 if test "$cross_compiling" = maybe; then
1545 cross_compiling=yes
1546 else
1547 { { echo "$as_me:1547: error: cannot run C compiled programs.
1548 If you meant to cross compile, use \`--host'." >&5
1549 echo "$as_me: error: cannot run C compiled programs.
1550 If you meant to cross compile, use \`--host'." >&2;}
1551 { (exit 1); exit 1; }; }
1552 fi
1553 fi
1554 fi
1555 echo "$as_me:1555: result: yes" >&5
1556 echo "${ECHO_T}yes" >&6
1557
1558 rm -f a.out a.exe "conftest$ac_cv_exeext"
1559 ac_clean_files=$ac_clean_files_save
1560 # Check the compiler produces executables we can run. If not, either
1561 # the compiler is broken, or we cross compile.
1562 echo "$as_me:1562: checking whether we are cross compiling" >&5
1563 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1564 echo "$as_me:1564: result: $cross_compiling" >&5
1565 echo "${ECHO_T}$cross_compiling" >&6
1566
1567 echo "$as_me:1567: checking for executable suffix" >&5
1568 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1569 if { (eval echo "$as_me:1569: \"$ac_link\"") >&5
1570 (eval $ac_link) 2>&5
1571 ac_status=$?
1572 echo "$as_me:1572: \$? = $ac_status" >&5
1573 (exit "$ac_status"); }; then
1574 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1575 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1576 # work properly (i.e., refer to `conftest.exe'), while it won't with
1577 # `rm'.
1578 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1579 case $ac_file in
1580 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1581 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1582 export ac_cv_exeext
1583 break;;
1584 * ) break;;
1585 esac
1586 done
1587 else
1588 { { echo "$as_me:1588: error: cannot compute EXEEXT: cannot compile and link" >&5
1589 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1590 { (exit 1); exit 1; }; }
1591 fi
1592
1593 rm -f "conftest$ac_cv_exeext"
1594 echo "$as_me:1594: result: $ac_cv_exeext" >&5
1595 echo "${ECHO_T}$ac_cv_exeext" >&6
1596
1597 rm -f "conftest.$ac_ext"
1598 EXEEXT=$ac_cv_exeext
1599 ac_exeext=$EXEEXT
1600 echo "$as_me:1600: checking for object suffix" >&5
1601 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1602 if test "${ac_cv_objext+set}" = set; then
1603 echo $ECHO_N "(cached) $ECHO_C" >&6
1604 else
1605 cat >"conftest.$ac_ext" <<_ACEOF
1606 #line 1606 "configure"
1607 #include "confdefs.h"
1608
1609 int
1610 main (void)
1611 {
1612
1613 ;
1614 return 0;
1615 }
1616 _ACEOF
1617 rm -f conftest.o conftest.obj
1618 if { (eval echo "$as_me:1618: \"$ac_compile\"") >&5
1619 (eval $ac_compile) 2>&5
1620 ac_status=$?
1621 echo "$as_me:1621: \$? = $ac_status" >&5
1622 (exit "$ac_status"); }; then
1623 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1624 case $ac_file in
1625 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1626 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1627 break;;
1628 esac
1629 done
1630 else
1631 echo "$as_me: failed program was:" >&5
1632 cat "conftest.$ac_ext" >&5
1633 { { echo "$as_me:1633: error: cannot compute OBJEXT: cannot compile" >&5
1634 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1635 { (exit 1); exit 1; }; }
1636 fi
1637
1638 rm -f "conftest.$ac_cv_objext" "conftest.$ac_ext"
1639 fi
1640 echo "$as_me:1640: result: $ac_cv_objext" >&5
1641 echo "${ECHO_T}$ac_cv_objext" >&6
1642 OBJEXT=$ac_cv_objext
1643 ac_objext=$OBJEXT
1644 echo "$as_me:1644: checking whether we are using the GNU C compiler" >&5
1645 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1646 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1647 echo $ECHO_N "(cached) $ECHO_C" >&6
1648 else
1649 cat >"conftest.$ac_ext" <<_ACEOF
1650 #line 1650 "configure"
1651 #include "confdefs.h"
1652
1653 int
1654 main (void)
1655 {
1656 #ifndef __GNUC__
1657 choke me
1658 #endif
1659
1660 ;
1661 return 0;
1662 }
1663 _ACEOF
1664 rm -f "conftest.$ac_objext"
1665 if { (eval echo "$as_me:1665: \"$ac_compile\"") >&5
1666 (eval $ac_compile) 2>&5
1667 ac_status=$?
1668 echo "$as_me:1668: \$? = $ac_status" >&5
1669 (exit "$ac_status"); } &&
1670 { ac_try='test -s "conftest.$ac_objext"'
1671 { (eval echo "$as_me:1671: \"$ac_try\"") >&5
1672 (eval $ac_try) 2>&5
1673 ac_status=$?
1674 echo "$as_me:1674: \$? = $ac_status" >&5
1675 (exit "$ac_status"); }; }; then
1676 ac_compiler_gnu=yes
1677 else
1678 echo "$as_me: failed program was:" >&5
1679 cat "conftest.$ac_ext" >&5
1680 ac_compiler_gnu=no
1681 fi
1682 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1683 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1684
1685 fi
1686 echo "$as_me:1686: result: $ac_cv_c_compiler_gnu" >&5
1687 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1688 GCC=`test $ac_compiler_gnu = yes && echo yes`
1689 ac_test_CFLAGS=${CFLAGS+set}
1690 ac_save_CFLAGS=$CFLAGS
1691 CFLAGS="-g"
1692 echo "$as_me:1692: checking whether $CC accepts -g" >&5
1693 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1694 if test "${ac_cv_prog_cc_g+set}" = set; then
1695 echo $ECHO_N "(cached) $ECHO_C" >&6
1696 else
1697 cat >"conftest.$ac_ext" <<_ACEOF
1698 #line 1698 "configure"
1699 #include "confdefs.h"
1700
1701 int
1702 main (void)
1703 {
1704
1705 ;
1706 return 0;
1707 }
1708 _ACEOF
1709 rm -f "conftest.$ac_objext"
1710 if { (eval echo "$as_me:1710: \"$ac_compile\"") >&5
1711 (eval $ac_compile) 2>&5
1712 ac_status=$?
1713 echo "$as_me:1713: \$? = $ac_status" >&5
1714 (exit "$ac_status"); } &&
1715 { ac_try='test -s "conftest.$ac_objext"'
1716 { (eval echo "$as_me:1716: \"$ac_try\"") >&5
1717 (eval $ac_try) 2>&5
1718 ac_status=$?
1719 echo "$as_me:1719: \$? = $ac_status" >&5
1720 (exit "$ac_status"); }; }; then
1721 ac_cv_prog_cc_g=yes
1722 else
1723 echo "$as_me: failed program was:" >&5
1724 cat "conftest.$ac_ext" >&5
1725 ac_cv_prog_cc_g=no
1726 fi
1727 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1728 fi
1729 echo "$as_me:1729: result: $ac_cv_prog_cc_g" >&5
1730 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1731 if test "$ac_test_CFLAGS" = set; then
1732 CFLAGS=$ac_save_CFLAGS
1733 elif test $ac_cv_prog_cc_g = yes; then
1734 if test "$GCC" = yes; then
1735 CFLAGS="-g -O2"
1736 else
1737 CFLAGS="-g"
1738 fi
1739 else
1740 if test "$GCC" = yes; then
1741 CFLAGS="-O2"
1742 else
1743 CFLAGS=
1744 fi
1745 fi
1746 # Some people use a C++ compiler to compile C. Since we use `exit',
1747 # in C++ we need to declare it. In case someone uses the same compiler
1748 # for both compiling C and C++ we need to have the C++ compiler decide
1749 # the declaration of exit, since it's the most demanding environment.
1750 cat >"conftest.$ac_ext" <<_ACEOF
1751 #ifndef __cplusplus
1752 choke me
1753 #endif
1754 _ACEOF
1755 rm -f "conftest.$ac_objext"
1756 if { (eval echo "$as_me:1756: \"$ac_compile\"") >&5
1757 (eval $ac_compile) 2>&5
1758 ac_status=$?
1759 echo "$as_me:1759: \$? = $ac_status" >&5
1760 (exit "$ac_status"); } &&
1761 { ac_try='test -s "conftest.$ac_objext"'
1762 { (eval echo "$as_me:1762: \"$ac_try\"") >&5
1763 (eval $ac_try) 2>&5
1764 ac_status=$?
1765 echo "$as_me:1765: \$? = $ac_status" >&5
1766 (exit "$ac_status"); }; }; then
1767 for ac_declaration in \
1768 ''\
1769 '#include <stdlib.h>' \
1770 'extern "C" void std::exit (int) throw (); using std::exit;' \
1771 'extern "C" void std::exit (int); using std::exit;' \
1772 'extern "C" void exit (int) throw ();' \
1773 'extern "C" void exit (int);' \
1774 'void exit (int);'
1775 do
1776 cat >"conftest.$ac_ext" <<_ACEOF
1777 #line 1777 "configure"
1778 #include "confdefs.h"
1779 #include <stdlib.h>
1780 $ac_declaration
1781 int
1782 main (void)
1783 {
1784 exit (42);
1785 ;
1786 return 0;
1787 }
1788 _ACEOF
1789 rm -f "conftest.$ac_objext"
1790 if { (eval echo "$as_me:1790: \"$ac_compile\"") >&5
1791 (eval $ac_compile) 2>&5
1792 ac_status=$?
1793 echo "$as_me:1793: \$? = $ac_status" >&5
1794 (exit "$ac_status"); } &&
1795 { ac_try='test -s "conftest.$ac_objext"'
1796 { (eval echo "$as_me:1796: \"$ac_try\"") >&5
1797 (eval $ac_try) 2>&5
1798 ac_status=$?
1799 echo "$as_me:1799: \$? = $ac_status" >&5
1800 (exit "$ac_status"); }; }; then
1801 :
1802 else
1803 echo "$as_me: failed program was:" >&5
1804 cat "conftest.$ac_ext" >&5
1805 continue
1806 fi
1807 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1808 cat >"conftest.$ac_ext" <<_ACEOF
1809 #line 1809 "configure"
1810 #include "confdefs.h"
1811 $ac_declaration
1812 int
1813 main (void)
1814 {
1815 exit (42);
1816 ;
1817 return 0;
1818 }
1819 _ACEOF
1820 rm -f "conftest.$ac_objext"
1821 if { (eval echo "$as_me:1821: \"$ac_compile\"") >&5
1822 (eval $ac_compile) 2>&5
1823 ac_status=$?
1824 echo "$as_me:1824: \$? = $ac_status" >&5
1825 (exit "$ac_status"); } &&
1826 { ac_try='test -s "conftest.$ac_objext"'
1827 { (eval echo "$as_me:1827: \"$ac_try\"") >&5
1828 (eval $ac_try) 2>&5
1829 ac_status=$?
1830 echo "$as_me:1830: \$? = $ac_status" >&5
1831 (exit "$ac_status"); }; }; then
1832 break
1833 else
1834 echo "$as_me: failed program was:" >&5
1835 cat "conftest.$ac_ext" >&5
1836 fi
1837 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1838 done
1839 rm -rf conftest*
1840 if test -n "$ac_declaration"; then
1841 echo '#ifdef __cplusplus' >>confdefs.h
1842 echo "$ac_declaration" >>confdefs.h
1843 echo '#endif' >>confdefs.h
1844 fi
1845
1846 else
1847 echo "$as_me: failed program was:" >&5
1848 cat "conftest.$ac_ext" >&5
1849 fi
1850 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1851 ac_ext=c
1852 ac_cpp='$CPP $CPPFLAGS'
1853 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1854 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1855 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1856 ac_main_return="return"
1857
1858 GCC_VERSION=none
1859 if test "$GCC" = yes ; then
1860 echo "$as_me:1860: checking version of $CC" >&5
1861 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1862 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^[^(]*([^)][^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1863 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1864 echo "$as_me:1864: result: $GCC_VERSION" >&5
1865 echo "${ECHO_T}$GCC_VERSION" >&6
1866 fi
1867
1868 INTEL_COMPILER=no
1869
1870 if test "$GCC" = yes ; then
1871 case "$host_os" in
1872 (linux*|gnu*)
1873 echo "$as_me:1873: checking if this is really Intel C compiler" >&5
1874 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
1875 cf_save_CFLAGS="$CFLAGS"
1876 CFLAGS="$CFLAGS -no-gcc"
1877 cat >"conftest.$ac_ext" <<_ACEOF
1878 #line 1878 "configure"
1879 #include "confdefs.h"
1880
1881 int
1882 main (void)
1883 {
1884
1885 #ifdef __INTEL_COMPILER
1886 #else
1887 #error __INTEL_COMPILER is not defined
1888 #endif
1889
1890 ;
1891 return 0;
1892 }
1893 _ACEOF
1894 rm -f "conftest.$ac_objext"
1895 if { (eval echo "$as_me:1895: \"$ac_compile\"") >&5
1896 (eval $ac_compile) 2>&5
1897 ac_status=$?
1898 echo "$as_me:1898: \$? = $ac_status" >&5
1899 (exit "$ac_status"); } &&
1900 { ac_try='test -s "conftest.$ac_objext"'
1901 { (eval echo "$as_me:1901: \"$ac_try\"") >&5
1902 (eval $ac_try) 2>&5
1903 ac_status=$?
1904 echo "$as_me:1904: \$? = $ac_status" >&5
1905 (exit "$ac_status"); }; }; then
1906 INTEL_COMPILER=yes
1907 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
1908
1909 else
1910 echo "$as_me: failed program was:" >&5
1911 cat "conftest.$ac_ext" >&5
1912 fi
1913 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1914 CFLAGS="$cf_save_CFLAGS"
1915 echo "$as_me:1915: result: $INTEL_COMPILER" >&5
1916 echo "${ECHO_T}$INTEL_COMPILER" >&6
1917 ;;
1918 esac
1919 fi
1920
1921 CLANG_COMPILER=no
1922
1923 if test "$GCC" = yes ; then
1924 echo "$as_me:1924: checking if this is really Clang C compiler" >&5
1925 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
1926 cf_save_CFLAGS="$CFLAGS"
1927 cat >"conftest.$ac_ext" <<_ACEOF
1928 #line 1928 "configure"
1929 #include "confdefs.h"
1930
1931 int
1932 main (void)
1933 {
1934
1935 #ifdef __clang__
1936 #else
1937 #error __clang__ is not defined
1938 #endif
1939
1940 ;
1941 return 0;
1942 }
1943 _ACEOF
1944 rm -f "conftest.$ac_objext"
1945 if { (eval echo "$as_me:1945: \"$ac_compile\"") >&5
1946 (eval $ac_compile) 2>&5
1947 ac_status=$?
1948 echo "$as_me:1948: \$? = $ac_status" >&5
1949 (exit "$ac_status"); } &&
1950 { ac_try='test -s "conftest.$ac_objext"'
1951 { (eval echo "$as_me:1951: \"$ac_try\"") >&5
1952 (eval $ac_try) 2>&5
1953 ac_status=$?
1954 echo "$as_me:1954: \$? = $ac_status" >&5
1955 (exit "$ac_status"); }; }; then
1956 CLANG_COMPILER=yes
1957
1958 else
1959 echo "$as_me: failed program was:" >&5
1960 cat "conftest.$ac_ext" >&5
1961 fi
1962 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1963 CFLAGS="$cf_save_CFLAGS"
1964 echo "$as_me:1964: result: $CLANG_COMPILER" >&5
1965 echo "${ECHO_T}$CLANG_COMPILER" >&6
1966 fi
1967
1968 CLANG_VERSION=none
1969
1970 if test "x$CLANG_COMPILER" = "xyes" ; then
1971 case "$CC" in
1972 (c[1-9][0-9]|*/c[1-9][0-9])
1973 { echo "$as_me:1973: WARNING: replacing broken compiler alias $CC" >&5
1974 echo "$as_me: WARNING: replacing broken compiler alias $CC" >&2;}
1975 CFLAGS="$CFLAGS -std=`echo "$CC" | sed -e 's%.*/%%'`"
1976 CC=clang
1977 ;;
1978 esac
1979
1980 echo "$as_me:1980: checking version of $CC" >&5
1981 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1982 CLANG_VERSION="`$CC --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(CLANG[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1983 test -z "$CLANG_VERSION" && CLANG_VERSION=unknown
1984 echo "$as_me:1984: result: $CLANG_VERSION" >&5
1985 echo "${ECHO_T}$CLANG_VERSION" >&6
1986
1987 for cf_clang_opt in \
1988 -Qunused-arguments \
1989 -Wno-error=implicit-function-declaration
1990 do
1991 echo "$as_me:1991: checking if option $cf_clang_opt works" >&5
1992 echo $ECHO_N "checking if option $cf_clang_opt works... $ECHO_C" >&6
1993 cf_save_CFLAGS="$CFLAGS"
1994 CFLAGS="$CFLAGS $cf_clang_opt"
1995 cat >"conftest.$ac_ext" <<_ACEOF
1996 #line 1996 "configure"
1997 #include "confdefs.h"
1998
1999 #include <stdio.h>
2000 int
2001 main (void)
2002 {
2003
2004 printf("hello!\\n");
2005 ;
2006 return 0;
2007 }
2008 _ACEOF
2009 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
2010 if { (eval echo "$as_me:2010: \"$ac_link\"") >&5
2011 (eval $ac_link) 2>&5
2012 ac_status=$?
2013 echo "$as_me:2013: \$? = $ac_status" >&5
2014 (exit "$ac_status"); } &&
2015 { ac_try='test -s "conftest$ac_exeext"'
2016 { (eval echo "$as_me:2016: \"$ac_try\"") >&5
2017 (eval $ac_try) 2>&5
2018 ac_status=$?
2019 echo "$as_me:2019: \$? = $ac_status" >&5
2020 (exit "$ac_status"); }; }; then
2021
2022 cf_clang_optok=yes
2023 else
2024 echo "$as_me: failed program was:" >&5
2025 cat "conftest.$ac_ext" >&5
2026
2027 cf_clang_optok=no
2028 fi
2029 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
2030 echo "$as_me:2030: result: $cf_clang_optok" >&5
2031 echo "${ECHO_T}$cf_clang_optok" >&6
2032 CFLAGS="$cf_save_CFLAGS"
2033 if test "$cf_clang_optok" = yes; then
2034 test -n "$verbose" && echo " adding option $cf_clang_opt" 1>&6
2035
2036 echo "${as_me:-configure}:2036: testing adding option $cf_clang_opt ..." 1>&5
2037
2038 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2039 CFLAGS="${CFLAGS}$cf_clang_opt"
2040
2041 fi
2042 done
2043 fi
2044
2045 echo "$as_me:2045: checking for $CC option to accept ANSI C" >&5
2046 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2047 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2048 echo $ECHO_N "(cached) $ECHO_C" >&6
2049 else
2050 ac_cv_prog_cc_stdc=no
2051 ac_save_CC=$CC
2052 cat >"conftest.$ac_ext" <<_ACEOF
2053 #line 2053 "configure"
2054 #include "confdefs.h"
2055 #include <stdarg.h>
2056 #include <stdio.h>
2057 #include <sys/types.h>
2058 #include <sys/stat.h>
2059 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2060 struct buf { int x; };
2061 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2062 static char *e (char **p, int i)
2063 {
2064 return p[i];
2065 }
2066 static char *f (char * (*g) (char **, int), char **p, ...)
2067 {
2068 char *s;
2069 va_list v;
2070 va_start (v,p);
2071 s = g (p, va_arg (v,int));
2072 va_end (v);
2073 return s;
2074 }
2075 int test (int i, double x);
2076 struct s1 {int (*f) (int a);};
2077 struct s2 {int (*f) (double a);};
2078 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2079 int argc;
2080 char **argv;
2081 int
2082 main (void)
2083 {
2084 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2085 ;
2086 return 0;
2087 }
2088 _ACEOF
2089 # Don't try gcc -ansi; that turns off useful extensions and
2090 # breaks some systems' header files.
2091 # AIX -qlanglvl=ansi
2092 # Ultrix and OSF/1 -std1
2093 # HP-UX 10.20 and later -Ae
2094 # HP-UX older versions -Aa -D_HPUX_SOURCE
2095 # SVR4 -Xc -D__EXTENSIONS__
2096 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2097 do
2098 CC="$ac_save_CC $ac_arg"
2099 rm -f "conftest.$ac_objext"
2100 if { (eval echo "$as_me:2100: \"$ac_compile\"") >&5
2101 (eval $ac_compile) 2>&5
2102 ac_status=$?
2103 echo "$as_me:2103: \$? = $ac_status" >&5
2104 (exit "$ac_status"); } &&
2105 { ac_try='test -s "conftest.$ac_objext"'
2106 { (eval echo "$as_me:2106: \"$ac_try\"") >&5
2107 (eval $ac_try) 2>&5
2108 ac_status=$?
2109 echo "$as_me:2109: \$? = $ac_status" >&5
2110 (exit "$ac_status"); }; }; then
2111 ac_cv_prog_cc_stdc=$ac_arg
2112 break
2113 else
2114 echo "$as_me: failed program was:" >&5
2115 cat "conftest.$ac_ext" >&5
2116 fi
2117 rm -f "conftest.$ac_objext"
2118 done
2119 rm -f "conftest.$ac_ext" "conftest.$ac_objext"
2120 CC=$ac_save_CC
2121
2122 fi
2123
2124 case "x$ac_cv_prog_cc_stdc" in
2125 x|xno)
2126 echo "$as_me:2126: result: none needed" >&5
2127 echo "${ECHO_T}none needed" >&6 ;;
2128 *)
2129 echo "$as_me:2129: result: $ac_cv_prog_cc_stdc" >&5
2130 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2131 CC="$CC $ac_cv_prog_cc_stdc" ;;
2132 esac
2133
2134 # This should have been defined by AC_PROG_CC
2135 : "${CC:=cc}"
2136
2137 echo "$as_me:2137: checking \$CFLAGS variable" >&5
2138 echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
2139 case "x$CFLAGS" in
2140 (*-[IUD]*)
2141 echo "$as_me:2141: result: broken" >&5
2142 echo "${ECHO_T}broken" >&6
2143 { echo "$as_me:2143: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
2144 echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
2145 cf_flags="$CFLAGS"
2146 CFLAGS=
2147 for cf_arg in $cf_flags
2148 do
2149
2150 cf_fix_cppflags=no
2151 cf_new_cflags=
2152 cf_new_cppflags=
2153 cf_new_extra_cppflags=
2154
2155 for cf_add_cflags in $cf_arg
2156 do
2157 case "$cf_fix_cppflags" in
2158 (no)
2159 case "$cf_add_cflags" in
2160 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2161 case "$cf_add_cflags" in
2162 (-D*)
2163 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2164
2165 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2166 && test -z "${cf_tst_cflags}" \
2167 && cf_fix_cppflags=yes
2168
2169 if test "$cf_fix_cppflags" = yes ; then
2170
2171 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2172 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2173
2174 continue
2175 elif test "${cf_tst_cflags}" = "\"'" ; then
2176
2177 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2178 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2179
2180 continue
2181 fi
2182 ;;
2183 esac
2184 case "$CPPFLAGS" in
2185 (*$cf_add_cflags)
2186 ;;
2187 (*)
2188 case "$cf_add_cflags" in
2189 (-D*)
2190 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2191
2192 CPPFLAGS=`echo "$CPPFLAGS" | \
2193 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2194 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2195
2196 ;;
2197 esac
2198
2199 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2200 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2201
2202 ;;
2203 esac
2204 ;;
2205 (*)
2206
2207 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2208 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2209
2210 ;;
2211 esac
2212 ;;
2213 (yes)
2214
2215 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2216 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2217
2218 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2219
2220 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2221 && test -z "${cf_tst_cflags}" \
2222 && cf_fix_cppflags=no
2223 ;;
2224 esac
2225 done
2226
2227 if test -n "$cf_new_cflags" ; then
2228
2229 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2230 CFLAGS="${CFLAGS}$cf_new_cflags"
2231
2232 fi
2233
2234 if test -n "$cf_new_cppflags" ; then
2235
2236 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2237 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2238
2239 fi
2240
2241 if test -n "$cf_new_extra_cppflags" ; then
2242
2243 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2244 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2245
2246 fi
2247
2248 done
2249 ;;
2250 (*)
2251 echo "$as_me:2251: result: ok" >&5
2252 echo "${ECHO_T}ok" >&6
2253 ;;
2254 esac
2255
2256 echo "$as_me:2256: checking \$CC variable" >&5
2257 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2258 case "$CC" in
2259 (*[\ \ ]-*)
2260 echo "$as_me:2260: result: broken" >&5
2261 echo "${ECHO_T}broken" >&6
2262 { echo "$as_me:2262: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2263 echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2264 # humor him...
2265 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2266 cf_flags=`echo "$CC" | sed -e "s%^$cf_prog%%"`
2267 CC="$cf_prog"
2268 for cf_arg in $cf_flags
2269 do
2270 case "x$cf_arg" in
2271 (x-[IUDfgOW]*)
2272
2273 cf_fix_cppflags=no
2274 cf_new_cflags=
2275 cf_new_cppflags=
2276 cf_new_extra_cppflags=
2277
2278 for cf_add_cflags in $cf_arg
2279 do
2280 case "$cf_fix_cppflags" in
2281 (no)
2282 case "$cf_add_cflags" in
2283 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2284 case "$cf_add_cflags" in
2285 (-D*)
2286 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2287
2288 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2289 && test -z "${cf_tst_cflags}" \
2290 && cf_fix_cppflags=yes
2291
2292 if test "$cf_fix_cppflags" = yes ; then
2293
2294 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2295 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2296
2297 continue
2298 elif test "${cf_tst_cflags}" = "\"'" ; then
2299
2300 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2301 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2302
2303 continue
2304 fi
2305 ;;
2306 esac
2307 case "$CPPFLAGS" in
2308 (*$cf_add_cflags)
2309 ;;
2310 (*)
2311 case "$cf_add_cflags" in
2312 (-D*)
2313 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2314
2315 CPPFLAGS=`echo "$CPPFLAGS" | \
2316 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2317 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2318
2319 ;;
2320 esac
2321
2322 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2323 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2324
2325 ;;
2326 esac
2327 ;;
2328 (*)
2329
2330 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2331 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2332
2333 ;;
2334 esac
2335 ;;
2336 (yes)
2337
2338 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2339 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2340
2341 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2342
2343 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2344 && test -z "${cf_tst_cflags}" \
2345 && cf_fix_cppflags=no
2346 ;;
2347 esac
2348 done
2349
2350 if test -n "$cf_new_cflags" ; then
2351
2352 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2353 CFLAGS="${CFLAGS}$cf_new_cflags"
2354
2355 fi
2356
2357 if test -n "$cf_new_cppflags" ; then
2358
2359 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2360 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2361
2362 fi
2363
2364 if test -n "$cf_new_extra_cppflags" ; then
2365
2366 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2367 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2368
2369 fi
2370
2371 ;;
2372 (*)
2373 CC="$CC $cf_arg"
2374 ;;
2375 esac
2376 done
2377 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2378
2379 echo "${as_me:-configure}:2379: testing resulting CC: '$CC' ..." 1>&5
2380
2381 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2382
2383 echo "${as_me:-configure}:2383: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2384
2385 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2386
2387 echo "${as_me:-configure}:2387: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2388
2389 ;;
2390 (*)
2391 echo "$as_me:2391: result: ok" >&5
2392 echo "${ECHO_T}ok" >&6
2393 ;;
2394 esac
2395
2396 echo "$as_me:2396: checking whether ${MAKE-make} sets \${MAKE}" >&5
2397 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
2398 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
2399 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
2400 echo $ECHO_N "(cached) $ECHO_C" >&6
2401 else
2402 cat >conftest.make <<\EOF
2403 all:
2404 @echo 'ac_maketemp="${MAKE}"'
2405 EOF
2406 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
2407 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
2408 if test -n "$ac_maketemp"; then
2409 eval ac_cv_prog_make_${ac_make}_set=yes
2410 else
2411 eval ac_cv_prog_make_${ac_make}_set=no
2412 fi
2413 rm -f conftest.make
2414 fi
2415 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
2416 echo "$as_me:2416: result: yes" >&5
2417 echo "${ECHO_T}yes" >&6
2418 SET_MAKE=
2419 else
2420 echo "$as_me:2420: result: no" >&5
2421 echo "${ECHO_T}no" >&6
2422 SET_MAKE="MAKE=${MAKE-make}"
2423 fi
2424
2425 for ac_prog in ggrep grep
2426 do
2427 # Extract the first word of "$ac_prog", so it can be a program name with args.
2428 set dummy $ac_prog; ac_word=$2
2429 echo "$as_me:2429: checking for $ac_word" >&5
2430 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2431 if test "${ac_cv_prog_GREP+set}" = set; then
2432 echo $ECHO_N "(cached) $ECHO_C" >&6
2433 else
2434 if test -n "$GREP"; then
2435 ac_cv_prog_GREP="$GREP" # Let the user override the test.
2436 else
2437 ac_save_IFS=$IFS; IFS=$ac_path_separator
2438 ac_dummy="$PATH"
2439 for ac_dir in $ac_dummy; do
2440 IFS=$ac_save_IFS
2441 test -z "$ac_dir" && ac_dir=.
2442 $as_executable_p "$ac_dir/$ac_word" || continue
2443 ac_cv_prog_GREP="$ac_prog"
2444 echo "$as_me:2444: found $ac_dir/$ac_word" >&5
2445 break
2446 done
2447
2448 fi
2449 fi
2450 GREP=$ac_cv_prog_GREP
2451 if test -n "$GREP"; then
2452 echo "$as_me:2452: result: $GREP" >&5
2453 echo "${ECHO_T}$GREP" >&6
2454 else
2455 echo "$as_me:2455: result: no" >&5
2456 echo "${ECHO_T}no" >&6
2457 fi
2458
2459 test -n "$GREP" && break
2460 done
2461 test -n "$GREP" || GREP=": "
2462
2463 echo "$as_me:2463: checking for fgrep" >&5
2464 echo $ECHO_N "checking for fgrep... $ECHO_C" >&6
2465 if test "${ac_cv_path_FGREP+set}" = set; then
2466 echo $ECHO_N "(cached) $ECHO_C" >&6
2467 else
2468 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
2469 then ac_cv_path_FGREP="$GREP -F"
2470 else
2471 for ac_prog in gfgrep fgrep
2472 do
2473 # Extract the first word of "$ac_prog", so it can be a program name with args.
2474 set dummy $ac_prog; ac_word=$2
2475 echo "$as_me:2475: checking for $ac_word" >&5
2476 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2477 if test "${ac_cv_path_FGREP+set}" = set; then
2478 echo $ECHO_N "(cached) $ECHO_C" >&6
2479 else
2480 case $FGREP in
2481 [\\/]* | ?:[\\/]*)
2482 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
2483 ;;
2484 *)
2485 ac_save_IFS=$IFS; IFS=$ac_path_separator
2486 ac_dummy="$PATH"
2487 for ac_dir in $ac_dummy; do
2488 IFS=$ac_save_IFS
2489 test -z "$ac_dir" && ac_dir=.
2490 if $as_executable_p "$ac_dir/$ac_word"; then
2491 ac_cv_path_FGREP="$ac_dir/$ac_word"
2492 echo "$as_me:2492: found $ac_dir/$ac_word" >&5
2493 break
2494 fi
2495 done
2496
2497 ;;
2498 esac
2499 fi
2500 FGREP=$ac_cv_path_FGREP
2501
2502 if test -n "$FGREP"; then
2503 echo "$as_me:2503: result: $FGREP" >&5
2504 echo "${ECHO_T}$FGREP" >&6
2505 else
2506 echo "$as_me:2506: result: no" >&5
2507 echo "${ECHO_T}no" >&6
2508 fi
2509
2510 test -n "$FGREP" && break
2511 done
2512 test -n "$FGREP" || FGREP=": "
2513
2514 test "x$ac_cv_path_FGREP" = "x:" && { { echo "$as_me:2514: error: cannot find workable fgrep" >&5
2515 echo "$as_me: error: cannot find workable fgrep" >&2;}
2516 { (exit 1); exit 1; }; }
2517 fi
2518 fi
2519 echo "$as_me:2519: result: $ac_cv_path_FGREP" >&5
2520 echo "${ECHO_T}$ac_cv_path_FGREP" >&6
2521 FGREP="$ac_cv_path_FGREP"
2522
2523 echo "$as_me:2523: checking for makeflags variable" >&5
2524 echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
2525 if test "${cf_cv_makeflags+set}" = set; then
2526 echo $ECHO_N "(cached) $ECHO_C" >&6
2527 else
2528
2529 cf_save_makeflags="$MAKEFLAGS"; unset MAKEFLAGS
2530 cf_save_mflags="$MFLAGS"; unset MFLAGS
2531 cf_cv_makeflags=''
2532 for cf_option in '-${MAKEFLAGS}' '${MFLAGS}'
2533 do
2534 cat >cf_makeflags.tmp <<CF_EOF
2535 SHELL = $SHELL
2536 all :
2537 @ echo '.$cf_option'
2538 CF_EOF
2539 cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | ${FGREP-fgrep} -v "ing directory" | sed -e 's,[ ]*$,,'`
2540 case "$cf_result" in
2541 (.*k|.*kw)
2542 cf_result="`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`"
2543 case "$cf_result" in
2544 (.*CC=*) cf_cv_makeflags=
2545 ;;
2546 (*) cf_cv_makeflags=$cf_option
2547 ;;
2548 esac
2549 break
2550 ;;
2551 (.-)
2552 ;;
2553 (*)
2554
2555 echo "${as_me:-configure}:2555: testing given option \"$cf_option\",no match \"$cf_result\" ..." 1>&5
2556
2557 ;;
2558 esac
2559 done
2560 test -n "$cf_save_makeflags" && MAKEFLAGS="$cf_save_makeflags"
2561 test -n "$cf_save_mflags" && MFLAGS="$cf_save_mflags"
2562 rm -f cf_makeflags.tmp
2563
2564 fi
2565 echo "$as_me:2565: result: $cf_cv_makeflags" >&5
2566 echo "${ECHO_T}$cf_cv_makeflags" >&6
2567
2568 echo "$as_me:2568: checking for \".PHONY\" make-support" >&5
2569 echo $ECHO_N "checking for \".PHONY\" make-support... $ECHO_C" >&6
2570 if test "${cf_cv_make_PHONY+set}" = set; then
2571 echo $ECHO_N "(cached) $ECHO_C" >&6
2572 else
2573
2574 rm -rf conftest*
2575 (
2576 mkdir conftest || exit 1
2577 cd conftest
2578 cat >makefile <<'CF_EOF'
2579 .PHONY: always
2580 DATA=0
2581 always: always.out
2582 @echo "** making $@ $(DATA)"
2583 once: once.out
2584 @echo "** making $@ $(DATA)"
2585 always.out:
2586 @echo "** making $@ $(DATA)"
2587 echo $(DATA) > $@
2588 once.out:
2589 @echo "** making $@ $(DATA)"
2590 echo $(DATA) > $@
2591 CF_EOF
2592 for cf_data in 1 2 3
2593 do
2594 ${MAKE:-make} always DATA=$cf_data
2595 ${MAKE:-make} once DATA=$cf_data
2596 ${MAKE:-make} -t always once
2597 if test -f always ; then
2598 echo "no (case 1)" > ../conftest.tmp
2599 elif test ! -f always.out ; then
2600 echo "no (case 2)" > ../conftest.tmp
2601 elif test ! -f once.out ; then
2602 echo "no (case 3)" > ../conftest.tmp
2603 elif ! cmp -s always.out once.out ; then
2604 echo "no (case 4)" > ../conftest.tmp
2605 diff always.out once.out
2606 else
2607 cf_check="`cat always.out`"
2608 if test "x$cf_check" != "x$cf_data" ; then
2609 echo "no (case 5)" > ../conftest.tmp
2610 else
2611 echo yes > ../conftest.tmp
2612 rm -f ./*.out
2613 continue
2614 fi
2615 fi
2616 break
2617 done
2618 ) >&5 2>&1
2619 cf_cv_make_PHONY="`cat conftest.tmp`"
2620 rm -rf conftest*
2621
2622 fi
2623 echo "$as_me:2623: result: $cf_cv_make_PHONY" >&5
2624 echo "${ECHO_T}$cf_cv_make_PHONY" >&6
2625 MAKE_NO_PHONY="#"
2626 MAKE_PHONY="#"
2627 test "x$cf_cv_make_PHONY" = xyes && MAKE_PHONY=
2628 test "x$cf_cv_make_PHONY" != xyes && MAKE_NO_PHONY=
2629
2630 echo "$as_me:2630: checking for egrep" >&5
2631 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2632 if test "${ac_cv_path_EGREP+set}" = set; then
2633 echo $ECHO_N "(cached) $ECHO_C" >&6
2634 else
2635 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
2636 then ac_cv_path_EGREP="$GREP -E"
2637 else
2638 for ac_prog in gegrep egrep
2639 do
2640 # Extract the first word of "$ac_prog", so it can be a program name with args.
2641 set dummy $ac_prog; ac_word=$2
2642 echo "$as_me:2642: checking for $ac_word" >&5
2643 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2644 if test "${ac_cv_path_EGREP+set}" = set; then
2645 echo $ECHO_N "(cached) $ECHO_C" >&6
2646 else
2647 case $EGREP in
2648 [\\/]* | ?:[\\/]*)
2649 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
2650 ;;
2651 *)
2652 ac_save_IFS=$IFS; IFS=$ac_path_separator
2653 ac_dummy="$PATH"
2654 for ac_dir in $ac_dummy; do
2655 IFS=$ac_save_IFS
2656 test -z "$ac_dir" && ac_dir=.
2657 if $as_executable_p "$ac_dir/$ac_word"; then
2658 ac_cv_path_EGREP="$ac_dir/$ac_word"
2659 echo "$as_me:2659: found $ac_dir/$ac_word" >&5
2660 break
2661 fi
2662 done
2663
2664 ;;
2665 esac
2666 fi
2667 EGREP=$ac_cv_path_EGREP
2668
2669 if test -n "$EGREP"; then
2670 echo "$as_me:2670: result: $EGREP" >&5
2671 echo "${ECHO_T}$EGREP" >&6
2672 else
2673 echo "$as_me:2673: result: no" >&5
2674 echo "${ECHO_T}no" >&6
2675 fi
2676
2677 test -n "$EGREP" && break
2678 done
2679 test -n "$EGREP" || EGREP=": "
2680
2681 test "x$ac_cv_path_EGREP" = "x:" && { { echo "$as_me:2681: error: cannot find workable egrep" >&5
2682 echo "$as_me: error: cannot find workable egrep" >&2;}
2683 { (exit 1); exit 1; }; }
2684 fi
2685 fi
2686 echo "$as_me:2686: result: $ac_cv_path_EGREP" >&5
2687 echo "${ECHO_T}$ac_cv_path_EGREP" >&6
2688 EGREP="$ac_cv_path_EGREP"
2689
2690 ac_ext=c
2691 ac_cpp='$CPP $CPPFLAGS'
2692 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
2693 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
2694 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2695 ac_main_return="return"
2696 echo "$as_me:2696: checking how to run the C preprocessor" >&5
2697 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2698 # On Suns, sometimes $CPP names a directory.
2699 if test -n "$CPP" && test -d "$CPP"; then
2700 CPP=
2701 fi
2702 if test -z "$CPP"; then
2703 if test "${ac_cv_prog_CPP+set}" = set; then
2704 echo $ECHO_N "(cached) $ECHO_C" >&6
2705 else
2706 # Double quotes because CPP needs to be expanded
2707 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2708 do
2709 ac_preproc_ok=false
2710 for ac_c_preproc_warn_flag in '' yes
2711 do
2712 # Use a header file that comes with gcc, so configuring glibc
2713 # with a fresh cross-compiler works.
2714 # On the NeXT, cc -E runs the code through the compiler's parser,
2715 # not just through cpp. "Syntax error" is here to catch this case.
2716 cat >"conftest.$ac_ext" <<_ACEOF
2717 #line 2717 "configure"
2718 #include "confdefs.h"
2719 #include <assert.h>
2720 Syntax error
2721 _ACEOF
2722 if { (eval echo "$as_me:2722: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2723 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2724 ac_status=$?
2725 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2726 rm -f conftest.er1
2727 cat conftest.err >&5
2728 echo "$as_me:2728: \$? = $ac_status" >&5
2729 (exit "$ac_status"); } >/dev/null; then
2730 if test -s conftest.err; then
2731 ac_cpp_err=$ac_c_preproc_warn_flag
2732 else
2733 ac_cpp_err=
2734 fi
2735 else
2736 ac_cpp_err=yes
2737 fi
2738 if test -z "$ac_cpp_err"; then
2739 :
2740 else
2741 echo "$as_me: failed program was:" >&5
2742 cat "conftest.$ac_ext" >&5
2743 # Broken: fails on valid input.
2744 continue
2745 fi
2746 rm -f conftest.err "conftest.$ac_ext"
2747
2748 # OK, works on sane cases. Now check whether non-existent headers
2749 # can be detected and how.
2750 cat >"conftest.$ac_ext" <<_ACEOF
2751 #line 2751 "configure"
2752 #include "confdefs.h"
2753 #include <ac_nonexistent.h>
2754 _ACEOF
2755 if { (eval echo "$as_me:2755: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2756 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2757 ac_status=$?
2758 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2759 rm -f conftest.er1
2760 cat conftest.err >&5
2761 echo "$as_me:2761: \$? = $ac_status" >&5
2762 (exit "$ac_status"); } >/dev/null; then
2763 if test -s conftest.err; then
2764 ac_cpp_err=$ac_c_preproc_warn_flag
2765 else
2766 ac_cpp_err=
2767 fi
2768 else
2769 ac_cpp_err=yes
2770 fi
2771 if test -z "$ac_cpp_err"; then
2772 # Broken: success on invalid input.
2773 continue
2774 else
2775 echo "$as_me: failed program was:" >&5
2776 cat "conftest.$ac_ext" >&5
2777 # Passes both tests.
2778 ac_preproc_ok=:
2779 break
2780 fi
2781 rm -f conftest.err "conftest.$ac_ext"
2782
2783 done
2784 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2785 rm -f conftest.err "conftest.$ac_ext"
2786 if $ac_preproc_ok; then
2787 break
2788 fi
2789
2790 done
2791 ac_cv_prog_CPP=$CPP
2792
2793 fi
2794 CPP=$ac_cv_prog_CPP
2795 else
2796 ac_cv_prog_CPP=$CPP
2797 fi
2798 echo "$as_me:2798: result: $CPP" >&5
2799 echo "${ECHO_T}$CPP" >&6
2800 ac_preproc_ok=false
2801 for ac_c_preproc_warn_flag in '' yes
2802 do
2803 # Use a header file that comes with gcc, so configuring glibc
2804 # with a fresh cross-compiler works.
2805 # On the NeXT, cc -E runs the code through the compiler's parser,
2806 # not just through cpp. "Syntax error" is here to catch this case.
2807 cat >"conftest.$ac_ext" <<_ACEOF
2808 #line 2808 "configure"
2809 #include "confdefs.h"
2810 #include <assert.h>
2811 Syntax error
2812 _ACEOF
2813 if { (eval echo "$as_me:2813: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2814 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2815 ac_status=$?
2816 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2817 rm -f conftest.er1
2818 cat conftest.err >&5
2819 echo "$as_me:2819: \$? = $ac_status" >&5
2820 (exit "$ac_status"); } >/dev/null; then
2821 if test -s conftest.err; then
2822 ac_cpp_err=$ac_c_preproc_warn_flag
2823 else
2824 ac_cpp_err=
2825 fi
2826 else
2827 ac_cpp_err=yes
2828 fi
2829 if test -z "$ac_cpp_err"; then
2830 :
2831 else
2832 echo "$as_me: failed program was:" >&5
2833 cat "conftest.$ac_ext" >&5
2834 # Broken: fails on valid input.
2835 continue
2836 fi
2837 rm -f conftest.err "conftest.$ac_ext"
2838
2839 # OK, works on sane cases. Now check whether non-existent headers
2840 # can be detected and how.
2841 cat >"conftest.$ac_ext" <<_ACEOF
2842 #line 2842 "configure"
2843 #include "confdefs.h"
2844 #include <ac_nonexistent.h>
2845 _ACEOF
2846 if { (eval echo "$as_me:2846: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2847 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2848 ac_status=$?
2849 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2850 rm -f conftest.er1
2851 cat conftest.err >&5
2852 echo "$as_me:2852: \$? = $ac_status" >&5
2853 (exit "$ac_status"); } >/dev/null; then
2854 if test -s conftest.err; then
2855 ac_cpp_err=$ac_c_preproc_warn_flag
2856 else
2857 ac_cpp_err=
2858 fi
2859 else
2860 ac_cpp_err=yes
2861 fi
2862 if test -z "$ac_cpp_err"; then
2863 # Broken: success on invalid input.
2864 continue
2865 else
2866 echo "$as_me: failed program was:" >&5
2867 cat "conftest.$ac_ext" >&5
2868 # Passes both tests.
2869 ac_preproc_ok=:
2870 break
2871 fi
2872 rm -f conftest.err "conftest.$ac_ext"
2873
2874 done
2875 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2876 rm -f conftest.err "conftest.$ac_ext"
2877 if $ac_preproc_ok; then
2878 :
2879 else
2880 { { echo "$as_me:2880: error: C preprocessor \"$CPP\" fails sanity check" >&5
2881 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2882 { (exit 1); exit 1; }; }
2883 fi
2884
2885 ac_ext=c
2886 ac_cpp='$CPP $CPPFLAGS'
2887 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
2888 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
2889 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2890 ac_main_return="return"
2891
2892 # Find a good install program. We prefer a C program (faster),
2893 # so one script is as good as another. But avoid the broken or
2894 # incompatible versions:
2895 # SysV /etc/install, /usr/sbin/install
2896 # SunOS /usr/etc/install
2897 # IRIX /sbin/install
2898 # AIX /bin/install
2899 # AmigaOS /C/install, which installs bootblocks on floppy discs
2900 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2901 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2902 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2903 # ./install, which can be erroneously created by make from ./install.sh.
2904 echo "$as_me:2904: checking for a BSD compatible install" >&5
2905 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2906 if test -z "$INSTALL"; then
2907 if test "${ac_cv_path_install+set}" = set; then
2908 echo $ECHO_N "(cached) $ECHO_C" >&6
2909 else
2910 ac_save_IFS=$IFS; IFS=$ac_path_separator
2911 for ac_dir in $PATH; do
2912 IFS=$ac_save_IFS
2913 # Account for people who put trailing slashes in PATH elements.
2914 case $ac_dir/ in
2915 / | ./ | .// | /cC/* \
2916 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2917 | /usr/ucb/* ) ;;
2918 *)
2919 # OSF1 and SCO ODT 3.0 have their own names for install.
2920 # Don't use installbsd from OSF since it installs stuff as root
2921 # by default.
2922 for ac_prog in ginstall scoinst install; do
2923 if $as_executable_p "$ac_dir/$ac_prog"; then
2924 if test $ac_prog = install &&
2925 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2926 # AIX install. It has an incompatible calling convention.
2927 :
2928 elif test $ac_prog = install &&
2929 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2930 # program-specific install script used by HP pwplus--don't use.
2931 :
2932 else
2933 ac_cv_path_install="$ac_dir/$ac_prog -c"
2934 break 2
2935 fi
2936 fi
2937 done
2938 ;;
2939 esac
2940 done
2941
2942 fi
2943 if test "${ac_cv_path_install+set}" = set; then
2944 INSTALL=$ac_cv_path_install
2945 else
2946 # As a last resort, use the slow shell script. We don't cache a
2947 # path for INSTALL within a source directory, because that will
2948 # break other packages using the cache if that directory is
2949 # removed, or if the path is relative.
2950 INSTALL=$ac_install_sh
2951 fi
2952 fi
2953 echo "$as_me:2953: result: $INSTALL" >&5
2954 echo "${ECHO_T}$INSTALL" >&6
2955
2956 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2957 # It thinks the first close brace ends the variable substitution.
2958 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2959
2960 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2961
2962 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2963
2964 for ac_prog in byacc 'bison -y'
2965 do
2966 # Extract the first word of "$ac_prog", so it can be a program name with args.
2967 set dummy $ac_prog; ac_word=$2
2968 echo "$as_me:2968: checking for $ac_word" >&5
2969 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2970 if test "${ac_cv_prog_YACC+set}" = set; then
2971 echo $ECHO_N "(cached) $ECHO_C" >&6
2972 else
2973 if test -n "$YACC"; then
2974 ac_cv_prog_YACC="$YACC" # Let the user override the test.
2975 else
2976 ac_save_IFS=$IFS; IFS=$ac_path_separator
2977 ac_dummy="$PATH"
2978 for ac_dir in $ac_dummy; do
2979 IFS=$ac_save_IFS
2980 test -z "$ac_dir" && ac_dir=.
2981 $as_executable_p "$ac_dir/$ac_word" || continue
2982 ac_cv_prog_YACC="$ac_prog"
2983 echo "$as_me:2983: found $ac_dir/$ac_word" >&5
2984 break
2985 done
2986
2987 fi
2988 fi
2989 YACC=$ac_cv_prog_YACC
2990 if test -n "$YACC"; then
2991 echo "$as_me:2991: result: $YACC" >&5
2992 echo "${ECHO_T}$YACC" >&6
2993 else
2994 echo "$as_me:2994: result: no" >&5
2995 echo "${ECHO_T}no" >&6
2996 fi
2997
2998 test -n "$YACC" && break
2999 done
3000 test -n "$YACC" || YACC="yacc"
3001
3002 for ac_prog in lint cppcheck splint
3003 do
3004 # Extract the first word of "$ac_prog", so it can be a program name with args.
3005 set dummy $ac_prog; ac_word=$2
3006 echo "$as_me:3006: checking for $ac_word" >&5
3007 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3008 if test "${ac_cv_prog_LINT+set}" = set; then
3009 echo $ECHO_N "(cached) $ECHO_C" >&6
3010 else
3011 if test -n "$LINT"; then
3012 ac_cv_prog_LINT="$LINT" # Let the user override the test.
3013 else
3014 ac_save_IFS=$IFS; IFS=$ac_path_separator
3015 ac_dummy="$PATH"
3016 for ac_dir in $ac_dummy; do
3017 IFS=$ac_save_IFS
3018 test -z "$ac_dir" && ac_dir=.
3019 $as_executable_p "$ac_dir/$ac_word" || continue
3020 ac_cv_prog_LINT="$ac_prog"
3021 echo "$as_me:3021: found $ac_dir/$ac_word" >&5
3022 break
3023 done
3024
3025 fi
3026 fi
3027 LINT=$ac_cv_prog_LINT
3028 if test -n "$LINT"; then
3029 echo "$as_me:3029: result: $LINT" >&5
3030 echo "${ECHO_T}$LINT" >&6
3031 else
3032 echo "$as_me:3032: result: no" >&5
3033 echo "${ECHO_T}no" >&6
3034 fi
3035
3036 test -n "$LINT" && break
3037 done
3038
3039 case "x$LINT" in
3040 (xlint|x*/lint) # NetBSD 10
3041 test -z "$LINT_OPTS" && LINT_OPTS="-chapbrxzgFS -v -Ac11"
3042 ;;
3043 (xcppcheck|x*/cppcheck)
3044 test -z "$LINT_OPTS" && LINT_OPTS="--enable=all -D__CPPCHECK__"
3045 ;;
3046 esac
3047
3048 echo "$as_me:3048: checking if filesystem supports mixed-case filenames" >&5
3049 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
3050 if test "${cf_cv_mixedcase+set}" = set; then
3051 echo $ECHO_N "(cached) $ECHO_C" >&6
3052 else
3053
3054 if test "$cross_compiling" = yes ; then
3055 case "$target_alias" in
3056 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*|darwin*)
3057 cf_cv_mixedcase=no
3058 ;;
3059 (*)
3060 cf_cv_mixedcase=yes
3061 ;;
3062 esac
3063 else
3064 rm -f conftest CONFTEST
3065 echo test >conftest
3066 if test -f CONFTEST ; then
3067 cf_cv_mixedcase=no
3068 else
3069 cf_cv_mixedcase=yes
3070 fi
3071 rm -f conftest CONFTEST
3072 fi
3073
3074 fi
3075 echo "$as_me:3075: result: $cf_cv_mixedcase" >&5
3076 echo "${ECHO_T}$cf_cv_mixedcase" >&6
3077 test "$cf_cv_mixedcase" = yes &&
3078 cat >>confdefs.h <<\EOF
3079 #define MIXEDCASE_FILENAMES 1
3080 EOF
3081
3082 for ac_prog in exctags ctags
3083 do
3084 # Extract the first word of "$ac_prog", so it can be a program name with args.
3085 set dummy $ac_prog; ac_word=$2
3086 echo "$as_me:3086: checking for $ac_word" >&5
3087 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3088 if test "${ac_cv_prog_CTAGS+set}" = set; then
3089 echo $ECHO_N "(cached) $ECHO_C" >&6
3090 else
3091 if test -n "$CTAGS"; then
3092 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
3093 else
3094 ac_save_IFS=$IFS; IFS=$ac_path_separator
3095 ac_dummy="$PATH"
3096 for ac_dir in $ac_dummy; do
3097 IFS=$ac_save_IFS
3098 test -z "$ac_dir" && ac_dir=.
3099 $as_executable_p "$ac_dir/$ac_word" || continue
3100 ac_cv_prog_CTAGS="$ac_prog"
3101 echo "$as_me:3101: found $ac_dir/$ac_word" >&5
3102 break
3103 done
3104
3105 fi
3106 fi
3107 CTAGS=$ac_cv_prog_CTAGS
3108 if test -n "$CTAGS"; then
3109 echo "$as_me:3109: result: $CTAGS" >&5
3110 echo "${ECHO_T}$CTAGS" >&6
3111 else
3112 echo "$as_me:3112: result: no" >&5
3113 echo "${ECHO_T}no" >&6
3114 fi
3115
3116 test -n "$CTAGS" && break
3117 done
3118
3119 for ac_prog in exetags etags
3120 do
3121 # Extract the first word of "$ac_prog", so it can be a program name with args.
3122 set dummy $ac_prog; ac_word=$2
3123 echo "$as_me:3123: checking for $ac_word" >&5
3124 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3125 if test "${ac_cv_prog_ETAGS+set}" = set; then
3126 echo $ECHO_N "(cached) $ECHO_C" >&6
3127 else
3128 if test -n "$ETAGS"; then
3129 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
3130 else
3131 ac_save_IFS=$IFS; IFS=$ac_path_separator
3132 ac_dummy="$PATH"
3133 for ac_dir in $ac_dummy; do
3134 IFS=$ac_save_IFS
3135 test -z "$ac_dir" && ac_dir=.
3136 $as_executable_p "$ac_dir/$ac_word" || continue
3137 ac_cv_prog_ETAGS="$ac_prog"
3138 echo "$as_me:3138: found $ac_dir/$ac_word" >&5
3139 break
3140 done
3141
3142 fi
3143 fi
3144 ETAGS=$ac_cv_prog_ETAGS
3145 if test -n "$ETAGS"; then
3146 echo "$as_me:3146: result: $ETAGS" >&5
3147 echo "${ECHO_T}$ETAGS" >&6
3148 else
3149 echo "$as_me:3149: result: no" >&5
3150 echo "${ECHO_T}no" >&6
3151 fi
3152
3153 test -n "$ETAGS" && break
3154 done
3155
3156 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
3157 set dummy ${CTAGS:-ctags}; ac_word=$2
3158 echo "$as_me:3158: checking for $ac_word" >&5
3159 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3160 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
3161 echo $ECHO_N "(cached) $ECHO_C" >&6
3162 else
3163 if test -n "$MAKE_LOWER_TAGS"; then
3164 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
3165 else
3166 ac_save_IFS=$IFS; IFS=$ac_path_separator
3167 ac_dummy="$PATH"
3168 for ac_dir in $ac_dummy; do
3169 IFS=$ac_save_IFS
3170 test -z "$ac_dir" && ac_dir=.
3171 $as_executable_p "$ac_dir/$ac_word" || continue
3172 ac_cv_prog_MAKE_LOWER_TAGS="yes"
3173 echo "$as_me:3173: found $ac_dir/$ac_word" >&5
3174 break
3175 done
3176
3177 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
3178 fi
3179 fi
3180 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
3181 if test -n "$MAKE_LOWER_TAGS"; then
3182 echo "$as_me:3182: result: $MAKE_LOWER_TAGS" >&5
3183 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
3184 else
3185 echo "$as_me:3185: result: no" >&5
3186 echo "${ECHO_T}no" >&6
3187 fi
3188
3189 if test "$cf_cv_mixedcase" = yes ; then
3190 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
3191 set dummy ${ETAGS:-etags}; ac_word=$2
3192 echo "$as_me:3192: checking for $ac_word" >&5
3193 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3194 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
3195 echo $ECHO_N "(cached) $ECHO_C" >&6
3196 else
3197 if test -n "$MAKE_UPPER_TAGS"; then
3198 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
3199 else
3200 ac_save_IFS=$IFS; IFS=$ac_path_separator
3201 ac_dummy="$PATH"
3202 for ac_dir in $ac_dummy; do
3203 IFS=$ac_save_IFS
3204 test -z "$ac_dir" && ac_dir=.
3205 $as_executable_p "$ac_dir/$ac_word" || continue
3206 ac_cv_prog_MAKE_UPPER_TAGS="yes"
3207 echo "$as_me:3207: found $ac_dir/$ac_word" >&5
3208 break
3209 done
3210
3211 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
3212 fi
3213 fi
3214 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
3215 if test -n "$MAKE_UPPER_TAGS"; then
3216 echo "$as_me:3216: result: $MAKE_UPPER_TAGS" >&5
3217 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
3218 else
3219 echo "$as_me:3219: result: no" >&5
3220 echo "${ECHO_T}no" >&6
3221 fi
3222
3223 else
3224 MAKE_UPPER_TAGS=no
3225 fi
3226
3227 if test "$MAKE_UPPER_TAGS" = yes ; then
3228 MAKE_UPPER_TAGS=
3229 else
3230 MAKE_UPPER_TAGS="#"
3231 fi
3232
3233 if test "$MAKE_LOWER_TAGS" = yes ; then
3234 MAKE_LOWER_TAGS=
3235 else
3236 MAKE_LOWER_TAGS="#"
3237 fi
3238
3239 echo "$as_me:3239: checking if the POSIX test-macros are already defined" >&5
3240 echo $ECHO_N "checking if the POSIX test-macros are already defined... $ECHO_C" >&6
3241 if test "${cf_cv_posix_visible+set}" = set; then
3242 echo $ECHO_N "(cached) $ECHO_C" >&6
3243 else
3244
3245 cat >"conftest.$ac_ext" <<_ACEOF
3246 #line 3246 "configure"
3247 #include "confdefs.h"
3248 #include <stdio.h>
3249 int
3250 main (void)
3251 {
3252
3253 #if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
3254 && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
3255 && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
3256 && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
3257 #error conflicting symbols found
3258 #endif
3259
3260 ;
3261 return 0;
3262 }
3263 _ACEOF
3264 rm -f "conftest.$ac_objext"
3265 if { (eval echo "$as_me:3265: \"$ac_compile\"") >&5
3266 (eval $ac_compile) 2>&5
3267 ac_status=$?
3268 echo "$as_me:3268: \$? = $ac_status" >&5
3269 (exit "$ac_status"); } &&
3270 { ac_try='test -s "conftest.$ac_objext"'
3271 { (eval echo "$as_me:3271: \"$ac_try\"") >&5
3272 (eval $ac_try) 2>&5
3273 ac_status=$?
3274 echo "$as_me:3274: \$? = $ac_status" >&5
3275 (exit "$ac_status"); }; }; then
3276 cf_cv_posix_visible=no
3277 else
3278 echo "$as_me: failed program was:" >&5
3279 cat "conftest.$ac_ext" >&5
3280 cf_cv_posix_visible=yes
3281 fi
3282 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3283
3284 fi
3285 echo "$as_me:3285: result: $cf_cv_posix_visible" >&5
3286 echo "${ECHO_T}$cf_cv_posix_visible" >&6
3287
3288 if test "$cf_cv_posix_visible" = no; then
3289
3290 cf_XOPEN_SOURCE=500
3291 cf_POSIX_C_SOURCE=199506L
3292 cf_xopen_source=
3293
3294 case "$host_os" in
3295 (aix[4-7]*)
3296 cf_xopen_source="-D_ALL_SOURCE"
3297 ;;
3298 (darwin[0-8].*)
3299 cf_xopen_source="-D_APPLE_C_SOURCE"
3300 ;;
3301 (darwin*)
3302 cf_xopen_source="-D_DARWIN_C_SOURCE"
3303 cf_XOPEN_SOURCE=
3304 ;;
3305 (freebsd*|dragonfly*|midnightbsd*)
3306 # 5.x headers associate
3307 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
3308 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
3309 cf_POSIX_C_SOURCE=200112L
3310 cf_XOPEN_SOURCE=600
3311 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3312 ;;
3313 (hpux11*)
3314 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
3315 ;;
3316 (hpux*)
3317 cf_xopen_source="-D_HPUX_SOURCE"
3318 ;;
3319 (irix[56].*)
3320 cf_xopen_source="-D_SGI_SOURCE"
3321 cf_XOPEN_SOURCE=
3322 ;;
3323 (linux*gnu*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin|msys|mingw*|linux*uclibc)
3324
3325 cf_gnu_xopen_source=$cf_XOPEN_SOURCE
3326
3327 echo "$as_me:3327: checking if this is the GNU C library" >&5
3328 echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
3329 if test "${cf_cv_gnu_library+set}" = set; then
3330 echo $ECHO_N "(cached) $ECHO_C" >&6
3331 else
3332
3333 cat >"conftest.$ac_ext" <<_ACEOF
3334 #line 3334 "configure"
3335 #include "confdefs.h"
3336 #include <sys/types.h>
3337 int
3338 main (void)
3339 {
3340
3341 #if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
3342 return 0;
3343 #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
3344 return 0;
3345 #else
3346 # error not GNU C library
3347 #endif
3348 ;
3349 return 0;
3350 }
3351 _ACEOF
3352 rm -f "conftest.$ac_objext"
3353 if { (eval echo "$as_me:3353: \"$ac_compile\"") >&5
3354 (eval $ac_compile) 2>&5
3355 ac_status=$?
3356 echo "$as_me:3356: \$? = $ac_status" >&5
3357 (exit "$ac_status"); } &&
3358 { ac_try='test -s "conftest.$ac_objext"'
3359 { (eval echo "$as_me:3359: \"$ac_try\"") >&5
3360 (eval $ac_try) 2>&5
3361 ac_status=$?
3362 echo "$as_me:3362: \$? = $ac_status" >&5
3363 (exit "$ac_status"); }; }; then
3364 cf_cv_gnu_library=yes
3365 else
3366 echo "$as_me: failed program was:" >&5
3367 cat "conftest.$ac_ext" >&5
3368 cf_cv_gnu_library=no
3369 fi
3370 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3371
3372 fi
3373 echo "$as_me:3373: result: $cf_cv_gnu_library" >&5
3374 echo "${ECHO_T}$cf_cv_gnu_library" >&6
3375
3376 if test x$cf_cv_gnu_library = xyes; then
3377
3378 # With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
3379 # was changed to help a little. newlib incorporated the change about 4
3380 # years later.
3381 echo "$as_me:3381: checking if _DEFAULT_SOURCE can be used as a basis" >&5
3382 echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
3383 if test "${cf_cv_gnu_library_219+set}" = set; then
3384 echo $ECHO_N "(cached) $ECHO_C" >&6
3385 else
3386
3387 cf_save="$CPPFLAGS"
3388
3389 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3390 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3391
3392 cat >"conftest.$ac_ext" <<_ACEOF
3393 #line 3393 "configure"
3394 #include "confdefs.h"
3395 #include <sys/types.h>
3396 int
3397 main (void)
3398 {
3399
3400 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
3401 return 0;
3402 #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
3403 return 0;
3404 #else
3405 # error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
3406 #endif
3407 ;
3408 return 0;
3409 }
3410 _ACEOF
3411 rm -f "conftest.$ac_objext"
3412 if { (eval echo "$as_me:3412: \"$ac_compile\"") >&5
3413 (eval $ac_compile) 2>&5
3414 ac_status=$?
3415 echo "$as_me:3415: \$? = $ac_status" >&5
3416 (exit "$ac_status"); } &&
3417 { ac_try='test -s "conftest.$ac_objext"'
3418 { (eval echo "$as_me:3418: \"$ac_try\"") >&5
3419 (eval $ac_try) 2>&5
3420 ac_status=$?
3421 echo "$as_me:3421: \$? = $ac_status" >&5
3422 (exit "$ac_status"); }; }; then
3423 cf_cv_gnu_library_219=yes
3424 else
3425 echo "$as_me: failed program was:" >&5
3426 cat "conftest.$ac_ext" >&5
3427 cf_cv_gnu_library_219=no
3428 fi
3429 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3430 CPPFLAGS="$cf_save"
3431
3432 fi
3433 echo "$as_me:3433: result: $cf_cv_gnu_library_219" >&5
3434 echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
3435
3436 if test "x$cf_cv_gnu_library_219" = xyes; then
3437 cf_save="$CPPFLAGS"
3438 echo "$as_me:3438: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
3439 echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
3440 if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
3441 echo $ECHO_N "(cached) $ECHO_C" >&6
3442 else
3443
3444 cf_fix_cppflags=no
3445 cf_new_cflags=
3446 cf_new_cppflags=
3447 cf_new_extra_cppflags=
3448
3449 for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
3450 do
3451 case "$cf_fix_cppflags" in
3452 (no)
3453 case "$cf_add_cflags" in
3454 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3455 case "$cf_add_cflags" in
3456 (-D*)
3457 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3458
3459 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3460 && test -z "${cf_tst_cflags}" \
3461 && cf_fix_cppflags=yes
3462
3463 if test "$cf_fix_cppflags" = yes ; then
3464
3465 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3466 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3467
3468 continue
3469 elif test "${cf_tst_cflags}" = "\"'" ; then
3470
3471 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3472 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3473
3474 continue
3475 fi
3476 ;;
3477 esac
3478 case "$CPPFLAGS" in
3479 (*$cf_add_cflags)
3480 ;;
3481 (*)
3482 case "$cf_add_cflags" in
3483 (-D*)
3484 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3485
3486 CPPFLAGS=`echo "$CPPFLAGS" | \
3487 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3488 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3489
3490 ;;
3491 esac
3492
3493 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3494 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3495
3496 ;;
3497 esac
3498 ;;
3499 (*)
3500
3501 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3502 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3503
3504 ;;
3505 esac
3506 ;;
3507 (yes)
3508
3509 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3510 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3511
3512 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
3513
3514 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3515 && test -z "${cf_tst_cflags}" \
3516 && cf_fix_cppflags=no
3517 ;;
3518 esac
3519 done
3520
3521 if test -n "$cf_new_cflags" ; then
3522
3523 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3524 CFLAGS="${CFLAGS}$cf_new_cflags"
3525
3526 fi
3527
3528 if test -n "$cf_new_cppflags" ; then
3529
3530 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3531 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3532
3533 fi
3534
3535 if test -n "$cf_new_extra_cppflags" ; then
3536
3537 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3538 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3539
3540 fi
3541
3542 cat >"conftest.$ac_ext" <<_ACEOF
3543 #line 3543 "configure"
3544 #include "confdefs.h"
3545
3546 #include <limits.h>
3547 #include <sys/types.h>
3548
3549 int
3550 main (void)
3551 {
3552
3553 #if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
3554 return 0;
3555 #else
3556 # error GNU C library is too old
3557 #endif
3558 ;
3559 return 0;
3560 }
3561 _ACEOF
3562 rm -f "conftest.$ac_objext"
3563 if { (eval echo "$as_me:3563: \"$ac_compile\"") >&5
3564 (eval $ac_compile) 2>&5
3565 ac_status=$?
3566 echo "$as_me:3566: \$? = $ac_status" >&5
3567 (exit "$ac_status"); } &&
3568 { ac_try='test -s "conftest.$ac_objext"'
3569 { (eval echo "$as_me:3569: \"$ac_try\"") >&5
3570 (eval $ac_try) 2>&5
3571 ac_status=$?
3572 echo "$as_me:3572: \$? = $ac_status" >&5
3573 (exit "$ac_status"); }; }; then
3574 cf_cv_gnu_dftsrc_219=yes
3575 else
3576 echo "$as_me: failed program was:" >&5
3577 cat "conftest.$ac_ext" >&5
3578 cf_cv_gnu_dftsrc_219=no
3579 fi
3580 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3581
3582 fi
3583 echo "$as_me:3583: result: $cf_cv_gnu_dftsrc_219" >&5
3584 echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
3585 test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
3586 else
3587 cf_cv_gnu_dftsrc_219=maybe
3588 fi
3589
3590 if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
3591
3592 echo "$as_me:3592: checking if we must define _GNU_SOURCE" >&5
3593 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
3594 if test "${cf_cv_gnu_source+set}" = set; then
3595 echo $ECHO_N "(cached) $ECHO_C" >&6
3596 else
3597
3598 cat >"conftest.$ac_ext" <<_ACEOF
3599 #line 3599 "configure"
3600 #include "confdefs.h"
3601 #include <sys/types.h>
3602 int
3603 main (void)
3604 {
3605
3606 #ifndef _XOPEN_SOURCE
3607 #error expected _XOPEN_SOURCE to be defined
3608 #endif
3609 ;
3610 return 0;
3611 }
3612 _ACEOF
3613 rm -f "conftest.$ac_objext"
3614 if { (eval echo "$as_me:3614: \"$ac_compile\"") >&5
3615 (eval $ac_compile) 2>&5
3616 ac_status=$?
3617 echo "$as_me:3617: \$? = $ac_status" >&5
3618 (exit "$ac_status"); } &&
3619 { ac_try='test -s "conftest.$ac_objext"'
3620 { (eval echo "$as_me:3620: \"$ac_try\"") >&5
3621 (eval $ac_try) 2>&5
3622 ac_status=$?
3623 echo "$as_me:3623: \$? = $ac_status" >&5
3624 (exit "$ac_status"); }; }; then
3625 cf_cv_gnu_source=no
3626 else
3627 echo "$as_me: failed program was:" >&5
3628 cat "conftest.$ac_ext" >&5
3629 cf_save="$CPPFLAGS"
3630
3631 cf_fix_cppflags=no
3632 cf_new_cflags=
3633 cf_new_cppflags=
3634 cf_new_extra_cppflags=
3635
3636 for cf_add_cflags in -D_GNU_SOURCE
3637 do
3638 case "$cf_fix_cppflags" in
3639 (no)
3640 case "$cf_add_cflags" in
3641 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3642 case "$cf_add_cflags" in
3643 (-D*)
3644 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3645
3646 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3647 && test -z "${cf_tst_cflags}" \
3648 && cf_fix_cppflags=yes
3649
3650 if test "$cf_fix_cppflags" = yes ; then
3651
3652 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3653 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3654
3655 continue
3656 elif test "${cf_tst_cflags}" = "\"'" ; then
3657
3658 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3659 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3660
3661 continue
3662 fi
3663 ;;
3664 esac
3665 case "$CPPFLAGS" in
3666 (*$cf_add_cflags)
3667 ;;
3668 (*)
3669 case "$cf_add_cflags" in
3670 (-D*)
3671 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3672
3673 CPPFLAGS=`echo "$CPPFLAGS" | \
3674 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3675 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3676
3677 ;;
3678 esac
3679
3680 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3681 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3682
3683 ;;
3684 esac
3685 ;;
3686 (*)
3687
3688 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3689 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3690
3691 ;;
3692 esac
3693 ;;
3694 (yes)
3695
3696 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3697 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3698
3699 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
3700
3701 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3702 && test -z "${cf_tst_cflags}" \
3703 && cf_fix_cppflags=no
3704 ;;
3705 esac
3706 done
3707
3708 if test -n "$cf_new_cflags" ; then
3709
3710 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3711 CFLAGS="${CFLAGS}$cf_new_cflags"
3712
3713 fi
3714
3715 if test -n "$cf_new_cppflags" ; then
3716
3717 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3718 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3719
3720 fi
3721
3722 if test -n "$cf_new_extra_cppflags" ; then
3723
3724 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3725 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3726
3727 fi
3728
3729 cat >"conftest.$ac_ext" <<_ACEOF
3730 #line 3730 "configure"
3731 #include "confdefs.h"
3732 #include <sys/types.h>
3733 int
3734 main (void)
3735 {
3736
3737 #ifdef _XOPEN_SOURCE
3738 #error expected _XOPEN_SOURCE to be undefined
3739 #endif
3740 ;
3741 return 0;
3742 }
3743 _ACEOF
3744 rm -f "conftest.$ac_objext"
3745 if { (eval echo "$as_me:3745: \"$ac_compile\"") >&5
3746 (eval $ac_compile) 2>&5
3747 ac_status=$?
3748 echo "$as_me:3748: \$? = $ac_status" >&5
3749 (exit "$ac_status"); } &&
3750 { ac_try='test -s "conftest.$ac_objext"'
3751 { (eval echo "$as_me:3751: \"$ac_try\"") >&5
3752 (eval $ac_try) 2>&5
3753 ac_status=$?
3754 echo "$as_me:3754: \$? = $ac_status" >&5
3755 (exit "$ac_status"); }; }; then
3756 cf_cv_gnu_source=no
3757 else
3758 echo "$as_me: failed program was:" >&5
3759 cat "conftest.$ac_ext" >&5
3760 cf_cv_gnu_source=yes
3761 fi
3762 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3763 CPPFLAGS="$cf_save"
3764
3765 fi
3766 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3767
3768 fi
3769 echo "$as_me:3769: result: $cf_cv_gnu_source" >&5
3770 echo "${ECHO_T}$cf_cv_gnu_source" >&6
3771
3772 if test "$cf_cv_gnu_source" = yes
3773 then
3774 echo "$as_me:3774: checking if we should also define _DEFAULT_SOURCE" >&5
3775 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
3776 if test "${cf_cv_default_source+set}" = set; then
3777 echo $ECHO_N "(cached) $ECHO_C" >&6
3778 else
3779
3780 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3781 CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
3782
3783 cat >"conftest.$ac_ext" <<_ACEOF
3784 #line 3784 "configure"
3785 #include "confdefs.h"
3786 #include <sys/types.h>
3787 int
3788 main (void)
3789 {
3790
3791 #ifdef _DEFAULT_SOURCE
3792 #error expected _DEFAULT_SOURCE to be undefined
3793 #endif
3794 ;
3795 return 0;
3796 }
3797 _ACEOF
3798 rm -f "conftest.$ac_objext"
3799 if { (eval echo "$as_me:3799: \"$ac_compile\"") >&5
3800 (eval $ac_compile) 2>&5
3801 ac_status=$?
3802 echo "$as_me:3802: \$? = $ac_status" >&5
3803 (exit "$ac_status"); } &&
3804 { ac_try='test -s "conftest.$ac_objext"'
3805 { (eval echo "$as_me:3805: \"$ac_try\"") >&5
3806 (eval $ac_try) 2>&5
3807 ac_status=$?
3808 echo "$as_me:3808: \$? = $ac_status" >&5
3809 (exit "$ac_status"); }; }; then
3810 cf_cv_default_source=no
3811 else
3812 echo "$as_me: failed program was:" >&5
3813 cat "conftest.$ac_ext" >&5
3814 cf_cv_default_source=yes
3815 fi
3816 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3817
3818 fi
3819 echo "$as_me:3819: result: $cf_cv_default_source" >&5
3820 echo "${ECHO_T}$cf_cv_default_source" >&6
3821 if test "$cf_cv_default_source" = yes
3822 then
3823
3824 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3825 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3826
3827 fi
3828 fi
3829 fi
3830
3831 fi
3832
3833 ;;
3834 linux*musl)
3835 cf_xopen_source="-D_BSD_SOURCE"
3836 ;;
3837 (minix*)
3838 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
3839 ;;
3840 (mirbsd*)
3841 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
3842 cf_XOPEN_SOURCE=
3843
3844 if test "$cf_cv_posix_visible" = no; then
3845
3846 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3847
3848 cf_save_CFLAGS="$CFLAGS"
3849 cf_save_CPPFLAGS="$CPPFLAGS"
3850
3851 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3852 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3853 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3854
3855 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3856 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3857 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3858
3859 echo "$as_me:3859: checking if we should define _POSIX_C_SOURCE" >&5
3860 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3861 if test "${cf_cv_posix_c_source+set}" = set; then
3862 echo $ECHO_N "(cached) $ECHO_C" >&6
3863 else
3864
3865 echo "${as_me:-configure}:3865: testing if the symbol is already defined go no further ..." 1>&5
3866
3867 cat >"conftest.$ac_ext" <<_ACEOF
3868 #line 3868 "configure"
3869 #include "confdefs.h"
3870 #include <sys/types.h>
3871 int
3872 main (void)
3873 {
3874
3875 #ifndef _POSIX_C_SOURCE
3876 #error _POSIX_C_SOURCE is not defined
3877 #endif
3878 ;
3879 return 0;
3880 }
3881 _ACEOF
3882 rm -f "conftest.$ac_objext"
3883 if { (eval echo "$as_me:3883: \"$ac_compile\"") >&5
3884 (eval $ac_compile) 2>&5
3885 ac_status=$?
3886 echo "$as_me:3886: \$? = $ac_status" >&5
3887 (exit "$ac_status"); } &&
3888 { ac_try='test -s "conftest.$ac_objext"'
3889 { (eval echo "$as_me:3889: \"$ac_try\"") >&5
3890 (eval $ac_try) 2>&5
3891 ac_status=$?
3892 echo "$as_me:3892: \$? = $ac_status" >&5
3893 (exit "$ac_status"); }; }; then
3894 cf_cv_posix_c_source=no
3895 else
3896 echo "$as_me: failed program was:" >&5
3897 cat "conftest.$ac_ext" >&5
3898 cf_want_posix_source=no
3899 case .$cf_POSIX_C_SOURCE in
3900 (.[12]??*)
3901 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3902 ;;
3903 (.2)
3904 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3905 cf_want_posix_source=yes
3906 ;;
3907 (.*)
3908 cf_want_posix_source=yes
3909 ;;
3910 esac
3911 if test "$cf_want_posix_source" = yes ; then
3912 cat >"conftest.$ac_ext" <<_ACEOF
3913 #line 3913 "configure"
3914 #include "confdefs.h"
3915 #include <sys/types.h>
3916 int
3917 main (void)
3918 {
3919
3920 #ifdef _POSIX_SOURCE
3921 #error _POSIX_SOURCE is defined
3922 #endif
3923 ;
3924 return 0;
3925 }
3926 _ACEOF
3927 rm -f "conftest.$ac_objext"
3928 if { (eval echo "$as_me:3928: \"$ac_compile\"") >&5
3929 (eval $ac_compile) 2>&5
3930 ac_status=$?
3931 echo "$as_me:3931: \$? = $ac_status" >&5
3932 (exit "$ac_status"); } &&
3933 { ac_try='test -s "conftest.$ac_objext"'
3934 { (eval echo "$as_me:3934: \"$ac_try\"") >&5
3935 (eval $ac_try) 2>&5
3936 ac_status=$?
3937 echo "$as_me:3937: \$? = $ac_status" >&5
3938 (exit "$ac_status"); }; }; then
3939 :
3940 else
3941 echo "$as_me: failed program was:" >&5
3942 cat "conftest.$ac_ext" >&5
3943 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3944 fi
3945 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3946 fi
3947
3948 echo "${as_me:-configure}:3948: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3949
3950 CFLAGS="$cf_trim_CFLAGS"
3951 CPPFLAGS="$cf_trim_CPPFLAGS"
3952
3953 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3954 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
3955
3956 echo "${as_me:-configure}:3956: testing if the second compile does not leave our definition intact error ..." 1>&5
3957
3958 cat >"conftest.$ac_ext" <<_ACEOF
3959 #line 3959 "configure"
3960 #include "confdefs.h"
3961 #include <sys/types.h>
3962 int
3963 main (void)
3964 {
3965
3966 #ifndef _POSIX_C_SOURCE
3967 #error _POSIX_C_SOURCE is not defined
3968 #endif
3969 ;
3970 return 0;
3971 }
3972 _ACEOF
3973 rm -f "conftest.$ac_objext"
3974 if { (eval echo "$as_me:3974: \"$ac_compile\"") >&5
3975 (eval $ac_compile) 2>&5
3976 ac_status=$?
3977 echo "$as_me:3977: \$? = $ac_status" >&5
3978 (exit "$ac_status"); } &&
3979 { ac_try='test -s "conftest.$ac_objext"'
3980 { (eval echo "$as_me:3980: \"$ac_try\"") >&5
3981 (eval $ac_try) 2>&5
3982 ac_status=$?
3983 echo "$as_me:3983: \$? = $ac_status" >&5
3984 (exit "$ac_status"); }; }; then
3985 :
3986 else
3987 echo "$as_me: failed program was:" >&5
3988 cat "conftest.$ac_ext" >&5
3989 cf_cv_posix_c_source=no
3990 fi
3991 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3992 CFLAGS="$cf_save_CFLAGS"
3993 CPPFLAGS="$cf_save_CPPFLAGS"
3994
3995 fi
3996 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3997
3998 fi
3999 echo "$as_me:3999: result: $cf_cv_posix_c_source" >&5
4000 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4001
4002 if test "$cf_cv_posix_c_source" != no ; then
4003 CFLAGS="$cf_trim_CFLAGS"
4004 CPPFLAGS="$cf_trim_CPPFLAGS"
4005
4006 cf_fix_cppflags=no
4007 cf_new_cflags=
4008 cf_new_cppflags=
4009 cf_new_extra_cppflags=
4010
4011 for cf_add_cflags in $cf_cv_posix_c_source
4012 do
4013 case "$cf_fix_cppflags" in
4014 (no)
4015 case "$cf_add_cflags" in
4016 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4017 case "$cf_add_cflags" in
4018 (-D*)
4019 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4020
4021 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4022 && test -z "${cf_tst_cflags}" \
4023 && cf_fix_cppflags=yes
4024
4025 if test "$cf_fix_cppflags" = yes ; then
4026
4027 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4028 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4029
4030 continue
4031 elif test "${cf_tst_cflags}" = "\"'" ; then
4032
4033 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4034 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4035
4036 continue
4037 fi
4038 ;;
4039 esac
4040 case "$CPPFLAGS" in
4041 (*$cf_add_cflags)
4042 ;;
4043 (*)
4044 case "$cf_add_cflags" in
4045 (-D*)
4046 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4047
4048 CPPFLAGS=`echo "$CPPFLAGS" | \
4049 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4050 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4051
4052 ;;
4053 esac
4054
4055 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4056 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4057
4058 ;;
4059 esac
4060 ;;
4061 (*)
4062
4063 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4064 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4065
4066 ;;
4067 esac
4068 ;;
4069 (yes)
4070
4071 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4072 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4073
4074 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4075
4076 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4077 && test -z "${cf_tst_cflags}" \
4078 && cf_fix_cppflags=no
4079 ;;
4080 esac
4081 done
4082
4083 if test -n "$cf_new_cflags" ; then
4084
4085 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4086 CFLAGS="${CFLAGS}$cf_new_cflags"
4087
4088 fi
4089
4090 if test -n "$cf_new_cppflags" ; then
4091
4092 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4093 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4094
4095 fi
4096
4097 if test -n "$cf_new_extra_cppflags" ; then
4098
4099 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4100 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4101
4102 fi
4103
4104 fi
4105
4106 fi # cf_cv_posix_visible
4107
4108 ;;
4109 (netbsd*)
4110 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
4111 ;;
4112 (openbsd[6-9]*)
4113 # OpenBSD 6.x has broken locale support, both compile-time and runtime.
4114 # see https://www.mail-archive.com/[email protected]/msg13200.html
4115 # Abusing the conformance level is a workaround.
4116 { echo "$as_me:4116: WARNING: this system does not provide usable locale support" >&5
4117 echo "$as_me: WARNING: this system does not provide usable locale support" >&2;}
4118 cf_xopen_source="-D_BSD_SOURCE"
4119 cf_XOPEN_SOURCE=700
4120 ;;
4121 (openbsd[4-5]*)
4122 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
4123 cf_xopen_source="-D_BSD_SOURCE"
4124 cf_XOPEN_SOURCE=600
4125 ;;
4126 (openbsd*)
4127 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
4128 ;;
4129 (osf[45]*)
4130 cf_xopen_source="-D_OSF_SOURCE"
4131 ;;
4132 (nto-qnx*)
4133 cf_xopen_source="-D_QNX_SOURCE"
4134 ;;
4135 (sco*)
4136 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
4137 ;;
4138 (solaris2.*)
4139 cf_xopen_source="-D__EXTENSIONS__"
4140 cf_cv_xopen_source=broken
4141 ;;
4142 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
4143 cf_XOPEN_SOURCE=
4144 cf_POSIX_C_SOURCE=
4145 ;;
4146 (*)
4147
4148 echo "$as_me:4148: checking if we should define _XOPEN_SOURCE" >&5
4149 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4150 if test "${cf_cv_xopen_source+set}" = set; then
4151 echo $ECHO_N "(cached) $ECHO_C" >&6
4152 else
4153
4154 cat >"conftest.$ac_ext" <<_ACEOF
4155 #line 4155 "configure"
4156 #include "confdefs.h"
4157
4158 $ac_includes_default
4159
4160 int
4161 main (void)
4162 {
4163
4164 #ifndef _XOPEN_SOURCE
4165 #error _XOPEN_SOURCE is not defined
4166 #endif
4167
4168 ;
4169 return 0;
4170 }
4171 _ACEOF
4172 rm -f "conftest.$ac_objext"
4173 if { (eval echo "$as_me:4173: \"$ac_compile\"") >&5
4174 (eval $ac_compile) 2>&5
4175 ac_status=$?
4176 echo "$as_me:4176: \$? = $ac_status" >&5
4177 (exit "$ac_status"); } &&
4178 { ac_try='test -s "conftest.$ac_objext"'
4179 { (eval echo "$as_me:4179: \"$ac_try\"") >&5
4180 (eval $ac_try) 2>&5
4181 ac_status=$?
4182 echo "$as_me:4182: \$? = $ac_status" >&5
4183 (exit "$ac_status"); }; }; then
4184 cf_cv_xopen_source=no
4185 else
4186 echo "$as_me: failed program was:" >&5
4187 cat "conftest.$ac_ext" >&5
4188 cf_save="$CPPFLAGS"
4189
4190 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4191 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4192
4193 cat >"conftest.$ac_ext" <<_ACEOF
4194 #line 4194 "configure"
4195 #include "confdefs.h"
4196
4197 $ac_includes_default
4198
4199 int
4200 main (void)
4201 {
4202
4203 #ifndef _XOPEN_SOURCE
4204 #error _XOPEN_SOURCE is not defined
4205 #endif
4206
4207 ;
4208 return 0;
4209 }
4210 _ACEOF
4211 rm -f "conftest.$ac_objext"
4212 if { (eval echo "$as_me:4212: \"$ac_compile\"") >&5
4213 (eval $ac_compile) 2>&5
4214 ac_status=$?
4215 echo "$as_me:4215: \$? = $ac_status" >&5
4216 (exit "$ac_status"); } &&
4217 { ac_try='test -s "conftest.$ac_objext"'
4218 { (eval echo "$as_me:4218: \"$ac_try\"") >&5
4219 (eval $ac_try) 2>&5
4220 ac_status=$?
4221 echo "$as_me:4221: \$? = $ac_status" >&5
4222 (exit "$ac_status"); }; }; then
4223 cf_cv_xopen_source=no
4224 else
4225 echo "$as_me: failed program was:" >&5
4226 cat "conftest.$ac_ext" >&5
4227 cf_cv_xopen_source=$cf_XOPEN_SOURCE
4228 fi
4229 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4230 CPPFLAGS="$cf_save"
4231
4232 fi
4233 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4234
4235 fi
4236 echo "$as_me:4236: result: $cf_cv_xopen_source" >&5
4237 echo "${ECHO_T}$cf_cv_xopen_source" >&6
4238
4239 if test "$cf_cv_xopen_source" != no ; then
4240
4241 CFLAGS=`echo "$CFLAGS" | \
4242 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4243 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4244
4245 CPPFLAGS=`echo "$CPPFLAGS" | \
4246 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4247 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4248
4249 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4250
4251 for cf_add_cflags in $cf_temp_xopen_source
4252 do
4253 case "x$cf_add_cflags" in
4254 (x-[DU]*)
4255
4256 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4257 while true
4258 do
4259 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
4260 test "$CFLAGS" != "$cf_old_cflag" || break
4261
4262 CFLAGS="$cf_old_cflag"
4263 done
4264
4265 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4266 while true
4267 do
4268 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
4269 test "$CPPFLAGS" != "$cf_old_cflag" || break
4270
4271 CPPFLAGS="$cf_old_cflag"
4272 done
4273
4274 ;;
4275 esac
4276
4277 cf_fix_cppflags=no
4278 cf_new_cflags=
4279 cf_new_cppflags=
4280 cf_new_extra_cppflags=
4281
4282 for cf_add_cflags in $cf_add_cflags
4283 do
4284 case "$cf_fix_cppflags" in
4285 (no)
4286 case "$cf_add_cflags" in
4287 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4288 case "$cf_add_cflags" in
4289 (-D*)
4290 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4291
4292 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4293 && test -z "${cf_tst_cflags}" \
4294 && cf_fix_cppflags=yes
4295
4296 if test "$cf_fix_cppflags" = yes ; then
4297
4298 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4299 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4300
4301 continue
4302 elif test "${cf_tst_cflags}" = "\"'" ; then
4303
4304 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4305 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4306
4307 continue
4308 fi
4309 ;;
4310 esac
4311 case "$CPPFLAGS" in
4312 (*$cf_add_cflags)
4313 ;;
4314 (*)
4315 case "$cf_add_cflags" in
4316 (-D*)
4317 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4318
4319 CPPFLAGS=`echo "$CPPFLAGS" | \
4320 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4321 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4322
4323 ;;
4324 esac
4325
4326 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4327 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4328
4329 ;;
4330 esac
4331 ;;
4332 (*)
4333
4334 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4335 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4336
4337 ;;
4338 esac
4339 ;;
4340 (yes)
4341
4342 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4343 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4344
4345 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4346
4347 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4348 && test -z "${cf_tst_cflags}" \
4349 && cf_fix_cppflags=no
4350 ;;
4351 esac
4352 done
4353
4354 if test -n "$cf_new_cflags" ; then
4355
4356 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4357 CFLAGS="${CFLAGS}$cf_new_cflags"
4358
4359 fi
4360
4361 if test -n "$cf_new_cppflags" ; then
4362
4363 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4364 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4365
4366 fi
4367
4368 if test -n "$cf_new_extra_cppflags" ; then
4369
4370 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4371 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4372
4373 fi
4374
4375 done
4376
4377 fi
4378
4379 cf_save_xopen_cppflags="$CPPFLAGS"
4380
4381 if test "$cf_cv_posix_visible" = no; then
4382
4383 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4384
4385 cf_save_CFLAGS="$CFLAGS"
4386 cf_save_CPPFLAGS="$CPPFLAGS"
4387
4388 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4389 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4390 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4391
4392 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4393 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4394 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4395
4396 echo "$as_me:4396: checking if we should define _POSIX_C_SOURCE" >&5
4397 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4398 if test "${cf_cv_posix_c_source+set}" = set; then
4399 echo $ECHO_N "(cached) $ECHO_C" >&6
4400 else
4401
4402 echo "${as_me:-configure}:4402: testing if the symbol is already defined go no further ..." 1>&5
4403
4404 cat >"conftest.$ac_ext" <<_ACEOF
4405 #line 4405 "configure"
4406 #include "confdefs.h"
4407 #include <sys/types.h>
4408 int
4409 main (void)
4410 {
4411
4412 #ifndef _POSIX_C_SOURCE
4413 #error _POSIX_C_SOURCE is not defined
4414 #endif
4415 ;
4416 return 0;
4417 }
4418 _ACEOF
4419 rm -f "conftest.$ac_objext"
4420 if { (eval echo "$as_me:4420: \"$ac_compile\"") >&5
4421 (eval $ac_compile) 2>&5
4422 ac_status=$?
4423 echo "$as_me:4423: \$? = $ac_status" >&5
4424 (exit "$ac_status"); } &&
4425 { ac_try='test -s "conftest.$ac_objext"'
4426 { (eval echo "$as_me:4426: \"$ac_try\"") >&5
4427 (eval $ac_try) 2>&5
4428 ac_status=$?
4429 echo "$as_me:4429: \$? = $ac_status" >&5
4430 (exit "$ac_status"); }; }; then
4431 cf_cv_posix_c_source=no
4432 else
4433 echo "$as_me: failed program was:" >&5
4434 cat "conftest.$ac_ext" >&5
4435 cf_want_posix_source=no
4436 case .$cf_POSIX_C_SOURCE in
4437 (.[12]??*)
4438 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4439 ;;
4440 (.2)
4441 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4442 cf_want_posix_source=yes
4443 ;;
4444 (.*)
4445 cf_want_posix_source=yes
4446 ;;
4447 esac
4448 if test "$cf_want_posix_source" = yes ; then
4449 cat >"conftest.$ac_ext" <<_ACEOF
4450 #line 4450 "configure"
4451 #include "confdefs.h"
4452 #include <sys/types.h>
4453 int
4454 main (void)
4455 {
4456
4457 #ifdef _POSIX_SOURCE
4458 #error _POSIX_SOURCE is defined
4459 #endif
4460 ;
4461 return 0;
4462 }
4463 _ACEOF
4464 rm -f "conftest.$ac_objext"
4465 if { (eval echo "$as_me:4465: \"$ac_compile\"") >&5
4466 (eval $ac_compile) 2>&5
4467 ac_status=$?
4468 echo "$as_me:4468: \$? = $ac_status" >&5
4469 (exit "$ac_status"); } &&
4470 { ac_try='test -s "conftest.$ac_objext"'
4471 { (eval echo "$as_me:4471: \"$ac_try\"") >&5
4472 (eval $ac_try) 2>&5
4473 ac_status=$?
4474 echo "$as_me:4474: \$? = $ac_status" >&5
4475 (exit "$ac_status"); }; }; then
4476 :
4477 else
4478 echo "$as_me: failed program was:" >&5
4479 cat "conftest.$ac_ext" >&5
4480 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4481 fi
4482 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4483 fi
4484
4485 echo "${as_me:-configure}:4485: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4486
4487 CFLAGS="$cf_trim_CFLAGS"
4488 CPPFLAGS="$cf_trim_CPPFLAGS"
4489
4490 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4491 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4492
4493 echo "${as_me:-configure}:4493: testing if the second compile does not leave our definition intact error ..." 1>&5
4494
4495 cat >"conftest.$ac_ext" <<_ACEOF
4496 #line 4496 "configure"
4497 #include "confdefs.h"
4498 #include <sys/types.h>
4499 int
4500 main (void)
4501 {
4502
4503 #ifndef _POSIX_C_SOURCE
4504 #error _POSIX_C_SOURCE is not defined
4505 #endif
4506 ;
4507 return 0;
4508 }
4509 _ACEOF
4510 rm -f "conftest.$ac_objext"
4511 if { (eval echo "$as_me:4511: \"$ac_compile\"") >&5
4512 (eval $ac_compile) 2>&5
4513 ac_status=$?
4514 echo "$as_me:4514: \$? = $ac_status" >&5
4515 (exit "$ac_status"); } &&
4516 { ac_try='test -s "conftest.$ac_objext"'
4517 { (eval echo "$as_me:4517: \"$ac_try\"") >&5
4518 (eval $ac_try) 2>&5
4519 ac_status=$?
4520 echo "$as_me:4520: \$? = $ac_status" >&5
4521 (exit "$ac_status"); }; }; then
4522 :
4523 else
4524 echo "$as_me: failed program was:" >&5
4525 cat "conftest.$ac_ext" >&5
4526 cf_cv_posix_c_source=no
4527 fi
4528 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4529 CFLAGS="$cf_save_CFLAGS"
4530 CPPFLAGS="$cf_save_CPPFLAGS"
4531
4532 fi
4533 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4534
4535 fi
4536 echo "$as_me:4536: result: $cf_cv_posix_c_source" >&5
4537 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4538
4539 if test "$cf_cv_posix_c_source" != no ; then
4540 CFLAGS="$cf_trim_CFLAGS"
4541 CPPFLAGS="$cf_trim_CPPFLAGS"
4542
4543 cf_fix_cppflags=no
4544 cf_new_cflags=
4545 cf_new_cppflags=
4546 cf_new_extra_cppflags=
4547
4548 for cf_add_cflags in $cf_cv_posix_c_source
4549 do
4550 case "$cf_fix_cppflags" in
4551 (no)
4552 case "$cf_add_cflags" in
4553 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4554 case "$cf_add_cflags" in
4555 (-D*)
4556 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4557
4558 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4559 && test -z "${cf_tst_cflags}" \
4560 && cf_fix_cppflags=yes
4561
4562 if test "$cf_fix_cppflags" = yes ; then
4563
4564 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4565 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4566
4567 continue
4568 elif test "${cf_tst_cflags}" = "\"'" ; then
4569
4570 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4571 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4572
4573 continue
4574 fi
4575 ;;
4576 esac
4577 case "$CPPFLAGS" in
4578 (*$cf_add_cflags)
4579 ;;
4580 (*)
4581 case "$cf_add_cflags" in
4582 (-D*)
4583 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4584
4585 CPPFLAGS=`echo "$CPPFLAGS" | \
4586 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4587 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4588
4589 ;;
4590 esac
4591
4592 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4593 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4594
4595 ;;
4596 esac
4597 ;;
4598 (*)
4599
4600 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4601 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4602
4603 ;;
4604 esac
4605 ;;
4606 (yes)
4607
4608 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4609 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4610
4611 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4612
4613 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4614 && test -z "${cf_tst_cflags}" \
4615 && cf_fix_cppflags=no
4616 ;;
4617 esac
4618 done
4619
4620 if test -n "$cf_new_cflags" ; then
4621
4622 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4623 CFLAGS="${CFLAGS}$cf_new_cflags"
4624
4625 fi
4626
4627 if test -n "$cf_new_cppflags" ; then
4628
4629 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4630 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4631
4632 fi
4633
4634 if test -n "$cf_new_extra_cppflags" ; then
4635
4636 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4637 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4638
4639 fi
4640
4641 fi
4642
4643 fi # cf_cv_posix_visible
4644
4645 # Some of these niche implementations use copy/paste, double-check...
4646 if test "$cf_cv_xopen_source" = no ; then
4647 test -n "$verbose" && echo " checking if _POSIX_C_SOURCE interferes with _XOPEN_SOURCE" 1>&6
4648
4649 echo "${as_me:-configure}:4649: testing checking if _POSIX_C_SOURCE interferes with _XOPEN_SOURCE ..." 1>&5
4650
4651 cat >"conftest.$ac_ext" <<_ACEOF
4652 #line 4652 "configure"
4653 #include "confdefs.h"
4654
4655 $ac_includes_default
4656
4657 int
4658 main (void)
4659 {
4660
4661 #ifndef _XOPEN_SOURCE
4662 #error _XOPEN_SOURCE is not defined
4663 #endif
4664
4665 ;
4666 return 0;
4667 }
4668 _ACEOF
4669 rm -f "conftest.$ac_objext"
4670 if { (eval echo "$as_me:4670: \"$ac_compile\"") >&5
4671 (eval $ac_compile) 2>&5
4672 ac_status=$?
4673 echo "$as_me:4673: \$? = $ac_status" >&5
4674 (exit "$ac_status"); } &&
4675 { ac_try='test -s "conftest.$ac_objext"'
4676 { (eval echo "$as_me:4676: \"$ac_try\"") >&5
4677 (eval $ac_try) 2>&5
4678 ac_status=$?
4679 echo "$as_me:4679: \$? = $ac_status" >&5
4680 (exit "$ac_status"); }; }; then
4681 :
4682 else
4683 echo "$as_me: failed program was:" >&5
4684 cat "conftest.$ac_ext" >&5
4685
4686 { echo "$as_me:4686: WARNING: _POSIX_C_SOURCE definition is not usable" >&5
4687 echo "$as_me: WARNING: _POSIX_C_SOURCE definition is not usable" >&2;}
4688 CPPFLAGS="$cf_save_xopen_cppflags"
4689 fi
4690 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4691 fi
4692 ;;
4693 esac
4694
4695 if test -n "$cf_xopen_source" ; then
4696
4697 for cf_add_cflags in $cf_xopen_source
4698 do
4699 case "x$cf_add_cflags" in
4700 (x-[DU]*)
4701
4702 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4703 while true
4704 do
4705 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
4706 test "$CFLAGS" != "$cf_old_cflag" || break
4707 test -n "$verbose" && echo " removing old option $cf_add_cflags from CFLAGS" 1>&6
4708
4709 echo "${as_me:-configure}:4709: testing removing old option $cf_add_cflags from CFLAGS ..." 1>&5
4710
4711 CFLAGS="$cf_old_cflag"
4712 done
4713
4714 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4715 while true
4716 do
4717 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
4718 test "$CPPFLAGS" != "$cf_old_cflag" || break
4719 test -n "$verbose" && echo " removing old option $cf_add_cflags from CPPFLAGS" 1>&6
4720
4721 echo "${as_me:-configure}:4721: testing removing old option $cf_add_cflags from CPPFLAGS ..." 1>&5
4722
4723 CPPFLAGS="$cf_old_cflag"
4724 done
4725
4726 ;;
4727 esac
4728
4729 cf_fix_cppflags=no
4730 cf_new_cflags=
4731 cf_new_cppflags=
4732 cf_new_extra_cppflags=
4733
4734 for cf_add_cflags in $cf_add_cflags
4735 do
4736 case "$cf_fix_cppflags" in
4737 (no)
4738 case "$cf_add_cflags" in
4739 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4740 case "$cf_add_cflags" in
4741 (-D*)
4742 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4743
4744 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4745 && test -z "${cf_tst_cflags}" \
4746 && cf_fix_cppflags=yes
4747
4748 if test "$cf_fix_cppflags" = yes ; then
4749
4750 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4751 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4752
4753 continue
4754 elif test "${cf_tst_cflags}" = "\"'" ; then
4755
4756 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4757 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4758
4759 continue
4760 fi
4761 ;;
4762 esac
4763 case "$CPPFLAGS" in
4764 (*$cf_add_cflags)
4765 ;;
4766 (*)
4767 case "$cf_add_cflags" in
4768 (-D*)
4769 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4770
4771 CPPFLAGS=`echo "$CPPFLAGS" | \
4772 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4773 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4774
4775 ;;
4776 esac
4777
4778 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4779 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4780
4781 ;;
4782 esac
4783 ;;
4784 (*)
4785
4786 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4787 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4788
4789 ;;
4790 esac
4791 ;;
4792 (yes)
4793
4794 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4795 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4796
4797 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4798
4799 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4800 && test -z "${cf_tst_cflags}" \
4801 && cf_fix_cppflags=no
4802 ;;
4803 esac
4804 done
4805
4806 if test -n "$cf_new_cflags" ; then
4807 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
4808
4809 echo "${as_me:-configure}:4809: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
4810
4811 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4812 CFLAGS="${CFLAGS}$cf_new_cflags"
4813
4814 fi
4815
4816 if test -n "$cf_new_cppflags" ; then
4817 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
4818
4819 echo "${as_me:-configure}:4819: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
4820
4821 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4822 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4823
4824 fi
4825
4826 if test -n "$cf_new_extra_cppflags" ; then
4827 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
4828
4829 echo "${as_me:-configure}:4829: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
4830
4831 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4832 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4833
4834 fi
4835
4836 done
4837
4838 fi
4839
4840 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
4841 echo "$as_me:4841: checking if _XOPEN_SOURCE really is set" >&5
4842 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
4843 cat >"conftest.$ac_ext" <<_ACEOF
4844 #line 4844 "configure"
4845 #include "confdefs.h"
4846 #include <stdlib.h>
4847 int
4848 main (void)
4849 {
4850
4851 #ifndef _XOPEN_SOURCE
4852 #error _XOPEN_SOURCE is not defined
4853 #endif
4854 ;
4855 return 0;
4856 }
4857 _ACEOF
4858 rm -f "conftest.$ac_objext"
4859 if { (eval echo "$as_me:4859: \"$ac_compile\"") >&5
4860 (eval $ac_compile) 2>&5
4861 ac_status=$?
4862 echo "$as_me:4862: \$? = $ac_status" >&5
4863 (exit "$ac_status"); } &&
4864 { ac_try='test -s "conftest.$ac_objext"'
4865 { (eval echo "$as_me:4865: \"$ac_try\"") >&5
4866 (eval $ac_try) 2>&5
4867 ac_status=$?
4868 echo "$as_me:4868: \$? = $ac_status" >&5
4869 (exit "$ac_status"); }; }; then
4870 cf_XOPEN_SOURCE_set=yes
4871 else
4872 echo "$as_me: failed program was:" >&5
4873 cat "conftest.$ac_ext" >&5
4874 cf_XOPEN_SOURCE_set=no
4875 fi
4876 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4877 echo "$as_me:4877: result: $cf_XOPEN_SOURCE_set" >&5
4878 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
4879 if test "$cf_XOPEN_SOURCE_set" = yes
4880 then
4881 cat >"conftest.$ac_ext" <<_ACEOF
4882 #line 4882 "configure"
4883 #include "confdefs.h"
4884 #include <stdlib.h>
4885 int
4886 main (void)
4887 {
4888
4889 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
4890 #error (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
4891 #endif
4892 ;
4893 return 0;
4894 }
4895 _ACEOF
4896 rm -f "conftest.$ac_objext"
4897 if { (eval echo "$as_me:4897: \"$ac_compile\"") >&5
4898 (eval $ac_compile) 2>&5
4899 ac_status=$?
4900 echo "$as_me:4900: \$? = $ac_status" >&5
4901 (exit "$ac_status"); } &&
4902 { ac_try='test -s "conftest.$ac_objext"'
4903 { (eval echo "$as_me:4903: \"$ac_try\"") >&5
4904 (eval $ac_try) 2>&5
4905 ac_status=$?
4906 echo "$as_me:4906: \$? = $ac_status" >&5
4907 (exit "$ac_status"); }; }; then
4908 cf_XOPEN_SOURCE_set_ok=yes
4909 else
4910 echo "$as_me: failed program was:" >&5
4911 cat "conftest.$ac_ext" >&5
4912 cf_XOPEN_SOURCE_set_ok=no
4913 fi
4914 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4915 if test "$cf_XOPEN_SOURCE_set_ok" = no
4916 then
4917 { echo "$as_me:4917: WARNING: _XOPEN_SOURCE is lower than requested" >&5
4918 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
4919 fi
4920 else
4921
4922 echo "$as_me:4922: checking if we should define _XOPEN_SOURCE" >&5
4923 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4924 if test "${cf_cv_xopen_source+set}" = set; then
4925 echo $ECHO_N "(cached) $ECHO_C" >&6
4926 else
4927
4928 cat >"conftest.$ac_ext" <<_ACEOF
4929 #line 4929 "configure"
4930 #include "confdefs.h"
4931
4932 $ac_includes_default
4933
4934 int
4935 main (void)
4936 {
4937
4938 #ifndef _XOPEN_SOURCE
4939 #error _XOPEN_SOURCE is not defined
4940 #endif
4941
4942 ;
4943 return 0;
4944 }
4945 _ACEOF
4946 rm -f "conftest.$ac_objext"
4947 if { (eval echo "$as_me:4947: \"$ac_compile\"") >&5
4948 (eval $ac_compile) 2>&5
4949 ac_status=$?
4950 echo "$as_me:4950: \$? = $ac_status" >&5
4951 (exit "$ac_status"); } &&
4952 { ac_try='test -s "conftest.$ac_objext"'
4953 { (eval echo "$as_me:4953: \"$ac_try\"") >&5
4954 (eval $ac_try) 2>&5
4955 ac_status=$?
4956 echo "$as_me:4956: \$? = $ac_status" >&5
4957 (exit "$ac_status"); }; }; then
4958 cf_cv_xopen_source=no
4959 else
4960 echo "$as_me: failed program was:" >&5
4961 cat "conftest.$ac_ext" >&5
4962 cf_save="$CPPFLAGS"
4963
4964 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4965 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4966
4967 cat >"conftest.$ac_ext" <<_ACEOF
4968 #line 4968 "configure"
4969 #include "confdefs.h"
4970
4971 $ac_includes_default
4972
4973 int
4974 main (void)
4975 {
4976
4977 #ifndef _XOPEN_SOURCE
4978 #error _XOPEN_SOURCE is not defined
4979 #endif
4980
4981 ;
4982 return 0;
4983 }
4984 _ACEOF
4985 rm -f "conftest.$ac_objext"
4986 if { (eval echo "$as_me:4986: \"$ac_compile\"") >&5
4987 (eval $ac_compile) 2>&5
4988 ac_status=$?
4989 echo "$as_me:4989: \$? = $ac_status" >&5
4990 (exit "$ac_status"); } &&
4991 { ac_try='test -s "conftest.$ac_objext"'
4992 { (eval echo "$as_me:4992: \"$ac_try\"") >&5
4993 (eval $ac_try) 2>&5
4994 ac_status=$?
4995 echo "$as_me:4995: \$? = $ac_status" >&5
4996 (exit "$ac_status"); }; }; then
4997 cf_cv_xopen_source=no
4998 else
4999 echo "$as_me: failed program was:" >&5
5000 cat "conftest.$ac_ext" >&5
5001 cf_cv_xopen_source=$cf_XOPEN_SOURCE
5002 fi
5003 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5004 CPPFLAGS="$cf_save"
5005
5006 fi
5007 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5008
5009 fi
5010 echo "$as_me:5010: result: $cf_cv_xopen_source" >&5
5011 echo "${ECHO_T}$cf_cv_xopen_source" >&6
5012
5013 if test "$cf_cv_xopen_source" != no ; then
5014
5015 CFLAGS=`echo "$CFLAGS" | \
5016 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5017 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5018
5019 CPPFLAGS=`echo "$CPPFLAGS" | \
5020 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5021 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5022
5023 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
5024
5025 for cf_add_cflags in $cf_temp_xopen_source
5026 do
5027 case "x$cf_add_cflags" in
5028 (x-[DU]*)
5029
5030 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5031 while true
5032 do
5033 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
5034 test "$CFLAGS" != "$cf_old_cflag" || break
5035
5036 CFLAGS="$cf_old_cflag"
5037 done
5038
5039 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5040 while true
5041 do
5042 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
5043 test "$CPPFLAGS" != "$cf_old_cflag" || break
5044
5045 CPPFLAGS="$cf_old_cflag"
5046 done
5047
5048 ;;
5049 esac
5050
5051 cf_fix_cppflags=no
5052 cf_new_cflags=
5053 cf_new_cppflags=
5054 cf_new_extra_cppflags=
5055
5056 for cf_add_cflags in $cf_add_cflags
5057 do
5058 case "$cf_fix_cppflags" in
5059 (no)
5060 case "$cf_add_cflags" in
5061 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5062 case "$cf_add_cflags" in
5063 (-D*)
5064 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5065
5066 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5067 && test -z "${cf_tst_cflags}" \
5068 && cf_fix_cppflags=yes
5069
5070 if test "$cf_fix_cppflags" = yes ; then
5071
5072 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5073 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5074
5075 continue
5076 elif test "${cf_tst_cflags}" = "\"'" ; then
5077
5078 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5079 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5080
5081 continue
5082 fi
5083 ;;
5084 esac
5085 case "$CPPFLAGS" in
5086 (*$cf_add_cflags)
5087 ;;
5088 (*)
5089 case "$cf_add_cflags" in
5090 (-D*)
5091 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5092
5093 CPPFLAGS=`echo "$CPPFLAGS" | \
5094 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5095 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5096
5097 ;;
5098 esac
5099
5100 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5101 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5102
5103 ;;
5104 esac
5105 ;;
5106 (*)
5107
5108 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5109 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5110
5111 ;;
5112 esac
5113 ;;
5114 (yes)
5115
5116 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5117 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5118
5119 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5120
5121 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5122 && test -z "${cf_tst_cflags}" \
5123 && cf_fix_cppflags=no
5124 ;;
5125 esac
5126 done
5127
5128 if test -n "$cf_new_cflags" ; then
5129
5130 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5131 CFLAGS="${CFLAGS}$cf_new_cflags"
5132
5133 fi
5134
5135 if test -n "$cf_new_cppflags" ; then
5136
5137 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5138 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5139
5140 fi
5141
5142 if test -n "$cf_new_extra_cppflags" ; then
5143
5144 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5145 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5146
5147 fi
5148
5149 done
5150
5151 fi
5152
5153 fi
5154 fi
5155 fi # cf_cv_posix_visible
5156
5157 # Check whether --enable-largefile or --disable-largefile was given.
5158 if test "${enable_largefile+set}" = set; then
5159 enableval="$enable_largefile"
5160
5161 fi;
5162 if test "$enable_largefile" != no; then
5163
5164 echo "$as_me:5164: checking for special C compiler options needed for large files" >&5
5165 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
5166 if test "${ac_cv_sys_largefile_CC+set}" = set; then
5167 echo $ECHO_N "(cached) $ECHO_C" >&6
5168 else
5169 ac_cv_sys_largefile_CC=no
5170 if test "$GCC" != yes; then
5171 ac_save_CC=$CC
5172 while :; do
5173 # IRIX 6.2 and later do not support large files by default,
5174 # so use the C compiler's -n32 option if that helps.
5175 cat >"conftest.$ac_ext" <<_ACEOF
5176 #line 5176 "configure"
5177 #include "confdefs.h"
5178 #include <sys/types.h>
5179 /* Check that off_t can represent 2**63 - 1 correctly.
5180 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5181 since some C++ compilers masquerading as C compilers
5182 incorrectly reject 9223372036854775807. */
5183 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5184 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5185 && LARGE_OFF_T % 2147483647 == 1)
5186 ? 1 : -1];
5187 int
5188 main (void)
5189 {
5190
5191 ;
5192 return 0;
5193 }
5194 _ACEOF
5195 rm -f "conftest.$ac_objext"
5196 if { (eval echo "$as_me:5196: \"$ac_compile\"") >&5
5197 (eval $ac_compile) 2>&5
5198 ac_status=$?
5199 echo "$as_me:5199: \$? = $ac_status" >&5
5200 (exit "$ac_status"); } &&
5201 { ac_try='test -s "conftest.$ac_objext"'
5202 { (eval echo "$as_me:5202: \"$ac_try\"") >&5
5203 (eval $ac_try) 2>&5
5204 ac_status=$?
5205 echo "$as_me:5205: \$? = $ac_status" >&5
5206 (exit "$ac_status"); }; }; then
5207 break
5208 else
5209 echo "$as_me: failed program was:" >&5
5210 cat "conftest.$ac_ext" >&5
5211 fi
5212 rm -f "conftest.$ac_objext"
5213 CC="$CC -n32"
5214 rm -f "conftest.$ac_objext"
5215 if { (eval echo "$as_me:5215: \"$ac_compile\"") >&5
5216 (eval $ac_compile) 2>&5
5217 ac_status=$?
5218 echo "$as_me:5218: \$? = $ac_status" >&5
5219 (exit "$ac_status"); } &&
5220 { ac_try='test -s "conftest.$ac_objext"'
5221 { (eval echo "$as_me:5221: \"$ac_try\"") >&5
5222 (eval $ac_try) 2>&5
5223 ac_status=$?
5224 echo "$as_me:5224: \$? = $ac_status" >&5
5225 (exit "$ac_status"); }; }; then
5226 ac_cv_sys_largefile_CC=' -n32'; break
5227 else
5228 echo "$as_me: failed program was:" >&5
5229 cat "conftest.$ac_ext" >&5
5230 fi
5231 rm -f "conftest.$ac_objext"
5232 break
5233 done
5234 CC=$ac_save_CC
5235 rm -f "conftest.$ac_ext"
5236 fi
5237 fi
5238 echo "$as_me:5238: result: $ac_cv_sys_largefile_CC" >&5
5239 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
5240 if test "$ac_cv_sys_largefile_CC" != no; then
5241 CC=$CC$ac_cv_sys_largefile_CC
5242 fi
5243
5244 echo "$as_me:5244: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5245 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
5246 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
5247 echo $ECHO_N "(cached) $ECHO_C" >&6
5248 else
5249 while :; do
5250 ac_cv_sys_file_offset_bits=no
5251 cat >"conftest.$ac_ext" <<_ACEOF
5252 #line 5252 "configure"
5253 #include "confdefs.h"
5254 #include <sys/types.h>
5255 /* Check that off_t can represent 2**63 - 1 correctly.
5256 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5257 since some C++ compilers masquerading as C compilers
5258 incorrectly reject 9223372036854775807. */
5259 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5260 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5261 && LARGE_OFF_T % 2147483647 == 1)
5262 ? 1 : -1];
5263 int
5264 main (void)
5265 {
5266
5267 ;
5268 return 0;
5269 }
5270 _ACEOF
5271 rm -f "conftest.$ac_objext"
5272 if { (eval echo "$as_me:5272: \"$ac_compile\"") >&5
5273 (eval $ac_compile) 2>&5
5274 ac_status=$?
5275 echo "$as_me:5275: \$? = $ac_status" >&5
5276 (exit "$ac_status"); } &&
5277 { ac_try='test -s "conftest.$ac_objext"'
5278 { (eval echo "$as_me:5278: \"$ac_try\"") >&5
5279 (eval $ac_try) 2>&5
5280 ac_status=$?
5281 echo "$as_me:5281: \$? = $ac_status" >&5
5282 (exit "$ac_status"); }; }; then
5283 break
5284 else
5285 echo "$as_me: failed program was:" >&5
5286 cat "conftest.$ac_ext" >&5
5287 fi
5288 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5289 cat >"conftest.$ac_ext" <<_ACEOF
5290 #line 5290 "configure"
5291 #include "confdefs.h"
5292 #define _FILE_OFFSET_BITS 64
5293 #include <sys/types.h>
5294 /* Check that off_t can represent 2**63 - 1 correctly.
5295 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5296 since some C++ compilers masquerading as C compilers
5297 incorrectly reject 9223372036854775807. */
5298 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5299 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5300 && LARGE_OFF_T % 2147483647 == 1)
5301 ? 1 : -1];
5302 int
5303 main (void)
5304 {
5305
5306 ;
5307 return 0;
5308 }
5309 _ACEOF
5310 rm -f "conftest.$ac_objext"
5311 if { (eval echo "$as_me:5311: \"$ac_compile\"") >&5
5312 (eval $ac_compile) 2>&5
5313 ac_status=$?
5314 echo "$as_me:5314: \$? = $ac_status" >&5
5315 (exit "$ac_status"); } &&
5316 { ac_try='test -s "conftest.$ac_objext"'
5317 { (eval echo "$as_me:5317: \"$ac_try\"") >&5
5318 (eval $ac_try) 2>&5
5319 ac_status=$?
5320 echo "$as_me:5320: \$? = $ac_status" >&5
5321 (exit "$ac_status"); }; }; then
5322 ac_cv_sys_file_offset_bits=64; break
5323 else
5324 echo "$as_me: failed program was:" >&5
5325 cat "conftest.$ac_ext" >&5
5326 fi
5327 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5328 break
5329 done
5330 fi
5331 echo "$as_me:5331: result: $ac_cv_sys_file_offset_bits" >&5
5332 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
5333 if test "$ac_cv_sys_file_offset_bits" != no; then
5334
5335 cat >>confdefs.h <<EOF
5336 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5337 EOF
5338
5339 fi
5340 rm -rf conftest*
5341 echo "$as_me:5341: checking for _LARGE_FILES value needed for large files" >&5
5342 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
5343 if test "${ac_cv_sys_large_files+set}" = set; then
5344 echo $ECHO_N "(cached) $ECHO_C" >&6
5345 else
5346 while :; do
5347 ac_cv_sys_large_files=no
5348 cat >"conftest.$ac_ext" <<_ACEOF
5349 #line 5349 "configure"
5350 #include "confdefs.h"
5351 #include <sys/types.h>
5352 /* Check that off_t can represent 2**63 - 1 correctly.
5353 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5354 since some C++ compilers masquerading as C compilers
5355 incorrectly reject 9223372036854775807. */
5356 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5357 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5358 && LARGE_OFF_T % 2147483647 == 1)
5359 ? 1 : -1];
5360 int
5361 main (void)
5362 {
5363
5364 ;
5365 return 0;
5366 }
5367 _ACEOF
5368 rm -f "conftest.$ac_objext"
5369 if { (eval echo "$as_me:5369: \"$ac_compile\"") >&5
5370 (eval $ac_compile) 2>&5
5371 ac_status=$?
5372 echo "$as_me:5372: \$? = $ac_status" >&5
5373 (exit "$ac_status"); } &&
5374 { ac_try='test -s "conftest.$ac_objext"'
5375 { (eval echo "$as_me:5375: \"$ac_try\"") >&5
5376 (eval $ac_try) 2>&5
5377 ac_status=$?
5378 echo "$as_me:5378: \$? = $ac_status" >&5
5379 (exit "$ac_status"); }; }; then
5380 break
5381 else
5382 echo "$as_me: failed program was:" >&5
5383 cat "conftest.$ac_ext" >&5
5384 fi
5385 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5386 cat >"conftest.$ac_ext" <<_ACEOF
5387 #line 5387 "configure"
5388 #include "confdefs.h"
5389 #define _LARGE_FILES 1
5390 #include <sys/types.h>
5391 /* Check that off_t can represent 2**63 - 1 correctly.
5392 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5393 since some C++ compilers masquerading as C compilers
5394 incorrectly reject 9223372036854775807. */
5395 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5396 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5397 && LARGE_OFF_T % 2147483647 == 1)
5398 ? 1 : -1];
5399 int
5400 main (void)
5401 {
5402
5403 ;
5404 return 0;
5405 }
5406 _ACEOF
5407 rm -f "conftest.$ac_objext"
5408 if { (eval echo "$as_me:5408: \"$ac_compile\"") >&5
5409 (eval $ac_compile) 2>&5
5410 ac_status=$?
5411 echo "$as_me:5411: \$? = $ac_status" >&5
5412 (exit "$ac_status"); } &&
5413 { ac_try='test -s "conftest.$ac_objext"'
5414 { (eval echo "$as_me:5414: \"$ac_try\"") >&5
5415 (eval $ac_try) 2>&5
5416 ac_status=$?
5417 echo "$as_me:5417: \$? = $ac_status" >&5
5418 (exit "$ac_status"); }; }; then
5419 ac_cv_sys_large_files=1; break
5420 else
5421 echo "$as_me: failed program was:" >&5
5422 cat "conftest.$ac_ext" >&5
5423 fi
5424 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5425 break
5426 done
5427 fi
5428 echo "$as_me:5428: result: $ac_cv_sys_large_files" >&5
5429 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
5430 if test "$ac_cv_sys_large_files" != no; then
5431
5432 cat >>confdefs.h <<EOF
5433 #define _LARGE_FILES $ac_cv_sys_large_files
5434 EOF
5435
5436 fi
5437 rm -rf conftest*
5438 fi
5439
5440 if test "$enable_largefile" != no ; then
5441 echo "$as_me:5441: checking for _LARGEFILE_SOURCE value needed for large files" >&5
5442 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
5443 if test "${ac_cv_sys_largefile_source+set}" = set; then
5444 echo $ECHO_N "(cached) $ECHO_C" >&6
5445 else
5446 while :; do
5447 ac_cv_sys_largefile_source=no
5448 cat >"conftest.$ac_ext" <<_ACEOF
5449 #line 5449 "configure"
5450 #include "confdefs.h"
5451 #include <stdio.h>
5452 #include <sys/types.h>
5453 int
5454 main (void)
5455 {
5456
5457 int (*my_fseeko)(FILE *, off_t, int) = fseeko;
5458 return my_fseeko(stdin, 0, 0);
5459 ;
5460 return 0;
5461 }
5462 _ACEOF
5463 rm -f "conftest.$ac_objext"
5464 if { (eval echo "$as_me:5464: \"$ac_compile\"") >&5
5465 (eval $ac_compile) 2>&5
5466 ac_status=$?
5467 echo "$as_me:5467: \$? = $ac_status" >&5
5468 (exit "$ac_status"); } &&
5469 { ac_try='test -s "conftest.$ac_objext"'
5470 { (eval echo "$as_me:5470: \"$ac_try\"") >&5
5471 (eval $ac_try) 2>&5
5472 ac_status=$?
5473 echo "$as_me:5473: \$? = $ac_status" >&5
5474 (exit "$ac_status"); }; }; then
5475 break
5476 else
5477 echo "$as_me: failed program was:" >&5
5478 cat "conftest.$ac_ext" >&5
5479 fi
5480 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5481 cat >"conftest.$ac_ext" <<_ACEOF
5482 #line 5482 "configure"
5483 #include "confdefs.h"
5484 #define _LARGEFILE_SOURCE 1
5485 #include <stdio.h>
5486 #include <sys/types.h>
5487 int
5488 main (void)
5489 {
5490
5491 int (*my_fseeko)(FILE *, off_t, int) = fseeko;
5492 return my_fseeko(stdin, 0, 0);
5493 ;
5494 return 0;
5495 }
5496 _ACEOF
5497 rm -f "conftest.$ac_objext"
5498 if { (eval echo "$as_me:5498: \"$ac_compile\"") >&5
5499 (eval $ac_compile) 2>&5
5500 ac_status=$?
5501 echo "$as_me:5501: \$? = $ac_status" >&5
5502 (exit "$ac_status"); } &&
5503 { ac_try='test -s "conftest.$ac_objext"'
5504 { (eval echo "$as_me:5504: \"$ac_try\"") >&5
5505 (eval $ac_try) 2>&5
5506 ac_status=$?
5507 echo "$as_me:5507: \$? = $ac_status" >&5
5508 (exit "$ac_status"); }; }; then
5509 ac_cv_sys_largefile_source=1; break
5510 else
5511 echo "$as_me: failed program was:" >&5
5512 cat "conftest.$ac_ext" >&5
5513 fi
5514 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5515 break
5516 done
5517 fi
5518 echo "$as_me:5518: result: $ac_cv_sys_largefile_source" >&5
5519 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
5520 if test "$ac_cv_sys_largefile_source" != no; then
5521
5522 cat >>confdefs.h <<EOF
5523 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
5524 EOF
5525
5526 fi
5527 rm -rf conftest*
5528
5529 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
5530 # in glibc 2.1.3, but that breaks too many other things.
5531 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
5532 echo "$as_me:5532: checking for fseeko" >&5
5533 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
5534 if test "${ac_cv_func_fseeko+set}" = set; then
5535 echo $ECHO_N "(cached) $ECHO_C" >&6
5536 else
5537 cat >"conftest.$ac_ext" <<_ACEOF
5538 #line 5538 "configure"
5539 #include "confdefs.h"
5540 #include <stdio.h>
5541 #include <sys/types.h>
5542 int
5543 main (void)
5544 {
5545 int (*my_fseeko)(FILE *, off_t, int) = fseeko;
5546 return my_fseeko && my_fseeko (stdin, 0, 0);
5547 ;
5548 return 0;
5549 }
5550 _ACEOF
5551 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
5552 if { (eval echo "$as_me:5552: \"$ac_link\"") >&5
5553 (eval $ac_link) 2>&5
5554 ac_status=$?
5555 echo "$as_me:5555: \$? = $ac_status" >&5
5556 (exit "$ac_status"); } &&
5557 { ac_try='test -s "conftest$ac_exeext"'
5558 { (eval echo "$as_me:5558: \"$ac_try\"") >&5
5559 (eval $ac_try) 2>&5
5560 ac_status=$?
5561 echo "$as_me:5561: \$? = $ac_status" >&5
5562 (exit "$ac_status"); }; }; then
5563 ac_cv_func_fseeko=yes
5564 else
5565 echo "$as_me: failed program was:" >&5
5566 cat "conftest.$ac_ext" >&5
5567 ac_cv_func_fseeko=no
5568 fi
5569 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
5570 fi
5571 echo "$as_me:5571: result: $ac_cv_func_fseeko" >&5
5572 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
5573 if test $ac_cv_func_fseeko = yes; then
5574
5575 cat >>confdefs.h <<\EOF
5576 #define HAVE_FSEEKO 1
5577 EOF
5578
5579 fi
5580
5581 # Normally we would collect these definitions in the config.h,
5582 # but (like _XOPEN_SOURCE), some environments rely on having these
5583 # defined before any of the system headers are included. Another
5584 # case comes up with C++, e.g., on AIX the compiler compiles the
5585 # header files by themselves before looking at the body files it is
5586 # told to compile. For ncurses, those header files do not include
5587 # the config.h
5588 if test "$ac_cv_sys_large_files" != no
5589 then
5590
5591 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5592 CPPFLAGS="${CPPFLAGS}-D_LARGE_FILES"
5593
5594 fi
5595 if test "$ac_cv_sys_largefile_source" != no
5596 then
5597
5598 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5599 CPPFLAGS="${CPPFLAGS}-D_LARGEFILE_SOURCE"
5600
5601 fi
5602 if test "$ac_cv_sys_file_offset_bits" != no
5603 then
5604
5605 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5606 CPPFLAGS="${CPPFLAGS}-D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits"
5607
5608 fi
5609
5610 echo "$as_me:5610: checking whether to use struct dirent64" >&5
5611 echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
5612 if test "${cf_cv_struct_dirent64+set}" = set; then
5613 echo $ECHO_N "(cached) $ECHO_C" >&6
5614 else
5615
5616 cat >"conftest.$ac_ext" <<_ACEOF
5617 #line 5617 "configure"
5618 #include "confdefs.h"
5619
5620 #pragma GCC diagnostic error "-Wincompatible-pointer-types"
5621 #include <sys/types.h>
5622 #include <dirent.h>
5623
5624 #ifndef __REDIRECT
5625 /* if transitional largefile support is setup, this is true */
5626 extern struct dirent64 * readdir(DIR *);
5627 #endif
5628
5629 int
5630 main (void)
5631 {
5632
5633 DIR *dp = opendir(".");
5634 struct dirent64 *x = readdir(dp);
5635 struct dirent *y = readdir(dp);
5636 int z = x - y;
5637 (void)z;
5638
5639 ;
5640 return 0;
5641 }
5642 _ACEOF
5643 rm -f "conftest.$ac_objext"
5644 if { (eval echo "$as_me:5644: \"$ac_compile\"") >&5
5645 (eval $ac_compile) 2>&5
5646 ac_status=$?
5647 echo "$as_me:5647: \$? = $ac_status" >&5
5648 (exit "$ac_status"); } &&
5649 { ac_try='test -s "conftest.$ac_objext"'
5650 { (eval echo "$as_me:5650: \"$ac_try\"") >&5
5651 (eval $ac_try) 2>&5
5652 ac_status=$?
5653 echo "$as_me:5653: \$? = $ac_status" >&5
5654 (exit "$ac_status"); }; }; then
5655 cf_cv_struct_dirent64=yes
5656 else
5657 echo "$as_me: failed program was:" >&5
5658 cat "conftest.$ac_ext" >&5
5659 cf_cv_struct_dirent64=no
5660 fi
5661 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5662
5663 fi
5664 echo "$as_me:5664: result: $cf_cv_struct_dirent64" >&5
5665 echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
5666 test "$cf_cv_struct_dirent64" = yes &&
5667 cat >>confdefs.h <<\EOF
5668 #define HAVE_STRUCT_DIRENT64 1
5669 EOF
5670
5671 fi
5672
5673 echo "$as_me:5673: checking for ANSI C header files" >&5
5674 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5675 if test "${ac_cv_header_stdc+set}" = set; then
5676 echo $ECHO_N "(cached) $ECHO_C" >&6
5677 else
5678 cat >"conftest.$ac_ext" <<_ACEOF
5679 #line 5679 "configure"
5680 #include "confdefs.h"
5681 #include <stdlib.h>
5682 #include <stdarg.h>
5683 #include <string.h>
5684 #include <float.h>
5685
5686 _ACEOF
5687 if { (eval echo "$as_me:5687: \"$ac_cpp "conftest.$ac_ext"\"") >&5
5688 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
5689 ac_status=$?
5690 $EGREP -v '^ *\+' conftest.er1 >conftest.err
5691 rm -f conftest.er1
5692 cat conftest.err >&5
5693 echo "$as_me:5693: \$? = $ac_status" >&5
5694 (exit "$ac_status"); } >/dev/null; then
5695 if test -s conftest.err; then
5696 ac_cpp_err=$ac_c_preproc_warn_flag
5697 else
5698 ac_cpp_err=
5699 fi
5700 else
5701 ac_cpp_err=yes
5702 fi
5703 if test -z "$ac_cpp_err"; then
5704 ac_cv_header_stdc=yes
5705 else
5706 echo "$as_me: failed program was:" >&5
5707 cat "conftest.$ac_ext" >&5
5708 ac_cv_header_stdc=no
5709 fi
5710 rm -f conftest.err "conftest.$ac_ext"
5711
5712 if test $ac_cv_header_stdc = yes; then
5713 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5714 cat >"conftest.$ac_ext" <<_ACEOF
5715 #line 5715 "configure"
5716 #include "confdefs.h"
5717 #include <string.h>
5718
5719 _ACEOF
5720 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5721 $EGREP "memchr" >/dev/null 2>&1; then
5722 :
5723 else
5724 ac_cv_header_stdc=no
5725 fi
5726 rm -rf conftest*
5727
5728 fi
5729
5730 if test $ac_cv_header_stdc = yes; then
5731 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5732 cat >"conftest.$ac_ext" <<_ACEOF
5733 #line 5733 "configure"
5734 #include "confdefs.h"
5735 #include <stdlib.h>
5736
5737 _ACEOF
5738 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5739 $EGREP "free" >/dev/null 2>&1; then
5740 :
5741 else
5742 ac_cv_header_stdc=no
5743 fi
5744 rm -rf conftest*
5745
5746 fi
5747
5748 if test $ac_cv_header_stdc = yes; then
5749 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5750 if test "$cross_compiling" = yes; then
5751 :
5752 else
5753 cat >"conftest.$ac_ext" <<_ACEOF
5754 #line 5754 "configure"
5755 #include "confdefs.h"
5756 #include <ctype.h>
5757 #if ((' ' & 0x0FF) == 0x020)
5758 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5759 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5760 #else
5761 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
5762 || ('j' <= (c) && (c) <= 'r') \
5763 || ('s' <= (c) && (c) <= 'z'))
5764 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5765 #endif
5766
5767 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5768 int
5769 main (void)
5770 {
5771 int i;
5772 for (i = 0; i < 256; i++)
5773 if (XOR (islower (i), ISLOWER (i))
5774 || toupper (i) != TOUPPER (i))
5775 $ac_main_return(2);
5776 $ac_main_return (0);
5777 }
5778 _ACEOF
5779 rm -f "conftest$ac_exeext"
5780 if { (eval echo "$as_me:5780: \"$ac_link\"") >&5
5781 (eval $ac_link) 2>&5
5782 ac_status=$?
5783 echo "$as_me:5783: \$? = $ac_status" >&5
5784 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
5785 { (eval echo "$as_me:5785: \"$ac_try\"") >&5
5786 (eval $ac_try) 2>&5
5787 ac_status=$?
5788 echo "$as_me:5788: \$? = $ac_status" >&5
5789 (exit "$ac_status"); }; }; then
5790 :
5791 else
5792 echo "$as_me: program exited with status $ac_status" >&5
5793 echo "$as_me: failed program was:" >&5
5794 cat "conftest.$ac_ext" >&5
5795 ac_cv_header_stdc=no
5796 fi
5797 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
5798 fi
5799 fi
5800 fi
5801 echo "$as_me:5801: result: $ac_cv_header_stdc" >&5
5802 echo "${ECHO_T}$ac_cv_header_stdc" >&6
5803 if test $ac_cv_header_stdc = yes; then
5804
5805 cat >>confdefs.h <<\EOF
5806 #define STDC_HEADERS 1
5807 EOF
5808
5809 fi
5810
5811 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
5812
5813 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
5814 inttypes.h stdint.h unistd.h
5815 do
5816 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5817 echo "$as_me:5817: checking for $ac_header" >&5
5818 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5819 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5820 echo $ECHO_N "(cached) $ECHO_C" >&6
5821 else
5822 cat >"conftest.$ac_ext" <<_ACEOF
5823 #line 5823 "configure"
5824 #include "confdefs.h"
5825 $ac_includes_default
5826 #include <$ac_header>
5827 _ACEOF
5828 rm -f "conftest.$ac_objext"
5829 if { (eval echo "$as_me:5829: \"$ac_compile\"") >&5
5830 (eval $ac_compile) 2>&5
5831 ac_status=$?
5832 echo "$as_me:5832: \$? = $ac_status" >&5
5833 (exit "$ac_status"); } &&
5834 { ac_try='test -s "conftest.$ac_objext"'
5835 { (eval echo "$as_me:5835: \"$ac_try\"") >&5
5836 (eval $ac_try) 2>&5
5837 ac_status=$?
5838 echo "$as_me:5838: \$? = $ac_status" >&5
5839 (exit "$ac_status"); }; }; then
5840 eval "$as_ac_Header=yes"
5841 else
5842 echo "$as_me: failed program was:" >&5
5843 cat "conftest.$ac_ext" >&5
5844 eval "$as_ac_Header=no"
5845 fi
5846 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5847 fi
5848 echo "$as_me:5848: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
5849 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
5850 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
5851 cat >>confdefs.h <<EOF
5852 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5853 EOF
5854
5855 fi
5856 done
5857
5858 echo "$as_me:5858: checking whether exit is declared" >&5
5859 echo $ECHO_N "checking whether exit is declared... $ECHO_C" >&6
5860 if test "${ac_cv_have_decl_exit+set}" = set; then
5861 echo $ECHO_N "(cached) $ECHO_C" >&6
5862 else
5863 cat >"conftest.$ac_ext" <<_ACEOF
5864 #line 5864 "configure"
5865 #include "confdefs.h"
5866 $ac_includes_default
5867 int
5868 main (void)
5869 {
5870 #ifndef exit
5871 (void) exit;
5872 #endif
5873
5874 ;
5875 return 0;
5876 }
5877 _ACEOF
5878 rm -f "conftest.$ac_objext"
5879 if { (eval echo "$as_me:5879: \"$ac_compile\"") >&5
5880 (eval $ac_compile) 2>&5
5881 ac_status=$?
5882 echo "$as_me:5882: \$? = $ac_status" >&5
5883 (exit "$ac_status"); } &&
5884 { ac_try='test -s "conftest.$ac_objext"'
5885 { (eval echo "$as_me:5885: \"$ac_try\"") >&5
5886 (eval $ac_try) 2>&5
5887 ac_status=$?
5888 echo "$as_me:5888: \$? = $ac_status" >&5
5889 (exit "$ac_status"); }; }; then
5890 ac_cv_have_decl_exit=yes
5891 else
5892 echo "$as_me: failed program was:" >&5
5893 cat "conftest.$ac_ext" >&5
5894 ac_cv_have_decl_exit=no
5895 fi
5896 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5897 fi
5898 echo "$as_me:5898: result: $ac_cv_have_decl_exit" >&5
5899 echo "${ECHO_T}$ac_cv_have_decl_exit" >&6
5900
5901 if test "$cross_compiling" = yes ; then
5902
5903 # defaults that we might want to override
5904 : ${BUILD_CFLAGS:=''}
5905 : ${BUILD_CPPFLAGS:=''}
5906 : ${BUILD_LDFLAGS:=''}
5907 : ${BUILD_LIBS:=''}
5908 : ${BUILD_EXEEXT:='$x'}
5909 : ${BUILD_OBJEXT:='o'}
5910
5911 # Check whether --with-build-cc or --without-build-cc was given.
5912 if test "${with_build_cc+set}" = set; then
5913 withval="$with_build_cc"
5914 BUILD_CC="$withval"
5915 else
5916 for ac_prog in gcc clang c99 c89 cc cl
5917 do
5918 # Extract the first word of "$ac_prog", so it can be a program name with args.
5919 set dummy $ac_prog; ac_word=$2
5920 echo "$as_me:5920: checking for $ac_word" >&5
5921 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5922 if test "${ac_cv_prog_BUILD_CC+set}" = set; then
5923 echo $ECHO_N "(cached) $ECHO_C" >&6
5924 else
5925 if test -n "$BUILD_CC"; then
5926 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
5927 else
5928 ac_save_IFS=$IFS; IFS=$ac_path_separator
5929 ac_dummy="$PATH"
5930 for ac_dir in $ac_dummy; do
5931 IFS=$ac_save_IFS
5932 test -z "$ac_dir" && ac_dir=.
5933 $as_executable_p "$ac_dir/$ac_word" || continue
5934 ac_cv_prog_BUILD_CC="$ac_prog"
5935 echo "$as_me:5935: found $ac_dir/$ac_word" >&5
5936 break
5937 done
5938
5939 fi
5940 fi
5941 BUILD_CC=$ac_cv_prog_BUILD_CC
5942 if test -n "$BUILD_CC"; then
5943 echo "$as_me:5943: result: $BUILD_CC" >&5
5944 echo "${ECHO_T}$BUILD_CC" >&6
5945 else
5946 echo "$as_me:5946: result: no" >&5
5947 echo "${ECHO_T}no" >&6
5948 fi
5949
5950 test -n "$BUILD_CC" && break
5951 done
5952 test -n "$BUILD_CC" || BUILD_CC="none"
5953
5954 fi;
5955 echo "$as_me:5955: checking for native build C compiler" >&5
5956 echo $ECHO_N "checking for native build C compiler... $ECHO_C" >&6
5957 echo "$as_me:5957: result: $BUILD_CC" >&5
5958 echo "${ECHO_T}$BUILD_CC" >&6
5959
5960 echo "$as_me:5960: checking for native build C preprocessor" >&5
5961 echo $ECHO_N "checking for native build C preprocessor... $ECHO_C" >&6
5962
5963 # Check whether --with-build-cpp or --without-build-cpp was given.
5964 if test "${with_build_cpp+set}" = set; then
5965 withval="$with_build_cpp"
5966 BUILD_CPP="$withval"
5967 else
5968 BUILD_CPP='${BUILD_CC} -E'
5969 fi;
5970 echo "$as_me:5970: result: $BUILD_CPP" >&5
5971 echo "${ECHO_T}$BUILD_CPP" >&6
5972
5973 echo "$as_me:5973: checking for native build C flags" >&5
5974 echo $ECHO_N "checking for native build C flags... $ECHO_C" >&6
5975
5976 # Check whether --with-build-cflags or --without-build-cflags was given.
5977 if test "${with_build_cflags+set}" = set; then
5978 withval="$with_build_cflags"
5979 BUILD_CFLAGS="$withval"
5980 fi;
5981 echo "$as_me:5981: result: $BUILD_CFLAGS" >&5
5982 echo "${ECHO_T}$BUILD_CFLAGS" >&6
5983
5984 echo "$as_me:5984: checking for native build C preprocessor-flags" >&5
5985 echo $ECHO_N "checking for native build C preprocessor-flags... $ECHO_C" >&6
5986
5987 # Check whether --with-build-cppflags or --without-build-cppflags was given.
5988 if test "${with_build_cppflags+set}" = set; then
5989 withval="$with_build_cppflags"
5990 BUILD_CPPFLAGS="$withval"
5991 fi;
5992 echo "$as_me:5992: result: $BUILD_CPPFLAGS" >&5
5993 echo "${ECHO_T}$BUILD_CPPFLAGS" >&6
5994
5995 echo "$as_me:5995: checking for native build linker-flags" >&5
5996 echo $ECHO_N "checking for native build linker-flags... $ECHO_C" >&6
5997
5998 # Check whether --with-build-ldflags or --without-build-ldflags was given.
5999 if test "${with_build_ldflags+set}" = set; then
6000 withval="$with_build_ldflags"
6001 BUILD_LDFLAGS="$withval"
6002 fi;
6003 echo "$as_me:6003: result: $BUILD_LDFLAGS" >&5
6004 echo "${ECHO_T}$BUILD_LDFLAGS" >&6
6005
6006 echo "$as_me:6006: checking for native build linker-libraries" >&5
6007 echo $ECHO_N "checking for native build linker-libraries... $ECHO_C" >&6
6008
6009 # Check whether --with-build-libs or --without-build-libs was given.
6010 if test "${with_build_libs+set}" = set; then
6011 withval="$with_build_libs"
6012 BUILD_LIBS="$withval"
6013 fi;
6014 echo "$as_me:6014: result: $BUILD_LIBS" >&5
6015 echo "${ECHO_T}$BUILD_LIBS" >&6
6016
6017 # this assumes we're on Unix.
6018 BUILD_EXEEXT=
6019 BUILD_OBJEXT=o
6020
6021 : ${BUILD_CC:='${CC}'}
6022
6023 echo "$as_me:6023: checking if the build-compiler \"$BUILD_CC\" works" >&5
6024 echo $ECHO_N "checking if the build-compiler \"$BUILD_CC\" works... $ECHO_C" >&6
6025
6026 cf_save_crossed=$cross_compiling
6027 cf_save_ac_link=$ac_link
6028 cross_compiling=no
6029 cf_build_cppflags=$BUILD_CPPFLAGS
6030 test "$cf_build_cppflags" = "#" && cf_build_cppflags=
6031 ac_link='$BUILD_CC -o "conftest$ac_exeext" $BUILD_CFLAGS $cf_build_cppflags $BUILD_LDFLAGS "conftest.$ac_ext" $BUILD_LIBS >&5'
6032
6033 if test "$cross_compiling" = yes; then
6034 cf_ok_build_cc=unknown
6035 else
6036 cat >"conftest.$ac_ext" <<_ACEOF
6037 #line 6037 "configure"
6038 #include "confdefs.h"
6039 #include <stdio.h>
6040 int main(int argc, char *argv[])
6041 {
6042 ${cf_cv_main_return:-return}(argc < 0 || argv == (void*)0 || argv[0] == (void*)0);
6043 }
6044
6045 _ACEOF
6046 rm -f "conftest$ac_exeext"
6047 if { (eval echo "$as_me:6047: \"$ac_link\"") >&5
6048 (eval $ac_link) 2>&5
6049 ac_status=$?
6050 echo "$as_me:6050: \$? = $ac_status" >&5
6051 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
6052 { (eval echo "$as_me:6052: \"$ac_try\"") >&5
6053 (eval $ac_try) 2>&5
6054 ac_status=$?
6055 echo "$as_me:6055: \$? = $ac_status" >&5
6056 (exit "$ac_status"); }; }; then
6057 cf_ok_build_cc=yes
6058 else
6059 echo "$as_me: program exited with status $ac_status" >&5
6060 echo "$as_me: failed program was:" >&5
6061 cat "conftest.$ac_ext" >&5
6062 cf_ok_build_cc=no
6063 fi
6064 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
6065 fi
6066
6067 cross_compiling=$cf_save_crossed
6068 ac_link=$cf_save_ac_link
6069
6070 echo "$as_me:6070: result: $cf_ok_build_cc" >&5
6071 echo "${ECHO_T}$cf_ok_build_cc" >&6
6072
6073 if test "$cf_ok_build_cc" != yes
6074 then
6075 { { echo "$as_me:6075: error: Cross-build requires two compilers.
6076 Use --with-build-cc to specify the native compiler." >&5
6077 echo "$as_me: error: Cross-build requires two compilers.
6078 Use --with-build-cc to specify the native compiler." >&2;}
6079 { (exit 1); exit 1; }; }
6080 fi
6081
6082 else
6083 : ${BUILD_CC:='${CC}'}
6084 : ${BUILD_CPP:='${CPP}'}
6085 : ${BUILD_CFLAGS:='${CFLAGS}'}
6086 : ${BUILD_CPPFLAGS:='${CPPFLAGS}'}
6087 : ${BUILD_LDFLAGS:='${LDFLAGS}'}
6088 : ${BUILD_LIBS:='${LIBS}'}
6089 : ${BUILD_EXEEXT:='$x'}
6090 : ${BUILD_OBJEXT:='o'}
6091 fi
6092
6093 if test "${MATHLIB+set}" != set ; then
6094 echo "$as_me:6094: checking for log in -lm" >&5
6095 echo $ECHO_N "checking for log in -lm... $ECHO_C" >&6
6096 if test "${ac_cv_lib_m_log+set}" = set; then
6097 echo $ECHO_N "(cached) $ECHO_C" >&6
6098 else
6099 ac_check_lib_save_LIBS=$LIBS
6100 LIBS="-lm $LIBS"
6101 cat >"conftest.$ac_ext" <<_ACEOF
6102 #line 6102 "configure"
6103 #include "confdefs.h"
6104
6105 /* Override any gcc2 internal prototype to avoid an error. */
6106 #ifdef __cplusplus
6107 extern "C"
6108 #endif
6109 /* We use char because int might match the return type of a gcc2
6110 builtin and then its argument prototype would still apply. */
6111 char log (void);
6112 int
6113 main (void)
6114 {
6115 log ();
6116 ;
6117 return 0;
6118 }
6119 _ACEOF
6120 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6121 if { (eval echo "$as_me:6121: \"$ac_link\"") >&5
6122 (eval $ac_link) 2>&5
6123 ac_status=$?
6124 echo "$as_me:6124: \$? = $ac_status" >&5
6125 (exit "$ac_status"); } &&
6126 { ac_try='test -s "conftest$ac_exeext"'
6127 { (eval echo "$as_me:6127: \"$ac_try\"") >&5
6128 (eval $ac_try) 2>&5
6129 ac_status=$?
6130 echo "$as_me:6130: \$? = $ac_status" >&5
6131 (exit "$ac_status"); }; }; then
6132 ac_cv_lib_m_log=yes
6133 else
6134 echo "$as_me: failed program was:" >&5
6135 cat "conftest.$ac_ext" >&5
6136 ac_cv_lib_m_log=no
6137 fi
6138 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6139 LIBS=$ac_check_lib_save_LIBS
6140 fi
6141 echo "$as_me:6141: result: $ac_cv_lib_m_log" >&5
6142 echo "${ECHO_T}$ac_cv_lib_m_log" >&6
6143 if test "$ac_cv_lib_m_log" = yes; then
6144 MATHLIB=-lm ; LIBS="-lm $LIBS"
6145 else
6146 # maybe don't need separate math library
6147 echo "$as_me:6147: checking for log" >&5
6148 echo $ECHO_N "checking for log... $ECHO_C" >&6
6149 if test "${ac_cv_func_log+set}" = set; then
6150 echo $ECHO_N "(cached) $ECHO_C" >&6
6151 else
6152 cat >"conftest.$ac_ext" <<_ACEOF
6153 #line 6153 "configure"
6154 #include "confdefs.h"
6155 #define log autoconf_temporary
6156 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6157 #undef log
6158
6159 #ifdef __cplusplus
6160 extern "C"
6161 #endif
6162
6163 /* We use char because int might match the return type of a gcc2
6164 builtin and then its argument prototype would still apply. */
6165 char log (void);
6166
6167 int
6168 main (void)
6169 {
6170
6171 /* The GNU C library defines stubs for functions which it implements
6172 to always fail with ENOSYS. Some functions are actually named
6173 something starting with __ and the normal name is an alias. */
6174 #if defined (__stub_log) || defined (__stub___log)
6175 #error found stub for log
6176 #endif
6177
6178 return log ();
6179 ;
6180 return 0;
6181 }
6182 _ACEOF
6183 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6184 if { (eval echo "$as_me:6184: \"$ac_link\"") >&5
6185 (eval $ac_link) 2>&5
6186 ac_status=$?
6187 echo "$as_me:6187: \$? = $ac_status" >&5
6188 (exit "$ac_status"); } &&
6189 { ac_try='test -s "conftest$ac_exeext"'
6190 { (eval echo "$as_me:6190: \"$ac_try\"") >&5
6191 (eval $ac_try) 2>&5
6192 ac_status=$?
6193 echo "$as_me:6193: \$? = $ac_status" >&5
6194 (exit "$ac_status"); }; }; then
6195 ac_cv_func_log=yes
6196 else
6197 echo "$as_me: failed program was:" >&5
6198 cat "conftest.$ac_ext" >&5
6199 ac_cv_func_log=no
6200 fi
6201 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6202 fi
6203 echo "$as_me:6203: result: $ac_cv_func_log" >&5
6204 echo "${ECHO_T}$ac_cv_func_log" >&6
6205 if test "$ac_cv_func_log" = yes; then
6206 log=yes
6207 fi
6208
6209 if test "$log" = yes
6210 then
6211 MATHLIB='' # evidently don't need one
6212 else
6213 { { echo "$as_me:6213: error: Cannot find a math library. You need to set MATHLIB in config.user" >&5
6214 echo "$as_me: error: Cannot find a math library. You need to set MATHLIB in config.user" >&2;}
6215 { (exit 1); exit 1; }; }
6216 fi
6217 fi
6218 fi
6219
6220 echo "$as_me:6220: checking if you want to see long compiling messages" >&5
6221 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
6222
6223 # Check whether --enable-echo or --disable-echo was given.
6224 if test "${enable_echo+set}" = set; then
6225 enableval="$enable_echo"
6226 test "$enableval" != no && enableval=yes
6227 if test "$enableval" != "yes" ; then
6228
6229 ECHO_LT='--silent'
6230 ECHO_LD='@echo linking $@;'
6231 RULE_CC='@echo compiling $<'
6232 SHOW_CC='@echo compiling $@'
6233 ECHO_CC='@'
6234
6235 else
6236
6237 ECHO_LT=''
6238 ECHO_LD=''
6239 RULE_CC=''
6240 SHOW_CC=''
6241 ECHO_CC=''
6242
6243 fi
6244 else
6245 enableval=yes
6246
6247 ECHO_LT=''
6248 ECHO_LD=''
6249 RULE_CC=''
6250 SHOW_CC=''
6251 ECHO_CC=''
6252
6253 fi;
6254 echo "$as_me:6254: result: $enableval" >&5
6255 echo "${ECHO_T}$enableval" >&6
6256
6257 echo "$as_me:6257: checking if you want to use C11 _Noreturn feature" >&5
6258 echo $ECHO_N "checking if you want to use C11 _Noreturn feature... $ECHO_C" >&6
6259
6260 # Check whether --enable-stdnoreturn or --disable-stdnoreturn was given.
6261 if test "${enable_stdnoreturn+set}" = set; then
6262 enableval="$enable_stdnoreturn"
6263 test "$enableval" != yes && enableval=no
6264 if test "$enableval" != "no" ; then
6265 enable_stdnoreturn=yes
6266 else
6267 enable_stdnoreturn=no
6268 fi
6269 else
6270 enableval=no
6271 enable_stdnoreturn=no
6272
6273 fi;
6274 echo "$as_me:6274: result: $enable_stdnoreturn" >&5
6275 echo "${ECHO_T}$enable_stdnoreturn" >&6
6276
6277 if test $enable_stdnoreturn = yes; then
6278 echo "$as_me:6278: checking for C11 _Noreturn feature" >&5
6279 echo $ECHO_N "checking for C11 _Noreturn feature... $ECHO_C" >&6
6280 if test "${cf_cv_c11_noreturn+set}" = set; then
6281 echo $ECHO_N "(cached) $ECHO_C" >&6
6282 else
6283 cat >"conftest.$ac_ext" <<_ACEOF
6284 #line 6284 "configure"
6285 #include "confdefs.h"
6286
6287 $ac_includes_default
6288 #include <stdnoreturn.h>
6289 static _Noreturn void giveup(void) { exit(0); }
6290
6291 int
6292 main (void)
6293 {
6294 if (feof(stdin)) giveup()
6295 ;
6296 return 0;
6297 }
6298 _ACEOF
6299 rm -f "conftest.$ac_objext"
6300 if { (eval echo "$as_me:6300: \"$ac_compile\"") >&5
6301 (eval $ac_compile) 2>&5
6302 ac_status=$?
6303 echo "$as_me:6303: \$? = $ac_status" >&5
6304 (exit "$ac_status"); } &&
6305 { ac_try='test -s "conftest.$ac_objext"'
6306 { (eval echo "$as_me:6306: \"$ac_try\"") >&5
6307 (eval $ac_try) 2>&5
6308 ac_status=$?
6309 echo "$as_me:6309: \$? = $ac_status" >&5
6310 (exit "$ac_status"); }; }; then
6311 cf_cv_c11_noreturn=yes
6312 else
6313 echo "$as_me: failed program was:" >&5
6314 cat "conftest.$ac_ext" >&5
6315 cf_cv_c11_noreturn=no
6316 fi
6317 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6318
6319 fi
6320 echo "$as_me:6320: result: $cf_cv_c11_noreturn" >&5
6321 echo "${ECHO_T}$cf_cv_c11_noreturn" >&6
6322 else
6323 cf_cv_c11_noreturn=no,
6324 fi
6325
6326 if test "$cf_cv_c11_noreturn" = yes; then
6327
6328 cat >>confdefs.h <<\EOF
6329 #define HAVE_STDNORETURN_H 1
6330 EOF
6331
6332 cat >>confdefs.h <<EOF
6333 #define STDC_NORETURN _Noreturn
6334 EOF
6335
6336 HAVE_STDNORETURN_H=1
6337 else
6338 HAVE_STDNORETURN_H=0
6339 fi
6340
6341 if test "$GCC" = yes || test "$GXX" = yes
6342 then
6343
6344 if test "$GCC" = yes || test "$GXX" = yes
6345 then
6346 case $CFLAGS in
6347 (*-Werror=*)
6348 cf_temp_flags=
6349 for cf_temp_scan in $CFLAGS
6350 do
6351 case "x$cf_temp_scan" in
6352 (x-Werror=format*)
6353
6354 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
6355 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
6356
6357 ;;
6358 (x-Werror=*)
6359
6360 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
6361 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
6362
6363 ;;
6364 (*)
6365
6366 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
6367 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
6368
6369 ;;
6370 esac
6371 done
6372 if test "x$CFLAGS" != "x$cf_temp_flags"
6373 then
6374 test -n "$verbose" && echo " repairing CFLAGS: $CFLAGS" 1>&6
6375
6376 echo "${as_me:-configure}:6376: testing repairing CFLAGS: $CFLAGS ..." 1>&5
6377
6378 CFLAGS="$cf_temp_flags"
6379 test -n "$verbose" && echo " ... fixed $CFLAGS" 1>&6
6380
6381 echo "${as_me:-configure}:6381: testing ... fixed $CFLAGS ..." 1>&5
6382
6383 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
6384
6385 echo "${as_me:-configure}:6385: testing ... extra $EXTRA_CFLAGS ..." 1>&5
6386
6387 fi
6388 ;;
6389 esac
6390 fi
6391
6392 if test "$GCC" = yes || test "$GXX" = yes
6393 then
6394 case $CPPFLAGS in
6395 (*-Werror=*)
6396 cf_temp_flags=
6397 for cf_temp_scan in $CPPFLAGS
6398 do
6399 case "x$cf_temp_scan" in
6400 (x-Werror=format*)
6401
6402 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
6403 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
6404
6405 ;;
6406 (x-Werror=*)
6407
6408 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
6409 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
6410
6411 ;;
6412 (*)
6413
6414 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
6415 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
6416
6417 ;;
6418 esac
6419 done
6420 if test "x$CPPFLAGS" != "x$cf_temp_flags"
6421 then
6422 test -n "$verbose" && echo " repairing CPPFLAGS: $CPPFLAGS" 1>&6
6423
6424 echo "${as_me:-configure}:6424: testing repairing CPPFLAGS: $CPPFLAGS ..." 1>&5
6425
6426 CPPFLAGS="$cf_temp_flags"
6427 test -n "$verbose" && echo " ... fixed $CPPFLAGS" 1>&6
6428
6429 echo "${as_me:-configure}:6429: testing ... fixed $CPPFLAGS ..." 1>&5
6430
6431 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
6432
6433 echo "${as_me:-configure}:6433: testing ... extra $EXTRA_CFLAGS ..." 1>&5
6434
6435 fi
6436 ;;
6437 esac
6438 fi
6439
6440 if test "$GCC" = yes || test "$GXX" = yes
6441 then
6442 case $LDFLAGS in
6443 (*-Werror=*)
6444 cf_temp_flags=
6445 for cf_temp_scan in $LDFLAGS
6446 do
6447 case "x$cf_temp_scan" in
6448 (x-Werror=format*)
6449
6450 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
6451 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
6452
6453 ;;
6454 (x-Werror=*)
6455
6456 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
6457 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
6458
6459 ;;
6460 (*)
6461
6462 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
6463 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
6464
6465 ;;
6466 esac
6467 done
6468 if test "x$LDFLAGS" != "x$cf_temp_flags"
6469 then
6470 test -n "$verbose" && echo " repairing LDFLAGS: $LDFLAGS" 1>&6
6471
6472 echo "${as_me:-configure}:6472: testing repairing LDFLAGS: $LDFLAGS ..." 1>&5
6473
6474 LDFLAGS="$cf_temp_flags"
6475 test -n "$verbose" && echo " ... fixed $LDFLAGS" 1>&6
6476
6477 echo "${as_me:-configure}:6477: testing ... fixed $LDFLAGS ..." 1>&5
6478
6479 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
6480
6481 echo "${as_me:-configure}:6481: testing ... extra $EXTRA_CFLAGS ..." 1>&5
6482
6483 fi
6484 ;;
6485 esac
6486 fi
6487
6488 echo "$as_me:6488: checking if you want to turn on gcc warnings" >&5
6489 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
6490
6491 # Check whether --enable-warnings or --disable-warnings was given.
6492 if test "${enable_warnings+set}" = set; then
6493 enableval="$enable_warnings"
6494 test "$enableval" != yes && enableval=no
6495 if test "$enableval" != "no" ; then
6496 enable_warnings=yes
6497 else
6498 enable_warnings=no
6499 fi
6500 else
6501 enableval=no
6502 enable_warnings=no
6503
6504 fi;
6505 echo "$as_me:6505: result: $enable_warnings" >&5
6506 echo "${ECHO_T}$enable_warnings" >&6
6507 if test "$enable_warnings" = "yes"
6508 then
6509
6510 if test "$GCC" = yes || test "$GXX" = yes
6511 then
6512 cat > conftest.i <<EOF
6513 #ifndef GCC_PRINTF
6514 #define GCC_PRINTF 0
6515 #endif
6516 #ifndef GCC_SCANF
6517 #define GCC_SCANF 0
6518 #endif
6519 #ifndef GCC_NORETURN
6520 #define GCC_NORETURN /* nothing */
6521 #endif
6522 #ifndef GCC_UNUSED
6523 #define GCC_UNUSED /* nothing */
6524 #endif
6525 EOF
6526 if test "$GCC" = yes
6527 then
6528 echo "$as_me:6528: checking for $CC __attribute__ directives" >&5
6529 echo $ECHO_N "checking for $CC __attribute__ directives... $ECHO_C" >&6
6530 test -n "$verbose" && echo "$as_me:6530: result: " >&5
6531 echo "${ECHO_T}" >&6
6532 cat > "conftest.$ac_ext" <<EOF
6533 #line 6533 "${as_me:-configure}"
6534 #include <stdio.h>
6535 #include "confdefs.h"
6536 #include "conftest.h"
6537 #include "conftest.i"
6538 #if GCC_PRINTF
6539 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
6540 #else
6541 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
6542 #endif
6543 #if GCC_SCANF
6544 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
6545 #else
6546 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
6547 #endif
6548 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
6549 extern GCC_NORETURN void oops(char *,...) GCC_PRINTFLIKE(1,2);
6550 extern GCC_NORETURN void foo(void);
6551 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
6552 EOF
6553 cf_printf_attribute=no
6554 cf_scanf_attribute=no
6555 for cf_attribute in scanf printf unused noreturn
6556 do
6557
6558 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6559
6560 cf_directive="__attribute__(($cf_attribute))"
6561 echo "checking for $CC $cf_directive" 1>&5
6562
6563 case "$cf_attribute" in
6564 (printf)
6565 cf_printf_attribute=yes
6566 cat >conftest.h <<EOF
6567 #define GCC_$cf_ATTRIBUTE 1
6568 EOF
6569 ;;
6570 (scanf)
6571 cf_scanf_attribute=yes
6572 cat >conftest.h <<EOF
6573 #define GCC_$cf_ATTRIBUTE 1
6574 EOF
6575 ;;
6576 (*)
6577 cat >conftest.h <<EOF
6578 #define GCC_$cf_ATTRIBUTE $cf_directive
6579 EOF
6580 ;;
6581 esac
6582
6583 if { (eval echo "$as_me:6583: \"$ac_compile\"") >&5
6584 (eval $ac_compile) 2>&5
6585 ac_status=$?
6586 echo "$as_me:6586: \$? = $ac_status" >&5
6587 (exit "$ac_status"); }; then
6588 test -n "$verbose" && echo "$as_me:6588: result: ... $cf_attribute" >&5
6589 echo "${ECHO_T}... $cf_attribute" >&6
6590 cat conftest.h >>confdefs.h
6591 case "$cf_attribute" in
6592 (noreturn)
6593
6594 cat >>confdefs.h <<EOF
6595 #define GCC_NORETURN $cf_directive
6596 EOF
6597
6598 ;;
6599 (printf)
6600 cf_value='/* nothing */'
6601 if test "$cf_printf_attribute" != no ; then
6602 cf_value='__attribute__((format(printf,fmt,var)))'
6603
6604 cat >>confdefs.h <<\EOF
6605 #define GCC_PRINTF 1
6606 EOF
6607
6608 fi
6609
6610 cat >>confdefs.h <<EOF
6611 #define GCC_PRINTFLIKE(fmt,var) $cf_value
6612 EOF
6613
6614 ;;
6615 (scanf)
6616 cf_value='/* nothing */'
6617 if test "$cf_scanf_attribute" != no ; then
6618 cf_value='__attribute__((format(scanf,fmt,var)))'
6619
6620 cat >>confdefs.h <<\EOF
6621 #define GCC_SCANF 1
6622 EOF
6623
6624 fi
6625
6626 cat >>confdefs.h <<EOF
6627 #define GCC_SCANFLIKE(fmt,var) $cf_value
6628 EOF
6629
6630 ;;
6631 (unused)
6632
6633 cat >>confdefs.h <<EOF
6634 #define GCC_UNUSED $cf_directive
6635 EOF
6636
6637 ;;
6638 esac
6639 fi
6640 done
6641 else
6642 ${FGREP-fgrep} define conftest.i >>confdefs.h
6643 fi
6644 rm -rf ./conftest*
6645 fi
6646
6647 if test "x$have_x" = xyes; then
6648
6649 cf_save_LIBS_CF_CONST_X_STRING="$LIBS"
6650 cf_save_CFLAGS_CF_CONST_X_STRING="$CFLAGS"
6651 cf_save_CPPFLAGS_CF_CONST_X_STRING="$CPPFLAGS"
6652 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
6653 for cf_X_CFLAGS in $X_CFLAGS
6654 do
6655 case "x$cf_X_CFLAGS" in
6656 x-[IUD]*)
6657 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
6658 ;;
6659 *)
6660 CFLAGS="$CFLAGS $cf_X_CFLAGS"
6661 ;;
6662 esac
6663 done
6664
6665 cat >"conftest.$ac_ext" <<_ACEOF
6666 #line 6666 "configure"
6667 #include "confdefs.h"
6668
6669 $ac_includes_default
6670 #include <X11/Intrinsic.h>
6671
6672 int
6673 main (void)
6674 {
6675 String foo = malloc(1); free((void*)foo)
6676 ;
6677 return 0;
6678 }
6679 _ACEOF
6680 rm -f "conftest.$ac_objext"
6681 if { (eval echo "$as_me:6681: \"$ac_compile\"") >&5
6682 (eval $ac_compile) 2>&5
6683 ac_status=$?
6684 echo "$as_me:6684: \$? = $ac_status" >&5
6685 (exit "$ac_status"); } &&
6686 { ac_try='test -s "conftest.$ac_objext"'
6687 { (eval echo "$as_me:6687: \"$ac_try\"") >&5
6688 (eval $ac_try) 2>&5
6689 ac_status=$?
6690 echo "$as_me:6690: \$? = $ac_status" >&5
6691 (exit "$ac_status"); }; }; then
6692
6693 echo "$as_me:6693: checking for X11/Xt const-feature" >&5
6694 echo $ECHO_N "checking for X11/Xt const-feature... $ECHO_C" >&6
6695 if test "${cf_cv_const_x_string+set}" = set; then
6696 echo $ECHO_N "(cached) $ECHO_C" >&6
6697 else
6698
6699 cat >"conftest.$ac_ext" <<_ACEOF
6700 #line 6700 "configure"
6701 #include "confdefs.h"
6702
6703 #undef _CONST_X_STRING
6704 #define _CONST_X_STRING /* X11R7.8 (perhaps) */
6705 #undef XTSTRINGDEFINES /* X11R5 and later */
6706 $ac_includes_default
6707 #include <X11/Intrinsic.h>
6708
6709 int
6710 main (void)
6711 {
6712 String foo = malloc(1); *foo = 0
6713 ;
6714 return 0;
6715 }
6716 _ACEOF
6717 rm -f "conftest.$ac_objext"
6718 if { (eval echo "$as_me:6718: \"$ac_compile\"") >&5
6719 (eval $ac_compile) 2>&5
6720 ac_status=$?
6721 echo "$as_me:6721: \$? = $ac_status" >&5
6722 (exit "$ac_status"); } &&
6723 { ac_try='test -s "conftest.$ac_objext"'
6724 { (eval echo "$as_me:6724: \"$ac_try\"") >&5
6725 (eval $ac_try) 2>&5
6726 ac_status=$?
6727 echo "$as_me:6727: \$? = $ac_status" >&5
6728 (exit "$ac_status"); }; }; then
6729
6730 cf_cv_const_x_string=no
6731
6732 else
6733 echo "$as_me: failed program was:" >&5
6734 cat "conftest.$ac_ext" >&5
6735
6736 cf_cv_const_x_string=yes
6737
6738 fi
6739 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6740
6741 fi
6742 echo "$as_me:6742: result: $cf_cv_const_x_string" >&5
6743 echo "${ECHO_T}$cf_cv_const_x_string" >&6
6744
6745 LIBS="$cf_save_LIBS_CF_CONST_X_STRING"
6746 CFLAGS="$cf_save_CFLAGS_CF_CONST_X_STRING"
6747 CPPFLAGS="$cf_save_CPPFLAGS_CF_CONST_X_STRING"
6748
6749 case "$cf_cv_const_x_string" in
6750 (no)
6751
6752 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6753 CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
6754
6755 ;;
6756 (*)
6757
6758 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
6759 CPPFLAGS="${CPPFLAGS}-D_CONST_X_STRING"
6760
6761 ;;
6762 esac
6763
6764 else
6765 echo "$as_me: failed program was:" >&5
6766 cat "conftest.$ac_ext" >&5
6767 fi
6768 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6769 fi
6770 cat > "conftest.$ac_ext" <<EOF
6771 #line 6771 "${as_me:-configure}"
6772 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
6773 EOF
6774 if test "$INTEL_COMPILER" = yes
6775 then
6776 # The "-wdXXX" options suppress warnings:
6777 # remark #1419: external declaration in primary source file
6778 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
6779 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
6780 # remark #193: zero used for undefined preprocessing identifier
6781 # remark #593: variable "curs_sb_left_arrow" was set but never used
6782 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
6783 # remark #869: parameter "tw" was never referenced
6784 # remark #981: operands are evaluated in unspecified order
6785 # warning #279: controlling expression is constant
6786
6787 echo "$as_me:6787: checking for $CC warning options" >&5
6788 echo $ECHO_N "checking for $CC warning options... $ECHO_C" >&6
6789 test -n "$verbose" && echo "$as_me:6789: result: " >&5
6790 echo "${ECHO_T}" >&6
6791 cf_save_CFLAGS="$CFLAGS"
6792 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
6793 for cf_opt in \
6794 wd1419 \
6795 wd1683 \
6796 wd1684 \
6797 wd193 \
6798 wd593 \
6799 wd279 \
6800 wd810 \
6801 wd869 \
6802 wd981
6803 do
6804 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
6805 if { (eval echo "$as_me:6805: \"$ac_compile\"") >&5
6806 (eval $ac_compile) 2>&5
6807 ac_status=$?
6808 echo "$as_me:6808: \$? = $ac_status" >&5
6809 (exit "$ac_status"); }; then
6810 test -n "$verbose" && echo "$as_me:6810: result: ... -$cf_opt" >&5
6811 echo "${ECHO_T}... -$cf_opt" >&6
6812 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
6813 fi
6814 done
6815 CFLAGS="$cf_save_CFLAGS"
6816 elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
6817 then
6818 echo "$as_me:6818: checking for $CC warning options" >&5
6819 echo $ECHO_N "checking for $CC warning options... $ECHO_C" >&6
6820 test -n "$verbose" && echo "$as_me:6820: result: " >&5
6821 echo "${ECHO_T}" >&6
6822 cf_save_CFLAGS="$CFLAGS"
6823 cf_warn_CONST=""
6824 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
6825 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
6826 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
6827 for cf_opt in W Wall \
6828 Wbad-function-cast \
6829 Wcast-align \
6830 Wcast-qual \
6831 Wdeclaration-after-statement \
6832 Wextra \
6833 Winline \
6834 Wmissing-declarations \
6835 Wmissing-prototypes \
6836 Wnested-externs \
6837 Wpointer-arith \
6838 Wshadow \
6839 Wstrict-prototypes \
6840 Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST
6841 do
6842 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
6843 if { (eval echo "$as_me:6843: \"$ac_compile\"") >&5
6844 (eval $ac_compile) 2>&5
6845 ac_status=$?
6846 echo "$as_me:6846: \$? = $ac_status" >&5
6847 (exit "$ac_status"); }; then
6848 test -n "$verbose" && echo "$as_me:6848: result: ... -$cf_opt" >&5
6849 echo "${ECHO_T}... -$cf_opt" >&6
6850 case "$cf_opt" in
6851 (Winline)
6852 case "$GCC_VERSION" in
6853 ([34].*)
6854 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
6855
6856 echo "${as_me:-configure}:6856: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
6857
6858 continue;;
6859 esac
6860 ;;
6861 (Wpointer-arith)
6862 case "$GCC_VERSION" in
6863 ([12].*)
6864 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
6865
6866 echo "${as_me:-configure}:6866: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
6867
6868 continue;;
6869 esac
6870 ;;
6871 esac
6872 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
6873 fi
6874 done
6875 CFLAGS="$cf_save_CFLAGS"
6876 fi
6877 rm -rf ./conftest*
6878
6879 fi
6880
6881 fi
6882
6883 # Extract the first word of "groff", so it can be a program name with args.
6884 set dummy groff; ac_word=$2
6885 echo "$as_me:6885: checking for $ac_word" >&5
6886 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6887 if test "${ac_cv_path_GROFF_PATH+set}" = set; then
6888 echo $ECHO_N "(cached) $ECHO_C" >&6
6889 else
6890 case $GROFF_PATH in
6891 [\\/]* | ?:[\\/]*)
6892 ac_cv_path_GROFF_PATH="$GROFF_PATH" # Let the user override the test with a path.
6893 ;;
6894 *)
6895 ac_save_IFS=$IFS; IFS=$ac_path_separator
6896 ac_dummy="$PATH"
6897 for ac_dir in $ac_dummy; do
6898 IFS=$ac_save_IFS
6899 test -z "$ac_dir" && ac_dir=.
6900 if $as_executable_p "$ac_dir/$ac_word"; then
6901 ac_cv_path_GROFF_PATH="$ac_dir/$ac_word"
6902 echo "$as_me:6902: found $ac_dir/$ac_word" >&5
6903 break
6904 fi
6905 done
6906
6907 test -z "$ac_cv_path_GROFF_PATH" && ac_cv_path_GROFF_PATH="no"
6908 ;;
6909 esac
6910 fi
6911 GROFF_PATH=$ac_cv_path_GROFF_PATH
6912
6913 if test -n "$GROFF_PATH"; then
6914 echo "$as_me:6914: result: $GROFF_PATH" >&5
6915 echo "${ECHO_T}$GROFF_PATH" >&6
6916 else
6917 echo "$as_me:6917: result: no" >&5
6918 echo "${ECHO_T}no" >&6
6919 fi
6920
6921 for ac_prog in nroff mandoc
6922 do
6923 # Extract the first word of "$ac_prog", so it can be a program name with args.
6924 set dummy $ac_prog; ac_word=$2
6925 echo "$as_me:6925: checking for $ac_word" >&5
6926 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6927 if test "${ac_cv_path_NROFF_PATH+set}" = set; then
6928 echo $ECHO_N "(cached) $ECHO_C" >&6
6929 else
6930 case $NROFF_PATH in
6931 [\\/]* | ?:[\\/]*)
6932 ac_cv_path_NROFF_PATH="$NROFF_PATH" # Let the user override the test with a path.
6933 ;;
6934 *)
6935 ac_save_IFS=$IFS; IFS=$ac_path_separator
6936 ac_dummy="$PATH"
6937 for ac_dir in $ac_dummy; do
6938 IFS=$ac_save_IFS
6939 test -z "$ac_dir" && ac_dir=.
6940 if $as_executable_p "$ac_dir/$ac_word"; then
6941 ac_cv_path_NROFF_PATH="$ac_dir/$ac_word"
6942 echo "$as_me:6942: found $ac_dir/$ac_word" >&5
6943 break
6944 fi
6945 done
6946
6947 ;;
6948 esac
6949 fi
6950 NROFF_PATH=$ac_cv_path_NROFF_PATH
6951
6952 if test -n "$NROFF_PATH"; then
6953 echo "$as_me:6953: result: $NROFF_PATH" >&5
6954 echo "${ECHO_T}$NROFF_PATH" >&6
6955 else
6956 echo "$as_me:6956: result: no" >&5
6957 echo "${ECHO_T}no" >&6
6958 fi
6959
6960 test -n "$NROFF_PATH" && break
6961 done
6962 test -n "$NROFF_PATH" || NROFF_PATH="no"
6963
6964 # Extract the first word of "tbl", so it can be a program name with args.
6965 set dummy tbl; ac_word=$2
6966 echo "$as_me:6966: checking for $ac_word" >&5
6967 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6968 if test "${ac_cv_path_TBL_PATH+set}" = set; then
6969 echo $ECHO_N "(cached) $ECHO_C" >&6
6970 else
6971 case $TBL_PATH in
6972 [\\/]* | ?:[\\/]*)
6973 ac_cv_path_TBL_PATH="$TBL_PATH" # Let the user override the test with a path.
6974 ;;
6975 *)
6976 ac_save_IFS=$IFS; IFS=$ac_path_separator
6977 ac_dummy="$PATH"
6978 for ac_dir in $ac_dummy; do
6979 IFS=$ac_save_IFS
6980 test -z "$ac_dir" && ac_dir=.
6981 if $as_executable_p "$ac_dir/$ac_word"; then
6982 ac_cv_path_TBL_PATH="$ac_dir/$ac_word"
6983 echo "$as_me:6983: found $ac_dir/$ac_word" >&5
6984 break
6985 fi
6986 done
6987
6988 test -z "$ac_cv_path_TBL_PATH" && ac_cv_path_TBL_PATH="cat"
6989 ;;
6990 esac
6991 fi
6992 TBL_PATH=$ac_cv_path_TBL_PATH
6993
6994 if test -n "$TBL_PATH"; then
6995 echo "$as_me:6995: result: $TBL_PATH" >&5
6996 echo "${ECHO_T}$TBL_PATH" >&6
6997 else
6998 echo "$as_me:6998: result: no" >&5
6999 echo "${ECHO_T}no" >&6
7000 fi
7001
7002 if test "x$GROFF_PATH" = xno
7003 then
7004 NROFF_NOTE=
7005 GROFF_NOTE="#"
7006 else
7007 NROFF_NOTE="#"
7008 GROFF_NOTE=
7009 fi
7010
7011 if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
7012 echo "$as_me:7012: checking target system type" >&5
7013 echo $ECHO_N "checking target system type... $ECHO_C" >&6
7014 if test "${ac_cv_target+set}" = set; then
7015 echo $ECHO_N "(cached) $ECHO_C" >&6
7016 else
7017 ac_cv_target_alias=$target_alias
7018 test "x$ac_cv_target_alias" = "x" &&
7019 ac_cv_target_alias=$ac_cv_host_alias
7020 ac_cv_target=`$ac_config_sub "$ac_cv_target_alias"` ||
7021 { { echo "$as_me:7021: error: $ac_config_sub $ac_cv_target_alias failed" >&5
7022 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
7023 { (exit 1); exit 1; }; }
7024
7025 fi
7026 echo "$as_me:7026: result: $ac_cv_target" >&5
7027 echo "${ECHO_T}$ac_cv_target" >&6
7028 target=$ac_cv_target
7029 target_cpu=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
7030 target_vendor=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
7031 target_os=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
7032
7033 # The aliases save the names the user supplied, while $host etc.
7034 # will get canonicalized.
7035 test -n "$target_alias" &&
7036 test "$program_prefix$program_suffix$program_transform_name" = \
7037 NONENONEs,x,x, &&
7038 program_prefix=${target_alias}-
7039 system_name="$host_os"
7040 else
7041 system_name="`(uname -s -r) 2>/dev/null`"
7042 if test -z "$system_name" ; then
7043 system_name="`(hostname) 2>/dev/null`"
7044 fi
7045 fi
7046 test -n "$system_name" &&
7047 cat >>confdefs.h <<EOF
7048 #define SYSTEM_NAME "$system_name"
7049 EOF
7050
7051 if test "${cf_cv_system_name+set}" = set; then
7052 echo $ECHO_N "(cached) $ECHO_C" >&6
7053 else
7054 cf_cv_system_name="$system_name"
7055 fi
7056
7057 test -z "$system_name" && system_name="$cf_cv_system_name"
7058 test -n "$cf_cv_system_name" && echo "$as_me:7058: result: Configuring for $cf_cv_system_name" >&5
7059 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
7060
7061 if test ".$system_name" != ".$cf_cv_system_name" ; then
7062 echo "$as_me:7062: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
7063 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
7064 { { echo "$as_me:7064: error: \"Please remove config.cache and try again.\"" >&5
7065 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
7066 { (exit 1); exit 1; }; }
7067 fi
7068
7069 # Check whether --with-system-type or --without-system-type was given.
7070 if test "${with_system_type+set}" = set; then
7071 withval="$with_system_type"
7072 { echo "$as_me:7072: WARNING: overriding system type to $withval" >&5
7073 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
7074 cf_cv_system_name=$withval
7075 host_os=$withval
7076
7077 fi;
7078
7079 case "$cf_cv_system_name" in
7080 (cygwin*|msys*|mingw32*|mingw64|os2*)
7081 GLOB_FULLPATH_POSIX='/*'
7082 GLOB_FULLPATH_OTHER='[a-zA-Z]:[\\/]*'
7083 ;;
7084 (*)
7085 GLOB_FULLPATH_POSIX='/*'
7086 GLOB_FULLPATH_OTHER=$GLOB_FULLPATH_POSIX
7087 ;;
7088 esac
7089
7090 case "x${with_man2html}" in
7091 (xno)
7092 cf_man2html=no
7093 ;;
7094 (x|xyes)
7095 # Extract the first word of "man2html", so it can be a program name with args.
7096 set dummy man2html; ac_word=$2
7097 echo "$as_me:7097: checking for $ac_word" >&5
7098 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7099 if test "${ac_cv_path_cf_man2html+set}" = set; then
7100 echo $ECHO_N "(cached) $ECHO_C" >&6
7101 else
7102 case $cf_man2html in
7103 [\\/]* | ?:[\\/]*)
7104 ac_cv_path_cf_man2html="$cf_man2html" # Let the user override the test with a path.
7105 ;;
7106 *)
7107 ac_save_IFS=$IFS; IFS=$ac_path_separator
7108 ac_dummy="$PATH"
7109 for ac_dir in $ac_dummy; do
7110 IFS=$ac_save_IFS
7111 test -z "$ac_dir" && ac_dir=.
7112 if $as_executable_p "$ac_dir/$ac_word"; then
7113 ac_cv_path_cf_man2html="$ac_dir/$ac_word"
7114 echo "$as_me:7114: found $ac_dir/$ac_word" >&5
7115 break
7116 fi
7117 done
7118
7119 test -z "$ac_cv_path_cf_man2html" && ac_cv_path_cf_man2html="no"
7120 ;;
7121 esac
7122 fi
7123 cf_man2html=$ac_cv_path_cf_man2html
7124
7125 if test -n "$cf_man2html"; then
7126 echo "$as_me:7126: result: $cf_man2html" >&5
7127 echo "${ECHO_T}$cf_man2html" >&6
7128 else
7129 echo "$as_me:7129: result: no" >&5
7130 echo "${ECHO_T}no" >&6
7131 fi
7132
7133 case "x$cf_man2html" in
7134 (x/*)
7135 echo "$as_me:7135: checking for the modified Earl Hood script" >&5
7136 echo $ECHO_N "checking for the modified Earl Hood script... $ECHO_C" >&6
7137 if ( $cf_man2html -help 2>&1 | grep 'Make an index of headers at the end' >/dev/null )
7138 then
7139 cf_man2html_ok=yes
7140 else
7141 cf_man2html=no
7142 cf_man2html_ok=no
7143 fi
7144 echo "$as_me:7144: result: $cf_man2html_ok" >&5
7145 echo "${ECHO_T}$cf_man2html_ok" >&6
7146 ;;
7147 (*)
7148 cf_man2html=no
7149 ;;
7150 esac
7151 esac
7152
7153 echo "$as_me:7153: checking for program to convert manpage to html" >&5
7154 echo $ECHO_N "checking for program to convert manpage to html... $ECHO_C" >&6
7155
7156 # Check whether --with-man2html or --without-man2html was given.
7157 if test "${with_man2html+set}" = set; then
7158 withval="$with_man2html"
7159 cf_man2html=$withval
7160 else
7161 cf_man2html=$cf_man2html
7162 fi;
7163
7164 cf_with_groff=no
7165
7166 case $cf_man2html in
7167 (yes)
7168 echo "$as_me:7168: result: man2html" >&5
7169 echo "${ECHO_T}man2html" >&6
7170 # Extract the first word of "man2html", so it can be a program name with args.
7171 set dummy man2html; ac_word=$2
7172 echo "$as_me:7172: checking for $ac_word" >&5
7173 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7174 if test "${ac_cv_path_cf_man2html+set}" = set; then
7175 echo $ECHO_N "(cached) $ECHO_C" >&6
7176 else
7177 case $cf_man2html in
7178 [\\/]* | ?:[\\/]*)
7179 ac_cv_path_cf_man2html="$cf_man2html" # Let the user override the test with a path.
7180 ;;
7181 *)
7182 ac_save_IFS=$IFS; IFS=$ac_path_separator
7183 ac_dummy="$PATH"
7184 for ac_dir in $ac_dummy; do
7185 IFS=$ac_save_IFS
7186 test -z "$ac_dir" && ac_dir=.
7187 if $as_executable_p "$ac_dir/$ac_word"; then
7188 ac_cv_path_cf_man2html="$ac_dir/$ac_word"
7189 echo "$as_me:7189: found $ac_dir/$ac_word" >&5
7190 break
7191 fi
7192 done
7193
7194 test -z "$ac_cv_path_cf_man2html" && ac_cv_path_cf_man2html="no"
7195 ;;
7196 esac
7197 fi
7198 cf_man2html=$ac_cv_path_cf_man2html
7199
7200 if test -n "$cf_man2html"; then
7201 echo "$as_me:7201: result: $cf_man2html" >&5
7202 echo "${ECHO_T}$cf_man2html" >&6
7203 else
7204 echo "$as_me:7204: result: no" >&5
7205 echo "${ECHO_T}no" >&6
7206 fi
7207
7208 ;;
7209 (no|groff|*/groff*)
7210 cf_with_groff=yes
7211 cf_man2html=$GROFF_PATH
7212 echo "$as_me:7212: result: $cf_man2html" >&5
7213 echo "${ECHO_T}$cf_man2html" >&6
7214 ;;
7215 (*)
7216 echo "$as_me:7216: result: $cf_man2html" >&5
7217 echo "${ECHO_T}$cf_man2html" >&6
7218 ;;
7219 esac
7220
7221 MAN2HTML_TEMP="man2html.tmp"
7222 cat >$MAN2HTML_TEMP <<CF_EOF
7223 #!$SHELL
7224 # Temporary script generated by CF_WITH_MAN2HTML
7225 # Convert inputs to html, sending result to standard output.
7226 #
7227 # Parameters:
7228 # \${1} = rootname of file to convert
7229 # \${2} = suffix of file to convert, e.g., "1"
7230 # \${3} = macros to use, e.g., "man"
7231 #
7232 ROOT=\$1
7233 TYPE=\$2
7234 MACS=\$3
7235
7236 unset LANG
7237 unset LC_ALL
7238 unset LC_CTYPE
7239 unset LANGUAGE
7240 GROFF_NO_SGR=stupid
7241 export GROFF_NO_SGR
7242
7243 CF_EOF
7244
7245 NROFF_OPTS=
7246 if test "x$cf_with_groff" = xyes
7247 then
7248 MAN2HTML_NOTE="$GROFF_NOTE"
7249 MAN2HTML_PATH="$GROFF_PATH"
7250 cat >>$MAN2HTML_TEMP <<CF_EOF
7251 $SHELL -c "$TBL_PATH \${ROOT}.\${TYPE} | $GROFF_PATH -P -o0 -I\${ROOT}_ -Thtml -\${MACS}"
7252 CF_EOF
7253 else
7254 # disable hyphenation if this is groff
7255 if test "x$GROFF_PATH" != xno
7256 then
7257 echo "$as_me:7257: checking if nroff is really groff" >&5
7258 echo $ECHO_N "checking if nroff is really groff... $ECHO_C" >&6
7259 cf_check_groff="`$NROFF_PATH --version 2>/dev/null | grep groff`"
7260 test -n "$cf_check_groff" && cf_check_groff=yes
7261 test -n "$cf_check_groff" || cf_check_groff=no
7262 echo "$as_me:7262: result: $cf_check_groff" >&5
7263 echo "${ECHO_T}$cf_check_groff" >&6
7264 test "x$cf_check_groff" = xyes && NROFF_OPTS="-rHY=0"
7265 fi
7266 MAN2HTML_NOTE=""
7267
7268 if test "x$prefix" != xNONE; then
7269 cf_path_syntax="$prefix"
7270 else
7271 cf_path_syntax="$ac_default_prefix"
7272 fi
7273
7274 case "x$cf_man2html" in
7275 (x\$\(*\)*|x\'*\'*)
7276 ;;
7277 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
7278 ;;
7279 (x\$\{*prefix\}*|x\$\{*dir\}*)
7280 eval cf_man2html="$cf_man2html"
7281 case "x$cf_man2html" in
7282 (xNONE/*)
7283 cf_man2html=`echo "$cf_man2html" | sed -e s%NONE%$cf_path_syntax%`
7284 ;;
7285 esac
7286 ;;
7287 (xno|xNONE/*)
7288 cf_man2html=`echo "$cf_man2html" | sed -e s%NONE%$cf_path_syntax%`
7289 ;;
7290 (*)
7291 { { echo "$as_me:7291: error: expected a pathname, not \"$cf_man2html\"" >&5
7292 echo "$as_me: error: expected a pathname, not \"$cf_man2html\"" >&2;}
7293 { (exit 1); exit 1; }; }
7294 ;;
7295 esac
7296
7297 MAN2HTML_PATH="$cf_man2html"
7298 echo "$as_me:7298: checking for $cf_man2html top/bottom margins" >&5
7299 echo $ECHO_N "checking for $cf_man2html top/bottom margins... $ECHO_C" >&6
7300
7301 # for this example, expect 3 lines of content, the remainder is head/foot
7302 cat >conftest.in <<CF_EOF
7303 .TH HEAD1 HEAD2 HEAD3 HEAD4 HEAD5
7304 .SH SECTION
7305 MARKER
7306 CF_EOF
7307
7308 LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
7309
7310 cf_man2html_1st="`${FGREP-fgrep} -n MARKER conftest.out |sed -e 's/^[^0-9]*://' -e 's/:.*//'`"
7311 cf_man2html_top=`expr "$cf_man2html_1st" - 2`
7312 cf_man2html_bot="`wc -l conftest.out |sed -e 's/[^0-9]//g'`"
7313 cf_man2html_bot=`expr "$cf_man2html_bot" - 2 - "$cf_man2html_top"`
7314 cf_man2html_top_bot="-topm=$cf_man2html_top -botm=$cf_man2html_bot"
7315
7316 echo "$as_me:7316: result: $cf_man2html_top_bot" >&5
7317 echo "${ECHO_T}$cf_man2html_top_bot" >&6
7318
7319 echo "$as_me:7319: checking for pagesize to use" >&5
7320 echo $ECHO_N "checking for pagesize to use... $ECHO_C" >&6
7321 for cf_block in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
7322 do
7323 cat >>conftest.in <<CF_EOF
7324 .nf
7325 0
7326 1
7327 2
7328 3
7329 4
7330 5
7331 6
7332 7
7333 8
7334 9
7335 CF_EOF
7336 done
7337
7338 LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
7339 cf_man2html_page="`${FGREP-fgrep} -n HEAD1 conftest.out |sed -n '$p' |sed -e 's/^[^0-9]*://' -e 's/:.*//'`"
7340 test -z "$cf_man2html_page" && cf_man2html_page=99999
7341 test "$cf_man2html_page" -gt 100 && cf_man2html_page=99999
7342
7343 rm -rf conftest*
7344 echo "$as_me:7344: result: $cf_man2html_page" >&5
7345 echo "${ECHO_T}$cf_man2html_page" >&6
7346
7347 cat >>$MAN2HTML_TEMP <<CF_EOF
7348 : \${MAN2HTML_PATH=$MAN2HTML_PATH}
7349 MAN2HTML_OPTS="\$MAN2HTML_OPTS -index -title=\"\$ROOT(\$TYPE)\" -compress -pgsize $cf_man2html_page"
7350 case \${TYPE} in
7351 (ms)
7352 $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH -topm=0 -botm=0 \$MAN2HTML_OPTS
7353 ;;
7354 (*)
7355 $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH $cf_man2html_top_bot \$MAN2HTML_OPTS
7356 ;;
7357 esac
7358 CF_EOF
7359 fi
7360
7361 chmod 700 $MAN2HTML_TEMP
7362
7363 ###############################################################################
7364 echo "$as_me:7364: checking if you want to use mawk's own regular-expressions engine" >&5
7365 echo $ECHO_N "checking if you want to use mawk's own regular-expressions engine... $ECHO_C" >&6
7366
7367 # Check whether --with-builtin-regex or --without-builtin-regex was given.
7368 if test "${with_builtin_regex+set}" = set; then
7369 withval="$with_builtin_regex"
7370
7371 with_builtin_regex=$withval
7372
7373 fi;
7374 if test "x${with_builtin_regex}" != xno; then
7375 with_builtin_regex=yes
7376
7377 cat >>confdefs.h <<\EOF
7378 #define LOCAL_REGEXP 1
7379 EOF
7380
7381 fi
7382 echo "$as_me:7382: result: $with_builtin_regex" >&5
7383 echo "${ECHO_T}$with_builtin_regex" >&6
7384
7385 if test "x${with_builtin_regex}" = xno; then
7386
7387 cf_regex_func=no
7388 cf_regex_libs=
7389 case "$host_os" in
7390 (mingw*)
7391 # -lsystre -ltre -lintl -liconv
7392 echo "$as_me:7392: checking for regcomp in -lsystre" >&5
7393 echo $ECHO_N "checking for regcomp in -lsystre... $ECHO_C" >&6
7394 if test "${ac_cv_lib_systre_regcomp+set}" = set; then
7395 echo $ECHO_N "(cached) $ECHO_C" >&6
7396 else
7397 ac_check_lib_save_LIBS=$LIBS
7398 LIBS="-lsystre $LIBS"
7399 cat >"conftest.$ac_ext" <<_ACEOF
7400 #line 7400 "configure"
7401 #include "confdefs.h"
7402
7403 /* Override any gcc2 internal prototype to avoid an error. */
7404 #ifdef __cplusplus
7405 extern "C"
7406 #endif
7407 /* We use char because int might match the return type of a gcc2
7408 builtin and then its argument prototype would still apply. */
7409 char regcomp (void);
7410 int
7411 main (void)
7412 {
7413 regcomp ();
7414 ;
7415 return 0;
7416 }
7417 _ACEOF
7418 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7419 if { (eval echo "$as_me:7419: \"$ac_link\"") >&5
7420 (eval $ac_link) 2>&5
7421 ac_status=$?
7422 echo "$as_me:7422: \$? = $ac_status" >&5
7423 (exit "$ac_status"); } &&
7424 { ac_try='test -s "conftest$ac_exeext"'
7425 { (eval echo "$as_me:7425: \"$ac_try\"") >&5
7426 (eval $ac_try) 2>&5
7427 ac_status=$?
7428 echo "$as_me:7428: \$? = $ac_status" >&5
7429 (exit "$ac_status"); }; }; then
7430 ac_cv_lib_systre_regcomp=yes
7431 else
7432 echo "$as_me: failed program was:" >&5
7433 cat "conftest.$ac_ext" >&5
7434 ac_cv_lib_systre_regcomp=no
7435 fi
7436 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7437 LIBS=$ac_check_lib_save_LIBS
7438 fi
7439 echo "$as_me:7439: result: $ac_cv_lib_systre_regcomp" >&5
7440 echo "${ECHO_T}$ac_cv_lib_systre_regcomp" >&6
7441 if test "$ac_cv_lib_systre_regcomp" = yes; then
7442
7443 echo "$as_me:7443: checking for libiconv_open in -liconv" >&5
7444 echo $ECHO_N "checking for libiconv_open in -liconv... $ECHO_C" >&6
7445 if test "${ac_cv_lib_iconv_libiconv_open+set}" = set; then
7446 echo $ECHO_N "(cached) $ECHO_C" >&6
7447 else
7448 ac_check_lib_save_LIBS=$LIBS
7449 LIBS="-liconv $LIBS"
7450 cat >"conftest.$ac_ext" <<_ACEOF
7451 #line 7451 "configure"
7452 #include "confdefs.h"
7453
7454 /* Override any gcc2 internal prototype to avoid an error. */
7455 #ifdef __cplusplus
7456 extern "C"
7457 #endif
7458 /* We use char because int might match the return type of a gcc2
7459 builtin and then its argument prototype would still apply. */
7460 char libiconv_open (void);
7461 int
7462 main (void)
7463 {
7464 libiconv_open ();
7465 ;
7466 return 0;
7467 }
7468 _ACEOF
7469 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7470 if { (eval echo "$as_me:7470: \"$ac_link\"") >&5
7471 (eval $ac_link) 2>&5
7472 ac_status=$?
7473 echo "$as_me:7473: \$? = $ac_status" >&5
7474 (exit "$ac_status"); } &&
7475 { ac_try='test -s "conftest$ac_exeext"'
7476 { (eval echo "$as_me:7476: \"$ac_try\"") >&5
7477 (eval $ac_try) 2>&5
7478 ac_status=$?
7479 echo "$as_me:7479: \$? = $ac_status" >&5
7480 (exit "$ac_status"); }; }; then
7481 ac_cv_lib_iconv_libiconv_open=yes
7482 else
7483 echo "$as_me: failed program was:" >&5
7484 cat "conftest.$ac_ext" >&5
7485 ac_cv_lib_iconv_libiconv_open=no
7486 fi
7487 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7488 LIBS=$ac_check_lib_save_LIBS
7489 fi
7490 echo "$as_me:7490: result: $ac_cv_lib_iconv_libiconv_open" >&5
7491 echo "${ECHO_T}$ac_cv_lib_iconv_libiconv_open" >&6
7492 if test "$ac_cv_lib_iconv_libiconv_open" = yes; then
7493
7494 cf_add_libs="$LIBS"
7495 # reverse order
7496 cf_add_0lib=
7497 for cf_add_1lib in -liconv; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7498 # filter duplicates
7499 for cf_add_1lib in $cf_add_0lib; do
7500 for cf_add_2lib in $cf_add_libs; do
7501 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7502 cf_add_1lib=
7503 break
7504 fi
7505 done
7506 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7507 done
7508 LIBS="$cf_add_libs"
7509
7510 fi
7511
7512 echo "$as_me:7512: checking for libintl_gettext in -lintl" >&5
7513 echo $ECHO_N "checking for libintl_gettext in -lintl... $ECHO_C" >&6
7514 if test "${ac_cv_lib_intl_libintl_gettext+set}" = set; then
7515 echo $ECHO_N "(cached) $ECHO_C" >&6
7516 else
7517 ac_check_lib_save_LIBS=$LIBS
7518 LIBS="-lintl $LIBS"
7519 cat >"conftest.$ac_ext" <<_ACEOF
7520 #line 7520 "configure"
7521 #include "confdefs.h"
7522
7523 /* Override any gcc2 internal prototype to avoid an error. */
7524 #ifdef __cplusplus
7525 extern "C"
7526 #endif
7527 /* We use char because int might match the return type of a gcc2
7528 builtin and then its argument prototype would still apply. */
7529 char libintl_gettext (void);
7530 int
7531 main (void)
7532 {
7533 libintl_gettext ();
7534 ;
7535 return 0;
7536 }
7537 _ACEOF
7538 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7539 if { (eval echo "$as_me:7539: \"$ac_link\"") >&5
7540 (eval $ac_link) 2>&5
7541 ac_status=$?
7542 echo "$as_me:7542: \$? = $ac_status" >&5
7543 (exit "$ac_status"); } &&
7544 { ac_try='test -s "conftest$ac_exeext"'
7545 { (eval echo "$as_me:7545: \"$ac_try\"") >&5
7546 (eval $ac_try) 2>&5
7547 ac_status=$?
7548 echo "$as_me:7548: \$? = $ac_status" >&5
7549 (exit "$ac_status"); }; }; then
7550 ac_cv_lib_intl_libintl_gettext=yes
7551 else
7552 echo "$as_me: failed program was:" >&5
7553 cat "conftest.$ac_ext" >&5
7554 ac_cv_lib_intl_libintl_gettext=no
7555 fi
7556 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7557 LIBS=$ac_check_lib_save_LIBS
7558 fi
7559 echo "$as_me:7559: result: $ac_cv_lib_intl_libintl_gettext" >&5
7560 echo "${ECHO_T}$ac_cv_lib_intl_libintl_gettext" >&6
7561 if test "$ac_cv_lib_intl_libintl_gettext" = yes; then
7562
7563 cf_add_libs="$LIBS"
7564 # reverse order
7565 cf_add_0lib=
7566 for cf_add_1lib in -lintl; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7567 # filter duplicates
7568 for cf_add_1lib in $cf_add_0lib; do
7569 for cf_add_2lib in $cf_add_libs; do
7570 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7571 cf_add_1lib=
7572 break
7573 fi
7574 done
7575 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7576 done
7577 LIBS="$cf_add_libs"
7578
7579 fi
7580
7581 echo "$as_me:7581: checking for tre_regcomp in -ltre" >&5
7582 echo $ECHO_N "checking for tre_regcomp in -ltre... $ECHO_C" >&6
7583 if test "${ac_cv_lib_tre_tre_regcomp+set}" = set; then
7584 echo $ECHO_N "(cached) $ECHO_C" >&6
7585 else
7586 ac_check_lib_save_LIBS=$LIBS
7587 LIBS="-ltre $LIBS"
7588 cat >"conftest.$ac_ext" <<_ACEOF
7589 #line 7589 "configure"
7590 #include "confdefs.h"
7591
7592 /* Override any gcc2 internal prototype to avoid an error. */
7593 #ifdef __cplusplus
7594 extern "C"
7595 #endif
7596 /* We use char because int might match the return type of a gcc2
7597 builtin and then its argument prototype would still apply. */
7598 char tre_regcomp (void);
7599 int
7600 main (void)
7601 {
7602 tre_regcomp ();
7603 ;
7604 return 0;
7605 }
7606 _ACEOF
7607 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7608 if { (eval echo "$as_me:7608: \"$ac_link\"") >&5
7609 (eval $ac_link) 2>&5
7610 ac_status=$?
7611 echo "$as_me:7611: \$? = $ac_status" >&5
7612 (exit "$ac_status"); } &&
7613 { ac_try='test -s "conftest$ac_exeext"'
7614 { (eval echo "$as_me:7614: \"$ac_try\"") >&5
7615 (eval $ac_try) 2>&5
7616 ac_status=$?
7617 echo "$as_me:7617: \$? = $ac_status" >&5
7618 (exit "$ac_status"); }; }; then
7619 ac_cv_lib_tre_tre_regcomp=yes
7620 else
7621 echo "$as_me: failed program was:" >&5
7622 cat "conftest.$ac_ext" >&5
7623 ac_cv_lib_tre_tre_regcomp=no
7624 fi
7625 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7626 LIBS=$ac_check_lib_save_LIBS
7627 fi
7628 echo "$as_me:7628: result: $ac_cv_lib_tre_tre_regcomp" >&5
7629 echo "${ECHO_T}$ac_cv_lib_tre_tre_regcomp" >&6
7630 if test "$ac_cv_lib_tre_tre_regcomp" = yes; then
7631
7632 cf_add_libs="$LIBS"
7633 # reverse order
7634 cf_add_0lib=
7635 for cf_add_1lib in -ltre; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7636 # filter duplicates
7637 for cf_add_1lib in $cf_add_0lib; do
7638 for cf_add_2lib in $cf_add_libs; do
7639 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7640 cf_add_1lib=
7641 break
7642 fi
7643 done
7644 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7645 done
7646 LIBS="$cf_add_libs"
7647
7648 fi
7649
7650 cf_add_libs="$LIBS"
7651 # reverse order
7652 cf_add_0lib=
7653 for cf_add_1lib in -lsystre; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7654 # filter duplicates
7655 for cf_add_1lib in $cf_add_0lib; do
7656 for cf_add_2lib in $cf_add_libs; do
7657 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7658 cf_add_1lib=
7659 break
7660 fi
7661 done
7662 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7663 done
7664 LIBS="$cf_add_libs"
7665
7666 cf_regex_func=regcomp
7667
7668 else
7669
7670 echo "$as_me:7670: checking for regcomp in -lgnurx" >&5
7671 echo $ECHO_N "checking for regcomp in -lgnurx... $ECHO_C" >&6
7672 if test "${ac_cv_lib_gnurx_regcomp+set}" = set; then
7673 echo $ECHO_N "(cached) $ECHO_C" >&6
7674 else
7675 ac_check_lib_save_LIBS=$LIBS
7676 LIBS="-lgnurx $LIBS"
7677 cat >"conftest.$ac_ext" <<_ACEOF
7678 #line 7678 "configure"
7679 #include "confdefs.h"
7680
7681 /* Override any gcc2 internal prototype to avoid an error. */
7682 #ifdef __cplusplus
7683 extern "C"
7684 #endif
7685 /* We use char because int might match the return type of a gcc2
7686 builtin and then its argument prototype would still apply. */
7687 char regcomp (void);
7688 int
7689 main (void)
7690 {
7691 regcomp ();
7692 ;
7693 return 0;
7694 }
7695 _ACEOF
7696 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7697 if { (eval echo "$as_me:7697: \"$ac_link\"") >&5
7698 (eval $ac_link) 2>&5
7699 ac_status=$?
7700 echo "$as_me:7700: \$? = $ac_status" >&5
7701 (exit "$ac_status"); } &&
7702 { ac_try='test -s "conftest$ac_exeext"'
7703 { (eval echo "$as_me:7703: \"$ac_try\"") >&5
7704 (eval $ac_try) 2>&5
7705 ac_status=$?
7706 echo "$as_me:7706: \$? = $ac_status" >&5
7707 (exit "$ac_status"); }; }; then
7708 ac_cv_lib_gnurx_regcomp=yes
7709 else
7710 echo "$as_me: failed program was:" >&5
7711 cat "conftest.$ac_ext" >&5
7712 ac_cv_lib_gnurx_regcomp=no
7713 fi
7714 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7715 LIBS=$ac_check_lib_save_LIBS
7716 fi
7717 echo "$as_me:7717: result: $ac_cv_lib_gnurx_regcomp" >&5
7718 echo "${ECHO_T}$ac_cv_lib_gnurx_regcomp" >&6
7719 if test "$ac_cv_lib_gnurx_regcomp" = yes; then
7720
7721 cf_add_libs="$LIBS"
7722 # reverse order
7723 cf_add_0lib=
7724 for cf_add_1lib in -lgnurx; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7725 # filter duplicates
7726 for cf_add_1lib in $cf_add_0lib; do
7727 for cf_add_2lib in $cf_add_libs; do
7728 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7729 cf_add_1lib=
7730 break
7731 fi
7732 done
7733 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7734 done
7735 LIBS="$cf_add_libs"
7736
7737 cf_regex_func=regcomp
7738 fi
7739
7740 fi
7741
7742 ;;
7743 (*)
7744 cf_regex_libs="regex re"
7745 echo "$as_me:7745: checking for regcomp" >&5
7746 echo $ECHO_N "checking for regcomp... $ECHO_C" >&6
7747 if test "${ac_cv_func_regcomp+set}" = set; then
7748 echo $ECHO_N "(cached) $ECHO_C" >&6
7749 else
7750 cat >"conftest.$ac_ext" <<_ACEOF
7751 #line 7751 "configure"
7752 #include "confdefs.h"
7753 #define regcomp autoconf_temporary
7754 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
7755 #undef regcomp
7756
7757 #ifdef __cplusplus
7758 extern "C"
7759 #endif
7760
7761 /* We use char because int might match the return type of a gcc2
7762 builtin and then its argument prototype would still apply. */
7763 char regcomp (void);
7764
7765 int
7766 main (void)
7767 {
7768
7769 /* The GNU C library defines stubs for functions which it implements
7770 to always fail with ENOSYS. Some functions are actually named
7771 something starting with __ and the normal name is an alias. */
7772 #if defined (__stub_regcomp) || defined (__stub___regcomp)
7773 #error found stub for regcomp
7774 #endif
7775
7776 return regcomp ();
7777 ;
7778 return 0;
7779 }
7780 _ACEOF
7781 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7782 if { (eval echo "$as_me:7782: \"$ac_link\"") >&5
7783 (eval $ac_link) 2>&5
7784 ac_status=$?
7785 echo "$as_me:7785: \$? = $ac_status" >&5
7786 (exit "$ac_status"); } &&
7787 { ac_try='test -s "conftest$ac_exeext"'
7788 { (eval echo "$as_me:7788: \"$ac_try\"") >&5
7789 (eval $ac_try) 2>&5
7790 ac_status=$?
7791 echo "$as_me:7791: \$? = $ac_status" >&5
7792 (exit "$ac_status"); }; }; then
7793 ac_cv_func_regcomp=yes
7794 else
7795 echo "$as_me: failed program was:" >&5
7796 cat "conftest.$ac_ext" >&5
7797 ac_cv_func_regcomp=no
7798 fi
7799 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7800 fi
7801 echo "$as_me:7801: result: $ac_cv_func_regcomp" >&5
7802 echo "${ECHO_T}$ac_cv_func_regcomp" >&6
7803 if test "$ac_cv_func_regcomp" = yes; then
7804 cf_regex_func=regcomp
7805 else
7806
7807 for cf_regex_lib in $cf_regex_libs
7808 do
7809 as_ac_Lib=`echo "ac_cv_lib_$cf_regex_lib''_regcomp" | $as_tr_sh`
7810 echo "$as_me:7810: checking for regcomp in -l$cf_regex_lib" >&5
7811 echo $ECHO_N "checking for regcomp in -l$cf_regex_lib... $ECHO_C" >&6
7812 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
7813 echo $ECHO_N "(cached) $ECHO_C" >&6
7814 else
7815 ac_check_lib_save_LIBS=$LIBS
7816 LIBS="-l$cf_regex_lib $LIBS"
7817 cat >"conftest.$ac_ext" <<_ACEOF
7818 #line 7818 "configure"
7819 #include "confdefs.h"
7820
7821 /* Override any gcc2 internal prototype to avoid an error. */
7822 #ifdef __cplusplus
7823 extern "C"
7824 #endif
7825 /* We use char because int might match the return type of a gcc2
7826 builtin and then its argument prototype would still apply. */
7827 char regcomp (void);
7828 int
7829 main (void)
7830 {
7831 regcomp ();
7832 ;
7833 return 0;
7834 }
7835 _ACEOF
7836 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7837 if { (eval echo "$as_me:7837: \"$ac_link\"") >&5
7838 (eval $ac_link) 2>&5
7839 ac_status=$?
7840 echo "$as_me:7840: \$? = $ac_status" >&5
7841 (exit "$ac_status"); } &&
7842 { ac_try='test -s "conftest$ac_exeext"'
7843 { (eval echo "$as_me:7843: \"$ac_try\"") >&5
7844 (eval $ac_try) 2>&5
7845 ac_status=$?
7846 echo "$as_me:7846: \$? = $ac_status" >&5
7847 (exit "$ac_status"); }; }; then
7848 eval "$as_ac_Lib=yes"
7849 else
7850 echo "$as_me: failed program was:" >&5
7851 cat "conftest.$ac_ext" >&5
7852 eval "$as_ac_Lib=no"
7853 fi
7854 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7855 LIBS=$ac_check_lib_save_LIBS
7856 fi
7857 echo "$as_me:7857: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
7858 echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
7859 if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
7860
7861 cf_add_libs="$LIBS"
7862 # reverse order
7863 cf_add_0lib=
7864 for cf_add_1lib in -l$cf_regex_lib; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7865 # filter duplicates
7866 for cf_add_1lib in $cf_add_0lib; do
7867 for cf_add_2lib in $cf_add_libs; do
7868 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7869 cf_add_1lib=
7870 break
7871 fi
7872 done
7873 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7874 done
7875 LIBS="$cf_add_libs"
7876
7877 cf_regex_func=regcomp
7878 break
7879 fi
7880
7881 done
7882
7883 fi
7884
7885 ;;
7886 esac
7887
7888 if test "$cf_regex_func" = no ; then
7889 echo "$as_me:7889: checking for compile" >&5
7890 echo $ECHO_N "checking for compile... $ECHO_C" >&6
7891 if test "${ac_cv_func_compile+set}" = set; then
7892 echo $ECHO_N "(cached) $ECHO_C" >&6
7893 else
7894 cat >"conftest.$ac_ext" <<_ACEOF
7895 #line 7895 "configure"
7896 #include "confdefs.h"
7897 #define compile autoconf_temporary
7898 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
7899 #undef compile
7900
7901 #ifdef __cplusplus
7902 extern "C"
7903 #endif
7904
7905 /* We use char because int might match the return type of a gcc2
7906 builtin and then its argument prototype would still apply. */
7907 char compile (void);
7908
7909 int
7910 main (void)
7911 {
7912
7913 /* The GNU C library defines stubs for functions which it implements
7914 to always fail with ENOSYS. Some functions are actually named
7915 something starting with __ and the normal name is an alias. */
7916 #if defined (__stub_compile) || defined (__stub___compile)
7917 #error found stub for compile
7918 #endif
7919
7920 return compile ();
7921 ;
7922 return 0;
7923 }
7924 _ACEOF
7925 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7926 if { (eval echo "$as_me:7926: \"$ac_link\"") >&5
7927 (eval $ac_link) 2>&5
7928 ac_status=$?
7929 echo "$as_me:7929: \$? = $ac_status" >&5
7930 (exit "$ac_status"); } &&
7931 { ac_try='test -s "conftest$ac_exeext"'
7932 { (eval echo "$as_me:7932: \"$ac_try\"") >&5
7933 (eval $ac_try) 2>&5
7934 ac_status=$?
7935 echo "$as_me:7935: \$? = $ac_status" >&5
7936 (exit "$ac_status"); }; }; then
7937 ac_cv_func_compile=yes
7938 else
7939 echo "$as_me: failed program was:" >&5
7940 cat "conftest.$ac_ext" >&5
7941 ac_cv_func_compile=no
7942 fi
7943 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7944 fi
7945 echo "$as_me:7945: result: $ac_cv_func_compile" >&5
7946 echo "${ECHO_T}$ac_cv_func_compile" >&6
7947 if test "$ac_cv_func_compile" = yes; then
7948 cf_regex_func=compile
7949 else
7950
7951 echo "$as_me:7951: checking for compile in -lgen" >&5
7952 echo $ECHO_N "checking for compile in -lgen... $ECHO_C" >&6
7953 if test "${ac_cv_lib_gen_compile+set}" = set; then
7954 echo $ECHO_N "(cached) $ECHO_C" >&6
7955 else
7956 ac_check_lib_save_LIBS=$LIBS
7957 LIBS="-lgen $LIBS"
7958 cat >"conftest.$ac_ext" <<_ACEOF
7959 #line 7959 "configure"
7960 #include "confdefs.h"
7961
7962 /* Override any gcc2 internal prototype to avoid an error. */
7963 #ifdef __cplusplus
7964 extern "C"
7965 #endif
7966 /* We use char because int might match the return type of a gcc2
7967 builtin and then its argument prototype would still apply. */
7968 char compile (void);
7969 int
7970 main (void)
7971 {
7972 compile ();
7973 ;
7974 return 0;
7975 }
7976 _ACEOF
7977 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7978 if { (eval echo "$as_me:7978: \"$ac_link\"") >&5
7979 (eval $ac_link) 2>&5
7980 ac_status=$?
7981 echo "$as_me:7981: \$? = $ac_status" >&5
7982 (exit "$ac_status"); } &&
7983 { ac_try='test -s "conftest$ac_exeext"'
7984 { (eval echo "$as_me:7984: \"$ac_try\"") >&5
7985 (eval $ac_try) 2>&5
7986 ac_status=$?
7987 echo "$as_me:7987: \$? = $ac_status" >&5
7988 (exit "$ac_status"); }; }; then
7989 ac_cv_lib_gen_compile=yes
7990 else
7991 echo "$as_me: failed program was:" >&5
7992 cat "conftest.$ac_ext" >&5
7993 ac_cv_lib_gen_compile=no
7994 fi
7995 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7996 LIBS=$ac_check_lib_save_LIBS
7997 fi
7998 echo "$as_me:7998: result: $ac_cv_lib_gen_compile" >&5
7999 echo "${ECHO_T}$ac_cv_lib_gen_compile" >&6
8000 if test "$ac_cv_lib_gen_compile" = yes; then
8001
8002 cf_add_libs="$LIBS"
8003 # reverse order
8004 cf_add_0lib=
8005 for cf_add_1lib in -lgen; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8006 # filter duplicates
8007 for cf_add_1lib in $cf_add_0lib; do
8008 for cf_add_2lib in $cf_add_libs; do
8009 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8010 cf_add_1lib=
8011 break
8012 fi
8013 done
8014 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8015 done
8016 LIBS="$cf_add_libs"
8017
8018 cf_regex_func=compile
8019 fi
8020
8021 fi
8022
8023 fi
8024
8025 if test "$cf_regex_func" = no ; then
8026 { echo "$as_me:8026: WARNING: cannot find regular expression library" >&5
8027 echo "$as_me: WARNING: cannot find regular expression library" >&2;}
8028 fi
8029
8030 echo "$as_me:8030: checking for regular-expression headers" >&5
8031 echo $ECHO_N "checking for regular-expression headers... $ECHO_C" >&6
8032 if test "${cf_cv_regex_hdrs+set}" = set; then
8033 echo $ECHO_N "(cached) $ECHO_C" >&6
8034 else
8035
8036 cf_cv_regex_hdrs=no
8037 case "$cf_regex_func" in
8038 (compile)
8039 for cf_regex_hdr in regexp.h regexpr.h
8040 do
8041 cat >"conftest.$ac_ext" <<_ACEOF
8042 #line 8042 "configure"
8043 #include "confdefs.h"
8044 #include <$cf_regex_hdr>
8045 int
8046 main (void)
8047 {
8048
8049 char *p = compile("", "", "", 0);
8050 int x = step("", "");
8051 (void)p;
8052 (void)x;
8053
8054 ;
8055 return 0;
8056 }
8057 _ACEOF
8058 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8059 if { (eval echo "$as_me:8059: \"$ac_link\"") >&5
8060 (eval $ac_link) 2>&5
8061 ac_status=$?
8062 echo "$as_me:8062: \$? = $ac_status" >&5
8063 (exit "$ac_status"); } &&
8064 { ac_try='test -s "conftest$ac_exeext"'
8065 { (eval echo "$as_me:8065: \"$ac_try\"") >&5
8066 (eval $ac_try) 2>&5
8067 ac_status=$?
8068 echo "$as_me:8068: \$? = $ac_status" >&5
8069 (exit "$ac_status"); }; }; then
8070
8071 cf_cv_regex_hdrs=$cf_regex_hdr
8072 break
8073
8074 else
8075 echo "$as_me: failed program was:" >&5
8076 cat "conftest.$ac_ext" >&5
8077 fi
8078 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8079 done
8080 ;;
8081 (*)
8082 for cf_regex_hdr in regex.h
8083 do
8084 cat >"conftest.$ac_ext" <<_ACEOF
8085 #line 8085 "configure"
8086 #include "confdefs.h"
8087 #include <sys/types.h>
8088 #include <stdio.h>
8089 #include <$cf_regex_hdr>
8090 int
8091 main (void)
8092 {
8093
8094 regex_t *p = NULL;
8095 int x = regcomp(p, "", 0);
8096 int y = regexec(p, "", 0, 0, 0);
8097 (void)x;
8098 (void)y;
8099 regfree(p);
8100
8101 ;
8102 return 0;
8103 }
8104 _ACEOF
8105 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8106 if { (eval echo "$as_me:8106: \"$ac_link\"") >&5
8107 (eval $ac_link) 2>&5
8108 ac_status=$?
8109 echo "$as_me:8109: \$? = $ac_status" >&5
8110 (exit "$ac_status"); } &&
8111 { ac_try='test -s "conftest$ac_exeext"'
8112 { (eval echo "$as_me:8112: \"$ac_try\"") >&5
8113 (eval $ac_try) 2>&5
8114 ac_status=$?
8115 echo "$as_me:8115: \$? = $ac_status" >&5
8116 (exit "$ac_status"); }; }; then
8117
8118 cf_cv_regex_hdrs=$cf_regex_hdr
8119 break
8120
8121 else
8122 echo "$as_me: failed program was:" >&5
8123 cat "conftest.$ac_ext" >&5
8124 fi
8125 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8126 done
8127 ;;
8128 esac
8129
8130 fi
8131 echo "$as_me:8131: result: $cf_cv_regex_hdrs" >&5
8132 echo "${ECHO_T}$cf_cv_regex_hdrs" >&6
8133
8134 case "$cf_cv_regex_hdrs" in
8135 (no) { echo "$as_me:8135: WARNING: no regular expression header found" >&5
8136 echo "$as_me: WARNING: no regular expression header found" >&2;} ;;
8137 (regex.h)
8138 cat >>confdefs.h <<\EOF
8139 #define HAVE_REGEX_H_FUNCS 1
8140 EOF
8141 ;;
8142 (regexp.h)
8143 cat >>confdefs.h <<\EOF
8144 #define HAVE_REGEXP_H_FUNCS 1
8145 EOF
8146 ;;
8147 (regexpr.h)
8148 cat >>confdefs.h <<\EOF
8149 #define HAVE_REGEXPR_H_FUNCS 1
8150 EOF
8151 ;;
8152 esac
8153
8154 fi
8155
8156 ###############################################################################
8157 echo "$as_me:8157: checking if you want to use mawk's own srand/rand functions" >&5
8158 echo $ECHO_N "checking if you want to use mawk's own srand/rand functions... $ECHO_C" >&6
8159
8160 # Check whether --enable-builtin-srand or --disable-builtin-srand was given.
8161 if test "${enable_builtin_srand+set}" = set; then
8162 enableval="$enable_builtin_srand"
8163 test "$enableval" != yes && enableval=no
8164 if test "$enableval" != "no" ; then
8165 with_builtin_srand=yes
8166 else
8167 with_builtin_srand=no
8168 fi
8169 else
8170 enableval=no
8171 with_builtin_srand=no
8172
8173 fi;
8174 if test "x${with_builtin_srand}" != xno; then
8175 with_builtin_srand=yes
8176 fi
8177 echo "$as_me:8177: result: $with_builtin_srand" >&5
8178 echo "${ECHO_T}$with_builtin_srand" >&6
8179
8180 if test "x${with_builtin_srand}" = xno; then
8181
8182 for ac_header in limits.h
8183 do
8184 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8185 echo "$as_me:8185: checking for $ac_header" >&5
8186 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8187 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8188 echo $ECHO_N "(cached) $ECHO_C" >&6
8189 else
8190 cat >"conftest.$ac_ext" <<_ACEOF
8191 #line 8191 "configure"
8192 #include "confdefs.h"
8193 #include <$ac_header>
8194 _ACEOF
8195 if { (eval echo "$as_me:8195: \"$ac_cpp "conftest.$ac_ext"\"") >&5
8196 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
8197 ac_status=$?
8198 $EGREP -v '^ *\+' conftest.er1 >conftest.err
8199 rm -f conftest.er1
8200 cat conftest.err >&5
8201 echo "$as_me:8201: \$? = $ac_status" >&5
8202 (exit "$ac_status"); } >/dev/null; then
8203 if test -s conftest.err; then
8204 ac_cpp_err=$ac_c_preproc_warn_flag
8205 else
8206 ac_cpp_err=
8207 fi
8208 else
8209 ac_cpp_err=yes
8210 fi
8211 if test -z "$ac_cpp_err"; then
8212 eval "$as_ac_Header=yes"
8213 else
8214 echo "$as_me: failed program was:" >&5
8215 cat "conftest.$ac_ext" >&5
8216 eval "$as_ac_Header=no"
8217 fi
8218 rm -f conftest.err "conftest.$ac_ext"
8219 fi
8220 echo "$as_me:8220: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
8221 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
8222 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
8223 cat >>confdefs.h <<EOF
8224 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8225 EOF
8226
8227 fi
8228 done
8229
8230 echo "$as_me:8230: checking if you want to use arc4random" >&5
8231 echo $ECHO_N "checking if you want to use arc4random... $ECHO_C" >&6
8232
8233 # Check whether --enable-arc4random or --disable-arc4random was given.
8234 if test "${enable_arc4random+set}" = set; then
8235 enableval="$enable_arc4random"
8236 enable_arc4random=yes
8237 else
8238 enable_arc4random=no
8239 fi;
8240 echo "$as_me:8240: result: $enable_arc4random" >&5
8241 echo "${ECHO_T}$enable_arc4random" >&6
8242
8243 cf_srand_arc4random=
8244 if test "$enable_arc4random" = yes ; then
8245 echo "$as_me:8245: checking for arc4random" >&5
8246 echo $ECHO_N "checking for arc4random... $ECHO_C" >&6
8247 if test "${ac_cv_func_arc4random+set}" = set; then
8248 echo $ECHO_N "(cached) $ECHO_C" >&6
8249 else
8250 cat >"conftest.$ac_ext" <<_ACEOF
8251 #line 8251 "configure"
8252 #include "confdefs.h"
8253 #define arc4random autoconf_temporary
8254 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
8255 #undef arc4random
8256
8257 #ifdef __cplusplus
8258 extern "C"
8259 #endif
8260
8261 /* We use char because int might match the return type of a gcc2
8262 builtin and then its argument prototype would still apply. */
8263 char arc4random (void);
8264
8265 int
8266 main (void)
8267 {
8268
8269 /* The GNU C library defines stubs for functions which it implements
8270 to always fail with ENOSYS. Some functions are actually named
8271 something starting with __ and the normal name is an alias. */
8272 #if defined (__stub_arc4random) || defined (__stub___arc4random)
8273 #error found stub for arc4random
8274 #endif
8275
8276 return arc4random ();
8277 ;
8278 return 0;
8279 }
8280 _ACEOF
8281 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8282 if { (eval echo "$as_me:8282: \"$ac_link\"") >&5
8283 (eval $ac_link) 2>&5
8284 ac_status=$?
8285 echo "$as_me:8285: \$? = $ac_status" >&5
8286 (exit "$ac_status"); } &&
8287 { ac_try='test -s "conftest$ac_exeext"'
8288 { (eval echo "$as_me:8288: \"$ac_try\"") >&5
8289 (eval $ac_try) 2>&5
8290 ac_status=$?
8291 echo "$as_me:8291: \$? = $ac_status" >&5
8292 (exit "$ac_status"); }; }; then
8293 ac_cv_func_arc4random=yes
8294 else
8295 echo "$as_me: failed program was:" >&5
8296 cat "conftest.$ac_ext" >&5
8297 ac_cv_func_arc4random=no
8298 fi
8299 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8300 fi
8301 echo "$as_me:8301: result: $ac_cv_func_arc4random" >&5
8302 echo "${ECHO_T}$ac_cv_func_arc4random" >&6
8303 if test "$ac_cv_func_arc4random" = yes; then
8304 :
8305 else
8306 echo "$as_me:8306: checking for arc4random in -lbsd" >&5
8307 echo $ECHO_N "checking for arc4random in -lbsd... $ECHO_C" >&6
8308 if test "${ac_cv_lib_bsd_arc4random+set}" = set; then
8309 echo $ECHO_N "(cached) $ECHO_C" >&6
8310 else
8311 ac_check_lib_save_LIBS=$LIBS
8312 LIBS="-lbsd $LIBS"
8313 cat >"conftest.$ac_ext" <<_ACEOF
8314 #line 8314 "configure"
8315 #include "confdefs.h"
8316
8317 /* Override any gcc2 internal prototype to avoid an error. */
8318 #ifdef __cplusplus
8319 extern "C"
8320 #endif
8321 /* We use char because int might match the return type of a gcc2
8322 builtin and then its argument prototype would still apply. */
8323 char arc4random (void);
8324 int
8325 main (void)
8326 {
8327 arc4random ();
8328 ;
8329 return 0;
8330 }
8331 _ACEOF
8332 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8333 if { (eval echo "$as_me:8333: \"$ac_link\"") >&5
8334 (eval $ac_link) 2>&5
8335 ac_status=$?
8336 echo "$as_me:8336: \$? = $ac_status" >&5
8337 (exit "$ac_status"); } &&
8338 { ac_try='test -s "conftest$ac_exeext"'
8339 { (eval echo "$as_me:8339: \"$ac_try\"") >&5
8340 (eval $ac_try) 2>&5
8341 ac_status=$?
8342 echo "$as_me:8342: \$? = $ac_status" >&5
8343 (exit "$ac_status"); }; }; then
8344 ac_cv_lib_bsd_arc4random=yes
8345 else
8346 echo "$as_me: failed program was:" >&5
8347 cat "conftest.$ac_ext" >&5
8348 ac_cv_lib_bsd_arc4random=no
8349 fi
8350 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8351 LIBS=$ac_check_lib_save_LIBS
8352 fi
8353 echo "$as_me:8353: result: $ac_cv_lib_bsd_arc4random" >&5
8354 echo "${ECHO_T}$ac_cv_lib_bsd_arc4random" >&6
8355 if test "$ac_cv_lib_bsd_arc4random" = yes; then
8356
8357 cf_add_libs="$LIBS"
8358 # reverse order
8359 cf_add_0lib=
8360 for cf_add_1lib in -lbsd; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8361 # filter duplicates
8362 for cf_add_1lib in $cf_add_0lib; do
8363 for cf_add_2lib in $cf_add_libs; do
8364 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8365 cf_add_1lib=
8366 break
8367 fi
8368 done
8369 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8370 done
8371 LIBS="$cf_add_libs"
8372
8373 fi
8374
8375 fi
8376
8377 test "$ac_cv_func_arc4random" = yes && cf_srand_arc4random=arc4random_stir/arc4random
8378 fi
8379
8380 echo "$as_me:8380: checking for random-integer functions" >&5
8381 echo $ECHO_N "checking for random-integer functions... $ECHO_C" >&6
8382 if test "${cf_cv_srand_func+set}" = set; then
8383 echo $ECHO_N "(cached) $ECHO_C" >&6
8384 else
8385
8386 cf_cv_srand_func=unknown
8387 for cf_func in $cf_srand_arc4random srandom/random srand48/lrand48 srand/rand
8388 do
8389
8390 cf_srand_func=`echo $cf_func | sed -e 's%/.*%%'`
8391 cf_rand_func=`echo $cf_func | sed -e 's%.*/%%'`
8392
8393 case $cf_srand_func in
8394 (arc4random_stir)
8395 cf_srand_func='(void)'
8396 ;;
8397 esac
8398
8399 cat >"conftest.$ac_ext" <<_ACEOF
8400 #line 8400 "configure"
8401 #include "confdefs.h"
8402
8403 $ac_includes_default
8404 #ifdef HAVE_LIMITS_H
8405 #include <limits.h>
8406 #endif
8407
8408 int
8409 main (void)
8410 {
8411 long seed = 1; $cf_srand_func(seed); seed = $cf_rand_func(); (void)seed
8412 ;
8413 return 0;
8414 }
8415 _ACEOF
8416 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8417 if { (eval echo "$as_me:8417: \"$ac_link\"") >&5
8418 (eval $ac_link) 2>&5
8419 ac_status=$?
8420 echo "$as_me:8420: \$? = $ac_status" >&5
8421 (exit "$ac_status"); } &&
8422 { ac_try='test -s "conftest$ac_exeext"'
8423 { (eval echo "$as_me:8423: \"$ac_try\"") >&5
8424 (eval $ac_try) 2>&5
8425 ac_status=$?
8426 echo "$as_me:8426: \$? = $ac_status" >&5
8427 (exit "$ac_status"); }; }; then
8428 cf_cv_srand_func=$cf_func
8429 break
8430 else
8431 echo "$as_me: failed program was:" >&5
8432 cat "conftest.$ac_ext" >&5
8433 fi
8434 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8435 done
8436
8437 fi
8438 echo "$as_me:8438: result: $cf_cv_srand_func" >&5
8439 echo "${ECHO_T}$cf_cv_srand_func" >&6
8440 if test "$cf_cv_srand_func" != unknown ; then
8441 echo "$as_me:8441: checking for range of random-integers" >&5
8442 echo $ECHO_N "checking for range of random-integers... $ECHO_C" >&6
8443 if test "${cf_cv_rand_max+set}" = set; then
8444 echo $ECHO_N "(cached) $ECHO_C" >&6
8445 else
8446
8447 case "$cf_cv_srand_func" in
8448 (srand/rand)
8449 cf_cv_rand_max=RAND_MAX
8450 cf_rand_max=16
8451 ;;
8452 (*/arc4random)
8453 cf_cv_rand_max=0xFFFFFFFFUL
8454 cf_rand_max=32
8455 ;;
8456 (*)
8457 cf_cv_rand_max=INT_MAX
8458 cf_rand_max=31
8459 ;;
8460 esac
8461 cat >"conftest.$ac_ext" <<_ACEOF
8462 #line 8462 "configure"
8463 #include "confdefs.h"
8464
8465 $ac_includes_default
8466 #ifdef HAVE_LIMITS_H
8467 #include <limits.h>
8468 #endif
8469
8470 int
8471 main (void)
8472 {
8473 long x = $cf_cv_rand_max; (void)x
8474 ;
8475 return 0;
8476 }
8477 _ACEOF
8478 rm -f "conftest.$ac_objext"
8479 if { (eval echo "$as_me:8479: \"$ac_compile\"") >&5
8480 (eval $ac_compile) 2>&5
8481 ac_status=$?
8482 echo "$as_me:8482: \$? = $ac_status" >&5
8483 (exit "$ac_status"); } &&
8484 { ac_try='test -s "conftest.$ac_objext"'
8485 { (eval echo "$as_me:8485: \"$ac_try\"") >&5
8486 (eval $ac_try) 2>&5
8487 ac_status=$?
8488 echo "$as_me:8488: \$? = $ac_status" >&5
8489 (exit "$ac_status"); }; }; then
8490 :
8491 else
8492 echo "$as_me: failed program was:" >&5
8493 cat "conftest.$ac_ext" >&5
8494 cf_cv_rand_max="(1UL<<$cf_rand_max)-1"
8495 fi
8496 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8497
8498 fi
8499 echo "$as_me:8499: result: $cf_cv_rand_max" >&5
8500 echo "${ECHO_T}$cf_cv_rand_max" >&6
8501
8502 case "$cf_cv_srand_func" in
8503 (*/arc4random)
8504 echo "$as_me:8504: checking if <bsd/stdlib.h> should be included" >&5
8505 echo $ECHO_N "checking if <bsd/stdlib.h> should be included... $ECHO_C" >&6
8506 cat >"conftest.$ac_ext" <<_ACEOF
8507 #line 8507 "configure"
8508 #include "confdefs.h"
8509
8510 $ac_includes_default
8511 #ifdef HAVE_LIMITS_H
8512 #include <limits.h>
8513 #endif
8514 #include <bsd/stdlib.h>
8515 int
8516 main (void)
8517 {
8518 void *arc4random(int);
8519 void *x = arc4random(1); (void)x
8520 ;
8521 return 0;
8522 }
8523 _ACEOF
8524 rm -f "conftest.$ac_objext"
8525 if { (eval echo "$as_me:8525: \"$ac_compile\"") >&5
8526 (eval $ac_compile) 2>&5
8527 ac_status=$?
8528 echo "$as_me:8528: \$? = $ac_status" >&5
8529 (exit "$ac_status"); } &&
8530 { ac_try='test -s "conftest.$ac_objext"'
8531 { (eval echo "$as_me:8531: \"$ac_try\"") >&5
8532 (eval $ac_try) 2>&5
8533 ac_status=$?
8534 echo "$as_me:8534: \$? = $ac_status" >&5
8535 (exit "$ac_status"); }; }; then
8536 cf_bsd_stdlib_h=no
8537 else
8538 echo "$as_me: failed program was:" >&5
8539 cat "conftest.$ac_ext" >&5
8540 cat >"conftest.$ac_ext" <<_ACEOF
8541 #line 8541 "configure"
8542 #include "confdefs.h"
8543
8544 $ac_includes_default
8545 #ifdef HAVE_LIMITS_H
8546 #include <limits.h>
8547 #endif
8548 #include <bsd/stdlib.h>
8549 int
8550 main (void)
8551 {
8552 unsigned long x = arc4random(); (void)x
8553 ;
8554 return 0;
8555 }
8556 _ACEOF
8557 rm -f "conftest.$ac_objext"
8558 if { (eval echo "$as_me:8558: \"$ac_compile\"") >&5
8559 (eval $ac_compile) 2>&5
8560 ac_status=$?
8561 echo "$as_me:8561: \$? = $ac_status" >&5
8562 (exit "$ac_status"); } &&
8563 { ac_try='test -s "conftest.$ac_objext"'
8564 { (eval echo "$as_me:8564: \"$ac_try\"") >&5
8565 (eval $ac_try) 2>&5
8566 ac_status=$?
8567 echo "$as_me:8567: \$? = $ac_status" >&5
8568 (exit "$ac_status"); }; }; then
8569 cf_bsd_stdlib_h=yes
8570 else
8571 echo "$as_me: failed program was:" >&5
8572 cat "conftest.$ac_ext" >&5
8573 cf_bsd_stdlib_h=no
8574 fi
8575 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8576 fi
8577 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8578 echo "$as_me:8578: result: $cf_bsd_stdlib_h" >&5
8579 echo "${ECHO_T}$cf_bsd_stdlib_h" >&6
8580 if test "$cf_bsd_stdlib_h" = yes
8581 then
8582
8583 cat >>confdefs.h <<\EOF
8584 #define HAVE_BSD_STDLIB_H 1
8585 EOF
8586
8587 else
8588 echo "$as_me:8588: checking if <bsd/random.h> should be included" >&5
8589 echo $ECHO_N "checking if <bsd/random.h> should be included... $ECHO_C" >&6
8590 cat >"conftest.$ac_ext" <<_ACEOF
8591 #line 8591 "configure"
8592 #include "confdefs.h"
8593
8594 $ac_includes_default
8595 #ifdef HAVE_LIMITS_H
8596 #include <limits.h>
8597 #endif
8598 #include <bsd/random.h>
8599 int
8600 main (void)
8601 {
8602 void *arc4random(int);
8603 void *x = arc4random(1); (void)x
8604 ;
8605 return 0;
8606 }
8607 _ACEOF
8608 rm -f "conftest.$ac_objext"
8609 if { (eval echo "$as_me:8609: \"$ac_compile\"") >&5
8610 (eval $ac_compile) 2>&5
8611 ac_status=$?
8612 echo "$as_me:8612: \$? = $ac_status" >&5
8613 (exit "$ac_status"); } &&
8614 { ac_try='test -s "conftest.$ac_objext"'
8615 { (eval echo "$as_me:8615: \"$ac_try\"") >&5
8616 (eval $ac_try) 2>&5
8617 ac_status=$?
8618 echo "$as_me:8618: \$? = $ac_status" >&5
8619 (exit "$ac_status"); }; }; then
8620 cf_bsd_random_h=no
8621 else
8622 echo "$as_me: failed program was:" >&5
8623 cat "conftest.$ac_ext" >&5
8624 cat >"conftest.$ac_ext" <<_ACEOF
8625 #line 8625 "configure"
8626 #include "confdefs.h"
8627 #include <bsd/random.h>
8628 int
8629 main (void)
8630 {
8631 unsigned long x = arc4random(); (void)x
8632 ;
8633 return 0;
8634 }
8635 _ACEOF
8636 rm -f "conftest.$ac_objext"
8637 if { (eval echo "$as_me:8637: \"$ac_compile\"") >&5
8638 (eval $ac_compile) 2>&5
8639 ac_status=$?
8640 echo "$as_me:8640: \$? = $ac_status" >&5
8641 (exit "$ac_status"); } &&
8642 { ac_try='test -s "conftest.$ac_objext"'
8643 { (eval echo "$as_me:8643: \"$ac_try\"") >&5
8644 (eval $ac_try) 2>&5
8645 ac_status=$?
8646 echo "$as_me:8646: \$? = $ac_status" >&5
8647 (exit "$ac_status"); }; }; then
8648 cf_bsd_random_h=yes
8649 else
8650 echo "$as_me: failed program was:" >&5
8651 cat "conftest.$ac_ext" >&5
8652 cf_bsd_random_h=no
8653 fi
8654 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8655 fi
8656 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
8657 echo "$as_me:8657: result: $cf_bsd_random_h" >&5
8658 echo "${ECHO_T}$cf_bsd_random_h" >&6
8659 if test "$cf_bsd_random_h" = yes
8660 then
8661
8662 cat >>confdefs.h <<\EOF
8663 #define HAVE_BSD_RANDOM_H 1
8664 EOF
8665
8666 else
8667 { echo "$as_me:8667: WARNING: no header file found for arc4random" >&5
8668 echo "$as_me: WARNING: no header file found for arc4random" >&2;}
8669 fi
8670 fi
8671 ;;
8672 esac
8673
8674 cf_srand_func=`echo $cf_func | sed -e 's%/.*%%'`
8675 cf_rand_func=`echo $cf_func | sed -e 's%.*/%%'`
8676
8677 case $cf_srand_func in
8678 (arc4random_stir)
8679 cf_srand_func='(void)'
8680 ;;
8681 esac
8682
8683 cf_rand_max=`echo "mawk_rand_max" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
8684
8685 cat >>confdefs.h <<EOF
8686 #define mawk_srand $cf_srand_func
8687 EOF
8688
8689 cat >>confdefs.h <<EOF
8690 #define mawk_rand $cf_rand_func
8691 EOF
8692
8693 cat >>confdefs.h <<EOF
8694 #define $cf_rand_max $cf_cv_rand_max
8695 EOF
8696
8697 fi
8698
8699 cat >>confdefs.h <<EOF
8700 #define NAME_RANDOM "$cf_cv_srand_func"
8701 EOF
8702
8703 fi
8704
8705 ###############################################################################
8706 echo "$as_me:8706: checking if you want mawk to initialize random numbers at startup" >&5
8707 echo $ECHO_N "checking if you want mawk to initialize random numbers at startup... $ECHO_C" >&6
8708
8709 # Check whether --enable-init-srand or --disable-init-srand was given.
8710 if test "${enable_init_srand+set}" = set; then
8711 enableval="$enable_init_srand"
8712 test "$enableval" != no && enableval=yes
8713 if test "$enableval" != "yes" ; then
8714 with_init_srand=no
8715 else
8716 with_init_srand=yes
8717 fi
8718 else
8719 enableval=yes
8720 with_init_srand=yes
8721
8722 fi;
8723 if test "x${with_init_srand}" != xno; then
8724 with_init_srand=yes
8725 else
8726
8727 cat >>confdefs.h <<\EOF
8728 #define NO_INIT_SRAND 1
8729 EOF
8730
8731 fi
8732 echo "$as_me:8732: result: $with_init_srand" >&5
8733 echo "${ECHO_T}$with_init_srand" >&6
8734
8735 ###############################################################################
8736 echo "$as_me:8736: checking if you want mawk to support regex interval expressions {m,n}" >&5
8737 echo $ECHO_N "checking if you want mawk to support regex interval expressions {m,n}... $ECHO_C" >&6
8738
8739 # Check whether --enable-interval-expr or --disable-interval-expr was given.
8740 if test "${enable_interval_expr+set}" = set; then
8741 enableval="$enable_interval_expr"
8742 test "$enableval" != no && enableval=yes
8743 if test "$enableval" != "yes" ; then
8744 with_interval_expr=no
8745 else
8746 with_interval_expr=yes
8747 fi
8748 else
8749 enableval=yes
8750 with_interval_expr=yes
8751
8752 fi;
8753 if test "x${with_interval_expr}" != xno; then
8754 with_interval_expr=yes
8755 else
8756
8757 cat >>confdefs.h <<\EOF
8758 #define NO_INTERVAL_EXPR 1
8759 EOF
8760
8761 fi
8762 echo "$as_me:8762: result: $with_interval_expr" >&5
8763 echo "${ECHO_T}$with_interval_expr" >&6
8764
8765 ###############################################################################
8766
8767 echo "$as_me:8767: checking if you want to use dmalloc for testing" >&5
8768 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
8769
8770 # Check whether --with-dmalloc or --without-dmalloc was given.
8771 if test "${with_dmalloc+set}" = set; then
8772 withval="$with_dmalloc"
8773 case "x$withval" in
8774 (x|xno) ;;
8775 (*)
8776 : "${with_cflags:=-g}"
8777 : "${enable_leaks:=no}"
8778 with_dmalloc=yes
8779
8780 cat >>confdefs.h <<EOF
8781 #define USE_DMALLOC 1
8782 EOF
8783
8784 ;;
8785 esac
8786 else
8787 with_dmalloc=
8788 fi;
8789 echo "$as_me:8789: result: ${with_dmalloc:-no}" >&5
8790 echo "${ECHO_T}${with_dmalloc:-no}" >&6
8791
8792 case ".$with_cflags" in
8793 (.*-g*)
8794 case .$CFLAGS in
8795 (.*-g*)
8796 ;;
8797 (*)
8798
8799 cf_fix_cppflags=no
8800 cf_new_cflags=
8801 cf_new_cppflags=
8802 cf_new_extra_cppflags=
8803
8804 for cf_add_cflags in -g
8805 do
8806 case "$cf_fix_cppflags" in
8807 (no)
8808 case "$cf_add_cflags" in
8809 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
8810 case "$cf_add_cflags" in
8811 (-D*)
8812 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
8813
8814 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8815 && test -z "${cf_tst_cflags}" \
8816 && cf_fix_cppflags=yes
8817
8818 if test "$cf_fix_cppflags" = yes ; then
8819
8820 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8821 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8822
8823 continue
8824 elif test "${cf_tst_cflags}" = "\"'" ; then
8825
8826 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8827 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8828
8829 continue
8830 fi
8831 ;;
8832 esac
8833 case "$CPPFLAGS" in
8834 (*$cf_add_cflags)
8835 ;;
8836 (*)
8837 case "$cf_add_cflags" in
8838 (-D*)
8839 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
8840
8841 CPPFLAGS=`echo "$CPPFLAGS" | \
8842 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
8843 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
8844
8845 ;;
8846 esac
8847
8848 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
8849 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
8850
8851 ;;
8852 esac
8853 ;;
8854 (*)
8855
8856 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
8857 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
8858
8859 ;;
8860 esac
8861 ;;
8862 (yes)
8863
8864 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
8865 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
8866
8867 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
8868
8869 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
8870 && test -z "${cf_tst_cflags}" \
8871 && cf_fix_cppflags=no
8872 ;;
8873 esac
8874 done
8875
8876 if test -n "$cf_new_cflags" ; then
8877
8878 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
8879 CFLAGS="${CFLAGS}$cf_new_cflags"
8880
8881 fi
8882
8883 if test -n "$cf_new_cppflags" ; then
8884
8885 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
8886 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
8887
8888 fi
8889
8890 if test -n "$cf_new_extra_cppflags" ; then
8891
8892 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
8893 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
8894
8895 fi
8896
8897 ;;
8898 esac
8899 ;;
8900 esac
8901
8902 if test "$with_dmalloc" = yes ; then
8903 echo "$as_me:8903: checking for dmalloc.h" >&5
8904 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
8905 if test "${ac_cv_header_dmalloc_h+set}" = set; then
8906 echo $ECHO_N "(cached) $ECHO_C" >&6
8907 else
8908 cat >"conftest.$ac_ext" <<_ACEOF
8909 #line 8909 "configure"
8910 #include "confdefs.h"
8911 #include <dmalloc.h>
8912 _ACEOF
8913 if { (eval echo "$as_me:8913: \"$ac_cpp "conftest.$ac_ext"\"") >&5
8914 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
8915 ac_status=$?
8916 $EGREP -v '^ *\+' conftest.er1 >conftest.err
8917 rm -f conftest.er1
8918 cat conftest.err >&5
8919 echo "$as_me:8919: \$? = $ac_status" >&5
8920 (exit "$ac_status"); } >/dev/null; then
8921 if test -s conftest.err; then
8922 ac_cpp_err=$ac_c_preproc_warn_flag
8923 else
8924 ac_cpp_err=
8925 fi
8926 else
8927 ac_cpp_err=yes
8928 fi
8929 if test -z "$ac_cpp_err"; then
8930 ac_cv_header_dmalloc_h=yes
8931 else
8932 echo "$as_me: failed program was:" >&5
8933 cat "conftest.$ac_ext" >&5
8934 ac_cv_header_dmalloc_h=no
8935 fi
8936 rm -f conftest.err "conftest.$ac_ext"
8937 fi
8938 echo "$as_me:8938: result: $ac_cv_header_dmalloc_h" >&5
8939 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
8940 if test "$ac_cv_header_dmalloc_h" = yes; then
8941
8942 echo "$as_me:8942: checking for dmalloc_debug in -ldmalloc" >&5
8943 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
8944 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
8945 echo $ECHO_N "(cached) $ECHO_C" >&6
8946 else
8947 ac_check_lib_save_LIBS=$LIBS
8948 LIBS="-ldmalloc $LIBS"
8949 cat >"conftest.$ac_ext" <<_ACEOF
8950 #line 8950 "configure"
8951 #include "confdefs.h"
8952
8953 /* Override any gcc2 internal prototype to avoid an error. */
8954 #ifdef __cplusplus
8955 extern "C"
8956 #endif
8957 /* We use char because int might match the return type of a gcc2
8958 builtin and then its argument prototype would still apply. */
8959 char dmalloc_debug (void);
8960 int
8961 main (void)
8962 {
8963 dmalloc_debug ();
8964 ;
8965 return 0;
8966 }
8967 _ACEOF
8968 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
8969 if { (eval echo "$as_me:8969: \"$ac_link\"") >&5
8970 (eval $ac_link) 2>&5
8971 ac_status=$?
8972 echo "$as_me:8972: \$? = $ac_status" >&5
8973 (exit "$ac_status"); } &&
8974 { ac_try='test -s "conftest$ac_exeext"'
8975 { (eval echo "$as_me:8975: \"$ac_try\"") >&5
8976 (eval $ac_try) 2>&5
8977 ac_status=$?
8978 echo "$as_me:8978: \$? = $ac_status" >&5
8979 (exit "$ac_status"); }; }; then
8980 ac_cv_lib_dmalloc_dmalloc_debug=yes
8981 else
8982 echo "$as_me: failed program was:" >&5
8983 cat "conftest.$ac_ext" >&5
8984 ac_cv_lib_dmalloc_dmalloc_debug=no
8985 fi
8986 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8987 LIBS=$ac_check_lib_save_LIBS
8988 fi
8989 echo "$as_me:8989: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
8990 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
8991 if test "$ac_cv_lib_dmalloc_dmalloc_debug" = yes; then
8992 cat >>confdefs.h <<EOF
8993 #define HAVE_LIBDMALLOC 1
8994 EOF
8995
8996 LIBS="-ldmalloc $LIBS"
8997
8998 fi
8999
9000 fi
9001
9002 fi
9003
9004 echo "$as_me:9004: checking if you want to use dbmalloc for testing" >&5
9005 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
9006
9007 # Check whether --with-dbmalloc or --without-dbmalloc was given.
9008 if test "${with_dbmalloc+set}" = set; then
9009 withval="$with_dbmalloc"
9010 case "x$withval" in
9011 (x|xno) ;;
9012 (*)
9013 : "${with_cflags:=-g}"
9014 : "${enable_leaks:=no}"
9015 with_dbmalloc=yes
9016
9017 cat >>confdefs.h <<EOF
9018 #define USE_DBMALLOC 1
9019 EOF
9020
9021 ;;
9022 esac
9023 else
9024 with_dbmalloc=
9025 fi;
9026 echo "$as_me:9026: result: ${with_dbmalloc:-no}" >&5
9027 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
9028
9029 case ".$with_cflags" in
9030 (.*-g*)
9031 case .$CFLAGS in
9032 (.*-g*)
9033 ;;
9034 (*)
9035
9036 cf_fix_cppflags=no
9037 cf_new_cflags=
9038 cf_new_cppflags=
9039 cf_new_extra_cppflags=
9040
9041 for cf_add_cflags in -g
9042 do
9043 case "$cf_fix_cppflags" in
9044 (no)
9045 case "$cf_add_cflags" in
9046 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9047 case "$cf_add_cflags" in
9048 (-D*)
9049 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9050
9051 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9052 && test -z "${cf_tst_cflags}" \
9053 && cf_fix_cppflags=yes
9054
9055 if test "$cf_fix_cppflags" = yes ; then
9056
9057 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9058 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9059
9060 continue
9061 elif test "${cf_tst_cflags}" = "\"'" ; then
9062
9063 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9064 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9065
9066 continue
9067 fi
9068 ;;
9069 esac
9070 case "$CPPFLAGS" in
9071 (*$cf_add_cflags)
9072 ;;
9073 (*)
9074 case "$cf_add_cflags" in
9075 (-D*)
9076 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9077
9078 CPPFLAGS=`echo "$CPPFLAGS" | \
9079 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9080 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9081
9082 ;;
9083 esac
9084
9085 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9086 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9087
9088 ;;
9089 esac
9090 ;;
9091 (*)
9092
9093 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9094 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9095
9096 ;;
9097 esac
9098 ;;
9099 (yes)
9100
9101 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9102 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9103
9104 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
9105
9106 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9107 && test -z "${cf_tst_cflags}" \
9108 && cf_fix_cppflags=no
9109 ;;
9110 esac
9111 done
9112
9113 if test -n "$cf_new_cflags" ; then
9114
9115 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9116 CFLAGS="${CFLAGS}$cf_new_cflags"
9117
9118 fi
9119
9120 if test -n "$cf_new_cppflags" ; then
9121
9122 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9123 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9124
9125 fi
9126
9127 if test -n "$cf_new_extra_cppflags" ; then
9128
9129 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9130 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9131
9132 fi
9133
9134 ;;
9135 esac
9136 ;;
9137 esac
9138
9139 if test "$with_dbmalloc" = yes ; then
9140 echo "$as_me:9140: checking for dbmalloc.h" >&5
9141 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
9142 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
9143 echo $ECHO_N "(cached) $ECHO_C" >&6
9144 else
9145 cat >"conftest.$ac_ext" <<_ACEOF
9146 #line 9146 "configure"
9147 #include "confdefs.h"
9148 #include <dbmalloc.h>
9149 _ACEOF
9150 if { (eval echo "$as_me:9150: \"$ac_cpp "conftest.$ac_ext"\"") >&5
9151 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
9152 ac_status=$?
9153 $EGREP -v '^ *\+' conftest.er1 >conftest.err
9154 rm -f conftest.er1
9155 cat conftest.err >&5
9156 echo "$as_me:9156: \$? = $ac_status" >&5
9157 (exit "$ac_status"); } >/dev/null; then
9158 if test -s conftest.err; then
9159 ac_cpp_err=$ac_c_preproc_warn_flag
9160 else
9161 ac_cpp_err=
9162 fi
9163 else
9164 ac_cpp_err=yes
9165 fi
9166 if test -z "$ac_cpp_err"; then
9167 ac_cv_header_dbmalloc_h=yes
9168 else
9169 echo "$as_me: failed program was:" >&5
9170 cat "conftest.$ac_ext" >&5
9171 ac_cv_header_dbmalloc_h=no
9172 fi
9173 rm -f conftest.err "conftest.$ac_ext"
9174 fi
9175 echo "$as_me:9175: result: $ac_cv_header_dbmalloc_h" >&5
9176 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
9177 if test "$ac_cv_header_dbmalloc_h" = yes; then
9178
9179 echo "$as_me:9179: checking for debug_malloc in -ldbmalloc" >&5
9180 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
9181 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
9182 echo $ECHO_N "(cached) $ECHO_C" >&6
9183 else
9184 ac_check_lib_save_LIBS=$LIBS
9185 LIBS="-ldbmalloc $LIBS"
9186 cat >"conftest.$ac_ext" <<_ACEOF
9187 #line 9187 "configure"
9188 #include "confdefs.h"
9189
9190 /* Override any gcc2 internal prototype to avoid an error. */
9191 #ifdef __cplusplus
9192 extern "C"
9193 #endif
9194 /* We use char because int might match the return type of a gcc2
9195 builtin and then its argument prototype would still apply. */
9196 char debug_malloc (void);
9197 int
9198 main (void)
9199 {
9200 debug_malloc ();
9201 ;
9202 return 0;
9203 }
9204 _ACEOF
9205 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9206 if { (eval echo "$as_me:9206: \"$ac_link\"") >&5
9207 (eval $ac_link) 2>&5
9208 ac_status=$?
9209 echo "$as_me:9209: \$? = $ac_status" >&5
9210 (exit "$ac_status"); } &&
9211 { ac_try='test -s "conftest$ac_exeext"'
9212 { (eval echo "$as_me:9212: \"$ac_try\"") >&5
9213 (eval $ac_try) 2>&5
9214 ac_status=$?
9215 echo "$as_me:9215: \$? = $ac_status" >&5
9216 (exit "$ac_status"); }; }; then
9217 ac_cv_lib_dbmalloc_debug_malloc=yes
9218 else
9219 echo "$as_me: failed program was:" >&5
9220 cat "conftest.$ac_ext" >&5
9221 ac_cv_lib_dbmalloc_debug_malloc=no
9222 fi
9223 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9224 LIBS=$ac_check_lib_save_LIBS
9225 fi
9226 echo "$as_me:9226: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
9227 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
9228 if test "$ac_cv_lib_dbmalloc_debug_malloc" = yes; then
9229 cat >>confdefs.h <<EOF
9230 #define HAVE_LIBDBMALLOC 1
9231 EOF
9232
9233 LIBS="-ldbmalloc $LIBS"
9234
9235 fi
9236
9237 fi
9238
9239 fi
9240
9241 echo "$as_me:9241: checking if you want to use valgrind for testing" >&5
9242 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
9243
9244 # Check whether --with-valgrind or --without-valgrind was given.
9245 if test "${with_valgrind+set}" = set; then
9246 withval="$with_valgrind"
9247 case "x$withval" in
9248 (x|xno) ;;
9249 (*)
9250 : "${with_cflags:=-g}"
9251 : "${enable_leaks:=no}"
9252 with_valgrind=yes
9253
9254 cat >>confdefs.h <<EOF
9255 #define USE_VALGRIND 1
9256 EOF
9257
9258 ;;
9259 esac
9260 else
9261 with_valgrind=
9262 fi;
9263 echo "$as_me:9263: result: ${with_valgrind:-no}" >&5
9264 echo "${ECHO_T}${with_valgrind:-no}" >&6
9265
9266 case ".$with_cflags" in
9267 (.*-g*)
9268 case .$CFLAGS in
9269 (.*-g*)
9270 ;;
9271 (*)
9272
9273 cf_fix_cppflags=no
9274 cf_new_cflags=
9275 cf_new_cppflags=
9276 cf_new_extra_cppflags=
9277
9278 for cf_add_cflags in -g
9279 do
9280 case "$cf_fix_cppflags" in
9281 (no)
9282 case "$cf_add_cflags" in
9283 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
9284 case "$cf_add_cflags" in
9285 (-D*)
9286 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
9287
9288 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9289 && test -z "${cf_tst_cflags}" \
9290 && cf_fix_cppflags=yes
9291
9292 if test "$cf_fix_cppflags" = yes ; then
9293
9294 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9295 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9296
9297 continue
9298 elif test "${cf_tst_cflags}" = "\"'" ; then
9299
9300 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9301 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9302
9303 continue
9304 fi
9305 ;;
9306 esac
9307 case "$CPPFLAGS" in
9308 (*$cf_add_cflags)
9309 ;;
9310 (*)
9311 case "$cf_add_cflags" in
9312 (-D*)
9313 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
9314
9315 CPPFLAGS=`echo "$CPPFLAGS" | \
9316 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
9317 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
9318
9319 ;;
9320 esac
9321
9322 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
9323 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
9324
9325 ;;
9326 esac
9327 ;;
9328 (*)
9329
9330 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
9331 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
9332
9333 ;;
9334 esac
9335 ;;
9336 (yes)
9337
9338 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
9339 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
9340
9341 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
9342
9343 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
9344 && test -z "${cf_tst_cflags}" \
9345 && cf_fix_cppflags=no
9346 ;;
9347 esac
9348 done
9349
9350 if test -n "$cf_new_cflags" ; then
9351
9352 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
9353 CFLAGS="${CFLAGS}$cf_new_cflags"
9354
9355 fi
9356
9357 if test -n "$cf_new_cppflags" ; then
9358
9359 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
9360 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
9361
9362 fi
9363
9364 if test -n "$cf_new_extra_cppflags" ; then
9365
9366 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
9367 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
9368
9369 fi
9370
9371 ;;
9372 esac
9373 ;;
9374 esac
9375
9376 echo "$as_me:9376: checking if you want to perform memory-leak testing" >&5
9377 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
9378
9379 # Check whether --enable-leaks or --disable-leaks was given.
9380 if test "${enable_leaks+set}" = set; then
9381 enableval="$enable_leaks"
9382 enable_leaks=$enableval
9383 else
9384 enable_leaks=yes
9385 fi;
9386 if test "x$enable_leaks" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
9387 echo "$as_me:9387: result: $with_no_leaks" >&5
9388 echo "${ECHO_T}$with_no_leaks" >&6
9389
9390 if test "$enable_leaks" = no ; then
9391
9392 cat >>confdefs.h <<\EOF
9393 #define NO_LEAKS 1
9394 EOF
9395
9396 cat >>confdefs.h <<\EOF
9397 #define YY_NO_LEAKS 1
9398 EOF
9399
9400 fi
9401
9402 echo "$as_me:9402: checking if you want to enable debugging trace" >&5
9403 echo $ECHO_N "checking if you want to enable debugging trace... $ECHO_C" >&6
9404
9405 # Check whether --enable-trace or --disable-trace was given.
9406 if test "${enable_trace+set}" = set; then
9407 enableval="$enable_trace"
9408 test "$enableval" != yes && enableval=no
9409 if test "$enableval" != "no" ; then
9410 with_trace=yes
9411 else
9412 with_trace=no
9413 fi
9414 else
9415 enableval=no
9416 with_trace=no
9417
9418 fi;
9419 echo "$as_me:9419: result: $with_trace" >&5
9420 echo "${ECHO_T}$with_trace" >&6
9421 if test "$with_trace" = "yes"
9422 then
9423
9424 cat >>confdefs.h <<\EOF
9425 #define OPT_TRACE 1
9426 EOF
9427
9428 fi
9429
9430 if test "x$with_trace" = xyes
9431 then
9432 EXTRAOBJS="$EXTRAOBJS trace\$o"
9433 fi
9434
9435 for ac_header in errno.h fcntl.h sys/time.h sys/wait.h
9436 do
9437 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9438 echo "$as_me:9438: checking for $ac_header" >&5
9439 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9440 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9441 echo $ECHO_N "(cached) $ECHO_C" >&6
9442 else
9443 cat >"conftest.$ac_ext" <<_ACEOF
9444 #line 9444 "configure"
9445 #include "confdefs.h"
9446 #include <$ac_header>
9447 _ACEOF
9448 if { (eval echo "$as_me:9448: \"$ac_cpp "conftest.$ac_ext"\"") >&5
9449 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
9450 ac_status=$?
9451 $EGREP -v '^ *\+' conftest.er1 >conftest.err
9452 rm -f conftest.er1
9453 cat conftest.err >&5
9454 echo "$as_me:9454: \$? = $ac_status" >&5
9455 (exit "$ac_status"); } >/dev/null; then
9456 if test -s conftest.err; then
9457 ac_cpp_err=$ac_c_preproc_warn_flag
9458 else
9459 ac_cpp_err=
9460 fi
9461 else
9462 ac_cpp_err=yes
9463 fi
9464 if test -z "$ac_cpp_err"; then
9465 eval "$as_ac_Header=yes"
9466 else
9467 echo "$as_me: failed program was:" >&5
9468 cat "conftest.$ac_ext" >&5
9469 eval "$as_ac_Header=no"
9470 fi
9471 rm -f conftest.err "conftest.$ac_ext"
9472 fi
9473 echo "$as_me:9473: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
9474 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
9475 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
9476 cat >>confdefs.h <<EOF
9477 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9478 EOF
9479
9480 fi
9481 done
9482
9483 echo "$as_me:9483: checking for int64_t" >&5
9484 echo $ECHO_N "checking for int64_t... $ECHO_C" >&6
9485 if test "${ac_cv_type_int64_t+set}" = set; then
9486 echo $ECHO_N "(cached) $ECHO_C" >&6
9487 else
9488 cat >"conftest.$ac_ext" <<_ACEOF
9489 #line 9489 "configure"
9490 #include "confdefs.h"
9491 $ac_includes_default
9492 int
9493 main (void)
9494 {
9495 if ((int64_t *) 0)
9496 return 0;
9497 if (sizeof (int64_t))
9498 return 0;
9499 ;
9500 return 0;
9501 }
9502 _ACEOF
9503 rm -f "conftest.$ac_objext"
9504 if { (eval echo "$as_me:9504: \"$ac_compile\"") >&5
9505 (eval $ac_compile) 2>&5
9506 ac_status=$?
9507 echo "$as_me:9507: \$? = $ac_status" >&5
9508 (exit "$ac_status"); } &&
9509 { ac_try='test -s "conftest.$ac_objext"'
9510 { (eval echo "$as_me:9510: \"$ac_try\"") >&5
9511 (eval $ac_try) 2>&5
9512 ac_status=$?
9513 echo "$as_me:9513: \$? = $ac_status" >&5
9514 (exit "$ac_status"); }; }; then
9515 ac_cv_type_int64_t=yes
9516 else
9517 echo "$as_me: failed program was:" >&5
9518 cat "conftest.$ac_ext" >&5
9519 ac_cv_type_int64_t=no
9520 fi
9521 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9522 fi
9523 echo "$as_me:9523: result: $ac_cv_type_int64_t" >&5
9524 echo "${ECHO_T}$ac_cv_type_int64_t" >&6
9525 if test "$ac_cv_type_int64_t" = yes; then
9526
9527 cat >>confdefs.h <<EOF
9528 #define HAVE_INT64_T 1
9529 EOF
9530
9531 fi
9532 echo "$as_me:9532: checking for uint64_t" >&5
9533 echo $ECHO_N "checking for uint64_t... $ECHO_C" >&6
9534 if test "${ac_cv_type_uint64_t+set}" = set; then
9535 echo $ECHO_N "(cached) $ECHO_C" >&6
9536 else
9537 cat >"conftest.$ac_ext" <<_ACEOF
9538 #line 9538 "configure"
9539 #include "confdefs.h"
9540 $ac_includes_default
9541 int
9542 main (void)
9543 {
9544 if ((uint64_t *) 0)
9545 return 0;
9546 if (sizeof (uint64_t))
9547 return 0;
9548 ;
9549 return 0;
9550 }
9551 _ACEOF
9552 rm -f "conftest.$ac_objext"
9553 if { (eval echo "$as_me:9553: \"$ac_compile\"") >&5
9554 (eval $ac_compile) 2>&5
9555 ac_status=$?
9556 echo "$as_me:9556: \$? = $ac_status" >&5
9557 (exit "$ac_status"); } &&
9558 { ac_try='test -s "conftest.$ac_objext"'
9559 { (eval echo "$as_me:9559: \"$ac_try\"") >&5
9560 (eval $ac_try) 2>&5
9561 ac_status=$?
9562 echo "$as_me:9562: \$? = $ac_status" >&5
9563 (exit "$ac_status"); }; }; then
9564 ac_cv_type_uint64_t=yes
9565 else
9566 echo "$as_me: failed program was:" >&5
9567 cat "conftest.$ac_ext" >&5
9568 ac_cv_type_uint64_t=no
9569 fi
9570 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9571 fi
9572 echo "$as_me:9572: result: $ac_cv_type_uint64_t" >&5
9573 echo "${ECHO_T}$ac_cv_type_uint64_t" >&6
9574 if test "$ac_cv_type_uint64_t" = yes; then
9575
9576 cat >>confdefs.h <<EOF
9577 #define HAVE_UINT64_T 1
9578 EOF
9579
9580 fi
9581 echo "$as_me:9581: checking for long long" >&5
9582 echo $ECHO_N "checking for long long... $ECHO_C" >&6
9583 if test "${ac_cv_type_long_long+set}" = set; then
9584 echo $ECHO_N "(cached) $ECHO_C" >&6
9585 else
9586 cat >"conftest.$ac_ext" <<_ACEOF
9587 #line 9587 "configure"
9588 #include "confdefs.h"
9589 $ac_includes_default
9590 int
9591 main (void)
9592 {
9593 if ((long long *) 0)
9594 return 0;
9595 if (sizeof (long long))
9596 return 0;
9597 ;
9598 return 0;
9599 }
9600 _ACEOF
9601 rm -f "conftest.$ac_objext"
9602 if { (eval echo "$as_me:9602: \"$ac_compile\"") >&5
9603 (eval $ac_compile) 2>&5
9604 ac_status=$?
9605 echo "$as_me:9605: \$? = $ac_status" >&5
9606 (exit "$ac_status"); } &&
9607 { ac_try='test -s "conftest.$ac_objext"'
9608 { (eval echo "$as_me:9608: \"$ac_try\"") >&5
9609 (eval $ac_try) 2>&5
9610 ac_status=$?
9611 echo "$as_me:9611: \$? = $ac_status" >&5
9612 (exit "$ac_status"); }; }; then
9613 ac_cv_type_long_long=yes
9614 else
9615 echo "$as_me: failed program was:" >&5
9616 cat "conftest.$ac_ext" >&5
9617 ac_cv_type_long_long=no
9618 fi
9619 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9620 fi
9621 echo "$as_me:9621: result: $ac_cv_type_long_long" >&5
9622 echo "${ECHO_T}$ac_cv_type_long_long" >&6
9623 if test "$ac_cv_type_long_long" = yes; then
9624
9625 cat >>confdefs.h <<EOF
9626 #define HAVE_LONG_LONG 1
9627 EOF
9628
9629 fi
9630
9631 echo "$as_me:9631: checking for float" >&5
9632 echo $ECHO_N "checking for float... $ECHO_C" >&6
9633 if test "${ac_cv_type_float+set}" = set; then
9634 echo $ECHO_N "(cached) $ECHO_C" >&6
9635 else
9636 cat >"conftest.$ac_ext" <<_ACEOF
9637 #line 9637 "configure"
9638 #include "confdefs.h"
9639 $ac_includes_default
9640 int
9641 main (void)
9642 {
9643 if ((float *) 0)
9644 return 0;
9645 if (sizeof (float))
9646 return 0;
9647 ;
9648 return 0;
9649 }
9650 _ACEOF
9651 rm -f "conftest.$ac_objext"
9652 if { (eval echo "$as_me:9652: \"$ac_compile\"") >&5
9653 (eval $ac_compile) 2>&5
9654 ac_status=$?
9655 echo "$as_me:9655: \$? = $ac_status" >&5
9656 (exit "$ac_status"); } &&
9657 { ac_try='test -s "conftest.$ac_objext"'
9658 { (eval echo "$as_me:9658: \"$ac_try\"") >&5
9659 (eval $ac_try) 2>&5
9660 ac_status=$?
9661 echo "$as_me:9661: \$? = $ac_status" >&5
9662 (exit "$ac_status"); }; }; then
9663 ac_cv_type_float=yes
9664 else
9665 echo "$as_me: failed program was:" >&5
9666 cat "conftest.$ac_ext" >&5
9667 ac_cv_type_float=no
9668 fi
9669 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9670 fi
9671 echo "$as_me:9671: result: $ac_cv_type_float" >&5
9672 echo "${ECHO_T}$ac_cv_type_float" >&6
9673
9674 echo "$as_me:9674: checking size of float" >&5
9675 echo $ECHO_N "checking size of float... $ECHO_C" >&6
9676 if test "${ac_cv_sizeof_float+set}" = set; then
9677 echo $ECHO_N "(cached) $ECHO_C" >&6
9678 else
9679 if test "$ac_cv_type_float" = yes; then
9680 if test "$cross_compiling" = yes; then
9681 # Depending upon the size, compute the lo and hi bounds.
9682 cat >"conftest.$ac_ext" <<_ACEOF
9683 #line 9683 "configure"
9684 #include "confdefs.h"
9685 $ac_includes_default
9686 int
9687 main (void)
9688 {
9689 int _array_ [1 - 2 * !((sizeof (float)) >= 0)]
9690 ;
9691 return 0;
9692 }
9693 _ACEOF
9694 rm -f "conftest.$ac_objext"
9695 if { (eval echo "$as_me:9695: \"$ac_compile\"") >&5
9696 (eval $ac_compile) 2>&5
9697 ac_status=$?
9698 echo "$as_me:9698: \$? = $ac_status" >&5
9699 (exit "$ac_status"); } &&
9700 { ac_try='test -s "conftest.$ac_objext"'
9701 { (eval echo "$as_me:9701: \"$ac_try\"") >&5
9702 (eval $ac_try) 2>&5
9703 ac_status=$?
9704 echo "$as_me:9704: \$? = $ac_status" >&5
9705 (exit "$ac_status"); }; }; then
9706 ac_lo=0 ac_mid=0
9707 while :; do
9708 cat >"conftest.$ac_ext" <<_ACEOF
9709 #line 9709 "configure"
9710 #include "confdefs.h"
9711 $ac_includes_default
9712 int
9713 main (void)
9714 {
9715 int _array_ [1 - 2 * !((sizeof (float)) <= $ac_mid)]
9716 ;
9717 return 0;
9718 }
9719 _ACEOF
9720 rm -f "conftest.$ac_objext"
9721 if { (eval echo "$as_me:9721: \"$ac_compile\"") >&5
9722 (eval $ac_compile) 2>&5
9723 ac_status=$?
9724 echo "$as_me:9724: \$? = $ac_status" >&5
9725 (exit "$ac_status"); } &&
9726 { ac_try='test -s "conftest.$ac_objext"'
9727 { (eval echo "$as_me:9727: \"$ac_try\"") >&5
9728 (eval $ac_try) 2>&5
9729 ac_status=$?
9730 echo "$as_me:9730: \$? = $ac_status" >&5
9731 (exit "$ac_status"); }; }; then
9732 ac_hi=$ac_mid; break
9733 else
9734 echo "$as_me: failed program was:" >&5
9735 cat "conftest.$ac_ext" >&5
9736 ac_lo=`expr "$ac_mid" + 1`; ac_mid=`expr 2 '*' "$ac_mid" + 1`
9737 fi
9738 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9739 done
9740 else
9741 echo "$as_me: failed program was:" >&5
9742 cat "conftest.$ac_ext" >&5
9743 ac_hi=-1 ac_mid=-1
9744 while :; do
9745 cat >"conftest.$ac_ext" <<_ACEOF
9746 #line 9746 "configure"
9747 #include "confdefs.h"
9748 $ac_includes_default
9749 int
9750 main (void)
9751 {
9752 int _array_ [1 - 2 * !((sizeof (float)) >= $ac_mid)]
9753 ;
9754 return 0;
9755 }
9756 _ACEOF
9757 rm -f "conftest.$ac_objext"
9758 if { (eval echo "$as_me:9758: \"$ac_compile\"") >&5
9759 (eval $ac_compile) 2>&5
9760 ac_status=$?
9761 echo "$as_me:9761: \$? = $ac_status" >&5
9762 (exit "$ac_status"); } &&
9763 { ac_try='test -s "conftest.$ac_objext"'
9764 { (eval echo "$as_me:9764: \"$ac_try\"") >&5
9765 (eval $ac_try) 2>&5
9766 ac_status=$?
9767 echo "$as_me:9767: \$? = $ac_status" >&5
9768 (exit "$ac_status"); }; }; then
9769 ac_lo=$ac_mid; break
9770 else
9771 echo "$as_me: failed program was:" >&5
9772 cat "conftest.$ac_ext" >&5
9773 ac_hi=`expr "$ac_mid" - 1`; ac_mid=`expr 2 '*' "$ac_mid"`
9774 fi
9775 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9776 done
9777 fi
9778 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9779 # Binary search between lo and hi bounds.
9780 while test "x$ac_lo" != "x$ac_hi"; do
9781 ac_mid=`expr '(' "$ac_hi" - "$ac_lo" ')' / 2 + "$ac_lo"`
9782 cat >"conftest.$ac_ext" <<_ACEOF
9783 #line 9783 "configure"
9784 #include "confdefs.h"
9785 $ac_includes_default
9786 int
9787 main (void)
9788 {
9789 int _array_ [1 - 2 * !((sizeof (float)) <= $ac_mid)]
9790 ;
9791 return 0;
9792 }
9793 _ACEOF
9794 rm -f "conftest.$ac_objext"
9795 if { (eval echo "$as_me:9795: \"$ac_compile\"") >&5
9796 (eval $ac_compile) 2>&5
9797 ac_status=$?
9798 echo "$as_me:9798: \$? = $ac_status" >&5
9799 (exit "$ac_status"); } &&
9800 { ac_try='test -s "conftest.$ac_objext"'
9801 { (eval echo "$as_me:9801: \"$ac_try\"") >&5
9802 (eval $ac_try) 2>&5
9803 ac_status=$?
9804 echo "$as_me:9804: \$? = $ac_status" >&5
9805 (exit "$ac_status"); }; }; then
9806 ac_hi=$ac_mid
9807 else
9808 echo "$as_me: failed program was:" >&5
9809 cat "conftest.$ac_ext" >&5
9810 ac_lo=`expr "$ac_mid" + 1`
9811 fi
9812 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9813 done
9814 ac_cv_sizeof_float=$ac_lo
9815 else
9816 if test "$cross_compiling" = yes; then
9817 { { echo "$as_me:9817: error: cannot run test program while cross compiling" >&5
9818 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
9819 { (exit 1); exit 1; }; }
9820 else
9821 cat >"conftest.$ac_ext" <<_ACEOF
9822 #line 9822 "configure"
9823 #include "confdefs.h"
9824 $ac_includes_default
9825 int
9826 main (void)
9827 {
9828 FILE *f = fopen ("conftest.val", "w");
9829 if (!f)
9830 $ac_main_return (1);
9831 fprintf (f, "%ld", (long)(sizeof (float)));
9832 fclose (f);
9833 ;
9834 return 0;
9835 }
9836 _ACEOF
9837 rm -f "conftest$ac_exeext"
9838 if { (eval echo "$as_me:9838: \"$ac_link\"") >&5
9839 (eval $ac_link) 2>&5
9840 ac_status=$?
9841 echo "$as_me:9841: \$? = $ac_status" >&5
9842 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
9843 { (eval echo "$as_me:9843: \"$ac_try\"") >&5
9844 (eval $ac_try) 2>&5
9845 ac_status=$?
9846 echo "$as_me:9846: \$? = $ac_status" >&5
9847 (exit "$ac_status"); }; }; then
9848 ac_cv_sizeof_float=`cat conftest.val`
9849 else
9850 echo "$as_me: program exited with status $ac_status" >&5
9851 echo "$as_me: failed program was:" >&5
9852 cat "conftest.$ac_ext" >&5
9853 fi
9854 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
9855 fi
9856 fi
9857 rm -f conftest.val
9858 else
9859 ac_cv_sizeof_float=0
9860 fi
9861 fi
9862 echo "$as_me:9862: result: $ac_cv_sizeof_float" >&5
9863 echo "${ECHO_T}$ac_cv_sizeof_float" >&6
9864 cat >>confdefs.h <<EOF
9865 #define SIZEOF_FLOAT $ac_cv_sizeof_float
9866 EOF
9867
9868 echo "$as_me:9868: checking for double" >&5
9869 echo $ECHO_N "checking for double... $ECHO_C" >&6
9870 if test "${ac_cv_type_double+set}" = set; then
9871 echo $ECHO_N "(cached) $ECHO_C" >&6
9872 else
9873 cat >"conftest.$ac_ext" <<_ACEOF
9874 #line 9874 "configure"
9875 #include "confdefs.h"
9876 $ac_includes_default
9877 int
9878 main (void)
9879 {
9880 if ((double *) 0)
9881 return 0;
9882 if (sizeof (double))
9883 return 0;
9884 ;
9885 return 0;
9886 }
9887 _ACEOF
9888 rm -f "conftest.$ac_objext"
9889 if { (eval echo "$as_me:9889: \"$ac_compile\"") >&5
9890 (eval $ac_compile) 2>&5
9891 ac_status=$?
9892 echo "$as_me:9892: \$? = $ac_status" >&5
9893 (exit "$ac_status"); } &&
9894 { ac_try='test -s "conftest.$ac_objext"'
9895 { (eval echo "$as_me:9895: \"$ac_try\"") >&5
9896 (eval $ac_try) 2>&5
9897 ac_status=$?
9898 echo "$as_me:9898: \$? = $ac_status" >&5
9899 (exit "$ac_status"); }; }; then
9900 ac_cv_type_double=yes
9901 else
9902 echo "$as_me: failed program was:" >&5
9903 cat "conftest.$ac_ext" >&5
9904 ac_cv_type_double=no
9905 fi
9906 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9907 fi
9908 echo "$as_me:9908: result: $ac_cv_type_double" >&5
9909 echo "${ECHO_T}$ac_cv_type_double" >&6
9910
9911 echo "$as_me:9911: checking size of double" >&5
9912 echo $ECHO_N "checking size of double... $ECHO_C" >&6
9913 if test "${ac_cv_sizeof_double+set}" = set; then
9914 echo $ECHO_N "(cached) $ECHO_C" >&6
9915 else
9916 if test "$ac_cv_type_double" = yes; then
9917 if test "$cross_compiling" = yes; then
9918 # Depending upon the size, compute the lo and hi bounds.
9919 cat >"conftest.$ac_ext" <<_ACEOF
9920 #line 9920 "configure"
9921 #include "confdefs.h"
9922 $ac_includes_default
9923 int
9924 main (void)
9925 {
9926 int _array_ [1 - 2 * !((sizeof (double)) >= 0)]
9927 ;
9928 return 0;
9929 }
9930 _ACEOF
9931 rm -f "conftest.$ac_objext"
9932 if { (eval echo "$as_me:9932: \"$ac_compile\"") >&5
9933 (eval $ac_compile) 2>&5
9934 ac_status=$?
9935 echo "$as_me:9935: \$? = $ac_status" >&5
9936 (exit "$ac_status"); } &&
9937 { ac_try='test -s "conftest.$ac_objext"'
9938 { (eval echo "$as_me:9938: \"$ac_try\"") >&5
9939 (eval $ac_try) 2>&5
9940 ac_status=$?
9941 echo "$as_me:9941: \$? = $ac_status" >&5
9942 (exit "$ac_status"); }; }; then
9943 ac_lo=0 ac_mid=0
9944 while :; do
9945 cat >"conftest.$ac_ext" <<_ACEOF
9946 #line 9946 "configure"
9947 #include "confdefs.h"
9948 $ac_includes_default
9949 int
9950 main (void)
9951 {
9952 int _array_ [1 - 2 * !((sizeof (double)) <= $ac_mid)]
9953 ;
9954 return 0;
9955 }
9956 _ACEOF
9957 rm -f "conftest.$ac_objext"
9958 if { (eval echo "$as_me:9958: \"$ac_compile\"") >&5
9959 (eval $ac_compile) 2>&5
9960 ac_status=$?
9961 echo "$as_me:9961: \$? = $ac_status" >&5
9962 (exit "$ac_status"); } &&
9963 { ac_try='test -s "conftest.$ac_objext"'
9964 { (eval echo "$as_me:9964: \"$ac_try\"") >&5
9965 (eval $ac_try) 2>&5
9966 ac_status=$?
9967 echo "$as_me:9967: \$? = $ac_status" >&5
9968 (exit "$ac_status"); }; }; then
9969 ac_hi=$ac_mid; break
9970 else
9971 echo "$as_me: failed program was:" >&5
9972 cat "conftest.$ac_ext" >&5
9973 ac_lo=`expr "$ac_mid" + 1`; ac_mid=`expr 2 '*' "$ac_mid" + 1`
9974 fi
9975 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9976 done
9977 else
9978 echo "$as_me: failed program was:" >&5
9979 cat "conftest.$ac_ext" >&5
9980 ac_hi=-1 ac_mid=-1
9981 while :; do
9982 cat >"conftest.$ac_ext" <<_ACEOF
9983 #line 9983 "configure"
9984 #include "confdefs.h"
9985 $ac_includes_default
9986 int
9987 main (void)
9988 {
9989 int _array_ [1 - 2 * !((sizeof (double)) >= $ac_mid)]
9990 ;
9991 return 0;
9992 }
9993 _ACEOF
9994 rm -f "conftest.$ac_objext"
9995 if { (eval echo "$as_me:9995: \"$ac_compile\"") >&5
9996 (eval $ac_compile) 2>&5
9997 ac_status=$?
9998 echo "$as_me:9998: \$? = $ac_status" >&5
9999 (exit "$ac_status"); } &&
10000 { ac_try='test -s "conftest.$ac_objext"'
10001 { (eval echo "$as_me:10001: \"$ac_try\"") >&5
10002 (eval $ac_try) 2>&5
10003 ac_status=$?
10004 echo "$as_me:10004: \$? = $ac_status" >&5
10005 (exit "$ac_status"); }; }; then
10006 ac_lo=$ac_mid; break
10007 else
10008 echo "$as_me: failed program was:" >&5
10009 cat "conftest.$ac_ext" >&5
10010 ac_hi=`expr "$ac_mid" - 1`; ac_mid=`expr 2 '*' "$ac_mid"`
10011 fi
10012 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10013 done
10014 fi
10015 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10016 # Binary search between lo and hi bounds.
10017 while test "x$ac_lo" != "x$ac_hi"; do
10018 ac_mid=`expr '(' "$ac_hi" - "$ac_lo" ')' / 2 + "$ac_lo"`
10019 cat >"conftest.$ac_ext" <<_ACEOF
10020 #line 10020 "configure"
10021 #include "confdefs.h"
10022 $ac_includes_default
10023 int
10024 main (void)
10025 {
10026 int _array_ [1 - 2 * !((sizeof (double)) <= $ac_mid)]
10027 ;
10028 return 0;
10029 }
10030 _ACEOF
10031 rm -f "conftest.$ac_objext"
10032 if { (eval echo "$as_me:10032: \"$ac_compile\"") >&5
10033 (eval $ac_compile) 2>&5
10034 ac_status=$?
10035 echo "$as_me:10035: \$? = $ac_status" >&5
10036 (exit "$ac_status"); } &&
10037 { ac_try='test -s "conftest.$ac_objext"'
10038 { (eval echo "$as_me:10038: \"$ac_try\"") >&5
10039 (eval $ac_try) 2>&5
10040 ac_status=$?
10041 echo "$as_me:10041: \$? = $ac_status" >&5
10042 (exit "$ac_status"); }; }; then
10043 ac_hi=$ac_mid
10044 else
10045 echo "$as_me: failed program was:" >&5
10046 cat "conftest.$ac_ext" >&5
10047 ac_lo=`expr "$ac_mid" + 1`
10048 fi
10049 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10050 done
10051 ac_cv_sizeof_double=$ac_lo
10052 else
10053 if test "$cross_compiling" = yes; then
10054 { { echo "$as_me:10054: error: cannot run test program while cross compiling" >&5
10055 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
10056 { (exit 1); exit 1; }; }
10057 else
10058 cat >"conftest.$ac_ext" <<_ACEOF
10059 #line 10059 "configure"
10060 #include "confdefs.h"
10061 $ac_includes_default
10062 int
10063 main (void)
10064 {
10065 FILE *f = fopen ("conftest.val", "w");
10066 if (!f)
10067 $ac_main_return (1);
10068 fprintf (f, "%ld", (long)(sizeof (double)));
10069 fclose (f);
10070 ;
10071 return 0;
10072 }
10073 _ACEOF
10074 rm -f "conftest$ac_exeext"
10075 if { (eval echo "$as_me:10075: \"$ac_link\"") >&5
10076 (eval $ac_link) 2>&5
10077 ac_status=$?
10078 echo "$as_me:10078: \$? = $ac_status" >&5
10079 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
10080 { (eval echo "$as_me:10080: \"$ac_try\"") >&5
10081 (eval $ac_try) 2>&5
10082 ac_status=$?
10083 echo "$as_me:10083: \$? = $ac_status" >&5
10084 (exit "$ac_status"); }; }; then
10085 ac_cv_sizeof_double=`cat conftest.val`
10086 else
10087 echo "$as_me: program exited with status $ac_status" >&5
10088 echo "$as_me: failed program was:" >&5
10089 cat "conftest.$ac_ext" >&5
10090 fi
10091 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
10092 fi
10093 fi
10094 rm -f conftest.val
10095 else
10096 ac_cv_sizeof_double=0
10097 fi
10098 fi
10099 echo "$as_me:10099: result: $ac_cv_sizeof_double" >&5
10100 echo "${ECHO_T}$ac_cv_sizeof_double" >&6
10101 cat >>confdefs.h <<EOF
10102 #define SIZEOF_DOUBLE $ac_cv_sizeof_double
10103 EOF
10104
10105 echo "$as_me:10105: checking for long" >&5
10106 echo $ECHO_N "checking for long... $ECHO_C" >&6
10107 if test "${ac_cv_type_long+set}" = set; then
10108 echo $ECHO_N "(cached) $ECHO_C" >&6
10109 else
10110 cat >"conftest.$ac_ext" <<_ACEOF
10111 #line 10111 "configure"
10112 #include "confdefs.h"
10113 $ac_includes_default
10114 int
10115 main (void)
10116 {
10117 if ((long *) 0)
10118 return 0;
10119 if (sizeof (long))
10120 return 0;
10121 ;
10122 return 0;
10123 }
10124 _ACEOF
10125 rm -f "conftest.$ac_objext"
10126 if { (eval echo "$as_me:10126: \"$ac_compile\"") >&5
10127 (eval $ac_compile) 2>&5
10128 ac_status=$?
10129 echo "$as_me:10129: \$? = $ac_status" >&5
10130 (exit "$ac_status"); } &&
10131 { ac_try='test -s "conftest.$ac_objext"'
10132 { (eval echo "$as_me:10132: \"$ac_try\"") >&5
10133 (eval $ac_try) 2>&5
10134 ac_status=$?
10135 echo "$as_me:10135: \$? = $ac_status" >&5
10136 (exit "$ac_status"); }; }; then
10137 ac_cv_type_long=yes
10138 else
10139 echo "$as_me: failed program was:" >&5
10140 cat "conftest.$ac_ext" >&5
10141 ac_cv_type_long=no
10142 fi
10143 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10144 fi
10145 echo "$as_me:10145: result: $ac_cv_type_long" >&5
10146 echo "${ECHO_T}$ac_cv_type_long" >&6
10147
10148 echo "$as_me:10148: checking size of long" >&5
10149 echo $ECHO_N "checking size of long... $ECHO_C" >&6
10150 if test "${ac_cv_sizeof_long+set}" = set; then
10151 echo $ECHO_N "(cached) $ECHO_C" >&6
10152 else
10153 if test "$ac_cv_type_long" = yes; then
10154 if test "$cross_compiling" = yes; then
10155 # Depending upon the size, compute the lo and hi bounds.
10156 cat >"conftest.$ac_ext" <<_ACEOF
10157 #line 10157 "configure"
10158 #include "confdefs.h"
10159 $ac_includes_default
10160 int
10161 main (void)
10162 {
10163 int _array_ [1 - 2 * !((sizeof (long)) >= 0)]
10164 ;
10165 return 0;
10166 }
10167 _ACEOF
10168 rm -f "conftest.$ac_objext"
10169 if { (eval echo "$as_me:10169: \"$ac_compile\"") >&5
10170 (eval $ac_compile) 2>&5
10171 ac_status=$?
10172 echo "$as_me:10172: \$? = $ac_status" >&5
10173 (exit "$ac_status"); } &&
10174 { ac_try='test -s "conftest.$ac_objext"'
10175 { (eval echo "$as_me:10175: \"$ac_try\"") >&5
10176 (eval $ac_try) 2>&5
10177 ac_status=$?
10178 echo "$as_me:10178: \$? = $ac_status" >&5
10179 (exit "$ac_status"); }; }; then
10180 ac_lo=0 ac_mid=0
10181 while :; do
10182 cat >"conftest.$ac_ext" <<_ACEOF
10183 #line 10183 "configure"
10184 #include "confdefs.h"
10185 $ac_includes_default
10186 int
10187 main (void)
10188 {
10189 int _array_ [1 - 2 * !((sizeof (long)) <= $ac_mid)]
10190 ;
10191 return 0;
10192 }
10193 _ACEOF
10194 rm -f "conftest.$ac_objext"
10195 if { (eval echo "$as_me:10195: \"$ac_compile\"") >&5
10196 (eval $ac_compile) 2>&5
10197 ac_status=$?
10198 echo "$as_me:10198: \$? = $ac_status" >&5
10199 (exit "$ac_status"); } &&
10200 { ac_try='test -s "conftest.$ac_objext"'
10201 { (eval echo "$as_me:10201: \"$ac_try\"") >&5
10202 (eval $ac_try) 2>&5
10203 ac_status=$?
10204 echo "$as_me:10204: \$? = $ac_status" >&5
10205 (exit "$ac_status"); }; }; then
10206 ac_hi=$ac_mid; break
10207 else
10208 echo "$as_me: failed program was:" >&5
10209 cat "conftest.$ac_ext" >&5
10210 ac_lo=`expr "$ac_mid" + 1`; ac_mid=`expr 2 '*' "$ac_mid" + 1`
10211 fi
10212 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10213 done
10214 else
10215 echo "$as_me: failed program was:" >&5
10216 cat "conftest.$ac_ext" >&5
10217 ac_hi=-1 ac_mid=-1
10218 while :; do
10219 cat >"conftest.$ac_ext" <<_ACEOF
10220 #line 10220 "configure"
10221 #include "confdefs.h"
10222 $ac_includes_default
10223 int
10224 main (void)
10225 {
10226 int _array_ [1 - 2 * !((sizeof (long)) >= $ac_mid)]
10227 ;
10228 return 0;
10229 }
10230 _ACEOF
10231 rm -f "conftest.$ac_objext"
10232 if { (eval echo "$as_me:10232: \"$ac_compile\"") >&5
10233 (eval $ac_compile) 2>&5
10234 ac_status=$?
10235 echo "$as_me:10235: \$? = $ac_status" >&5
10236 (exit "$ac_status"); } &&
10237 { ac_try='test -s "conftest.$ac_objext"'
10238 { (eval echo "$as_me:10238: \"$ac_try\"") >&5
10239 (eval $ac_try) 2>&5
10240 ac_status=$?
10241 echo "$as_me:10241: \$? = $ac_status" >&5
10242 (exit "$ac_status"); }; }; then
10243 ac_lo=$ac_mid; break
10244 else
10245 echo "$as_me: failed program was:" >&5
10246 cat "conftest.$ac_ext" >&5
10247 ac_hi=`expr "$ac_mid" - 1`; ac_mid=`expr 2 '*' "$ac_mid"`
10248 fi
10249 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10250 done
10251 fi
10252 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10253 # Binary search between lo and hi bounds.
10254 while test "x$ac_lo" != "x$ac_hi"; do
10255 ac_mid=`expr '(' "$ac_hi" - "$ac_lo" ')' / 2 + "$ac_lo"`
10256 cat >"conftest.$ac_ext" <<_ACEOF
10257 #line 10257 "configure"
10258 #include "confdefs.h"
10259 $ac_includes_default
10260 int
10261 main (void)
10262 {
10263 int _array_ [1 - 2 * !((sizeof (long)) <= $ac_mid)]
10264 ;
10265 return 0;
10266 }
10267 _ACEOF
10268 rm -f "conftest.$ac_objext"
10269 if { (eval echo "$as_me:10269: \"$ac_compile\"") >&5
10270 (eval $ac_compile) 2>&5
10271 ac_status=$?
10272 echo "$as_me:10272: \$? = $ac_status" >&5
10273 (exit "$ac_status"); } &&
10274 { ac_try='test -s "conftest.$ac_objext"'
10275 { (eval echo "$as_me:10275: \"$ac_try\"") >&5
10276 (eval $ac_try) 2>&5
10277 ac_status=$?
10278 echo "$as_me:10278: \$? = $ac_status" >&5
10279 (exit "$ac_status"); }; }; then
10280 ac_hi=$ac_mid
10281 else
10282 echo "$as_me: failed program was:" >&5
10283 cat "conftest.$ac_ext" >&5
10284 ac_lo=`expr "$ac_mid" + 1`
10285 fi
10286 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10287 done
10288 ac_cv_sizeof_long=$ac_lo
10289 else
10290 if test "$cross_compiling" = yes; then
10291 { { echo "$as_me:10291: error: cannot run test program while cross compiling" >&5
10292 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
10293 { (exit 1); exit 1; }; }
10294 else
10295 cat >"conftest.$ac_ext" <<_ACEOF
10296 #line 10296 "configure"
10297 #include "confdefs.h"
10298 $ac_includes_default
10299 int
10300 main (void)
10301 {
10302 FILE *f = fopen ("conftest.val", "w");
10303 if (!f)
10304 $ac_main_return (1);
10305 fprintf (f, "%ld", (long)(sizeof (long)));
10306 fclose (f);
10307 ;
10308 return 0;
10309 }
10310 _ACEOF
10311 rm -f "conftest$ac_exeext"
10312 if { (eval echo "$as_me:10312: \"$ac_link\"") >&5
10313 (eval $ac_link) 2>&5
10314 ac_status=$?
10315 echo "$as_me:10315: \$? = $ac_status" >&5
10316 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
10317 { (eval echo "$as_me:10317: \"$ac_try\"") >&5
10318 (eval $ac_try) 2>&5
10319 ac_status=$?
10320 echo "$as_me:10320: \$? = $ac_status" >&5
10321 (exit "$ac_status"); }; }; then
10322 ac_cv_sizeof_long=`cat conftest.val`
10323 else
10324 echo "$as_me: program exited with status $ac_status" >&5
10325 echo "$as_me: failed program was:" >&5
10326 cat "conftest.$ac_ext" >&5
10327 fi
10328 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
10329 fi
10330 fi
10331 rm -f conftest.val
10332 else
10333 ac_cv_sizeof_long=0
10334 fi
10335 fi
10336 echo "$as_me:10336: result: $ac_cv_sizeof_long" >&5
10337 echo "${ECHO_T}$ac_cv_sizeof_long" >&6
10338 cat >>confdefs.h <<EOF
10339 #define SIZEOF_LONG $ac_cv_sizeof_long
10340 EOF
10341
10342 echo "$as_me:10342: checking for int64_t" >&5
10343 echo $ECHO_N "checking for int64_t... $ECHO_C" >&6
10344 if test "${ac_cv_type_int64_t+set}" = set; then
10345 echo $ECHO_N "(cached) $ECHO_C" >&6
10346 else
10347 cat >"conftest.$ac_ext" <<_ACEOF
10348 #line 10348 "configure"
10349 #include "confdefs.h"
10350 $ac_includes_default
10351 int
10352 main (void)
10353 {
10354 if ((int64_t *) 0)
10355 return 0;
10356 if (sizeof (int64_t))
10357 return 0;
10358 ;
10359 return 0;
10360 }
10361 _ACEOF
10362 rm -f "conftest.$ac_objext"
10363 if { (eval echo "$as_me:10363: \"$ac_compile\"") >&5
10364 (eval $ac_compile) 2>&5
10365 ac_status=$?
10366 echo "$as_me:10366: \$? = $ac_status" >&5
10367 (exit "$ac_status"); } &&
10368 { ac_try='test -s "conftest.$ac_objext"'
10369 { (eval echo "$as_me:10369: \"$ac_try\"") >&5
10370 (eval $ac_try) 2>&5
10371 ac_status=$?
10372 echo "$as_me:10372: \$? = $ac_status" >&5
10373 (exit "$ac_status"); }; }; then
10374 ac_cv_type_int64_t=yes
10375 else
10376 echo "$as_me: failed program was:" >&5
10377 cat "conftest.$ac_ext" >&5
10378 ac_cv_type_int64_t=no
10379 fi
10380 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10381 fi
10382 echo "$as_me:10382: result: $ac_cv_type_int64_t" >&5
10383 echo "${ECHO_T}$ac_cv_type_int64_t" >&6
10384
10385 echo "$as_me:10385: checking size of int64_t" >&5
10386 echo $ECHO_N "checking size of int64_t... $ECHO_C" >&6
10387 if test "${ac_cv_sizeof_int64_t+set}" = set; then
10388 echo $ECHO_N "(cached) $ECHO_C" >&6
10389 else
10390 if test "$ac_cv_type_int64_t" = yes; then
10391 if test "$cross_compiling" = yes; then
10392 # Depending upon the size, compute the lo and hi bounds.
10393 cat >"conftest.$ac_ext" <<_ACEOF
10394 #line 10394 "configure"
10395 #include "confdefs.h"
10396 $ac_includes_default
10397 int
10398 main (void)
10399 {
10400 int _array_ [1 - 2 * !((sizeof (int64_t)) >= 0)]
10401 ;
10402 return 0;
10403 }
10404 _ACEOF
10405 rm -f "conftest.$ac_objext"
10406 if { (eval echo "$as_me:10406: \"$ac_compile\"") >&5
10407 (eval $ac_compile) 2>&5
10408 ac_status=$?
10409 echo "$as_me:10409: \$? = $ac_status" >&5
10410 (exit "$ac_status"); } &&
10411 { ac_try='test -s "conftest.$ac_objext"'
10412 { (eval echo "$as_me:10412: \"$ac_try\"") >&5
10413 (eval $ac_try) 2>&5
10414 ac_status=$?
10415 echo "$as_me:10415: \$? = $ac_status" >&5
10416 (exit "$ac_status"); }; }; then
10417 ac_lo=0 ac_mid=0
10418 while :; do
10419 cat >"conftest.$ac_ext" <<_ACEOF
10420 #line 10420 "configure"
10421 #include "confdefs.h"
10422 $ac_includes_default
10423 int
10424 main (void)
10425 {
10426 int _array_ [1 - 2 * !((sizeof (int64_t)) <= $ac_mid)]
10427 ;
10428 return 0;
10429 }
10430 _ACEOF
10431 rm -f "conftest.$ac_objext"
10432 if { (eval echo "$as_me:10432: \"$ac_compile\"") >&5
10433 (eval $ac_compile) 2>&5
10434 ac_status=$?
10435 echo "$as_me:10435: \$? = $ac_status" >&5
10436 (exit "$ac_status"); } &&
10437 { ac_try='test -s "conftest.$ac_objext"'
10438 { (eval echo "$as_me:10438: \"$ac_try\"") >&5
10439 (eval $ac_try) 2>&5
10440 ac_status=$?
10441 echo "$as_me:10441: \$? = $ac_status" >&5
10442 (exit "$ac_status"); }; }; then
10443 ac_hi=$ac_mid; break
10444 else
10445 echo "$as_me: failed program was:" >&5
10446 cat "conftest.$ac_ext" >&5
10447 ac_lo=`expr "$ac_mid" + 1`; ac_mid=`expr 2 '*' "$ac_mid" + 1`
10448 fi
10449 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10450 done
10451 else
10452 echo "$as_me: failed program was:" >&5
10453 cat "conftest.$ac_ext" >&5
10454 ac_hi=-1 ac_mid=-1
10455 while :; do
10456 cat >"conftest.$ac_ext" <<_ACEOF
10457 #line 10457 "configure"
10458 #include "confdefs.h"
10459 $ac_includes_default
10460 int
10461 main (void)
10462 {
10463 int _array_ [1 - 2 * !((sizeof (int64_t)) >= $ac_mid)]
10464 ;
10465 return 0;
10466 }
10467 _ACEOF
10468 rm -f "conftest.$ac_objext"
10469 if { (eval echo "$as_me:10469: \"$ac_compile\"") >&5
10470 (eval $ac_compile) 2>&5
10471 ac_status=$?
10472 echo "$as_me:10472: \$? = $ac_status" >&5
10473 (exit "$ac_status"); } &&
10474 { ac_try='test -s "conftest.$ac_objext"'
10475 { (eval echo "$as_me:10475: \"$ac_try\"") >&5
10476 (eval $ac_try) 2>&5
10477 ac_status=$?
10478 echo "$as_me:10478: \$? = $ac_status" >&5
10479 (exit "$ac_status"); }; }; then
10480 ac_lo=$ac_mid; break
10481 else
10482 echo "$as_me: failed program was:" >&5
10483 cat "conftest.$ac_ext" >&5
10484 ac_hi=`expr "$ac_mid" - 1`; ac_mid=`expr 2 '*' "$ac_mid"`
10485 fi
10486 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10487 done
10488 fi
10489 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10490 # Binary search between lo and hi bounds.
10491 while test "x$ac_lo" != "x$ac_hi"; do
10492 ac_mid=`expr '(' "$ac_hi" - "$ac_lo" ')' / 2 + "$ac_lo"`
10493 cat >"conftest.$ac_ext" <<_ACEOF
10494 #line 10494 "configure"
10495 #include "confdefs.h"
10496 $ac_includes_default
10497 int
10498 main (void)
10499 {
10500 int _array_ [1 - 2 * !((sizeof (int64_t)) <= $ac_mid)]
10501 ;
10502 return 0;
10503 }
10504 _ACEOF
10505 rm -f "conftest.$ac_objext"
10506 if { (eval echo "$as_me:10506: \"$ac_compile\"") >&5
10507 (eval $ac_compile) 2>&5
10508 ac_status=$?
10509 echo "$as_me:10509: \$? = $ac_status" >&5
10510 (exit "$ac_status"); } &&
10511 { ac_try='test -s "conftest.$ac_objext"'
10512 { (eval echo "$as_me:10512: \"$ac_try\"") >&5
10513 (eval $ac_try) 2>&5
10514 ac_status=$?
10515 echo "$as_me:10515: \$? = $ac_status" >&5
10516 (exit "$ac_status"); }; }; then
10517 ac_hi=$ac_mid
10518 else
10519 echo "$as_me: failed program was:" >&5
10520 cat "conftest.$ac_ext" >&5
10521 ac_lo=`expr "$ac_mid" + 1`
10522 fi
10523 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10524 done
10525 ac_cv_sizeof_int64_t=$ac_lo
10526 else
10527 if test "$cross_compiling" = yes; then
10528 { { echo "$as_me:10528: error: cannot run test program while cross compiling" >&5
10529 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
10530 { (exit 1); exit 1; }; }
10531 else
10532 cat >"conftest.$ac_ext" <<_ACEOF
10533 #line 10533 "configure"
10534 #include "confdefs.h"
10535 $ac_includes_default
10536 int
10537 main (void)
10538 {
10539 FILE *f = fopen ("conftest.val", "w");
10540 if (!f)
10541 $ac_main_return (1);
10542 fprintf (f, "%ld", (long)(sizeof (int64_t)));
10543 fclose (f);
10544 ;
10545 return 0;
10546 }
10547 _ACEOF
10548 rm -f "conftest$ac_exeext"
10549 if { (eval echo "$as_me:10549: \"$ac_link\"") >&5
10550 (eval $ac_link) 2>&5
10551 ac_status=$?
10552 echo "$as_me:10552: \$? = $ac_status" >&5
10553 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
10554 { (eval echo "$as_me:10554: \"$ac_try\"") >&5
10555 (eval $ac_try) 2>&5
10556 ac_status=$?
10557 echo "$as_me:10557: \$? = $ac_status" >&5
10558 (exit "$ac_status"); }; }; then
10559 ac_cv_sizeof_int64_t=`cat conftest.val`
10560 else
10561 echo "$as_me: program exited with status $ac_status" >&5
10562 echo "$as_me: failed program was:" >&5
10563 cat "conftest.$ac_ext" >&5
10564 fi
10565 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
10566 fi
10567 fi
10568 rm -f conftest.val
10569 else
10570 ac_cv_sizeof_int64_t=0
10571 fi
10572 fi
10573 echo "$as_me:10573: result: $ac_cv_sizeof_int64_t" >&5
10574 echo "${ECHO_T}$ac_cv_sizeof_int64_t" >&6
10575 cat >>confdefs.h <<EOF
10576 #define SIZEOF_INT64_T $ac_cv_sizeof_int64_t
10577 EOF
10578
10579 echo "$as_me:10579: checking for long long" >&5
10580 echo $ECHO_N "checking for long long... $ECHO_C" >&6
10581 if test "${ac_cv_type_long_long+set}" = set; then
10582 echo $ECHO_N "(cached) $ECHO_C" >&6
10583 else
10584 cat >"conftest.$ac_ext" <<_ACEOF
10585 #line 10585 "configure"
10586 #include "confdefs.h"
10587 $ac_includes_default
10588 int
10589 main (void)
10590 {
10591 if ((long long *) 0)
10592 return 0;
10593 if (sizeof (long long))
10594 return 0;
10595 ;
10596 return 0;
10597 }
10598 _ACEOF
10599 rm -f "conftest.$ac_objext"
10600 if { (eval echo "$as_me:10600: \"$ac_compile\"") >&5
10601 (eval $ac_compile) 2>&5
10602 ac_status=$?
10603 echo "$as_me:10603: \$? = $ac_status" >&5
10604 (exit "$ac_status"); } &&
10605 { ac_try='test -s "conftest.$ac_objext"'
10606 { (eval echo "$as_me:10606: \"$ac_try\"") >&5
10607 (eval $ac_try) 2>&5
10608 ac_status=$?
10609 echo "$as_me:10609: \$? = $ac_status" >&5
10610 (exit "$ac_status"); }; }; then
10611 ac_cv_type_long_long=yes
10612 else
10613 echo "$as_me: failed program was:" >&5
10614 cat "conftest.$ac_ext" >&5
10615 ac_cv_type_long_long=no
10616 fi
10617 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10618 fi
10619 echo "$as_me:10619: result: $ac_cv_type_long_long" >&5
10620 echo "${ECHO_T}$ac_cv_type_long_long" >&6
10621
10622 echo "$as_me:10622: checking size of long long" >&5
10623 echo $ECHO_N "checking size of long long... $ECHO_C" >&6
10624 if test "${ac_cv_sizeof_long_long+set}" = set; then
10625 echo $ECHO_N "(cached) $ECHO_C" >&6
10626 else
10627 if test "$ac_cv_type_long_long" = yes; then
10628 if test "$cross_compiling" = yes; then
10629 # Depending upon the size, compute the lo and hi bounds.
10630 cat >"conftest.$ac_ext" <<_ACEOF
10631 #line 10631 "configure"
10632 #include "confdefs.h"
10633 $ac_includes_default
10634 int
10635 main (void)
10636 {
10637 int _array_ [1 - 2 * !((sizeof (long long)) >= 0)]
10638 ;
10639 return 0;
10640 }
10641 _ACEOF
10642 rm -f "conftest.$ac_objext"
10643 if { (eval echo "$as_me:10643: \"$ac_compile\"") >&5
10644 (eval $ac_compile) 2>&5
10645 ac_status=$?
10646 echo "$as_me:10646: \$? = $ac_status" >&5
10647 (exit "$ac_status"); } &&
10648 { ac_try='test -s "conftest.$ac_objext"'
10649 { (eval echo "$as_me:10649: \"$ac_try\"") >&5
10650 (eval $ac_try) 2>&5
10651 ac_status=$?
10652 echo "$as_me:10652: \$? = $ac_status" >&5
10653 (exit "$ac_status"); }; }; then
10654 ac_lo=0 ac_mid=0
10655 while :; do
10656 cat >"conftest.$ac_ext" <<_ACEOF
10657 #line 10657 "configure"
10658 #include "confdefs.h"
10659 $ac_includes_default
10660 int
10661 main (void)
10662 {
10663 int _array_ [1 - 2 * !((sizeof (long long)) <= $ac_mid)]
10664 ;
10665 return 0;
10666 }
10667 _ACEOF
10668 rm -f "conftest.$ac_objext"
10669 if { (eval echo "$as_me:10669: \"$ac_compile\"") >&5
10670 (eval $ac_compile) 2>&5
10671 ac_status=$?
10672 echo "$as_me:10672: \$? = $ac_status" >&5
10673 (exit "$ac_status"); } &&
10674 { ac_try='test -s "conftest.$ac_objext"'
10675 { (eval echo "$as_me:10675: \"$ac_try\"") >&5
10676 (eval $ac_try) 2>&5
10677 ac_status=$?
10678 echo "$as_me:10678: \$? = $ac_status" >&5
10679 (exit "$ac_status"); }; }; then
10680 ac_hi=$ac_mid; break
10681 else
10682 echo "$as_me: failed program was:" >&5
10683 cat "conftest.$ac_ext" >&5
10684 ac_lo=`expr "$ac_mid" + 1`; ac_mid=`expr 2 '*' "$ac_mid" + 1`
10685 fi
10686 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10687 done
10688 else
10689 echo "$as_me: failed program was:" >&5
10690 cat "conftest.$ac_ext" >&5
10691 ac_hi=-1 ac_mid=-1
10692 while :; do
10693 cat >"conftest.$ac_ext" <<_ACEOF
10694 #line 10694 "configure"
10695 #include "confdefs.h"
10696 $ac_includes_default
10697 int
10698 main (void)
10699 {
10700 int _array_ [1 - 2 * !((sizeof (long long)) >= $ac_mid)]
10701 ;
10702 return 0;
10703 }
10704 _ACEOF
10705 rm -f "conftest.$ac_objext"
10706 if { (eval echo "$as_me:10706: \"$ac_compile\"") >&5
10707 (eval $ac_compile) 2>&5
10708 ac_status=$?
10709 echo "$as_me:10709: \$? = $ac_status" >&5
10710 (exit "$ac_status"); } &&
10711 { ac_try='test -s "conftest.$ac_objext"'
10712 { (eval echo "$as_me:10712: \"$ac_try\"") >&5
10713 (eval $ac_try) 2>&5
10714 ac_status=$?
10715 echo "$as_me:10715: \$? = $ac_status" >&5
10716 (exit "$ac_status"); }; }; then
10717 ac_lo=$ac_mid; break
10718 else
10719 echo "$as_me: failed program was:" >&5
10720 cat "conftest.$ac_ext" >&5
10721 ac_hi=`expr "$ac_mid" - 1`; ac_mid=`expr 2 '*' "$ac_mid"`
10722 fi
10723 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10724 done
10725 fi
10726 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10727 # Binary search between lo and hi bounds.
10728 while test "x$ac_lo" != "x$ac_hi"; do
10729 ac_mid=`expr '(' "$ac_hi" - "$ac_lo" ')' / 2 + "$ac_lo"`
10730 cat >"conftest.$ac_ext" <<_ACEOF
10731 #line 10731 "configure"
10732 #include "confdefs.h"
10733 $ac_includes_default
10734 int
10735 main (void)
10736 {
10737 int _array_ [1 - 2 * !((sizeof (long long)) <= $ac_mid)]
10738 ;
10739 return 0;
10740 }
10741 _ACEOF
10742 rm -f "conftest.$ac_objext"
10743 if { (eval echo "$as_me:10743: \"$ac_compile\"") >&5
10744 (eval $ac_compile) 2>&5
10745 ac_status=$?
10746 echo "$as_me:10746: \$? = $ac_status" >&5
10747 (exit "$ac_status"); } &&
10748 { ac_try='test -s "conftest.$ac_objext"'
10749 { (eval echo "$as_me:10749: \"$ac_try\"") >&5
10750 (eval $ac_try) 2>&5
10751 ac_status=$?
10752 echo "$as_me:10752: \$? = $ac_status" >&5
10753 (exit "$ac_status"); }; }; then
10754 ac_hi=$ac_mid
10755 else
10756 echo "$as_me: failed program was:" >&5
10757 cat "conftest.$ac_ext" >&5
10758 ac_lo=`expr "$ac_mid" + 1`
10759 fi
10760 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10761 done
10762 ac_cv_sizeof_long_long=$ac_lo
10763 else
10764 if test "$cross_compiling" = yes; then
10765 { { echo "$as_me:10765: error: cannot run test program while cross compiling" >&5
10766 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
10767 { (exit 1); exit 1; }; }
10768 else
10769 cat >"conftest.$ac_ext" <<_ACEOF
10770 #line 10770 "configure"
10771 #include "confdefs.h"
10772 $ac_includes_default
10773 int
10774 main (void)
10775 {
10776 FILE *f = fopen ("conftest.val", "w");
10777 if (!f)
10778 $ac_main_return (1);
10779 fprintf (f, "%ld", (long)(sizeof (long long)));
10780 fclose (f);
10781 ;
10782 return 0;
10783 }
10784 _ACEOF
10785 rm -f "conftest$ac_exeext"
10786 if { (eval echo "$as_me:10786: \"$ac_link\"") >&5
10787 (eval $ac_link) 2>&5
10788 ac_status=$?
10789 echo "$as_me:10789: \$? = $ac_status" >&5
10790 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
10791 { (eval echo "$as_me:10791: \"$ac_try\"") >&5
10792 (eval $ac_try) 2>&5
10793 ac_status=$?
10794 echo "$as_me:10794: \$? = $ac_status" >&5
10795 (exit "$ac_status"); }; }; then
10796 ac_cv_sizeof_long_long=`cat conftest.val`
10797 else
10798 echo "$as_me: program exited with status $ac_status" >&5
10799 echo "$as_me: failed program was:" >&5
10800 cat "conftest.$ac_ext" >&5
10801 fi
10802 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
10803 fi
10804 fi
10805 rm -f conftest.val
10806 else
10807 ac_cv_sizeof_long_long=0
10808 fi
10809 fi
10810 echo "$as_me:10810: result: $ac_cv_sizeof_long_long" >&5
10811 echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
10812 cat >>confdefs.h <<EOF
10813 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
10814 EOF
10815
10816 if test "x$cf_mawk_check_size_t" != xyes ; then
10817
10818 if test "${cf_cv_size_t_SIZE_T_STDDEF_H+set}" = set; then
10819 echo $ECHO_N "(cached) $ECHO_C" >&6
10820 else
10821
10822 echo "$as_me:10822: checking for stddef.h" >&5
10823 echo $ECHO_N "checking for stddef.h... $ECHO_C" >&6
10824 if test "${ac_cv_header_stddef_h+set}" = set; then
10825 echo $ECHO_N "(cached) $ECHO_C" >&6
10826 else
10827 cat >"conftest.$ac_ext" <<_ACEOF
10828 #line 10828 "configure"
10829 #include "confdefs.h"
10830 #include <stddef.h>
10831 _ACEOF
10832 if { (eval echo "$as_me:10832: \"$ac_cpp "conftest.$ac_ext"\"") >&5
10833 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
10834 ac_status=$?
10835 $EGREP -v '^ *\+' conftest.er1 >conftest.err
10836 rm -f conftest.er1
10837 cat conftest.err >&5
10838 echo "$as_me:10838: \$? = $ac_status" >&5
10839 (exit "$ac_status"); } >/dev/null; then
10840 if test -s conftest.err; then
10841 ac_cpp_err=$ac_c_preproc_warn_flag
10842 else
10843 ac_cpp_err=
10844 fi
10845 else
10846 ac_cpp_err=yes
10847 fi
10848 if test -z "$ac_cpp_err"; then
10849 ac_cv_header_stddef_h=yes
10850 else
10851 echo "$as_me: failed program was:" >&5
10852 cat "conftest.$ac_ext" >&5
10853 ac_cv_header_stddef_h=no
10854 fi
10855 rm -f conftest.err "conftest.$ac_ext"
10856 fi
10857 echo "$as_me:10857: result: $ac_cv_header_stddef_h" >&5
10858 echo "${ECHO_T}$ac_cv_header_stddef_h" >&6
10859 if test "$ac_cv_header_stddef_h" = yes; then
10860 cf_mawk_check_size=ok
10861 fi
10862
10863 if test "x$cf_mawk_check_size" = xok ; then
10864 echo "$as_me:10864: checking if size_t is declared in stddef.h" >&5
10865 echo $ECHO_N "checking if size_t is declared in stddef.h... $ECHO_C" >&6
10866 if test "${cf_cv_size_t_SIZE_T_STDDEF_H+set}" = set; then
10867 echo $ECHO_N "(cached) $ECHO_C" >&6
10868 else
10869
10870 cat >"conftest.$ac_ext" <<_ACEOF
10871 #line 10871 "configure"
10872 #include "confdefs.h"
10873 #include <stddef.h>
10874 int
10875 main (void)
10876 {
10877 size_t *n
10878 ;
10879 return 0;
10880 }
10881 _ACEOF
10882 rm -f "conftest.$ac_objext"
10883 if { (eval echo "$as_me:10883: \"$ac_compile\"") >&5
10884 (eval $ac_compile) 2>&5
10885 ac_status=$?
10886 echo "$as_me:10886: \$? = $ac_status" >&5
10887 (exit "$ac_status"); } &&
10888 { ac_try='test -s "conftest.$ac_objext"'
10889 { (eval echo "$as_me:10889: \"$ac_try\"") >&5
10890 (eval $ac_try) 2>&5
10891 ac_status=$?
10892 echo "$as_me:10892: \$? = $ac_status" >&5
10893 (exit "$ac_status"); }; }; then
10894 cf_cv_size_t_SIZE_T_STDDEF_H=yes
10895 else
10896 echo "$as_me: failed program was:" >&5
10897 cat "conftest.$ac_ext" >&5
10898 cf_cv_size_t_SIZE_T_STDDEF_H=no
10899 fi
10900 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10901 fi
10902 echo "$as_me:10902: result: $cf_cv_size_t_SIZE_T_STDDEF_H" >&5
10903 echo "${ECHO_T}$cf_cv_size_t_SIZE_T_STDDEF_H" >&6
10904 fi
10905
10906 fi
10907
10908 if test "x$cf_cv_size_t_SIZE_T_STDDEF_H" = xyes ; then
10909
10910 cat >>confdefs.h <<EOF
10911 #define SIZE_T_STDDEF_H 1
10912 EOF
10913
10914 cf_mawk_check_size_t=yes
10915 fi
10916 fi
10917
10918 if test "x$cf_mawk_check_size_t" != xyes ; then
10919
10920 if test "${cf_cv_size_t_SIZE_T_TYPES_H+set}" = set; then
10921 echo $ECHO_N "(cached) $ECHO_C" >&6
10922 else
10923
10924 echo "$as_me:10924: checking for sys/types.h" >&5
10925 echo $ECHO_N "checking for sys/types.h... $ECHO_C" >&6
10926 if test "${ac_cv_header_sys_types_h+set}" = set; then
10927 echo $ECHO_N "(cached) $ECHO_C" >&6
10928 else
10929 cat >"conftest.$ac_ext" <<_ACEOF
10930 #line 10930 "configure"
10931 #include "confdefs.h"
10932 #include <sys/types.h>
10933 _ACEOF
10934 if { (eval echo "$as_me:10934: \"$ac_cpp "conftest.$ac_ext"\"") >&5
10935 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
10936 ac_status=$?
10937 $EGREP -v '^ *\+' conftest.er1 >conftest.err
10938 rm -f conftest.er1
10939 cat conftest.err >&5
10940 echo "$as_me:10940: \$? = $ac_status" >&5
10941 (exit "$ac_status"); } >/dev/null; then
10942 if test -s conftest.err; then
10943 ac_cpp_err=$ac_c_preproc_warn_flag
10944 else
10945 ac_cpp_err=
10946 fi
10947 else
10948 ac_cpp_err=yes
10949 fi
10950 if test -z "$ac_cpp_err"; then
10951 ac_cv_header_sys_types_h=yes
10952 else
10953 echo "$as_me: failed program was:" >&5
10954 cat "conftest.$ac_ext" >&5
10955 ac_cv_header_sys_types_h=no
10956 fi
10957 rm -f conftest.err "conftest.$ac_ext"
10958 fi
10959 echo "$as_me:10959: result: $ac_cv_header_sys_types_h" >&5
10960 echo "${ECHO_T}$ac_cv_header_sys_types_h" >&6
10961 if test "$ac_cv_header_sys_types_h" = yes; then
10962 cf_mawk_check_size=ok
10963 fi
10964
10965 if test "x$cf_mawk_check_size" = xok ; then
10966 echo "$as_me:10966: checking if size_t is declared in sys/types.h" >&5
10967 echo $ECHO_N "checking if size_t is declared in sys/types.h... $ECHO_C" >&6
10968 if test "${cf_cv_size_t_SIZE_T_TYPES_H+set}" = set; then
10969 echo $ECHO_N "(cached) $ECHO_C" >&6
10970 else
10971
10972 cat >"conftest.$ac_ext" <<_ACEOF
10973 #line 10973 "configure"
10974 #include "confdefs.h"
10975 #include <sys/types.h>
10976 int
10977 main (void)
10978 {
10979 size_t *n
10980 ;
10981 return 0;
10982 }
10983 _ACEOF
10984 rm -f "conftest.$ac_objext"
10985 if { (eval echo "$as_me:10985: \"$ac_compile\"") >&5
10986 (eval $ac_compile) 2>&5
10987 ac_status=$?
10988 echo "$as_me:10988: \$? = $ac_status" >&5
10989 (exit "$ac_status"); } &&
10990 { ac_try='test -s "conftest.$ac_objext"'
10991 { (eval echo "$as_me:10991: \"$ac_try\"") >&5
10992 (eval $ac_try) 2>&5
10993 ac_status=$?
10994 echo "$as_me:10994: \$? = $ac_status" >&5
10995 (exit "$ac_status"); }; }; then
10996 cf_cv_size_t_SIZE_T_TYPES_H=yes
10997 else
10998 echo "$as_me: failed program was:" >&5
10999 cat "conftest.$ac_ext" >&5
11000 cf_cv_size_t_SIZE_T_TYPES_H=no
11001 fi
11002 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11003 fi
11004 echo "$as_me:11004: result: $cf_cv_size_t_SIZE_T_TYPES_H" >&5
11005 echo "${ECHO_T}$cf_cv_size_t_SIZE_T_TYPES_H" >&6
11006 fi
11007
11008 fi
11009
11010 if test "x$cf_cv_size_t_SIZE_T_TYPES_H" = xyes ; then
11011
11012 cat >>confdefs.h <<EOF
11013 #define SIZE_T_TYPES_H 1
11014 EOF
11015
11016 cf_mawk_check_size_t=yes
11017 fi
11018 fi
11019
11020 echo "$as_me:11020: checking for setlocale()" >&5
11021 echo $ECHO_N "checking for setlocale()... $ECHO_C" >&6
11022 if test "${cf_cv_locale+set}" = set; then
11023 echo $ECHO_N "(cached) $ECHO_C" >&6
11024 else
11025
11026 cat >"conftest.$ac_ext" <<_ACEOF
11027 #line 11027 "configure"
11028 #include "confdefs.h"
11029
11030 $ac_includes_default
11031 #include <locale.h>
11032 int
11033 main (void)
11034 {
11035 setlocale(LC_ALL, "")
11036 ;
11037 return 0;
11038 }
11039 _ACEOF
11040 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11041 if { (eval echo "$as_me:11041: \"$ac_link\"") >&5
11042 (eval $ac_link) 2>&5
11043 ac_status=$?
11044 echo "$as_me:11044: \$? = $ac_status" >&5
11045 (exit "$ac_status"); } &&
11046 { ac_try='test -s "conftest$ac_exeext"'
11047 { (eval echo "$as_me:11047: \"$ac_try\"") >&5
11048 (eval $ac_try) 2>&5
11049 ac_status=$?
11050 echo "$as_me:11050: \$? = $ac_status" >&5
11051 (exit "$ac_status"); }; }; then
11052 cf_cv_locale=yes
11053 else
11054 echo "$as_me: failed program was:" >&5
11055 cat "conftest.$ac_ext" >&5
11056 cf_cv_locale=no
11057 fi
11058 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11059
11060 fi
11061
11062 echo "$as_me:11062: result: $cf_cv_locale" >&5
11063 echo "${ECHO_T}$cf_cv_locale" >&6
11064 test "$cf_cv_locale" = yes && {
11065 cat >>confdefs.h <<\EOF
11066 #define LOCALE 1
11067 EOF
11068 }
11069
11070 echo "$as_me:11070: checking if external environ is declared" >&5
11071 echo $ECHO_N "checking if external environ is declared... $ECHO_C" >&6
11072 if test "${cf_cv_dcl_environ+set}" = set; then
11073 echo $ECHO_N "(cached) $ECHO_C" >&6
11074 else
11075
11076 cat >"conftest.$ac_ext" <<_ACEOF
11077 #line 11077 "configure"
11078 #include "confdefs.h"
11079
11080 $ac_includes_default
11081 int
11082 main (void)
11083 {
11084 void* x = (void*) environ; (void)x
11085 ;
11086 return 0;
11087 }
11088 _ACEOF
11089 rm -f "conftest.$ac_objext"
11090 if { (eval echo "$as_me:11090: \"$ac_compile\"") >&5
11091 (eval $ac_compile) 2>&5
11092 ac_status=$?
11093 echo "$as_me:11093: \$? = $ac_status" >&5
11094 (exit "$ac_status"); } &&
11095 { ac_try='test -s "conftest.$ac_objext"'
11096 { (eval echo "$as_me:11096: \"$ac_try\"") >&5
11097 (eval $ac_try) 2>&5
11098 ac_status=$?
11099 echo "$as_me:11099: \$? = $ac_status" >&5
11100 (exit "$ac_status"); }; }; then
11101 cf_cv_dcl_environ=yes
11102 else
11103 echo "$as_me: failed program was:" >&5
11104 cat "conftest.$ac_ext" >&5
11105 cf_cv_dcl_environ=no
11106 fi
11107 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11108
11109 fi
11110 echo "$as_me:11110: result: $cf_cv_dcl_environ" >&5
11111 echo "${ECHO_T}$cf_cv_dcl_environ" >&6
11112
11113 if test "$cf_cv_dcl_environ" = no ; then
11114
11115 cf_result=`echo "decl_environ" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11116
11117 cat >>confdefs.h <<EOF
11118 #define $cf_result 1
11119 EOF
11120
11121 fi
11122
11123 # It's possible (for near-UNIX clones) that the data doesn't exist
11124
11125 echo "$as_me:11125: checking if external environ exists" >&5
11126 echo $ECHO_N "checking if external environ exists... $ECHO_C" >&6
11127 if test "${cf_cv_have_environ+set}" = set; then
11128 echo $ECHO_N "(cached) $ECHO_C" >&6
11129 else
11130
11131 cat >"conftest.$ac_ext" <<_ACEOF
11132 #line 11132 "configure"
11133 #include "confdefs.h"
11134
11135 #undef environ
11136 extern int environ;
11137
11138 int
11139 main (void)
11140 {
11141 environ = 2
11142 ;
11143 return 0;
11144 }
11145 _ACEOF
11146 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11147 if { (eval echo "$as_me:11147: \"$ac_link\"") >&5
11148 (eval $ac_link) 2>&5
11149 ac_status=$?
11150 echo "$as_me:11150: \$? = $ac_status" >&5
11151 (exit "$ac_status"); } &&
11152 { ac_try='test -s "conftest$ac_exeext"'
11153 { (eval echo "$as_me:11153: \"$ac_try\"") >&5
11154 (eval $ac_try) 2>&5
11155 ac_status=$?
11156 echo "$as_me:11156: \$? = $ac_status" >&5
11157 (exit "$ac_status"); }; }; then
11158 cf_cv_have_environ=yes
11159 else
11160 echo "$as_me: failed program was:" >&5
11161 cat "conftest.$ac_ext" >&5
11162 cf_cv_have_environ=no
11163 fi
11164 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11165
11166 fi
11167 echo "$as_me:11167: result: $cf_cv_have_environ" >&5
11168 echo "${ECHO_T}$cf_cv_have_environ" >&6
11169
11170 if test "$cf_cv_have_environ" = yes ; then
11171
11172 cf_result=`echo "have_environ" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
11173
11174 cat >>confdefs.h <<EOF
11175 #define $cf_result 1
11176 EOF
11177
11178 fi
11179
11180 for ac_func in fork fstat matherr mktime pipe strftime tsearch wait
11181 do
11182 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11183 echo "$as_me:11183: checking for $ac_func" >&5
11184 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11185 if eval "test \"\${$as_ac_var+set}\" = set"; then
11186 echo $ECHO_N "(cached) $ECHO_C" >&6
11187 else
11188 cat >"conftest.$ac_ext" <<_ACEOF
11189 #line 11189 "configure"
11190 #include "confdefs.h"
11191 #define $ac_func autoconf_temporary
11192 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11193 #undef $ac_func
11194
11195 #ifdef __cplusplus
11196 extern "C"
11197 #endif
11198
11199 /* We use char because int might match the return type of a gcc2
11200 builtin and then its argument prototype would still apply. */
11201 char $ac_func (void);
11202
11203 int
11204 main (void)
11205 {
11206
11207 /* The GNU C library defines stubs for functions which it implements
11208 to always fail with ENOSYS. Some functions are actually named
11209 something starting with __ and the normal name is an alias. */
11210 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11211 #error found stub for $ac_func
11212 #endif
11213
11214 return $ac_func ();
11215 ;
11216 return 0;
11217 }
11218 _ACEOF
11219 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11220 if { (eval echo "$as_me:11220: \"$ac_link\"") >&5
11221 (eval $ac_link) 2>&5
11222 ac_status=$?
11223 echo "$as_me:11223: \$? = $ac_status" >&5
11224 (exit "$ac_status"); } &&
11225 { ac_try='test -s "conftest$ac_exeext"'
11226 { (eval echo "$as_me:11226: \"$ac_try\"") >&5
11227 (eval $ac_try) 2>&5
11228 ac_status=$?
11229 echo "$as_me:11229: \$? = $ac_status" >&5
11230 (exit "$ac_status"); }; }; then
11231 eval "$as_ac_var=yes"
11232 else
11233 echo "$as_me: failed program was:" >&5
11234 cat "conftest.$ac_ext" >&5
11235 eval "$as_ac_var=no"
11236 fi
11237 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11238 fi
11239 echo "$as_me:11239: result: `eval echo '${'"$as_ac_var"'}'`" >&5
11240 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
11241 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
11242 cat >>confdefs.h <<EOF
11243 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11244 EOF
11245
11246 fi
11247 done
11248
11249 cf_save_libs="$LIBS"
11250 echo "$as_me:11250: checking for clock_gettime" >&5
11251 echo $ECHO_N "checking for clock_gettime... $ECHO_C" >&6
11252 if test "${ac_cv_func_clock_gettime+set}" = set; then
11253 echo $ECHO_N "(cached) $ECHO_C" >&6
11254 else
11255 cat >"conftest.$ac_ext" <<_ACEOF
11256 #line 11256 "configure"
11257 #include "confdefs.h"
11258 #define clock_gettime autoconf_temporary
11259 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11260 #undef clock_gettime
11261
11262 #ifdef __cplusplus
11263 extern "C"
11264 #endif
11265
11266 /* We use char because int might match the return type of a gcc2
11267 builtin and then its argument prototype would still apply. */
11268 char clock_gettime (void);
11269
11270 int
11271 main (void)
11272 {
11273
11274 /* The GNU C library defines stubs for functions which it implements
11275 to always fail with ENOSYS. Some functions are actually named
11276 something starting with __ and the normal name is an alias. */
11277 #if defined (__stub_clock_gettime) || defined (__stub___clock_gettime)
11278 #error found stub for clock_gettime
11279 #endif
11280
11281 return clock_gettime ();
11282 ;
11283 return 0;
11284 }
11285 _ACEOF
11286 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11287 if { (eval echo "$as_me:11287: \"$ac_link\"") >&5
11288 (eval $ac_link) 2>&5
11289 ac_status=$?
11290 echo "$as_me:11290: \$? = $ac_status" >&5
11291 (exit "$ac_status"); } &&
11292 { ac_try='test -s "conftest$ac_exeext"'
11293 { (eval echo "$as_me:11293: \"$ac_try\"") >&5
11294 (eval $ac_try) 2>&5
11295 ac_status=$?
11296 echo "$as_me:11296: \$? = $ac_status" >&5
11297 (exit "$ac_status"); }; }; then
11298 ac_cv_func_clock_gettime=yes
11299 else
11300 echo "$as_me: failed program was:" >&5
11301 cat "conftest.$ac_ext" >&5
11302 ac_cv_func_clock_gettime=no
11303 fi
11304 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11305 fi
11306 echo "$as_me:11306: result: $ac_cv_func_clock_gettime" >&5
11307 echo "${ECHO_T}$ac_cv_func_clock_gettime" >&6
11308 if test "$ac_cv_func_clock_gettime" = yes; then
11309 cf_cv_test_clock_gettime=yes
11310 else
11311 echo "$as_me:11311: checking for clock_gettime in -lrt" >&5
11312 echo $ECHO_N "checking for clock_gettime in -lrt... $ECHO_C" >&6
11313 if test "${ac_cv_lib_rt_clock_gettime+set}" = set; then
11314 echo $ECHO_N "(cached) $ECHO_C" >&6
11315 else
11316 ac_check_lib_save_LIBS=$LIBS
11317 LIBS="-lrt $LIBS"
11318 cat >"conftest.$ac_ext" <<_ACEOF
11319 #line 11319 "configure"
11320 #include "confdefs.h"
11321
11322 /* Override any gcc2 internal prototype to avoid an error. */
11323 #ifdef __cplusplus
11324 extern "C"
11325 #endif
11326 /* We use char because int might match the return type of a gcc2
11327 builtin and then its argument prototype would still apply. */
11328 char clock_gettime (void);
11329 int
11330 main (void)
11331 {
11332 clock_gettime ();
11333 ;
11334 return 0;
11335 }
11336 _ACEOF
11337 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11338 if { (eval echo "$as_me:11338: \"$ac_link\"") >&5
11339 (eval $ac_link) 2>&5
11340 ac_status=$?
11341 echo "$as_me:11341: \$? = $ac_status" >&5
11342 (exit "$ac_status"); } &&
11343 { ac_try='test -s "conftest$ac_exeext"'
11344 { (eval echo "$as_me:11344: \"$ac_try\"") >&5
11345 (eval $ac_try) 2>&5
11346 ac_status=$?
11347 echo "$as_me:11347: \$? = $ac_status" >&5
11348 (exit "$ac_status"); }; }; then
11349 ac_cv_lib_rt_clock_gettime=yes
11350 else
11351 echo "$as_me: failed program was:" >&5
11352 cat "conftest.$ac_ext" >&5
11353 ac_cv_lib_rt_clock_gettime=no
11354 fi
11355 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11356 LIBS=$ac_check_lib_save_LIBS
11357 fi
11358 echo "$as_me:11358: result: $ac_cv_lib_rt_clock_gettime" >&5
11359 echo "${ECHO_T}$ac_cv_lib_rt_clock_gettime" >&6
11360 if test "$ac_cv_lib_rt_clock_gettime" = yes; then
11361 LIBS="-lrt $LIBS"
11362 cf_cv_test_clock_gettime=yes
11363 else
11364 cf_cv_test_clock_gettime=no
11365 fi
11366
11367 fi
11368
11369 if test "$cf_cv_test_clock_gettime" = yes ; then
11370 echo "$as_me:11370: checking if clock_gettime links" >&5
11371 echo $ECHO_N "checking if clock_gettime links... $ECHO_C" >&6
11372 if test "${cf_cv_func_clock_gettime+set}" = set; then
11373 echo $ECHO_N "(cached) $ECHO_C" >&6
11374 else
11375
11376 cat >"conftest.$ac_ext" <<_ACEOF
11377 #line 11377 "configure"
11378 #include "confdefs.h"
11379
11380 $ac_includes_default
11381 #include <time.h>
11382
11383 int
11384 main (void)
11385 {
11386 struct timespec ts;
11387 int rc = clock_gettime(CLOCK_REALTIME, &ts)
11388 + clock_gettime(CLOCK_MONOTONIC, &ts);
11389 (void) rc; (void)ts
11390 ;
11391 return 0;
11392 }
11393 _ACEOF
11394 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11395 if { (eval echo "$as_me:11395: \"$ac_link\"") >&5
11396 (eval $ac_link) 2>&5
11397 ac_status=$?
11398 echo "$as_me:11398: \$? = $ac_status" >&5
11399 (exit "$ac_status"); } &&
11400 { ac_try='test -s "conftest$ac_exeext"'
11401 { (eval echo "$as_me:11401: \"$ac_try\"") >&5
11402 (eval $ac_try) 2>&5
11403 ac_status=$?
11404 echo "$as_me:11404: \$? = $ac_status" >&5
11405 (exit "$ac_status"); }; }; then
11406 cf_cv_func_clock_gettime=yes
11407 else
11408 echo "$as_me: failed program was:" >&5
11409 cat "conftest.$ac_ext" >&5
11410 cf_cv_func_clock_gettime=no
11411 fi
11412 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11413
11414 fi
11415 echo "$as_me:11415: result: $cf_cv_func_clock_gettime" >&5
11416 echo "${ECHO_T}$cf_cv_func_clock_gettime" >&6
11417 else
11418 cf_cv_func_clock_gettime=no
11419 fi
11420
11421 if test "$cf_cv_func_clock_gettime" = yes
11422 then
11423
11424 cat >>confdefs.h <<\EOF
11425 #define HAVE_CLOCK_GETTIME 1
11426 EOF
11427
11428 else
11429 echo "$as_me:11429: checking for gettimeofday" >&5
11430 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
11431 if test "${ac_cv_func_gettimeofday+set}" = set; then
11432 echo $ECHO_N "(cached) $ECHO_C" >&6
11433 else
11434 cat >"conftest.$ac_ext" <<_ACEOF
11435 #line 11435 "configure"
11436 #include "confdefs.h"
11437 #define gettimeofday autoconf_temporary
11438 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11439 #undef gettimeofday
11440
11441 #ifdef __cplusplus
11442 extern "C"
11443 #endif
11444
11445 /* We use char because int might match the return type of a gcc2
11446 builtin and then its argument prototype would still apply. */
11447 char gettimeofday (void);
11448
11449 int
11450 main (void)
11451 {
11452
11453 /* The GNU C library defines stubs for functions which it implements
11454 to always fail with ENOSYS. Some functions are actually named
11455 something starting with __ and the normal name is an alias. */
11456 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
11457 #error found stub for gettimeofday
11458 #endif
11459
11460 return gettimeofday ();
11461 ;
11462 return 0;
11463 }
11464 _ACEOF
11465 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11466 if { (eval echo "$as_me:11466: \"$ac_link\"") >&5
11467 (eval $ac_link) 2>&5
11468 ac_status=$?
11469 echo "$as_me:11469: \$? = $ac_status" >&5
11470 (exit "$ac_status"); } &&
11471 { ac_try='test -s "conftest$ac_exeext"'
11472 { (eval echo "$as_me:11472: \"$ac_try\"") >&5
11473 (eval $ac_try) 2>&5
11474 ac_status=$?
11475 echo "$as_me:11475: \$? = $ac_status" >&5
11476 (exit "$ac_status"); }; }; then
11477 ac_cv_func_gettimeofday=yes
11478 else
11479 echo "$as_me: failed program was:" >&5
11480 cat "conftest.$ac_ext" >&5
11481 ac_cv_func_gettimeofday=no
11482 fi
11483 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11484 fi
11485 echo "$as_me:11485: result: $ac_cv_func_gettimeofday" >&5
11486 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
11487 if test "$ac_cv_func_gettimeofday" = yes; then
11488
11489 cat >>confdefs.h <<\EOF
11490 #define HAVE_GETTIMEOFDAY 1
11491 EOF
11492
11493 else
11494
11495 echo "$as_me:11495: checking for gettimeofday in -lbsd" >&5
11496 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
11497 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
11498 echo $ECHO_N "(cached) $ECHO_C" >&6
11499 else
11500 ac_check_lib_save_LIBS=$LIBS
11501 LIBS="-lbsd $LIBS"
11502 cat >"conftest.$ac_ext" <<_ACEOF
11503 #line 11503 "configure"
11504 #include "confdefs.h"
11505
11506 /* Override any gcc2 internal prototype to avoid an error. */
11507 #ifdef __cplusplus
11508 extern "C"
11509 #endif
11510 /* We use char because int might match the return type of a gcc2
11511 builtin and then its argument prototype would still apply. */
11512 char gettimeofday (void);
11513 int
11514 main (void)
11515 {
11516 gettimeofday ();
11517 ;
11518 return 0;
11519 }
11520 _ACEOF
11521 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11522 if { (eval echo "$as_me:11522: \"$ac_link\"") >&5
11523 (eval $ac_link) 2>&5
11524 ac_status=$?
11525 echo "$as_me:11525: \$? = $ac_status" >&5
11526 (exit "$ac_status"); } &&
11527 { ac_try='test -s "conftest$ac_exeext"'
11528 { (eval echo "$as_me:11528: \"$ac_try\"") >&5
11529 (eval $ac_try) 2>&5
11530 ac_status=$?
11531 echo "$as_me:11531: \$? = $ac_status" >&5
11532 (exit "$ac_status"); }; }; then
11533 ac_cv_lib_bsd_gettimeofday=yes
11534 else
11535 echo "$as_me: failed program was:" >&5
11536 cat "conftest.$ac_ext" >&5
11537 ac_cv_lib_bsd_gettimeofday=no
11538 fi
11539 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11540 LIBS=$ac_check_lib_save_LIBS
11541 fi
11542 echo "$as_me:11542: result: $ac_cv_lib_bsd_gettimeofday" >&5
11543 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
11544 if test "$ac_cv_lib_bsd_gettimeofday" = yes; then
11545
11546 cat >>confdefs.h <<\EOF
11547 #define HAVE_GETTIMEOFDAY 1
11548 EOF
11549
11550 cf_add_libs="$LIBS"
11551 # reverse order
11552 cf_add_0lib=
11553 for cf_add_1lib in -lbsd; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11554 # filter duplicates
11555 for cf_add_1lib in $cf_add_0lib; do
11556 for cf_add_2lib in $cf_add_libs; do
11557 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11558 cf_add_1lib=
11559 break
11560 fi
11561 done
11562 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11563 done
11564 LIBS="$cf_add_libs"
11565
11566 fi
11567
11568 fi
11569 fi
11570
11571 ### Checks for libraries.
11572 case $cf_cv_system_name in
11573 (*mingw32*)
11574 CPPFLAGS="$CPPFLAGS -DWINVER=0x0501"
11575 # LIBS=" -lpsapi $LIBS"
11576 ;;
11577 esac
11578
11579 test "$ac_cv_func_fork" = yes && \
11580 test "$ac_cv_func_pipe" = yes && \
11581 test "$ac_cv_func_wait" = yes && \
11582
11583 cat >>confdefs.h <<\EOF
11584 #define HAVE_REAL_PIPES 1
11585 EOF
11586
11587 echo "$as_me:11587: checking if math.h declares _LIB_VERSION" >&5
11588 echo $ECHO_N "checking if math.h declares _LIB_VERSION... $ECHO_C" >&6
11589 if test "${cf_cv_get_math_lib_version+set}" = set; then
11590 echo $ECHO_N "(cached) $ECHO_C" >&6
11591 else
11592
11593 cat >"conftest.$ac_ext" <<_ACEOF
11594 #line 11594 "configure"
11595 #include "confdefs.h"
11596
11597 #include <math.h>
11598 int
11599 main (void)
11600 {
11601 int foo = _LIB_VERSION
11602 ;
11603 return 0;
11604 }
11605 _ACEOF
11606 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11607 if { (eval echo "$as_me:11607: \"$ac_link\"") >&5
11608 (eval $ac_link) 2>&5
11609 ac_status=$?
11610 echo "$as_me:11610: \$? = $ac_status" >&5
11611 (exit "$ac_status"); } &&
11612 { ac_try='test -s "conftest$ac_exeext"'
11613 { (eval echo "$as_me:11613: \"$ac_try\"") >&5
11614 (eval $ac_try) 2>&5
11615 ac_status=$?
11616 echo "$as_me:11616: \$? = $ac_status" >&5
11617 (exit "$ac_status"); }; }; then
11618 cf_cv_get_math_lib_version=yes
11619 else
11620 echo "$as_me: failed program was:" >&5
11621 cat "conftest.$ac_ext" >&5
11622 cf_cv_get_math_lib_version=no
11623 fi
11624 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11625
11626 fi
11627 echo "$as_me:11627: result: $cf_cv_get_math_lib_version" >&5
11628 echo "${ECHO_T}$cf_cv_get_math_lib_version" >&6
11629
11630 if test "x$cf_cv_get_math_lib_version" = xyes
11631 then
11632 echo "$as_me:11632: checking if we can update _LIB_VERSION" >&5
11633 echo $ECHO_N "checking if we can update _LIB_VERSION... $ECHO_C" >&6
11634 if test "${cf_cv_set_math_lib_version+set}" = set; then
11635 echo $ECHO_N "(cached) $ECHO_C" >&6
11636 else
11637
11638 cat >"conftest.$ac_ext" <<_ACEOF
11639 #line 11639 "configure"
11640 #include "confdefs.h"
11641
11642 #include <math.h>
11643 int
11644 main (void)
11645 {
11646 _LIB_VERSION = _IEEE_
11647 ;
11648 return 0;
11649 }
11650 _ACEOF
11651 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11652 if { (eval echo "$as_me:11652: \"$ac_link\"") >&5
11653 (eval $ac_link) 2>&5
11654 ac_status=$?
11655 echo "$as_me:11655: \$? = $ac_status" >&5
11656 (exit "$ac_status"); } &&
11657 { ac_try='test -s "conftest$ac_exeext"'
11658 { (eval echo "$as_me:11658: \"$ac_try\"") >&5
11659 (eval $ac_try) 2>&5
11660 ac_status=$?
11661 echo "$as_me:11661: \$? = $ac_status" >&5
11662 (exit "$ac_status"); }; }; then
11663 cf_cv_set_math_lib_version=yes
11664 else
11665 echo "$as_me: failed program was:" >&5
11666 cat "conftest.$ac_ext" >&5
11667 cf_cv_set_math_lib_version=no
11668 fi
11669 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11670
11671 fi
11672 echo "$as_me:11672: result: $cf_cv_set_math_lib_version" >&5
11673 echo "${ECHO_T}$cf_cv_set_math_lib_version" >&6
11674 if test "x$cf_cv_set_math_lib_version" = xyes
11675 then
11676
11677 cat >>confdefs.h <<\EOF
11678 #define HAVE_MATH__LIB_VERSION 1
11679 EOF
11680
11681 else
11682 { echo "$as_me:11682: WARNING: this is probably due to a defect in your system headers" >&5
11683 echo "$as_me: WARNING: this is probably due to a defect in your system headers" >&2;}
11684 fi
11685 fi
11686
11687 echo "$as_me:11687: checking for limits.h" >&5
11688 echo $ECHO_N "checking for limits.h... $ECHO_C" >&6
11689 if test "${ac_cv_header_limits_h+set}" = set; then
11690 echo $ECHO_N "(cached) $ECHO_C" >&6
11691 else
11692 cat >"conftest.$ac_ext" <<_ACEOF
11693 #line 11693 "configure"
11694 #include "confdefs.h"
11695 #include <limits.h>
11696 _ACEOF
11697 if { (eval echo "$as_me:11697: \"$ac_cpp "conftest.$ac_ext"\"") >&5
11698 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
11699 ac_status=$?
11700 $EGREP -v '^ *\+' conftest.er1 >conftest.err
11701 rm -f conftest.er1
11702 cat conftest.err >&5
11703 echo "$as_me:11703: \$? = $ac_status" >&5
11704 (exit "$ac_status"); } >/dev/null; then
11705 if test -s conftest.err; then
11706 ac_cpp_err=$ac_c_preproc_warn_flag
11707 else
11708 ac_cpp_err=
11709 fi
11710 else
11711 ac_cpp_err=yes
11712 fi
11713 if test -z "$ac_cpp_err"; then
11714 ac_cv_header_limits_h=yes
11715 else
11716 echo "$as_me: failed program was:" >&5
11717 cat "conftest.$ac_ext" >&5
11718 ac_cv_header_limits_h=no
11719 fi
11720 rm -f conftest.err "conftest.$ac_ext"
11721 fi
11722 echo "$as_me:11722: result: $ac_cv_header_limits_h" >&5
11723 echo "${ECHO_T}$ac_cv_header_limits_h" >&6
11724 if test "$ac_cv_header_limits_h" = yes; then
11725 cf_limits_h=yes
11726 fi
11727
11728 if test "x$cf_limits_h" = xyes ; then :
11729 else
11730 echo "$as_me:11730: checking for values.h" >&5
11731 echo $ECHO_N "checking for values.h... $ECHO_C" >&6
11732 if test "${ac_cv_header_values_h+set}" = set; then
11733 echo $ECHO_N "(cached) $ECHO_C" >&6
11734 else
11735 cat >"conftest.$ac_ext" <<_ACEOF
11736 #line 11736 "configure"
11737 #include "confdefs.h"
11738 #include <values.h>
11739 _ACEOF
11740 if { (eval echo "$as_me:11740: \"$ac_cpp "conftest.$ac_ext"\"") >&5
11741 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
11742 ac_status=$?
11743 $EGREP -v '^ *\+' conftest.er1 >conftest.err
11744 rm -f conftest.er1
11745 cat conftest.err >&5
11746 echo "$as_me:11746: \$? = $ac_status" >&5
11747 (exit "$ac_status"); } >/dev/null; then
11748 if test -s conftest.err; then
11749 ac_cpp_err=$ac_c_preproc_warn_flag
11750 else
11751 ac_cpp_err=
11752 fi
11753 else
11754 ac_cpp_err=yes
11755 fi
11756 if test -z "$ac_cpp_err"; then
11757 ac_cv_header_values_h=yes
11758 else
11759 echo "$as_me: failed program was:" >&5
11760 cat "conftest.$ac_ext" >&5
11761 ac_cv_header_values_h=no
11762 fi
11763 rm -f conftest.err "conftest.$ac_ext"
11764 fi
11765 echo "$as_me:11765: result: $ac_cv_header_values_h" >&5
11766 echo "${ECHO_T}$ac_cv_header_values_h" >&6
11767 if test "$ac_cv_header_values_h" = yes; then
11768 cf_values_h=yes
11769 fi
11770
11771 if test "x$cf_values_h" = xyes ; then
11772 if test "$cross_compiling" = yes; then
11773 { { echo "$as_me:11773: error: cannot run test program while cross compiling" >&5
11774 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
11775 { (exit 1); exit 1; }; }
11776 else
11777 cat >"conftest.$ac_ext" <<_ACEOF
11778 #line 11778 "configure"
11779 #include "confdefs.h"
11780 $ac_includes_default
11781
11782 #include <values.h>
11783
11784 int main(void)
11785 { FILE *out = fopen("conftest.out", "w") ;
11786 unsigned max_uint = 0;
11787 unsigned long max_ulong = 0;
11788 if ( ! out ) exit(1) ;
11789 fprintf(out, "MAX__INT 0x%x\n", MAXINT) ;
11790 fprintf(out, "MAX__LONG 0x%lx\n", MAXLONG) ;
11791 #ifdef MAXUINT
11792 max_uint = MAXUINT; /* not likely (SunOS/Solaris lacks it) */
11793 #else
11794 max_uint = MAXINT;
11795 max_uint <<= 1;
11796 max_uint |= 1;
11797 #endif
11798 fprintf(out, "MAX__UINT 0x%lx\n", max_uint) ;
11799 #ifdef MAXULONG
11800 max_ulong = MAXULONG;
11801 #else
11802 max_ulong = MAXLONG;
11803 max_ulong <<= 1;
11804 max_ulong |= 1;
11805 #endif
11806 fprintf(out, "MAX__ULONG 0x%lx\n", max_ulong) ;
11807 ${cf_cv_main_return:-return}(0);
11808 }
11809
11810 _ACEOF
11811 rm -f "conftest$ac_exeext"
11812 if { (eval echo "$as_me:11812: \"$ac_link\"") >&5
11813 (eval $ac_link) 2>&5
11814 ac_status=$?
11815 echo "$as_me:11815: \$? = $ac_status" >&5
11816 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
11817 { (eval echo "$as_me:11817: \"$ac_try\"") >&5
11818 (eval $ac_try) 2>&5
11819 ac_status=$?
11820 echo "$as_me:11820: \$? = $ac_status" >&5
11821 (exit "$ac_status"); }; }; then
11822 cf_maxint_set=yes
11823 else
11824 echo "$as_me: program exited with status $ac_status" >&5
11825 echo "$as_me: failed program was:" >&5
11826 cat "conftest.$ac_ext" >&5
11827 { { echo "$as_me:11827: error: C program to compute maxint and maxlong failed.
11828 Please send bug report to [email protected]." >&5
11829 echo "$as_me: error: C program to compute maxint and maxlong failed.
11830 Please send bug report to [email protected]." >&2;}
11831 { (exit 1); exit 1; }; }
11832 fi
11833 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
11834 fi
11835 fi
11836 if test "x$cf_maxint_set" != xyes ; then
11837 # compute it -- assumes two's complement
11838 if test "$cross_compiling" = yes; then
11839 { { echo "$as_me:11839: error: cannot run test program while cross compiling" >&5
11840 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
11841 { (exit 1); exit 1; }; }
11842 else
11843 cat >"conftest.$ac_ext" <<_ACEOF
11844 #line 11844 "configure"
11845 #include "confdefs.h"
11846 #include <stdio.h>
11847 #include <stdlib.h>
11848 int main(void)
11849 {
11850 static int y ;
11851 static unsigned yu;
11852 static long yy ;
11853 static unsigned long yyu ;
11854 FILE *out ;
11855
11856 if ( !(out = fopen("conftest.out","w")) ) exit(1) ;
11857 /* find max int and max long */
11858 y = 0x1000 ;
11859 while ( y > 0 ) { yu = y; y *= 2 ; }
11860 fprintf(out,"MAX__INT 0x%x\n", y-1) ;
11861
11862 yu = yu - 1;
11863 yu <<= 1;
11864 yu |= 1;
11865 yu <<= 1;
11866 yu |= 1;
11867 fprintf(out,"MAX__UINT 0x%xU\n", yu) ;
11868
11869 yy = 0x1000 ;
11870 while ( yy > 0 ) { yyu = yy; yy *= 2 ; }
11871 fprintf(out,"MAX__LONG 0x%lxL\n", yy-1) ;
11872
11873 yyu = yyu - 1;
11874 yyu <<= 1;
11875 yyu |= 1;
11876 yyu <<= 1;
11877 yyu |= 1;
11878 fprintf(out,"MAX__ULONG 0x%lxUL\n", yyu) ;
11879
11880 ${cf_cv_main_return:-return}(0);
11881 }
11882 _ACEOF
11883 rm -f "conftest$ac_exeext"
11884 if { (eval echo "$as_me:11884: \"$ac_link\"") >&5
11885 (eval $ac_link) 2>&5
11886 ac_status=$?
11887 echo "$as_me:11887: \$? = $ac_status" >&5
11888 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
11889 { (eval echo "$as_me:11889: \"$ac_try\"") >&5
11890 (eval $ac_try) 2>&5
11891 ac_status=$?
11892 echo "$as_me:11892: \$? = $ac_status" >&5
11893 (exit "$ac_status"); }; }; then
11894 :
11895 else
11896 echo "$as_me: program exited with status $ac_status" >&5
11897 echo "$as_me: failed program was:" >&5
11898 cat "conftest.$ac_ext" >&5
11899 { { echo "$as_me:11899: error: C program to compute maxint and maxlong failed.
11900 Please send bug report to [email protected]." >&5
11901 echo "$as_me: error: C program to compute maxint and maxlong failed.
11902 Please send bug report to [email protected]." >&2;}
11903 { (exit 1); exit 1; }; }
11904 fi
11905 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
11906 fi
11907 fi
11908 cat conftest.out | while true
11909 do
11910 read name value
11911 test -z "$name" && break
11912 cat >>confdefs.h <<EOF
11913 #define $name $value
11914 EOF
11915
11916 done
11917 rm -f conftest.out
11918 fi
11919
11920 for ac_func in isinf isnan sigaction
11921 do
11922 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11923 echo "$as_me:11923: checking for $ac_func" >&5
11924 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11925 if eval "test \"\${$as_ac_var+set}\" = set"; then
11926 echo $ECHO_N "(cached) $ECHO_C" >&6
11927 else
11928 cat >"conftest.$ac_ext" <<_ACEOF
11929 #line 11929 "configure"
11930 #include "confdefs.h"
11931 #define $ac_func autoconf_temporary
11932 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
11933 #undef $ac_func
11934
11935 #ifdef __cplusplus
11936 extern "C"
11937 #endif
11938
11939 /* We use char because int might match the return type of a gcc2
11940 builtin and then its argument prototype would still apply. */
11941 char $ac_func (void);
11942
11943 int
11944 main (void)
11945 {
11946
11947 /* The GNU C library defines stubs for functions which it implements
11948 to always fail with ENOSYS. Some functions are actually named
11949 something starting with __ and the normal name is an alias. */
11950 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11951 #error found stub for $ac_func
11952 #endif
11953
11954 return $ac_func ();
11955 ;
11956 return 0;
11957 }
11958 _ACEOF
11959 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11960 if { (eval echo "$as_me:11960: \"$ac_link\"") >&5
11961 (eval $ac_link) 2>&5
11962 ac_status=$?
11963 echo "$as_me:11963: \$? = $ac_status" >&5
11964 (exit "$ac_status"); } &&
11965 { ac_try='test -s "conftest$ac_exeext"'
11966 { (eval echo "$as_me:11966: \"$ac_try\"") >&5
11967 (eval $ac_try) 2>&5
11968 ac_status=$?
11969 echo "$as_me:11969: \$? = $ac_status" >&5
11970 (exit "$ac_status"); }; }; then
11971 eval "$as_ac_var=yes"
11972 else
11973 echo "$as_me: failed program was:" >&5
11974 cat "conftest.$ac_ext" >&5
11975 eval "$as_ac_var=no"
11976 fi
11977 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11978 fi
11979 echo "$as_me:11979: result: `eval echo '${'"$as_ac_var"'}'`" >&5
11980 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
11981 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
11982 cat >>confdefs.h <<EOF
11983 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11984 EOF
11985
11986 fi
11987 done
11988
11989 test "$ac_cv_func_sigaction" = yes && sigaction=1
11990
11991 for ac_header in siginfo.h
11992 do
11993 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11994 echo "$as_me:11994: checking for $ac_header" >&5
11995 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11996 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11997 echo $ECHO_N "(cached) $ECHO_C" >&6
11998 else
11999 cat >"conftest.$ac_ext" <<_ACEOF
12000 #line 12000 "configure"
12001 #include "confdefs.h"
12002 #include <$ac_header>
12003 _ACEOF
12004 if { (eval echo "$as_me:12004: \"$ac_cpp "conftest.$ac_ext"\"") >&5
12005 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
12006 ac_status=$?
12007 $EGREP -v '^ *\+' conftest.er1 >conftest.err
12008 rm -f conftest.er1
12009 cat conftest.err >&5
12010 echo "$as_me:12010: \$? = $ac_status" >&5
12011 (exit "$ac_status"); } >/dev/null; then
12012 if test -s conftest.err; then
12013 ac_cpp_err=$ac_c_preproc_warn_flag
12014 else
12015 ac_cpp_err=
12016 fi
12017 else
12018 ac_cpp_err=yes
12019 fi
12020 if test -z "$ac_cpp_err"; then
12021 eval "$as_ac_Header=yes"
12022 else
12023 echo "$as_me: failed program was:" >&5
12024 cat "conftest.$ac_ext" >&5
12025 eval "$as_ac_Header=no"
12026 fi
12027 rm -f conftest.err "conftest.$ac_ext"
12028 fi
12029 echo "$as_me:12029: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
12030 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
12031 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
12032 cat >>confdefs.h <<EOF
12033 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12034 EOF
12035
12036 fi
12037 done
12038
12039 test "$ac_cv_header_siginfo_h" = yes && siginfo_h=1
12040
12041 echo "$as_me:12041: checking if we should use siginfo" >&5
12042 echo $ECHO_N "checking if we should use siginfo... $ECHO_C" >&6
12043 if test "${cf_cv_use_sv_siginfo+set}" = set; then
12044 echo $ECHO_N "(cached) $ECHO_C" >&6
12045 else
12046
12047 if test "$sigaction" = 1 && test "$siginfo_h" = 1 ; then
12048 cf_cv_use_sv_siginfo=yes
12049 else
12050 cf_cv_use_sv_siginfo=no
12051 fi
12052
12053 fi
12054 echo "$as_me:12054: result: $cf_cv_use_sv_siginfo" >&5
12055 echo "${ECHO_T}$cf_cv_use_sv_siginfo" >&6
12056
12057 echo "$as_me:12057: checking return type of signal handlers" >&5
12058 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
12059 if test "${ac_cv_type_signal+set}" = set; then
12060 echo $ECHO_N "(cached) $ECHO_C" >&6
12061 else
12062 cat >"conftest.$ac_ext" <<_ACEOF
12063 #line 12063 "configure"
12064 #include "confdefs.h"
12065 #include <sys/types.h>
12066 #include <signal.h>
12067 #ifdef signal
12068 # undef signal
12069 #endif
12070 extern void (*signal (int, void (*)(int)))(int);
12071
12072 int
12073 main (void)
12074 {
12075 int i = 0; (void) i
12076 ;
12077 return 0;
12078 }
12079 _ACEOF
12080 rm -f "conftest.$ac_objext"
12081 if { (eval echo "$as_me:12081: \"$ac_compile\"") >&5
12082 (eval $ac_compile) 2>&5
12083 ac_status=$?
12084 echo "$as_me:12084: \$? = $ac_status" >&5
12085 (exit "$ac_status"); } &&
12086 { ac_try='test -s "conftest.$ac_objext"'
12087 { (eval echo "$as_me:12087: \"$ac_try\"") >&5
12088 (eval $ac_try) 2>&5
12089 ac_status=$?
12090 echo "$as_me:12090: \$? = $ac_status" >&5
12091 (exit "$ac_status"); }; }; then
12092 ac_cv_type_signal=void
12093 else
12094 echo "$as_me: failed program was:" >&5
12095 cat "conftest.$ac_ext" >&5
12096 ac_cv_type_signal=int
12097 fi
12098 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12099 fi
12100 echo "$as_me:12100: result: $ac_cv_type_signal" >&5
12101 echo "${ECHO_T}$ac_cv_type_signal" >&6
12102
12103 cat >>confdefs.h <<EOF
12104 #define RETSIGTYPE $ac_cv_type_signal
12105 EOF
12106
12107 echo "$as_me:12107: checking if we should use sigaction.sa_sigaction" >&5
12108 echo $ECHO_N "checking if we should use sigaction.sa_sigaction... $ECHO_C" >&6
12109 if test "${cf_cv_use_sa_sigaction+set}" = set; then
12110 echo $ECHO_N "(cached) $ECHO_C" >&6
12111 else
12112
12113 cf_cv_use_sa_sigaction=no
12114 if test "$ac_cv_func_sigaction" = yes
12115 then
12116 cat >"conftest.$ac_ext" <<_ACEOF
12117 #line 12117 "configure"
12118 #include "confdefs.h"
12119 #include <signal.h>
12120 int
12121 main (void)
12122 {
12123
12124 struct sigaction foo;
12125 foo.sa_sigaction = 0;
12126 (void) foo;
12127
12128 ;
12129 return 0;
12130 }
12131 _ACEOF
12132 rm -f "conftest.$ac_objext"
12133 if { (eval echo "$as_me:12133: \"$ac_compile\"") >&5
12134 (eval $ac_compile) 2>&5
12135 ac_status=$?
12136 echo "$as_me:12136: \$? = $ac_status" >&5
12137 (exit "$ac_status"); } &&
12138 { ac_try='test -s "conftest.$ac_objext"'
12139 { (eval echo "$as_me:12139: \"$ac_try\"") >&5
12140 (eval $ac_try) 2>&5
12141 ac_status=$?
12142 echo "$as_me:12142: \$? = $ac_status" >&5
12143 (exit "$ac_status"); }; }; then
12144 cf_cv_use_sa_sigaction=yes
12145 else
12146 echo "$as_me: failed program was:" >&5
12147 cat "conftest.$ac_ext" >&5
12148 fi
12149 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
12150 fi
12151
12152 fi
12153 echo "$as_me:12153: result: $cf_cv_use_sa_sigaction" >&5
12154 echo "${ECHO_T}$cf_cv_use_sa_sigaction" >&6
12155
12156 test "$cf_cv_use_sa_sigaction" = yes &&
12157 cat >>confdefs.h <<\EOF
12158 #define HAVE_SIGACTION_SA_SIGACTION 1
12159 EOF
12160
12161 cf_FPE_DEFS="$CPPFLAGS"
12162 cf_FPE_LIBS="$LIBS"
12163 cf_FPE_SRCS="$srcdir/fpe_check.c"
12164
12165 CPPFLAGS="$CPPFLAGS -I. -DRETSIGTYPE=$ac_cv_type_signal"
12166 LIBS="$MATHLIB $LIBS"
12167
12168 echo checking handling of floating point exceptions
12169
12170 cat >conftest.$ac_ext <<CF_EOF
12171 #include <$cf_FPE_SRCS>
12172 CF_EOF
12173
12174 rm -f conftest$ac_exeext
12175
12176 if { (eval echo "$as_me:12176: \"$ac_link\"") >&5
12177 (eval $ac_link) 2>&5
12178 ac_status=$?
12179 echo "$as_me:12179: \$? = $ac_status" >&5
12180 (exit "$ac_status"); }; then
12181 echo "FPE_CHECK 1:check_fpe_traps" >&5
12182 ./conftest 2>/dev/null
12183 cf_status=$?
12184 else
12185 echo "$cf_FPE_SRCS failed to compile" 1>&2
12186 cf_status=100
12187 fi
12188
12189 echo "FPE_CHECK status=$cf_status" >&5
12190 case $cf_status in
12191 (0) ;; # good news do nothing
12192 (3) # reasonably good news
12193
12194 cat >>confdefs.h <<\EOF
12195 #define FPE_TRAPS_ON 1
12196 EOF
12197
12198 if test "x$cf_cv_use_sv_siginfo" = "xno"
12199 then
12200 echo "$as_me:12200: checking for sigvec" >&5
12201 echo $ECHO_N "checking for sigvec... $ECHO_C" >&6
12202 if test "${ac_cv_func_sigvec+set}" = set; then
12203 echo $ECHO_N "(cached) $ECHO_C" >&6
12204 else
12205 cat >"conftest.$ac_ext" <<_ACEOF
12206 #line 12206 "configure"
12207 #include "confdefs.h"
12208 #define sigvec autoconf_temporary
12209 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12210 #undef sigvec
12211
12212 #ifdef __cplusplus
12213 extern "C"
12214 #endif
12215
12216 /* We use char because int might match the return type of a gcc2
12217 builtin and then its argument prototype would still apply. */
12218 char sigvec (void);
12219
12220 int
12221 main (void)
12222 {
12223
12224 /* The GNU C library defines stubs for functions which it implements
12225 to always fail with ENOSYS. Some functions are actually named
12226 something starting with __ and the normal name is an alias. */
12227 #if defined (__stub_sigvec) || defined (__stub___sigvec)
12228 #error found stub for sigvec
12229 #endif
12230
12231 return sigvec ();
12232 ;
12233 return 0;
12234 }
12235 _ACEOF
12236 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12237 if { (eval echo "$as_me:12237: \"$ac_link\"") >&5
12238 (eval $ac_link) 2>&5
12239 ac_status=$?
12240 echo "$as_me:12240: \$? = $ac_status" >&5
12241 (exit "$ac_status"); } &&
12242 { ac_try='test -s "conftest$ac_exeext"'
12243 { (eval echo "$as_me:12243: \"$ac_try\"") >&5
12244 (eval $ac_try) 2>&5
12245 ac_status=$?
12246 echo "$as_me:12246: \$? = $ac_status" >&5
12247 (exit "$ac_status"); }; }; then
12248 ac_cv_func_sigvec=yes
12249 else
12250 echo "$as_me: failed program was:" >&5
12251 cat "conftest.$ac_ext" >&5
12252 ac_cv_func_sigvec=no
12253 fi
12254 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12255 fi
12256 echo "$as_me:12256: result: $ac_cv_func_sigvec" >&5
12257 echo "${ECHO_T}$ac_cv_func_sigvec" >&6
12258 if test "$ac_cv_func_sigvec" = yes; then
12259 cf_have_sigvec=1
12260 fi
12261
12262 echo "FPE_CHECK 2:get_fpe_codes" >&5
12263 if test "$cf_have_sigvec" = 1 && ./fpe_check$ac_exeext phoney_arg >> defines.out ; then
12264 :
12265 else
12266
12267 cat >>confdefs.h <<\EOF
12268 #define NOINFO_SIGFPE 1
12269 EOF
12270
12271 fi
12272 fi ;;
12273
12274 (1|2|4) # bad news have to turn off traps
12275 # only know how to do this on systemV and solaris
12276 echo "$as_me:12276: checking for ieeefp.h" >&5
12277 echo $ECHO_N "checking for ieeefp.h... $ECHO_C" >&6
12278 if test "${ac_cv_header_ieeefp_h+set}" = set; then
12279 echo $ECHO_N "(cached) $ECHO_C" >&6
12280 else
12281 cat >"conftest.$ac_ext" <<_ACEOF
12282 #line 12282 "configure"
12283 #include "confdefs.h"
12284 #include <ieeefp.h>
12285 _ACEOF
12286 if { (eval echo "$as_me:12286: \"$ac_cpp "conftest.$ac_ext"\"") >&5
12287 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
12288 ac_status=$?
12289 $EGREP -v '^ *\+' conftest.er1 >conftest.err
12290 rm -f conftest.er1
12291 cat conftest.err >&5
12292 echo "$as_me:12292: \$? = $ac_status" >&5
12293 (exit "$ac_status"); } >/dev/null; then
12294 if test -s conftest.err; then
12295 ac_cpp_err=$ac_c_preproc_warn_flag
12296 else
12297 ac_cpp_err=
12298 fi
12299 else
12300 ac_cpp_err=yes
12301 fi
12302 if test -z "$ac_cpp_err"; then
12303 ac_cv_header_ieeefp_h=yes
12304 else
12305 echo "$as_me: failed program was:" >&5
12306 cat "conftest.$ac_ext" >&5
12307 ac_cv_header_ieeefp_h=no
12308 fi
12309 rm -f conftest.err "conftest.$ac_ext"
12310 fi
12311 echo "$as_me:12311: result: $ac_cv_header_ieeefp_h" >&5
12312 echo "${ECHO_T}$ac_cv_header_ieeefp_h" >&6
12313 if test "$ac_cv_header_ieeefp_h" = yes; then
12314 cf_have_ieeefp_h=1
12315 fi
12316
12317 echo "$as_me:12317: checking for fpsetmask" >&5
12318 echo $ECHO_N "checking for fpsetmask... $ECHO_C" >&6
12319 if test "${ac_cv_func_fpsetmask+set}" = set; then
12320 echo $ECHO_N "(cached) $ECHO_C" >&6
12321 else
12322 cat >"conftest.$ac_ext" <<_ACEOF
12323 #line 12323 "configure"
12324 #include "confdefs.h"
12325 #define fpsetmask autoconf_temporary
12326 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12327 #undef fpsetmask
12328
12329 #ifdef __cplusplus
12330 extern "C"
12331 #endif
12332
12333 /* We use char because int might match the return type of a gcc2
12334 builtin and then its argument prototype would still apply. */
12335 char fpsetmask (void);
12336
12337 int
12338 main (void)
12339 {
12340
12341 /* The GNU C library defines stubs for functions which it implements
12342 to always fail with ENOSYS. Some functions are actually named
12343 something starting with __ and the normal name is an alias. */
12344 #if defined (__stub_fpsetmask) || defined (__stub___fpsetmask)
12345 #error found stub for fpsetmask
12346 #endif
12347
12348 return fpsetmask ();
12349 ;
12350 return 0;
12351 }
12352 _ACEOF
12353 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12354 if { (eval echo "$as_me:12354: \"$ac_link\"") >&5
12355 (eval $ac_link) 2>&5
12356 ac_status=$?
12357 echo "$as_me:12357: \$? = $ac_status" >&5
12358 (exit "$ac_status"); } &&
12359 { ac_try='test -s "conftest$ac_exeext"'
12360 { (eval echo "$as_me:12360: \"$ac_try\"") >&5
12361 (eval $ac_try) 2>&5
12362 ac_status=$?
12363 echo "$as_me:12363: \$? = $ac_status" >&5
12364 (exit "$ac_status"); }; }; then
12365 ac_cv_func_fpsetmask=yes
12366 else
12367 echo "$as_me: failed program was:" >&5
12368 cat "conftest.$ac_ext" >&5
12369 ac_cv_func_fpsetmask=no
12370 fi
12371 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12372 fi
12373 echo "$as_me:12373: result: $ac_cv_func_fpsetmask" >&5
12374 echo "${ECHO_T}$ac_cv_func_fpsetmask" >&6
12375 if test "$ac_cv_func_fpsetmask" = yes; then
12376 cf_have_fpsetmask=1
12377 fi
12378
12379 if test "$cf_have_ieeefp_h" = 1 && test "$cf_have_fpsetmask" = 1 ; then
12380 cat >>confdefs.h <<\EOF
12381 #define FPE_TRAPS_ON 1
12382 EOF
12383
12384 cat >>confdefs.h <<\EOF
12385 #define USE_IEEEFP_H 1
12386 EOF
12387
12388 cat >>confdefs.h <<EOF
12389 #define TURN_ON_FPE_TRAPS fpsetmask(fpgetmask() | (FP_X_DZ|FP_X_OFL))
12390 EOF
12391
12392 cat >>confdefs.h <<EOF
12393 #define TURN_OFF_FPE_TRAPS fpsetmask(fpgetmask() & ~(FP_X_DZ|FP_X_OFL))
12394 EOF
12395
12396 if test "x$cf_cv_use_sv_siginfo" = "xno"
12397 then
12398 echo "$as_me:12398: checking for sigvec" >&5
12399 echo $ECHO_N "checking for sigvec... $ECHO_C" >&6
12400 if test "${ac_cv_func_sigvec+set}" = set; then
12401 echo $ECHO_N "(cached) $ECHO_C" >&6
12402 else
12403 cat >"conftest.$ac_ext" <<_ACEOF
12404 #line 12404 "configure"
12405 #include "confdefs.h"
12406 #define sigvec autoconf_temporary
12407 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12408 #undef sigvec
12409
12410 #ifdef __cplusplus
12411 extern "C"
12412 #endif
12413
12414 /* We use char because int might match the return type of a gcc2
12415 builtin and then its argument prototype would still apply. */
12416 char sigvec (void);
12417
12418 int
12419 main (void)
12420 {
12421
12422 /* The GNU C library defines stubs for functions which it implements
12423 to always fail with ENOSYS. Some functions are actually named
12424 something starting with __ and the normal name is an alias. */
12425 #if defined (__stub_sigvec) || defined (__stub___sigvec)
12426 #error found stub for sigvec
12427 #endif
12428
12429 return sigvec ();
12430 ;
12431 return 0;
12432 }
12433 _ACEOF
12434 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12435 if { (eval echo "$as_me:12435: \"$ac_link\"") >&5
12436 (eval $ac_link) 2>&5
12437 ac_status=$?
12438 echo "$as_me:12438: \$? = $ac_status" >&5
12439 (exit "$ac_status"); } &&
12440 { ac_try='test -s "conftest$ac_exeext"'
12441 { (eval echo "$as_me:12441: \"$ac_try\"") >&5
12442 (eval $ac_try) 2>&5
12443 ac_status=$?
12444 echo "$as_me:12444: \$? = $ac_status" >&5
12445 (exit "$ac_status"); }; }; then
12446 ac_cv_func_sigvec=yes
12447 else
12448 echo "$as_me: failed program was:" >&5
12449 cat "conftest.$ac_ext" >&5
12450 ac_cv_func_sigvec=no
12451 fi
12452 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12453 fi
12454 echo "$as_me:12454: result: $ac_cv_func_sigvec" >&5
12455 echo "${ECHO_T}$ac_cv_func_sigvec" >&6
12456 if test "$ac_cv_func_sigvec" = yes; then
12457 cf_have_sigvec=1
12458 fi
12459
12460 echo "FPE_CHECK 2:get_fpe_codes" >&5
12461 if test "$cf_have_sigvec" = 1 && ./fpe_check$ac_exeext phoney_arg >> defines.out ; then
12462 :
12463 else
12464
12465 cat >>confdefs.h <<\EOF
12466 #define NOINFO_SIGFPE 1
12467 EOF
12468
12469 fi
12470 fi
12471
12472 # look for strtod overflow bug
12473 echo "$as_me:12473: checking strtod bug on overflow" >&5
12474 echo $ECHO_N "checking strtod bug on overflow... $ECHO_C" >&6
12475
12476 rm -f conftest$ac_exeext
12477 CPPFLAGS="$CPPFLAGS -DUSE_IEEEFP_H"
12478
12479 cat >conftest.$ac_ext <<CF_EOF
12480 #include <$cf_FPE_SRCS>
12481 CF_EOF
12482
12483 if { (eval echo "$as_me:12483: \"$ac_link\"") >&5
12484 (eval $ac_link) 2>&5
12485 ac_status=$?
12486 echo "$as_me:12486: \$? = $ac_status" >&5
12487 (exit "$ac_status"); }; then
12488 echo "FPE_CHECK 3:check_strtod_ovf" >&5
12489 if ./conftest phoney_arg phoney_arg 2>/dev/null
12490 then
12491 echo "$as_me:12491: result: no bug" >&5
12492 echo "${ECHO_T}no bug" >&6
12493 else
12494 echo "$as_me:12494: result: buggy -- will use work around" >&5
12495 echo "${ECHO_T}buggy -- will use work around" >&6
12496
12497 cat >>confdefs.h <<EOF
12498 #define HAVE_STRTOD_OVF_BUG 1
12499 EOF
12500
12501 fi
12502 else
12503 echo "$as_me:12503: result: $cf_FPE_SRCS failed to compile" >&5
12504 echo "${ECHO_T}$cf_FPE_SRCS failed to compile" >&6
12505 fi
12506 else
12507 if test $cf_status != 4 ; then
12508 cat >>confdefs.h <<\EOF
12509 #define FPE_TRAPS_ON 1
12510 EOF
12511
12512 if test "x$cf_cv_use_sv_siginfo" = "xno"
12513 then
12514 echo "$as_me:12514: checking for sigvec" >&5
12515 echo $ECHO_N "checking for sigvec... $ECHO_C" >&6
12516 if test "${ac_cv_func_sigvec+set}" = set; then
12517 echo $ECHO_N "(cached) $ECHO_C" >&6
12518 else
12519 cat >"conftest.$ac_ext" <<_ACEOF
12520 #line 12520 "configure"
12521 #include "confdefs.h"
12522 #define sigvec autoconf_temporary
12523 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12524 #undef sigvec
12525
12526 #ifdef __cplusplus
12527 extern "C"
12528 #endif
12529
12530 /* We use char because int might match the return type of a gcc2
12531 builtin and then its argument prototype would still apply. */
12532 char sigvec (void);
12533
12534 int
12535 main (void)
12536 {
12537
12538 /* The GNU C library defines stubs for functions which it implements
12539 to always fail with ENOSYS. Some functions are actually named
12540 something starting with __ and the normal name is an alias. */
12541 #if defined (__stub_sigvec) || defined (__stub___sigvec)
12542 #error found stub for sigvec
12543 #endif
12544
12545 return sigvec ();
12546 ;
12547 return 0;
12548 }
12549 _ACEOF
12550 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12551 if { (eval echo "$as_me:12551: \"$ac_link\"") >&5
12552 (eval $ac_link) 2>&5
12553 ac_status=$?
12554 echo "$as_me:12554: \$? = $ac_status" >&5
12555 (exit "$ac_status"); } &&
12556 { ac_try='test -s "conftest$ac_exeext"'
12557 { (eval echo "$as_me:12557: \"$ac_try\"") >&5
12558 (eval $ac_try) 2>&5
12559 ac_status=$?
12560 echo "$as_me:12560: \$? = $ac_status" >&5
12561 (exit "$ac_status"); }; }; then
12562 ac_cv_func_sigvec=yes
12563 else
12564 echo "$as_me: failed program was:" >&5
12565 cat "conftest.$ac_ext" >&5
12566 ac_cv_func_sigvec=no
12567 fi
12568 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12569 fi
12570 echo "$as_me:12570: result: $ac_cv_func_sigvec" >&5
12571 echo "${ECHO_T}$ac_cv_func_sigvec" >&6
12572 if test "$ac_cv_func_sigvec" = yes; then
12573 cf_have_sigvec=1
12574 fi
12575
12576 echo "FPE_CHECK 2:get_fpe_codes" >&5
12577 if test "$cf_have_sigvec" = 1 && ./fpe_check$ac_exeext phoney_arg >> defines.out ; then
12578 :
12579 else
12580
12581 cat >>confdefs.h <<\EOF
12582 #define NOINFO_SIGFPE 1
12583 EOF
12584
12585 fi
12586 fi
12587 fi
12588
12589 case $cf_status in
12590 (1)
12591 cat 1>&2 <<-'EOF'
12592 Warning: Your system defaults generate floating point exception
12593 on divide by zero but not on overflow. You need to
12594 #define TURN_ON_FPE_TRAPS to handle overflow.
12595 EOF
12596 ;;
12597 (2)
12598 cat 1>&2 <<-'EOF'
12599 Warning: Your system defaults generate floating point exception
12600 on overflow but not on divide by zero. You need to
12601 #define TURN_ON_FPE_TRAPS to handle divide by zero.
12602 EOF
12603 ;;
12604 (4)
12605 cat 1>&2 <<-'EOF'
12606 Warning: Your system defaults do not generate floating point
12607 exceptions, but your math library does not support this behavior.
12608 You need to
12609 #define TURN_ON_FPE_TRAPS to use fp exceptions for consistency.
12610 EOF
12611 ;;
12612 esac
12613 cat 1>&2 <<-'EOF'
12614 Please report this so I can fix this script to do it automatically.
12615 [email protected]
12616 You can continue with the build and the resulting mawk will be
12617 usable, but getting FPE_TRAPS_ON correct eventually is best.
12618 EOF
12619 fi
12620 ;;
12621
12622 (*) # some sort of disaster
12623 if test "x$cross_compiling" = xno
12624 then
12625 cat 1>&2 <<-EOF
12626 The program \`fpe_check' compiled from $cf_FPE_SRCS seems to have
12627 unexpectly blown up. Please report this to [email protected]
12628 EOF
12629 # quit or not ???
12630 else
12631 cat 1>&2 <<-EOF
12632 The program \`fpe_check' will not work for cross-compiling.
12633 You can continue with the build and the resulting mawk will be
12634 usable, but getting FPE_TRAPS_ON correct eventually is best.
12635 EOF
12636 fi
12637 ;;
12638 esac
12639
12640 CPPFLAGS="$cf_FPE_DEFS"
12641 LIBS="$cf_FPE_LIBS"
12642
12643 rm -f conftest.$ac_ext fpe_check$ac_exeext # whew!!
12644
12645 ac_config_files="$ac_config_files Makefile man/Makefile"
12646
12647 cat >confcache <<\_ACEOF
12648 # This file is a shell script that caches the results of configure
12649 # tests run on this system so they can be shared between configure
12650 # scripts and configure runs, see configure's option --config-cache.
12651 # It is not useful on other systems. If it contains results you don't
12652 # want to keep, you may remove or edit it.
12653 #
12654 # config.status only pays attention to the cache file if you give it
12655 # the --recheck option to rerun configure.
12656 #
12657 # `ac_cv_env_foo' variables (set or unset) will be overridden when
12658 # loading this file, other *unset* `ac_cv_foo' will be assigned the
12659 # following values.
12660
12661 _ACEOF
12662
12663 # The following way of writing the cache mishandles newlines in values,
12664 # but we know of no workaround that is simple, portable, and efficient.
12665 # So, don't put newlines in cache variables' values.
12666 # Ultrix sh set writes to stderr and can't be redirected directly,
12667 # and sets the high bit in the cache file unless we assign to the vars.
12668 {
12669 (set) 2>&1 |
12670 case `(ac_space=' '; set | grep ac_space) 2>&1` in
12671 *ac_space=\ *)
12672 # `set' does not quote correctly, so add quotes (double-quote
12673 # substitution turns \\\\ into \\, and sed turns \\ into \).
12674 sed -n \
12675 "s/'/'\\\\''/g;
12676 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
12677 ;;
12678 *)
12679 # `set' quotes correctly as required by POSIX, so do not add quotes.
12680 sed -n \
12681 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
12682 ;;
12683 esac;
12684 } |
12685 sed '
12686 t clear
12687 : clear
12688 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
12689 t end
12690 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
12691 : end' >>confcache
12692 if cmp -s $cache_file confcache; then :; else
12693 if test -w $cache_file; then
12694 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
12695 cat confcache >$cache_file
12696 else
12697 echo "not updating unwritable cache $cache_file"
12698 fi
12699 fi
12700 rm -f confcache
12701
12702 test "x$prefix" = xNONE && prefix=$ac_default_prefix
12703 # Let make expand exec_prefix.
12704 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
12705
12706 # VPATH may cause trouble with some makes, so we remove $(srcdir),
12707 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
12708 # trailing colons and then remove the whole line if VPATH becomes empty
12709 # (actually we leave an empty line to preserve line numbers).
12710 if test "x$srcdir" = x.; then
12711 ac_vpsub='/^[ ]*VPATH[ ]*=/{
12712 s/:*\$(srcdir):*/:/;
12713 s/:*\${srcdir}:*/:/;
12714 s/:*@srcdir@:*/:/;
12715 s/^\([^=]*=[ ]*\):*/\1/;
12716 s/:*$//;
12717 s/^[^=]*=[ ]*$//;
12718 }'
12719 fi
12720
12721 DEFS=-DHAVE_CONFIG_H
12722
12723 : "${CONFIG_STATUS=./config.status}"
12724 ac_clean_files_save=$ac_clean_files
12725 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
12726 { echo "$as_me:12726: creating $CONFIG_STATUS" >&5
12727 echo "$as_me: creating $CONFIG_STATUS" >&6;}
12728 cat >"$CONFIG_STATUS" <<_ACEOF
12729 #! $SHELL
12730 # Generated automatically by configure.
12731 # Run this file to recreate the current configuration.
12732 # Compiler output produced by configure, useful for debugging
12733 # configure, is in config.log if it exists.
12734
12735 me=\`echo "\$0" | sed -e 's,.*\\/,,'\`
12736
12737 debug=false
12738 SHELL=\${CONFIG_SHELL-$SHELL}
12739 ac_cs_invocation="\$0 \$@"
12740
12741 CLICOLOR_FORCE= GREP_OPTIONS=
12742 unset CLICOLOR_FORCE GREP_OPTIONS
12743 _ACEOF
12744
12745 cat >>"$CONFIG_STATUS" <<\_ACEOF
12746 # Be Bourne compatible
12747 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
12748 emulate sh
12749 NULLCMD=:
12750 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
12751 set -o posix
12752 fi
12753
12754 # Name of the executable.
12755 as_me=`echo "$0" |sed 's,.*[\\/],,'`
12756
12757 if expr a : '\(a\)' >/dev/null 2>&1; then
12758 as_expr="expr"
12759 else
12760 as_expr="false"
12761 fi
12762
12763 rm -f conf$$ conf$$.exe conf$$.file
12764 echo >conf$$.file
12765 if ln -s conf$$.file conf$$ 2>/dev/null; then
12766 # We could just check for DJGPP; but this test a) works b) is more generic
12767 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
12768 if test -f conf$$.exe; then
12769 # Don't use ln at all; we don't have any links
12770 as_ln_s='cp -p'
12771 else
12772 as_ln_s='ln -s'
12773 fi
12774 elif ln conf$$.file conf$$ 2>/dev/null; then
12775 as_ln_s='ln'
12776 else
12777 as_ln_s='cp -p'
12778 fi
12779 rm -f conf$$ conf$$.exe conf$$.file
12780
12781 as_executable_p="test -f"
12782
12783 # Support unset when possible.
12784 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
12785 as_unset="unset"
12786 else
12787 as_unset="false"
12788 fi
12789
12790 # NLS nuisances.
12791 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
12792 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
12793 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
12794 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
12795 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
12796 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
12797 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
12798 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
12799
12800 # IFS
12801 # We need space, tab and new line, in precisely that order.
12802 as_nl='
12803 '
12804 IFS=" $as_nl"
12805
12806 # CDPATH.
12807 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
12808
12809 exec 6>&1
12810
12811 _ACEOF
12812
12813 # Files that config.status was made for.
12814 if test -n "$ac_config_files"; then
12815 echo "config_files=\"$ac_config_files\"" >>"$CONFIG_STATUS"
12816 fi
12817
12818 if test -n "$ac_config_headers"; then
12819 echo "config_headers=\"$ac_config_headers\"" >>"$CONFIG_STATUS"
12820 fi
12821
12822 if test -n "$ac_config_links"; then
12823 echo "config_links=\"$ac_config_links\"" >>"$CONFIG_STATUS"
12824 fi
12825
12826 if test -n "$ac_config_commands"; then
12827 echo "config_commands=\"$ac_config_commands\"" >>"$CONFIG_STATUS"
12828 fi
12829
12830 cat >>"$CONFIG_STATUS" <<\EOF
12831
12832 ac_cs_usage="\
12833 \`$as_me' instantiates files from templates according to the
12834 current configuration.
12835
12836 Usage: $0 [OPTIONS] [FILE]...
12837
12838 -h, --help print this help, then exit
12839 -V, --version print version number, then exit
12840 -d, --debug don't remove temporary files
12841 --recheck update $as_me by reconfiguring in the same conditions
12842 --file=FILE[:TEMPLATE]
12843 instantiate the configuration file FILE
12844 --header=FILE[:TEMPLATE]
12845 instantiate the configuration header FILE
12846
12847 Configuration files:
12848 $config_files
12849
12850 Configuration headers:
12851 $config_headers
12852
12853 Report bugs to <[email protected]>."
12854 EOF
12855
12856 cat >>"$CONFIG_STATUS" <<EOF
12857 ac_cs_version="\\
12858 config.status
12859 configured by $0, generated by GNU Autoconf 2.52.20250126,
12860 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
12861
12862 Copyright 2003-2022,2023 Thomas E. Dickey
12863 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
12864 Free Software Foundation, Inc.
12865 This config.status script is free software; the Free Software Foundation
12866 gives unlimited permission to copy, distribute and modify it."
12867 srcdir="$srcdir"
12868 INSTALL="$INSTALL"
12869 EOF
12870
12871 cat >>"$CONFIG_STATUS" <<\EOF
12872 # If no file are specified by the user, then we need to provide default
12873 # value. By we need to know if files were specified by the user.
12874 ac_need_defaults=:
12875 while test $# != 0
12876 do
12877 case $1 in
12878 --*=*)
12879 ac_option=`expr "x$1" : 'x\([^=]*\)='`
12880 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
12881 shift
12882 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
12883 shift
12884 ;;
12885 -*);;
12886 *) # This is not an option, so the user has probably given explicit
12887 # arguments.
12888 ac_need_defaults=false;;
12889 esac
12890
12891 case $1 in
12892 # Handling of the options.
12893 EOF
12894 cat >>"$CONFIG_STATUS" <<EOF
12895 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
12896 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
12897 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
12898 EOF
12899 cat >>"$CONFIG_STATUS" <<\EOF
12900 --version | --vers* | -V )
12901 echo "$ac_cs_version"; exit 0 ;;
12902 --he | --h)
12903 # Conflict between --help and --header
12904 { { echo "$as_me:12904: error: ambiguous option: $1
12905 Try \`$0 --help' for more information." >&5
12906 echo "$as_me: error: ambiguous option: $1
12907 Try \`$0 --help' for more information." >&2;}
12908 { (exit 1); exit 1; }; };;
12909 --help | --hel | -h )
12910 echo "$ac_cs_usage"; exit 0 ;;
12911 --debug | --d* | -d )
12912 debug=: ;;
12913 --file | --fil | --fi | --f )
12914 shift
12915 CONFIG_FILES="$CONFIG_FILES $1"
12916 ac_need_defaults=false;;
12917 --header | --heade | --head | --hea )
12918 shift
12919 CONFIG_HEADERS="$CONFIG_HEADERS $1"
12920 ac_need_defaults=false;;
12921
12922 # This is an error.
12923 -*) { { echo "$as_me:12923: error: unrecognized option: $1
12924 Try \`$0 --help' for more information." >&5
12925 echo "$as_me: error: unrecognized option: $1
12926 Try \`$0 --help' for more information." >&2;}
12927 { (exit 1); exit 1; }; } ;;
12928
12929 *) ac_config_targets="$ac_config_targets $1" ;;
12930
12931 esac
12932 shift
12933 done
12934
12935 exec 5>>config.log
12936 cat >&5 << _ACEOF
12937
12938 ## ----------------------- ##
12939 ## Running config.status. ##
12940 ## ----------------------- ##
12941
12942 This file was extended by $as_me 2.52.20250126, executed with
12943 CONFIG_FILES = $CONFIG_FILES
12944 CONFIG_HEADERS = $CONFIG_HEADERS
12945 CONFIG_LINKS = $CONFIG_LINKS
12946 CONFIG_COMMANDS = $CONFIG_COMMANDS
12947 > "$ac_cs_invocation"
12948 on `(hostname || uname -n) 2>/dev/null | sed 1q`
12949
12950 _ACEOF
12951 EOF
12952
12953 cat >>"$CONFIG_STATUS" <<\EOF
12954 for ac_config_target in $ac_config_targets
12955 do
12956 case "$ac_config_target" in
12957 # Handling of arguments.
12958 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
12959 "man/Makefile" ) CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
12960 "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h:config_h.in" ;;
12961 *) { { echo "$as_me:12961: error: invalid argument: $ac_config_target" >&5
12962 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
12963 { (exit 1); exit 1; }; };;
12964 esac
12965 done
12966
12967 # If the user did not use the arguments to specify the items to instantiate,
12968 # then the envvar interface is used. Set only those that are not.
12969 # We use the long form for the default assignment because of an extremely
12970 # bizarre bug on SunOS 4.1.3.
12971 if "$ac_need_defaults"; then
12972 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
12973 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
12974 fi
12975
12976 # Create a temporary directory, and hook for its removal unless debugging.
12977 $debug ||
12978 {
12979 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
12980 trap '{ (exit 1); exit 1; }' 1 2 13 15
12981 }
12982
12983 # Create a (secure) tmp directory for tmp files.
12984 : "${TMPDIR=/tmp}"
12985 {
12986 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
12987 test -n "$tmp" && test -d "$tmp"
12988 } ||
12989 {
12990 tmp=$TMPDIR/cs$$-$RANDOM
12991 (umask 077 && mkdir "$tmp")
12992 } ||
12993 {
12994 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
12995 { (exit 1); exit 1; }
12996 }
12997
12998 EOF
12999
13000 cat >>"$CONFIG_STATUS" <<EOF
13001
13002 #
13003 # CONFIG_FILES section.
13004 #
13005
13006 # No need to generate the scripts if there are no CONFIG_FILES.
13007 # This happens for instance when ./config.status config.h
13008 if test -n "\$CONFIG_FILES"; then
13009 # Protect against being on the right side of a sed subst in config.status.
13010 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
13011 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >"\$tmp"/subs.sed <<\\CEOF
13012 s,@SHELL@,$SHELL,;t t
13013 s,@exec_prefix@,$exec_prefix,;t t
13014 s,@prefix@,$prefix,;t t
13015 s,@program_transform_name@,$program_transform_name,;t t
13016 s,@bindir@,$bindir,;t t
13017 s,@sbindir@,$sbindir,;t t
13018 s,@libexecdir@,$libexecdir,;t t
13019 s,@datarootdir@,$datarootdir,;t t
13020 s,@datadir@,$datadir,;t t
13021 s,@sysconfdir@,$sysconfdir,;t t
13022 s,@sharedstatedir@,$sharedstatedir,;t t
13023 s,@localstatedir@,$localstatedir,;t t
13024 s,@runstatedir@,$runstatedir,;t t
13025 s,@libdir@,$libdir,;t t
13026 s,@includedir@,$includedir,;t t
13027 s,@oldincludedir@,$oldincludedir,;t t
13028 s,@infodir@,$infodir,;t t
13029 s,@mandir@,$mandir,;t t
13030 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
13031 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
13032 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
13033 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
13034 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
13035 s,@build_alias@,$build_alias,;t t
13036 s,@host_alias@,$host_alias,;t t
13037 s,@target_alias@,$target_alias,;t t
13038 s,@ECHO_C@,$ECHO_C,;t t
13039 s,@ECHO_N@,$ECHO_N,;t t
13040 s,@ECHO_T@,$ECHO_T,;t t
13041 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
13042 s,@DEFS@,$DEFS,;t t
13043 s,@LIBS@,$LIBS,;t t
13044 s,@build@,$build,;t t
13045 s,@build_cpu@,$build_cpu,;t t
13046 s,@build_vendor@,$build_vendor,;t t
13047 s,@build_os@,$build_os,;t t
13048 s,@host@,$host,;t t
13049 s,@host_cpu@,$host_cpu,;t t
13050 s,@host_vendor@,$host_vendor,;t t
13051 s,@host_os@,$host_os,;t t
13052 s,@CC@,$CC,;t t
13053 s,@CFLAGS@,$CFLAGS,;t t
13054 s,@LDFLAGS@,$LDFLAGS,;t t
13055 s,@CPPFLAGS@,$CPPFLAGS,;t t
13056 s,@ac_ct_CC@,$ac_ct_CC,;t t
13057 s,@EXEEXT@,$EXEEXT,;t t
13058 s,@OBJEXT@,$OBJEXT,;t t
13059 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
13060 s,@SET_MAKE@,$SET_MAKE,;t t
13061 s,@GREP@,$GREP,;t t
13062 s,@FGREP@,$FGREP,;t t
13063 s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t
13064 s,@MAKE_NO_PHONY@,$MAKE_NO_PHONY,;t t
13065 s,@MAKE_PHONY@,$MAKE_PHONY,;t t
13066 s,@CPP@,$CPP,;t t
13067 s,@EGREP@,$EGREP,;t t
13068 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
13069 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
13070 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
13071 s,@YACC@,$YACC,;t t
13072 s,@LINT@,$LINT,;t t
13073 s,@LINT_OPTS@,$LINT_OPTS,;t t
13074 s,@LINT_LIBS@,$LINT_LIBS,;t t
13075 s,@CTAGS@,$CTAGS,;t t
13076 s,@ETAGS@,$ETAGS,;t t
13077 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
13078 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
13079 s,@BUILD_CC@,$BUILD_CC,;t t
13080 s,@BUILD_CPP@,$BUILD_CPP,;t t
13081 s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
13082 s,@BUILD_CPPFLAGS@,$BUILD_CPPFLAGS,;t t
13083 s,@BUILD_LDFLAGS@,$BUILD_LDFLAGS,;t t
13084 s,@BUILD_LIBS@,$BUILD_LIBS,;t t
13085 s,@BUILD_EXEEXT@,$BUILD_EXEEXT,;t t
13086 s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t
13087 s,@MATHLIB@,$MATHLIB,;t t
13088 s,@ECHO_LT@,$ECHO_LT,;t t
13089 s,@ECHO_LD@,$ECHO_LD,;t t
13090 s,@RULE_CC@,$RULE_CC,;t t
13091 s,@SHOW_CC@,$SHOW_CC,;t t
13092 s,@ECHO_CC@,$ECHO_CC,;t t
13093 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
13094 s,@HAVE_STDNORETURN_H@,$HAVE_STDNORETURN_H,;t t
13095 s,@STDC_NORETURN@,$STDC_NORETURN,;t t
13096 s,@GROFF_PATH@,$GROFF_PATH,;t t
13097 s,@NROFF_PATH@,$NROFF_PATH,;t t
13098 s,@TBL_PATH@,$TBL_PATH,;t t
13099 s,@GROFF_NOTE@,$GROFF_NOTE,;t t
13100 s,@NROFF_NOTE@,$NROFF_NOTE,;t t
13101 s,@cf_man2html@,$cf_man2html,;t t
13102 s,@target@,$target,;t t
13103 s,@target_cpu@,$target_cpu,;t t
13104 s,@target_vendor@,$target_vendor,;t t
13105 s,@target_os@,$target_os,;t t
13106 s,@GLOB_FULLPATH_POSIX@,$GLOB_FULLPATH_POSIX,;t t
13107 s,@GLOB_FULLPATH_OTHER@,$GLOB_FULLPATH_OTHER,;t t
13108 s,@MAN2HTML_NOTE@,$MAN2HTML_NOTE,;t t
13109 s,@MAN2HTML_PATH@,$MAN2HTML_PATH,;t t
13110 s,@MAN2HTML_TEMP@,$MAN2HTML_TEMP,;t t
13111 s,@EXTRAOBJS@,$EXTRAOBJS,;t t
13112 CEOF
13113
13114 EOF
13115
13116 cat >>"$CONFIG_STATUS" <<\EOF
13117 # Split the substitutions into bite-sized pieces for seds with
13118 # small command number limits, like on Digital OSF/1 and HP-UX.
13119 ac_max_sed_lines=48
13120 ac_sed_frag=1 # Number of current file.
13121 ac_beg=1 # First line for current file.
13122 ac_end=$ac_max_sed_lines # Line after last line for current file.
13123 ac_more_lines=:
13124 ac_sed_cmds=
13125 while "$ac_more_lines"; do
13126 if test "$ac_beg" -gt 1; then
13127 sed "1,${ac_beg}d; ${ac_end}q" "$tmp"/subs.sed >"$tmp"/subs.frag
13128 else
13129 sed "${ac_end}q" "$tmp"/subs.sed >"$tmp"/subs.frag
13130 fi
13131 if test ! -s "$tmp"/subs.frag; then
13132 ac_more_lines=false
13133 else
13134 # The purpose of the label and of the branching condition is to
13135 # speed up the sed processing (if there are no `@' at all, there
13136 # is no need to browse any of the substitutions).
13137 # These are the two extra sed commands mentioned above.
13138 (echo ':t
13139 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && sed -e 's/\\\\*$//g' -e 's/$/\\/' -e 's/;t t\\/;t t/' -e 't' -e '3,'$ac_max_sed_lines's/$/\\/' "$tmp"/subs.frag) >"$tmp"/subs-$ac_sed_frag.sed
13140 # It is possible to make a multiline substitution using escaped newlines.
13141 # Ensure that we do not split the substitution between script fragments.
13142 ac_BEG=$ac_end
13143 ac_END=`expr "$ac_end" + "$ac_max_sed_lines"`
13144 sed "1,${ac_BEG}d; ${ac_END}p; q" "$tmp"/subs.sed >"$tmp"/subs.next
13145 if test -s "$tmp"/subs.next; then
13146 grep '^s,@[^@,][^@,]*@,.*$' "$tmp"/subs.next | grep -v '^s,@.*;t t$' >"$tmp"/subs.edit
13147 if test ! -s "$tmp"/subs.edit; then
13148 grep "^s,@[^@,][^@,]*@,.*,;t t$" "$tmp"/subs.next >"$tmp"/subs.edit
13149 if test ! -s "$tmp"/subs.edit; then
13150 if test "$ac_beg" -gt 1; then
13151 ac_end=`expr "$ac_end" - 1`
13152 continue
13153 fi
13154 fi
13155 fi
13156 fi
13157
13158 if test -z "$ac_sed_cmds"; then
13159 ac_sed_cmds="sed -f \"$tmp\"/subs-$ac_sed_frag.sed"
13160 else
13161 ac_sed_cmds="$ac_sed_cmds | sed -f \"$tmp\"/subs-$ac_sed_frag.sed"
13162 fi
13163 ac_sed_frag=`expr "$ac_sed_frag" + 1`
13164 ac_beg=$ac_end
13165 ac_end=`expr "$ac_end" + "$ac_max_sed_lines"`
13166 fi
13167 done
13168 if test -z "$ac_sed_cmds"; then
13169 ac_sed_cmds="cat"
13170 fi
13171 fi # test -n "$CONFIG_FILES"
13172
13173 EOF
13174 cat >>"$CONFIG_STATUS" <<\EOF
13175 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
13176 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
13177 case "$ac_file" in
13178 - | *:- | *:-:* ) # input from stdin
13179 cat >"$tmp"/stdin
13180 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
13181 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
13182 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
13183 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
13184 * ) ac_file_in=$ac_file.in ;;
13185 esac
13186
13187 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
13188 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
13189 X"$ac_file" : 'X\(//\)[^/]' \| \
13190 X"$ac_file" : 'X\(//\)$' \| \
13191 X"$ac_file" : 'X\(/\)' \| \
13192 . : '\(.\)' 2>/dev/null ||
13193 echo X"$ac_file" |
13194 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
13195 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
13196 /^X\(\/\/\)$/{ s//\1/; q; }
13197 /^X\(\/\).*/{ s//\1/; q; }
13198 s/.*/./; q'`
13199 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
13200 { case "$ac_dir" in
13201 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
13202 *) as_incr_dir=.;;
13203 esac
13204 as_dummy="$ac_dir"
13205 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
13206 case $as_mkdir_dir in
13207 # Skip DOS drivespec
13208 ?:) as_incr_dir=$as_mkdir_dir ;;
13209 *)
13210 as_incr_dir=$as_incr_dir/$as_mkdir_dir
13211 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
13212 ;;
13213 esac
13214 done; }
13215
13216 ac_dir_suffix="/`echo "$ac_dir"|sed 's,^\./,,'`"
13217 # A "../" for each directory in $ac_dir_suffix.
13218 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
13219 else
13220 ac_dir_suffix= ac_dots=
13221 fi
13222
13223 case "$srcdir" in
13224 .) ac_srcdir=.
13225 if test -z "$ac_dots"; then
13226 ac_top_srcdir=.
13227 else
13228 ac_top_srcdir=`echo "$ac_dots" | sed 's,/$,,'`
13229 fi ;;
13230 [\\/]* | ?:[\\/]* )
13231 ac_srcdir="$srcdir$ac_dir_suffix";
13232 ac_top_srcdir="$srcdir" ;;
13233 *) # Relative path.
13234 ac_srcdir="$ac_dots$srcdir$ac_dir_suffix"
13235 ac_top_srcdir="$ac_dots$srcdir" ;;
13236 esac
13237
13238 case $INSTALL in
13239 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
13240 *) ac_INSTALL=$ac_dots$INSTALL ;;
13241 esac
13242
13243 if test x"$ac_file" != x-; then
13244 { echo "$as_me:13244: creating $ac_file" >&5
13245 echo "$as_me: creating $ac_file" >&6;}
13246 rm -f "$ac_file"
13247 fi
13248 # Let's still pretend it is `configure' which instantiates (i.e., don't
13249 # use $as_me), people would be surprised to read:
13250 # /* config.h. Generated automatically by config.status. */
13251 configure_input="Generated automatically from `echo $ac_file_in |
13252 sed 's,.*/,,'` by configure."
13253
13254 # First look for the input files in the build tree, otherwise in the
13255 # src tree.
13256 ac_file_inputs=`IFS=:
13257 for f in $ac_file_in; do
13258 case $f in
13259 -) echo "$tmp"/stdin ;;
13260 [\\/$]*)
13261 # Absolute (can't be DOS-style, as IFS=:)
13262 test -f "$f" || { { echo "$as_me:13262: error: cannot find input file: $f" >&5
13263 echo "$as_me: error: cannot find input file: $f" >&2;}
13264 { (exit 1); exit 1; }; }
13265 echo "$f";;
13266 *) # Relative
13267 if test -f "$f"; then
13268 # Build tree
13269 echo "$f"
13270 elif test -f "$srcdir/$f"; then
13271 # Source tree
13272 echo "$srcdir/$f"
13273 else
13274 # /dev/null tree
13275 { { echo "$as_me:13275: error: cannot find input file: $f" >&5
13276 echo "$as_me: error: cannot find input file: $f" >&2;}
13277 { (exit 1); exit 1; }; }
13278 fi;;
13279 esac
13280 done` || { (exit 1); exit 1; }
13281 EOF
13282 cat >>"$CONFIG_STATUS" <<\EOF
13283 ac_warn_datarootdir=no
13284 if test x"$ac_file" != x-; then
13285 for ac_item in $ac_file_inputs
13286 do
13287 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' "$ac_item"`
13288 if test -n "$ac_seen"; then
13289 ac_used=`grep '@datarootdir@' "$ac_item"`
13290 if test -z "$ac_used"; then
13291 { echo "$as_me:13291: WARNING: datarootdir was used implicitly but not set:
13292 $ac_seen" >&5
13293 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
13294 $ac_seen" >&2;}
13295 ac_warn_datarootdir=yes
13296 fi
13297 fi
13298 ac_seen=`grep '${datarootdir}' "$ac_item"`
13299 if test -n "$ac_seen"; then
13300 { echo "$as_me:13300: WARNING: datarootdir was used explicitly but not set:
13301 $ac_seen" >&5
13302 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
13303 $ac_seen" >&2;}
13304 ac_warn_datarootdir=yes
13305 fi
13306 done
13307 fi
13308
13309 if test "x$ac_warn_datarootdir" = xyes; then
13310 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
13311 fi
13312
13313 EOF
13314 cat >>"$CONFIG_STATUS" <<EOF
13315 sed "$ac_vpsub
13316 $extrasub
13317 EOF
13318 cat >>"$CONFIG_STATUS" <<\EOF
13319 :t
13320 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
13321 s,@configure_input@,$configure_input,;t t
13322 s,@srcdir@,$ac_srcdir,;t t
13323 s,@top_srcdir@,$ac_top_srcdir,;t t
13324 s,@INSTALL@,$ac_INSTALL,;t t
13325 " $ac_file_inputs | (eval "$ac_sed_cmds") >"$tmp"/out
13326 rm -f "$tmp"/stdin
13327 EOF
13328 test -n "${FGREP}" || FGREP="grep -F"
13329 test -n "${EGREP}" || EGREP="grep -E"
13330 cat >>"$CONFIG_STATUS" <<EOF
13331 test -n "\${FGREP}" || FGREP="$FGREP"
13332 test -n "\${EGREP}" || EGREP="$EGREP"
13333 EOF
13334 cat >>"$CONFIG_STATUS" <<\EOF
13335 if test x"$ac_file" != x-; then
13336 cp "$tmp/out" "$ac_file"
13337
13338 for ac_name in prefix exec_prefix datarootdir
13339 do
13340 ac_seen=`$FGREP -n '${'$ac_name'[:=].*}' "$ac_file"`
13341 if test -n "$ac_seen"; then
13342 ac_init=`$EGREP '[ ]*'$ac_name'[ ]*=' "$ac_file"`
13343 if test -z "$ac_init"; then
13344 ac_seen=`echo "$ac_seen" |sed -e 's,^,'"$ac_file"':,'`
13345 { echo "$as_me:13345: WARNING: Variable $ac_name is used but was not set:
13346 $ac_seen" >&5
13347 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
13348 $ac_seen" >&2;}
13349 fi
13350 fi
13351 done
13352 $EGREP -n '@[a-z_][a-z_0-9]+@' "$ac_file" >"$tmp"/out
13353 $EGREP -n '@[A-Z_][A-Z_0-9]+@' "$ac_file" >>"$tmp"/out
13354 if test -s "$tmp"/out; then
13355 ac_seen=`sed -e 's,^,'"$ac_file"':,' < "$tmp"/out`
13356 { echo "$as_me:13356: WARNING: Some variables may not be substituted:
13357 $ac_seen" >&5
13358 echo "$as_me: WARNING: Some variables may not be substituted:
13359 $ac_seen" >&2;}
13360 fi
13361 else
13362 cat "$tmp"/out
13363 fi
13364 rm -f "$tmp"/out
13365
13366 done
13367 EOF
13368 cat >>"$CONFIG_STATUS" <<\EOF
13369
13370 #
13371 # CONFIG_HEADER section.
13372 #
13373
13374 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
13375 # NAME is the cpp macro being defined and VALUE is the value it is being given.
13376 #
13377 # ac_d sets the value in "#define NAME VALUE" lines.
13378 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
13379 ac_dB='[ ].*$,\1#\2'
13380 ac_dC=' '
13381 ac_dD=',;t'
13382 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
13383 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
13384 ac_iB='\([ ]\),\1#\2define\3'
13385 ac_iC=' '
13386 ac_iD='\4,;t'
13387 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
13388 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
13389 ac_uB='$,\1#\2define\3'
13390 ac_uC=' '
13391 ac_uD=',;t'
13392
13393 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
13394 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
13395 case "$ac_file" in
13396 - | *:- | *:-:* ) # input from stdin
13397 cat >"$tmp"/stdin
13398 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
13399 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
13400 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
13401 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
13402 * ) ac_file_in=$ac_file.in ;;
13403 esac
13404
13405 test x"$ac_file" != x- && { echo "$as_me:13405: creating $ac_file" >&5
13406 echo "$as_me: creating $ac_file" >&6;}
13407
13408 # First look for the input files in the build tree, otherwise in the
13409 # src tree.
13410 ac_file_inputs=`IFS=:
13411 for f in $ac_file_in; do
13412 case $f in
13413 -) echo "$tmp"/stdin ;;
13414 [\\/$]*)
13415 # Absolute (can't be DOS-style, as IFS=:)
13416 test -f "$f" || { { echo "$as_me:13416: error: cannot find input file: $f" >&5
13417 echo "$as_me: error: cannot find input file: $f" >&2;}
13418 { (exit 1); exit 1; }; }
13419 echo $f;;
13420 *) # Relative
13421 if test -f "$f"; then
13422 # Build tree
13423 echo $f
13424 elif test -f "$srcdir/$f"; then
13425 # Source tree
13426 echo "$srcdir/$f"
13427 else
13428 # /dev/null tree
13429 { { echo "$as_me:13429: error: cannot find input file: $f" >&5
13430 echo "$as_me: error: cannot find input file: $f" >&2;}
13431 { (exit 1); exit 1; }; }
13432 fi;;
13433 esac
13434 done` || { (exit 1); exit 1; }
13435 # Remove the trailing spaces.
13436 sed 's/[ ]*$//' $ac_file_inputs >"$tmp"/in
13437
13438 EOF
13439
13440 # Transform confdefs.h into two sed scripts, `conftest.defines' and
13441 # `conftest.undefs', that substitutes the proper values into
13442 # config.h.in to produce config.h. The first handles `#define'
13443 # templates, and the second `#undef' templates.
13444 # And first: Protect against being on the right side of a sed subst in
13445 # config.status. Protect against being in an unquoted here document
13446 # in config.status.
13447 rm -f conftest.defines conftest.undefs
13448 # Using a here document instead of a string reduces the quoting nightmare.
13449 # Putting comments in sed scripts is not portable.
13450 #
13451 # `end' is used to avoid that the second main sed command (meant for
13452 # 0-ary CPP macros) applies to n-ary macro definitions.
13453 # See the Autoconf documentation for `clear'.
13454 cat >confdef2sed.sed <<\EOF
13455 s/[\\&,]/\\&/g
13456 s,[\\$`],\\&,g
13457 t clear
13458 : clear
13459 s,^[ ]*#[ ]*define[ ][ ]*\(\([^ (][^ (]*\)([^)]*)\)[ ]*\(.*\)$,${ac_dA}\2${ac_dB}\1${ac_dC}\3${ac_dD},gp
13460 t end
13461 s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
13462 : end
13463 EOF
13464 # If some macros were called several times there might be several times
13465 # the same #defines, which is useless. Nevertheless, we may not want to
13466 # sort them, since we want the *last* AC-DEFINE to be honored.
13467 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
13468 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
13469 sed 's/ac_d/ac_i/g' conftest.defines >>conftest.undefs
13470 rm -f confdef2sed.sed
13471
13472 # This sed command replaces #undef with comments. This is necessary, for
13473 # example, in the case of _POSIX_SOURCE, which is predefined and required
13474 # on some systems where configure will not decide to define it.
13475 cat >>conftest.undefs <<\EOF
13476 s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
13477 EOF
13478
13479 # Break up conftest.defines because some shells have a limit on the size
13480 # of here documents, and old seds have small limits too (100 cmds).
13481 echo ' # Handle all the #define templates only if necessary.' >>"$CONFIG_STATUS"
13482 echo ' test -n "${EGREP}" || EGREP="grep -E"' >>"$CONFIG_STATUS"
13483 echo ' if ${EGREP} "^[ ]*#[ ]*define" "$tmp"/in >/dev/null; then' >>"$CONFIG_STATUS"
13484 echo ' # If there are no defines, we may have an empty if/fi' >>"$CONFIG_STATUS"
13485 echo ' :' >>"$CONFIG_STATUS"
13486 rm -f conftest.tail
13487 while grep . conftest.defines >/dev/null
13488 do
13489 # Write a limited-size here document to "$tmp"/defines.sed.
13490 echo ' cat >"$tmp"/defines.sed <<CEOF' >>"$CONFIG_STATUS"
13491 # Speed up: don't consider the non `#define' lines.
13492 echo '/^[ ]*#[ ]*define/!b' >>"$CONFIG_STATUS"
13493 # Work around the forget-to-reset-the-flag bug.
13494 echo 't clr' >>"$CONFIG_STATUS"
13495 echo ': clr' >>"$CONFIG_STATUS"
13496 sed "${ac_max_here_lines}q" conftest.defines >>"$CONFIG_STATUS"
13497 echo 'CEOF
13498 sed -f "$tmp"/defines.sed "$tmp"/in >"$tmp"/out
13499 rm -f "$tmp"/in
13500 mv "$tmp"/out "$tmp"/in
13501 ' >>"$CONFIG_STATUS"
13502 sed "1,${ac_max_here_lines}d" conftest.defines >conftest.tail
13503 rm -f conftest.defines
13504 mv conftest.tail conftest.defines
13505 done
13506 rm -f conftest.defines
13507 echo ' fi # grep' >>"$CONFIG_STATUS"
13508 echo >>"$CONFIG_STATUS"
13509
13510 # Break up conftest.undefs because some shells have a limit on the size
13511 # of here documents, and old seds have small limits too (100 cmds).
13512 echo ' # Handle all the #undef templates' >>"$CONFIG_STATUS"
13513 rm -f conftest.tail
13514 while grep . conftest.undefs >/dev/null
13515 do
13516 # Write a limited-size here document to "$tmp"/undefs.sed.
13517 echo ' cat >"$tmp"/undefs.sed <<CEOF' >>"$CONFIG_STATUS"
13518 # Speed up: don't consider the non `#undef'
13519 echo '/^[ ]*#[ ]*undef/!b' >>"$CONFIG_STATUS"
13520 # Work around the forget-to-reset-the-flag bug.
13521 echo 't clr' >>"$CONFIG_STATUS"
13522 echo ': clr' >>"$CONFIG_STATUS"
13523 sed "${ac_max_here_lines}q" conftest.undefs >>"$CONFIG_STATUS"
13524 echo 'CEOF
13525 sed -f "$tmp"/undefs.sed "$tmp"/in >"$tmp"/out
13526 rm -f "$tmp"/in
13527 mv "$tmp"/out "$tmp"/in
13528 ' >>"$CONFIG_STATUS"
13529 sed "1,${ac_max_here_lines}d" conftest.undefs >conftest.tail
13530 rm -f conftest.undefs
13531 mv conftest.tail conftest.undefs
13532 done
13533 rm -f conftest.undefs
13534
13535 cat >>"$CONFIG_STATUS" <<\EOF
13536 # Let's still pretend it is `configure' which instantiates (i.e., don't
13537 # use $as_me), people would be surprised to read:
13538 # /* config.h. Generated automatically by config.status. */
13539 if test x"$ac_file" = x-; then
13540 echo "/* Generated automatically by configure. */" >"$tmp"/config.h
13541 else
13542 echo "/* $ac_file. Generated automatically by configure. */" >"$tmp"/config.h
13543 fi
13544 cat "$tmp"/in >>"$tmp"/config.h
13545 rm -f "$tmp"/in
13546 if test x"$ac_file" != x-; then
13547 if cmp -s "$ac_file" "$tmp/config.h" 2>/dev/null; then
13548 { echo "$as_me:13548: $ac_file is unchanged" >&5
13549 echo "$as_me: $ac_file is unchanged" >&6;}
13550 else
13551 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
13552 X"$ac_file" : 'X\(//\)[^/]' \| \
13553 X"$ac_file" : 'X\(//\)$' \| \
13554 X"$ac_file" : 'X\(/\)' \| \
13555 . : '\(.\)' 2>/dev/null ||
13556 echo X"$ac_file" |
13557 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
13558 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
13559 /^X\(\/\/\)$/{ s//\1/; q; }
13560 /^X\(\/\).*/{ s//\1/; q; }
13561 s/.*/./; q'`
13562 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
13563 { case "$ac_dir" in
13564 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
13565 *) as_incr_dir=.;;
13566 esac
13567 as_dummy="$ac_dir"
13568 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
13569 case $as_mkdir_dir in
13570 # Skip DOS drivespec
13571 ?:) as_incr_dir=$as_mkdir_dir ;;
13572 *)
13573 as_incr_dir=$as_incr_dir/$as_mkdir_dir
13574 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
13575 ;;
13576 esac
13577 done; }
13578
13579 fi
13580 rm -f "$ac_file"
13581 mv "$tmp/config.h" "$ac_file"
13582 fi
13583 else
13584 cat "$tmp"/config.h
13585 rm -f "$tmp"/config.h
13586 fi
13587 done
13588 EOF
13589
13590 cat >>"$CONFIG_STATUS" <<\EOF
13591
13592 { (exit 0); exit 0; }
13593 EOF
13594 chmod +x "$CONFIG_STATUS"
13595 ac_clean_files=$ac_clean_files_save
13596
13597 # configure is writing to config.log, and then calls config.status.
13598 # config.status does its own redirection, appending to config.log.
13599 # Unfortunately, on DOS this fails, as config.log is still kept open
13600 # by configure, so config.status won't be able to write to it; its
13601 # output is simply discarded. So we exec the FD to /dev/null,
13602 # effectively closing config.log, so it can be properly (re)opened and
13603 # appended to by config.status. When coming back to configure, we
13604 # need to make the FD available again.
13605 if test "$no_create" != yes; then
13606 ac_cs_success=:
13607 exec 5>/dev/null
13608 $SHELL "$CONFIG_STATUS" || ac_cs_success=false
13609 exec 5>>config.log
13610 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
13611 # would make configure fail if this is the last instruction.
13612 "$ac_cs_success" || { (exit 1); exit 1; }
13613 fi
13614