Debian Codegraph @

configure

raw
1 #! /bin/sh
2 # From configure.in Revision: 1.37 .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by Autoconf 2.52.20250126.
5 #
6 # Copyright 2003-2022,2023 Thomas E. Dickey
7 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
8 # Free Software Foundation, Inc.
9 # This configure script is free software; the Free Software Foundation
10 # gives unlimited permission to copy, distribute and modify it.
11
12 # Avoid depending upon Character Ranges.
13 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
14 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
15 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16 as_cr_digits='0123456789'
17 as_cr_alnum=$as_cr_Letters$as_cr_digits
18
19 # Sed expression to map a string onto a valid variable name.
20 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
21
22 # Sed expression to map a string onto a valid CPP name.
23 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
24
25 # Be Bourne compatible
26 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
27 emulate sh
28 NULLCMD=:
29 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
30 set -o posix
31 fi
32
33 # Name of the executable.
34 as_me=`echo "$0" |sed 's,.*[\\/],,'`
35
36 if expr a : '\(a\)' >/dev/null 2>&1; then
37 as_expr="expr"
38 else
39 as_expr="false"
40 fi
41
42 rm -f conf$$ conf$$.exe conf$$.file
43 echo >conf$$.file
44 if ln -s conf$$.file conf$$ 2>/dev/null; then
45 # We could just check for DJGPP; but this test a) works b) is more generic
46 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
47 if test -f conf$$.exe; then
48 # Don't use ln at all; we don't have any links
49 as_ln_s='cp -p'
50 else
51 as_ln_s='ln -s'
52 fi
53 elif ln conf$$.file conf$$ 2>/dev/null; then
54 as_ln_s='ln'
55 else
56 as_ln_s='cp -p'
57 fi
58 rm -f conf$$ conf$$.exe conf$$.file
59
60 as_executable_p="test -f"
61
62 # Support unset when possible.
63 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
64 as_unset="unset"
65 else
66 as_unset="false"
67 fi
68
69 # NLS nuisances.
70 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
71 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
72 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
73 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
74 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
75 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
76 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
77 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
78
79 # IFS
80 # We need space, tab and new line, in precisely that order.
81 as_nl='
82 '
83 IFS=" $as_nl"
84
85 # CDPATH.
86 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
87
88 # Name of the host.
89 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
90 # so uname gets run too.
91 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
92
93 exec 6>&1
94
95 #
96 # Initializations.
97 #
98 ac_default_prefix=/usr/local
99 cross_compiling=no
100 subdirs=
101 MFLAGS=
102 MAKEFLAGS=
103 SHELL=${CONFIG_SHELL-/bin/sh}
104
105 # Maximum number of lines to put in a shell here document.
106 # This variable seems obsolete. It should probably be removed, and
107 # only ac_max_sed_lines should be used.
108 : "${ac_max_here_lines=38}"
109
110 ac_unique_file="esc.c"
111 # Factoring default headers for most tests.
112 ac_includes_default="\
113 #include <stdio.h>
114 #if HAVE_SYS_TYPES_H
115 # include <sys/types.h>
116 #endif
117 #if HAVE_SYS_STAT_H
118 # include <sys/stat.h>
119 #endif
120 #if STDC_HEADERS
121 # include <stdlib.h>
122 # include <stddef.h>
123 #else
124 # if HAVE_STDLIB_H
125 # include <stdlib.h>
126 # endif
127 #endif
128 #if HAVE_STRING_H
129 # if !STDC_HEADERS && HAVE_MEMORY_H
130 # include <memory.h>
131 # endif
132 # include <string.h>
133 #endif
134 #if HAVE_STRINGS_H
135 # include <strings.h>
136 #endif
137 #if HAVE_INTTYPES_H
138 # include <inttypes.h>
139 #else
140 # if HAVE_STDINT_H
141 # include <stdint.h>
142 # endif
143 #endif
144 #if HAVE_UNISTD_H
145 # include <unistd.h>
146 #endif"
147
148 # Initialize some variables set by options.
149 ac_init_help=
150 ac_init_version=false
151 # The variables have the same names as the options, with
152 # dashes changed to underlines.
153 cache_file=/dev/null
154 exec_prefix=NONE
155 no_create=
156 no_recursion=
157 prefix=NONE
158 program_prefix=NONE
159 program_suffix=NONE
160 program_transform_name=s,x,x,
161 silent=
162 site=
163 srcdir=
164 verbose=
165 x_includes=NONE
166 x_libraries=NONE
167
168 # Installation directory options.
169 # These are left unexpanded so users can "make install exec_prefix=/foo"
170 # and all the variables that are supposed to be based on exec_prefix
171 # by default will actually change.
172 # Use braces instead of parens because sh, perl, etc. also accept them.
173 bindir='${exec_prefix}/bin'
174 sbindir='${exec_prefix}/sbin'
175 libexecdir='${exec_prefix}/libexec'
176 datarootdir='${prefix}/share'
177 datadir='${datarootdir}'
178 sysconfdir='${prefix}/etc'
179 sharedstatedir='${prefix}/com'
180 localstatedir='${prefix}/var'
181 runstatedir='${localstatedir}/run'
182 libdir='${exec_prefix}/lib'
183 includedir='${prefix}/include'
184 oldincludedir='/usr/include'
185 infodir='${datarootdir}/info'
186 mandir='${datarootdir}/man'
187
188 # Identity of this package.
189 PACKAGE_NAME=
190 PACKAGE_TARNAME=
191 PACKAGE_VERSION=
192 PACKAGE_STRING=
193 PACKAGE_BUGREPORT=
194
195 ac_prev=
196 for ac_option
197 do
198 # If the previous option needs an argument, assign it.
199 if test -n "$ac_prev"; then
200 eval "$ac_prev=\$ac_option"
201 ac_prev=
202 continue
203 fi
204
205 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
206
207 # Accept the important Cygnus configure options, so we can diagnose typos.
208
209 case "$ac_option" in
210
211 -bindir | --bindir | --bindi | --bind | --bin | --bi)
212 ac_prev=bindir ;;
213 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
214 bindir=$ac_optarg ;;
215
216 -build | --build | --buil | --bui | --bu)
217 ac_prev=build_alias ;;
218 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
219 build_alias=$ac_optarg ;;
220
221 -cache-file | --cache-file | --cache-fil | --cache-fi \
222 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
223 ac_prev=cache_file ;;
224 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
225 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
226 cache_file=$ac_optarg ;;
227
228 --config-cache | -C)
229 cache_file=config.cache ;;
230
231 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
232 ac_prev=datadir ;;
233 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
234 | --da=*)
235 datadir=$ac_optarg ;;
236
237 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
238 | --dataroo | --dataro | --datar)
239 ac_prev=datarootdir ;;
240 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
241 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
242 datarootdir=$ac_optarg ;;
243
244 -disable-* | --disable-*)
245 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
246 # Reject names that are not valid shell variable names.
247 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
248 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
249 { (exit 1); exit 1; }; }
250 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
251 eval "enable_$ac_feature=no" ;;
252
253 -enable-* | --enable-*)
254 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
255 # Reject names that are not valid shell variable names.
256 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
257 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
258 { (exit 1); exit 1; }; }
259 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
260 case "$ac_option" in
261 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
262 *) ac_optarg=yes ;;
263 esac
264 eval "enable_$ac_feature='$ac_optarg'" ;;
265
266 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
267 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
268 | --exec | --exe | --ex)
269 ac_prev=exec_prefix ;;
270 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
271 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
272 | --exec=* | --exe=* | --ex=*)
273 exec_prefix=$ac_optarg ;;
274
275 -gas | --gas | --ga | --g)
276 # Obsolete; use --with-gas.
277 with_gas=yes ;;
278
279 -help | --help | --hel | --he | -h)
280 ac_init_help=long ;;
281 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
282 ac_init_help=recursive ;;
283 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
284 ac_init_help=short ;;
285
286 -host | --host | --hos | --ho)
287 ac_prev=host_alias ;;
288 -host=* | --host=* | --hos=* | --ho=*)
289 host_alias=$ac_optarg ;;
290
291 -includedir | --includedir | --includedi | --included | --include \
292 | --includ | --inclu | --incl | --inc)
293 ac_prev=includedir ;;
294 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
295 | --includ=* | --inclu=* | --incl=* | --inc=*)
296 includedir=$ac_optarg ;;
297
298 -infodir | --infodir | --infodi | --infod | --info | --inf)
299 ac_prev=infodir ;;
300 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
301 infodir=$ac_optarg ;;
302
303 -libdir | --libdir | --libdi | --libd)
304 ac_prev=libdir ;;
305 -libdir=* | --libdir=* | --libdi=* | --libd=*)
306 libdir=$ac_optarg ;;
307
308 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
309 | --libexe | --libex | --libe)
310 ac_prev=libexecdir ;;
311 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
312 | --libexe=* | --libex=* | --libe=*)
313 libexecdir=$ac_optarg ;;
314
315 -localstatedir | --localstatedir | --localstatedi | --localstated \
316 | --localstate | --localstat | --localsta | --localst \
317 | --locals | --local | --loca | --loc | --lo)
318 ac_prev=localstatedir ;;
319 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
320 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
321 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
322 localstatedir=$ac_optarg ;;
323
324 -runstatedir | --runstatedir | --runstatedi | --runstated \
325 | --runstate | --runstat | --runsta | --runst \
326 | --runs | --run | --ru)
327 ac_prev=runstatedir ;;
328 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
329 | --runstate=* | --runstat=* | --runsta=* | --runst=* \
330 | --runs=* | --run=* | --ru=*)
331 runstatedir=$ac_optarg ;;
332
333 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
334 ac_prev=mandir ;;
335 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
336 mandir=$ac_optarg ;;
337
338 -nfp | --nfp | --nf)
339 # Obsolete; use --without-fp.
340 with_fp=no ;;
341
342 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
343 | --no-cr | --no-c)
344 no_create=yes ;;
345
346 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
347 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
348 no_recursion=yes ;;
349
350 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
351 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
352 | --oldin | --oldi | --old | --ol | --o)
353 ac_prev=oldincludedir ;;
354 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
355 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
356 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
357 oldincludedir=$ac_optarg ;;
358
359 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
360 ac_prev=prefix ;;
361 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
362 prefix=$ac_optarg ;;
363
364 -program-prefix | --program-prefix | --program-prefi | --program-pref \
365 | --program-pre | --program-pr | --program-p)
366 ac_prev=program_prefix ;;
367 -program-prefix=* | --program-prefix=* | --program-prefi=* \
368 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
369 program_prefix=$ac_optarg ;;
370
371 -program-suffix | --program-suffix | --program-suffi | --program-suff \
372 | --program-suf | --program-su | --program-s)
373 ac_prev=program_suffix ;;
374 -program-suffix=* | --program-suffix=* | --program-suffi=* \
375 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
376 program_suffix=$ac_optarg ;;
377
378 -program-transform-name | --program-transform-name \
379 | --program-transform-nam | --program-transform-na \
380 | --program-transform-n | --program-transform- \
381 | --program-transform | --program-transfor \
382 | --program-transfo | --program-transf \
383 | --program-trans | --program-tran \
384 | --progr-tra | --program-tr | --program-t)
385 ac_prev=program_transform_name ;;
386 -program-transform-name=* | --program-transform-name=* \
387 | --program-transform-nam=* | --program-transform-na=* \
388 | --program-transform-n=* | --program-transform-=* \
389 | --program-transform=* | --program-transfor=* \
390 | --program-transfo=* | --program-transf=* \
391 | --program-trans=* | --program-tran=* \
392 | --progr-tra=* | --program-tr=* | --program-t=*)
393 program_transform_name=$ac_optarg ;;
394
395 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
396 | -silent | --silent | --silen | --sile | --sil)
397 silent=yes ;;
398
399 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
400 ac_prev=sbindir ;;
401 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
402 | --sbi=* | --sb=*)
403 sbindir=$ac_optarg ;;
404
405 -sharedstatedir | --sharedstatedir | --sharedstatedi \
406 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
407 | --sharedst | --shareds | --shared | --share | --shar \
408 | --sha | --sh)
409 ac_prev=sharedstatedir ;;
410 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
411 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
412 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
413 | --sha=* | --sh=*)
414 sharedstatedir=$ac_optarg ;;
415
416 -site | --site | --sit)
417 ac_prev=site ;;
418 -site=* | --site=* | --sit=*)
419 site=$ac_optarg ;;
420
421 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
422 ac_prev=srcdir ;;
423 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
424 srcdir=$ac_optarg ;;
425
426 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
427 | --syscon | --sysco | --sysc | --sys | --sy)
428 ac_prev=sysconfdir ;;
429 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
430 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
431 sysconfdir=$ac_optarg ;;
432
433 -target | --target | --targe | --targ | --tar | --ta | --t)
434 ac_prev=target_alias ;;
435 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
436 target_alias=$ac_optarg ;;
437
438 -v | -verbose | --verbose | --verbos | --verbo | --verb)
439 verbose=yes ;;
440
441 -version | --version | --versio | --versi | --vers | -V)
442 ac_init_version=: ;;
443
444 -with-* | --with-*)
445 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
446 # Reject names that are not valid shell variable names.
447 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
448 { echo "$as_me: error: invalid package name: $ac_package" >&2
449 { (exit 1); exit 1; }; }
450 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
451 case "$ac_option" in
452 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
453 *) ac_optarg=yes ;;
454 esac
455 eval "with_$ac_package='$ac_optarg'" ;;
456
457 -without-* | --without-*)
458 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
459 # Reject names that are not valid shell variable names.
460 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
461 { echo "$as_me: error: invalid package name: $ac_package" >&2
462 { (exit 1); exit 1; }; }
463 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
464 eval "with_$ac_package=no" ;;
465
466 --x)
467 # Obsolete; use --with-x.
468 with_x=yes ;;
469
470 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
471 | --x-incl | --x-inc | --x-in | --x-i)
472 ac_prev=x_includes ;;
473 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
474 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
475 x_includes=$ac_optarg ;;
476
477 -x-libraries | --x-libraries | --x-librarie | --x-librari \
478 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
479 ac_prev=x_libraries ;;
480 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
481 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
482 x_libraries=$ac_optarg ;;
483
484 -*dir | -dvi* | -doc* | -html* | -local* | -pdf* | -ps* )
485 echo "$as_me: WARNING: unsupported option: $ac_option" >&2
486 ;;
487
488 -*) { echo "$as_me: error: unrecognized option: $ac_option
489 Try \`$0 --help' for more information." >&2
490 { (exit 1); exit 1; }; }
491 ;;
492
493 *=*)
494 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
495 # Reject names that are not valid shell variable names.
496 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
497 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
498 { (exit 1); exit 1; }; }
499 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
500 eval "$ac_envvar='$ac_optarg'"
501 export "$ac_envvar" ;;
502
503 *)
504 # FIXME: should be removed in autoconf 3.0.
505 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
506 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
507 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
508 : "${build_alias=$ac_option}" "${host_alias=$ac_option}" "${target_alias=$ac_option}"
509 ;;
510
511 esac
512 done
513
514 if test -n "$ac_prev"; then
515 ac_option=--`echo "$ac_prev" | sed 's/_/-/g'`
516 { echo "$as_me: error: missing argument to $ac_option" >&2
517 { (exit 1); exit 1; }; }
518 fi
519
520 # Be sure to have absolute paths.
521 for ac_var in exec_prefix prefix
522 do
523 eval ac_val=$`echo "$ac_var"`
524 case "$ac_val" in
525 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
526 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
527 { (exit 1); exit 1; }; };;
528 esac
529 done
530
531 # Be sure to have absolute paths.
532 for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
533 localstatedir libdir includedir oldincludedir infodir mandir
534 do
535 eval ac_val=$`echo "$ac_var"`
536 case "$ac_val" in
537 [\\/$]* | ?:[\\/]* ) ;;
538 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
539 { (exit 1); exit 1; }; };;
540 esac
541 done
542
543 # There might be people who depend on the old broken behavior: `$host'
544 # used to hold the argument of --host etc.
545 build=$build_alias
546 host=$host_alias
547 target=$target_alias
548
549 # FIXME: should be removed in autoconf 3.0.
550 if test "x$host_alias" != x; then
551 if test "x$build_alias" = x; then
552 cross_compiling=maybe
553 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
554 If a cross compiler is detected then cross compile mode will be used." >&2
555 elif test "x$build_alias" != "x$host_alias"; then
556 cross_compiling=yes
557 fi
558 fi
559
560 ac_tool_prefix=
561 test -n "$host_alias" && ac_tool_prefix=$host_alias-
562
563 test "$silent" = yes && exec 6>/dev/null
564
565 # Find the source files, if location was not specified.
566 if test -z "$srcdir"; then
567 ac_srcdir_defaulted=yes
568 # Try the directory containing this script, then its parent.
569 ac_prog=$0
570 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
571 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
572 srcdir=$ac_confdir
573 if test ! -r "$srcdir/$ac_unique_file"; then
574 srcdir=..
575 fi
576 else
577 ac_srcdir_defaulted=no
578 fi
579 if test ! -r "$srcdir/$ac_unique_file"; then
580 if test "$ac_srcdir_defaulted" = yes; then
581 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
582 { (exit 1); exit 1; }; }
583 else
584 { echo "$as_me: error: cannot find sources in $srcdir" >&2
585 { (exit 1); exit 1; }; }
586 fi
587 fi
588 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
589 ac_env_build_alias_set=${build_alias+set}
590 ac_env_build_alias_value=$build_alias
591 ac_cv_env_build_alias_set=${build_alias+set}
592 ac_cv_env_build_alias_value=$build_alias
593 ac_env_host_alias_set=${host_alias+set}
594 ac_env_host_alias_value=$host_alias
595 ac_cv_env_host_alias_set=${host_alias+set}
596 ac_cv_env_host_alias_value=$host_alias
597 ac_env_target_alias_set=${target_alias+set}
598 ac_env_target_alias_value=$target_alias
599 ac_cv_env_target_alias_set=${target_alias+set}
600 ac_cv_env_target_alias_value=$target_alias
601 ac_env_CC_set=${CC+set}
602 ac_env_CC_value=$CC
603 ac_cv_env_CC_set=${CC+set}
604 ac_cv_env_CC_value=$CC
605 ac_env_CFLAGS_set=${CFLAGS+set}
606 ac_env_CFLAGS_value=$CFLAGS
607 ac_cv_env_CFLAGS_set=${CFLAGS+set}
608 ac_cv_env_CFLAGS_value=$CFLAGS
609 ac_env_LDFLAGS_set=${LDFLAGS+set}
610 ac_env_LDFLAGS_value=$LDFLAGS
611 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
612 ac_cv_env_LDFLAGS_value=$LDFLAGS
613 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
614 ac_env_CPPFLAGS_value=$CPPFLAGS
615 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
616 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
617 ac_env_CPP_set=${CPP+set}
618 ac_env_CPP_value=$CPP
619 ac_cv_env_CPP_set=${CPP+set}
620 ac_cv_env_CPP_value=$CPP
621
622 #
623 # Report the --help message.
624 #
625 if test "$ac_init_help" = "long"; then
626 # Omit some internal or obsolete options to make the list less imposing.
627 # This message is too long to be a string in the A/UX 3.1 sh.
628 cat <<EOF
629 \`configure' configures this package to adapt to many kinds of systems.
630
631 Usage: $0 [OPTION]... [VAR=VALUE]...
632
633 To assign environment variables (e.g., CC, CFLAGS...), specify them as
634 VAR=VALUE. See below for descriptions of some of the useful variables.
635
636 Defaults for the options are specified in brackets.
637
638 Configuration:
639 -h, --help display this help and exit
640 --help=short display options specific to this package
641 --help=recursive display the short help of all the included packages
642 -V, --version display version information and exit
643 -q, --quiet, --silent do not print \`checking...' messages
644 --cache-file=FILE cache test results in FILE [disabled]
645 -C, --config-cache alias for \`--cache-file=config.cache'
646 -n, --no-create do not create output files
647 --srcdir=DIR find the sources in DIR [configure dir or \`..']
648
649 EOF
650
651 cat <<EOF
652 Installation directories:
653 --prefix=PREFIX install architecture-independent files in PREFIX
654 [$ac_default_prefix]
655 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
656 [PREFIX]
657
658 By default, \`make install' will install all the files in
659 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
660 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
661 for instance \`--prefix=\$HOME'.
662
663 For better control, use the options below.
664
665 Fine tuning of the installation directories:
666 --bindir=DIR user executables [EPREFIX/bin]
667 --sbindir=DIR system admin executables [EPREFIX/sbin]
668 --libexecdir=DIR program executables [EPREFIX/libexec]
669 --datarootdir=DIR read-only architecture-independent data [PREFIX/share]
670 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
671 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
672 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
673 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
674 --runstatedir=DIR extra definition of runtime data [LOCALSTATEDIR/run]
675 --libdir=DIR object code libraries [EPREFIX/lib]
676 --includedir=DIR C header files [PREFIX/include]
677 --oldincludedir=DIR C header files for non-gcc [/usr/include]
678 --infodir=DIR info documentation [DATAROOTDIR/info]
679 --mandir=DIR man documentation [DATAROOTDIR/man]
680 EOF
681
682 cat <<\EOF
683
684 Program names:
685 --program-prefix=PREFIX prepend PREFIX to installed program names
686 --program-suffix=SUFFIX append SUFFIX to installed program names
687 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
688
689 System types:
690 --build=BUILD configure for building on BUILD [guessed]
691 --host=HOST build programs to run on HOST [BUILD]
692 --target=TARGET configure for building compilers for TARGET [HOST]
693 EOF
694 fi
695
696 if test -n "$ac_init_help"; then
697
698 cat <<\EOF
699
700 Optional Packages:
701 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
702 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
703
704 Optional Features:
705 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
706 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
707
708 --with-system-type=XXX test: override derived host system-type
709 --with-man2html[=XXX] use XXX rather than groff
710 --disable-echo do not display "compiling" commands
711 --enable-warnings test: turn on gcc compiler warnings
712 --enable-stdnoreturn enable C11 _Noreturn feature for diagnostics
713
714 Some influential environment variables:
715 CC C compiler command
716 CFLAGS C compiler flags
717 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
718 nonstandard directory <lib dir>
719 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
720 headers in a nonstandard directory <include dir>
721 CPP C preprocessor
722
723 Use these variables to override the choices made by `configure' or to help
724 it to find libraries and programs with nonstandard names/locations.
725
726 EOF
727 fi
728
729 if test "$ac_init_help" = "recursive"; then
730 # If there are subdirs, report their specific --help.
731 ac_popdir=`pwd`
732 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
733 cd "$ac_subdir"
734 # A "../" for each directory in /$ac_subdir.
735 ac_dots=`echo "$ac_subdir" |
736 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
737
738 case "$srcdir" in
739 .) # No --srcdir option. We are building in place.
740 ac_sub_srcdir="$srcdir" ;;
741 [\\/]* | ?:[\\/]* ) # Absolute path.
742 ac_sub_srcdir="$srcdir/$ac_subdir" ;;
743 *) # Relative path.
744 ac_sub_srcdir="$ac_dots$srcdir/$ac_subdir" ;;
745 esac
746
747 # Check for guested configure; otherwise get Cygnus style configure.
748 if test -f "$ac_sub_srcdir/configure.gnu"; then
749 echo
750 $SHELL "$ac_sub_srcdir/configure.gnu" --help=recursive
751 elif test -f "$ac_sub_srcdir/configure"; then
752 echo
753 $SHELL "$ac_sub_srcdir/configure" --help=recursive
754 elif test -f "$ac_sub_srcdir/configure.ac" ||
755 test -f "$ac_sub_srcdir/configure.in"; then
756 echo
757 "$ac_configure" --help
758 else
759 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
760 fi
761 cd "$ac_popdir"
762 done
763 fi
764
765 test -n "$ac_init_help" && exit 0
766 if "$ac_init_version"; then
767 cat <<\EOF
768
769 Copyright 2003-2022,2023 Thomas E. Dickey
770 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
771 Free Software Foundation, Inc.
772 This configure script is free software; the Free Software Foundation
773 gives unlimited permission to copy, distribute and modify it.
774 EOF
775 exit 0
776 fi
777 exec 5>config.log
778 cat >&5 <<EOF
779 This file contains any messages produced by compilers while
780 running configure, to aid debugging if configure makes a mistake.
781
782 It was created by $as_me, which was
783 generated by GNU Autoconf 2.52.20250126. Invocation command line was
784
785 $ $0 $@
786
787 EOF
788 {
789 cat <<_ASUNAME
790 ## ---------- ##
791 ## Platform. ##
792 ## ---------- ##
793
794 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
795 uname -m = `(uname -m) 2>/dev/null || echo unknown`
796 uname -r = `(uname -r) 2>/dev/null || echo unknown`
797 uname -s = `(uname -s) 2>/dev/null || echo unknown`
798 uname -v = `(uname -v) 2>/dev/null || echo unknown`
799
800 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
801 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
802
803 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
804 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
805 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
806 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
807 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
808 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
809 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
810
811 PATH = $PATH
812
813 _ASUNAME
814 } >&5
815
816 cat >&5 <<EOF
817 ## ------------ ##
818 ## Core tests. ##
819 ## ------------ ##
820
821 EOF
822
823 # Keep a trace of the command line.
824 # Strip out --no-create and --no-recursion so they do not pile up.
825 # Also quote any args containing shell meta-characters.
826 ac_configure_args=
827 ac_sep=
828 for ac_arg
829 do
830 case "$ac_arg" in
831 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
832 | --no-cr | --no-c) ;;
833 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
834 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
835 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
836 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
837 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
838 ac_sep=" " ;;
839 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
840 ac_sep=" " ;;
841 esac
842 # Get rid of the leading space.
843 done
844
845 # When interrupted or exit'd, cleanup temporary files, and complete
846 # config.log. We remove comments because anyway the quotes in there
847 # would cause problems or look ugly.
848 trap 'exit_status=$?
849 # Save into config.log some information that might help in debugging.
850 echo >&5
851 echo "## ----------------- ##" >&5
852 echo "## Cache variables. ##" >&5
853 echo "## ----------------- ##" >&5
854 echo >&5
855 # The following way of writing the cache mishandles newlines in values,
856 {
857 (set) 2>&1 |
858 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
859 *ac_space=\ *)
860 sed -n \
861 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
862 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
863 ;;
864 *)
865 sed -n \
866 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
867 ;;
868 esac;
869 } >&5
870 sed "/^$/d" confdefs.h >conftest.log
871 if test -s conftest.log; then
872 echo >&5
873 echo "## ------------ ##" >&5
874 echo "## confdefs.h. ##" >&5
875 echo "## ------------ ##" >&5
876 echo >&5
877 cat conftest.log >&5
878 fi
879 (echo; echo) >&5
880 test "$ac_signal" != 0 &&
881 echo "$as_me: caught signal $ac_signal" >&5
882 echo "$as_me: exit $exit_status" >&5
883 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
884 exit $exit_status
885 ' 0
886 for ac_signal in 1 2 13 15; do
887 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' "$ac_signal"
888 done
889 ac_signal=0
890
891 # confdefs.h avoids OS command line length limits that DEFS can exceed.
892 rm -rf conftest* confdefs.h
893 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
894 echo >confdefs.h
895
896 # Let the site file select an alternate cache file if it wants to.
897 # Prefer explicitly selected file to automatically selected ones.
898 if test -z "$CONFIG_SITE"; then
899 if test "x$prefix" != xNONE; then
900 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
901 else
902 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
903 fi
904 fi
905 for ac_site_file in $CONFIG_SITE; do
906 if test -r "$ac_site_file"; then
907 { echo "$as_me:907: loading site script $ac_site_file" >&5
908 echo "$as_me: loading site script $ac_site_file" >&6;}
909 cat "$ac_site_file" >&5
910 . "$ac_site_file"
911 fi
912 done
913
914 if test -r "$cache_file"; then
915 # Some versions of bash will fail to source /dev/null (special
916 # files actually), so we avoid doing that.
917 if test -f "$cache_file"; then
918 { echo "$as_me:918: loading cache $cache_file" >&5
919 echo "$as_me: loading cache $cache_file" >&6;}
920 case $cache_file in
921 [\\/]* | ?:[\\/]* ) . $cache_file;;
922 *) . ./$cache_file;;
923 esac
924 fi
925 else
926 { echo "$as_me:926: creating cache $cache_file" >&5
927 echo "$as_me: creating cache $cache_file" >&6;}
928 >$cache_file
929 fi
930
931 # Check that the precious variables saved in the cache have kept the same
932 # value.
933 ac_cache_corrupted=false
934 for ac_var in `(set) 2>&1 |
935 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
936 eval ac_old_set=\$ac_cv_env_${ac_var}_set
937 eval ac_new_set=\$ac_env_${ac_var}_set
938 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
939 eval ac_new_val="\$ac_env_${ac_var}_value"
940 case "$ac_old_set,$ac_new_set" in
941 set,)
942 { echo "$as_me:942: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
943 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
944 ac_cache_corrupted=: ;;
945 ,set)
946 { echo "$as_me:946: error: \`$ac_var' was not set in the previous run" >&5
947 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
948 ac_cache_corrupted=: ;;
949 ,);;
950 *)
951 if test "x$ac_old_val" != "x$ac_new_val"; then
952 { echo "$as_me:952: error: \`$ac_var' has changed since the previous run:" >&5
953 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
954 { echo "$as_me:954: former value: $ac_old_val" >&5
955 echo "$as_me: former value: $ac_old_val" >&2;}
956 { echo "$as_me:956: current value: $ac_new_val" >&5
957 echo "$as_me: current value: $ac_new_val" >&2;}
958 ac_cache_corrupted=:
959 fi;;
960 esac
961 # Pass precious variables to config.status. It doesn't matter if
962 # we pass some twice (in addition to the command line arguments).
963 if test "$ac_new_set" = set; then
964 case "$ac_new_val" in
965 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
966 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
967 ac_configure_args="$ac_configure_args '$ac_arg'"
968 ;;
969 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
970 ;;
971 esac
972 fi
973 done
974 if "$ac_cache_corrupted"; then
975 { echo "$as_me:975: error: changes in the environment can compromise the build" >&5
976 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
977 { { echo "$as_me:977: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
978 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
979 { (exit 1); exit 1; }; }
980 fi
981
982 ac_ext=c
983 ac_cpp='$CPP $CPPFLAGS'
984 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
985 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
986 ac_compiler_gnu=$ac_cv_c_compiler_gnu
987 ac_main_return="return"
988
989 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
990 *c*,-n*) ECHO_N=
991 ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
992 ECHO_T=' '
993 ;;
994 *c*,* ) ECHO_N=-n
995 ECHO_C=
996 ECHO_T=
997 ;;
998 *) ECHO_N=
999 ECHO_C='\c'
1000 ECHO_T=
1001 ;;
1002 esac
1003 echo "#! $SHELL" >conftest.sh
1004 echo "exit 0" >>conftest.sh
1005 chmod +x conftest.sh
1006 if { (echo "$as_me:1006: PATH=\".;.\"; conftest.sh") >&5
1007 (PATH=".;."; conftest.sh) 2>&5
1008 ac_status=$?
1009 echo "$as_me:1009: \$? = $ac_status" >&5
1010 (exit "$ac_status"); }; then
1011 ac_path_separator=';'
1012 else
1013 ac_path_separator=:
1014 fi
1015 PATH_SEPARATOR="$ac_path_separator"
1016 rm -f conftest.sh
1017
1018 ac_config_headers="$ac_config_headers config.h:config.hin"
1019
1020 ac_aux_dir=
1021 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1022 if test -f "$ac_dir/install-sh"; then
1023 ac_aux_dir=$ac_dir
1024 ac_install_sh="$ac_aux_dir/install-sh -c"
1025 break
1026 elif test -f "$ac_dir/install.sh"; then
1027 ac_aux_dir=$ac_dir
1028 ac_install_sh="$ac_aux_dir/install.sh -c"
1029 break
1030 elif test -f "$ac_dir/shtool"; then
1031 ac_aux_dir=$ac_dir
1032 ac_install_sh="$ac_aux_dir/shtool install -c"
1033 break
1034 fi
1035 done
1036 if test -z "$ac_aux_dir"; then
1037 { { echo "$as_me:1037: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1038 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1039 { (exit 1); exit 1; }; }
1040 fi
1041 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1042 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1043 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1044
1045 # Make sure we can run config.sub.
1046 $ac_config_sub sun4 >/dev/null 2>&1 ||
1047 { { echo "$as_me:1047: error: cannot run $ac_config_sub" >&5
1048 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1049 { (exit 1); exit 1; }; }
1050
1051 echo "$as_me:1051: checking build system type" >&5
1052 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1053 if test "${ac_cv_build+set}" = set; then
1054 echo $ECHO_N "(cached) $ECHO_C" >&6
1055 else
1056 ac_cv_build_alias=$build_alias
1057 test -z "$ac_cv_build_alias" &&
1058 ac_cv_build_alias=`$ac_config_guess`
1059 test -z "$ac_cv_build_alias" &&
1060 { { echo "$as_me:1060: error: cannot guess build type; you must specify one" >&5
1061 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1062 { (exit 1); exit 1; }; }
1063 ac_cv_build=`$ac_config_sub "$ac_cv_build_alias"` ||
1064 { { echo "$as_me:1064: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1065 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1066 { (exit 1); exit 1; }; }
1067
1068 fi
1069 echo "$as_me:1069: result: $ac_cv_build" >&5
1070 echo "${ECHO_T}$ac_cv_build" >&6
1071 build=$ac_cv_build
1072 build_cpu=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1073 build_vendor=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1074 build_os=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1075
1076 if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
1077 echo "$as_me:1077: checking host system type" >&5
1078 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1079 if test "${ac_cv_host+set}" = set; then
1080 echo $ECHO_N "(cached) $ECHO_C" >&6
1081 else
1082 ac_cv_host_alias=$host_alias
1083 test -z "$ac_cv_host_alias" &&
1084 ac_cv_host_alias=$ac_cv_build_alias
1085 ac_cv_host=`$ac_config_sub "$ac_cv_host_alias"` ||
1086 { { echo "$as_me:1086: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1087 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1088 { (exit 1); exit 1; }; }
1089
1090 fi
1091 echo "$as_me:1091: result: $ac_cv_host" >&5
1092 echo "${ECHO_T}$ac_cv_host" >&6
1093 host=$ac_cv_host
1094 host_cpu=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1095 host_vendor=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1096 host_os=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1097
1098 system_name="$host_os"
1099 else
1100 system_name="`(uname -s -r) 2>/dev/null`"
1101 if test -z "$system_name" ; then
1102 system_name="`(hostname) 2>/dev/null`"
1103 fi
1104 fi
1105 test -n "$system_name" &&
1106 cat >>confdefs.h <<EOF
1107 #define SYSTEM_NAME "$system_name"
1108 EOF
1109
1110 if test "${cf_cv_system_name+set}" = set; then
1111 echo $ECHO_N "(cached) $ECHO_C" >&6
1112 else
1113 cf_cv_system_name="$system_name"
1114 fi
1115
1116 test -z "$system_name" && system_name="$cf_cv_system_name"
1117 test -n "$cf_cv_system_name" && echo "$as_me:1117: result: Configuring for $cf_cv_system_name" >&5
1118 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1119
1120 if test ".$system_name" != ".$cf_cv_system_name" ; then
1121 echo "$as_me:1121: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1122 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1123 { { echo "$as_me:1123: error: \"Please remove config.cache and try again.\"" >&5
1124 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1125 { (exit 1); exit 1; }; }
1126 fi
1127
1128 if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
1129 echo "$as_me:1129: checking target system type" >&5
1130 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1131 if test "${ac_cv_target+set}" = set; then
1132 echo $ECHO_N "(cached) $ECHO_C" >&6
1133 else
1134 ac_cv_target_alias=$target_alias
1135 test "x$ac_cv_target_alias" = "x" &&
1136 ac_cv_target_alias=$ac_cv_host_alias
1137 ac_cv_target=`$ac_config_sub "$ac_cv_target_alias"` ||
1138 { { echo "$as_me:1138: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1139 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1140 { (exit 1); exit 1; }; }
1141
1142 fi
1143 echo "$as_me:1143: result: $ac_cv_target" >&5
1144 echo "${ECHO_T}$ac_cv_target" >&6
1145 target=$ac_cv_target
1146 target_cpu=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1147 target_vendor=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1148 target_os=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1149
1150 # The aliases save the names the user supplied, while $host etc.
1151 # will get canonicalized.
1152 test -n "$target_alias" &&
1153 test "$program_prefix$program_suffix$program_transform_name" = \
1154 NONENONEs,x,x, &&
1155 program_prefix=${target_alias}-
1156 system_name="$host_os"
1157 else
1158 system_name="`(uname -s -r) 2>/dev/null`"
1159 if test -z "$system_name" ; then
1160 system_name="`(hostname) 2>/dev/null`"
1161 fi
1162 fi
1163 test -n "$system_name" &&
1164 cat >>confdefs.h <<EOF
1165 #define SYSTEM_NAME "$system_name"
1166 EOF
1167
1168 if test "${cf_cv_system_name+set}" = set; then
1169 echo $ECHO_N "(cached) $ECHO_C" >&6
1170 else
1171 cf_cv_system_name="$system_name"
1172 fi
1173
1174 test -z "$system_name" && system_name="$cf_cv_system_name"
1175 test -n "$cf_cv_system_name" && echo "$as_me:1175: result: Configuring for $cf_cv_system_name" >&5
1176 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1177
1178 if test ".$system_name" != ".$cf_cv_system_name" ; then
1179 echo "$as_me:1179: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1180 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1181 { { echo "$as_me:1181: error: \"Please remove config.cache and try again.\"" >&5
1182 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1183 { (exit 1); exit 1; }; }
1184 fi
1185
1186 # Check whether --with-system-type or --without-system-type was given.
1187 if test "${with_system_type+set}" = set; then
1188 withval="$with_system_type"
1189 { echo "$as_me:1189: WARNING: overriding system type to $withval" >&5
1190 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
1191 cf_cv_system_name=$withval
1192 host_os=$withval
1193
1194 fi;
1195
1196 test "$program_prefix" != NONE &&
1197 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1198 # Use a double $ so make ignores it.
1199 test "$program_suffix" != NONE &&
1200 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1201 # Double any \ or $. echo might interpret backslashes.
1202 # By default was `s,x,x', remove it if useless.
1203 cat <<\_ACEOF >conftest.sed
1204 s/[\\$]/&&/g;s/;s,x,x,$//
1205 _ACEOF
1206 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1207 rm conftest.sed
1208
1209 ac_ext=c
1210 ac_cpp='$CPP $CPPFLAGS'
1211 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1212 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1213 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1214 ac_main_return="return"
1215 if test -n "$ac_tool_prefix"; then
1216 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1217 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1218 echo "$as_me:1218: checking for $ac_word" >&5
1219 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1220 if test "${ac_cv_prog_CC+set}" = set; then
1221 echo $ECHO_N "(cached) $ECHO_C" >&6
1222 else
1223 if test -n "$CC"; then
1224 ac_cv_prog_CC="$CC" # Let the user override the test.
1225 else
1226 ac_save_IFS=$IFS; IFS=$ac_path_separator
1227 ac_dummy="$PATH"
1228 for ac_dir in $ac_dummy; do
1229 IFS=$ac_save_IFS
1230 test -z "$ac_dir" && ac_dir=.
1231 $as_executable_p "$ac_dir/$ac_word" || continue
1232 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1233 echo "$as_me:1233: found $ac_dir/$ac_word" >&5
1234 break
1235 done
1236
1237 fi
1238 fi
1239 CC=$ac_cv_prog_CC
1240 if test -n "$CC"; then
1241 echo "$as_me:1241: result: $CC" >&5
1242 echo "${ECHO_T}$CC" >&6
1243 else
1244 echo "$as_me:1244: result: no" >&5
1245 echo "${ECHO_T}no" >&6
1246 fi
1247
1248 fi
1249 if test -z "$ac_cv_prog_CC"; then
1250 ac_ct_CC=$CC
1251 # Extract the first word of "gcc", so it can be a program name with args.
1252 set dummy gcc; ac_word=$2
1253 echo "$as_me:1253: checking for $ac_word" >&5
1254 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1255 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1256 echo $ECHO_N "(cached) $ECHO_C" >&6
1257 else
1258 if test -n "$ac_ct_CC"; then
1259 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1260 else
1261 ac_save_IFS=$IFS; IFS=$ac_path_separator
1262 ac_dummy="$PATH"
1263 for ac_dir in $ac_dummy; do
1264 IFS=$ac_save_IFS
1265 test -z "$ac_dir" && ac_dir=.
1266 $as_executable_p "$ac_dir/$ac_word" || continue
1267 ac_cv_prog_ac_ct_CC="gcc"
1268 echo "$as_me:1268: found $ac_dir/$ac_word" >&5
1269 break
1270 done
1271
1272 fi
1273 fi
1274 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1275 if test -n "$ac_ct_CC"; then
1276 echo "$as_me:1276: result: $ac_ct_CC" >&5
1277 echo "${ECHO_T}$ac_ct_CC" >&6
1278 else
1279 echo "$as_me:1279: result: no" >&5
1280 echo "${ECHO_T}no" >&6
1281 fi
1282
1283 CC=$ac_ct_CC
1284 else
1285 CC="$ac_cv_prog_CC"
1286 fi
1287
1288 if test -z "$CC"; then
1289 if test -n "$ac_tool_prefix"; then
1290 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1291 set dummy ${ac_tool_prefix}cc; ac_word=$2
1292 echo "$as_me:1292: checking for $ac_word" >&5
1293 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1294 if test "${ac_cv_prog_CC+set}" = set; then
1295 echo $ECHO_N "(cached) $ECHO_C" >&6
1296 else
1297 if test -n "$CC"; then
1298 ac_cv_prog_CC="$CC" # Let the user override the test.
1299 else
1300 ac_save_IFS=$IFS; IFS=$ac_path_separator
1301 ac_dummy="$PATH"
1302 for ac_dir in $ac_dummy; do
1303 IFS=$ac_save_IFS
1304 test -z "$ac_dir" && ac_dir=.
1305 $as_executable_p "$ac_dir/$ac_word" || continue
1306 ac_cv_prog_CC="${ac_tool_prefix}cc"
1307 echo "$as_me:1307: found $ac_dir/$ac_word" >&5
1308 break
1309 done
1310
1311 fi
1312 fi
1313 CC=$ac_cv_prog_CC
1314 if test -n "$CC"; then
1315 echo "$as_me:1315: result: $CC" >&5
1316 echo "${ECHO_T}$CC" >&6
1317 else
1318 echo "$as_me:1318: result: no" >&5
1319 echo "${ECHO_T}no" >&6
1320 fi
1321
1322 fi
1323 if test -z "$ac_cv_prog_CC"; then
1324 ac_ct_CC=$CC
1325 # Extract the first word of "cc", so it can be a program name with args.
1326 set dummy cc; ac_word=$2
1327 echo "$as_me:1327: checking for $ac_word" >&5
1328 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1329 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1330 echo $ECHO_N "(cached) $ECHO_C" >&6
1331 else
1332 if test -n "$ac_ct_CC"; then
1333 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1334 else
1335 ac_save_IFS=$IFS; IFS=$ac_path_separator
1336 ac_dummy="$PATH"
1337 for ac_dir in $ac_dummy; do
1338 IFS=$ac_save_IFS
1339 test -z "$ac_dir" && ac_dir=.
1340 $as_executable_p "$ac_dir/$ac_word" || continue
1341 ac_cv_prog_ac_ct_CC="cc"
1342 echo "$as_me:1342: found $ac_dir/$ac_word" >&5
1343 break
1344 done
1345
1346 fi
1347 fi
1348 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1349 if test -n "$ac_ct_CC"; then
1350 echo "$as_me:1350: result: $ac_ct_CC" >&5
1351 echo "${ECHO_T}$ac_ct_CC" >&6
1352 else
1353 echo "$as_me:1353: result: no" >&5
1354 echo "${ECHO_T}no" >&6
1355 fi
1356
1357 CC=$ac_ct_CC
1358 else
1359 CC="$ac_cv_prog_CC"
1360 fi
1361
1362 fi
1363 if test -z "$CC"; then
1364 # Extract the first word of "cc", so it can be a program name with args.
1365 set dummy cc; ac_word=$2
1366 echo "$as_me:1366: checking for $ac_word" >&5
1367 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1368 if test "${ac_cv_prog_CC+set}" = set; then
1369 echo $ECHO_N "(cached) $ECHO_C" >&6
1370 else
1371 if test -n "$CC"; then
1372 ac_cv_prog_CC="$CC" # Let the user override the test.
1373 else
1374 ac_prog_rejected=no
1375 ac_save_IFS=$IFS; IFS=$ac_path_separator
1376 ac_dummy="$PATH"
1377 for ac_dir in $ac_dummy; do
1378 IFS=$ac_save_IFS
1379 test -z "$ac_dir" && ac_dir=.
1380 $as_executable_p "$ac_dir/$ac_word" || continue
1381 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1382 ac_prog_rejected=yes
1383 continue
1384 fi
1385 ac_cv_prog_CC="cc"
1386 echo "$as_me:1386: found $ac_dir/$ac_word" >&5
1387 break
1388 done
1389
1390 if test "$ac_prog_rejected" = yes; then
1391 # We found a bogon in the path, so make sure we never use it.
1392 set dummy $ac_cv_prog_CC
1393 shift
1394 if test $# != 0; then
1395 # We chose a different compiler from the bogus one.
1396 # However, it has the same basename, so the bogon will be chosen
1397 # first if we set CC to just the basename; use the full file name.
1398 shift
1399 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1400 shift
1401 ac_cv_prog_CC="$@"
1402 fi
1403 fi
1404 fi
1405 fi
1406 CC=$ac_cv_prog_CC
1407 if test -n "$CC"; then
1408 echo "$as_me:1408: result: $CC" >&5
1409 echo "${ECHO_T}$CC" >&6
1410 else
1411 echo "$as_me:1411: result: no" >&5
1412 echo "${ECHO_T}no" >&6
1413 fi
1414
1415 fi
1416 if test -z "$CC"; then
1417 if test -n "$ac_tool_prefix"; then
1418 for ac_prog in cl
1419 do
1420 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1421 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1422 echo "$as_me:1422: checking for $ac_word" >&5
1423 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1424 if test "${ac_cv_prog_CC+set}" = set; then
1425 echo $ECHO_N "(cached) $ECHO_C" >&6
1426 else
1427 if test -n "$CC"; then
1428 ac_cv_prog_CC="$CC" # Let the user override the test.
1429 else
1430 ac_save_IFS=$IFS; IFS=$ac_path_separator
1431 ac_dummy="$PATH"
1432 for ac_dir in $ac_dummy; do
1433 IFS=$ac_save_IFS
1434 test -z "$ac_dir" && ac_dir=.
1435 $as_executable_p "$ac_dir/$ac_word" || continue
1436 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1437 echo "$as_me:1437: found $ac_dir/$ac_word" >&5
1438 break
1439 done
1440
1441 fi
1442 fi
1443 CC=$ac_cv_prog_CC
1444 if test -n "$CC"; then
1445 echo "$as_me:1445: result: $CC" >&5
1446 echo "${ECHO_T}$CC" >&6
1447 else
1448 echo "$as_me:1448: result: no" >&5
1449 echo "${ECHO_T}no" >&6
1450 fi
1451
1452 test -n "$CC" && break
1453 done
1454 fi
1455 if test -z "$CC"; then
1456 ac_ct_CC=$CC
1457 for ac_prog in cl
1458 do
1459 # Extract the first word of "$ac_prog", so it can be a program name with args.
1460 set dummy $ac_prog; ac_word=$2
1461 echo "$as_me:1461: checking for $ac_word" >&5
1462 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1463 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1464 echo $ECHO_N "(cached) $ECHO_C" >&6
1465 else
1466 if test -n "$ac_ct_CC"; then
1467 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1468 else
1469 ac_save_IFS=$IFS; IFS=$ac_path_separator
1470 ac_dummy="$PATH"
1471 for ac_dir in $ac_dummy; do
1472 IFS=$ac_save_IFS
1473 test -z "$ac_dir" && ac_dir=.
1474 $as_executable_p "$ac_dir/$ac_word" || continue
1475 ac_cv_prog_ac_ct_CC="$ac_prog"
1476 echo "$as_me:1476: found $ac_dir/$ac_word" >&5
1477 break
1478 done
1479
1480 fi
1481 fi
1482 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1483 if test -n "$ac_ct_CC"; then
1484 echo "$as_me:1484: result: $ac_ct_CC" >&5
1485 echo "${ECHO_T}$ac_ct_CC" >&6
1486 else
1487 echo "$as_me:1487: result: no" >&5
1488 echo "${ECHO_T}no" >&6
1489 fi
1490
1491 test -n "$ac_ct_CC" && break
1492 done
1493
1494 CC=$ac_ct_CC
1495 fi
1496
1497 fi
1498
1499 test -z "$CC" && { { echo "$as_me:1499: error: no acceptable cc found in \$PATH" >&5
1500 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1501 { (exit 1); exit 1; }; }
1502
1503 # Provide some information about the compiler.
1504 echo "$as_me:1504:" \
1505 "checking for C compiler version" >&5
1506 ac_compiler=`set X $ac_compile; echo "$2"`
1507 { (eval echo "$as_me:1507: \"$ac_compiler --version </dev/null >&5\"") >&5
1508 (eval $ac_compiler --version </dev/null >&5) 2>&5
1509 ac_status=$?
1510 echo "$as_me:1510: \$? = $ac_status" >&5
1511 (exit "$ac_status"); }
1512 { (eval echo "$as_me:1512: \"$ac_compiler -v </dev/null >&5\"") >&5
1513 (eval $ac_compiler -v </dev/null >&5) 2>&5
1514 ac_status=$?
1515 echo "$as_me:1515: \$? = $ac_status" >&5
1516 (exit "$ac_status"); }
1517 { (eval echo "$as_me:1517: \"$ac_compiler -V </dev/null >&5\"") >&5
1518 (eval $ac_compiler -V </dev/null >&5) 2>&5
1519 ac_status=$?
1520 echo "$as_me:1520: \$? = $ac_status" >&5
1521 (exit "$ac_status"); }
1522
1523 cat >"conftest.$ac_ext" <<_ACEOF
1524 #line 1524 "configure"
1525 #include "confdefs.h"
1526
1527 int
1528 main (void)
1529 {
1530
1531 ;
1532 return 0;
1533 }
1534 _ACEOF
1535 ac_clean_files_save=$ac_clean_files
1536 ac_clean_files="$ac_clean_files a.out a.exe"
1537 # Try to create an executable without -o first, disregard a.out.
1538 # It will help us diagnose broken compilers, and finding out an intuition
1539 # of exeext.
1540 echo "$as_me:1540: checking for C compiler default output" >&5
1541 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1542 ac_link_default=`echo "$ac_link" | sed 's/ -o *"conftest[^"]*"//'`
1543 if { (eval echo "$as_me:1543: \"$ac_link_default\"") >&5
1544 (eval $ac_link_default) 2>&5
1545 ac_status=$?
1546 echo "$as_me:1546: \$? = $ac_status" >&5
1547 (exit "$ac_status"); }; then
1548 # Find the output, starting from the most likely. This scheme is
1549 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1550 # resort.
1551 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1552 ls a.out conftest 2>/dev/null;
1553 ls a.* conftest.* 2>/dev/null`; do
1554 case $ac_file in
1555 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1556 a.out ) # We found the default executable, but exeext='' is most
1557 # certainly right.
1558 break;;
1559 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1560 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1561 export ac_cv_exeext
1562 break;;
1563 * ) break;;
1564 esac
1565 done
1566 else
1567 echo "$as_me: failed program was:" >&5
1568 cat "conftest.$ac_ext" >&5
1569 { { echo "$as_me:1569: error: C compiler cannot create executables" >&5
1570 echo "$as_me: error: C compiler cannot create executables" >&2;}
1571 { (exit 77); exit 77; }; }
1572 fi
1573
1574 ac_exeext=$ac_cv_exeext
1575 echo "$as_me:1575: result: $ac_file" >&5
1576 echo "${ECHO_T}$ac_file" >&6
1577
1578 # Check the compiler produces executables we can run. If not, either
1579 # the compiler is broken, or we cross compile.
1580 echo "$as_me:1580: checking whether the C compiler works" >&5
1581 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1582 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1583 # If not cross compiling, check that we can run a simple program.
1584 if test "$cross_compiling" != yes; then
1585 if { ac_try='./$ac_file'
1586 { (eval echo "$as_me:1586: \"$ac_try\"") >&5
1587 (eval $ac_try) 2>&5
1588 ac_status=$?
1589 echo "$as_me:1589: \$? = $ac_status" >&5
1590 (exit "$ac_status"); }; }; then
1591 cross_compiling=no
1592 else
1593 if test "$cross_compiling" = maybe; then
1594 cross_compiling=yes
1595 else
1596 { { echo "$as_me:1596: error: cannot run C compiled programs.
1597 If you meant to cross compile, use \`--host'." >&5
1598 echo "$as_me: error: cannot run C compiled programs.
1599 If you meant to cross compile, use \`--host'." >&2;}
1600 { (exit 1); exit 1; }; }
1601 fi
1602 fi
1603 fi
1604 echo "$as_me:1604: result: yes" >&5
1605 echo "${ECHO_T}yes" >&6
1606
1607 rm -f a.out a.exe "conftest$ac_cv_exeext"
1608 ac_clean_files=$ac_clean_files_save
1609 # Check the compiler produces executables we can run. If not, either
1610 # the compiler is broken, or we cross compile.
1611 echo "$as_me:1611: checking whether we are cross compiling" >&5
1612 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1613 echo "$as_me:1613: result: $cross_compiling" >&5
1614 echo "${ECHO_T}$cross_compiling" >&6
1615
1616 echo "$as_me:1616: checking for executable suffix" >&5
1617 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1618 if { (eval echo "$as_me:1618: \"$ac_link\"") >&5
1619 (eval $ac_link) 2>&5
1620 ac_status=$?
1621 echo "$as_me:1621: \$? = $ac_status" >&5
1622 (exit "$ac_status"); }; then
1623 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1624 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1625 # work properly (i.e., refer to `conftest.exe'), while it won't with
1626 # `rm'.
1627 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1628 case $ac_file in
1629 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1630 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1631 export ac_cv_exeext
1632 break;;
1633 * ) break;;
1634 esac
1635 done
1636 else
1637 { { echo "$as_me:1637: error: cannot compute EXEEXT: cannot compile and link" >&5
1638 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1639 { (exit 1); exit 1; }; }
1640 fi
1641
1642 rm -f "conftest$ac_cv_exeext"
1643 echo "$as_me:1643: result: $ac_cv_exeext" >&5
1644 echo "${ECHO_T}$ac_cv_exeext" >&6
1645
1646 rm -f "conftest.$ac_ext"
1647 EXEEXT=$ac_cv_exeext
1648 ac_exeext=$EXEEXT
1649 echo "$as_me:1649: checking for object suffix" >&5
1650 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1651 if test "${ac_cv_objext+set}" = set; then
1652 echo $ECHO_N "(cached) $ECHO_C" >&6
1653 else
1654 cat >"conftest.$ac_ext" <<_ACEOF
1655 #line 1655 "configure"
1656 #include "confdefs.h"
1657
1658 int
1659 main (void)
1660 {
1661
1662 ;
1663 return 0;
1664 }
1665 _ACEOF
1666 rm -f conftest.o conftest.obj
1667 if { (eval echo "$as_me:1667: \"$ac_compile\"") >&5
1668 (eval $ac_compile) 2>&5
1669 ac_status=$?
1670 echo "$as_me:1670: \$? = $ac_status" >&5
1671 (exit "$ac_status"); }; then
1672 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1673 case $ac_file in
1674 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1675 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1676 break;;
1677 esac
1678 done
1679 else
1680 echo "$as_me: failed program was:" >&5
1681 cat "conftest.$ac_ext" >&5
1682 { { echo "$as_me:1682: error: cannot compute OBJEXT: cannot compile" >&5
1683 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1684 { (exit 1); exit 1; }; }
1685 fi
1686
1687 rm -f "conftest.$ac_cv_objext" "conftest.$ac_ext"
1688 fi
1689 echo "$as_me:1689: result: $ac_cv_objext" >&5
1690 echo "${ECHO_T}$ac_cv_objext" >&6
1691 OBJEXT=$ac_cv_objext
1692 ac_objext=$OBJEXT
1693 echo "$as_me:1693: checking whether we are using the GNU C compiler" >&5
1694 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1695 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1696 echo $ECHO_N "(cached) $ECHO_C" >&6
1697 else
1698 cat >"conftest.$ac_ext" <<_ACEOF
1699 #line 1699 "configure"
1700 #include "confdefs.h"
1701
1702 int
1703 main (void)
1704 {
1705 #ifndef __GNUC__
1706 choke me
1707 #endif
1708
1709 ;
1710 return 0;
1711 }
1712 _ACEOF
1713 rm -f "conftest.$ac_objext"
1714 if { (eval echo "$as_me:1714: \"$ac_compile\"") >&5
1715 (eval $ac_compile) 2>&5
1716 ac_status=$?
1717 echo "$as_me:1717: \$? = $ac_status" >&5
1718 (exit "$ac_status"); } &&
1719 { ac_try='test -s "conftest.$ac_objext"'
1720 { (eval echo "$as_me:1720: \"$ac_try\"") >&5
1721 (eval $ac_try) 2>&5
1722 ac_status=$?
1723 echo "$as_me:1723: \$? = $ac_status" >&5
1724 (exit "$ac_status"); }; }; then
1725 ac_compiler_gnu=yes
1726 else
1727 echo "$as_me: failed program was:" >&5
1728 cat "conftest.$ac_ext" >&5
1729 ac_compiler_gnu=no
1730 fi
1731 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1732 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1733
1734 fi
1735 echo "$as_me:1735: result: $ac_cv_c_compiler_gnu" >&5
1736 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1737 GCC=`test $ac_compiler_gnu = yes && echo yes`
1738 ac_test_CFLAGS=${CFLAGS+set}
1739 ac_save_CFLAGS=$CFLAGS
1740 CFLAGS="-g"
1741 echo "$as_me:1741: checking whether $CC accepts -g" >&5
1742 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1743 if test "${ac_cv_prog_cc_g+set}" = set; then
1744 echo $ECHO_N "(cached) $ECHO_C" >&6
1745 else
1746 cat >"conftest.$ac_ext" <<_ACEOF
1747 #line 1747 "configure"
1748 #include "confdefs.h"
1749
1750 int
1751 main (void)
1752 {
1753
1754 ;
1755 return 0;
1756 }
1757 _ACEOF
1758 rm -f "conftest.$ac_objext"
1759 if { (eval echo "$as_me:1759: \"$ac_compile\"") >&5
1760 (eval $ac_compile) 2>&5
1761 ac_status=$?
1762 echo "$as_me:1762: \$? = $ac_status" >&5
1763 (exit "$ac_status"); } &&
1764 { ac_try='test -s "conftest.$ac_objext"'
1765 { (eval echo "$as_me:1765: \"$ac_try\"") >&5
1766 (eval $ac_try) 2>&5
1767 ac_status=$?
1768 echo "$as_me:1768: \$? = $ac_status" >&5
1769 (exit "$ac_status"); }; }; then
1770 ac_cv_prog_cc_g=yes
1771 else
1772 echo "$as_me: failed program was:" >&5
1773 cat "conftest.$ac_ext" >&5
1774 ac_cv_prog_cc_g=no
1775 fi
1776 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1777 fi
1778 echo "$as_me:1778: result: $ac_cv_prog_cc_g" >&5
1779 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1780 if test "$ac_test_CFLAGS" = set; then
1781 CFLAGS=$ac_save_CFLAGS
1782 elif test $ac_cv_prog_cc_g = yes; then
1783 if test "$GCC" = yes; then
1784 CFLAGS="-g -O2"
1785 else
1786 CFLAGS="-g"
1787 fi
1788 else
1789 if test "$GCC" = yes; then
1790 CFLAGS="-O2"
1791 else
1792 CFLAGS=
1793 fi
1794 fi
1795 # Some people use a C++ compiler to compile C. Since we use `exit',
1796 # in C++ we need to declare it. In case someone uses the same compiler
1797 # for both compiling C and C++ we need to have the C++ compiler decide
1798 # the declaration of exit, since it's the most demanding environment.
1799 cat >"conftest.$ac_ext" <<_ACEOF
1800 #ifndef __cplusplus
1801 choke me
1802 #endif
1803 _ACEOF
1804 rm -f "conftest.$ac_objext"
1805 if { (eval echo "$as_me:1805: \"$ac_compile\"") >&5
1806 (eval $ac_compile) 2>&5
1807 ac_status=$?
1808 echo "$as_me:1808: \$? = $ac_status" >&5
1809 (exit "$ac_status"); } &&
1810 { ac_try='test -s "conftest.$ac_objext"'
1811 { (eval echo "$as_me:1811: \"$ac_try\"") >&5
1812 (eval $ac_try) 2>&5
1813 ac_status=$?
1814 echo "$as_me:1814: \$? = $ac_status" >&5
1815 (exit "$ac_status"); }; }; then
1816 for ac_declaration in \
1817 ''\
1818 '#include <stdlib.h>' \
1819 'extern "C" void std::exit (int) throw (); using std::exit;' \
1820 'extern "C" void std::exit (int); using std::exit;' \
1821 'extern "C" void exit (int) throw ();' \
1822 'extern "C" void exit (int);' \
1823 'void exit (int);'
1824 do
1825 cat >"conftest.$ac_ext" <<_ACEOF
1826 #line 1826 "configure"
1827 #include "confdefs.h"
1828 #include <stdlib.h>
1829 $ac_declaration
1830 int
1831 main (void)
1832 {
1833 exit (42);
1834 ;
1835 return 0;
1836 }
1837 _ACEOF
1838 rm -f "conftest.$ac_objext"
1839 if { (eval echo "$as_me:1839: \"$ac_compile\"") >&5
1840 (eval $ac_compile) 2>&5
1841 ac_status=$?
1842 echo "$as_me:1842: \$? = $ac_status" >&5
1843 (exit "$ac_status"); } &&
1844 { ac_try='test -s "conftest.$ac_objext"'
1845 { (eval echo "$as_me:1845: \"$ac_try\"") >&5
1846 (eval $ac_try) 2>&5
1847 ac_status=$?
1848 echo "$as_me:1848: \$? = $ac_status" >&5
1849 (exit "$ac_status"); }; }; then
1850 :
1851 else
1852 echo "$as_me: failed program was:" >&5
1853 cat "conftest.$ac_ext" >&5
1854 continue
1855 fi
1856 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1857 cat >"conftest.$ac_ext" <<_ACEOF
1858 #line 1858 "configure"
1859 #include "confdefs.h"
1860 $ac_declaration
1861 int
1862 main (void)
1863 {
1864 exit (42);
1865 ;
1866 return 0;
1867 }
1868 _ACEOF
1869 rm -f "conftest.$ac_objext"
1870 if { (eval echo "$as_me:1870: \"$ac_compile\"") >&5
1871 (eval $ac_compile) 2>&5
1872 ac_status=$?
1873 echo "$as_me:1873: \$? = $ac_status" >&5
1874 (exit "$ac_status"); } &&
1875 { ac_try='test -s "conftest.$ac_objext"'
1876 { (eval echo "$as_me:1876: \"$ac_try\"") >&5
1877 (eval $ac_try) 2>&5
1878 ac_status=$?
1879 echo "$as_me:1879: \$? = $ac_status" >&5
1880 (exit "$ac_status"); }; }; then
1881 break
1882 else
1883 echo "$as_me: failed program was:" >&5
1884 cat "conftest.$ac_ext" >&5
1885 fi
1886 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1887 done
1888 rm -rf conftest*
1889 if test -n "$ac_declaration"; then
1890 echo '#ifdef __cplusplus' >>confdefs.h
1891 echo "$ac_declaration" >>confdefs.h
1892 echo '#endif' >>confdefs.h
1893 fi
1894
1895 else
1896 echo "$as_me: failed program was:" >&5
1897 cat "conftest.$ac_ext" >&5
1898 fi
1899 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1900 ac_ext=c
1901 ac_cpp='$CPP $CPPFLAGS'
1902 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1903 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1904 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1905 ac_main_return="return"
1906
1907 GCC_VERSION=none
1908 if test "$GCC" = yes ; then
1909 echo "$as_me:1909: checking version of $CC" >&5
1910 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1911 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^[^(]*([^)][^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1912 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1913 echo "$as_me:1913: result: $GCC_VERSION" >&5
1914 echo "${ECHO_T}$GCC_VERSION" >&6
1915 fi
1916
1917 INTEL_COMPILER=no
1918
1919 if test "$GCC" = yes ; then
1920 case "$host_os" in
1921 (linux*|gnu*)
1922 echo "$as_me:1922: checking if this is really Intel C compiler" >&5
1923 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
1924 cf_save_CFLAGS="$CFLAGS"
1925 CFLAGS="$CFLAGS -no-gcc"
1926 cat >"conftest.$ac_ext" <<_ACEOF
1927 #line 1927 "configure"
1928 #include "confdefs.h"
1929
1930 int
1931 main (void)
1932 {
1933
1934 #ifdef __INTEL_COMPILER
1935 #else
1936 #error __INTEL_COMPILER is not defined
1937 #endif
1938
1939 ;
1940 return 0;
1941 }
1942 _ACEOF
1943 rm -f "conftest.$ac_objext"
1944 if { (eval echo "$as_me:1944: \"$ac_compile\"") >&5
1945 (eval $ac_compile) 2>&5
1946 ac_status=$?
1947 echo "$as_me:1947: \$? = $ac_status" >&5
1948 (exit "$ac_status"); } &&
1949 { ac_try='test -s "conftest.$ac_objext"'
1950 { (eval echo "$as_me:1950: \"$ac_try\"") >&5
1951 (eval $ac_try) 2>&5
1952 ac_status=$?
1953 echo "$as_me:1953: \$? = $ac_status" >&5
1954 (exit "$ac_status"); }; }; then
1955 INTEL_COMPILER=yes
1956 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
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: $INTEL_COMPILER" >&5
1965 echo "${ECHO_T}$INTEL_COMPILER" >&6
1966 ;;
1967 esac
1968 fi
1969
1970 CLANG_COMPILER=no
1971
1972 if test "$GCC" = yes ; then
1973 echo "$as_me:1973: checking if this is really Clang C compiler" >&5
1974 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
1975 cf_save_CFLAGS="$CFLAGS"
1976 cat >"conftest.$ac_ext" <<_ACEOF
1977 #line 1977 "configure"
1978 #include "confdefs.h"
1979
1980 int
1981 main (void)
1982 {
1983
1984 #ifdef __clang__
1985 #else
1986 #error __clang__ is not defined
1987 #endif
1988
1989 ;
1990 return 0;
1991 }
1992 _ACEOF
1993 rm -f "conftest.$ac_objext"
1994 if { (eval echo "$as_me:1994: \"$ac_compile\"") >&5
1995 (eval $ac_compile) 2>&5
1996 ac_status=$?
1997 echo "$as_me:1997: \$? = $ac_status" >&5
1998 (exit "$ac_status"); } &&
1999 { ac_try='test -s "conftest.$ac_objext"'
2000 { (eval echo "$as_me:2000: \"$ac_try\"") >&5
2001 (eval $ac_try) 2>&5
2002 ac_status=$?
2003 echo "$as_me:2003: \$? = $ac_status" >&5
2004 (exit "$ac_status"); }; }; then
2005 CLANG_COMPILER=yes
2006
2007 else
2008 echo "$as_me: failed program was:" >&5
2009 cat "conftest.$ac_ext" >&5
2010 fi
2011 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
2012 CFLAGS="$cf_save_CFLAGS"
2013 echo "$as_me:2013: result: $CLANG_COMPILER" >&5
2014 echo "${ECHO_T}$CLANG_COMPILER" >&6
2015 fi
2016
2017 CLANG_VERSION=none
2018
2019 if test "x$CLANG_COMPILER" = "xyes" ; then
2020 case "$CC" in
2021 (c[1-9][0-9]|*/c[1-9][0-9])
2022 { echo "$as_me:2022: WARNING: replacing broken compiler alias $CC" >&5
2023 echo "$as_me: WARNING: replacing broken compiler alias $CC" >&2;}
2024 CFLAGS="$CFLAGS -std=`echo "$CC" | sed -e 's%.*/%%'`"
2025 CC=clang
2026 ;;
2027 esac
2028
2029 echo "$as_me:2029: checking version of $CC" >&5
2030 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
2031 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.].*//'`"
2032 test -z "$CLANG_VERSION" && CLANG_VERSION=unknown
2033 echo "$as_me:2033: result: $CLANG_VERSION" >&5
2034 echo "${ECHO_T}$CLANG_VERSION" >&6
2035
2036 for cf_clang_opt in \
2037 -Qunused-arguments \
2038 -Wno-error=implicit-function-declaration
2039 do
2040 echo "$as_me:2040: checking if option $cf_clang_opt works" >&5
2041 echo $ECHO_N "checking if option $cf_clang_opt works... $ECHO_C" >&6
2042 cf_save_CFLAGS="$CFLAGS"
2043 CFLAGS="$CFLAGS $cf_clang_opt"
2044 cat >"conftest.$ac_ext" <<_ACEOF
2045 #line 2045 "configure"
2046 #include "confdefs.h"
2047
2048 #include <stdio.h>
2049 int
2050 main (void)
2051 {
2052
2053 printf("hello!\\n");
2054 ;
2055 return 0;
2056 }
2057 _ACEOF
2058 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
2059 if { (eval echo "$as_me:2059: \"$ac_link\"") >&5
2060 (eval $ac_link) 2>&5
2061 ac_status=$?
2062 echo "$as_me:2062: \$? = $ac_status" >&5
2063 (exit "$ac_status"); } &&
2064 { ac_try='test -s "conftest$ac_exeext"'
2065 { (eval echo "$as_me:2065: \"$ac_try\"") >&5
2066 (eval $ac_try) 2>&5
2067 ac_status=$?
2068 echo "$as_me:2068: \$? = $ac_status" >&5
2069 (exit "$ac_status"); }; }; then
2070
2071 cf_clang_optok=yes
2072 else
2073 echo "$as_me: failed program was:" >&5
2074 cat "conftest.$ac_ext" >&5
2075
2076 cf_clang_optok=no
2077 fi
2078 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
2079 echo "$as_me:2079: result: $cf_clang_optok" >&5
2080 echo "${ECHO_T}$cf_clang_optok" >&6
2081 CFLAGS="$cf_save_CFLAGS"
2082 if test "$cf_clang_optok" = yes; then
2083 test -n "$verbose" && echo " adding option $cf_clang_opt" 1>&6
2084
2085 echo "${as_me:-configure}:2085: testing adding option $cf_clang_opt ..." 1>&5
2086
2087 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2088 CFLAGS="${CFLAGS}$cf_clang_opt"
2089
2090 fi
2091 done
2092 fi
2093
2094 echo "$as_me:2094: checking for $CC option to accept ANSI C" >&5
2095 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2096 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2097 echo $ECHO_N "(cached) $ECHO_C" >&6
2098 else
2099 ac_cv_prog_cc_stdc=no
2100 ac_save_CC=$CC
2101 cat >"conftest.$ac_ext" <<_ACEOF
2102 #line 2102 "configure"
2103 #include "confdefs.h"
2104 #include <stdarg.h>
2105 #include <stdio.h>
2106 #include <sys/types.h>
2107 #include <sys/stat.h>
2108 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2109 struct buf { int x; };
2110 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2111 static char *e (char **p, int i)
2112 {
2113 return p[i];
2114 }
2115 static char *f (char * (*g) (char **, int), char **p, ...)
2116 {
2117 char *s;
2118 va_list v;
2119 va_start (v,p);
2120 s = g (p, va_arg (v,int));
2121 va_end (v);
2122 return s;
2123 }
2124 int test (int i, double x);
2125 struct s1 {int (*f) (int a);};
2126 struct s2 {int (*f) (double a);};
2127 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2128 int argc;
2129 char **argv;
2130 int
2131 main (void)
2132 {
2133 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2134 ;
2135 return 0;
2136 }
2137 _ACEOF
2138 # Don't try gcc -ansi; that turns off useful extensions and
2139 # breaks some systems' header files.
2140 # AIX -qlanglvl=ansi
2141 # Ultrix and OSF/1 -std1
2142 # HP-UX 10.20 and later -Ae
2143 # HP-UX older versions -Aa -D_HPUX_SOURCE
2144 # SVR4 -Xc -D__EXTENSIONS__
2145 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2146 do
2147 CC="$ac_save_CC $ac_arg"
2148 rm -f "conftest.$ac_objext"
2149 if { (eval echo "$as_me:2149: \"$ac_compile\"") >&5
2150 (eval $ac_compile) 2>&5
2151 ac_status=$?
2152 echo "$as_me:2152: \$? = $ac_status" >&5
2153 (exit "$ac_status"); } &&
2154 { ac_try='test -s "conftest.$ac_objext"'
2155 { (eval echo "$as_me:2155: \"$ac_try\"") >&5
2156 (eval $ac_try) 2>&5
2157 ac_status=$?
2158 echo "$as_me:2158: \$? = $ac_status" >&5
2159 (exit "$ac_status"); }; }; then
2160 ac_cv_prog_cc_stdc=$ac_arg
2161 break
2162 else
2163 echo "$as_me: failed program was:" >&5
2164 cat "conftest.$ac_ext" >&5
2165 fi
2166 rm -f "conftest.$ac_objext"
2167 done
2168 rm -f "conftest.$ac_ext" "conftest.$ac_objext"
2169 CC=$ac_save_CC
2170
2171 fi
2172
2173 case "x$ac_cv_prog_cc_stdc" in
2174 x|xno)
2175 echo "$as_me:2175: result: none needed" >&5
2176 echo "${ECHO_T}none needed" >&6 ;;
2177 *)
2178 echo "$as_me:2178: result: $ac_cv_prog_cc_stdc" >&5
2179 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2180 CC="$CC $ac_cv_prog_cc_stdc" ;;
2181 esac
2182
2183 # This should have been defined by AC_PROG_CC
2184 : "${CC:=cc}"
2185
2186 echo "$as_me:2186: checking \$CFLAGS variable" >&5
2187 echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
2188 case "x$CFLAGS" in
2189 (*-[IUD]*)
2190 echo "$as_me:2190: result: broken" >&5
2191 echo "${ECHO_T}broken" >&6
2192 { echo "$as_me:2192: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
2193 echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
2194 cf_flags="$CFLAGS"
2195 CFLAGS=
2196 for cf_arg in $cf_flags
2197 do
2198
2199 cf_fix_cppflags=no
2200 cf_new_cflags=
2201 cf_new_cppflags=
2202 cf_new_extra_cppflags=
2203
2204 for cf_add_cflags in $cf_arg
2205 do
2206 case "$cf_fix_cppflags" in
2207 (no)
2208 case "$cf_add_cflags" in
2209 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2210 case "$cf_add_cflags" in
2211 (-D*)
2212 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2213
2214 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2215 && test -z "${cf_tst_cflags}" \
2216 && cf_fix_cppflags=yes
2217
2218 if test "$cf_fix_cppflags" = yes ; then
2219
2220 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2221 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2222
2223 continue
2224 elif test "${cf_tst_cflags}" = "\"'" ; then
2225
2226 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2227 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2228
2229 continue
2230 fi
2231 ;;
2232 esac
2233 case "$CPPFLAGS" in
2234 (*$cf_add_cflags)
2235 ;;
2236 (*)
2237 case "$cf_add_cflags" in
2238 (-D*)
2239 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2240
2241 CPPFLAGS=`echo "$CPPFLAGS" | \
2242 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2243 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2244
2245 ;;
2246 esac
2247
2248 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2249 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2250
2251 ;;
2252 esac
2253 ;;
2254 (*)
2255
2256 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2257 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2258
2259 ;;
2260 esac
2261 ;;
2262 (yes)
2263
2264 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2265 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2266
2267 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2268
2269 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2270 && test -z "${cf_tst_cflags}" \
2271 && cf_fix_cppflags=no
2272 ;;
2273 esac
2274 done
2275
2276 if test -n "$cf_new_cflags" ; then
2277
2278 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2279 CFLAGS="${CFLAGS}$cf_new_cflags"
2280
2281 fi
2282
2283 if test -n "$cf_new_cppflags" ; then
2284
2285 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2286 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2287
2288 fi
2289
2290 if test -n "$cf_new_extra_cppflags" ; then
2291
2292 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2293 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2294
2295 fi
2296
2297 done
2298 ;;
2299 (*)
2300 echo "$as_me:2300: result: ok" >&5
2301 echo "${ECHO_T}ok" >&6
2302 ;;
2303 esac
2304
2305 echo "$as_me:2305: checking \$CC variable" >&5
2306 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2307 case "$CC" in
2308 (*[\ \ ]-*)
2309 echo "$as_me:2309: result: broken" >&5
2310 echo "${ECHO_T}broken" >&6
2311 { echo "$as_me:2311: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2312 echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2313 # humor him...
2314 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2315 cf_flags=`echo "$CC" | sed -e "s%^$cf_prog%%"`
2316 CC="$cf_prog"
2317 for cf_arg in $cf_flags
2318 do
2319 case "x$cf_arg" in
2320 (x-[IUDfgOW]*)
2321
2322 cf_fix_cppflags=no
2323 cf_new_cflags=
2324 cf_new_cppflags=
2325 cf_new_extra_cppflags=
2326
2327 for cf_add_cflags in $cf_arg
2328 do
2329 case "$cf_fix_cppflags" in
2330 (no)
2331 case "$cf_add_cflags" in
2332 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2333 case "$cf_add_cflags" in
2334 (-D*)
2335 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2336
2337 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2338 && test -z "${cf_tst_cflags}" \
2339 && cf_fix_cppflags=yes
2340
2341 if test "$cf_fix_cppflags" = yes ; then
2342
2343 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2344 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2345
2346 continue
2347 elif test "${cf_tst_cflags}" = "\"'" ; then
2348
2349 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2350 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2351
2352 continue
2353 fi
2354 ;;
2355 esac
2356 case "$CPPFLAGS" in
2357 (*$cf_add_cflags)
2358 ;;
2359 (*)
2360 case "$cf_add_cflags" in
2361 (-D*)
2362 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2363
2364 CPPFLAGS=`echo "$CPPFLAGS" | \
2365 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2366 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2367
2368 ;;
2369 esac
2370
2371 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2372 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2373
2374 ;;
2375 esac
2376 ;;
2377 (*)
2378
2379 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2380 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2381
2382 ;;
2383 esac
2384 ;;
2385 (yes)
2386
2387 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2388 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2389
2390 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2391
2392 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2393 && test -z "${cf_tst_cflags}" \
2394 && cf_fix_cppflags=no
2395 ;;
2396 esac
2397 done
2398
2399 if test -n "$cf_new_cflags" ; then
2400
2401 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2402 CFLAGS="${CFLAGS}$cf_new_cflags"
2403
2404 fi
2405
2406 if test -n "$cf_new_cppflags" ; then
2407
2408 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2409 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2410
2411 fi
2412
2413 if test -n "$cf_new_extra_cppflags" ; then
2414
2415 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2416 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2417
2418 fi
2419
2420 ;;
2421 (*)
2422 CC="$CC $cf_arg"
2423 ;;
2424 esac
2425 done
2426 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2427
2428 echo "${as_me:-configure}:2428: testing resulting CC: '$CC' ..." 1>&5
2429
2430 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2431
2432 echo "${as_me:-configure}:2432: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2433
2434 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2435
2436 echo "${as_me:-configure}:2436: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2437
2438 ;;
2439 (*)
2440 echo "$as_me:2440: result: ok" >&5
2441 echo "${ECHO_T}ok" >&6
2442 ;;
2443 esac
2444
2445 # Find a good install program. We prefer a C program (faster),
2446 # so one script is as good as another. But avoid the broken or
2447 # incompatible versions:
2448 # SysV /etc/install, /usr/sbin/install
2449 # SunOS /usr/etc/install
2450 # IRIX /sbin/install
2451 # AIX /bin/install
2452 # AmigaOS /C/install, which installs bootblocks on floppy discs
2453 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2454 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2455 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2456 # ./install, which can be erroneously created by make from ./install.sh.
2457 echo "$as_me:2457: checking for a BSD compatible install" >&5
2458 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2459 if test -z "$INSTALL"; then
2460 if test "${ac_cv_path_install+set}" = set; then
2461 echo $ECHO_N "(cached) $ECHO_C" >&6
2462 else
2463 ac_save_IFS=$IFS; IFS=$ac_path_separator
2464 for ac_dir in $PATH; do
2465 IFS=$ac_save_IFS
2466 # Account for people who put trailing slashes in PATH elements.
2467 case $ac_dir/ in
2468 / | ./ | .// | /cC/* \
2469 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2470 | /usr/ucb/* ) ;;
2471 *)
2472 # OSF1 and SCO ODT 3.0 have their own names for install.
2473 # Don't use installbsd from OSF since it installs stuff as root
2474 # by default.
2475 for ac_prog in ginstall scoinst install; do
2476 if $as_executable_p "$ac_dir/$ac_prog"; then
2477 if test $ac_prog = install &&
2478 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2479 # AIX install. It has an incompatible calling convention.
2480 :
2481 elif test $ac_prog = install &&
2482 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
2483 # program-specific install script used by HP pwplus--don't use.
2484 :
2485 else
2486 ac_cv_path_install="$ac_dir/$ac_prog -c"
2487 break 2
2488 fi
2489 fi
2490 done
2491 ;;
2492 esac
2493 done
2494
2495 fi
2496 if test "${ac_cv_path_install+set}" = set; then
2497 INSTALL=$ac_cv_path_install
2498 else
2499 # As a last resort, use the slow shell script. We don't cache a
2500 # path for INSTALL within a source directory, because that will
2501 # break other packages using the cache if that directory is
2502 # removed, or if the path is relative.
2503 INSTALL=$ac_install_sh
2504 fi
2505 fi
2506 echo "$as_me:2506: result: $INSTALL" >&5
2507 echo "${ECHO_T}$INSTALL" >&6
2508
2509 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2510 # It thinks the first close brace ends the variable substitution.
2511 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2512
2513 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2514
2515 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2516
2517 echo "$as_me:2517: checking for \".PHONY\" make-support" >&5
2518 echo $ECHO_N "checking for \".PHONY\" make-support... $ECHO_C" >&6
2519 if test "${cf_cv_make_PHONY+set}" = set; then
2520 echo $ECHO_N "(cached) $ECHO_C" >&6
2521 else
2522
2523 rm -rf conftest*
2524 (
2525 mkdir conftest || exit 1
2526 cd conftest
2527 cat >makefile <<'CF_EOF'
2528 .PHONY: always
2529 DATA=0
2530 always: always.out
2531 @echo "** making $@ $(DATA)"
2532 once: once.out
2533 @echo "** making $@ $(DATA)"
2534 always.out:
2535 @echo "** making $@ $(DATA)"
2536 echo $(DATA) > $@
2537 once.out:
2538 @echo "** making $@ $(DATA)"
2539 echo $(DATA) > $@
2540 CF_EOF
2541 for cf_data in 1 2 3
2542 do
2543 ${MAKE:-make} always DATA=$cf_data
2544 ${MAKE:-make} once DATA=$cf_data
2545 ${MAKE:-make} -t always once
2546 if test -f always ; then
2547 echo "no (case 1)" > ../conftest.tmp
2548 elif test ! -f always.out ; then
2549 echo "no (case 2)" > ../conftest.tmp
2550 elif test ! -f once.out ; then
2551 echo "no (case 3)" > ../conftest.tmp
2552 elif ! cmp -s always.out once.out ; then
2553 echo "no (case 4)" > ../conftest.tmp
2554 diff always.out once.out
2555 else
2556 cf_check="`cat always.out`"
2557 if test "x$cf_check" != "x$cf_data" ; then
2558 echo "no (case 5)" > ../conftest.tmp
2559 else
2560 echo yes > ../conftest.tmp
2561 rm -f ./*.out
2562 continue
2563 fi
2564 fi
2565 break
2566 done
2567 ) >&5 2>&1
2568 cf_cv_make_PHONY="`cat conftest.tmp`"
2569 rm -rf conftest*
2570
2571 fi
2572 echo "$as_me:2572: result: $cf_cv_make_PHONY" >&5
2573 echo "${ECHO_T}$cf_cv_make_PHONY" >&6
2574 MAKE_NO_PHONY="#"
2575 MAKE_PHONY="#"
2576 test "x$cf_cv_make_PHONY" = xyes && MAKE_PHONY=
2577 test "x$cf_cv_make_PHONY" != xyes && MAKE_NO_PHONY=
2578
2579 echo "$as_me:2579: checking if filesystem supports mixed-case filenames" >&5
2580 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
2581 if test "${cf_cv_mixedcase+set}" = set; then
2582 echo $ECHO_N "(cached) $ECHO_C" >&6
2583 else
2584
2585 if test "$cross_compiling" = yes ; then
2586 case "$target_alias" in
2587 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*|darwin*)
2588 cf_cv_mixedcase=no
2589 ;;
2590 (*)
2591 cf_cv_mixedcase=yes
2592 ;;
2593 esac
2594 else
2595 rm -f conftest CONFTEST
2596 echo test >conftest
2597 if test -f CONFTEST ; then
2598 cf_cv_mixedcase=no
2599 else
2600 cf_cv_mixedcase=yes
2601 fi
2602 rm -f conftest CONFTEST
2603 fi
2604
2605 fi
2606 echo "$as_me:2606: result: $cf_cv_mixedcase" >&5
2607 echo "${ECHO_T}$cf_cv_mixedcase" >&6
2608 test "$cf_cv_mixedcase" = yes &&
2609 cat >>confdefs.h <<\EOF
2610 #define MIXEDCASE_FILENAMES 1
2611 EOF
2612
2613 for ac_prog in exctags ctags
2614 do
2615 # Extract the first word of "$ac_prog", so it can be a program name with args.
2616 set dummy $ac_prog; ac_word=$2
2617 echo "$as_me:2617: checking for $ac_word" >&5
2618 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2619 if test "${ac_cv_prog_CTAGS+set}" = set; then
2620 echo $ECHO_N "(cached) $ECHO_C" >&6
2621 else
2622 if test -n "$CTAGS"; then
2623 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
2624 else
2625 ac_save_IFS=$IFS; IFS=$ac_path_separator
2626 ac_dummy="$PATH"
2627 for ac_dir in $ac_dummy; do
2628 IFS=$ac_save_IFS
2629 test -z "$ac_dir" && ac_dir=.
2630 $as_executable_p "$ac_dir/$ac_word" || continue
2631 ac_cv_prog_CTAGS="$ac_prog"
2632 echo "$as_me:2632: found $ac_dir/$ac_word" >&5
2633 break
2634 done
2635
2636 fi
2637 fi
2638 CTAGS=$ac_cv_prog_CTAGS
2639 if test -n "$CTAGS"; then
2640 echo "$as_me:2640: result: $CTAGS" >&5
2641 echo "${ECHO_T}$CTAGS" >&6
2642 else
2643 echo "$as_me:2643: result: no" >&5
2644 echo "${ECHO_T}no" >&6
2645 fi
2646
2647 test -n "$CTAGS" && break
2648 done
2649
2650 for ac_prog in exetags etags
2651 do
2652 # Extract the first word of "$ac_prog", so it can be a program name with args.
2653 set dummy $ac_prog; ac_word=$2
2654 echo "$as_me:2654: checking for $ac_word" >&5
2655 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2656 if test "${ac_cv_prog_ETAGS+set}" = set; then
2657 echo $ECHO_N "(cached) $ECHO_C" >&6
2658 else
2659 if test -n "$ETAGS"; then
2660 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
2661 else
2662 ac_save_IFS=$IFS; IFS=$ac_path_separator
2663 ac_dummy="$PATH"
2664 for ac_dir in $ac_dummy; do
2665 IFS=$ac_save_IFS
2666 test -z "$ac_dir" && ac_dir=.
2667 $as_executable_p "$ac_dir/$ac_word" || continue
2668 ac_cv_prog_ETAGS="$ac_prog"
2669 echo "$as_me:2669: found $ac_dir/$ac_word" >&5
2670 break
2671 done
2672
2673 fi
2674 fi
2675 ETAGS=$ac_cv_prog_ETAGS
2676 if test -n "$ETAGS"; then
2677 echo "$as_me:2677: result: $ETAGS" >&5
2678 echo "${ECHO_T}$ETAGS" >&6
2679 else
2680 echo "$as_me:2680: result: no" >&5
2681 echo "${ECHO_T}no" >&6
2682 fi
2683
2684 test -n "$ETAGS" && break
2685 done
2686
2687 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
2688 set dummy ${CTAGS:-ctags}; ac_word=$2
2689 echo "$as_me:2689: checking for $ac_word" >&5
2690 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2691 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
2692 echo $ECHO_N "(cached) $ECHO_C" >&6
2693 else
2694 if test -n "$MAKE_LOWER_TAGS"; then
2695 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
2696 else
2697 ac_save_IFS=$IFS; IFS=$ac_path_separator
2698 ac_dummy="$PATH"
2699 for ac_dir in $ac_dummy; do
2700 IFS=$ac_save_IFS
2701 test -z "$ac_dir" && ac_dir=.
2702 $as_executable_p "$ac_dir/$ac_word" || continue
2703 ac_cv_prog_MAKE_LOWER_TAGS="yes"
2704 echo "$as_me:2704: found $ac_dir/$ac_word" >&5
2705 break
2706 done
2707
2708 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
2709 fi
2710 fi
2711 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
2712 if test -n "$MAKE_LOWER_TAGS"; then
2713 echo "$as_me:2713: result: $MAKE_LOWER_TAGS" >&5
2714 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
2715 else
2716 echo "$as_me:2716: result: no" >&5
2717 echo "${ECHO_T}no" >&6
2718 fi
2719
2720 if test "$cf_cv_mixedcase" = yes ; then
2721 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
2722 set dummy ${ETAGS:-etags}; ac_word=$2
2723 echo "$as_me:2723: checking for $ac_word" >&5
2724 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2725 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
2726 echo $ECHO_N "(cached) $ECHO_C" >&6
2727 else
2728 if test -n "$MAKE_UPPER_TAGS"; then
2729 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
2730 else
2731 ac_save_IFS=$IFS; IFS=$ac_path_separator
2732 ac_dummy="$PATH"
2733 for ac_dir in $ac_dummy; do
2734 IFS=$ac_save_IFS
2735 test -z "$ac_dir" && ac_dir=.
2736 $as_executable_p "$ac_dir/$ac_word" || continue
2737 ac_cv_prog_MAKE_UPPER_TAGS="yes"
2738 echo "$as_me:2738: found $ac_dir/$ac_word" >&5
2739 break
2740 done
2741
2742 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
2743 fi
2744 fi
2745 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
2746 if test -n "$MAKE_UPPER_TAGS"; then
2747 echo "$as_me:2747: result: $MAKE_UPPER_TAGS" >&5
2748 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
2749 else
2750 echo "$as_me:2750: result: no" >&5
2751 echo "${ECHO_T}no" >&6
2752 fi
2753
2754 else
2755 MAKE_UPPER_TAGS=no
2756 fi
2757
2758 if test "$MAKE_UPPER_TAGS" = yes ; then
2759 MAKE_UPPER_TAGS=
2760 else
2761 MAKE_UPPER_TAGS="#"
2762 fi
2763
2764 if test "$MAKE_LOWER_TAGS" = yes ; then
2765 MAKE_LOWER_TAGS=
2766 else
2767 MAKE_LOWER_TAGS="#"
2768 fi
2769
2770 for ac_prog in lint cppcheck splint
2771 do
2772 # Extract the first word of "$ac_prog", so it can be a program name with args.
2773 set dummy $ac_prog; ac_word=$2
2774 echo "$as_me:2774: checking for $ac_word" >&5
2775 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2776 if test "${ac_cv_prog_LINT+set}" = set; then
2777 echo $ECHO_N "(cached) $ECHO_C" >&6
2778 else
2779 if test -n "$LINT"; then
2780 ac_cv_prog_LINT="$LINT" # Let the user override the test.
2781 else
2782 ac_save_IFS=$IFS; IFS=$ac_path_separator
2783 ac_dummy="$PATH"
2784 for ac_dir in $ac_dummy; do
2785 IFS=$ac_save_IFS
2786 test -z "$ac_dir" && ac_dir=.
2787 $as_executable_p "$ac_dir/$ac_word" || continue
2788 ac_cv_prog_LINT="$ac_prog"
2789 echo "$as_me:2789: found $ac_dir/$ac_word" >&5
2790 break
2791 done
2792
2793 fi
2794 fi
2795 LINT=$ac_cv_prog_LINT
2796 if test -n "$LINT"; then
2797 echo "$as_me:2797: result: $LINT" >&5
2798 echo "${ECHO_T}$LINT" >&6
2799 else
2800 echo "$as_me:2800: result: no" >&5
2801 echo "${ECHO_T}no" >&6
2802 fi
2803
2804 test -n "$LINT" && break
2805 done
2806
2807 case "x$LINT" in
2808 (xlint|x*/lint) # NetBSD 10
2809 test -z "$LINT_OPTS" && LINT_OPTS="-chapbrxzgFS -v -Ac11"
2810 ;;
2811 (xcppcheck|x*/cppcheck)
2812 test -z "$LINT_OPTS" && LINT_OPTS="--enable=all -D__CPPCHECK__"
2813 ;;
2814 esac
2815
2816 # Extract the first word of "groff", so it can be a program name with args.
2817 set dummy groff; ac_word=$2
2818 echo "$as_me:2818: checking for $ac_word" >&5
2819 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2820 if test "${ac_cv_path_GROFF_PATH+set}" = set; then
2821 echo $ECHO_N "(cached) $ECHO_C" >&6
2822 else
2823 case $GROFF_PATH in
2824 [\\/]* | ?:[\\/]*)
2825 ac_cv_path_GROFF_PATH="$GROFF_PATH" # Let the user override the test with a path.
2826 ;;
2827 *)
2828 ac_save_IFS=$IFS; IFS=$ac_path_separator
2829 ac_dummy="$PATH"
2830 for ac_dir in $ac_dummy; do
2831 IFS=$ac_save_IFS
2832 test -z "$ac_dir" && ac_dir=.
2833 if $as_executable_p "$ac_dir/$ac_word"; then
2834 ac_cv_path_GROFF_PATH="$ac_dir/$ac_word"
2835 echo "$as_me:2835: found $ac_dir/$ac_word" >&5
2836 break
2837 fi
2838 done
2839
2840 test -z "$ac_cv_path_GROFF_PATH" && ac_cv_path_GROFF_PATH="no"
2841 ;;
2842 esac
2843 fi
2844 GROFF_PATH=$ac_cv_path_GROFF_PATH
2845
2846 if test -n "$GROFF_PATH"; then
2847 echo "$as_me:2847: result: $GROFF_PATH" >&5
2848 echo "${ECHO_T}$GROFF_PATH" >&6
2849 else
2850 echo "$as_me:2850: result: no" >&5
2851 echo "${ECHO_T}no" >&6
2852 fi
2853
2854 for ac_prog in nroff mandoc
2855 do
2856 # Extract the first word of "$ac_prog", so it can be a program name with args.
2857 set dummy $ac_prog; ac_word=$2
2858 echo "$as_me:2858: checking for $ac_word" >&5
2859 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2860 if test "${ac_cv_path_NROFF_PATH+set}" = set; then
2861 echo $ECHO_N "(cached) $ECHO_C" >&6
2862 else
2863 case $NROFF_PATH in
2864 [\\/]* | ?:[\\/]*)
2865 ac_cv_path_NROFF_PATH="$NROFF_PATH" # Let the user override the test with a path.
2866 ;;
2867 *)
2868 ac_save_IFS=$IFS; IFS=$ac_path_separator
2869 ac_dummy="$PATH"
2870 for ac_dir in $ac_dummy; do
2871 IFS=$ac_save_IFS
2872 test -z "$ac_dir" && ac_dir=.
2873 if $as_executable_p "$ac_dir/$ac_word"; then
2874 ac_cv_path_NROFF_PATH="$ac_dir/$ac_word"
2875 echo "$as_me:2875: found $ac_dir/$ac_word" >&5
2876 break
2877 fi
2878 done
2879
2880 ;;
2881 esac
2882 fi
2883 NROFF_PATH=$ac_cv_path_NROFF_PATH
2884
2885 if test -n "$NROFF_PATH"; then
2886 echo "$as_me:2886: result: $NROFF_PATH" >&5
2887 echo "${ECHO_T}$NROFF_PATH" >&6
2888 else
2889 echo "$as_me:2889: result: no" >&5
2890 echo "${ECHO_T}no" >&6
2891 fi
2892
2893 test -n "$NROFF_PATH" && break
2894 done
2895 test -n "$NROFF_PATH" || NROFF_PATH="no"
2896
2897 # Extract the first word of "tbl", so it can be a program name with args.
2898 set dummy tbl; ac_word=$2
2899 echo "$as_me:2899: checking for $ac_word" >&5
2900 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2901 if test "${ac_cv_path_TBL_PATH+set}" = set; then
2902 echo $ECHO_N "(cached) $ECHO_C" >&6
2903 else
2904 case $TBL_PATH in
2905 [\\/]* | ?:[\\/]*)
2906 ac_cv_path_TBL_PATH="$TBL_PATH" # Let the user override the test with a path.
2907 ;;
2908 *)
2909 ac_save_IFS=$IFS; IFS=$ac_path_separator
2910 ac_dummy="$PATH"
2911 for ac_dir in $ac_dummy; do
2912 IFS=$ac_save_IFS
2913 test -z "$ac_dir" && ac_dir=.
2914 if $as_executable_p "$ac_dir/$ac_word"; then
2915 ac_cv_path_TBL_PATH="$ac_dir/$ac_word"
2916 echo "$as_me:2916: found $ac_dir/$ac_word" >&5
2917 break
2918 fi
2919 done
2920
2921 test -z "$ac_cv_path_TBL_PATH" && ac_cv_path_TBL_PATH="cat"
2922 ;;
2923 esac
2924 fi
2925 TBL_PATH=$ac_cv_path_TBL_PATH
2926
2927 if test -n "$TBL_PATH"; then
2928 echo "$as_me:2928: result: $TBL_PATH" >&5
2929 echo "${ECHO_T}$TBL_PATH" >&6
2930 else
2931 echo "$as_me:2931: result: no" >&5
2932 echo "${ECHO_T}no" >&6
2933 fi
2934
2935 if test "x$GROFF_PATH" = xno
2936 then
2937 NROFF_NOTE=
2938 GROFF_NOTE="#"
2939 else
2940 NROFF_NOTE="#"
2941 GROFF_NOTE=
2942 fi
2943
2944 for ac_prog in ggrep grep
2945 do
2946 # Extract the first word of "$ac_prog", so it can be a program name with args.
2947 set dummy $ac_prog; ac_word=$2
2948 echo "$as_me:2948: checking for $ac_word" >&5
2949 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2950 if test "${ac_cv_prog_GREP+set}" = set; then
2951 echo $ECHO_N "(cached) $ECHO_C" >&6
2952 else
2953 if test -n "$GREP"; then
2954 ac_cv_prog_GREP="$GREP" # Let the user override the test.
2955 else
2956 ac_save_IFS=$IFS; IFS=$ac_path_separator
2957 ac_dummy="$PATH"
2958 for ac_dir in $ac_dummy; do
2959 IFS=$ac_save_IFS
2960 test -z "$ac_dir" && ac_dir=.
2961 $as_executable_p "$ac_dir/$ac_word" || continue
2962 ac_cv_prog_GREP="$ac_prog"
2963 echo "$as_me:2963: found $ac_dir/$ac_word" >&5
2964 break
2965 done
2966
2967 fi
2968 fi
2969 GREP=$ac_cv_prog_GREP
2970 if test -n "$GREP"; then
2971 echo "$as_me:2971: result: $GREP" >&5
2972 echo "${ECHO_T}$GREP" >&6
2973 else
2974 echo "$as_me:2974: result: no" >&5
2975 echo "${ECHO_T}no" >&6
2976 fi
2977
2978 test -n "$GREP" && break
2979 done
2980 test -n "$GREP" || GREP=": "
2981
2982 echo "$as_me:2982: checking for fgrep" >&5
2983 echo $ECHO_N "checking for fgrep... $ECHO_C" >&6
2984 if test "${ac_cv_path_FGREP+set}" = set; then
2985 echo $ECHO_N "(cached) $ECHO_C" >&6
2986 else
2987 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
2988 then ac_cv_path_FGREP="$GREP -F"
2989 else
2990 for ac_prog in gfgrep fgrep
2991 do
2992 # Extract the first word of "$ac_prog", so it can be a program name with args.
2993 set dummy $ac_prog; ac_word=$2
2994 echo "$as_me:2994: checking for $ac_word" >&5
2995 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2996 if test "${ac_cv_path_FGREP+set}" = set; then
2997 echo $ECHO_N "(cached) $ECHO_C" >&6
2998 else
2999 case $FGREP in
3000 [\\/]* | ?:[\\/]*)
3001 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
3002 ;;
3003 *)
3004 ac_save_IFS=$IFS; IFS=$ac_path_separator
3005 ac_dummy="$PATH"
3006 for ac_dir in $ac_dummy; do
3007 IFS=$ac_save_IFS
3008 test -z "$ac_dir" && ac_dir=.
3009 if $as_executable_p "$ac_dir/$ac_word"; then
3010 ac_cv_path_FGREP="$ac_dir/$ac_word"
3011 echo "$as_me:3011: found $ac_dir/$ac_word" >&5
3012 break
3013 fi
3014 done
3015
3016 ;;
3017 esac
3018 fi
3019 FGREP=$ac_cv_path_FGREP
3020
3021 if test -n "$FGREP"; then
3022 echo "$as_me:3022: result: $FGREP" >&5
3023 echo "${ECHO_T}$FGREP" >&6
3024 else
3025 echo "$as_me:3025: result: no" >&5
3026 echo "${ECHO_T}no" >&6
3027 fi
3028
3029 test -n "$FGREP" && break
3030 done
3031 test -n "$FGREP" || FGREP=": "
3032
3033 test "x$ac_cv_path_FGREP" = "x:" && { { echo "$as_me:3033: error: cannot find workable fgrep" >&5
3034 echo "$as_me: error: cannot find workable fgrep" >&2;}
3035 { (exit 1); exit 1; }; }
3036 fi
3037 fi
3038 echo "$as_me:3038: result: $ac_cv_path_FGREP" >&5
3039 echo "${ECHO_T}$ac_cv_path_FGREP" >&6
3040 FGREP="$ac_cv_path_FGREP"
3041
3042 case "$cf_cv_system_name" in
3043 (cygwin*|msys*|mingw32*|mingw64|os2*)
3044 GLOB_FULLPATH_POSIX='/*'
3045 GLOB_FULLPATH_OTHER='[a-zA-Z]:[\\/]*'
3046 ;;
3047 (*)
3048 GLOB_FULLPATH_POSIX='/*'
3049 GLOB_FULLPATH_OTHER=$GLOB_FULLPATH_POSIX
3050 ;;
3051 esac
3052
3053 case "x${with_man2html}" in
3054 (xno)
3055 cf_man2html=no
3056 ;;
3057 (x|xyes)
3058 # Extract the first word of "man2html", so it can be a program name with args.
3059 set dummy man2html; ac_word=$2
3060 echo "$as_me:3060: checking for $ac_word" >&5
3061 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3062 if test "${ac_cv_path_cf_man2html+set}" = set; then
3063 echo $ECHO_N "(cached) $ECHO_C" >&6
3064 else
3065 case $cf_man2html in
3066 [\\/]* | ?:[\\/]*)
3067 ac_cv_path_cf_man2html="$cf_man2html" # Let the user override the test with a path.
3068 ;;
3069 *)
3070 ac_save_IFS=$IFS; IFS=$ac_path_separator
3071 ac_dummy="$PATH"
3072 for ac_dir in $ac_dummy; do
3073 IFS=$ac_save_IFS
3074 test -z "$ac_dir" && ac_dir=.
3075 if $as_executable_p "$ac_dir/$ac_word"; then
3076 ac_cv_path_cf_man2html="$ac_dir/$ac_word"
3077 echo "$as_me:3077: found $ac_dir/$ac_word" >&5
3078 break
3079 fi
3080 done
3081
3082 test -z "$ac_cv_path_cf_man2html" && ac_cv_path_cf_man2html="no"
3083 ;;
3084 esac
3085 fi
3086 cf_man2html=$ac_cv_path_cf_man2html
3087
3088 if test -n "$cf_man2html"; then
3089 echo "$as_me:3089: result: $cf_man2html" >&5
3090 echo "${ECHO_T}$cf_man2html" >&6
3091 else
3092 echo "$as_me:3092: result: no" >&5
3093 echo "${ECHO_T}no" >&6
3094 fi
3095
3096 case "x$cf_man2html" in
3097 (x/*)
3098 echo "$as_me:3098: checking for the modified Earl Hood script" >&5
3099 echo $ECHO_N "checking for the modified Earl Hood script... $ECHO_C" >&6
3100 if ( $cf_man2html -help 2>&1 | grep 'Make an index of headers at the end' >/dev/null )
3101 then
3102 cf_man2html_ok=yes
3103 else
3104 cf_man2html=no
3105 cf_man2html_ok=no
3106 fi
3107 echo "$as_me:3107: result: $cf_man2html_ok" >&5
3108 echo "${ECHO_T}$cf_man2html_ok" >&6
3109 ;;
3110 (*)
3111 cf_man2html=no
3112 ;;
3113 esac
3114 esac
3115
3116 echo "$as_me:3116: checking for program to convert manpage to html" >&5
3117 echo $ECHO_N "checking for program to convert manpage to html... $ECHO_C" >&6
3118
3119 # Check whether --with-man2html or --without-man2html was given.
3120 if test "${with_man2html+set}" = set; then
3121 withval="$with_man2html"
3122 cf_man2html=$withval
3123 else
3124 cf_man2html=$cf_man2html
3125 fi;
3126
3127 cf_with_groff=no
3128
3129 case $cf_man2html in
3130 (yes)
3131 echo "$as_me:3131: result: man2html" >&5
3132 echo "${ECHO_T}man2html" >&6
3133 # Extract the first word of "man2html", so it can be a program name with args.
3134 set dummy man2html; ac_word=$2
3135 echo "$as_me:3135: checking for $ac_word" >&5
3136 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3137 if test "${ac_cv_path_cf_man2html+set}" = set; then
3138 echo $ECHO_N "(cached) $ECHO_C" >&6
3139 else
3140 case $cf_man2html in
3141 [\\/]* | ?:[\\/]*)
3142 ac_cv_path_cf_man2html="$cf_man2html" # Let the user override the test with a path.
3143 ;;
3144 *)
3145 ac_save_IFS=$IFS; IFS=$ac_path_separator
3146 ac_dummy="$PATH"
3147 for ac_dir in $ac_dummy; do
3148 IFS=$ac_save_IFS
3149 test -z "$ac_dir" && ac_dir=.
3150 if $as_executable_p "$ac_dir/$ac_word"; then
3151 ac_cv_path_cf_man2html="$ac_dir/$ac_word"
3152 echo "$as_me:3152: found $ac_dir/$ac_word" >&5
3153 break
3154 fi
3155 done
3156
3157 test -z "$ac_cv_path_cf_man2html" && ac_cv_path_cf_man2html="no"
3158 ;;
3159 esac
3160 fi
3161 cf_man2html=$ac_cv_path_cf_man2html
3162
3163 if test -n "$cf_man2html"; then
3164 echo "$as_me:3164: result: $cf_man2html" >&5
3165 echo "${ECHO_T}$cf_man2html" >&6
3166 else
3167 echo "$as_me:3167: result: no" >&5
3168 echo "${ECHO_T}no" >&6
3169 fi
3170
3171 ;;
3172 (no|groff|*/groff*)
3173 cf_with_groff=yes
3174 cf_man2html=$GROFF_PATH
3175 echo "$as_me:3175: result: $cf_man2html" >&5
3176 echo "${ECHO_T}$cf_man2html" >&6
3177 ;;
3178 (*)
3179 echo "$as_me:3179: result: $cf_man2html" >&5
3180 echo "${ECHO_T}$cf_man2html" >&6
3181 ;;
3182 esac
3183
3184 MAN2HTML_TEMP="man2html.tmp"
3185 cat >$MAN2HTML_TEMP <<CF_EOF
3186 #!$SHELL
3187 # Temporary script generated by CF_WITH_MAN2HTML
3188 # Convert inputs to html, sending result to standard output.
3189 #
3190 # Parameters:
3191 # \${1} = rootname of file to convert
3192 # \${2} = suffix of file to convert, e.g., "1"
3193 # \${3} = macros to use, e.g., "man"
3194 #
3195 ROOT=\$1
3196 TYPE=\$2
3197 MACS=\$3
3198
3199 unset LANG
3200 unset LC_ALL
3201 unset LC_CTYPE
3202 unset LANGUAGE
3203 GROFF_NO_SGR=stupid
3204 export GROFF_NO_SGR
3205
3206 CF_EOF
3207
3208 NROFF_OPTS=
3209 if test "x$cf_with_groff" = xyes
3210 then
3211 MAN2HTML_NOTE="$GROFF_NOTE"
3212 MAN2HTML_PATH="$GROFF_PATH"
3213 cat >>$MAN2HTML_TEMP <<CF_EOF
3214 $SHELL -c "$TBL_PATH \${ROOT}.\${TYPE} | $GROFF_PATH -P -o0 -I\${ROOT}_ -Thtml -\${MACS}"
3215 CF_EOF
3216 else
3217 # disable hyphenation if this is groff
3218 if test "x$GROFF_PATH" != xno
3219 then
3220 echo "$as_me:3220: checking if nroff is really groff" >&5
3221 echo $ECHO_N "checking if nroff is really groff... $ECHO_C" >&6
3222 cf_check_groff="`$NROFF_PATH --version 2>/dev/null | grep groff`"
3223 test -n "$cf_check_groff" && cf_check_groff=yes
3224 test -n "$cf_check_groff" || cf_check_groff=no
3225 echo "$as_me:3225: result: $cf_check_groff" >&5
3226 echo "${ECHO_T}$cf_check_groff" >&6
3227 test "x$cf_check_groff" = xyes && NROFF_OPTS="-rHY=0"
3228 fi
3229 MAN2HTML_NOTE=""
3230
3231 if test "x$prefix" != xNONE; then
3232 cf_path_syntax="$prefix"
3233 else
3234 cf_path_syntax="$ac_default_prefix"
3235 fi
3236
3237 case "x$cf_man2html" in
3238 (x\$\(*\)*|x\'*\'*)
3239 ;;
3240 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
3241 ;;
3242 (x\$\{*prefix\}*|x\$\{*dir\}*)
3243 eval cf_man2html="$cf_man2html"
3244 case "x$cf_man2html" in
3245 (xNONE/*)
3246 cf_man2html=`echo "$cf_man2html" | sed -e s%NONE%$cf_path_syntax%`
3247 ;;
3248 esac
3249 ;;
3250 (xno|xNONE/*)
3251 cf_man2html=`echo "$cf_man2html" | sed -e s%NONE%$cf_path_syntax%`
3252 ;;
3253 (*)
3254 { { echo "$as_me:3254: error: expected a pathname, not \"$cf_man2html\"" >&5
3255 echo "$as_me: error: expected a pathname, not \"$cf_man2html\"" >&2;}
3256 { (exit 1); exit 1; }; }
3257 ;;
3258 esac
3259
3260 MAN2HTML_PATH="$cf_man2html"
3261 echo "$as_me:3261: checking for $cf_man2html top/bottom margins" >&5
3262 echo $ECHO_N "checking for $cf_man2html top/bottom margins... $ECHO_C" >&6
3263
3264 # for this example, expect 3 lines of content, the remainder is head/foot
3265 cat >conftest.in <<CF_EOF
3266 .TH HEAD1 HEAD2 HEAD3 HEAD4 HEAD5
3267 .SH SECTION
3268 MARKER
3269 CF_EOF
3270
3271 LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
3272
3273 cf_man2html_1st="`${FGREP-fgrep} -n MARKER conftest.out |sed -e 's/^[^0-9]*://' -e 's/:.*//'`"
3274 cf_man2html_top=`expr "$cf_man2html_1st" - 2`
3275 cf_man2html_bot="`wc -l conftest.out |sed -e 's/[^0-9]//g'`"
3276 cf_man2html_bot=`expr "$cf_man2html_bot" - 2 - "$cf_man2html_top"`
3277 cf_man2html_top_bot="-topm=$cf_man2html_top -botm=$cf_man2html_bot"
3278
3279 echo "$as_me:3279: result: $cf_man2html_top_bot" >&5
3280 echo "${ECHO_T}$cf_man2html_top_bot" >&6
3281
3282 echo "$as_me:3282: checking for pagesize to use" >&5
3283 echo $ECHO_N "checking for pagesize to use... $ECHO_C" >&6
3284 for cf_block in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
3285 do
3286 cat >>conftest.in <<CF_EOF
3287 .nf
3288 0
3289 1
3290 2
3291 3
3292 4
3293 5
3294 6
3295 7
3296 8
3297 9
3298 CF_EOF
3299 done
3300
3301 LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
3302 cf_man2html_page="`${FGREP-fgrep} -n HEAD1 conftest.out |sed -n '$p' |sed -e 's/^[^0-9]*://' -e 's/:.*//'`"
3303 test -z "$cf_man2html_page" && cf_man2html_page=99999
3304 test "$cf_man2html_page" -gt 100 && cf_man2html_page=99999
3305
3306 rm -rf conftest*
3307 echo "$as_me:3307: result: $cf_man2html_page" >&5
3308 echo "${ECHO_T}$cf_man2html_page" >&6
3309
3310 cat >>$MAN2HTML_TEMP <<CF_EOF
3311 : \${MAN2HTML_PATH=$MAN2HTML_PATH}
3312 MAN2HTML_OPTS="\$MAN2HTML_OPTS -index -title=\"\$ROOT(\$TYPE)\" -compress -pgsize $cf_man2html_page"
3313 case \${TYPE} in
3314 (ms)
3315 $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH -topm=0 -botm=0 \$MAN2HTML_OPTS
3316 ;;
3317 (*)
3318 $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH $cf_man2html_top_bot \$MAN2HTML_OPTS
3319 ;;
3320 esac
3321 CF_EOF
3322 fi
3323
3324 chmod 700 $MAN2HTML_TEMP
3325
3326 echo "$as_me:3326: checking if you want to see long compiling messages" >&5
3327 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
3328
3329 # Check whether --enable-echo or --disable-echo was given.
3330 if test "${enable_echo+set}" = set; then
3331 enableval="$enable_echo"
3332 test "$enableval" != no && enableval=yes
3333 if test "$enableval" != "yes" ; then
3334
3335 ECHO_LT='--silent'
3336 ECHO_LD='@echo linking $@;'
3337 RULE_CC='@echo compiling $<'
3338 SHOW_CC='@echo compiling $@'
3339 ECHO_CC='@'
3340
3341 else
3342
3343 ECHO_LT=''
3344 ECHO_LD=''
3345 RULE_CC=''
3346 SHOW_CC=''
3347 ECHO_CC=''
3348
3349 fi
3350 else
3351 enableval=yes
3352
3353 ECHO_LT=''
3354 ECHO_LD=''
3355 RULE_CC=''
3356 SHOW_CC=''
3357 ECHO_CC=''
3358
3359 fi;
3360 echo "$as_me:3360: result: $enableval" >&5
3361 echo "${ECHO_T}$enableval" >&6
3362
3363 echo "$as_me:3363: checking if you want to use C11 _Noreturn feature" >&5
3364 echo $ECHO_N "checking if you want to use C11 _Noreturn feature... $ECHO_C" >&6
3365
3366 # Check whether --enable-stdnoreturn or --disable-stdnoreturn was given.
3367 if test "${enable_stdnoreturn+set}" = set; then
3368 enableval="$enable_stdnoreturn"
3369 test "$enableval" != yes && enableval=no
3370 if test "$enableval" != "no" ; then
3371 enable_stdnoreturn=yes
3372 else
3373 enable_stdnoreturn=no
3374 fi
3375 else
3376 enableval=no
3377 enable_stdnoreturn=no
3378
3379 fi;
3380 echo "$as_me:3380: result: $enable_stdnoreturn" >&5
3381 echo "${ECHO_T}$enable_stdnoreturn" >&6
3382
3383 if test $enable_stdnoreturn = yes; then
3384 echo "$as_me:3384: checking for C11 _Noreturn feature" >&5
3385 echo $ECHO_N "checking for C11 _Noreturn feature... $ECHO_C" >&6
3386 if test "${cf_cv_c11_noreturn+set}" = set; then
3387 echo $ECHO_N "(cached) $ECHO_C" >&6
3388 else
3389 cat >"conftest.$ac_ext" <<_ACEOF
3390 #line 3390 "configure"
3391 #include "confdefs.h"
3392
3393 $ac_includes_default
3394 #include <stdnoreturn.h>
3395 static _Noreturn void giveup(void) { exit(0); }
3396
3397 int
3398 main (void)
3399 {
3400 if (feof(stdin)) giveup()
3401 ;
3402 return 0;
3403 }
3404 _ACEOF
3405 rm -f "conftest.$ac_objext"
3406 if { (eval echo "$as_me:3406: \"$ac_compile\"") >&5
3407 (eval $ac_compile) 2>&5
3408 ac_status=$?
3409 echo "$as_me:3409: \$? = $ac_status" >&5
3410 (exit "$ac_status"); } &&
3411 { ac_try='test -s "conftest.$ac_objext"'
3412 { (eval echo "$as_me:3412: \"$ac_try\"") >&5
3413 (eval $ac_try) 2>&5
3414 ac_status=$?
3415 echo "$as_me:3415: \$? = $ac_status" >&5
3416 (exit "$ac_status"); }; }; then
3417 cf_cv_c11_noreturn=yes
3418 else
3419 echo "$as_me: failed program was:" >&5
3420 cat "conftest.$ac_ext" >&5
3421 cf_cv_c11_noreturn=no
3422 fi
3423 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3424
3425 fi
3426 echo "$as_me:3426: result: $cf_cv_c11_noreturn" >&5
3427 echo "${ECHO_T}$cf_cv_c11_noreturn" >&6
3428 else
3429 cf_cv_c11_noreturn=no,
3430 fi
3431
3432 if test "$cf_cv_c11_noreturn" = yes; then
3433
3434 cat >>confdefs.h <<\EOF
3435 #define HAVE_STDNORETURN_H 1
3436 EOF
3437
3438 cat >>confdefs.h <<EOF
3439 #define STDC_NORETURN _Noreturn
3440 EOF
3441
3442 HAVE_STDNORETURN_H=1
3443 else
3444 HAVE_STDNORETURN_H=0
3445 fi
3446
3447 if test "$GCC" = yes || test "$GXX" = yes
3448 then
3449
3450 if test "$GCC" = yes || test "$GXX" = yes
3451 then
3452 case $CFLAGS in
3453 (*-Werror=*)
3454 cf_temp_flags=
3455 for cf_temp_scan in $CFLAGS
3456 do
3457 case "x$cf_temp_scan" in
3458 (x-Werror=format*)
3459
3460 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
3461 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
3462
3463 ;;
3464 (x-Werror=*)
3465
3466 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
3467 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
3468
3469 ;;
3470 (*)
3471
3472 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
3473 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
3474
3475 ;;
3476 esac
3477 done
3478 if test "x$CFLAGS" != "x$cf_temp_flags"
3479 then
3480 test -n "$verbose" && echo " repairing CFLAGS: $CFLAGS" 1>&6
3481
3482 echo "${as_me:-configure}:3482: testing repairing CFLAGS: $CFLAGS ..." 1>&5
3483
3484 CFLAGS="$cf_temp_flags"
3485 test -n "$verbose" && echo " ... fixed $CFLAGS" 1>&6
3486
3487 echo "${as_me:-configure}:3487: testing ... fixed $CFLAGS ..." 1>&5
3488
3489 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
3490
3491 echo "${as_me:-configure}:3491: testing ... extra $EXTRA_CFLAGS ..." 1>&5
3492
3493 fi
3494 ;;
3495 esac
3496 fi
3497
3498 if test "$GCC" = yes || test "$GXX" = yes
3499 then
3500 case $CPPFLAGS in
3501 (*-Werror=*)
3502 cf_temp_flags=
3503 for cf_temp_scan in $CPPFLAGS
3504 do
3505 case "x$cf_temp_scan" in
3506 (x-Werror=format*)
3507
3508 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
3509 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
3510
3511 ;;
3512 (x-Werror=*)
3513
3514 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
3515 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
3516
3517 ;;
3518 (*)
3519
3520 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
3521 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
3522
3523 ;;
3524 esac
3525 done
3526 if test "x$CPPFLAGS" != "x$cf_temp_flags"
3527 then
3528 test -n "$verbose" && echo " repairing CPPFLAGS: $CPPFLAGS" 1>&6
3529
3530 echo "${as_me:-configure}:3530: testing repairing CPPFLAGS: $CPPFLAGS ..." 1>&5
3531
3532 CPPFLAGS="$cf_temp_flags"
3533 test -n "$verbose" && echo " ... fixed $CPPFLAGS" 1>&6
3534
3535 echo "${as_me:-configure}:3535: testing ... fixed $CPPFLAGS ..." 1>&5
3536
3537 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
3538
3539 echo "${as_me:-configure}:3539: testing ... extra $EXTRA_CFLAGS ..." 1>&5
3540
3541 fi
3542 ;;
3543 esac
3544 fi
3545
3546 if test "$GCC" = yes || test "$GXX" = yes
3547 then
3548 case $LDFLAGS in
3549 (*-Werror=*)
3550 cf_temp_flags=
3551 for cf_temp_scan in $LDFLAGS
3552 do
3553 case "x$cf_temp_scan" in
3554 (x-Werror=format*)
3555
3556 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
3557 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
3558
3559 ;;
3560 (x-Werror=*)
3561
3562 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
3563 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
3564
3565 ;;
3566 (*)
3567
3568 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
3569 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
3570
3571 ;;
3572 esac
3573 done
3574 if test "x$LDFLAGS" != "x$cf_temp_flags"
3575 then
3576 test -n "$verbose" && echo " repairing LDFLAGS: $LDFLAGS" 1>&6
3577
3578 echo "${as_me:-configure}:3578: testing repairing LDFLAGS: $LDFLAGS ..." 1>&5
3579
3580 LDFLAGS="$cf_temp_flags"
3581 test -n "$verbose" && echo " ... fixed $LDFLAGS" 1>&6
3582
3583 echo "${as_me:-configure}:3583: testing ... fixed $LDFLAGS ..." 1>&5
3584
3585 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
3586
3587 echo "${as_me:-configure}:3587: testing ... extra $EXTRA_CFLAGS ..." 1>&5
3588
3589 fi
3590 ;;
3591 esac
3592 fi
3593
3594 echo "$as_me:3594: checking if you want to turn on gcc warnings" >&5
3595 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
3596
3597 # Check whether --enable-warnings or --disable-warnings was given.
3598 if test "${enable_warnings+set}" = set; then
3599 enableval="$enable_warnings"
3600 test "$enableval" != yes && enableval=no
3601 if test "$enableval" != "no" ; then
3602 enable_warnings=yes
3603 else
3604 enable_warnings=no
3605 fi
3606 else
3607 enableval=no
3608 enable_warnings=no
3609
3610 fi;
3611 echo "$as_me:3611: result: $enable_warnings" >&5
3612 echo "${ECHO_T}$enable_warnings" >&6
3613 if test "$enable_warnings" = "yes"
3614 then
3615
3616 if test "$GCC" = yes || test "$GXX" = yes
3617 then
3618 cat > conftest.i <<EOF
3619 #ifndef GCC_PRINTF
3620 #define GCC_PRINTF 0
3621 #endif
3622 #ifndef GCC_SCANF
3623 #define GCC_SCANF 0
3624 #endif
3625 #ifndef GCC_NORETURN
3626 #define GCC_NORETURN /* nothing */
3627 #endif
3628 #ifndef GCC_UNUSED
3629 #define GCC_UNUSED /* nothing */
3630 #endif
3631 EOF
3632 if test "$GCC" = yes
3633 then
3634 { echo "$as_me:3634: checking for $CC __attribute__ directives..." >&5
3635 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
3636 cat > "conftest.$ac_ext" <<EOF
3637 #line 3637 "${as_me:-configure}"
3638 #include <stdio.h>
3639 #include "confdefs.h"
3640 #include "conftest.h"
3641 #include "conftest.i"
3642 #if GCC_PRINTF
3643 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
3644 #else
3645 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
3646 #endif
3647 #if GCC_SCANF
3648 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
3649 #else
3650 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
3651 #endif
3652 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
3653 extern GCC_NORETURN void oops(char *,...) GCC_PRINTFLIKE(1,2);
3654 extern GCC_NORETURN void foo(void);
3655 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
3656 EOF
3657 cf_printf_attribute=no
3658 cf_scanf_attribute=no
3659 for cf_attribute in scanf printf unused noreturn
3660 do
3661
3662 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
3663
3664 cf_directive="__attribute__(($cf_attribute))"
3665 echo "checking for $CC $cf_directive" 1>&5
3666
3667 case "$cf_attribute" in
3668 (printf)
3669 cf_printf_attribute=yes
3670 cat >conftest.h <<EOF
3671 #define GCC_$cf_ATTRIBUTE 1
3672 EOF
3673 ;;
3674 (scanf)
3675 cf_scanf_attribute=yes
3676 cat >conftest.h <<EOF
3677 #define GCC_$cf_ATTRIBUTE 1
3678 EOF
3679 ;;
3680 (*)
3681 cat >conftest.h <<EOF
3682 #define GCC_$cf_ATTRIBUTE $cf_directive
3683 EOF
3684 ;;
3685 esac
3686
3687 if { (eval echo "$as_me:3687: \"$ac_compile\"") >&5
3688 (eval $ac_compile) 2>&5
3689 ac_status=$?
3690 echo "$as_me:3690: \$? = $ac_status" >&5
3691 (exit "$ac_status"); }; then
3692 test -n "$verbose" && echo "$as_me:3692: result: ... $cf_attribute" >&5
3693 echo "${ECHO_T}... $cf_attribute" >&6
3694 cat conftest.h >>confdefs.h
3695 case "$cf_attribute" in
3696 (noreturn)
3697
3698 cat >>confdefs.h <<EOF
3699 #define GCC_NORETURN $cf_directive
3700 EOF
3701
3702 ;;
3703 (printf)
3704 cf_value='/* nothing */'
3705 if test "$cf_printf_attribute" != no ; then
3706 cf_value='__attribute__((format(printf,fmt,var)))'
3707
3708 cat >>confdefs.h <<\EOF
3709 #define GCC_PRINTF 1
3710 EOF
3711
3712 fi
3713
3714 cat >>confdefs.h <<EOF
3715 #define GCC_PRINTFLIKE(fmt,var) $cf_value
3716 EOF
3717
3718 ;;
3719 (scanf)
3720 cf_value='/* nothing */'
3721 if test "$cf_scanf_attribute" != no ; then
3722 cf_value='__attribute__((format(scanf,fmt,var)))'
3723
3724 cat >>confdefs.h <<\EOF
3725 #define GCC_SCANF 1
3726 EOF
3727
3728 fi
3729
3730 cat >>confdefs.h <<EOF
3731 #define GCC_SCANFLIKE(fmt,var) $cf_value
3732 EOF
3733
3734 ;;
3735 (unused)
3736
3737 cat >>confdefs.h <<EOF
3738 #define GCC_UNUSED $cf_directive
3739 EOF
3740
3741 ;;
3742 esac
3743 fi
3744 done
3745 else
3746 ${FGREP-fgrep} define conftest.i >>confdefs.h
3747 fi
3748 rm -rf ./conftest*
3749 fi
3750
3751 if test "x$have_x" = xyes; then echo "skipping X-const check"; fi
3752 cat > "conftest.$ac_ext" <<EOF
3753 #line 3753 "${as_me:-configure}"
3754 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
3755 EOF
3756 if test "$INTEL_COMPILER" = yes
3757 then
3758 # The "-wdXXX" options suppress warnings:
3759 # remark #1419: external declaration in primary source file
3760 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
3761 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
3762 # remark #193: zero used for undefined preprocessing identifier
3763 # remark #593: variable "curs_sb_left_arrow" was set but never used
3764 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
3765 # remark #869: parameter "tw" was never referenced
3766 # remark #981: operands are evaluated in unspecified order
3767 # warning #279: controlling expression is constant
3768
3769 { echo "$as_me:3769: checking for $CC warning options..." >&5
3770 echo "$as_me: checking for $CC warning options..." >&6;}
3771 cf_save_CFLAGS="$CFLAGS"
3772 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
3773 for cf_opt in \
3774 wd1419 \
3775 wd1683 \
3776 wd1684 \
3777 wd193 \
3778 wd593 \
3779 wd279 \
3780 wd810 \
3781 wd869 \
3782 wd981
3783 do
3784 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
3785 if { (eval echo "$as_me:3785: \"$ac_compile\"") >&5
3786 (eval $ac_compile) 2>&5
3787 ac_status=$?
3788 echo "$as_me:3788: \$? = $ac_status" >&5
3789 (exit "$ac_status"); }; then
3790 test -n "$verbose" && echo "$as_me:3790: result: ... -$cf_opt" >&5
3791 echo "${ECHO_T}... -$cf_opt" >&6
3792 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
3793 fi
3794 done
3795 CFLAGS="$cf_save_CFLAGS"
3796 elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
3797 then
3798 { echo "$as_me:3798: checking for $CC warning options..." >&5
3799 echo "$as_me: checking for $CC warning options..." >&6;}
3800 cf_save_CFLAGS="$CFLAGS"
3801 cf_warn_CONST=""
3802 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
3803 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
3804 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
3805 for cf_opt in W Wall \
3806 Wbad-function-cast \
3807 Wcast-align \
3808 Wcast-qual \
3809 Wdeclaration-after-statement \
3810 Wextra \
3811 Winline \
3812 Wmissing-declarations \
3813 Wmissing-prototypes \
3814 Wnested-externs \
3815 Wpointer-arith \
3816 Wshadow \
3817 Wstrict-prototypes \
3818 Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST
3819 do
3820 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
3821 if { (eval echo "$as_me:3821: \"$ac_compile\"") >&5
3822 (eval $ac_compile) 2>&5
3823 ac_status=$?
3824 echo "$as_me:3824: \$? = $ac_status" >&5
3825 (exit "$ac_status"); }; then
3826 test -n "$verbose" && echo "$as_me:3826: result: ... -$cf_opt" >&5
3827 echo "${ECHO_T}... -$cf_opt" >&6
3828 case "$cf_opt" in
3829 (Winline)
3830 case "$GCC_VERSION" in
3831 ([34].*)
3832 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
3833
3834 echo "${as_me:-configure}:3834: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
3835
3836 continue;;
3837 esac
3838 ;;
3839 (Wpointer-arith)
3840 case "$GCC_VERSION" in
3841 ([12].*)
3842 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
3843
3844 echo "${as_me:-configure}:3844: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
3845
3846 continue;;
3847 esac
3848 ;;
3849 esac
3850 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
3851 fi
3852 done
3853 CFLAGS="$cf_save_CFLAGS"
3854 fi
3855 rm -rf ./conftest*
3856
3857 fi
3858
3859 fi
3860
3861 echo "$as_me:3861: checking if the POSIX test-macros are already defined" >&5
3862 echo $ECHO_N "checking if the POSIX test-macros are already defined... $ECHO_C" >&6
3863 if test "${cf_cv_posix_visible+set}" = set; then
3864 echo $ECHO_N "(cached) $ECHO_C" >&6
3865 else
3866
3867 cat >"conftest.$ac_ext" <<_ACEOF
3868 #line 3868 "configure"
3869 #include "confdefs.h"
3870 #include <stdio.h>
3871 int
3872 main (void)
3873 {
3874
3875 #if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
3876 && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
3877 && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
3878 && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
3879 #error conflicting symbols found
3880 #endif
3881
3882 ;
3883 return 0;
3884 }
3885 _ACEOF
3886 rm -f "conftest.$ac_objext"
3887 if { (eval echo "$as_me:3887: \"$ac_compile\"") >&5
3888 (eval $ac_compile) 2>&5
3889 ac_status=$?
3890 echo "$as_me:3890: \$? = $ac_status" >&5
3891 (exit "$ac_status"); } &&
3892 { ac_try='test -s "conftest.$ac_objext"'
3893 { (eval echo "$as_me:3893: \"$ac_try\"") >&5
3894 (eval $ac_try) 2>&5
3895 ac_status=$?
3896 echo "$as_me:3896: \$? = $ac_status" >&5
3897 (exit "$ac_status"); }; }; then
3898 cf_cv_posix_visible=no
3899 else
3900 echo "$as_me: failed program was:" >&5
3901 cat "conftest.$ac_ext" >&5
3902 cf_cv_posix_visible=yes
3903 fi
3904 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3905
3906 fi
3907 echo "$as_me:3907: result: $cf_cv_posix_visible" >&5
3908 echo "${ECHO_T}$cf_cv_posix_visible" >&6
3909
3910 if test "$cf_cv_posix_visible" = no; then
3911
3912 cf_XOPEN_SOURCE=500
3913 cf_POSIX_C_SOURCE=199506L
3914 cf_xopen_source=
3915
3916 case "$host_os" in
3917 (aix[4-7]*)
3918 cf_xopen_source="-D_ALL_SOURCE"
3919 ;;
3920 (darwin[0-8].*)
3921 cf_xopen_source="-D_APPLE_C_SOURCE"
3922 ;;
3923 (darwin*)
3924 cf_xopen_source="-D_DARWIN_C_SOURCE"
3925 cf_XOPEN_SOURCE=
3926 ;;
3927 (freebsd*|dragonfly*|midnightbsd*)
3928 # 5.x headers associate
3929 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
3930 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
3931 cf_POSIX_C_SOURCE=200112L
3932 cf_XOPEN_SOURCE=600
3933 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3934 ;;
3935 (hpux11*)
3936 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
3937 ;;
3938 (hpux*)
3939 cf_xopen_source="-D_HPUX_SOURCE"
3940 ;;
3941 (irix[56].*)
3942 cf_xopen_source="-D_SGI_SOURCE"
3943 cf_XOPEN_SOURCE=
3944 ;;
3945 (linux*gnu*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin|msys|mingw*|linux*uclibc)
3946
3947 cf_gnu_xopen_source=$cf_XOPEN_SOURCE
3948
3949 echo "$as_me:3949: checking if this is the GNU C library" >&5
3950 echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
3951 if test "${cf_cv_gnu_library+set}" = set; then
3952 echo $ECHO_N "(cached) $ECHO_C" >&6
3953 else
3954
3955 cat >"conftest.$ac_ext" <<_ACEOF
3956 #line 3956 "configure"
3957 #include "confdefs.h"
3958 #include <sys/types.h>
3959 int
3960 main (void)
3961 {
3962
3963 #if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
3964 return 0;
3965 #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
3966 return 0;
3967 #else
3968 # error not GNU C library
3969 #endif
3970 ;
3971 return 0;
3972 }
3973 _ACEOF
3974 rm -f "conftest.$ac_objext"
3975 if { (eval echo "$as_me:3975: \"$ac_compile\"") >&5
3976 (eval $ac_compile) 2>&5
3977 ac_status=$?
3978 echo "$as_me:3978: \$? = $ac_status" >&5
3979 (exit "$ac_status"); } &&
3980 { ac_try='test -s "conftest.$ac_objext"'
3981 { (eval echo "$as_me:3981: \"$ac_try\"") >&5
3982 (eval $ac_try) 2>&5
3983 ac_status=$?
3984 echo "$as_me:3984: \$? = $ac_status" >&5
3985 (exit "$ac_status"); }; }; then
3986 cf_cv_gnu_library=yes
3987 else
3988 echo "$as_me: failed program was:" >&5
3989 cat "conftest.$ac_ext" >&5
3990 cf_cv_gnu_library=no
3991 fi
3992 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3993
3994 fi
3995 echo "$as_me:3995: result: $cf_cv_gnu_library" >&5
3996 echo "${ECHO_T}$cf_cv_gnu_library" >&6
3997
3998 if test x$cf_cv_gnu_library = xyes; then
3999
4000 # With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
4001 # was changed to help a little. newlib incorporated the change about 4
4002 # years later.
4003 echo "$as_me:4003: checking if _DEFAULT_SOURCE can be used as a basis" >&5
4004 echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
4005 if test "${cf_cv_gnu_library_219+set}" = set; then
4006 echo $ECHO_N "(cached) $ECHO_C" >&6
4007 else
4008
4009 cf_save="$CPPFLAGS"
4010
4011 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4012 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
4013
4014 cat >"conftest.$ac_ext" <<_ACEOF
4015 #line 4015 "configure"
4016 #include "confdefs.h"
4017 #include <sys/types.h>
4018 int
4019 main (void)
4020 {
4021
4022 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
4023 return 0;
4024 #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
4025 return 0;
4026 #else
4027 # error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
4028 #endif
4029 ;
4030 return 0;
4031 }
4032 _ACEOF
4033 rm -f "conftest.$ac_objext"
4034 if { (eval echo "$as_me:4034: \"$ac_compile\"") >&5
4035 (eval $ac_compile) 2>&5
4036 ac_status=$?
4037 echo "$as_me:4037: \$? = $ac_status" >&5
4038 (exit "$ac_status"); } &&
4039 { ac_try='test -s "conftest.$ac_objext"'
4040 { (eval echo "$as_me:4040: \"$ac_try\"") >&5
4041 (eval $ac_try) 2>&5
4042 ac_status=$?
4043 echo "$as_me:4043: \$? = $ac_status" >&5
4044 (exit "$ac_status"); }; }; then
4045 cf_cv_gnu_library_219=yes
4046 else
4047 echo "$as_me: failed program was:" >&5
4048 cat "conftest.$ac_ext" >&5
4049 cf_cv_gnu_library_219=no
4050 fi
4051 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4052 CPPFLAGS="$cf_save"
4053
4054 fi
4055 echo "$as_me:4055: result: $cf_cv_gnu_library_219" >&5
4056 echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
4057
4058 if test "x$cf_cv_gnu_library_219" = xyes; then
4059 cf_save="$CPPFLAGS"
4060 echo "$as_me:4060: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
4061 echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
4062 if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
4063 echo $ECHO_N "(cached) $ECHO_C" >&6
4064 else
4065
4066 cf_fix_cppflags=no
4067 cf_new_cflags=
4068 cf_new_cppflags=
4069 cf_new_extra_cppflags=
4070
4071 for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
4072 do
4073 case "$cf_fix_cppflags" in
4074 (no)
4075 case "$cf_add_cflags" in
4076 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4077 case "$cf_add_cflags" in
4078 (-D*)
4079 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4080
4081 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4082 && test -z "${cf_tst_cflags}" \
4083 && cf_fix_cppflags=yes
4084
4085 if test "$cf_fix_cppflags" = yes ; then
4086
4087 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4088 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4089
4090 continue
4091 elif test "${cf_tst_cflags}" = "\"'" ; then
4092
4093 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4094 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4095
4096 continue
4097 fi
4098 ;;
4099 esac
4100 case "$CPPFLAGS" in
4101 (*$cf_add_cflags)
4102 ;;
4103 (*)
4104 case "$cf_add_cflags" in
4105 (-D*)
4106 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4107
4108 CPPFLAGS=`echo "$CPPFLAGS" | \
4109 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4110 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4111
4112 ;;
4113 esac
4114
4115 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4116 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4117
4118 ;;
4119 esac
4120 ;;
4121 (*)
4122
4123 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4124 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4125
4126 ;;
4127 esac
4128 ;;
4129 (yes)
4130
4131 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4132 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4133
4134 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4135
4136 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4137 && test -z "${cf_tst_cflags}" \
4138 && cf_fix_cppflags=no
4139 ;;
4140 esac
4141 done
4142
4143 if test -n "$cf_new_cflags" ; then
4144
4145 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4146 CFLAGS="${CFLAGS}$cf_new_cflags"
4147
4148 fi
4149
4150 if test -n "$cf_new_cppflags" ; then
4151
4152 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4153 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4154
4155 fi
4156
4157 if test -n "$cf_new_extra_cppflags" ; then
4158
4159 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4160 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4161
4162 fi
4163
4164 cat >"conftest.$ac_ext" <<_ACEOF
4165 #line 4165 "configure"
4166 #include "confdefs.h"
4167
4168 #include <limits.h>
4169 #include <sys/types.h>
4170
4171 int
4172 main (void)
4173 {
4174
4175 #if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
4176 return 0;
4177 #else
4178 # error GNU C library is too old
4179 #endif
4180 ;
4181 return 0;
4182 }
4183 _ACEOF
4184 rm -f "conftest.$ac_objext"
4185 if { (eval echo "$as_me:4185: \"$ac_compile\"") >&5
4186 (eval $ac_compile) 2>&5
4187 ac_status=$?
4188 echo "$as_me:4188: \$? = $ac_status" >&5
4189 (exit "$ac_status"); } &&
4190 { ac_try='test -s "conftest.$ac_objext"'
4191 { (eval echo "$as_me:4191: \"$ac_try\"") >&5
4192 (eval $ac_try) 2>&5
4193 ac_status=$?
4194 echo "$as_me:4194: \$? = $ac_status" >&5
4195 (exit "$ac_status"); }; }; then
4196 cf_cv_gnu_dftsrc_219=yes
4197 else
4198 echo "$as_me: failed program was:" >&5
4199 cat "conftest.$ac_ext" >&5
4200 cf_cv_gnu_dftsrc_219=no
4201 fi
4202 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4203
4204 fi
4205 echo "$as_me:4205: result: $cf_cv_gnu_dftsrc_219" >&5
4206 echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
4207 test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
4208 else
4209 cf_cv_gnu_dftsrc_219=maybe
4210 fi
4211
4212 if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
4213
4214 echo "$as_me:4214: checking if we must define _GNU_SOURCE" >&5
4215 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
4216 if test "${cf_cv_gnu_source+set}" = set; then
4217 echo $ECHO_N "(cached) $ECHO_C" >&6
4218 else
4219
4220 cat >"conftest.$ac_ext" <<_ACEOF
4221 #line 4221 "configure"
4222 #include "confdefs.h"
4223 #include <sys/types.h>
4224 int
4225 main (void)
4226 {
4227
4228 #ifndef _XOPEN_SOURCE
4229 #error expected _XOPEN_SOURCE to be defined
4230 #endif
4231 ;
4232 return 0;
4233 }
4234 _ACEOF
4235 rm -f "conftest.$ac_objext"
4236 if { (eval echo "$as_me:4236: \"$ac_compile\"") >&5
4237 (eval $ac_compile) 2>&5
4238 ac_status=$?
4239 echo "$as_me:4239: \$? = $ac_status" >&5
4240 (exit "$ac_status"); } &&
4241 { ac_try='test -s "conftest.$ac_objext"'
4242 { (eval echo "$as_me:4242: \"$ac_try\"") >&5
4243 (eval $ac_try) 2>&5
4244 ac_status=$?
4245 echo "$as_me:4245: \$? = $ac_status" >&5
4246 (exit "$ac_status"); }; }; then
4247 cf_cv_gnu_source=no
4248 else
4249 echo "$as_me: failed program was:" >&5
4250 cat "conftest.$ac_ext" >&5
4251 cf_save="$CPPFLAGS"
4252
4253 cf_fix_cppflags=no
4254 cf_new_cflags=
4255 cf_new_cppflags=
4256 cf_new_extra_cppflags=
4257
4258 for cf_add_cflags in -D_GNU_SOURCE
4259 do
4260 case "$cf_fix_cppflags" in
4261 (no)
4262 case "$cf_add_cflags" in
4263 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4264 case "$cf_add_cflags" in
4265 (-D*)
4266 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4267
4268 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4269 && test -z "${cf_tst_cflags}" \
4270 && cf_fix_cppflags=yes
4271
4272 if test "$cf_fix_cppflags" = yes ; then
4273
4274 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4275 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4276
4277 continue
4278 elif test "${cf_tst_cflags}" = "\"'" ; then
4279
4280 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4281 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4282
4283 continue
4284 fi
4285 ;;
4286 esac
4287 case "$CPPFLAGS" in
4288 (*$cf_add_cflags)
4289 ;;
4290 (*)
4291 case "$cf_add_cflags" in
4292 (-D*)
4293 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4294
4295 CPPFLAGS=`echo "$CPPFLAGS" | \
4296 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4297 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4298
4299 ;;
4300 esac
4301
4302 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4303 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4304
4305 ;;
4306 esac
4307 ;;
4308 (*)
4309
4310 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4311 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4312
4313 ;;
4314 esac
4315 ;;
4316 (yes)
4317
4318 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4319 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4320
4321 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4322
4323 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4324 && test -z "${cf_tst_cflags}" \
4325 && cf_fix_cppflags=no
4326 ;;
4327 esac
4328 done
4329
4330 if test -n "$cf_new_cflags" ; then
4331
4332 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4333 CFLAGS="${CFLAGS}$cf_new_cflags"
4334
4335 fi
4336
4337 if test -n "$cf_new_cppflags" ; then
4338
4339 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4340 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4341
4342 fi
4343
4344 if test -n "$cf_new_extra_cppflags" ; then
4345
4346 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4347 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4348
4349 fi
4350
4351 cat >"conftest.$ac_ext" <<_ACEOF
4352 #line 4352 "configure"
4353 #include "confdefs.h"
4354 #include <sys/types.h>
4355 int
4356 main (void)
4357 {
4358
4359 #ifdef _XOPEN_SOURCE
4360 #error expected _XOPEN_SOURCE to be undefined
4361 #endif
4362 ;
4363 return 0;
4364 }
4365 _ACEOF
4366 rm -f "conftest.$ac_objext"
4367 if { (eval echo "$as_me:4367: \"$ac_compile\"") >&5
4368 (eval $ac_compile) 2>&5
4369 ac_status=$?
4370 echo "$as_me:4370: \$? = $ac_status" >&5
4371 (exit "$ac_status"); } &&
4372 { ac_try='test -s "conftest.$ac_objext"'
4373 { (eval echo "$as_me:4373: \"$ac_try\"") >&5
4374 (eval $ac_try) 2>&5
4375 ac_status=$?
4376 echo "$as_me:4376: \$? = $ac_status" >&5
4377 (exit "$ac_status"); }; }; then
4378 cf_cv_gnu_source=no
4379 else
4380 echo "$as_me: failed program was:" >&5
4381 cat "conftest.$ac_ext" >&5
4382 cf_cv_gnu_source=yes
4383 fi
4384 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4385 CPPFLAGS="$cf_save"
4386
4387 fi
4388 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4389
4390 fi
4391 echo "$as_me:4391: result: $cf_cv_gnu_source" >&5
4392 echo "${ECHO_T}$cf_cv_gnu_source" >&6
4393
4394 if test "$cf_cv_gnu_source" = yes
4395 then
4396 echo "$as_me:4396: checking if we should also define _DEFAULT_SOURCE" >&5
4397 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
4398 if test "${cf_cv_default_source+set}" = set; then
4399 echo $ECHO_N "(cached) $ECHO_C" >&6
4400 else
4401
4402 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4403 CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
4404
4405 cat >"conftest.$ac_ext" <<_ACEOF
4406 #line 4406 "configure"
4407 #include "confdefs.h"
4408 #include <sys/types.h>
4409 int
4410 main (void)
4411 {
4412
4413 #ifdef _DEFAULT_SOURCE
4414 #error expected _DEFAULT_SOURCE to be undefined
4415 #endif
4416 ;
4417 return 0;
4418 }
4419 _ACEOF
4420 rm -f "conftest.$ac_objext"
4421 if { (eval echo "$as_me:4421: \"$ac_compile\"") >&5
4422 (eval $ac_compile) 2>&5
4423 ac_status=$?
4424 echo "$as_me:4424: \$? = $ac_status" >&5
4425 (exit "$ac_status"); } &&
4426 { ac_try='test -s "conftest.$ac_objext"'
4427 { (eval echo "$as_me:4427: \"$ac_try\"") >&5
4428 (eval $ac_try) 2>&5
4429 ac_status=$?
4430 echo "$as_me:4430: \$? = $ac_status" >&5
4431 (exit "$ac_status"); }; }; then
4432 cf_cv_default_source=no
4433 else
4434 echo "$as_me: failed program was:" >&5
4435 cat "conftest.$ac_ext" >&5
4436 cf_cv_default_source=yes
4437 fi
4438 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4439
4440 fi
4441 echo "$as_me:4441: result: $cf_cv_default_source" >&5
4442 echo "${ECHO_T}$cf_cv_default_source" >&6
4443 if test "$cf_cv_default_source" = yes
4444 then
4445
4446 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4447 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
4448
4449 fi
4450 fi
4451 fi
4452
4453 fi
4454
4455 ;;
4456 linux*musl)
4457 cf_xopen_source="-D_BSD_SOURCE"
4458 ;;
4459 (minix*)
4460 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
4461 ;;
4462 (mirbsd*)
4463 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
4464 cf_XOPEN_SOURCE=
4465
4466 if test "$cf_cv_posix_visible" = no; then
4467
4468 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4469
4470 cf_save_CFLAGS="$CFLAGS"
4471 cf_save_CPPFLAGS="$CPPFLAGS"
4472
4473 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4474 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4475 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4476
4477 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4478 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4479 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4480
4481 echo "$as_me:4481: checking if we should define _POSIX_C_SOURCE" >&5
4482 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4483 if test "${cf_cv_posix_c_source+set}" = set; then
4484 echo $ECHO_N "(cached) $ECHO_C" >&6
4485 else
4486
4487 echo "${as_me:-configure}:4487: testing if the symbol is already defined go no further ..." 1>&5
4488
4489 cat >"conftest.$ac_ext" <<_ACEOF
4490 #line 4490 "configure"
4491 #include "confdefs.h"
4492 #include <sys/types.h>
4493 int
4494 main (void)
4495 {
4496
4497 #ifndef _POSIX_C_SOURCE
4498 #error _POSIX_C_SOURCE is not defined
4499 #endif
4500 ;
4501 return 0;
4502 }
4503 _ACEOF
4504 rm -f "conftest.$ac_objext"
4505 if { (eval echo "$as_me:4505: \"$ac_compile\"") >&5
4506 (eval $ac_compile) 2>&5
4507 ac_status=$?
4508 echo "$as_me:4508: \$? = $ac_status" >&5
4509 (exit "$ac_status"); } &&
4510 { ac_try='test -s "conftest.$ac_objext"'
4511 { (eval echo "$as_me:4511: \"$ac_try\"") >&5
4512 (eval $ac_try) 2>&5
4513 ac_status=$?
4514 echo "$as_me:4514: \$? = $ac_status" >&5
4515 (exit "$ac_status"); }; }; then
4516 cf_cv_posix_c_source=no
4517 else
4518 echo "$as_me: failed program was:" >&5
4519 cat "conftest.$ac_ext" >&5
4520 cf_want_posix_source=no
4521 case .$cf_POSIX_C_SOURCE in
4522 (.[12]??*)
4523 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4524 ;;
4525 (.2)
4526 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4527 cf_want_posix_source=yes
4528 ;;
4529 (.*)
4530 cf_want_posix_source=yes
4531 ;;
4532 esac
4533 if test "$cf_want_posix_source" = yes ; then
4534 cat >"conftest.$ac_ext" <<_ACEOF
4535 #line 4535 "configure"
4536 #include "confdefs.h"
4537 #include <sys/types.h>
4538 int
4539 main (void)
4540 {
4541
4542 #ifdef _POSIX_SOURCE
4543 #error _POSIX_SOURCE is defined
4544 #endif
4545 ;
4546 return 0;
4547 }
4548 _ACEOF
4549 rm -f "conftest.$ac_objext"
4550 if { (eval echo "$as_me:4550: \"$ac_compile\"") >&5
4551 (eval $ac_compile) 2>&5
4552 ac_status=$?
4553 echo "$as_me:4553: \$? = $ac_status" >&5
4554 (exit "$ac_status"); } &&
4555 { ac_try='test -s "conftest.$ac_objext"'
4556 { (eval echo "$as_me:4556: \"$ac_try\"") >&5
4557 (eval $ac_try) 2>&5
4558 ac_status=$?
4559 echo "$as_me:4559: \$? = $ac_status" >&5
4560 (exit "$ac_status"); }; }; then
4561 :
4562 else
4563 echo "$as_me: failed program was:" >&5
4564 cat "conftest.$ac_ext" >&5
4565 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4566 fi
4567 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4568 fi
4569
4570 echo "${as_me:-configure}:4570: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4571
4572 CFLAGS="$cf_trim_CFLAGS"
4573 CPPFLAGS="$cf_trim_CPPFLAGS"
4574
4575 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4576 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4577
4578 echo "${as_me:-configure}:4578: testing if the second compile does not leave our definition intact error ..." 1>&5
4579
4580 cat >"conftest.$ac_ext" <<_ACEOF
4581 #line 4581 "configure"
4582 #include "confdefs.h"
4583 #include <sys/types.h>
4584 int
4585 main (void)
4586 {
4587
4588 #ifndef _POSIX_C_SOURCE
4589 #error _POSIX_C_SOURCE is not defined
4590 #endif
4591 ;
4592 return 0;
4593 }
4594 _ACEOF
4595 rm -f "conftest.$ac_objext"
4596 if { (eval echo "$as_me:4596: \"$ac_compile\"") >&5
4597 (eval $ac_compile) 2>&5
4598 ac_status=$?
4599 echo "$as_me:4599: \$? = $ac_status" >&5
4600 (exit "$ac_status"); } &&
4601 { ac_try='test -s "conftest.$ac_objext"'
4602 { (eval echo "$as_me:4602: \"$ac_try\"") >&5
4603 (eval $ac_try) 2>&5
4604 ac_status=$?
4605 echo "$as_me:4605: \$? = $ac_status" >&5
4606 (exit "$ac_status"); }; }; then
4607 :
4608 else
4609 echo "$as_me: failed program was:" >&5
4610 cat "conftest.$ac_ext" >&5
4611 cf_cv_posix_c_source=no
4612 fi
4613 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4614 CFLAGS="$cf_save_CFLAGS"
4615 CPPFLAGS="$cf_save_CPPFLAGS"
4616
4617 fi
4618 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4619
4620 fi
4621 echo "$as_me:4621: result: $cf_cv_posix_c_source" >&5
4622 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4623
4624 if test "$cf_cv_posix_c_source" != no ; then
4625 CFLAGS="$cf_trim_CFLAGS"
4626 CPPFLAGS="$cf_trim_CPPFLAGS"
4627
4628 cf_fix_cppflags=no
4629 cf_new_cflags=
4630 cf_new_cppflags=
4631 cf_new_extra_cppflags=
4632
4633 for cf_add_cflags in $cf_cv_posix_c_source
4634 do
4635 case "$cf_fix_cppflags" in
4636 (no)
4637 case "$cf_add_cflags" in
4638 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4639 case "$cf_add_cflags" in
4640 (-D*)
4641 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4642
4643 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4644 && test -z "${cf_tst_cflags}" \
4645 && cf_fix_cppflags=yes
4646
4647 if test "$cf_fix_cppflags" = yes ; then
4648
4649 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4650 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4651
4652 continue
4653 elif test "${cf_tst_cflags}" = "\"'" ; then
4654
4655 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4656 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4657
4658 continue
4659 fi
4660 ;;
4661 esac
4662 case "$CPPFLAGS" in
4663 (*$cf_add_cflags)
4664 ;;
4665 (*)
4666 case "$cf_add_cflags" in
4667 (-D*)
4668 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4669
4670 CPPFLAGS=`echo "$CPPFLAGS" | \
4671 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4672 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4673
4674 ;;
4675 esac
4676
4677 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4678 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4679
4680 ;;
4681 esac
4682 ;;
4683 (*)
4684
4685 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4686 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4687
4688 ;;
4689 esac
4690 ;;
4691 (yes)
4692
4693 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4694 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4695
4696 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4697
4698 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4699 && test -z "${cf_tst_cflags}" \
4700 && cf_fix_cppflags=no
4701 ;;
4702 esac
4703 done
4704
4705 if test -n "$cf_new_cflags" ; then
4706
4707 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4708 CFLAGS="${CFLAGS}$cf_new_cflags"
4709
4710 fi
4711
4712 if test -n "$cf_new_cppflags" ; then
4713
4714 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4715 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4716
4717 fi
4718
4719 if test -n "$cf_new_extra_cppflags" ; then
4720
4721 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4722 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4723
4724 fi
4725
4726 fi
4727
4728 fi # cf_cv_posix_visible
4729
4730 ;;
4731 (netbsd*)
4732 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
4733 ;;
4734 (openbsd[6-9]*)
4735 # OpenBSD 6.x has broken locale support, both compile-time and runtime.
4736 # see https://www.mail-archive.com/[email protected]/msg13200.html
4737 # Abusing the conformance level is a workaround.
4738 { echo "$as_me:4738: WARNING: this system does not provide usable locale support" >&5
4739 echo "$as_me: WARNING: this system does not provide usable locale support" >&2;}
4740 cf_xopen_source="-D_BSD_SOURCE"
4741 cf_XOPEN_SOURCE=700
4742 ;;
4743 (openbsd[4-5]*)
4744 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
4745 cf_xopen_source="-D_BSD_SOURCE"
4746 cf_XOPEN_SOURCE=600
4747 ;;
4748 (openbsd*)
4749 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
4750 ;;
4751 (osf[45]*)
4752 cf_xopen_source="-D_OSF_SOURCE"
4753 ;;
4754 (nto-qnx*)
4755 cf_xopen_source="-D_QNX_SOURCE"
4756 ;;
4757 (sco*)
4758 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
4759 ;;
4760 (solaris2.*)
4761 cf_xopen_source="-D__EXTENSIONS__"
4762 cf_cv_xopen_source=broken
4763 ;;
4764 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
4765 cf_XOPEN_SOURCE=
4766 cf_POSIX_C_SOURCE=
4767 ;;
4768 (*)
4769
4770 echo "$as_me:4770: checking if we should define _XOPEN_SOURCE" >&5
4771 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4772 if test "${cf_cv_xopen_source+set}" = set; then
4773 echo $ECHO_N "(cached) $ECHO_C" >&6
4774 else
4775
4776 cat >"conftest.$ac_ext" <<_ACEOF
4777 #line 4777 "configure"
4778 #include "confdefs.h"
4779
4780 $ac_includes_default
4781
4782 int
4783 main (void)
4784 {
4785
4786 #ifndef _XOPEN_SOURCE
4787 #error _XOPEN_SOURCE is not defined
4788 #endif
4789
4790 ;
4791 return 0;
4792 }
4793 _ACEOF
4794 rm -f "conftest.$ac_objext"
4795 if { (eval echo "$as_me:4795: \"$ac_compile\"") >&5
4796 (eval $ac_compile) 2>&5
4797 ac_status=$?
4798 echo "$as_me:4798: \$? = $ac_status" >&5
4799 (exit "$ac_status"); } &&
4800 { ac_try='test -s "conftest.$ac_objext"'
4801 { (eval echo "$as_me:4801: \"$ac_try\"") >&5
4802 (eval $ac_try) 2>&5
4803 ac_status=$?
4804 echo "$as_me:4804: \$? = $ac_status" >&5
4805 (exit "$ac_status"); }; }; then
4806 cf_cv_xopen_source=no
4807 else
4808 echo "$as_me: failed program was:" >&5
4809 cat "conftest.$ac_ext" >&5
4810 cf_save="$CPPFLAGS"
4811
4812 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4813 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4814
4815 cat >"conftest.$ac_ext" <<_ACEOF
4816 #line 4816 "configure"
4817 #include "confdefs.h"
4818
4819 $ac_includes_default
4820
4821 int
4822 main (void)
4823 {
4824
4825 #ifndef _XOPEN_SOURCE
4826 #error _XOPEN_SOURCE is not defined
4827 #endif
4828
4829 ;
4830 return 0;
4831 }
4832 _ACEOF
4833 rm -f "conftest.$ac_objext"
4834 if { (eval echo "$as_me:4834: \"$ac_compile\"") >&5
4835 (eval $ac_compile) 2>&5
4836 ac_status=$?
4837 echo "$as_me:4837: \$? = $ac_status" >&5
4838 (exit "$ac_status"); } &&
4839 { ac_try='test -s "conftest.$ac_objext"'
4840 { (eval echo "$as_me:4840: \"$ac_try\"") >&5
4841 (eval $ac_try) 2>&5
4842 ac_status=$?
4843 echo "$as_me:4843: \$? = $ac_status" >&5
4844 (exit "$ac_status"); }; }; then
4845 cf_cv_xopen_source=no
4846 else
4847 echo "$as_me: failed program was:" >&5
4848 cat "conftest.$ac_ext" >&5
4849 cf_cv_xopen_source=$cf_XOPEN_SOURCE
4850 fi
4851 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4852 CPPFLAGS="$cf_save"
4853
4854 fi
4855 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4856
4857 fi
4858 echo "$as_me:4858: result: $cf_cv_xopen_source" >&5
4859 echo "${ECHO_T}$cf_cv_xopen_source" >&6
4860
4861 if test "$cf_cv_xopen_source" != no ; then
4862
4863 CFLAGS=`echo "$CFLAGS" | \
4864 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4865 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4866
4867 CPPFLAGS=`echo "$CPPFLAGS" | \
4868 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4869 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4870
4871 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4872
4873 for cf_add_cflags in $cf_temp_xopen_source
4874 do
4875 case "x$cf_add_cflags" in
4876 (x-[DU]*)
4877
4878 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4879 while true
4880 do
4881 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'`
4882 test "$CFLAGS" != "$cf_old_cflag" || break
4883
4884 CFLAGS="$cf_old_cflag"
4885 done
4886
4887 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4888 while true
4889 do
4890 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'`
4891 test "$CPPFLAGS" != "$cf_old_cflag" || break
4892
4893 CPPFLAGS="$cf_old_cflag"
4894 done
4895
4896 ;;
4897 esac
4898
4899 cf_fix_cppflags=no
4900 cf_new_cflags=
4901 cf_new_cppflags=
4902 cf_new_extra_cppflags=
4903
4904 for cf_add_cflags in $cf_add_cflags
4905 do
4906 case "$cf_fix_cppflags" in
4907 (no)
4908 case "$cf_add_cflags" in
4909 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4910 case "$cf_add_cflags" in
4911 (-D*)
4912 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4913
4914 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4915 && test -z "${cf_tst_cflags}" \
4916 && cf_fix_cppflags=yes
4917
4918 if test "$cf_fix_cppflags" = yes ; then
4919
4920 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4921 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4922
4923 continue
4924 elif test "${cf_tst_cflags}" = "\"'" ; then
4925
4926 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4927 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4928
4929 continue
4930 fi
4931 ;;
4932 esac
4933 case "$CPPFLAGS" in
4934 (*$cf_add_cflags)
4935 ;;
4936 (*)
4937 case "$cf_add_cflags" in
4938 (-D*)
4939 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4940
4941 CPPFLAGS=`echo "$CPPFLAGS" | \
4942 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4943 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4944
4945 ;;
4946 esac
4947
4948 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4949 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4950
4951 ;;
4952 esac
4953 ;;
4954 (*)
4955
4956 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4957 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4958
4959 ;;
4960 esac
4961 ;;
4962 (yes)
4963
4964 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4965 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4966
4967 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4968
4969 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4970 && test -z "${cf_tst_cflags}" \
4971 && cf_fix_cppflags=no
4972 ;;
4973 esac
4974 done
4975
4976 if test -n "$cf_new_cflags" ; then
4977
4978 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4979 CFLAGS="${CFLAGS}$cf_new_cflags"
4980
4981 fi
4982
4983 if test -n "$cf_new_cppflags" ; then
4984
4985 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4986 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4987
4988 fi
4989
4990 if test -n "$cf_new_extra_cppflags" ; then
4991
4992 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4993 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4994
4995 fi
4996
4997 done
4998
4999 fi
5000
5001 cf_save_xopen_cppflags="$CPPFLAGS"
5002
5003 if test "$cf_cv_posix_visible" = no; then
5004
5005 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
5006
5007 cf_save_CFLAGS="$CFLAGS"
5008 cf_save_CPPFLAGS="$CPPFLAGS"
5009
5010 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
5011 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5012 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
5013
5014 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
5015 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5016 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
5017
5018 echo "$as_me:5018: checking if we should define _POSIX_C_SOURCE" >&5
5019 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
5020 if test "${cf_cv_posix_c_source+set}" = set; then
5021 echo $ECHO_N "(cached) $ECHO_C" >&6
5022 else
5023
5024 echo "${as_me:-configure}:5024: testing if the symbol is already defined go no further ..." 1>&5
5025
5026 cat >"conftest.$ac_ext" <<_ACEOF
5027 #line 5027 "configure"
5028 #include "confdefs.h"
5029 #include <sys/types.h>
5030 int
5031 main (void)
5032 {
5033
5034 #ifndef _POSIX_C_SOURCE
5035 #error _POSIX_C_SOURCE is not defined
5036 #endif
5037 ;
5038 return 0;
5039 }
5040 _ACEOF
5041 rm -f "conftest.$ac_objext"
5042 if { (eval echo "$as_me:5042: \"$ac_compile\"") >&5
5043 (eval $ac_compile) 2>&5
5044 ac_status=$?
5045 echo "$as_me:5045: \$? = $ac_status" >&5
5046 (exit "$ac_status"); } &&
5047 { ac_try='test -s "conftest.$ac_objext"'
5048 { (eval echo "$as_me:5048: \"$ac_try\"") >&5
5049 (eval $ac_try) 2>&5
5050 ac_status=$?
5051 echo "$as_me:5051: \$? = $ac_status" >&5
5052 (exit "$ac_status"); }; }; then
5053 cf_cv_posix_c_source=no
5054 else
5055 echo "$as_me: failed program was:" >&5
5056 cat "conftest.$ac_ext" >&5
5057 cf_want_posix_source=no
5058 case .$cf_POSIX_C_SOURCE in
5059 (.[12]??*)
5060 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
5061 ;;
5062 (.2)
5063 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
5064 cf_want_posix_source=yes
5065 ;;
5066 (.*)
5067 cf_want_posix_source=yes
5068 ;;
5069 esac
5070 if test "$cf_want_posix_source" = yes ; then
5071 cat >"conftest.$ac_ext" <<_ACEOF
5072 #line 5072 "configure"
5073 #include "confdefs.h"
5074 #include <sys/types.h>
5075 int
5076 main (void)
5077 {
5078
5079 #ifdef _POSIX_SOURCE
5080 #error _POSIX_SOURCE is defined
5081 #endif
5082 ;
5083 return 0;
5084 }
5085 _ACEOF
5086 rm -f "conftest.$ac_objext"
5087 if { (eval echo "$as_me:5087: \"$ac_compile\"") >&5
5088 (eval $ac_compile) 2>&5
5089 ac_status=$?
5090 echo "$as_me:5090: \$? = $ac_status" >&5
5091 (exit "$ac_status"); } &&
5092 { ac_try='test -s "conftest.$ac_objext"'
5093 { (eval echo "$as_me:5093: \"$ac_try\"") >&5
5094 (eval $ac_try) 2>&5
5095 ac_status=$?
5096 echo "$as_me:5096: \$? = $ac_status" >&5
5097 (exit "$ac_status"); }; }; then
5098 :
5099 else
5100 echo "$as_me: failed program was:" >&5
5101 cat "conftest.$ac_ext" >&5
5102 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
5103 fi
5104 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5105 fi
5106
5107 echo "${as_me:-configure}:5107: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
5108
5109 CFLAGS="$cf_trim_CFLAGS"
5110 CPPFLAGS="$cf_trim_CPPFLAGS"
5111
5112 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5113 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
5114
5115 echo "${as_me:-configure}:5115: testing if the second compile does not leave our definition intact error ..." 1>&5
5116
5117 cat >"conftest.$ac_ext" <<_ACEOF
5118 #line 5118 "configure"
5119 #include "confdefs.h"
5120 #include <sys/types.h>
5121 int
5122 main (void)
5123 {
5124
5125 #ifndef _POSIX_C_SOURCE
5126 #error _POSIX_C_SOURCE is not defined
5127 #endif
5128 ;
5129 return 0;
5130 }
5131 _ACEOF
5132 rm -f "conftest.$ac_objext"
5133 if { (eval echo "$as_me:5133: \"$ac_compile\"") >&5
5134 (eval $ac_compile) 2>&5
5135 ac_status=$?
5136 echo "$as_me:5136: \$? = $ac_status" >&5
5137 (exit "$ac_status"); } &&
5138 { ac_try='test -s "conftest.$ac_objext"'
5139 { (eval echo "$as_me:5139: \"$ac_try\"") >&5
5140 (eval $ac_try) 2>&5
5141 ac_status=$?
5142 echo "$as_me:5142: \$? = $ac_status" >&5
5143 (exit "$ac_status"); }; }; then
5144 :
5145 else
5146 echo "$as_me: failed program was:" >&5
5147 cat "conftest.$ac_ext" >&5
5148 cf_cv_posix_c_source=no
5149 fi
5150 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5151 CFLAGS="$cf_save_CFLAGS"
5152 CPPFLAGS="$cf_save_CPPFLAGS"
5153
5154 fi
5155 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5156
5157 fi
5158 echo "$as_me:5158: result: $cf_cv_posix_c_source" >&5
5159 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
5160
5161 if test "$cf_cv_posix_c_source" != no ; then
5162 CFLAGS="$cf_trim_CFLAGS"
5163 CPPFLAGS="$cf_trim_CPPFLAGS"
5164
5165 cf_fix_cppflags=no
5166 cf_new_cflags=
5167 cf_new_cppflags=
5168 cf_new_extra_cppflags=
5169
5170 for cf_add_cflags in $cf_cv_posix_c_source
5171 do
5172 case "$cf_fix_cppflags" in
5173 (no)
5174 case "$cf_add_cflags" in
5175 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5176 case "$cf_add_cflags" in
5177 (-D*)
5178 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5179
5180 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5181 && test -z "${cf_tst_cflags}" \
5182 && cf_fix_cppflags=yes
5183
5184 if test "$cf_fix_cppflags" = yes ; then
5185
5186 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5187 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5188
5189 continue
5190 elif test "${cf_tst_cflags}" = "\"'" ; then
5191
5192 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5193 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5194
5195 continue
5196 fi
5197 ;;
5198 esac
5199 case "$CPPFLAGS" in
5200 (*$cf_add_cflags)
5201 ;;
5202 (*)
5203 case "$cf_add_cflags" in
5204 (-D*)
5205 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5206
5207 CPPFLAGS=`echo "$CPPFLAGS" | \
5208 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5209 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5210
5211 ;;
5212 esac
5213
5214 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5215 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5216
5217 ;;
5218 esac
5219 ;;
5220 (*)
5221
5222 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5223 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5224
5225 ;;
5226 esac
5227 ;;
5228 (yes)
5229
5230 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5231 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5232
5233 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5234
5235 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5236 && test -z "${cf_tst_cflags}" \
5237 && cf_fix_cppflags=no
5238 ;;
5239 esac
5240 done
5241
5242 if test -n "$cf_new_cflags" ; then
5243
5244 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5245 CFLAGS="${CFLAGS}$cf_new_cflags"
5246
5247 fi
5248
5249 if test -n "$cf_new_cppflags" ; then
5250
5251 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5252 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5253
5254 fi
5255
5256 if test -n "$cf_new_extra_cppflags" ; then
5257
5258 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5259 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5260
5261 fi
5262
5263 fi
5264
5265 fi # cf_cv_posix_visible
5266
5267 # Some of these niche implementations use copy/paste, double-check...
5268 if test "$cf_cv_xopen_source" = no ; then
5269 test -n "$verbose" && echo " checking if _POSIX_C_SOURCE interferes with _XOPEN_SOURCE" 1>&6
5270
5271 echo "${as_me:-configure}:5271: testing checking if _POSIX_C_SOURCE interferes with _XOPEN_SOURCE ..." 1>&5
5272
5273 cat >"conftest.$ac_ext" <<_ACEOF
5274 #line 5274 "configure"
5275 #include "confdefs.h"
5276
5277 $ac_includes_default
5278
5279 int
5280 main (void)
5281 {
5282
5283 #ifndef _XOPEN_SOURCE
5284 #error _XOPEN_SOURCE is not defined
5285 #endif
5286
5287 ;
5288 return 0;
5289 }
5290 _ACEOF
5291 rm -f "conftest.$ac_objext"
5292 if { (eval echo "$as_me:5292: \"$ac_compile\"") >&5
5293 (eval $ac_compile) 2>&5
5294 ac_status=$?
5295 echo "$as_me:5295: \$? = $ac_status" >&5
5296 (exit "$ac_status"); } &&
5297 { ac_try='test -s "conftest.$ac_objext"'
5298 { (eval echo "$as_me:5298: \"$ac_try\"") >&5
5299 (eval $ac_try) 2>&5
5300 ac_status=$?
5301 echo "$as_me:5301: \$? = $ac_status" >&5
5302 (exit "$ac_status"); }; }; then
5303 :
5304 else
5305 echo "$as_me: failed program was:" >&5
5306 cat "conftest.$ac_ext" >&5
5307
5308 { echo "$as_me:5308: WARNING: _POSIX_C_SOURCE definition is not usable" >&5
5309 echo "$as_me: WARNING: _POSIX_C_SOURCE definition is not usable" >&2;}
5310 CPPFLAGS="$cf_save_xopen_cppflags"
5311 fi
5312 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5313 fi
5314 ;;
5315 esac
5316
5317 if test -n "$cf_xopen_source" ; then
5318
5319 for cf_add_cflags in $cf_xopen_source
5320 do
5321 case "x$cf_add_cflags" in
5322 (x-[DU]*)
5323
5324 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5325 while true
5326 do
5327 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'`
5328 test "$CFLAGS" != "$cf_old_cflag" || break
5329 test -n "$verbose" && echo " removing old option $cf_add_cflags from CFLAGS" 1>&6
5330
5331 echo "${as_me:-configure}:5331: testing removing old option $cf_add_cflags from CFLAGS ..." 1>&5
5332
5333 CFLAGS="$cf_old_cflag"
5334 done
5335
5336 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5337 while true
5338 do
5339 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'`
5340 test "$CPPFLAGS" != "$cf_old_cflag" || break
5341 test -n "$verbose" && echo " removing old option $cf_add_cflags from CPPFLAGS" 1>&6
5342
5343 echo "${as_me:-configure}:5343: testing removing old option $cf_add_cflags from CPPFLAGS ..." 1>&5
5344
5345 CPPFLAGS="$cf_old_cflag"
5346 done
5347
5348 ;;
5349 esac
5350
5351 cf_fix_cppflags=no
5352 cf_new_cflags=
5353 cf_new_cppflags=
5354 cf_new_extra_cppflags=
5355
5356 for cf_add_cflags in $cf_add_cflags
5357 do
5358 case "$cf_fix_cppflags" in
5359 (no)
5360 case "$cf_add_cflags" in
5361 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5362 case "$cf_add_cflags" in
5363 (-D*)
5364 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5365
5366 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5367 && test -z "${cf_tst_cflags}" \
5368 && cf_fix_cppflags=yes
5369
5370 if test "$cf_fix_cppflags" = yes ; then
5371
5372 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5373 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5374
5375 continue
5376 elif test "${cf_tst_cflags}" = "\"'" ; then
5377
5378 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5379 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5380
5381 continue
5382 fi
5383 ;;
5384 esac
5385 case "$CPPFLAGS" in
5386 (*$cf_add_cflags)
5387 ;;
5388 (*)
5389 case "$cf_add_cflags" in
5390 (-D*)
5391 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5392
5393 CPPFLAGS=`echo "$CPPFLAGS" | \
5394 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5395 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5396
5397 ;;
5398 esac
5399
5400 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5401 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5402
5403 ;;
5404 esac
5405 ;;
5406 (*)
5407
5408 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5409 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5410
5411 ;;
5412 esac
5413 ;;
5414 (yes)
5415
5416 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5417 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5418
5419 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5420
5421 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5422 && test -z "${cf_tst_cflags}" \
5423 && cf_fix_cppflags=no
5424 ;;
5425 esac
5426 done
5427
5428 if test -n "$cf_new_cflags" ; then
5429 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
5430
5431 echo "${as_me:-configure}:5431: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
5432
5433 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5434 CFLAGS="${CFLAGS}$cf_new_cflags"
5435
5436 fi
5437
5438 if test -n "$cf_new_cppflags" ; then
5439 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
5440
5441 echo "${as_me:-configure}:5441: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
5442
5443 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5444 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5445
5446 fi
5447
5448 if test -n "$cf_new_extra_cppflags" ; then
5449 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
5450
5451 echo "${as_me:-configure}:5451: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
5452
5453 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5454 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5455
5456 fi
5457
5458 done
5459
5460 fi
5461
5462 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
5463 echo "$as_me:5463: checking if _XOPEN_SOURCE really is set" >&5
5464 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
5465 cat >"conftest.$ac_ext" <<_ACEOF
5466 #line 5466 "configure"
5467 #include "confdefs.h"
5468 #include <stdlib.h>
5469 int
5470 main (void)
5471 {
5472
5473 #ifndef _XOPEN_SOURCE
5474 #error _XOPEN_SOURCE is not defined
5475 #endif
5476 ;
5477 return 0;
5478 }
5479 _ACEOF
5480 rm -f "conftest.$ac_objext"
5481 if { (eval echo "$as_me:5481: \"$ac_compile\"") >&5
5482 (eval $ac_compile) 2>&5
5483 ac_status=$?
5484 echo "$as_me:5484: \$? = $ac_status" >&5
5485 (exit "$ac_status"); } &&
5486 { ac_try='test -s "conftest.$ac_objext"'
5487 { (eval echo "$as_me:5487: \"$ac_try\"") >&5
5488 (eval $ac_try) 2>&5
5489 ac_status=$?
5490 echo "$as_me:5490: \$? = $ac_status" >&5
5491 (exit "$ac_status"); }; }; then
5492 cf_XOPEN_SOURCE_set=yes
5493 else
5494 echo "$as_me: failed program was:" >&5
5495 cat "conftest.$ac_ext" >&5
5496 cf_XOPEN_SOURCE_set=no
5497 fi
5498 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5499 echo "$as_me:5499: result: $cf_XOPEN_SOURCE_set" >&5
5500 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
5501 if test "$cf_XOPEN_SOURCE_set" = yes
5502 then
5503 cat >"conftest.$ac_ext" <<_ACEOF
5504 #line 5504 "configure"
5505 #include "confdefs.h"
5506 #include <stdlib.h>
5507 int
5508 main (void)
5509 {
5510
5511 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
5512 #error (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
5513 #endif
5514 ;
5515 return 0;
5516 }
5517 _ACEOF
5518 rm -f "conftest.$ac_objext"
5519 if { (eval echo "$as_me:5519: \"$ac_compile\"") >&5
5520 (eval $ac_compile) 2>&5
5521 ac_status=$?
5522 echo "$as_me:5522: \$? = $ac_status" >&5
5523 (exit "$ac_status"); } &&
5524 { ac_try='test -s "conftest.$ac_objext"'
5525 { (eval echo "$as_me:5525: \"$ac_try\"") >&5
5526 (eval $ac_try) 2>&5
5527 ac_status=$?
5528 echo "$as_me:5528: \$? = $ac_status" >&5
5529 (exit "$ac_status"); }; }; then
5530 cf_XOPEN_SOURCE_set_ok=yes
5531 else
5532 echo "$as_me: failed program was:" >&5
5533 cat "conftest.$ac_ext" >&5
5534 cf_XOPEN_SOURCE_set_ok=no
5535 fi
5536 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5537 if test "$cf_XOPEN_SOURCE_set_ok" = no
5538 then
5539 { echo "$as_me:5539: WARNING: _XOPEN_SOURCE is lower than requested" >&5
5540 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
5541 fi
5542 else
5543
5544 echo "$as_me:5544: checking if we should define _XOPEN_SOURCE" >&5
5545 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
5546 if test "${cf_cv_xopen_source+set}" = set; then
5547 echo $ECHO_N "(cached) $ECHO_C" >&6
5548 else
5549
5550 cat >"conftest.$ac_ext" <<_ACEOF
5551 #line 5551 "configure"
5552 #include "confdefs.h"
5553
5554 $ac_includes_default
5555
5556 int
5557 main (void)
5558 {
5559
5560 #ifndef _XOPEN_SOURCE
5561 #error _XOPEN_SOURCE is not defined
5562 #endif
5563
5564 ;
5565 return 0;
5566 }
5567 _ACEOF
5568 rm -f "conftest.$ac_objext"
5569 if { (eval echo "$as_me:5569: \"$ac_compile\"") >&5
5570 (eval $ac_compile) 2>&5
5571 ac_status=$?
5572 echo "$as_me:5572: \$? = $ac_status" >&5
5573 (exit "$ac_status"); } &&
5574 { ac_try='test -s "conftest.$ac_objext"'
5575 { (eval echo "$as_me:5575: \"$ac_try\"") >&5
5576 (eval $ac_try) 2>&5
5577 ac_status=$?
5578 echo "$as_me:5578: \$? = $ac_status" >&5
5579 (exit "$ac_status"); }; }; then
5580 cf_cv_xopen_source=no
5581 else
5582 echo "$as_me: failed program was:" >&5
5583 cat "conftest.$ac_ext" >&5
5584 cf_save="$CPPFLAGS"
5585
5586 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5587 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
5588
5589 cat >"conftest.$ac_ext" <<_ACEOF
5590 #line 5590 "configure"
5591 #include "confdefs.h"
5592
5593 $ac_includes_default
5594
5595 int
5596 main (void)
5597 {
5598
5599 #ifndef _XOPEN_SOURCE
5600 #error _XOPEN_SOURCE is not defined
5601 #endif
5602
5603 ;
5604 return 0;
5605 }
5606 _ACEOF
5607 rm -f "conftest.$ac_objext"
5608 if { (eval echo "$as_me:5608: \"$ac_compile\"") >&5
5609 (eval $ac_compile) 2>&5
5610 ac_status=$?
5611 echo "$as_me:5611: \$? = $ac_status" >&5
5612 (exit "$ac_status"); } &&
5613 { ac_try='test -s "conftest.$ac_objext"'
5614 { (eval echo "$as_me:5614: \"$ac_try\"") >&5
5615 (eval $ac_try) 2>&5
5616 ac_status=$?
5617 echo "$as_me:5617: \$? = $ac_status" >&5
5618 (exit "$ac_status"); }; }; then
5619 cf_cv_xopen_source=no
5620 else
5621 echo "$as_me: failed program was:" >&5
5622 cat "conftest.$ac_ext" >&5
5623 cf_cv_xopen_source=$cf_XOPEN_SOURCE
5624 fi
5625 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5626 CPPFLAGS="$cf_save"
5627
5628 fi
5629 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5630
5631 fi
5632 echo "$as_me:5632: result: $cf_cv_xopen_source" >&5
5633 echo "${ECHO_T}$cf_cv_xopen_source" >&6
5634
5635 if test "$cf_cv_xopen_source" != no ; then
5636
5637 CFLAGS=`echo "$CFLAGS" | \
5638 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5639 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5640
5641 CPPFLAGS=`echo "$CPPFLAGS" | \
5642 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
5643 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
5644
5645 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
5646
5647 for cf_add_cflags in $cf_temp_xopen_source
5648 do
5649 case "x$cf_add_cflags" in
5650 (x-[DU]*)
5651
5652 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5653 while true
5654 do
5655 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'`
5656 test "$CFLAGS" != "$cf_old_cflag" || break
5657
5658 CFLAGS="$cf_old_cflag"
5659 done
5660
5661 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
5662 while true
5663 do
5664 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'`
5665 test "$CPPFLAGS" != "$cf_old_cflag" || break
5666
5667 CPPFLAGS="$cf_old_cflag"
5668 done
5669
5670 ;;
5671 esac
5672
5673 cf_fix_cppflags=no
5674 cf_new_cflags=
5675 cf_new_cppflags=
5676 cf_new_extra_cppflags=
5677
5678 for cf_add_cflags in $cf_add_cflags
5679 do
5680 case "$cf_fix_cppflags" in
5681 (no)
5682 case "$cf_add_cflags" in
5683 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5684 case "$cf_add_cflags" in
5685 (-D*)
5686 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5687
5688 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5689 && test -z "${cf_tst_cflags}" \
5690 && cf_fix_cppflags=yes
5691
5692 if test "$cf_fix_cppflags" = yes ; then
5693
5694 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5695 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5696
5697 continue
5698 elif test "${cf_tst_cflags}" = "\"'" ; then
5699
5700 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5701 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5702
5703 continue
5704 fi
5705 ;;
5706 esac
5707 case "$CPPFLAGS" in
5708 (*$cf_add_cflags)
5709 ;;
5710 (*)
5711 case "$cf_add_cflags" in
5712 (-D*)
5713 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5714
5715 CPPFLAGS=`echo "$CPPFLAGS" | \
5716 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5717 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5718
5719 ;;
5720 esac
5721
5722 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5723 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5724
5725 ;;
5726 esac
5727 ;;
5728 (*)
5729
5730 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5731 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5732
5733 ;;
5734 esac
5735 ;;
5736 (yes)
5737
5738 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5739 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5740
5741 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5742
5743 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5744 && test -z "${cf_tst_cflags}" \
5745 && cf_fix_cppflags=no
5746 ;;
5747 esac
5748 done
5749
5750 if test -n "$cf_new_cflags" ; then
5751
5752 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5753 CFLAGS="${CFLAGS}$cf_new_cflags"
5754
5755 fi
5756
5757 if test -n "$cf_new_cppflags" ; then
5758
5759 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5760 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5761
5762 fi
5763
5764 if test -n "$cf_new_extra_cppflags" ; then
5765
5766 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5767 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5768
5769 fi
5770
5771 done
5772
5773 fi
5774
5775 fi
5776 fi
5777 fi # cf_cv_posix_visible
5778
5779 ### extra things that we'll substitute in the makefile
5780 echo "$as_me:5780: checking for egrep" >&5
5781 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
5782 if test "${ac_cv_path_EGREP+set}" = set; then
5783 echo $ECHO_N "(cached) $ECHO_C" >&6
5784 else
5785 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5786 then ac_cv_path_EGREP="$GREP -E"
5787 else
5788 for ac_prog in gegrep egrep
5789 do
5790 # Extract the first word of "$ac_prog", so it can be a program name with args.
5791 set dummy $ac_prog; ac_word=$2
5792 echo "$as_me:5792: checking for $ac_word" >&5
5793 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5794 if test "${ac_cv_path_EGREP+set}" = set; then
5795 echo $ECHO_N "(cached) $ECHO_C" >&6
5796 else
5797 case $EGREP in
5798 [\\/]* | ?:[\\/]*)
5799 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
5800 ;;
5801 *)
5802 ac_save_IFS=$IFS; IFS=$ac_path_separator
5803 ac_dummy="$PATH"
5804 for ac_dir in $ac_dummy; do
5805 IFS=$ac_save_IFS
5806 test -z "$ac_dir" && ac_dir=.
5807 if $as_executable_p "$ac_dir/$ac_word"; then
5808 ac_cv_path_EGREP="$ac_dir/$ac_word"
5809 echo "$as_me:5809: found $ac_dir/$ac_word" >&5
5810 break
5811 fi
5812 done
5813
5814 ;;
5815 esac
5816 fi
5817 EGREP=$ac_cv_path_EGREP
5818
5819 if test -n "$EGREP"; then
5820 echo "$as_me:5820: result: $EGREP" >&5
5821 echo "${ECHO_T}$EGREP" >&6
5822 else
5823 echo "$as_me:5823: result: no" >&5
5824 echo "${ECHO_T}no" >&6
5825 fi
5826
5827 test -n "$EGREP" && break
5828 done
5829 test -n "$EGREP" || EGREP=": "
5830
5831 test "x$ac_cv_path_EGREP" = "x:" && { { echo "$as_me:5831: error: cannot find workable egrep" >&5
5832 echo "$as_me: error: cannot find workable egrep" >&2;}
5833 { (exit 1); exit 1; }; }
5834 fi
5835 fi
5836 echo "$as_me:5836: result: $ac_cv_path_EGREP" >&5
5837 echo "${ECHO_T}$ac_cv_path_EGREP" >&6
5838 EGREP="$ac_cv_path_EGREP"
5839
5840 ac_ext=c
5841 ac_cpp='$CPP $CPPFLAGS'
5842 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
5843 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
5844 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5845 ac_main_return="return"
5846 echo "$as_me:5846: checking how to run the C preprocessor" >&5
5847 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
5848 # On Suns, sometimes $CPP names a directory.
5849 if test -n "$CPP" && test -d "$CPP"; then
5850 CPP=
5851 fi
5852 if test -z "$CPP"; then
5853 if test "${ac_cv_prog_CPP+set}" = set; then
5854 echo $ECHO_N "(cached) $ECHO_C" >&6
5855 else
5856 # Double quotes because CPP needs to be expanded
5857 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5858 do
5859 ac_preproc_ok=false
5860 for ac_c_preproc_warn_flag in '' yes
5861 do
5862 # Use a header file that comes with gcc, so configuring glibc
5863 # with a fresh cross-compiler works.
5864 # On the NeXT, cc -E runs the code through the compiler's parser,
5865 # not just through cpp. "Syntax error" is here to catch this case.
5866 cat >"conftest.$ac_ext" <<_ACEOF
5867 #line 5867 "configure"
5868 #include "confdefs.h"
5869 #include <assert.h>
5870 Syntax error
5871 _ACEOF
5872 if { (eval echo "$as_me:5872: \"$ac_cpp "conftest.$ac_ext"\"") >&5
5873 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
5874 ac_status=$?
5875 $EGREP -v '^ *\+' conftest.er1 >conftest.err
5876 rm -f conftest.er1
5877 cat conftest.err >&5
5878 echo "$as_me:5878: \$? = $ac_status" >&5
5879 (exit "$ac_status"); } >/dev/null; then
5880 if test -s conftest.err; then
5881 ac_cpp_err=$ac_c_preproc_warn_flag
5882 else
5883 ac_cpp_err=
5884 fi
5885 else
5886 ac_cpp_err=yes
5887 fi
5888 if test -z "$ac_cpp_err"; then
5889 :
5890 else
5891 echo "$as_me: failed program was:" >&5
5892 cat "conftest.$ac_ext" >&5
5893 # Broken: fails on valid input.
5894 continue
5895 fi
5896 rm -f conftest.err "conftest.$ac_ext"
5897
5898 # OK, works on sane cases. Now check whether non-existent headers
5899 # can be detected and how.
5900 cat >"conftest.$ac_ext" <<_ACEOF
5901 #line 5901 "configure"
5902 #include "confdefs.h"
5903 #include <ac_nonexistent.h>
5904 _ACEOF
5905 if { (eval echo "$as_me:5905: \"$ac_cpp "conftest.$ac_ext"\"") >&5
5906 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
5907 ac_status=$?
5908 $EGREP -v '^ *\+' conftest.er1 >conftest.err
5909 rm -f conftest.er1
5910 cat conftest.err >&5
5911 echo "$as_me:5911: \$? = $ac_status" >&5
5912 (exit "$ac_status"); } >/dev/null; then
5913 if test -s conftest.err; then
5914 ac_cpp_err=$ac_c_preproc_warn_flag
5915 else
5916 ac_cpp_err=
5917 fi
5918 else
5919 ac_cpp_err=yes
5920 fi
5921 if test -z "$ac_cpp_err"; then
5922 # Broken: success on invalid input.
5923 continue
5924 else
5925 echo "$as_me: failed program was:" >&5
5926 cat "conftest.$ac_ext" >&5
5927 # Passes both tests.
5928 ac_preproc_ok=:
5929 break
5930 fi
5931 rm -f conftest.err "conftest.$ac_ext"
5932
5933 done
5934 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5935 rm -f conftest.err "conftest.$ac_ext"
5936 if $ac_preproc_ok; then
5937 break
5938 fi
5939
5940 done
5941 ac_cv_prog_CPP=$CPP
5942
5943 fi
5944 CPP=$ac_cv_prog_CPP
5945 else
5946 ac_cv_prog_CPP=$CPP
5947 fi
5948 echo "$as_me:5948: result: $CPP" >&5
5949 echo "${ECHO_T}$CPP" >&6
5950 ac_preproc_ok=false
5951 for ac_c_preproc_warn_flag in '' yes
5952 do
5953 # Use a header file that comes with gcc, so configuring glibc
5954 # with a fresh cross-compiler works.
5955 # On the NeXT, cc -E runs the code through the compiler's parser,
5956 # not just through cpp. "Syntax error" is here to catch this case.
5957 cat >"conftest.$ac_ext" <<_ACEOF
5958 #line 5958 "configure"
5959 #include "confdefs.h"
5960 #include <assert.h>
5961 Syntax error
5962 _ACEOF
5963 if { (eval echo "$as_me:5963: \"$ac_cpp "conftest.$ac_ext"\"") >&5
5964 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
5965 ac_status=$?
5966 $EGREP -v '^ *\+' conftest.er1 >conftest.err
5967 rm -f conftest.er1
5968 cat conftest.err >&5
5969 echo "$as_me:5969: \$? = $ac_status" >&5
5970 (exit "$ac_status"); } >/dev/null; then
5971 if test -s conftest.err; then
5972 ac_cpp_err=$ac_c_preproc_warn_flag
5973 else
5974 ac_cpp_err=
5975 fi
5976 else
5977 ac_cpp_err=yes
5978 fi
5979 if test -z "$ac_cpp_err"; then
5980 :
5981 else
5982 echo "$as_me: failed program was:" >&5
5983 cat "conftest.$ac_ext" >&5
5984 # Broken: fails on valid input.
5985 continue
5986 fi
5987 rm -f conftest.err "conftest.$ac_ext"
5988
5989 # OK, works on sane cases. Now check whether non-existent headers
5990 # can be detected and how.
5991 cat >"conftest.$ac_ext" <<_ACEOF
5992 #line 5992 "configure"
5993 #include "confdefs.h"
5994 #include <ac_nonexistent.h>
5995 _ACEOF
5996 if { (eval echo "$as_me:5996: \"$ac_cpp "conftest.$ac_ext"\"") >&5
5997 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
5998 ac_status=$?
5999 $EGREP -v '^ *\+' conftest.er1 >conftest.err
6000 rm -f conftest.er1
6001 cat conftest.err >&5
6002 echo "$as_me:6002: \$? = $ac_status" >&5
6003 (exit "$ac_status"); } >/dev/null; then
6004 if test -s conftest.err; then
6005 ac_cpp_err=$ac_c_preproc_warn_flag
6006 else
6007 ac_cpp_err=
6008 fi
6009 else
6010 ac_cpp_err=yes
6011 fi
6012 if test -z "$ac_cpp_err"; then
6013 # Broken: success on invalid input.
6014 continue
6015 else
6016 echo "$as_me: failed program was:" >&5
6017 cat "conftest.$ac_ext" >&5
6018 # Passes both tests.
6019 ac_preproc_ok=:
6020 break
6021 fi
6022 rm -f conftest.err "conftest.$ac_ext"
6023
6024 done
6025 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6026 rm -f conftest.err "conftest.$ac_ext"
6027 if $ac_preproc_ok; then
6028 :
6029 else
6030 { { echo "$as_me:6030: error: C preprocessor \"$CPP\" fails sanity check" >&5
6031 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
6032 { (exit 1); exit 1; }; }
6033 fi
6034
6035 ac_ext=c
6036 ac_cpp='$CPP $CPPFLAGS'
6037 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
6038 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
6039 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6040 ac_main_return="return"
6041
6042 echo "$as_me:6042: checking for ANSI C header files" >&5
6043 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
6044 if test "${ac_cv_header_stdc+set}" = set; then
6045 echo $ECHO_N "(cached) $ECHO_C" >&6
6046 else
6047 cat >"conftest.$ac_ext" <<_ACEOF
6048 #line 6048 "configure"
6049 #include "confdefs.h"
6050 #include <stdlib.h>
6051 #include <stdarg.h>
6052 #include <string.h>
6053 #include <float.h>
6054
6055 _ACEOF
6056 if { (eval echo "$as_me:6056: \"$ac_cpp "conftest.$ac_ext"\"") >&5
6057 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
6058 ac_status=$?
6059 $EGREP -v '^ *\+' conftest.er1 >conftest.err
6060 rm -f conftest.er1
6061 cat conftest.err >&5
6062 echo "$as_me:6062: \$? = $ac_status" >&5
6063 (exit "$ac_status"); } >/dev/null; then
6064 if test -s conftest.err; then
6065 ac_cpp_err=$ac_c_preproc_warn_flag
6066 else
6067 ac_cpp_err=
6068 fi
6069 else
6070 ac_cpp_err=yes
6071 fi
6072 if test -z "$ac_cpp_err"; then
6073 ac_cv_header_stdc=yes
6074 else
6075 echo "$as_me: failed program was:" >&5
6076 cat "conftest.$ac_ext" >&5
6077 ac_cv_header_stdc=no
6078 fi
6079 rm -f conftest.err "conftest.$ac_ext"
6080
6081 if test $ac_cv_header_stdc = yes; then
6082 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6083 cat >"conftest.$ac_ext" <<_ACEOF
6084 #line 6084 "configure"
6085 #include "confdefs.h"
6086 #include <string.h>
6087
6088 _ACEOF
6089 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6090 $EGREP "memchr" >/dev/null 2>&1; then
6091 :
6092 else
6093 ac_cv_header_stdc=no
6094 fi
6095 rm -rf conftest*
6096
6097 fi
6098
6099 if test $ac_cv_header_stdc = yes; then
6100 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6101 cat >"conftest.$ac_ext" <<_ACEOF
6102 #line 6102 "configure"
6103 #include "confdefs.h"
6104 #include <stdlib.h>
6105
6106 _ACEOF
6107 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6108 $EGREP "free" >/dev/null 2>&1; then
6109 :
6110 else
6111 ac_cv_header_stdc=no
6112 fi
6113 rm -rf conftest*
6114
6115 fi
6116
6117 if test $ac_cv_header_stdc = yes; then
6118 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6119 if test "$cross_compiling" = yes; then
6120 :
6121 else
6122 cat >"conftest.$ac_ext" <<_ACEOF
6123 #line 6123 "configure"
6124 #include "confdefs.h"
6125 #include <ctype.h>
6126 #if ((' ' & 0x0FF) == 0x020)
6127 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6128 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6129 #else
6130 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
6131 || ('j' <= (c) && (c) <= 'r') \
6132 || ('s' <= (c) && (c) <= 'z'))
6133 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6134 #endif
6135
6136 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6137 int
6138 main (void)
6139 {
6140 int i;
6141 for (i = 0; i < 256; i++)
6142 if (XOR (islower (i), ISLOWER (i))
6143 || toupper (i) != TOUPPER (i))
6144 $ac_main_return(2);
6145 $ac_main_return (0);
6146 }
6147 _ACEOF
6148 rm -f "conftest$ac_exeext"
6149 if { (eval echo "$as_me:6149: \"$ac_link\"") >&5
6150 (eval $ac_link) 2>&5
6151 ac_status=$?
6152 echo "$as_me:6152: \$? = $ac_status" >&5
6153 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
6154 { (eval echo "$as_me:6154: \"$ac_try\"") >&5
6155 (eval $ac_try) 2>&5
6156 ac_status=$?
6157 echo "$as_me:6157: \$? = $ac_status" >&5
6158 (exit "$ac_status"); }; }; then
6159 :
6160 else
6161 echo "$as_me: program exited with status $ac_status" >&5
6162 echo "$as_me: failed program was:" >&5
6163 cat "conftest.$ac_ext" >&5
6164 ac_cv_header_stdc=no
6165 fi
6166 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
6167 fi
6168 fi
6169 fi
6170 echo "$as_me:6170: result: $ac_cv_header_stdc" >&5
6171 echo "${ECHO_T}$ac_cv_header_stdc" >&6
6172 if test $ac_cv_header_stdc = yes; then
6173
6174 cat >>confdefs.h <<\EOF
6175 #define STDC_HEADERS 1
6176 EOF
6177
6178 fi
6179
6180 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6181
6182 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6183 inttypes.h stdint.h unistd.h
6184 do
6185 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6186 echo "$as_me:6186: checking for $ac_header" >&5
6187 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6188 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6189 echo $ECHO_N "(cached) $ECHO_C" >&6
6190 else
6191 cat >"conftest.$ac_ext" <<_ACEOF
6192 #line 6192 "configure"
6193 #include "confdefs.h"
6194 $ac_includes_default
6195 #include <$ac_header>
6196 _ACEOF
6197 rm -f "conftest.$ac_objext"
6198 if { (eval echo "$as_me:6198: \"$ac_compile\"") >&5
6199 (eval $ac_compile) 2>&5
6200 ac_status=$?
6201 echo "$as_me:6201: \$? = $ac_status" >&5
6202 (exit "$ac_status"); } &&
6203 { ac_try='test -s "conftest.$ac_objext"'
6204 { (eval echo "$as_me:6204: \"$ac_try\"") >&5
6205 (eval $ac_try) 2>&5
6206 ac_status=$?
6207 echo "$as_me:6207: \$? = $ac_status" >&5
6208 (exit "$ac_status"); }; }; then
6209 eval "$as_ac_Header=yes"
6210 else
6211 echo "$as_me: failed program was:" >&5
6212 cat "conftest.$ac_ext" >&5
6213 eval "$as_ac_Header=no"
6214 fi
6215 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6216 fi
6217 echo "$as_me:6217: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
6218 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
6219 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
6220 cat >>confdefs.h <<EOF
6221 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6222 EOF
6223
6224 fi
6225 done
6226
6227 echo "$as_me:6227: checking whether exit is declared" >&5
6228 echo $ECHO_N "checking whether exit is declared... $ECHO_C" >&6
6229 if test "${ac_cv_have_decl_exit+set}" = set; then
6230 echo $ECHO_N "(cached) $ECHO_C" >&6
6231 else
6232 cat >"conftest.$ac_ext" <<_ACEOF
6233 #line 6233 "configure"
6234 #include "confdefs.h"
6235 $ac_includes_default
6236 int
6237 main (void)
6238 {
6239 #ifndef exit
6240 (void) exit;
6241 #endif
6242
6243 ;
6244 return 0;
6245 }
6246 _ACEOF
6247 rm -f "conftest.$ac_objext"
6248 if { (eval echo "$as_me:6248: \"$ac_compile\"") >&5
6249 (eval $ac_compile) 2>&5
6250 ac_status=$?
6251 echo "$as_me:6251: \$? = $ac_status" >&5
6252 (exit "$ac_status"); } &&
6253 { ac_try='test -s "conftest.$ac_objext"'
6254 { (eval echo "$as_me:6254: \"$ac_try\"") >&5
6255 (eval $ac_try) 2>&5
6256 ac_status=$?
6257 echo "$as_me:6257: \$? = $ac_status" >&5
6258 (exit "$ac_status"); }; }; then
6259 ac_cv_have_decl_exit=yes
6260 else
6261 echo "$as_me: failed program was:" >&5
6262 cat "conftest.$ac_ext" >&5
6263 ac_cv_have_decl_exit=no
6264 fi
6265 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6266 fi
6267 echo "$as_me:6267: result: $ac_cv_have_decl_exit" >&5
6268 echo "${ECHO_T}$ac_cv_have_decl_exit" >&6
6269
6270 echo "$as_me:6270: checking return type of signal handlers" >&5
6271 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
6272 if test "${ac_cv_type_signal+set}" = set; then
6273 echo $ECHO_N "(cached) $ECHO_C" >&6
6274 else
6275 cat >"conftest.$ac_ext" <<_ACEOF
6276 #line 6276 "configure"
6277 #include "confdefs.h"
6278 #include <sys/types.h>
6279 #include <signal.h>
6280 #ifdef signal
6281 # undef signal
6282 #endif
6283 extern void (*signal (int, void (*)(int)))(int);
6284
6285 int
6286 main (void)
6287 {
6288 int i = 0; (void) i
6289 ;
6290 return 0;
6291 }
6292 _ACEOF
6293 rm -f "conftest.$ac_objext"
6294 if { (eval echo "$as_me:6294: \"$ac_compile\"") >&5
6295 (eval $ac_compile) 2>&5
6296 ac_status=$?
6297 echo "$as_me:6297: \$? = $ac_status" >&5
6298 (exit "$ac_status"); } &&
6299 { ac_try='test -s "conftest.$ac_objext"'
6300 { (eval echo "$as_me:6300: \"$ac_try\"") >&5
6301 (eval $ac_try) 2>&5
6302 ac_status=$?
6303 echo "$as_me:6303: \$? = $ac_status" >&5
6304 (exit "$ac_status"); }; }; then
6305 ac_cv_type_signal=void
6306 else
6307 echo "$as_me: failed program was:" >&5
6308 cat "conftest.$ac_ext" >&5
6309 ac_cv_type_signal=int
6310 fi
6311 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6312 fi
6313 echo "$as_me:6313: result: $ac_cv_type_signal" >&5
6314 echo "${ECHO_T}$ac_cv_type_signal" >&6
6315
6316 cat >>confdefs.h <<EOF
6317 #define RETSIGTYPE $ac_cv_type_signal
6318 EOF
6319
6320 for ac_header in \
6321 fcntl.h \
6322 ioctl.h \
6323 sgtty.h \
6324 sys/filio.h \
6325 sys/ioctl.h \
6326 termio.h \
6327 termios.h \
6328
6329 do
6330 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6331 echo "$as_me:6331: checking for $ac_header" >&5
6332 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6333 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6334 echo $ECHO_N "(cached) $ECHO_C" >&6
6335 else
6336 cat >"conftest.$ac_ext" <<_ACEOF
6337 #line 6337 "configure"
6338 #include "confdefs.h"
6339 #include <$ac_header>
6340 _ACEOF
6341 if { (eval echo "$as_me:6341: \"$ac_cpp "conftest.$ac_ext"\"") >&5
6342 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
6343 ac_status=$?
6344 $EGREP -v '^ *\+' conftest.er1 >conftest.err
6345 rm -f conftest.er1
6346 cat conftest.err >&5
6347 echo "$as_me:6347: \$? = $ac_status" >&5
6348 (exit "$ac_status"); } >/dev/null; then
6349 if test -s conftest.err; then
6350 ac_cpp_err=$ac_c_preproc_warn_flag
6351 else
6352 ac_cpp_err=
6353 fi
6354 else
6355 ac_cpp_err=yes
6356 fi
6357 if test -z "$ac_cpp_err"; then
6358 eval "$as_ac_Header=yes"
6359 else
6360 echo "$as_me: failed program was:" >&5
6361 cat "conftest.$ac_ext" >&5
6362 eval "$as_ac_Header=no"
6363 fi
6364 rm -f conftest.err "conftest.$ac_ext"
6365 fi
6366 echo "$as_me:6366: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
6367 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
6368 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
6369 cat >>confdefs.h <<EOF
6370 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6371 EOF
6372
6373 fi
6374 done
6375
6376 for ac_func in \
6377 alarm \
6378 rdchk \
6379 tcgetattr \
6380 usleep \
6381 vfprintf \
6382
6383 do
6384 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
6385 echo "$as_me:6385: checking for $ac_func" >&5
6386 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
6387 if eval "test \"\${$as_ac_var+set}\" = set"; then
6388 echo $ECHO_N "(cached) $ECHO_C" >&6
6389 else
6390 cat >"conftest.$ac_ext" <<_ACEOF
6391 #line 6391 "configure"
6392 #include "confdefs.h"
6393 #define $ac_func autoconf_temporary
6394 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6395 #undef $ac_func
6396
6397 #ifdef __cplusplus
6398 extern "C"
6399 #endif
6400
6401 /* We use char because int might match the return type of a gcc2
6402 builtin and then its argument prototype would still apply. */
6403 char $ac_func (void);
6404
6405 int
6406 main (void)
6407 {
6408
6409 /* The GNU C library defines stubs for functions which it implements
6410 to always fail with ENOSYS. Some functions are actually named
6411 something starting with __ and the normal name is an alias. */
6412 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6413 #error found stub for $ac_func
6414 #endif
6415
6416 return $ac_func ();
6417 ;
6418 return 0;
6419 }
6420 _ACEOF
6421 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6422 if { (eval echo "$as_me:6422: \"$ac_link\"") >&5
6423 (eval $ac_link) 2>&5
6424 ac_status=$?
6425 echo "$as_me:6425: \$? = $ac_status" >&5
6426 (exit "$ac_status"); } &&
6427 { ac_try='test -s "conftest$ac_exeext"'
6428 { (eval echo "$as_me:6428: \"$ac_try\"") >&5
6429 (eval $ac_try) 2>&5
6430 ac_status=$?
6431 echo "$as_me:6431: \$? = $ac_status" >&5
6432 (exit "$ac_status"); }; }; then
6433 eval "$as_ac_var=yes"
6434 else
6435 echo "$as_me: failed program was:" >&5
6436 cat "conftest.$ac_ext" >&5
6437 eval "$as_ac_var=no"
6438 fi
6439 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6440 fi
6441 echo "$as_me:6441: result: `eval echo '${'"$as_ac_var"'}'`" >&5
6442 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
6443 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
6444 cat >>confdefs.h <<EOF
6445 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
6446 EOF
6447
6448 fi
6449 done
6450
6451 echo "$as_me:6451: checking for setlocale()" >&5
6452 echo $ECHO_N "checking for setlocale()... $ECHO_C" >&6
6453 if test "${cf_cv_locale+set}" = set; then
6454 echo $ECHO_N "(cached) $ECHO_C" >&6
6455 else
6456
6457 cat >"conftest.$ac_ext" <<_ACEOF
6458 #line 6458 "configure"
6459 #include "confdefs.h"
6460
6461 $ac_includes_default
6462 #include <locale.h>
6463 int
6464 main (void)
6465 {
6466 setlocale(LC_ALL, "")
6467 ;
6468 return 0;
6469 }
6470 _ACEOF
6471 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6472 if { (eval echo "$as_me:6472: \"$ac_link\"") >&5
6473 (eval $ac_link) 2>&5
6474 ac_status=$?
6475 echo "$as_me:6475: \$? = $ac_status" >&5
6476 (exit "$ac_status"); } &&
6477 { ac_try='test -s "conftest$ac_exeext"'
6478 { (eval echo "$as_me:6478: \"$ac_try\"") >&5
6479 (eval $ac_try) 2>&5
6480 ac_status=$?
6481 echo "$as_me:6481: \$? = $ac_status" >&5
6482 (exit "$ac_status"); }; }; then
6483 cf_cv_locale=yes
6484 else
6485 echo "$as_me: failed program was:" >&5
6486 cat "conftest.$ac_ext" >&5
6487 cf_cv_locale=no
6488 fi
6489 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6490
6491 fi
6492
6493 echo "$as_me:6493: result: $cf_cv_locale" >&5
6494 echo "${ECHO_T}$cf_cv_locale" >&6
6495 test "$cf_cv_locale" = yes && {
6496 cat >>confdefs.h <<\EOF
6497 #define LOCALE 1
6498 EOF
6499 }
6500
6501 for ac_func in strerror
6502 do
6503 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
6504 echo "$as_me:6504: checking for $ac_func" >&5
6505 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
6506 if eval "test \"\${$as_ac_var+set}\" = set"; then
6507 echo $ECHO_N "(cached) $ECHO_C" >&6
6508 else
6509 cat >"conftest.$ac_ext" <<_ACEOF
6510 #line 6510 "configure"
6511 #include "confdefs.h"
6512 #define $ac_func autoconf_temporary
6513 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6514 #undef $ac_func
6515
6516 #ifdef __cplusplus
6517 extern "C"
6518 #endif
6519
6520 /* We use char because int might match the return type of a gcc2
6521 builtin and then its argument prototype would still apply. */
6522 char $ac_func (void);
6523
6524 int
6525 main (void)
6526 {
6527
6528 /* The GNU C library defines stubs for functions which it implements
6529 to always fail with ENOSYS. Some functions are actually named
6530 something starting with __ and the normal name is an alias. */
6531 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6532 #error found stub for $ac_func
6533 #endif
6534
6535 return $ac_func ();
6536 ;
6537 return 0;
6538 }
6539 _ACEOF
6540 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6541 if { (eval echo "$as_me:6541: \"$ac_link\"") >&5
6542 (eval $ac_link) 2>&5
6543 ac_status=$?
6544 echo "$as_me:6544: \$? = $ac_status" >&5
6545 (exit "$ac_status"); } &&
6546 { ac_try='test -s "conftest$ac_exeext"'
6547 { (eval echo "$as_me:6547: \"$ac_try\"") >&5
6548 (eval $ac_try) 2>&5
6549 ac_status=$?
6550 echo "$as_me:6550: \$? = $ac_status" >&5
6551 (exit "$ac_status"); }; }; then
6552 eval "$as_ac_var=yes"
6553 else
6554 echo "$as_me: failed program was:" >&5
6555 cat "conftest.$ac_ext" >&5
6556 eval "$as_ac_var=no"
6557 fi
6558 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6559 fi
6560 echo "$as_me:6560: result: `eval echo '${'"$as_ac_var"'}'`" >&5
6561 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
6562 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
6563 cat >>confdefs.h <<EOF
6564 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
6565 EOF
6566 cat >>confdefs.h <<\EOF
6567 #define HAVE_STRERROR 1
6568 EOF
6569
6570 else
6571
6572 echo "$as_me:6572: checking if external sys_nerr is declared" >&5
6573 echo $ECHO_N "checking if external sys_nerr is declared... $ECHO_C" >&6
6574 if test "${cf_cv_dcl_sys_nerr+set}" = set; then
6575 echo $ECHO_N "(cached) $ECHO_C" >&6
6576 else
6577
6578 cat >"conftest.$ac_ext" <<_ACEOF
6579 #line 6579 "configure"
6580 #include "confdefs.h"
6581
6582 $ac_includes_default
6583 #include <errno.h>
6584 int
6585 main (void)
6586 {
6587 int x = (int) sys_nerr; (void)x
6588 ;
6589 return 0;
6590 }
6591 _ACEOF
6592 rm -f "conftest.$ac_objext"
6593 if { (eval echo "$as_me:6593: \"$ac_compile\"") >&5
6594 (eval $ac_compile) 2>&5
6595 ac_status=$?
6596 echo "$as_me:6596: \$? = $ac_status" >&5
6597 (exit "$ac_status"); } &&
6598 { ac_try='test -s "conftest.$ac_objext"'
6599 { (eval echo "$as_me:6599: \"$ac_try\"") >&5
6600 (eval $ac_try) 2>&5
6601 ac_status=$?
6602 echo "$as_me:6602: \$? = $ac_status" >&5
6603 (exit "$ac_status"); }; }; then
6604 cf_cv_dcl_sys_nerr=yes
6605 else
6606 echo "$as_me: failed program was:" >&5
6607 cat "conftest.$ac_ext" >&5
6608 cf_cv_dcl_sys_nerr=no
6609 fi
6610 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6611
6612 fi
6613 echo "$as_me:6613: result: $cf_cv_dcl_sys_nerr" >&5
6614 echo "${ECHO_T}$cf_cv_dcl_sys_nerr" >&6
6615
6616 if test "$cf_cv_dcl_sys_nerr" = no ; then
6617
6618 cf_result=`echo "decl_sys_nerr" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6619
6620 cat >>confdefs.h <<EOF
6621 #define $cf_result 1
6622 EOF
6623
6624 fi
6625
6626 # It's possible (for near-UNIX clones) that the data doesn't exist
6627
6628 echo "$as_me:6628: checking if external sys_nerr exists" >&5
6629 echo $ECHO_N "checking if external sys_nerr exists... $ECHO_C" >&6
6630 if test "${cf_cv_have_sys_nerr+set}" = set; then
6631 echo $ECHO_N "(cached) $ECHO_C" >&6
6632 else
6633
6634 cat >"conftest.$ac_ext" <<_ACEOF
6635 #line 6635 "configure"
6636 #include "confdefs.h"
6637
6638 #undef sys_nerr
6639 extern int sys_nerr;
6640
6641 int
6642 main (void)
6643 {
6644 sys_nerr = 2
6645 ;
6646 return 0;
6647 }
6648 _ACEOF
6649 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6650 if { (eval echo "$as_me:6650: \"$ac_link\"") >&5
6651 (eval $ac_link) 2>&5
6652 ac_status=$?
6653 echo "$as_me:6653: \$? = $ac_status" >&5
6654 (exit "$ac_status"); } &&
6655 { ac_try='test -s "conftest$ac_exeext"'
6656 { (eval echo "$as_me:6656: \"$ac_try\"") >&5
6657 (eval $ac_try) 2>&5
6658 ac_status=$?
6659 echo "$as_me:6659: \$? = $ac_status" >&5
6660 (exit "$ac_status"); }; }; then
6661 cf_cv_have_sys_nerr=yes
6662 else
6663 echo "$as_me: failed program was:" >&5
6664 cat "conftest.$ac_ext" >&5
6665 cf_cv_have_sys_nerr=no
6666 fi
6667 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6668
6669 fi
6670 echo "$as_me:6670: result: $cf_cv_have_sys_nerr" >&5
6671 echo "${ECHO_T}$cf_cv_have_sys_nerr" >&6
6672
6673 if test "$cf_cv_have_sys_nerr" = yes ; then
6674
6675 cf_result=`echo "have_sys_nerr" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6676
6677 cat >>confdefs.h <<EOF
6678 #define $cf_result 1
6679 EOF
6680
6681 fi
6682
6683 echo "$as_me:6683: checking if external sys_errlist is declared" >&5
6684 echo $ECHO_N "checking if external sys_errlist is declared... $ECHO_C" >&6
6685 if test "${cf_cv_dcl_sys_errlist+set}" = set; then
6686 echo $ECHO_N "(cached) $ECHO_C" >&6
6687 else
6688
6689 cat >"conftest.$ac_ext" <<_ACEOF
6690 #line 6690 "configure"
6691 #include "confdefs.h"
6692
6693 $ac_includes_default
6694 #include <errno.h>
6695 int
6696 main (void)
6697 {
6698 int x = (int) sys_errlist; (void)x
6699 ;
6700 return 0;
6701 }
6702 _ACEOF
6703 rm -f "conftest.$ac_objext"
6704 if { (eval echo "$as_me:6704: \"$ac_compile\"") >&5
6705 (eval $ac_compile) 2>&5
6706 ac_status=$?
6707 echo "$as_me:6707: \$? = $ac_status" >&5
6708 (exit "$ac_status"); } &&
6709 { ac_try='test -s "conftest.$ac_objext"'
6710 { (eval echo "$as_me:6710: \"$ac_try\"") >&5
6711 (eval $ac_try) 2>&5
6712 ac_status=$?
6713 echo "$as_me:6713: \$? = $ac_status" >&5
6714 (exit "$ac_status"); }; }; then
6715 cf_cv_dcl_sys_errlist=yes
6716 else
6717 echo "$as_me: failed program was:" >&5
6718 cat "conftest.$ac_ext" >&5
6719 cf_cv_dcl_sys_errlist=no
6720 fi
6721 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6722
6723 fi
6724 echo "$as_me:6724: result: $cf_cv_dcl_sys_errlist" >&5
6725 echo "${ECHO_T}$cf_cv_dcl_sys_errlist" >&6
6726
6727 if test "$cf_cv_dcl_sys_errlist" = no ; then
6728
6729 cf_result=`echo "decl_sys_errlist" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6730
6731 cat >>confdefs.h <<EOF
6732 #define $cf_result 1
6733 EOF
6734
6735 fi
6736
6737 # It's possible (for near-UNIX clones) that the data doesn't exist
6738
6739 echo "$as_me:6739: checking if external sys_errlist exists" >&5
6740 echo $ECHO_N "checking if external sys_errlist exists... $ECHO_C" >&6
6741 if test "${cf_cv_have_sys_errlist+set}" = set; then
6742 echo $ECHO_N "(cached) $ECHO_C" >&6
6743 else
6744
6745 cat >"conftest.$ac_ext" <<_ACEOF
6746 #line 6746 "configure"
6747 #include "confdefs.h"
6748
6749 #undef sys_errlist
6750 extern int sys_errlist;
6751
6752 int
6753 main (void)
6754 {
6755 sys_errlist = 2
6756 ;
6757 return 0;
6758 }
6759 _ACEOF
6760 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6761 if { (eval echo "$as_me:6761: \"$ac_link\"") >&5
6762 (eval $ac_link) 2>&5
6763 ac_status=$?
6764 echo "$as_me:6764: \$? = $ac_status" >&5
6765 (exit "$ac_status"); } &&
6766 { ac_try='test -s "conftest$ac_exeext"'
6767 { (eval echo "$as_me:6767: \"$ac_try\"") >&5
6768 (eval $ac_try) 2>&5
6769 ac_status=$?
6770 echo "$as_me:6770: \$? = $ac_status" >&5
6771 (exit "$ac_status"); }; }; then
6772 cf_cv_have_sys_errlist=yes
6773 else
6774 echo "$as_me: failed program was:" >&5
6775 cat "conftest.$ac_ext" >&5
6776 cf_cv_have_sys_errlist=no
6777 fi
6778 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6779
6780 fi
6781 echo "$as_me:6781: result: $cf_cv_have_sys_errlist" >&5
6782 echo "${ECHO_T}$cf_cv_have_sys_errlist" >&6
6783
6784 if test "$cf_cv_have_sys_errlist" = yes ; then
6785
6786 cf_result=`echo "have_sys_errlist" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
6787
6788 cat >>confdefs.h <<EOF
6789 #define $cf_result 1
6790 EOF
6791
6792 fi
6793
6794 fi
6795 done
6796
6797 ### special configuration tests
6798
6799 echo "$as_me:6799: checking if POSIX VDISABLE symbol should be used" >&5
6800 echo $ECHO_N "checking if POSIX VDISABLE symbol should be used... $ECHO_C" >&6
6801 if test "${cf_cv_posix_vdisable+set}" = set; then
6802 echo $ECHO_N "(cached) $ECHO_C" >&6
6803 else
6804
6805 if test "$cross_compiling" = yes; then
6806 cat >"conftest.$ac_ext" <<_ACEOF
6807 #line 6807 "configure"
6808 #include "confdefs.h"
6809
6810 #if defined(HAVE_TERMIOS_H) && defined(HAVE_TCGETATTR)
6811 #include <termios.h>
6812 #endif
6813 #ifdef HAVE_UNISTD_H
6814 #include <unistd.h>
6815 #endif
6816 int
6817 main (void)
6818 {
6819
6820 #if defined(_POSIX_VDISABLE) && (_POSIX_VDISABLE != -1)
6821 int temp = _POSIX_VDISABLE;
6822 #else
6823 this did not work
6824 #endif
6825 ;
6826 return 0;
6827 }
6828 _ACEOF
6829 rm -f "conftest.$ac_objext"
6830 if { (eval echo "$as_me:6830: \"$ac_compile\"") >&5
6831 (eval $ac_compile) 2>&5
6832 ac_status=$?
6833 echo "$as_me:6833: \$? = $ac_status" >&5
6834 (exit "$ac_status"); } &&
6835 { ac_try='test -s "conftest.$ac_objext"'
6836 { (eval echo "$as_me:6836: \"$ac_try\"") >&5
6837 (eval $ac_try) 2>&5
6838 ac_status=$?
6839 echo "$as_me:6839: \$? = $ac_status" >&5
6840 (exit "$ac_status"); }; }; then
6841 cf_cv_posix_vdisable=yes
6842 else
6843 echo "$as_me: failed program was:" >&5
6844 cat "conftest.$ac_ext" >&5
6845 cf_cv_posix_vdisable=no
6846 fi
6847 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6848 else
6849 cat >"conftest.$ac_ext" <<_ACEOF
6850 #line 6850 "configure"
6851 #include "confdefs.h"
6852
6853 $ac_includes_default
6854
6855 #if defined(HAVE_TERMIOS_H) && defined(HAVE_TCGETATTR)
6856 #include <termios.h>
6857 #endif
6858
6859 #if defined(_POSIX_VDISABLE)
6860 int main(void) { ${cf_cv_main_return:-return}(_POSIX_VDISABLE == -1); }
6861 #endif
6862 _ACEOF
6863 rm -f "conftest$ac_exeext"
6864 if { (eval echo "$as_me:6864: \"$ac_link\"") >&5
6865 (eval $ac_link) 2>&5
6866 ac_status=$?
6867 echo "$as_me:6867: \$? = $ac_status" >&5
6868 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
6869 { (eval echo "$as_me:6869: \"$ac_try\"") >&5
6870 (eval $ac_try) 2>&5
6871 ac_status=$?
6872 echo "$as_me:6872: \$? = $ac_status" >&5
6873 (exit "$ac_status"); }; }; then
6874 cf_cv_posix_vdisable=yes
6875 else
6876 echo "$as_me: program exited with status $ac_status" >&5
6877 echo "$as_me: failed program was:" >&5
6878 cat "conftest.$ac_ext" >&5
6879 cf_cv_posix_vdisable=no
6880 fi
6881 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
6882 fi
6883
6884 fi
6885
6886 echo "$as_me:6886: result: $cf_cv_posix_vdisable" >&5
6887 echo "${ECHO_T}$cf_cv_posix_vdisable" >&6
6888 test $cf_cv_posix_vdisable = yes &&
6889 cat >>confdefs.h <<\EOF
6890 #define HAVE_POSIX_VDISABLE 1
6891 EOF
6892
6893 echo "$as_me:6893: checking if we may use FIONREAD" >&5
6894 echo $ECHO_N "checking if we may use FIONREAD... $ECHO_C" >&6
6895 if test "${cf_cv_use_fionread+set}" = set; then
6896 echo $ECHO_N "(cached) $ECHO_C" >&6
6897 else
6898
6899 cat >"conftest.$ac_ext" <<_ACEOF
6900 #line 6900 "configure"
6901 #include "confdefs.h"
6902
6903 #if HAVE_SYS_FILIO_H
6904 # include <sys/filio.h> /* FIONREAD (BSDs) */
6905 #endif
6906 #if HAVE_SYS_IOCTL_H
6907 # include <sys/ioctl.h> /* FIONREAD (other...) */
6908 #endif
6909
6910 int
6911 main (void)
6912 {
6913
6914 int l1;
6915 ioctl (0, FIONREAD, &l1);
6916
6917 ;
6918 return 0;
6919 }
6920 _ACEOF
6921 rm -f "conftest.$ac_objext"
6922 if { (eval echo "$as_me:6922: \"$ac_compile\"") >&5
6923 (eval $ac_compile) 2>&5
6924 ac_status=$?
6925 echo "$as_me:6925: \$? = $ac_status" >&5
6926 (exit "$ac_status"); } &&
6927 { ac_try='test -s "conftest.$ac_objext"'
6928 { (eval echo "$as_me:6928: \"$ac_try\"") >&5
6929 (eval $ac_try) 2>&5
6930 ac_status=$?
6931 echo "$as_me:6931: \$? = $ac_status" >&5
6932 (exit "$ac_status"); }; }; then
6933 cf_cv_use_fionread=yes
6934 else
6935 echo "$as_me: failed program was:" >&5
6936 cat "conftest.$ac_ext" >&5
6937 cf_cv_use_fionread=no
6938 fi
6939 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6940
6941 fi
6942
6943 echo "$as_me:6943: result: $cf_cv_use_fionread" >&5
6944 echo "${ECHO_T}$cf_cv_use_fionread" >&6
6945 test $cf_cv_use_fionread = yes &&
6946 cat >>confdefs.h <<\EOF
6947 #define USE_FIONREAD 1
6948 EOF
6949
6950 echo "$as_me:6950: checking for nl_langinfo and CODESET" >&5
6951 echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
6952 if test "${am_cv_langinfo_codeset+set}" = set; then
6953 echo $ECHO_N "(cached) $ECHO_C" >&6
6954 else
6955 cat >"conftest.$ac_ext" <<_ACEOF
6956 #line 6956 "configure"
6957 #include "confdefs.h"
6958
6959 $ac_includes_default
6960 #include <langinfo.h>
6961 int
6962 main (void)
6963 {
6964 char* cs = nl_langinfo(CODESET); (void)cs
6965 ;
6966 return 0;
6967 }
6968 _ACEOF
6969 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6970 if { (eval echo "$as_me:6970: \"$ac_link\"") >&5
6971 (eval $ac_link) 2>&5
6972 ac_status=$?
6973 echo "$as_me:6973: \$? = $ac_status" >&5
6974 (exit "$ac_status"); } &&
6975 { ac_try='test -s "conftest$ac_exeext"'
6976 { (eval echo "$as_me:6976: \"$ac_try\"") >&5
6977 (eval $ac_try) 2>&5
6978 ac_status=$?
6979 echo "$as_me:6979: \$? = $ac_status" >&5
6980 (exit "$ac_status"); }; }; then
6981 am_cv_langinfo_codeset=yes
6982 else
6983 echo "$as_me: failed program was:" >&5
6984 cat "conftest.$ac_ext" >&5
6985 am_cv_langinfo_codeset=no
6986 fi
6987 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6988
6989 fi
6990 echo "$as_me:6990: result: $am_cv_langinfo_codeset" >&5
6991 echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
6992 if test "$am_cv_langinfo_codeset" = yes; then
6993
6994 cat >>confdefs.h <<\EOF
6995 #define HAVE_LANGINFO_CODESET 1
6996 EOF
6997
6998 fi
6999
7000 ### debugging/testing
7001
7002 ### output makefile and config.h
7003 ac_config_files="$ac_config_files makefile"
7004 cat >confcache <<\_ACEOF
7005 # This file is a shell script that caches the results of configure
7006 # tests run on this system so they can be shared between configure
7007 # scripts and configure runs, see configure's option --config-cache.
7008 # It is not useful on other systems. If it contains results you don't
7009 # want to keep, you may remove or edit it.
7010 #
7011 # config.status only pays attention to the cache file if you give it
7012 # the --recheck option to rerun configure.
7013 #
7014 # `ac_cv_env_foo' variables (set or unset) will be overridden when
7015 # loading this file, other *unset* `ac_cv_foo' will be assigned the
7016 # following values.
7017
7018 _ACEOF
7019
7020 # The following way of writing the cache mishandles newlines in values,
7021 # but we know of no workaround that is simple, portable, and efficient.
7022 # So, don't put newlines in cache variables' values.
7023 # Ultrix sh set writes to stderr and can't be redirected directly,
7024 # and sets the high bit in the cache file unless we assign to the vars.
7025 {
7026 (set) 2>&1 |
7027 case `(ac_space=' '; set | grep ac_space) 2>&1` in
7028 *ac_space=\ *)
7029 # `set' does not quote correctly, so add quotes (double-quote
7030 # substitution turns \\\\ into \\, and sed turns \\ into \).
7031 sed -n \
7032 "s/'/'\\\\''/g;
7033 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
7034 ;;
7035 *)
7036 # `set' quotes correctly as required by POSIX, so do not add quotes.
7037 sed -n \
7038 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
7039 ;;
7040 esac;
7041 } |
7042 sed '
7043 t clear
7044 : clear
7045 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
7046 t end
7047 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
7048 : end' >>confcache
7049 if cmp -s $cache_file confcache; then :; else
7050 if test -w $cache_file; then
7051 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
7052 cat confcache >$cache_file
7053 else
7054 echo "not updating unwritable cache $cache_file"
7055 fi
7056 fi
7057 rm -f confcache
7058
7059 test "x$prefix" = xNONE && prefix=$ac_default_prefix
7060 # Let make expand exec_prefix.
7061 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7062
7063 # VPATH may cause trouble with some makes, so we remove $(srcdir),
7064 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
7065 # trailing colons and then remove the whole line if VPATH becomes empty
7066 # (actually we leave an empty line to preserve line numbers).
7067 if test "x$srcdir" = x.; then
7068 ac_vpsub='/^[ ]*VPATH[ ]*=/{
7069 s/:*\$(srcdir):*/:/;
7070 s/:*\${srcdir}:*/:/;
7071 s/:*@srcdir@:*/:/;
7072 s/^\([^=]*=[ ]*\):*/\1/;
7073 s/:*$//;
7074 s/^[^=]*=[ ]*$//;
7075 }'
7076 fi
7077
7078 DEFS=-DHAVE_CONFIG_H
7079
7080 : "${CONFIG_STATUS=./config.status}"
7081 ac_clean_files_save=$ac_clean_files
7082 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
7083 { echo "$as_me:7083: creating $CONFIG_STATUS" >&5
7084 echo "$as_me: creating $CONFIG_STATUS" >&6;}
7085 cat >"$CONFIG_STATUS" <<_ACEOF
7086 #! $SHELL
7087 # Generated automatically by configure.
7088 # Run this file to recreate the current configuration.
7089 # Compiler output produced by configure, useful for debugging
7090 # configure, is in config.log if it exists.
7091
7092 me=\`echo "\$0" | sed -e 's,.*\\/,,'\`
7093
7094 debug=false
7095 SHELL=\${CONFIG_SHELL-$SHELL}
7096 ac_cs_invocation="\$0 \$@"
7097
7098 CLICOLOR_FORCE= GREP_OPTIONS=
7099 unset CLICOLOR_FORCE GREP_OPTIONS
7100 _ACEOF
7101
7102 cat >>"$CONFIG_STATUS" <<\_ACEOF
7103 # Be Bourne compatible
7104 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
7105 emulate sh
7106 NULLCMD=:
7107 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
7108 set -o posix
7109 fi
7110
7111 # Name of the executable.
7112 as_me=`echo "$0" |sed 's,.*[\\/],,'`
7113
7114 if expr a : '\(a\)' >/dev/null 2>&1; then
7115 as_expr="expr"
7116 else
7117 as_expr="false"
7118 fi
7119
7120 rm -f conf$$ conf$$.exe conf$$.file
7121 echo >conf$$.file
7122 if ln -s conf$$.file conf$$ 2>/dev/null; then
7123 # We could just check for DJGPP; but this test a) works b) is more generic
7124 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
7125 if test -f conf$$.exe; then
7126 # Don't use ln at all; we don't have any links
7127 as_ln_s='cp -p'
7128 else
7129 as_ln_s='ln -s'
7130 fi
7131 elif ln conf$$.file conf$$ 2>/dev/null; then
7132 as_ln_s='ln'
7133 else
7134 as_ln_s='cp -p'
7135 fi
7136 rm -f conf$$ conf$$.exe conf$$.file
7137
7138 as_executable_p="test -f"
7139
7140 # Support unset when possible.
7141 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
7142 as_unset="unset"
7143 else
7144 as_unset="false"
7145 fi
7146
7147 # NLS nuisances.
7148 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
7149 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
7150 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
7151 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
7152 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
7153 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
7154 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
7155 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
7156
7157 # IFS
7158 # We need space, tab and new line, in precisely that order.
7159 as_nl='
7160 '
7161 IFS=" $as_nl"
7162
7163 # CDPATH.
7164 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
7165
7166 exec 6>&1
7167
7168 _ACEOF
7169
7170 # Files that config.status was made for.
7171 if test -n "$ac_config_files"; then
7172 echo "config_files=\"$ac_config_files\"" >>"$CONFIG_STATUS"
7173 fi
7174
7175 if test -n "$ac_config_headers"; then
7176 echo "config_headers=\"$ac_config_headers\"" >>"$CONFIG_STATUS"
7177 fi
7178
7179 if test -n "$ac_config_links"; then
7180 echo "config_links=\"$ac_config_links\"" >>"$CONFIG_STATUS"
7181 fi
7182
7183 if test -n "$ac_config_commands"; then
7184 echo "config_commands=\"$ac_config_commands\"" >>"$CONFIG_STATUS"
7185 fi
7186
7187 cat >>"$CONFIG_STATUS" <<\EOF
7188
7189 ac_cs_usage="\
7190 \`$as_me' instantiates files from templates according to the
7191 current configuration.
7192
7193 Usage: $0 [OPTIONS] [FILE]...
7194
7195 -h, --help print this help, then exit
7196 -V, --version print version number, then exit
7197 -d, --debug don't remove temporary files
7198 --recheck update $as_me by reconfiguring in the same conditions
7199 --file=FILE[:TEMPLATE]
7200 instantiate the configuration file FILE
7201 --header=FILE[:TEMPLATE]
7202 instantiate the configuration header FILE
7203
7204 Configuration files:
7205 $config_files
7206
7207 Configuration headers:
7208 $config_headers
7209
7210 Report bugs to <[email protected]>."
7211 EOF
7212
7213 cat >>"$CONFIG_STATUS" <<EOF
7214 ac_cs_version="\\
7215 config.status
7216 configured by $0, generated by GNU Autoconf 2.52.20250126,
7217 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
7218
7219 Copyright 2003-2022,2023 Thomas E. Dickey
7220 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
7221 Free Software Foundation, Inc.
7222 This config.status script is free software; the Free Software Foundation
7223 gives unlimited permission to copy, distribute and modify it."
7224 srcdir="$srcdir"
7225 INSTALL="$INSTALL"
7226 EOF
7227
7228 cat >>"$CONFIG_STATUS" <<\EOF
7229 # If no file are specified by the user, then we need to provide default
7230 # value. By we need to know if files were specified by the user.
7231 ac_need_defaults=:
7232 while test $# != 0
7233 do
7234 case $1 in
7235 --*=*)
7236 ac_option=`expr "x$1" : 'x\([^=]*\)='`
7237 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
7238 shift
7239 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
7240 shift
7241 ;;
7242 -*);;
7243 *) # This is not an option, so the user has probably given explicit
7244 # arguments.
7245 ac_need_defaults=false;;
7246 esac
7247
7248 case $1 in
7249 # Handling of the options.
7250 EOF
7251 cat >>"$CONFIG_STATUS" <<EOF
7252 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
7253 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
7254 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
7255 EOF
7256 cat >>"$CONFIG_STATUS" <<\EOF
7257 --version | --vers* | -V )
7258 echo "$ac_cs_version"; exit 0 ;;
7259 --he | --h)
7260 # Conflict between --help and --header
7261 { { echo "$as_me:7261: error: ambiguous option: $1
7262 Try \`$0 --help' for more information." >&5
7263 echo "$as_me: error: ambiguous option: $1
7264 Try \`$0 --help' for more information." >&2;}
7265 { (exit 1); exit 1; }; };;
7266 --help | --hel | -h )
7267 echo "$ac_cs_usage"; exit 0 ;;
7268 --debug | --d* | -d )
7269 debug=: ;;
7270 --file | --fil | --fi | --f )
7271 shift
7272 CONFIG_FILES="$CONFIG_FILES $1"
7273 ac_need_defaults=false;;
7274 --header | --heade | --head | --hea )
7275 shift
7276 CONFIG_HEADERS="$CONFIG_HEADERS $1"
7277 ac_need_defaults=false;;
7278
7279 # This is an error.
7280 -*) { { echo "$as_me:7280: error: unrecognized option: $1
7281 Try \`$0 --help' for more information." >&5
7282 echo "$as_me: error: unrecognized option: $1
7283 Try \`$0 --help' for more information." >&2;}
7284 { (exit 1); exit 1; }; } ;;
7285
7286 *) ac_config_targets="$ac_config_targets $1" ;;
7287
7288 esac
7289 shift
7290 done
7291
7292 exec 5>>config.log
7293 cat >&5 << _ACEOF
7294
7295 ## ----------------------- ##
7296 ## Running config.status. ##
7297 ## ----------------------- ##
7298
7299 This file was extended by $as_me 2.52.20250126, executed with
7300 CONFIG_FILES = $CONFIG_FILES
7301 CONFIG_HEADERS = $CONFIG_HEADERS
7302 CONFIG_LINKS = $CONFIG_LINKS
7303 CONFIG_COMMANDS = $CONFIG_COMMANDS
7304 > "$ac_cs_invocation"
7305 on `(hostname || uname -n) 2>/dev/null | sed 1q`
7306
7307 _ACEOF
7308 EOF
7309
7310 cat >>"$CONFIG_STATUS" <<\EOF
7311 for ac_config_target in $ac_config_targets
7312 do
7313 case "$ac_config_target" in
7314 # Handling of arguments.
7315 "makefile" ) CONFIG_FILES="$CONFIG_FILES makefile" ;;
7316 "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.hin" ;;
7317 *) { { echo "$as_me:7317: error: invalid argument: $ac_config_target" >&5
7318 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
7319 { (exit 1); exit 1; }; };;
7320 esac
7321 done
7322
7323 # If the user did not use the arguments to specify the items to instantiate,
7324 # then the envvar interface is used. Set only those that are not.
7325 # We use the long form for the default assignment because of an extremely
7326 # bizarre bug on SunOS 4.1.3.
7327 if "$ac_need_defaults"; then
7328 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
7329 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
7330 fi
7331
7332 # Create a temporary directory, and hook for its removal unless debugging.
7333 $debug ||
7334 {
7335 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
7336 trap '{ (exit 1); exit 1; }' 1 2 13 15
7337 }
7338
7339 # Create a (secure) tmp directory for tmp files.
7340 : "${TMPDIR=/tmp}"
7341 {
7342 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
7343 test -n "$tmp" && test -d "$tmp"
7344 } ||
7345 {
7346 tmp=$TMPDIR/cs$$-$RANDOM
7347 (umask 077 && mkdir "$tmp")
7348 } ||
7349 {
7350 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
7351 { (exit 1); exit 1; }
7352 }
7353
7354 EOF
7355
7356 cat >>"$CONFIG_STATUS" <<EOF
7357
7358 #
7359 # CONFIG_FILES section.
7360 #
7361
7362 # No need to generate the scripts if there are no CONFIG_FILES.
7363 # This happens for instance when ./config.status config.h
7364 if test -n "\$CONFIG_FILES"; then
7365 # Protect against being on the right side of a sed subst in config.status.
7366 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
7367 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >"\$tmp"/subs.sed <<\\CEOF
7368 s,@X_CFLAGS@,$X_CFLAGS,;t t
7369 s,@X_LIBS@,$X_LIBS,;t t
7370 s,@SHELL@,$SHELL,;t t
7371 s,@exec_prefix@,$exec_prefix,;t t
7372 s,@prefix@,$prefix,;t t
7373 s,@program_transform_name@,$program_transform_name,;t t
7374 s,@bindir@,$bindir,;t t
7375 s,@sbindir@,$sbindir,;t t
7376 s,@libexecdir@,$libexecdir,;t t
7377 s,@datarootdir@,$datarootdir,;t t
7378 s,@datadir@,$datadir,;t t
7379 s,@sysconfdir@,$sysconfdir,;t t
7380 s,@sharedstatedir@,$sharedstatedir,;t t
7381 s,@localstatedir@,$localstatedir,;t t
7382 s,@runstatedir@,$runstatedir,;t t
7383 s,@libdir@,$libdir,;t t
7384 s,@includedir@,$includedir,;t t
7385 s,@oldincludedir@,$oldincludedir,;t t
7386 s,@infodir@,$infodir,;t t
7387 s,@mandir@,$mandir,;t t
7388 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
7389 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
7390 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
7391 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
7392 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
7393 s,@build_alias@,$build_alias,;t t
7394 s,@host_alias@,$host_alias,;t t
7395 s,@target_alias@,$target_alias,;t t
7396 s,@ECHO_C@,$ECHO_C,;t t
7397 s,@ECHO_N@,$ECHO_N,;t t
7398 s,@ECHO_T@,$ECHO_T,;t t
7399 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
7400 s,@DEFS@,$DEFS,;t t
7401 s,@LIBS@,$LIBS,;t t
7402 s,@build@,$build,;t t
7403 s,@build_cpu@,$build_cpu,;t t
7404 s,@build_vendor@,$build_vendor,;t t
7405 s,@build_os@,$build_os,;t t
7406 s,@host@,$host,;t t
7407 s,@host_cpu@,$host_cpu,;t t
7408 s,@host_vendor@,$host_vendor,;t t
7409 s,@host_os@,$host_os,;t t
7410 s,@target@,$target,;t t
7411 s,@target_cpu@,$target_cpu,;t t
7412 s,@target_vendor@,$target_vendor,;t t
7413 s,@target_os@,$target_os,;t t
7414 s,@CC@,$CC,;t t
7415 s,@CFLAGS@,$CFLAGS,;t t
7416 s,@LDFLAGS@,$LDFLAGS,;t t
7417 s,@CPPFLAGS@,$CPPFLAGS,;t t
7418 s,@ac_ct_CC@,$ac_ct_CC,;t t
7419 s,@EXEEXT@,$EXEEXT,;t t
7420 s,@OBJEXT@,$OBJEXT,;t t
7421 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
7422 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
7423 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
7424 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
7425 s,@MAKE_NO_PHONY@,$MAKE_NO_PHONY,;t t
7426 s,@MAKE_PHONY@,$MAKE_PHONY,;t t
7427 s,@CTAGS@,$CTAGS,;t t
7428 s,@ETAGS@,$ETAGS,;t t
7429 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
7430 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
7431 s,@LINT@,$LINT,;t t
7432 s,@LINT_OPTS@,$LINT_OPTS,;t t
7433 s,@LINT_LIBS@,$LINT_LIBS,;t t
7434 s,@GROFF_PATH@,$GROFF_PATH,;t t
7435 s,@NROFF_PATH@,$NROFF_PATH,;t t
7436 s,@TBL_PATH@,$TBL_PATH,;t t
7437 s,@GROFF_NOTE@,$GROFF_NOTE,;t t
7438 s,@NROFF_NOTE@,$NROFF_NOTE,;t t
7439 s,@GREP@,$GREP,;t t
7440 s,@FGREP@,$FGREP,;t t
7441 s,@cf_man2html@,$cf_man2html,;t t
7442 s,@GLOB_FULLPATH_POSIX@,$GLOB_FULLPATH_POSIX,;t t
7443 s,@GLOB_FULLPATH_OTHER@,$GLOB_FULLPATH_OTHER,;t t
7444 s,@MAN2HTML_NOTE@,$MAN2HTML_NOTE,;t t
7445 s,@MAN2HTML_PATH@,$MAN2HTML_PATH,;t t
7446 s,@MAN2HTML_TEMP@,$MAN2HTML_TEMP,;t t
7447 s,@ECHO_LT@,$ECHO_LT,;t t
7448 s,@ECHO_LD@,$ECHO_LD,;t t
7449 s,@RULE_CC@,$RULE_CC,;t t
7450 s,@SHOW_CC@,$SHOW_CC,;t t
7451 s,@ECHO_CC@,$ECHO_CC,;t t
7452 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
7453 s,@HAVE_STDNORETURN_H@,$HAVE_STDNORETURN_H,;t t
7454 s,@STDC_NORETURN@,$STDC_NORETURN,;t t
7455 s,@CPP@,$CPP,;t t
7456 s,@EGREP@,$EGREP,;t t
7457 CEOF
7458
7459 EOF
7460
7461 cat >>"$CONFIG_STATUS" <<\EOF
7462 # Split the substitutions into bite-sized pieces for seds with
7463 # small command number limits, like on Digital OSF/1 and HP-UX.
7464 ac_max_sed_lines=48
7465 ac_sed_frag=1 # Number of current file.
7466 ac_beg=1 # First line for current file.
7467 ac_end=$ac_max_sed_lines # Line after last line for current file.
7468 ac_more_lines=:
7469 ac_sed_cmds=
7470 while "$ac_more_lines"; do
7471 if test "$ac_beg" -gt 1; then
7472 sed "1,${ac_beg}d; ${ac_end}q" "$tmp"/subs.sed >"$tmp"/subs.frag
7473 else
7474 sed "${ac_end}q" "$tmp"/subs.sed >"$tmp"/subs.frag
7475 fi
7476 if test ! -s "$tmp"/subs.frag; then
7477 ac_more_lines=false
7478 else
7479 # The purpose of the label and of the branching condition is to
7480 # speed up the sed processing (if there are no `@' at all, there
7481 # is no need to browse any of the substitutions).
7482 # These are the two extra sed commands mentioned above.
7483 (echo ':t
7484 /@[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
7485 # It is possible to make a multiline substitution using escaped newlines.
7486 # Ensure that we do not split the substitution between script fragments.
7487 ac_BEG=$ac_end
7488 ac_END=`expr "$ac_end" + "$ac_max_sed_lines"`
7489 sed "1,${ac_BEG}d; ${ac_END}p; q" "$tmp"/subs.sed >"$tmp"/subs.next
7490 if test -s "$tmp"/subs.next; then
7491 grep '^s,@[^@,][^@,]*@,.*$' "$tmp"/subs.next | grep -v '^s,@.*;t t$' >"$tmp"/subs.edit
7492 if test ! -s "$tmp"/subs.edit; then
7493 grep "^s,@[^@,][^@,]*@,.*,;t t$" "$tmp"/subs.next >"$tmp"/subs.edit
7494 if test ! -s "$tmp"/subs.edit; then
7495 if test "$ac_beg" -gt 1; then
7496 ac_end=`expr "$ac_end" - 1`
7497 continue
7498 fi
7499 fi
7500 fi
7501 fi
7502
7503 if test -z "$ac_sed_cmds"; then
7504 ac_sed_cmds="sed -f \"$tmp\"/subs-$ac_sed_frag.sed"
7505 else
7506 ac_sed_cmds="$ac_sed_cmds | sed -f \"$tmp\"/subs-$ac_sed_frag.sed"
7507 fi
7508 ac_sed_frag=`expr "$ac_sed_frag" + 1`
7509 ac_beg=$ac_end
7510 ac_end=`expr "$ac_end" + "$ac_max_sed_lines"`
7511 fi
7512 done
7513 if test -z "$ac_sed_cmds"; then
7514 ac_sed_cmds="cat"
7515 fi
7516 fi # test -n "$CONFIG_FILES"
7517
7518 EOF
7519 cat >>"$CONFIG_STATUS" <<\EOF
7520 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
7521 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
7522 case "$ac_file" in
7523 - | *:- | *:-:* ) # input from stdin
7524 cat >"$tmp"/stdin
7525 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
7526 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
7527 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
7528 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
7529 * ) ac_file_in=$ac_file.in ;;
7530 esac
7531
7532 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
7533 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7534 X"$ac_file" : 'X\(//\)[^/]' \| \
7535 X"$ac_file" : 'X\(//\)$' \| \
7536 X"$ac_file" : 'X\(/\)' \| \
7537 . : '\(.\)' 2>/dev/null ||
7538 echo X"$ac_file" |
7539 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
7540 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
7541 /^X\(\/\/\)$/{ s//\1/; q; }
7542 /^X\(\/\).*/{ s//\1/; q; }
7543 s/.*/./; q'`
7544 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
7545 { case "$ac_dir" in
7546 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
7547 *) as_incr_dir=.;;
7548 esac
7549 as_dummy="$ac_dir"
7550 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
7551 case $as_mkdir_dir in
7552 # Skip DOS drivespec
7553 ?:) as_incr_dir=$as_mkdir_dir ;;
7554 *)
7555 as_incr_dir=$as_incr_dir/$as_mkdir_dir
7556 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
7557 ;;
7558 esac
7559 done; }
7560
7561 ac_dir_suffix="/`echo "$ac_dir"|sed 's,^\./,,'`"
7562 # A "../" for each directory in $ac_dir_suffix.
7563 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
7564 else
7565 ac_dir_suffix= ac_dots=
7566 fi
7567
7568 case "$srcdir" in
7569 .) ac_srcdir=.
7570 if test -z "$ac_dots"; then
7571 ac_top_srcdir=.
7572 else
7573 ac_top_srcdir=`echo "$ac_dots" | sed 's,/$,,'`
7574 fi ;;
7575 [\\/]* | ?:[\\/]* )
7576 ac_srcdir="$srcdir$ac_dir_suffix";
7577 ac_top_srcdir="$srcdir" ;;
7578 *) # Relative path.
7579 ac_srcdir="$ac_dots$srcdir$ac_dir_suffix"
7580 ac_top_srcdir="$ac_dots$srcdir" ;;
7581 esac
7582
7583 case $INSTALL in
7584 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
7585 *) ac_INSTALL=$ac_dots$INSTALL ;;
7586 esac
7587
7588 if test x"$ac_file" != x-; then
7589 { echo "$as_me:7589: creating $ac_file" >&5
7590 echo "$as_me: creating $ac_file" >&6;}
7591 rm -f "$ac_file"
7592 fi
7593 # Let's still pretend it is `configure' which instantiates (i.e., don't
7594 # use $as_me), people would be surprised to read:
7595 # /* config.h. Generated automatically by config.status. */
7596 configure_input="Generated automatically from `echo $ac_file_in |
7597 sed 's,.*/,,'` by configure."
7598
7599 # First look for the input files in the build tree, otherwise in the
7600 # src tree.
7601 ac_file_inputs=`IFS=:
7602 for f in $ac_file_in; do
7603 case $f in
7604 -) echo "$tmp"/stdin ;;
7605 [\\/$]*)
7606 # Absolute (can't be DOS-style, as IFS=:)
7607 test -f "$f" || { { echo "$as_me:7607: error: cannot find input file: $f" >&5
7608 echo "$as_me: error: cannot find input file: $f" >&2;}
7609 { (exit 1); exit 1; }; }
7610 echo "$f";;
7611 *) # Relative
7612 if test -f "$f"; then
7613 # Build tree
7614 echo "$f"
7615 elif test -f "$srcdir/$f"; then
7616 # Source tree
7617 echo "$srcdir/$f"
7618 else
7619 # /dev/null tree
7620 { { echo "$as_me:7620: error: cannot find input file: $f" >&5
7621 echo "$as_me: error: cannot find input file: $f" >&2;}
7622 { (exit 1); exit 1; }; }
7623 fi;;
7624 esac
7625 done` || { (exit 1); exit 1; }
7626 EOF
7627 cat >>"$CONFIG_STATUS" <<\EOF
7628 ac_warn_datarootdir=no
7629 if test x"$ac_file" != x-; then
7630 for ac_item in $ac_file_inputs
7631 do
7632 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' "$ac_item"`
7633 if test -n "$ac_seen"; then
7634 ac_used=`grep '@datarootdir@' "$ac_item"`
7635 if test -z "$ac_used"; then
7636 { echo "$as_me:7636: WARNING: datarootdir was used implicitly but not set:
7637 $ac_seen" >&5
7638 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
7639 $ac_seen" >&2;}
7640 ac_warn_datarootdir=yes
7641 fi
7642 fi
7643 ac_seen=`grep '${datarootdir}' "$ac_item"`
7644 if test -n "$ac_seen"; then
7645 { echo "$as_me:7645: WARNING: datarootdir was used explicitly but not set:
7646 $ac_seen" >&5
7647 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
7648 $ac_seen" >&2;}
7649 ac_warn_datarootdir=yes
7650 fi
7651 done
7652 fi
7653
7654 if test "x$ac_warn_datarootdir" = xyes; then
7655 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
7656 fi
7657
7658 EOF
7659 cat >>"$CONFIG_STATUS" <<EOF
7660 sed "$ac_vpsub
7661 $extrasub
7662 EOF
7663 cat >>"$CONFIG_STATUS" <<\EOF
7664 :t
7665 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
7666 s,@configure_input@,$configure_input,;t t
7667 s,@srcdir@,$ac_srcdir,;t t
7668 s,@top_srcdir@,$ac_top_srcdir,;t t
7669 s,@INSTALL@,$ac_INSTALL,;t t
7670 " $ac_file_inputs | (eval "$ac_sed_cmds") >"$tmp"/out
7671 rm -f "$tmp"/stdin
7672 EOF
7673 test -n "${FGREP}" || FGREP="grep -F"
7674 test -n "${EGREP}" || EGREP="grep -E"
7675 cat >>"$CONFIG_STATUS" <<EOF
7676 test -n "\${FGREP}" || FGREP="$FGREP"
7677 test -n "\${EGREP}" || EGREP="$EGREP"
7678 EOF
7679 cat >>"$CONFIG_STATUS" <<\EOF
7680 if test x"$ac_file" != x-; then
7681 cp "$tmp/out" "$ac_file"
7682
7683 for ac_name in prefix exec_prefix datarootdir
7684 do
7685 ac_seen=`$FGREP -n '${'$ac_name'[:=].*}' "$ac_file"`
7686 if test -n "$ac_seen"; then
7687 ac_init=`$EGREP '[ ]*'$ac_name'[ ]*=' "$ac_file"`
7688 if test -z "$ac_init"; then
7689 ac_seen=`echo "$ac_seen" |sed -e 's,^,'"$ac_file"':,'`
7690 { echo "$as_me:7690: WARNING: Variable $ac_name is used but was not set:
7691 $ac_seen" >&5
7692 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
7693 $ac_seen" >&2;}
7694 fi
7695 fi
7696 done
7697 $EGREP -n '@[a-z_][a-z_0-9]+@' "$ac_file" >"$tmp"/out
7698 $EGREP -n '@[A-Z_][A-Z_0-9]+@' "$ac_file" >>"$tmp"/out
7699 if test -s "$tmp"/out; then
7700 ac_seen=`sed -e 's,^,'"$ac_file"':,' < "$tmp"/out`
7701 { echo "$as_me:7701: WARNING: Some variables may not be substituted:
7702 $ac_seen" >&5
7703 echo "$as_me: WARNING: Some variables may not be substituted:
7704 $ac_seen" >&2;}
7705 fi
7706 else
7707 cat "$tmp"/out
7708 fi
7709 rm -f "$tmp"/out
7710
7711 done
7712 EOF
7713 cat >>"$CONFIG_STATUS" <<\EOF
7714
7715 #
7716 # CONFIG_HEADER section.
7717 #
7718
7719 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
7720 # NAME is the cpp macro being defined and VALUE is the value it is being given.
7721 #
7722 # ac_d sets the value in "#define NAME VALUE" lines.
7723 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
7724 ac_dB='[ ].*$,\1#\2'
7725 ac_dC=' '
7726 ac_dD=',;t'
7727 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
7728 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
7729 ac_iB='\([ ]\),\1#\2define\3'
7730 ac_iC=' '
7731 ac_iD='\4,;t'
7732 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
7733 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
7734 ac_uB='$,\1#\2define\3'
7735 ac_uC=' '
7736 ac_uD=',;t'
7737
7738 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
7739 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
7740 case "$ac_file" in
7741 - | *:- | *:-:* ) # input from stdin
7742 cat >"$tmp"/stdin
7743 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
7744 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
7745 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
7746 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
7747 * ) ac_file_in=$ac_file.in ;;
7748 esac
7749
7750 test x"$ac_file" != x- && { echo "$as_me:7750: creating $ac_file" >&5
7751 echo "$as_me: creating $ac_file" >&6;}
7752
7753 # First look for the input files in the build tree, otherwise in the
7754 # src tree.
7755 ac_file_inputs=`IFS=:
7756 for f in $ac_file_in; do
7757 case $f in
7758 -) echo "$tmp"/stdin ;;
7759 [\\/$]*)
7760 # Absolute (can't be DOS-style, as IFS=:)
7761 test -f "$f" || { { echo "$as_me:7761: error: cannot find input file: $f" >&5
7762 echo "$as_me: error: cannot find input file: $f" >&2;}
7763 { (exit 1); exit 1; }; }
7764 echo $f;;
7765 *) # Relative
7766 if test -f "$f"; then
7767 # Build tree
7768 echo $f
7769 elif test -f "$srcdir/$f"; then
7770 # Source tree
7771 echo "$srcdir/$f"
7772 else
7773 # /dev/null tree
7774 { { echo "$as_me:7774: error: cannot find input file: $f" >&5
7775 echo "$as_me: error: cannot find input file: $f" >&2;}
7776 { (exit 1); exit 1; }; }
7777 fi;;
7778 esac
7779 done` || { (exit 1); exit 1; }
7780 # Remove the trailing spaces.
7781 sed 's/[ ]*$//' $ac_file_inputs >"$tmp"/in
7782
7783 EOF
7784
7785 # Transform confdefs.h into two sed scripts, `conftest.defines' and
7786 # `conftest.undefs', that substitutes the proper values into
7787 # config.h.in to produce config.h. The first handles `#define'
7788 # templates, and the second `#undef' templates.
7789 # And first: Protect against being on the right side of a sed subst in
7790 # config.status. Protect against being in an unquoted here document
7791 # in config.status.
7792 rm -f conftest.defines conftest.undefs
7793 # Using a here document instead of a string reduces the quoting nightmare.
7794 # Putting comments in sed scripts is not portable.
7795 #
7796 # `end' is used to avoid that the second main sed command (meant for
7797 # 0-ary CPP macros) applies to n-ary macro definitions.
7798 # See the Autoconf documentation for `clear'.
7799 cat >confdef2sed.sed <<\EOF
7800 s/[\\&,]/\\&/g
7801 s,[\\$`],\\&,g
7802 t clear
7803 : clear
7804 s,^[ ]*#[ ]*define[ ][ ]*\(\([^ (][^ (]*\)([^)]*)\)[ ]*\(.*\)$,${ac_dA}\2${ac_dB}\1${ac_dC}\3${ac_dD},gp
7805 t end
7806 s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
7807 : end
7808 EOF
7809 # If some macros were called several times there might be several times
7810 # the same #defines, which is useless. Nevertheless, we may not want to
7811 # sort them, since we want the *last* AC-DEFINE to be honored.
7812 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
7813 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
7814 sed 's/ac_d/ac_i/g' conftest.defines >>conftest.undefs
7815 rm -f confdef2sed.sed
7816
7817 # This sed command replaces #undef with comments. This is necessary, for
7818 # example, in the case of _POSIX_SOURCE, which is predefined and required
7819 # on some systems where configure will not decide to define it.
7820 cat >>conftest.undefs <<\EOF
7821 s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
7822 EOF
7823
7824 # Break up conftest.defines because some shells have a limit on the size
7825 # of here documents, and old seds have small limits too (100 cmds).
7826 echo ' # Handle all the #define templates only if necessary.' >>"$CONFIG_STATUS"
7827 echo ' test -n "${EGREP}" || EGREP="grep -E"' >>"$CONFIG_STATUS"
7828 echo ' if ${EGREP} "^[ ]*#[ ]*define" "$tmp"/in >/dev/null; then' >>"$CONFIG_STATUS"
7829 echo ' # If there are no defines, we may have an empty if/fi' >>"$CONFIG_STATUS"
7830 echo ' :' >>"$CONFIG_STATUS"
7831 rm -f conftest.tail
7832 while grep . conftest.defines >/dev/null
7833 do
7834 # Write a limited-size here document to "$tmp"/defines.sed.
7835 echo ' cat >"$tmp"/defines.sed <<CEOF' >>"$CONFIG_STATUS"
7836 # Speed up: don't consider the non `#define' lines.
7837 echo '/^[ ]*#[ ]*define/!b' >>"$CONFIG_STATUS"
7838 # Work around the forget-to-reset-the-flag bug.
7839 echo 't clr' >>"$CONFIG_STATUS"
7840 echo ': clr' >>"$CONFIG_STATUS"
7841 sed "${ac_max_here_lines}q" conftest.defines >>"$CONFIG_STATUS"
7842 echo 'CEOF
7843 sed -f "$tmp"/defines.sed "$tmp"/in >"$tmp"/out
7844 rm -f "$tmp"/in
7845 mv "$tmp"/out "$tmp"/in
7846 ' >>"$CONFIG_STATUS"
7847 sed "1,${ac_max_here_lines}d" conftest.defines >conftest.tail
7848 rm -f conftest.defines
7849 mv conftest.tail conftest.defines
7850 done
7851 rm -f conftest.defines
7852 echo ' fi # grep' >>"$CONFIG_STATUS"
7853 echo >>"$CONFIG_STATUS"
7854
7855 # Break up conftest.undefs because some shells have a limit on the size
7856 # of here documents, and old seds have small limits too (100 cmds).
7857 echo ' # Handle all the #undef templates' >>"$CONFIG_STATUS"
7858 rm -f conftest.tail
7859 while grep . conftest.undefs >/dev/null
7860 do
7861 # Write a limited-size here document to "$tmp"/undefs.sed.
7862 echo ' cat >"$tmp"/undefs.sed <<CEOF' >>"$CONFIG_STATUS"
7863 # Speed up: don't consider the non `#undef'
7864 echo '/^[ ]*#[ ]*undef/!b' >>"$CONFIG_STATUS"
7865 # Work around the forget-to-reset-the-flag bug.
7866 echo 't clr' >>"$CONFIG_STATUS"
7867 echo ': clr' >>"$CONFIG_STATUS"
7868 sed "${ac_max_here_lines}q" conftest.undefs >>"$CONFIG_STATUS"
7869 echo 'CEOF
7870 sed -f "$tmp"/undefs.sed "$tmp"/in >"$tmp"/out
7871 rm -f "$tmp"/in
7872 mv "$tmp"/out "$tmp"/in
7873 ' >>"$CONFIG_STATUS"
7874 sed "1,${ac_max_here_lines}d" conftest.undefs >conftest.tail
7875 rm -f conftest.undefs
7876 mv conftest.tail conftest.undefs
7877 done
7878 rm -f conftest.undefs
7879
7880 cat >>"$CONFIG_STATUS" <<\EOF
7881 # Let's still pretend it is `configure' which instantiates (i.e., don't
7882 # use $as_me), people would be surprised to read:
7883 # /* config.h. Generated automatically by config.status. */
7884 if test x"$ac_file" = x-; then
7885 echo "/* Generated automatically by configure. */" >"$tmp"/config.h
7886 else
7887 echo "/* $ac_file. Generated automatically by configure. */" >"$tmp"/config.h
7888 fi
7889 cat "$tmp"/in >>"$tmp"/config.h
7890 rm -f "$tmp"/in
7891 if test x"$ac_file" != x-; then
7892 if cmp -s "$ac_file" "$tmp/config.h" 2>/dev/null; then
7893 { echo "$as_me:7893: $ac_file is unchanged" >&5
7894 echo "$as_me: $ac_file is unchanged" >&6;}
7895 else
7896 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7897 X"$ac_file" : 'X\(//\)[^/]' \| \
7898 X"$ac_file" : 'X\(//\)$' \| \
7899 X"$ac_file" : 'X\(/\)' \| \
7900 . : '\(.\)' 2>/dev/null ||
7901 echo X"$ac_file" |
7902 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
7903 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
7904 /^X\(\/\/\)$/{ s//\1/; q; }
7905 /^X\(\/\).*/{ s//\1/; q; }
7906 s/.*/./; q'`
7907 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
7908 { case "$ac_dir" in
7909 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
7910 *) as_incr_dir=.;;
7911 esac
7912 as_dummy="$ac_dir"
7913 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
7914 case $as_mkdir_dir in
7915 # Skip DOS drivespec
7916 ?:) as_incr_dir=$as_mkdir_dir ;;
7917 *)
7918 as_incr_dir=$as_incr_dir/$as_mkdir_dir
7919 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
7920 ;;
7921 esac
7922 done; }
7923
7924 fi
7925 rm -f "$ac_file"
7926 mv "$tmp/config.h" "$ac_file"
7927 fi
7928 else
7929 cat "$tmp"/config.h
7930 rm -f "$tmp"/config.h
7931 fi
7932 done
7933 EOF
7934
7935 cat >>"$CONFIG_STATUS" <<\EOF
7936
7937 { (exit 0); exit 0; }
7938 EOF
7939 chmod +x "$CONFIG_STATUS"
7940 ac_clean_files=$ac_clean_files_save
7941
7942 # configure is writing to config.log, and then calls config.status.
7943 # config.status does its own redirection, appending to config.log.
7944 # Unfortunately, on DOS this fails, as config.log is still kept open
7945 # by configure, so config.status won't be able to write to it; its
7946 # output is simply discarded. So we exec the FD to /dev/null,
7947 # effectively closing config.log, so it can be properly (re)opened and
7948 # appended to by config.status. When coming back to configure, we
7949 # need to make the FD available again.
7950 if test "$no_create" != yes; then
7951 ac_cs_success=:
7952 exec 5>/dev/null
7953 $SHELL "$CONFIG_STATUS" || ac_cs_success=false
7954 exec 5>>config.log
7955 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
7956 # would make configure fail if this is the last instruction.
7957 "$ac_cs_success" || { (exit 1); exit 1; }
7958 fi
7959
7960 test -z "$cf_make_docs" && cf_make_docs=0
7961
7962 cf_output=makefile
7963 test -f "$cf_output" || cf_output=Makefile
7964
7965 if test "$cf_make_docs" = 0
7966 then
7967 cat >>$cf_output <<CF_EOF
7968 ################################################################################
7969 ## generated by CF_MAKE_DOCS
7970 .SUFFIXES : .html .1 .man .ps .pdf .txt
7971
7972 ${NROFF_NOTE}.1.txt :
7973 ${NROFF_NOTE} \$(SHELL) -c "tbl \$*.1 | nroff -man | col -bx" >\$@
7974
7975 ${GROFF_NOTE}.ps.pdf :
7976 ${GROFF_NOTE} ps2pdf \$*.ps
7977 ${GROFF_NOTE}
7978 ${GROFF_NOTE}.1.ps :
7979 ${GROFF_NOTE} \$(SHELL) -c "tbl \$*.1 | groff -man" >\$@
7980 ${GROFF_NOTE}
7981 ${GROFF_NOTE}.1.txt :
7982 ${GROFF_NOTE} GROFF_NO_SGR=stupid \$(SHELL) -c "tbl \$*.1 | nroff -rHY=0 -Tascii -man | col -bx" >\$@
7983
7984 ${MAN2HTML_NOTE}.1.html :
7985 ${MAN2HTML_NOTE} ./${MAN2HTML_TEMP} \$* 1 man >\$@
7986
7987 CF_EOF
7988 cf_make_docs=1
7989 fi
7990
7991 for cf_name in '$(THIS)'
7992 do
7993 cat >>$cf_output <<CF_EOF
7994 ################################################################################
7995 ${NROFF_NOTE}docs docs-$cf_name :: $cf_name.txt
7996 ${MAN2HTML_NOTE}docs docs-$cf_name :: $cf_name.html
7997 ${GROFF_NOTE}docs docs-$cf_name :: $cf_name.pdf
7998 ${GROFF_NOTE}docs docs-$cf_name :: $cf_name.ps
7999 ${GROFF_NOTE}docs docs-$cf_name :: $cf_name.txt
8000
8001 clean \\
8002 docs-clean ::
8003 ${NROFF_NOTE} rm -f $cf_name.txt
8004 ${MAN2HTML_NOTE} rm -f $cf_name.html
8005 ${GROFF_NOTE} rm -f $cf_name.pdf
8006 ${GROFF_NOTE} rm -f $cf_name.ps
8007 ${GROFF_NOTE} rm -f $cf_name.txt
8008
8009 ${NROFF_NOTE}$cf_name.txt : $cf_name.1
8010 ${MAN2HTML_NOTE}$cf_name.html : $cf_name.1
8011 ${GROFF_NOTE}$cf_name.pdf : $cf_name.ps
8012 ${GROFF_NOTE}$cf_name.ps : $cf_name.1
8013 ${GROFF_NOTE}$cf_name.txt : $cf_name.1
8014 CF_EOF
8015 done
8016