* m4/Makefile.am.in: updated file
[findutils.git] / configure
blob343b52cdfbee35eb8a9009a60c50bab32b518683
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated automatically using Autoconf version 2.14a
4 # Copyright (C) 1992, 93, 94, 95, 96, 98, 1999 Free Software Foundation, Inc.
6 # This configure script is free software; the Free Software Foundation
7 # gives unlimited permission to copy, distribute and modify it.
9 # Defaults:
10 ac_arg_with_help=
11 ac_arg_enable_help=
12 ac_arg_var_help=
13 ac_default_prefix=/usr/local
14 # Factorizing default headers for most tests.
15 ac_includes_default="\
16 #include <stdio.h>
17 #include <sys/types.h>
18 #if STDC_HEADERS
19 # include <stdlib.h>
20 # include <stddef.h>
21 #else
22 # if HAVE_STDLIB_H
23 # include <stdlib.h>
24 # endif
25 #endif
26 #if HAVE_STRING_H
27 # if !STDC_HEADERS && HAVE_MEMORY_H
28 # include <memory.h>
29 # endif
30 # include <string.h>
31 #else
32 # if HAVE_STRINGS_H
33 # include <strings.h>
34 # endif
35 #endif
36 #if HAVE_UNISTD_H
37 # include <unistd.h>
38 #endif"
39 # Any additions from configure.in:
40 ac_arg_enable_help="$ac_arg_enable_help
41 --disable-dependency-tracking Speeds up one-time builds
42 --enable-dependency-tracking Do not reject slow dependency extractors"
43 ac_arg_enable_help="$ac_arg_enable_help
44 --enable-id-cache cache all UIDs & GIDs; avoid if using NIS or Hesiod"
45 ac_arg_with_help="$ac_arg_with_help
46 --with-afs support -fstype afs"
47 ac_arg_var_help="$ac_arg_var_help
48 CFLAGS Extra flags for the C compiler"
49 ac_arg_with_help="$ac_arg_with_help
50 --without-included-regex don't compile regex; this is the default on
51 systems with version 2 of the GNU C library
52 (use with caution on other system)"
53 ac_arg_enable_help="$ac_arg_enable_help
54 --disable-assert turn off assertions"
55 ac_arg_enable_help="$ac_arg_enable_help
56 --disable-nls do not use Native Language Support"
57 ac_arg_with_help="$ac_arg_with_help
58 --with-included-gettext use the GNU gettext library included here"
59 ac_arg_with_help="$ac_arg_with_help
60 --with-catgets use catgets functions if available"
62 # Initialize some variables set by options.
63 # The variables have the same names as the options, with
64 # dashes changed to underlines.
65 build=NONE
66 cache_file=./config.cache
67 exec_prefix=NONE
68 host=NONE
69 no_create=
70 nonopt=NONE
71 no_recursion=
72 prefix=NONE
73 program_prefix=NONE
74 program_suffix=NONE
75 program_transform_name=s,x,x,
76 silent=
77 site=
78 srcdir=
79 target=NONE
80 verbose=
81 x_includes=NONE
82 x_libraries=NONE
83 bindir='${exec_prefix}/bin'
84 sbindir='${exec_prefix}/sbin'
85 libexecdir='${exec_prefix}/libexec'
86 datadir='${prefix}/share'
87 sysconfdir='${prefix}/etc'
88 sharedstatedir='${prefix}/com'
89 localstatedir='${prefix}/var'
90 libdir='${exec_prefix}/lib'
91 includedir='${prefix}/include'
92 oldincludedir='/usr/include'
93 infodir='${prefix}/info'
94 mandir='${prefix}/man'
96 # Initialize some other variables.
97 subdirs=
98 MFLAGS= MAKEFLAGS=
99 SHELL=${CONFIG_SHELL-/bin/sh}
100 # Maximum number of lines to put in a shell here document.
101 : ${ac_max_here_lines=48}
102 # Sed expression to map a string onto a valid sh and CPP variable names.
103 ac_tr_sh='sed -e y%*+%pp%;s%[^a-zA-Z0-9_]%_%g'
104 ac_tr_cpp='sed -e y%*abcdefghijklmnopqrstuvwxyz%PABCDEFGHIJKLMNOPQRSTUVWXYZ%;s%[^A-Z0-9_]%_%g'
106 ac_prev=
107 for ac_option
109 # If the previous option needs an argument, assign it.
110 if test -n "$ac_prev"; then
111 eval "$ac_prev=\$ac_option"
112 ac_prev=
113 continue
116 ac_optarg=`echo "$ac_option" | sed -n 's/^[^=]*=//p'`
118 # Accept the important Cygnus configure options, so we can diagnose typos.
120 case "$ac_option" in
122 -bindir | --bindir | --bindi | --bind | --bin | --bi)
123 ac_prev=bindir ;;
124 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
125 bindir="$ac_optarg" ;;
127 -build | --build | --buil | --bui | --bu)
128 ac_prev=build ;;
129 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
130 build="$ac_optarg" ;;
132 -cache-file | --cache-file | --cache-fil | --cache-fi \
133 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
134 ac_prev=cache_file ;;
135 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
136 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
137 cache_file="$ac_optarg" ;;
139 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
140 ac_prev=datadir ;;
141 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
142 | --da=*)
143 datadir="$ac_optarg" ;;
145 -disable-* | --disable-*)
146 ac_feature=`echo "$ac_option"|sed -e 's/-*disable-//'`
147 # Reject names that are not valid shell variable names.
148 if echo "$ac_feature" | grep '[^-a-zA-Z0-9_]' >/dev/null 2>&1; then
149 { echo "configure: error: invalid feature: $ac_feature" 1>&2; exit 1; }
151 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
152 eval "enable_${ac_feature}=no" ;;
154 -enable-* | --enable-*)
155 ac_feature=`echo "$ac_option"|sed -e 's/-*enable-//' -e 's/=.*//'`
156 # Reject names that are not valid shell variable names.
157 if echo "$ac_feature" | grep '[^-a-zA-Z0-9_]' >/dev/null 2>&1; then
158 { echo "configure: error: invalid feature: $ac_feature" 1>&2; exit 1; }
160 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
161 case "$ac_option" in
162 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
163 *) ac_optarg=yes ;;
164 esac
165 eval "enable_${ac_feature}='$ac_optarg'" ;;
167 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
168 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
169 | --exec | --exe | --ex)
170 ac_prev=exec_prefix ;;
171 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
172 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
173 | --exec=* | --exe=* | --ex=*)
174 exec_prefix="$ac_optarg" ;;
176 -gas | --gas | --ga | --g)
177 # Obsolete; use --with-gas.
178 with_gas=yes ;;
180 -help | --help | --hel | --he | -h)
181 # Omit some internal or obsolete options to make the list less imposing.
182 # This message is too long to be a string in the A/UX 3.1 sh.
183 cat <<\EOF
184 `configure' configures software source code packages to adapt to many kinds
185 of systems.
187 Usage: configure [OPTION]... [VAR=VALUE]... [HOST]
189 To safely assign special values to environment variables (e.g., CC,
190 CFLAGS...), give to `configure' the definition as VAR=VALUE.
192 Defaults for the options are specified in brackets.
194 Configuration:
195 -h, --help print this message
196 --version print the version of autoconf that created configure
197 -q, --quiet, --silent do not print \`checking...' messages
198 --cache-file=FILE cache test results in FILE
199 -n, --no-create do not create output files
201 Directories:
202 --prefix=PREFIX install architecture-independent files in PREFIX
203 [$ac_default_prefix]
204 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
205 [same as prefix]
206 --bindir=DIR user executables in DIR [EPREFIX/bin]
207 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
208 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
209 --datadir=DIR read-only architecture-independent data in DIR
210 [PREFIX/share]
211 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
212 --sharedstatedir=DIR modifiable architecture-independent data in DIR
213 [PREFIX/com]
214 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
215 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
216 --includedir=DIR C header files in DIR [PREFIX/include]
217 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
218 --infodir=DIR info documentation in DIR [PREFIX/info]
219 --mandir=DIR man documentation in DIR [PREFIX/man]
220 --srcdir=DIR find the sources in DIR [configure dir or ..]
222 Program names:
223 --program-prefix=PREFIX prepend PREFIX to installed program names
224 --program-suffix=SUFFIX append SUFFIX to installed program names
225 --program-transform-name=PROGRAM
226 run sed PROGRAM on installed program names
229 cat <<\EOF
230 Host type:
231 --build=BUILD configure for building on BUILD [BUILD=HOST]
232 --host=HOST configure for HOST [guessed]
233 --target=TARGET configure for TARGET [TARGET=HOST]
235 X features:
236 --x-includes=DIR X include files are in DIR
237 --x-libraries=DIR X library files are in DIR
239 test -n "$ac_arg_enable_help" && echo "
240 Optional features:
241 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
242 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]\
243 $ac_arg_enable_help"
244 test -n "$ac_arg_with_help" && echo "
245 Optional packages:
246 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
247 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)\
248 $ac_arg_with_help"
249 test -n "$ac_arg_var_help" && echo "
250 Some influent environment variables:$ac_arg_var_help"
251 exit 0 ;;
253 -host | --host | --hos | --ho)
254 ac_prev=host ;;
255 -host=* | --host=* | --hos=* | --ho=*)
256 host="$ac_optarg" ;;
258 -includedir | --includedir | --includedi | --included | --include \
259 | --includ | --inclu | --incl | --inc)
260 ac_prev=includedir ;;
261 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
262 | --includ=* | --inclu=* | --incl=* | --inc=*)
263 includedir="$ac_optarg" ;;
265 -infodir | --infodir | --infodi | --infod | --info | --inf)
266 ac_prev=infodir ;;
267 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
268 infodir="$ac_optarg" ;;
270 -libdir | --libdir | --libdi | --libd)
271 ac_prev=libdir ;;
272 -libdir=* | --libdir=* | --libdi=* | --libd=*)
273 libdir="$ac_optarg" ;;
275 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
276 | --libexe | --libex | --libe)
277 ac_prev=libexecdir ;;
278 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
279 | --libexe=* | --libex=* | --libe=*)
280 libexecdir="$ac_optarg" ;;
282 -localstatedir | --localstatedir | --localstatedi | --localstated \
283 | --localstate | --localstat | --localsta | --localst \
284 | --locals | --local | --loca | --loc | --lo)
285 ac_prev=localstatedir ;;
286 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
287 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
288 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
289 localstatedir="$ac_optarg" ;;
291 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
292 ac_prev=mandir ;;
293 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
294 mandir="$ac_optarg" ;;
296 -nfp | --nfp | --nf)
297 # Obsolete; use --without-fp.
298 with_fp=no ;;
300 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
301 | --no-cr | --no-c)
302 no_create=yes ;;
304 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
305 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
306 no_recursion=yes ;;
308 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
309 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
310 | --oldin | --oldi | --old | --ol | --o)
311 ac_prev=oldincludedir ;;
312 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
313 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
314 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
315 oldincludedir="$ac_optarg" ;;
317 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
318 ac_prev=prefix ;;
319 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
320 prefix="$ac_optarg" ;;
322 -program-prefix | --program-prefix | --program-prefi | --program-pref \
323 | --program-pre | --program-pr | --program-p)
324 ac_prev=program_prefix ;;
325 -program-prefix=* | --program-prefix=* | --program-prefi=* \
326 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
327 program_prefix="$ac_optarg" ;;
329 -program-suffix | --program-suffix | --program-suffi | --program-suff \
330 | --program-suf | --program-su | --program-s)
331 ac_prev=program_suffix ;;
332 -program-suffix=* | --program-suffix=* | --program-suffi=* \
333 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
334 program_suffix="$ac_optarg" ;;
336 -program-transform-name | --program-transform-name \
337 | --program-transform-nam | --program-transform-na \
338 | --program-transform-n | --program-transform- \
339 | --program-transform | --program-transfor \
340 | --program-transfo | --program-transf \
341 | --program-trans | --program-tran \
342 | --progr-tra | --program-tr | --program-t)
343 ac_prev=program_transform_name ;;
344 -program-transform-name=* | --program-transform-name=* \
345 | --program-transform-nam=* | --program-transform-na=* \
346 | --program-transform-n=* | --program-transform-=* \
347 | --program-transform=* | --program-transfor=* \
348 | --program-transfo=* | --program-transf=* \
349 | --program-trans=* | --program-tran=* \
350 | --progr-tra=* | --program-tr=* | --program-t=*)
351 program_transform_name="$ac_optarg" ;;
353 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
354 | -silent | --silent | --silen | --sile | --sil)
355 silent=yes ;;
357 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
358 ac_prev=sbindir ;;
359 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
360 | --sbi=* | --sb=*)
361 sbindir="$ac_optarg" ;;
363 -sharedstatedir | --sharedstatedir | --sharedstatedi \
364 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
365 | --sharedst | --shareds | --shared | --share | --shar \
366 | --sha | --sh)
367 ac_prev=sharedstatedir ;;
368 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
369 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
370 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
371 | --sha=* | --sh=*)
372 sharedstatedir="$ac_optarg" ;;
374 -site | --site | --sit)
375 ac_prev=site ;;
376 -site=* | --site=* | --sit=*)
377 site="$ac_optarg" ;;
379 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
380 ac_prev=srcdir ;;
381 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
382 srcdir="$ac_optarg" ;;
384 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
385 | --syscon | --sysco | --sysc | --sys | --sy)
386 ac_prev=sysconfdir ;;
387 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
388 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
389 sysconfdir="$ac_optarg" ;;
391 -target | --target | --targe | --targ | --tar | --ta | --t)
392 ac_prev=target ;;
393 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
394 target="$ac_optarg" ;;
396 -v | -verbose | --verbose | --verbos | --verbo | --verb)
397 verbose=yes ;;
399 -version | --version | --versio | --versi | --vers)
400 echo "configure generated by autoconf version 2.14a"
401 exit 0 ;;
403 -with-* | --with-*)
404 ac_package=`echo "$ac_option"|sed -e 's/-*with-//' -e 's/=.*//'`
405 # Reject names that are not valid shell variable names.
406 if echo "$ac_feature" | grep '[^-a-zA-Z0-9_]' >/dev/null 2>&1; then
407 { echo "configure: error: invalid package: $ac_package" 1>&2; exit 1; }
409 ac_package=`echo $ac_package| sed 's/-/_/g'`
410 case "$ac_option" in
411 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
412 *) ac_optarg=yes ;;
413 esac
414 eval "with_${ac_package}='$ac_optarg'" ;;
416 -without-* | --without-*)
417 ac_package=`echo "$ac_option"|sed -e 's/-*without-//'`
418 # Reject names that are not valid shell variable names.
419 if echo "$ac_feature" | grep '[^-a-zA-Z0-9_]' >/dev/null 2>&1; then
420 { echo "configure: error: invalid package: $ac_package" 1>&2; exit 1; }
422 ac_package=`echo $ac_package| sed 's/-/_/g'`
423 eval "with_${ac_package}=no" ;;
425 --x)
426 # Obsolete; use --with-x.
427 with_x=yes ;;
429 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
430 | --x-incl | --x-inc | --x-in | --x-i)
431 ac_prev=x_includes ;;
432 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
433 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
434 x_includes="$ac_optarg" ;;
436 -x-libraries | --x-libraries | --x-librarie | --x-librari \
437 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
438 ac_prev=x_libraries ;;
439 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
440 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
441 x_libraries="$ac_optarg" ;;
443 -*) { echo "configure: error: unrecognized option: $ac_option
444 Try \`configure --help' for more information." 1>&2; exit 1; }
447 *=*)
448 ac_envvar=`echo "$ac_option" | sed -e 's/=.*//'`
449 # Reject names that are not valid shell variable names.
450 if echo "$ac_envvar" | grep '[^a-zA-Z0-9_]' >/dev/null 2>&1; then
451 { echo "configure: error: invalid variable name: $ac_envvar" 1>&2; exit 1; }
453 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
454 eval "$ac_envvar='$ac_optarg'"
455 export $ac_envvar ;;
458 if echo "$ac_feature" | grep '[^-a-zA-Z0-9.]' >/dev/null 2>&1; then
459 echo "configure: warning: invalid host type: $ac_option" 1>&2
461 if test "x$nonopt" != xNONE; then
462 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
464 nonopt="$ac_option"
467 esac
468 done
470 if test -n "$ac_prev"; then
471 { echo "configure: error: missing argument to --\`echo $ac_prev | sed 's/_/-/g'\`" 1>&2; exit 1; }
474 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
476 # File descriptor usage:
477 # 0 standard input
478 # 1 file creation
479 # 2 errors and warnings
480 # 3 some systems may open it to /dev/tty
481 # 4 used on the Kubota Titan
482 # 6 checking for... messages and results
483 # 5 compiler messages saved in config.log
484 if test "$silent" = yes; then
485 exec 6>/dev/null
486 else
487 exec 6>&1
489 exec 5>./config.log
491 echo "\
492 This file contains any messages produced by compilers while
493 running configure, to aid debugging if configure makes a mistake.
494 " 1>&5
496 # Strip out --no-create and --no-recursion so they do not pile up.
497 # Also quote any args containing shell meta-characters.
498 ac_configure_args=
499 for ac_arg
501 case "$ac_arg" in
502 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
503 | --no-cr | --no-c) ;;
504 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
505 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
506 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
507 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
508 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
509 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
510 esac
511 done
513 # NLS nuisances.
514 # Only set these to C if already set. These must not be set unconditionally
515 # because not all systems understand e.g. LANG=C (notably SCO).
516 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
517 # Non-C LC_CTYPE values break the ctype check.
518 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
519 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
520 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
521 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
523 # confdefs.h avoids OS command line length limits that DEFS can exceed.
524 rm -rf conftest* confdefs.h
525 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
526 echo >confdefs.h
528 # A filename unique to this package, relative to the directory that
529 # configure is in, which we can look for to find out if srcdir is correct.
530 ac_unique_file=find/pred.c
532 # Find the source files, if location was not specified.
533 if test -z "$srcdir"; then
534 ac_srcdir_defaulted=yes
535 # Try the directory containing this script, then its parent.
536 ac_prog=$0
537 ac_confdir=`echo "$ac_prog" | sed 's%/[^/][^/]*$%%'`
538 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
539 srcdir=$ac_confdir
540 if test ! -r $srcdir/$ac_unique_file; then
541 srcdir=..
543 else
544 ac_srcdir_defaulted=no
546 if test ! -r $srcdir/$ac_unique_file; then
547 if test "$ac_srcdir_defaulted" = yes; then
548 { echo "configure: error: cannot find sources in $ac_confdir or .." 1>&2; exit 1; }
549 else
550 { echo "configure: error: cannot find sources in $srcdir" 1>&2; exit 1; }
553 srcdir=`echo "$srcdir" | sed 's%\([^/]\)/*$%\1%'`
555 # Prefer explicitly selected file to automatically selected ones.
556 if test -z "$CONFIG_SITE"; then
557 if test "x$prefix" != xNONE; then
558 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
559 else
560 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
563 for ac_site_file in $CONFIG_SITE; do
564 if test -r "$ac_site_file"; then
565 echo "loading site script $ac_site_file"
566 . "$ac_site_file"
568 done
570 if test -r "$cache_file"; then
571 echo "loading cache $cache_file"
572 test -f "$cache_file" && . $cache_file
573 else
574 echo "creating cache $cache_file"
575 >$cache_file
578 ac_ext=c
579 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
580 ac_cpp='$CPP $CPPFLAGS'
581 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
582 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
583 cross_compiling=$ac_cv_prog_cc_cross
585 ac_exeext=
586 ac_objext=o
587 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
588 # Stardent Vistra SVR4 grep lacks -e, says Kaveh Ghazi
589 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
590 ac_n= ac_c='
591 ' ac_t=' '
592 else
593 ac_n=-n ac_c= ac_t=
595 else
596 ac_n= ac_c='\c' ac_t=
599 ALL_LINGUAS=" de es fr it ko nl pl pt_BR ru sv gl et"
601 ac_aux_dir=
602 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
603 if test -f $ac_dir/install-sh; then
604 ac_aux_dir=$ac_dir
605 ac_install_sh="$ac_aux_dir/install-sh -c"
606 break
607 elif test -f $ac_dir/install.sh; then
608 ac_aux_dir=$ac_dir
609 ac_install_sh="$ac_aux_dir/install.sh -c"
610 break
611 elif test -f $ac_dir/shtool; then
612 ac_aux_dir=$ac_dir
613 ac_install_sh="$ac_aux_dir/shtool install -c"
614 break
616 done
617 if test -z "$ac_aux_dir"; then
618 { echo "configure: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
620 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
621 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
622 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
624 # Find a good install program. We prefer a C program (faster),
625 # so one script is as good as another. But avoid the broken or
626 # incompatible versions:
627 # SysV /etc/install, /usr/sbin/install
628 # SunOS /usr/etc/install
629 # IRIX /sbin/install
630 # AIX /bin/install
631 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
632 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
633 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
634 # ./install, which can be erroneously created by make from ./install.sh.
635 echo $ac_n "checking for a BSD compatible install... $ac_c" 1>&6
636 echo "configure:637: checking for a BSD compatible install" 1>&5
637 if test -z "$INSTALL"; then
638 if test "${ac_cv_path_install+set}" = set; then
639 echo $ac_n "(cached) $ac_c" 1>&6
640 else
641 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
642 for ac_dir in $PATH; do
643 # Account for people who put trailing slashes in PATH elements.
644 case "$ac_dir/" in
645 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
647 # OSF1 and SCO ODT 3.0 have their own names for install.
648 # Don't use installbsd from OSF since it installs stuff as root
649 # by default.
650 for ac_prog in ginstall scoinst install; do
651 if test -f $ac_dir/$ac_prog; then
652 if test $ac_prog = install &&
653 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
654 # AIX install. It has an incompatible calling convention.
656 elif test $ac_prog = install &&
657 grep pwplus $ac_dir/$ac_prog >/dev/null 2>&1; then
658 # program-specific install script used by HP pwplus--don't use.
660 else
661 ac_cv_path_install="$ac_dir/$ac_prog -c"
662 break 2
665 done
667 esac
668 done
669 IFS="$ac_save_IFS"
672 if test "${ac_cv_path_install+set}" = set; then
673 INSTALL="$ac_cv_path_install"
674 else
675 # As a last resort, use the slow shell script. We don't cache a
676 # path for INSTALL within a source directory, because that will
677 # break other packages using the cache if that directory is
678 # removed, or if the path is relative.
679 INSTALL="$ac_install_sh"
682 echo "$ac_t""$INSTALL" 1>&6
684 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
685 # It thinks the first close brace ends the variable substitution.
686 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
688 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
690 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
692 echo $ac_n "checking whether build environment is sane... $ac_c" 1>&6
693 echo "configure:694: checking whether build environment is sane" 1>&5
694 # Just in case
695 sleep 1
696 echo timestamp > conftestfile
697 # Do `set' in a subshell so we don't clobber the current shell's
698 # arguments. Must try -L first in case configure is actually a
699 # symlink; some systems play weird games with the mod time of symlinks
700 # (eg FreeBSD returns the mod time of the symlink's containing
701 # directory).
702 if (
703 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
704 if test "$*" = "X"; then
705 # -L didn't work.
706 set X `ls -t $srcdir/configure conftestfile`
708 if test "$*" != "X $srcdir/configure conftestfile" \
709 && test "$*" != "X conftestfile $srcdir/configure"; then
711 # If neither matched, then we have a broken ls. This can happen
712 # if, for instance, CONFIG_SHELL is bash and it inherits a
713 # broken ls alias from the environment. This has actually
714 # happened. Such a system could not be considered "sane".
715 { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
716 alias in your environment" 1>&2; exit 1; }
719 test "$2" = conftestfile
721 then
722 # Ok.
724 else
725 { echo "configure: error: newly created file is older than distributed files!
726 Check your system clock" 1>&2; exit 1; }
728 rm -f conftest*
729 echo "$ac_t""yes" 1>&6
730 if test "$program_transform_name" = s,x,x,; then
731 program_transform_name=
732 else
733 # Double any \ or $. echo might interpret backslashes.
734 cat <<\EOF_SED >conftestsed
735 s,\\,\\\\,g; s,\$,$$,g
736 EOF_SED
737 program_transform_name=`echo $program_transform_name|sed -f conftestsed`
738 rm -f conftestsed
740 test "$program_prefix" != NONE &&
741 program_transform_name="s,^,${program_prefix},;$program_transform_name"
742 # Use a double $ so make ignores it.
743 test "$program_suffix" != NONE &&
744 program_transform_name="s,\$\$,${program_suffix},;$program_transform_name"
746 # sed with no file args requires a program.
747 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
749 test x"${MISSING+set}" = xset || \
750 MISSING="\${SHELL} `CDPATH=: && cd $ac_aux_dir && pwd`/missing"
751 if eval "$MISSING --run :"; then
752 am_missing_run="$MISSING --run "
753 else
754 am_missing_run=
755 echo "configure: warning: \`missing' script is too old or missing" 1>&2
758 for ac_prog in mawk gawk nawk awk
760 # Extract the first word of "$ac_prog", so it can be a program name with args.
761 set dummy $ac_prog; ac_word=$2
762 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
763 echo "configure:764: checking for $ac_word" 1>&5
764 if test "${ac_cv_prog_AWK+set}" = set; then
765 echo $ac_n "(cached) $ac_c" 1>&6
766 else
767 if test -n "$AWK"; then
768 ac_cv_prog_AWK="$AWK" # Let the user override the test.
769 else
770 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
771 ac_dummy="$PATH"
772 for ac_dir in $ac_dummy; do
773 test -z "$ac_dir" && ac_dir=.
774 if test -f $ac_dir/$ac_word; then
775 ac_cv_prog_AWK="$ac_prog"
776 break
778 done
779 IFS="$ac_save_ifs"
782 AWK="$ac_cv_prog_AWK"
783 if test -n "$AWK"; then
784 echo "$ac_t""$AWK" 1>&6
785 else
786 echo "$ac_t""no" 1>&6
789 test -n "$AWK" && break
790 done
792 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}... $ac_c" 1>&6
793 echo "configure:794: checking whether ${MAKE-make} sets \${MAKE}" 1>&5
794 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
795 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
796 echo $ac_n "(cached) $ac_c" 1>&6
797 else
798 cat >conftestmake <<\EOF
799 all:
800 @echo 'ac_maketemp="${MAKE}"'
802 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
803 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
804 if test -n "$ac_maketemp"; then
805 eval ac_cv_prog_make_${ac_make}_set=yes
806 else
807 eval ac_cv_prog_make_${ac_make}_set=no
809 rm -f conftestmake
811 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
812 echo "$ac_t""yes" 1>&6
813 SET_MAKE=
814 else
815 echo "$ac_t""no" 1>&6
816 SET_MAKE="MAKE=${MAKE-make}"
819 # Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
820 if test "${enable_dependency_tracking+set}" = set; then
821 enableval="$enable_dependency_tracking"
825 if test "x$enable_dependency_tracking" = xno; then
826 AMDEP="#"
827 else
828 am_depcomp="$ac_aux_dir/depcomp"
829 if test ! -f "$am_depcomp"; then
830 AMDEP="#"
831 else
832 AMDEP=
836 if test -z "$AMDEP"; then
837 AMDEPBACKSLASH='\'
838 else
839 AMDEPBACKSLASH=
842 if test -d .deps || mkdir .deps 2> /dev/null || test -d .deps; then
843 DEPDIR=.deps
844 else
845 DEPDIR=_deps
848 PACKAGE=findutils
850 VERSION=4.1.4
852 if test "`CDPATH=: && cd $srcdir && pwd`" != "`pwd`" &&
853 test -f $srcdir/config.status; then
854 { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
856 cat >>confdefs.h <<EOF
857 #define PACKAGE "$PACKAGE"
860 cat >>confdefs.h <<EOF
861 #define VERSION "$VERSION"
864 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal"}
866 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
868 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake"}
870 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
872 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
874 AMTAR=${AMTAR-"${am_missing_run}tar"}
876 if test -z "$install_sh"; then
877 install_sh="$ac_aux_dir/install-sh"
878 test -f "$install_sh" || install_sh="$ac_aux_dir/install.sh"
879 test -f "$install_sh" || install_sh="${am_missing_run}${ac_auxdir}/install-sh"
880 install_sh="`echo $install_sh | sed -e 's/\${SHELL}//'`"
883 # Check whether --enable-id-cache or --disable-id-cache was given.
884 if test "${enable_id_cache+set}" = set; then
885 enableval="$enable_id_cache"
886 cat >>confdefs.h <<\EOF
887 #define CACHE_IDS 1
892 # Check whether --with-afs or --without-afs was given.
893 if test "${with_afs+set}" = set; then
894 withval="$with_afs"
895 cat >>confdefs.h <<\EOF
896 #define AFS 1
899 CPPFLAGS="$CPPFLAGS -I/usr/afsws/include"
900 LIBS="$LIBS -L/usr/afsws/lib -L/usr/afsws/lib/afs -lsys -lrx -llwp"
903 case "${CFLAGS+set} $ac_configure_args" in
904 *" CFLAGS="* );;
905 "set "*) ac_configure_args="CFLAGS='$CFLAGS' $ac_configure_args";;
906 esac
908 # Extract the first word of "gcc", so it can be a program name with args.
909 set dummy gcc; ac_word=$2
910 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
911 echo "configure:912: checking for $ac_word" 1>&5
912 if test "${ac_cv_prog_CC+set}" = set; then
913 echo $ac_n "(cached) $ac_c" 1>&6
914 else
915 if test -n "$CC"; then
916 ac_cv_prog_CC="$CC" # Let the user override the test.
917 else
918 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
919 ac_dummy="$PATH"
920 for ac_dir in $ac_dummy; do
921 test -z "$ac_dir" && ac_dir=.
922 if test -f $ac_dir/$ac_word; then
923 ac_cv_prog_CC="gcc"
924 break
926 done
927 IFS="$ac_save_ifs"
930 CC="$ac_cv_prog_CC"
931 if test -n "$CC"; then
932 echo "$ac_t""$CC" 1>&6
933 else
934 echo "$ac_t""no" 1>&6
937 if test -z "$CC"; then
938 # Extract the first word of "cc", so it can be a program name with args.
939 set dummy cc; ac_word=$2
940 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
941 echo "configure:942: checking for $ac_word" 1>&5
942 if test "${ac_cv_prog_CC+set}" = set; then
943 echo $ac_n "(cached) $ac_c" 1>&6
944 else
945 if test -n "$CC"; then
946 ac_cv_prog_CC="$CC" # Let the user override the test.
947 else
948 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
949 ac_prog_rejected=no
950 ac_dummy="$PATH"
951 for ac_dir in $ac_dummy; do
952 test -z "$ac_dir" && ac_dir=.
953 if test -f $ac_dir/$ac_word; then
954 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
955 ac_prog_rejected=yes
956 continue
958 ac_cv_prog_CC="cc"
959 break
961 done
962 IFS="$ac_save_ifs"
963 if test $ac_prog_rejected = yes; then
964 # We found a bogon in the path, so make sure we never use it.
965 set dummy $ac_cv_prog_CC
966 shift
967 if test $# -gt 0; then
968 # We chose a different compiler from the bogus one.
969 # However, it has the same basename, so the bogon will be chosen
970 # first if we set CC to just the basename; use the full file name.
971 shift
972 set dummy "$ac_dir/$ac_word" "$@"
973 shift
974 ac_cv_prog_CC="$@"
979 CC="$ac_cv_prog_CC"
980 if test -n "$CC"; then
981 echo "$ac_t""$CC" 1>&6
982 else
983 echo "$ac_t""no" 1>&6
986 if test -z "$CC"; then
987 for ac_prog in cl
989 # Extract the first word of "$ac_prog", so it can be a program name with args.
990 set dummy $ac_prog; ac_word=$2
991 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
992 echo "configure:993: checking for $ac_word" 1>&5
993 if test "${ac_cv_prog_CC+set}" = set; then
994 echo $ac_n "(cached) $ac_c" 1>&6
995 else
996 if test -n "$CC"; then
997 ac_cv_prog_CC="$CC" # Let the user override the test.
998 else
999 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1000 ac_dummy="$PATH"
1001 for ac_dir in $ac_dummy; do
1002 test -z "$ac_dir" && ac_dir=.
1003 if test -f $ac_dir/$ac_word; then
1004 ac_cv_prog_CC="$ac_prog"
1005 break
1007 done
1008 IFS="$ac_save_ifs"
1011 CC="$ac_cv_prog_CC"
1012 if test -n "$CC"; then
1013 echo "$ac_t""$CC" 1>&6
1014 else
1015 echo "$ac_t""no" 1>&6
1018 test -n "$CC" && break
1019 done
1024 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1026 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) works... $ac_c" 1>&6
1027 echo "configure:1028: checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) works" 1>&5
1029 ac_ext=c
1030 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1031 ac_cpp='$CPP $CPPFLAGS'
1032 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1033 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1034 cross_compiling=$ac_cv_prog_cc_cross
1036 cat >conftest.$ac_ext <<EOF
1038 #line 1039 "configure"
1039 #include "confdefs.h"
1041 int main(){return(0);}
1043 if { (eval echo configure:1044: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1044 ac_cv_prog_cc_works=yes
1045 # If we can't run a trivial program, we are probably using a cross compiler.
1046 if (./conftest; exit) 2>/dev/null; then
1047 ac_cv_prog_cc_cross=no
1048 else
1049 ac_cv_prog_cc_cross=yes
1051 else
1052 echo "configure: failed program was:" >&5
1053 cat conftest.$ac_ext >&5
1054 ac_cv_prog_cc_works=no
1056 rm -fr conftest*
1057 ac_ext=c
1058 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1059 ac_cpp='$CPP $CPPFLAGS'
1060 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1061 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1062 cross_compiling=$ac_cv_prog_cc_cross
1064 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1065 if test $ac_cv_prog_cc_works = no; then
1066 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 77; }
1068 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) is a cross-compiler... $ac_c" 1>&6
1069 echo "configure:1070: checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) is a cross-compiler" 1>&5
1070 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1071 cross_compiling=$ac_cv_prog_cc_cross
1073 echo $ac_n "checking whether we are using GNU C... $ac_c" 1>&6
1074 echo "configure:1075: checking whether we are using GNU C" 1>&5
1075 if test "${ac_cv_prog_gcc+set}" = set; then
1076 echo $ac_n "(cached) $ac_c" 1>&6
1077 else
1078 cat >conftest.c <<EOF
1079 #ifdef __GNUC__
1080 yes;
1081 #endif
1083 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1084: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1084 ac_cv_prog_gcc=yes
1085 else
1086 ac_cv_prog_gcc=no
1089 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1091 if test $ac_cv_prog_gcc = yes; then
1092 GCC=yes
1093 else
1094 GCC=
1097 ac_test_CFLAGS="${CFLAGS+set}"
1098 ac_save_CFLAGS="$CFLAGS"
1099 CFLAGS=
1100 echo $ac_n "checking whether ${CC-cc} accepts -g... $ac_c" 1>&6
1101 echo "configure:1102: checking whether ${CC-cc} accepts -g" 1>&5
1102 if test "${ac_cv_prog_cc_g+set}" = set; then
1103 echo $ac_n "(cached) $ac_c" 1>&6
1104 else
1105 echo 'void f(){}' >conftest.c
1106 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1107 ac_cv_prog_cc_g=yes
1108 else
1109 ac_cv_prog_cc_g=no
1111 rm -f conftest*
1114 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1115 if test "$ac_test_CFLAGS" = set; then
1116 CFLAGS="$ac_save_CFLAGS"
1117 elif test $ac_cv_prog_cc_g = yes; then
1118 if test "$GCC" = yes; then
1119 CFLAGS="-g -O2"
1120 else
1121 CFLAGS="-g"
1123 else
1124 if test "$GCC" = yes; then
1125 CFLAGS="-O2"
1126 else
1127 CFLAGS=
1131 echo $ac_n "checking how to run the C preprocessor... $ac_c" 1>&6
1132 echo "configure:1133: checking how to run the C preprocessor" 1>&5
1133 # On Suns, sometimes $CPP names a directory.
1134 if test -n "$CPP" && test -d "$CPP"; then
1135 CPP=
1137 if test -z "$CPP"; then
1138 if test "${ac_cv_prog_CPP+set}" = set; then
1139 echo $ac_n "(cached) $ac_c" 1>&6
1140 else
1141 # This must be in double quotes, not single quotes, because CPP may get
1142 # substituted into the Makefile and "${CC-cc}" will confuse make.
1143 CPP="${CC-cc} -E"
1144 # On the NeXT, cc -E runs the code through the compiler's parser,
1145 # not just through cpp.
1146 cat >conftest.$ac_ext <<EOF
1147 #line 1148 "configure"
1148 #include "confdefs.h"
1149 #include <assert.h>
1150 Syntax Error
1152 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1153 { (eval echo configure:1154: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1154 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1155 if test -z "$ac_err"; then
1157 else
1158 echo "$ac_err" >&5
1159 echo "configure: failed program was:" >&5
1160 cat conftest.$ac_ext >&5
1161 rm -rf conftest*
1162 CPP="${CC-cc} -E -traditional-cpp"
1163 cat >conftest.$ac_ext <<EOF
1164 #line 1165 "configure"
1165 #include "confdefs.h"
1166 #include <assert.h>
1167 Syntax Error
1169 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1170 { (eval echo configure:1171: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1171 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1172 if test -z "$ac_err"; then
1174 else
1175 echo "$ac_err" >&5
1176 echo "configure: failed program was:" >&5
1177 cat conftest.$ac_ext >&5
1178 rm -rf conftest*
1179 CPP="${CC-cc} -nologo -E"
1180 cat >conftest.$ac_ext <<EOF
1181 #line 1182 "configure"
1182 #include "confdefs.h"
1183 #include <assert.h>
1184 Syntax Error
1186 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1187 { (eval echo configure:1188: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1188 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1189 if test -z "$ac_err"; then
1191 else
1192 echo "$ac_err" >&5
1193 echo "configure: failed program was:" >&5
1194 cat conftest.$ac_ext >&5
1195 rm -rf conftest*
1196 CPP=/lib/cpp
1198 rm -f conftest*
1200 rm -f conftest*
1202 rm -f conftest*
1203 ac_cv_prog_CPP="$CPP"
1205 CPP="$ac_cv_prog_CPP"
1206 else
1207 ac_cv_prog_CPP="$CPP"
1209 echo "$ac_t""$CPP" 1>&6
1211 depcc="$CC"
1212 depcpp="$CPP"
1213 echo $ac_n "checking dependency style of $depcc... $ac_c" 1>&6
1214 echo "configure:1215: checking dependency style of $depcc" 1>&5
1215 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
1216 echo $ac_n "(cached) $ac_c" 1>&6
1217 else
1219 if test -z "$AMDEP"; then
1220 echo '#include "conftest.h"' > conftest.c
1221 echo 'int i;' > conftest.h
1223 am_cv_CC_dependencies_compiler_type=none
1224 for depmode in `sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < "$am_depcomp"`; do
1225 case "$depmode" in
1226 nosideeffect)
1227 # after this tag, mechanisms are not by side-effect, so they'll
1228 # only be used when explicitly requested
1229 if test "x$enable_dependency_tracking" = xyes; then
1230 continue
1231 else
1232 break
1235 none) break ;;
1236 esac
1237 if depmode="$depmode" \
1238 source=conftest.c object=conftest.o \
1239 depfile=conftest.Po tmpdepfile=conftest.TPo \
1240 $SHELL $am_depcomp $depcc -c conftest.c 2>/dev/null &&
1241 grep conftest.h conftest.Po > /dev/null 2>&1; then
1242 am_cv_CC_dependencies_compiler_type="$depmode"
1243 break
1245 done
1247 rm -f conftest.*
1248 else
1249 am_cv_CC_dependencies_compiler_type=none
1254 echo "$ac_t""$am_cv_CC_dependencies_compiler_type" 1>&6
1255 CCDEPMODE="depmode=$am_cv_CC_dependencies_compiler_type"
1257 echo $ac_n "checking how to run the C preprocessor... $ac_c" 1>&6
1258 echo "configure:1259: checking how to run the C preprocessor" 1>&5
1259 # On Suns, sometimes $CPP names a directory.
1260 if test -n "$CPP" && test -d "$CPP"; then
1261 CPP=
1263 if test -z "$CPP"; then
1264 if test "${ac_cv_prog_CPP+set}" = set; then
1265 echo $ac_n "(cached) $ac_c" 1>&6
1266 else
1267 # This must be in double quotes, not single quotes, because CPP may get
1268 # substituted into the Makefile and "${CC-cc}" will confuse make.
1269 CPP="${CC-cc} -E"
1270 # On the NeXT, cc -E runs the code through the compiler's parser,
1271 # not just through cpp.
1272 cat >conftest.$ac_ext <<EOF
1273 #line 1274 "configure"
1274 #include "confdefs.h"
1275 #include <assert.h>
1276 Syntax Error
1278 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1279 { (eval echo configure:1280: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1280 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1281 if test -z "$ac_err"; then
1283 else
1284 echo "$ac_err" >&5
1285 echo "configure: failed program was:" >&5
1286 cat conftest.$ac_ext >&5
1287 rm -rf conftest*
1288 CPP="${CC-cc} -E -traditional-cpp"
1289 cat >conftest.$ac_ext <<EOF
1290 #line 1291 "configure"
1291 #include "confdefs.h"
1292 #include <assert.h>
1293 Syntax Error
1295 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1296 { (eval echo configure:1297: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1297 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1298 if test -z "$ac_err"; then
1300 else
1301 echo "$ac_err" >&5
1302 echo "configure: failed program was:" >&5
1303 cat conftest.$ac_ext >&5
1304 rm -rf conftest*
1305 CPP="${CC-cc} -nologo -E"
1306 cat >conftest.$ac_ext <<EOF
1307 #line 1308 "configure"
1308 #include "confdefs.h"
1309 #include <assert.h>
1310 Syntax Error
1312 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1313 { (eval echo configure:1314: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1314 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1315 if test -z "$ac_err"; then
1317 else
1318 echo "$ac_err" >&5
1319 echo "configure: failed program was:" >&5
1320 cat conftest.$ac_ext >&5
1321 rm -rf conftest*
1322 CPP=/lib/cpp
1324 rm -f conftest*
1326 rm -f conftest*
1328 rm -f conftest*
1329 ac_cv_prog_CPP="$CPP"
1331 CPP="$ac_cv_prog_CPP"
1332 else
1333 ac_cv_prog_CPP="$CPP"
1335 echo "$ac_t""$CPP" 1>&6
1337 echo $ac_n "checking for AIX... $ac_c" 1>&6
1338 echo "configure:1339: checking for AIX" 1>&5
1339 cat >conftest.$ac_ext <<EOF
1340 #line 1341 "configure"
1341 #include "confdefs.h"
1342 #ifdef _AIX
1344 #endif
1347 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1348 egrep "yes" >/dev/null 2>&1; then
1349 rm -rf conftest*
1350 echo "$ac_t""yes" 1>&6
1351 cat >>confdefs.h <<\EOF
1352 #define _ALL_SOURCE 1
1355 else
1356 rm -rf conftest*
1357 echo "$ac_t""no" 1>&6
1359 rm -f conftest*
1361 echo $ac_n "checking for minix/config.h... $ac_c" 1>&6
1362 echo "configure:1363: checking for minix/config.h" 1>&5
1363 if test "${ac_cv_header_minix_config_h+set}" = set; then
1364 echo $ac_n "(cached) $ac_c" 1>&6
1365 else
1366 cat >conftest.$ac_ext <<EOF
1367 #line 1368 "configure"
1368 #include "confdefs.h"
1369 #include <minix/config.h>
1372 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1373 { (eval echo configure:1374: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1374 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1375 if test -z "$ac_err"; then
1376 rm -rf conftest*
1377 ac_cv_header_minix_config_h=yes
1378 else
1379 echo "$ac_err" >&5
1380 echo "configure: failed program was:" >&5
1381 cat conftest.$ac_ext >&5
1382 rm -rf conftest*
1383 ac_cv_header_minix_config_h=no
1385 rm -f conftest*
1387 echo "$ac_t""$ac_cv_header_minix_config_h" 1>&6
1388 if test $ac_cv_header_minix_config_h = yes; then
1389 MINIX=yes
1390 else
1391 MINIX=
1394 if test "$MINIX" = yes; then
1395 cat >>confdefs.h <<\EOF
1396 #define _POSIX_SOURCE 1
1399 cat >>confdefs.h <<\EOF
1400 #define _POSIX_1_SOURCE 2
1403 cat >>confdefs.h <<\EOF
1404 #define _MINIX 1
1409 echo $ac_n "checking for strerror in -lcposix... $ac_c" 1>&6
1410 echo "configure:1411: checking for strerror in -lcposix" 1>&5
1411 if test "${ac_cv_lib_cposix_strerror+set}" = set; then
1412 echo $ac_n "(cached) $ac_c" 1>&6
1413 else
1414 ac_save_LIBS="$LIBS"
1415 LIBS="-lcposix $LIBS"
1416 cat >conftest.$ac_ext <<EOF
1417 #line 1418 "configure"
1418 #include "confdefs.h"
1419 /* Override any gcc2 internal prototype to avoid an error. */
1420 /* We use char because int might match the return type of a gcc2
1421 builtin and then its argument prototype would still apply. */
1422 char strerror();
1425 main()
1427 strerror()
1429 return 0;
1432 if { (eval echo configure:1433: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1433 rm -rf conftest*
1434 ac_cv_lib_cposix_strerror=yes
1435 else
1436 echo "configure: failed program was:" >&5
1437 cat conftest.$ac_ext >&5
1438 rm -rf conftest*
1439 ac_cv_lib_cposix_strerror=no
1441 rm -f conftest*
1443 LIBS="$ac_save_LIBS"
1445 echo "$ac_t""$ac_cv_lib_cposix_strerror" 1>&6
1446 if test $ac_cv_lib_cposix_strerror = yes; then
1447 LIBS="$LIBS -lcposix"
1450 echo $ac_n "checking for ${CC-cc} option to accept ANSI C... $ac_c" 1>&6
1451 echo "configure:1452: checking for ${CC-cc} option to accept ANSI C" 1>&5
1452 if test "${ac_cv_prog_cc_stdc+set}" = set; then
1453 echo $ac_n "(cached) $ac_c" 1>&6
1454 else
1455 ac_cv_prog_cc_stdc=no
1456 ac_save_CC="$CC"
1457 # Don't try gcc -ansi; that turns off useful extensions and
1458 # breaks some systems' header files.
1459 # AIX -qlanglvl=ansi
1460 # Ultrix and OSF/1 -std1
1461 # HP-UX 10.20 and later -Ae
1462 # HP-UX older versions -Aa -D_HPUX_SOURCE
1463 # SVR4 -Xc -D__EXTENSIONS__
1464 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1466 CC="$ac_save_CC $ac_arg"
1467 cat >conftest.$ac_ext <<EOF
1468 #line 1469 "configure"
1469 #include "confdefs.h"
1470 #include <stdarg.h>
1471 #include <stdio.h>
1472 #include <sys/types.h>
1473 #include <sys/stat.h>
1474 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
1475 struct buf { int x; };
1476 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1477 static char *e (p, i)
1478 char **p;
1479 int i;
1481 return p[i];
1483 static char *f (char * (*g) (char **, int), char **p, ...)
1485 char *s;
1486 va_list v;
1487 va_start (v,p);
1488 s = g (p, va_arg (v,int));
1489 va_end (v);
1490 return s;
1492 int test (int i, double x);
1493 struct s1 {int (*f) (int a);};
1494 struct s2 {int (*f) (double a);};
1495 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1496 int argc;
1497 char **argv;
1499 main ()
1501 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
1503 return 0;
1506 if { (eval echo configure:1507: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1507 rm -rf conftest*
1508 ac_cv_prog_cc_stdc="$ac_arg"; break
1509 else
1510 echo "configure: failed program was:" >&5
1511 cat conftest.$ac_ext >&5
1513 rm -f conftest*
1514 done
1515 CC="$ac_save_CC"
1519 case "x$ac_cv_prog_cc_stdc" in
1520 x|xno)
1521 echo "$ac_t""none needed" 1>&6 ;;
1523 echo "$ac_t""$ac_cv_prog_cc_stdc" 1>&6
1524 CC="$CC $ac_cv_prog_cc_stdc" ;;
1525 esac
1527 echo $ac_n "checking for ${CC-cc} option to accept ANSI C... $ac_c" 1>&6
1528 echo "configure:1529: checking for ${CC-cc} option to accept ANSI C" 1>&5
1529 if test "${am_cv_prog_cc_stdc+set}" = set; then
1530 echo $ac_n "(cached) $ac_c" 1>&6
1531 else
1532 am_cv_prog_cc_stdc=no
1533 ac_save_CC="$CC"
1534 # Don't try gcc -ansi; that turns off useful extensions and
1535 # breaks some systems' header files.
1536 # AIX -qlanglvl=ansi
1537 # Ultrix and OSF/1 -std1
1538 # HP-UX 10.20 and later -Ae
1539 # HP-UX older versions -Aa -D_HPUX_SOURCE
1540 # SVR4 -Xc -D__EXTENSIONS__
1541 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1543 CC="$ac_save_CC $ac_arg"
1544 cat >conftest.$ac_ext <<EOF
1545 #line 1546 "configure"
1546 #include "confdefs.h"
1547 #include <stdarg.h>
1548 #include <stdio.h>
1549 #include <sys/types.h>
1550 #include <sys/stat.h>
1551 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
1552 struct buf { int x; };
1553 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1554 static char *e (p, i)
1555 char **p;
1556 int i;
1558 return p[i];
1560 static char *f (char * (*g) (char **, int), char **p, ...)
1562 char *s;
1563 va_list v;
1564 va_start (v,p);
1565 s = g (p, va_arg (v,int));
1566 va_end (v);
1567 return s;
1569 int test (int i, double x);
1570 struct s1 {int (*f) (int a);};
1571 struct s2 {int (*f) (double a);};
1572 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1573 int argc;
1574 char **argv;
1577 main ()
1580 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
1583 return 0;
1586 if { (eval echo configure:1587: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1587 rm -rf conftest*
1588 am_cv_prog_cc_stdc="$ac_arg"; break
1589 else
1590 echo "configure: failed program was:" >&5
1591 cat conftest.$ac_ext >&5
1593 rm -f conftest*
1594 done
1595 CC="$ac_save_CC"
1599 if test -z "$am_cv_prog_cc_stdc"; then
1600 echo "$ac_t""none needed" 1>&6
1601 else
1602 echo "$ac_t""$am_cv_prog_cc_stdc" 1>&6
1604 case "x$am_cv_prog_cc_stdc" in
1605 x|xno) ;;
1606 *) CC="$CC $am_cv_prog_cc_stdc" ;;
1607 esac
1609 echo $ac_n "checking for function prototypes... $ac_c" 1>&6
1610 echo "configure:1611: checking for function prototypes" 1>&5
1611 if test "$am_cv_prog_cc_stdc" != no; then
1612 echo "$ac_t""yes" 1>&6
1613 cat >>confdefs.h <<\EOF
1614 #define PROTOTYPES 1
1617 U= ANSI2KNR=
1618 else
1619 echo "$ac_t""no" 1>&6
1620 U=_ ANSI2KNR=./ansi2knr
1621 # Ensure some checks needed by ansi2knr itself.
1622 echo $ac_n "checking for ANSI C header files... $ac_c" 1>&6
1623 echo "configure:1624: checking for ANSI C header files" 1>&5
1624 if test "${ac_cv_header_stdc+set}" = set; then
1625 echo $ac_n "(cached) $ac_c" 1>&6
1626 else
1627 cat >conftest.$ac_ext <<EOF
1628 #line 1629 "configure"
1629 #include "confdefs.h"
1630 #include <stdlib.h>
1631 #include <stdarg.h>
1632 #include <string.h>
1633 #include <float.h>
1636 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1637 { (eval echo configure:1638: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1638 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1639 if test -z "$ac_err"; then
1640 rm -rf conftest*
1641 ac_cv_header_stdc=yes
1642 else
1643 echo "$ac_err" >&5
1644 echo "configure: failed program was:" >&5
1645 cat conftest.$ac_ext >&5
1646 rm -rf conftest*
1647 ac_cv_header_stdc=no
1649 rm -f conftest*
1651 if test $ac_cv_header_stdc = yes; then
1652 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1653 cat >conftest.$ac_ext <<EOF
1654 #line 1655 "configure"
1655 #include "confdefs.h"
1656 #include <string.h>
1659 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1660 egrep "memchr" >/dev/null 2>&1; then
1662 else
1663 rm -rf conftest*
1664 ac_cv_header_stdc=no
1666 rm -f conftest*
1670 if test $ac_cv_header_stdc = yes; then
1671 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1672 cat >conftest.$ac_ext <<EOF
1673 #line 1674 "configure"
1674 #include "confdefs.h"
1675 #include <stdlib.h>
1678 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1679 egrep "free" >/dev/null 2>&1; then
1681 else
1682 rm -rf conftest*
1683 ac_cv_header_stdc=no
1685 rm -f conftest*
1689 if test $ac_cv_header_stdc = yes; then
1690 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1691 if test "$cross_compiling" = yes; then
1693 else
1694 cat >conftest.$ac_ext <<EOF
1695 #line 1696 "configure"
1696 #include "confdefs.h"
1697 #include <ctype.h>
1698 #if ((' ' & 0x0FF) == 0x020)
1699 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1700 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1701 #else
1702 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
1703 || ('j' <= (c) && (c) <= 'r') \
1704 || ('s' <= (c) && (c) <= 'z'))
1705 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
1706 #endif
1708 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1710 main ()
1712 int i;
1713 for (i = 0; i < 256; i++)
1714 if (XOR (islower (i), ISLOWER (i))
1715 || toupper (i) != TOUPPER (i))
1716 exit(2);
1717 exit (0);
1720 if { (eval echo configure:1721: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1721 then
1723 else
1724 echo "configure: failed program was:" >&5
1725 cat conftest.$ac_ext >&5
1726 rm -fr conftest*
1727 ac_cv_header_stdc=no
1729 rm -fr conftest*
1735 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1736 if test $ac_cv_header_stdc = yes; then
1737 cat >>confdefs.h <<\EOF
1738 #define STDC_HEADERS 1
1743 for ac_header in string.h
1745 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
1746 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
1747 echo "configure:1748: checking for $ac_header" 1>&5
1748 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
1749 echo $ac_n "(cached) $ac_c" 1>&6
1750 else
1751 cat >conftest.$ac_ext <<EOF
1752 #line 1753 "configure"
1753 #include "confdefs.h"
1754 #include <$ac_header>
1757 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1758 { (eval echo configure:1759: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1759 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1760 if test -z "$ac_err"; then
1761 rm -rf conftest*
1762 eval "$ac_ac_Header=yes"
1763 else
1764 echo "$ac_err" >&5
1765 echo "configure: failed program was:" >&5
1766 cat conftest.$ac_ext >&5
1767 rm -rf conftest*
1768 eval "$ac_ac_Header=no"
1770 rm -f conftest*
1772 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
1773 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
1774 cat >>confdefs.h <<EOF
1775 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
1779 done
1783 # Find a good install program. We prefer a C program (faster),
1784 # so one script is as good as another. But avoid the broken or
1785 # incompatible versions:
1786 # SysV /etc/install, /usr/sbin/install
1787 # SunOS /usr/etc/install
1788 # IRIX /sbin/install
1789 # AIX /bin/install
1790 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1791 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1792 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1793 # ./install, which can be erroneously created by make from ./install.sh.
1794 echo $ac_n "checking for a BSD compatible install... $ac_c" 1>&6
1795 echo "configure:1796: checking for a BSD compatible install" 1>&5
1796 if test -z "$INSTALL"; then
1797 if test "${ac_cv_path_install+set}" = set; then
1798 echo $ac_n "(cached) $ac_c" 1>&6
1799 else
1800 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
1801 for ac_dir in $PATH; do
1802 # Account for people who put trailing slashes in PATH elements.
1803 case "$ac_dir/" in
1804 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1806 # OSF1 and SCO ODT 3.0 have their own names for install.
1807 # Don't use installbsd from OSF since it installs stuff as root
1808 # by default.
1809 for ac_prog in ginstall scoinst install; do
1810 if test -f $ac_dir/$ac_prog; then
1811 if test $ac_prog = install &&
1812 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1813 # AIX install. It has an incompatible calling convention.
1815 elif test $ac_prog = install &&
1816 grep pwplus $ac_dir/$ac_prog >/dev/null 2>&1; then
1817 # program-specific install script used by HP pwplus--don't use.
1819 else
1820 ac_cv_path_install="$ac_dir/$ac_prog -c"
1821 break 2
1824 done
1826 esac
1827 done
1828 IFS="$ac_save_IFS"
1831 if test "${ac_cv_path_install+set}" = set; then
1832 INSTALL="$ac_cv_path_install"
1833 else
1834 # As a last resort, use the slow shell script. We don't cache a
1835 # path for INSTALL within a source directory, because that will
1836 # break other packages using the cache if that directory is
1837 # removed, or if the path is relative.
1838 INSTALL="$ac_install_sh"
1841 echo "$ac_t""$INSTALL" 1>&6
1843 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1844 # It thinks the first close brace ends the variable substitution.
1845 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1847 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
1849 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1851 # Extract the first word of "ranlib", so it can be a program name with args.
1852 set dummy ranlib; ac_word=$2
1853 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
1854 echo "configure:1855: checking for $ac_word" 1>&5
1855 if test "${ac_cv_prog_RANLIB+set}" = set; then
1856 echo $ac_n "(cached) $ac_c" 1>&6
1857 else
1858 if test -n "$RANLIB"; then
1859 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1860 else
1861 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1862 ac_dummy="$PATH"
1863 for ac_dir in $ac_dummy; do
1864 test -z "$ac_dir" && ac_dir=.
1865 if test -f $ac_dir/$ac_word; then
1866 ac_cv_prog_RANLIB="ranlib"
1867 break
1869 done
1870 IFS="$ac_save_ifs"
1871 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1874 RANLIB="$ac_cv_prog_RANLIB"
1875 if test -n "$RANLIB"; then
1876 echo "$ac_t""$RANLIB" 1>&6
1877 else
1878 echo "$ac_t""no" 1>&6
1881 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}... $ac_c" 1>&6
1882 echo "configure:1883: checking whether ${MAKE-make} sets \${MAKE}" 1>&5
1883 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1884 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1885 echo $ac_n "(cached) $ac_c" 1>&6
1886 else
1887 cat >conftestmake <<\EOF
1888 all:
1889 @echo 'ac_maketemp="${MAKE}"'
1891 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1892 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1893 if test -n "$ac_maketemp"; then
1894 eval ac_cv_prog_make_${ac_make}_set=yes
1895 else
1896 eval ac_cv_prog_make_${ac_make}_set=no
1898 rm -f conftestmake
1900 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1901 echo "$ac_t""yes" 1>&6
1902 SET_MAKE=
1903 else
1904 echo "$ac_t""no" 1>&6
1905 SET_MAKE="MAKE=${MAKE-make}"
1908 echo $ac_n "checking for inttypes.h... $ac_c" 1>&6
1909 echo "configure:1910: checking for inttypes.h" 1>&5
1910 if test "${jm_ac_cv_header_inttypes_h+set}" = set; then
1911 echo $ac_n "(cached) $ac_c" 1>&6
1912 else
1913 cat >conftest.$ac_ext <<EOF
1914 #line 1915 "configure"
1915 #include "confdefs.h"
1916 #include <sys/types.h>
1917 #include <inttypes.h>
1919 main ()
1921 uintmax_t i = (uintmax_t) -1;
1923 return 0;
1926 if { (eval echo configure:1927: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1927 rm -rf conftest*
1928 jm_ac_cv_header_inttypes_h=yes
1929 else
1930 echo "configure: failed program was:" >&5
1931 cat conftest.$ac_ext >&5
1932 rm -rf conftest*
1933 jm_ac_cv_header_inttypes_h=no
1935 rm -f conftest*
1937 echo "$ac_t""$jm_ac_cv_header_inttypes_h" 1>&6
1938 if test $jm_ac_cv_header_inttypes_h = yes; then
1939 cat >>confdefs.h <<EOF
1940 #define HAVE_INTTYPES_H 1
1945 echo $ac_n "checking for unsigned long long... $ac_c" 1>&6
1946 echo "configure:1947: checking for unsigned long long" 1>&5
1947 if test "${ac_cv_type_unsigned_long_long+set}" = set; then
1948 echo $ac_n "(cached) $ac_c" 1>&6
1949 else
1950 cat >conftest.$ac_ext <<EOF
1951 #line 1952 "configure"
1952 #include "confdefs.h"
1953 unsigned long long ull = 1; int i = 63;
1955 main()
1957 unsigned long long ullmax = (unsigned long long) -1;
1958 return ull << i | ull >> i | ullmax / ull | ullmax % ull;
1960 return 0;
1963 if { (eval echo configure:1964: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1964 rm -rf conftest*
1965 ac_cv_type_unsigned_long_long=yes
1966 else
1967 echo "configure: failed program was:" >&5
1968 cat conftest.$ac_ext >&5
1969 rm -rf conftest*
1970 ac_cv_type_unsigned_long_long=no
1972 rm -f conftest*
1975 echo "$ac_t""$ac_cv_type_unsigned_long_long" 1>&6
1976 if test $ac_cv_type_unsigned_long_long = yes; then
1977 cat >>confdefs.h <<\EOF
1978 #define HAVE_UNSIGNED_LONG_LONG 1
1983 echo $ac_n "checking for uid_t in sys/types.h... $ac_c" 1>&6
1984 echo "configure:1985: checking for uid_t in sys/types.h" 1>&5
1985 if test "${ac_cv_type_uid_t+set}" = set; then
1986 echo $ac_n "(cached) $ac_c" 1>&6
1987 else
1988 cat >conftest.$ac_ext <<EOF
1989 #line 1990 "configure"
1990 #include "confdefs.h"
1991 #include <sys/types.h>
1994 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1995 egrep "uid_t" >/dev/null 2>&1; then
1996 rm -rf conftest*
1997 ac_cv_type_uid_t=yes
1998 else
1999 rm -rf conftest*
2000 ac_cv_type_uid_t=no
2002 rm -f conftest*
2005 echo "$ac_t""$ac_cv_type_uid_t" 1>&6
2006 if test $ac_cv_type_uid_t = no; then
2007 cat >>confdefs.h <<\EOF
2008 #define uid_t int
2011 cat >>confdefs.h <<\EOF
2012 #define gid_t int
2017 if test $jm_ac_cv_header_inttypes_h = no; then
2019 test $ac_cv_type_unsigned_long_long = yes \
2020 && ac_type='unsigned long long' \
2021 || ac_type='unsigned long'
2022 cat >>confdefs.h <<EOF
2023 #define uintmax_t $ac_type
2028 echo $ac_n "checking whether byte ordering is bigendian... $ac_c" 1>&6
2029 echo "configure:2030: checking whether byte ordering is bigendian" 1>&5
2030 if test "${ac_cv_c_bigendian+set}" = set; then
2031 echo $ac_n "(cached) $ac_c" 1>&6
2032 else
2033 ac_cv_c_bigendian=unknown
2034 # See if sys/param.h defines the BYTE_ORDER macro.
2035 cat >conftest.$ac_ext <<EOF
2036 #line 2037 "configure"
2037 #include "confdefs.h"
2038 #include <sys/types.h>
2039 #include <sys/param.h>
2042 main ()
2044 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
2045 bogus endian macros
2046 #endif
2049 return 0;
2052 if { (eval echo configure:2053: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2053 rm -rf conftest*
2054 # It does; now see whether it defined to BIG_ENDIAN or not.
2055 cat >conftest.$ac_ext <<EOF
2056 #line 2057 "configure"
2057 #include "confdefs.h"
2058 #include <sys/types.h>
2059 #include <sys/param.h>
2062 main ()
2064 #if BYTE_ORDER != BIG_ENDIAN
2065 not big endian
2066 #endif
2069 return 0;
2072 if { (eval echo configure:2073: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2073 rm -rf conftest*
2074 ac_cv_c_bigendian=yes
2075 else
2076 echo "configure: failed program was:" >&5
2077 cat conftest.$ac_ext >&5
2078 rm -rf conftest*
2079 ac_cv_c_bigendian=no
2081 rm -f conftest*
2082 else
2083 echo "configure: failed program was:" >&5
2084 cat conftest.$ac_ext >&5
2086 rm -f conftest*
2087 if test $ac_cv_c_bigendian = unknown; then
2088 if test "$cross_compiling" = yes; then
2089 { echo "configure: error: cannot run test program while cross compiling" 1>&2; exit 1; }
2090 else
2091 cat >conftest.$ac_ext <<EOF
2092 #line 2093 "configure"
2093 #include "confdefs.h"
2095 main ()
2097 /* Are we little or big endian? From Harbison&Steele. */
2098 union
2100 long l;
2101 char c[sizeof (long)];
2102 } u;
2103 u.l = 1;
2104 exit (u.c[sizeof (long) - 1] == 1);
2107 if { (eval echo configure:2108: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2108 then
2109 ac_cv_c_bigendian=no
2110 else
2111 echo "configure: failed program was:" >&5
2112 cat conftest.$ac_ext >&5
2113 rm -fr conftest*
2114 ac_cv_c_bigendian=yes
2116 rm -fr conftest*
2122 echo "$ac_t""$ac_cv_c_bigendian" 1>&6
2123 if test $ac_cv_c_bigendian = yes; then
2124 cat >>confdefs.h <<\EOF
2125 #define WORDS_BIGENDIAN 1
2130 echo $ac_n "checking for working const... $ac_c" 1>&6
2131 echo "configure:2132: checking for working const" 1>&5
2132 if test "${ac_cv_c_const+set}" = set; then
2133 echo $ac_n "(cached) $ac_c" 1>&6
2134 else
2135 cat >conftest.$ac_ext <<EOF
2136 #line 2137 "configure"
2137 #include "confdefs.h"
2140 main ()
2143 /* Ultrix mips cc rejects this. */
2144 typedef int charset[2]; const charset x = {0, 0};
2145 /* SunOS 4.1.1 cc rejects this. */
2146 char const *const *ccp;
2147 char **p;
2148 /* NEC SVR4.0.2 mips cc rejects this. */
2149 struct point {int x, y;};
2150 static struct point const zero = {0,0};
2151 /* AIX XL C 1.02.0.0 rejects this.
2152 It does not let you subtract one const X* pointer from another in an arm
2153 of an if-expression whose if-part is not a constant expression */
2154 const char *g = "string";
2155 ccp = &g + (g ? g-g : 0);
2156 /* HPUX 7.0 cc rejects these. */
2157 ++ccp;
2158 p = (char**) ccp;
2159 ccp = (char const *const *) p;
2160 { /* SCO 3.2v4 cc rejects this. */
2161 char *t;
2162 char const *s = 0 ? (char *) 0 : (char const *) 0;
2164 *t++ = 0;
2166 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
2167 int x[] = {25, 17};
2168 const int *foo = &x[0];
2169 ++foo;
2171 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2172 typedef const int *iptr;
2173 iptr p = 0;
2174 ++p;
2176 { /* AIX XL C 1.02.0.0 rejects this saying
2177 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2178 struct s { int j; const int *ap[3]; };
2179 struct s *b; b->j = 5;
2181 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2182 const int foo = 10;
2186 return 0;
2189 if { (eval echo configure:2190: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2190 rm -rf conftest*
2191 ac_cv_c_const=yes
2192 else
2193 echo "configure: failed program was:" >&5
2194 cat conftest.$ac_ext >&5
2195 rm -rf conftest*
2196 ac_cv_c_const=no
2198 rm -f conftest*
2200 echo "$ac_t""$ac_cv_c_const" 1>&6
2201 if test $ac_cv_c_const = no; then
2202 cat >>confdefs.h <<EOF
2203 #define const /* empty */
2208 echo $ac_n "checking for inline... $ac_c" 1>&6
2209 echo "configure:2210: checking for inline" 1>&5
2210 if test "${ac_cv_c_inline+set}" = set; then
2211 echo $ac_n "(cached) $ac_c" 1>&6
2212 else
2213 ac_cv_c_inline=no
2214 for ac_kw in inline __inline__ __inline; do
2215 cat >conftest.$ac_ext <<EOF
2216 #line 2217 "configure"
2217 #include "confdefs.h"
2220 main ()
2222 #ifndef __cplusplus
2223 } $ac_kw int foo() {
2224 #endif
2227 return 0;
2230 if { (eval echo configure:2231: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2231 rm -rf conftest*
2232 ac_cv_c_inline=$ac_kw; break
2233 else
2234 echo "configure: failed program was:" >&5
2235 cat conftest.$ac_ext >&5
2237 rm -f conftest*
2238 done
2241 echo "$ac_t""$ac_cv_c_inline" 1>&6
2242 case "$ac_cv_c_inline" in
2243 inline | yes) ;;
2244 no) cat >>confdefs.h <<\EOF
2245 #define inline
2248 *) cat >>confdefs.h <<EOF
2249 #define inline $ac_cv_c_inline
2252 esac
2254 echo $ac_n "checking for long double... $ac_c" 1>&6
2255 echo "configure:2256: checking for long double" 1>&5
2256 if test "${ac_cv_c_long_double+set}" = set; then
2257 echo $ac_n "(cached) $ac_c" 1>&6
2258 else
2259 if test "$GCC" = yes; then
2260 ac_cv_c_long_double=yes
2261 else
2262 if test "$cross_compiling" = yes; then
2263 { echo "configure: error: cannot run test program while cross compiling" 1>&2; exit 1; }
2264 else
2265 cat >conftest.$ac_ext <<EOF
2266 #line 2267 "configure"
2267 #include "confdefs.h"
2269 main()
2271 /* The Stardent Vistra knows sizeof(long double), but does not
2272 support it. */
2273 long double foo = 0.0;
2274 /* On Ultrix 4.3 cc, long double is 4 and double is 8. */
2275 exit(sizeof(long double) < sizeof(double));
2278 if { (eval echo configure:2279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2279 then
2280 ac_cv_c_long_double=yes
2281 else
2282 echo "configure: failed program was:" >&5
2283 cat conftest.$ac_ext >&5
2284 rm -fr conftest*
2285 ac_cv_c_long_double=no
2287 rm -fr conftest*
2293 echo "$ac_t""$ac_cv_c_long_double" 1>&6
2294 if test $ac_cv_c_long_double = yes; then
2295 cat >>confdefs.h <<\EOF
2296 #define HAVE_LONG_DOUBLE 1
2301 ac_header_dirent=no
2302 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
2304 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2305 echo $ac_n "checking for $ac_hdr that defines DIR... $ac_c" 1>&6
2306 echo "configure:2307: checking for $ac_hdr that defines DIR" 1>&5
2307 if eval "test \"\${ac_cv_header_dirent_$ac_safe+set}\" = set"; then
2308 echo $ac_n "(cached) $ac_c" 1>&6
2309 else
2310 cat >conftest.$ac_ext <<EOF
2311 #line 2312 "configure"
2312 #include "confdefs.h"
2313 #include <sys/types.h>
2314 #include <$ac_hdr>
2317 main ()
2319 DIR *dirp = 0;
2321 return 0;
2324 if { (eval echo configure:2325: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2325 rm -rf conftest*
2326 eval "ac_cv_header_dirent_$ac_safe=yes"
2327 else
2328 echo "configure: failed program was:" >&5
2329 cat conftest.$ac_ext >&5
2330 rm -rf conftest*
2331 eval "ac_cv_header_dirent_$ac_safe=no"
2333 rm -f conftest*
2335 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
2336 echo "$ac_t""yes" 1>&6
2337 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2338 cat >>confdefs.h <<EOF
2339 #define $ac_tr_hdr 1
2341 ac_header_dirent=$ac_hdr; break
2342 else
2343 echo "$ac_t""no" 1>&6
2345 done
2346 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
2347 if test $ac_header_dirent = dirent.h; then
2348 echo $ac_n "checking for opendir in -ldir... $ac_c" 1>&6
2349 echo "configure:2350: checking for opendir in -ldir" 1>&5
2350 if test "${ac_cv_lib_dir_opendir+set}" = set; then
2351 echo $ac_n "(cached) $ac_c" 1>&6
2352 else
2353 ac_save_LIBS="$LIBS"
2354 LIBS="-ldir $LIBS"
2355 cat >conftest.$ac_ext <<EOF
2356 #line 2357 "configure"
2357 #include "confdefs.h"
2358 /* Override any gcc2 internal prototype to avoid an error. */
2359 /* We use char because int might match the return type of a gcc2
2360 builtin and then its argument prototype would still apply. */
2361 char opendir();
2364 main()
2366 opendir()
2368 return 0;
2371 if { (eval echo configure:2372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2372 rm -rf conftest*
2373 ac_cv_lib_dir_opendir=yes
2374 else
2375 echo "configure: failed program was:" >&5
2376 cat conftest.$ac_ext >&5
2377 rm -rf conftest*
2378 ac_cv_lib_dir_opendir=no
2380 rm -f conftest*
2382 LIBS="$ac_save_LIBS"
2384 echo "$ac_t""$ac_cv_lib_dir_opendir" 1>&6
2385 if test $ac_cv_lib_dir_opendir = yes; then
2386 LIBS="$LIBS -ldir"
2389 else
2390 echo $ac_n "checking for opendir in -lx... $ac_c" 1>&6
2391 echo "configure:2392: checking for opendir in -lx" 1>&5
2392 if test "${ac_cv_lib_x_opendir+set}" = set; then
2393 echo $ac_n "(cached) $ac_c" 1>&6
2394 else
2395 ac_save_LIBS="$LIBS"
2396 LIBS="-lx $LIBS"
2397 cat >conftest.$ac_ext <<EOF
2398 #line 2399 "configure"
2399 #include "confdefs.h"
2400 /* Override any gcc2 internal prototype to avoid an error. */
2401 /* We use char because int might match the return type of a gcc2
2402 builtin and then its argument prototype would still apply. */
2403 char opendir();
2406 main()
2408 opendir()
2410 return 0;
2413 if { (eval echo configure:2414: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2414 rm -rf conftest*
2415 ac_cv_lib_x_opendir=yes
2416 else
2417 echo "configure: failed program was:" >&5
2418 cat conftest.$ac_ext >&5
2419 rm -rf conftest*
2420 ac_cv_lib_x_opendir=no
2422 rm -f conftest*
2424 LIBS="$ac_save_LIBS"
2426 echo "$ac_t""$ac_cv_lib_x_opendir" 1>&6
2427 if test $ac_cv_lib_x_opendir = yes; then
2428 LIBS="$LIBS -lx"
2433 echo $ac_n "checking for ANSI C header files... $ac_c" 1>&6
2434 echo "configure:2435: checking for ANSI C header files" 1>&5
2435 if test "${ac_cv_header_stdc+set}" = set; then
2436 echo $ac_n "(cached) $ac_c" 1>&6
2437 else
2438 cat >conftest.$ac_ext <<EOF
2439 #line 2440 "configure"
2440 #include "confdefs.h"
2441 #include <stdlib.h>
2442 #include <stdarg.h>
2443 #include <string.h>
2444 #include <float.h>
2447 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2448 { (eval echo configure:2449: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2449 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2450 if test -z "$ac_err"; then
2451 rm -rf conftest*
2452 ac_cv_header_stdc=yes
2453 else
2454 echo "$ac_err" >&5
2455 echo "configure: failed program was:" >&5
2456 cat conftest.$ac_ext >&5
2457 rm -rf conftest*
2458 ac_cv_header_stdc=no
2460 rm -f conftest*
2462 if test $ac_cv_header_stdc = yes; then
2463 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2464 cat >conftest.$ac_ext <<EOF
2465 #line 2466 "configure"
2466 #include "confdefs.h"
2467 #include <string.h>
2470 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2471 egrep "memchr" >/dev/null 2>&1; then
2473 else
2474 rm -rf conftest*
2475 ac_cv_header_stdc=no
2477 rm -f conftest*
2481 if test $ac_cv_header_stdc = yes; then
2482 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2483 cat >conftest.$ac_ext <<EOF
2484 #line 2485 "configure"
2485 #include "confdefs.h"
2486 #include <stdlib.h>
2489 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2490 egrep "free" >/dev/null 2>&1; then
2492 else
2493 rm -rf conftest*
2494 ac_cv_header_stdc=no
2496 rm -f conftest*
2500 if test $ac_cv_header_stdc = yes; then
2501 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2502 if test "$cross_compiling" = yes; then
2504 else
2505 cat >conftest.$ac_ext <<EOF
2506 #line 2507 "configure"
2507 #include "confdefs.h"
2508 #include <ctype.h>
2509 #if ((' ' & 0x0FF) == 0x020)
2510 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2511 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2512 #else
2513 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
2514 || ('j' <= (c) && (c) <= 'r') \
2515 || ('s' <= (c) && (c) <= 'z'))
2516 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
2517 #endif
2519 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2521 main ()
2523 int i;
2524 for (i = 0; i < 256; i++)
2525 if (XOR (islower (i), ISLOWER (i))
2526 || toupper (i) != TOUPPER (i))
2527 exit(2);
2528 exit (0);
2531 if { (eval echo configure:2532: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2532 then
2534 else
2535 echo "configure: failed program was:" >&5
2536 cat conftest.$ac_ext >&5
2537 rm -fr conftest*
2538 ac_cv_header_stdc=no
2540 rm -fr conftest*
2546 echo "$ac_t""$ac_cv_header_stdc" 1>&6
2547 if test $ac_cv_header_stdc = yes; then
2548 cat >>confdefs.h <<\EOF
2549 #define STDC_HEADERS 1
2554 echo $ac_n "checking for struct stat.st_blksize... $ac_c" 1>&6
2555 echo "configure:2556: checking for struct stat.st_blksize" 1>&5
2556 if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
2557 echo $ac_n "(cached) $ac_c" 1>&6
2558 else
2559 cat >conftest.$ac_ext <<EOF
2560 #line 2561 "configure"
2561 #include "confdefs.h"
2562 $ac_includes_default
2564 main ()
2566 struct stat foo;
2567 foo.st_blksize;
2569 return 0;
2572 if { (eval echo configure:2573: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2573 rm -rf conftest*
2574 ac_cv_member_struct_stat_st_blksize=yes
2575 else
2576 echo "configure: failed program was:" >&5
2577 cat conftest.$ac_ext >&5
2578 rm -rf conftest*
2579 ac_cv_member_struct_stat_st_blksize=no
2581 rm -f conftest*
2583 echo "$ac_t""$ac_cv_member_struct_stat_st_blksize" 1>&6
2584 if test $ac_cv_member_struct_stat_st_blksize = yes; then
2585 cat >>confdefs.h <<EOF
2586 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
2591 echo $ac_n "checking for struct stat.st_blocks... $ac_c" 1>&6
2592 echo "configure:2593: checking for struct stat.st_blocks" 1>&5
2593 if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
2594 echo $ac_n "(cached) $ac_c" 1>&6
2595 else
2596 cat >conftest.$ac_ext <<EOF
2597 #line 2598 "configure"
2598 #include "confdefs.h"
2599 #include <sys/types.h>
2600 #include <sys/stat.h>
2603 main ()
2605 struct stat foo;
2606 foo.st_blocks;
2608 return 0;
2611 if { (eval echo configure:2612: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2612 rm -rf conftest*
2613 ac_cv_member_struct_stat_st_blocks=yes
2614 else
2615 echo "configure: failed program was:" >&5
2616 cat conftest.$ac_ext >&5
2617 rm -rf conftest*
2618 ac_cv_member_struct_stat_st_blocks=no
2620 rm -f conftest*
2622 echo "$ac_t""$ac_cv_member_struct_stat_st_blocks" 1>&6
2623 if test $ac_cv_member_struct_stat_st_blocks = yes; then
2624 cat >>confdefs.h <<EOF
2625 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
2628 cat >>confdefs.h <<\EOF
2629 #define HAVE_ST_BLOCKS 1
2632 else
2633 LIBOBJS="$LIBOBJS fileblocks.${ac_objext}"
2637 echo $ac_n "checking whether struct tm is in sys/time.h or time.h... $ac_c" 1>&6
2638 echo "configure:2639: checking whether struct tm is in sys/time.h or time.h" 1>&5
2639 if test "${ac_cv_struct_tm+set}" = set; then
2640 echo $ac_n "(cached) $ac_c" 1>&6
2641 else
2642 cat >conftest.$ac_ext <<EOF
2643 #line 2644 "configure"
2644 #include "confdefs.h"
2645 #include <sys/types.h>
2646 #include <time.h>
2649 main ()
2651 struct tm *tp; tp->tm_sec;
2653 return 0;
2656 if { (eval echo configure:2657: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2657 rm -rf conftest*
2658 ac_cv_struct_tm=time.h
2659 else
2660 echo "configure: failed program was:" >&5
2661 cat conftest.$ac_ext >&5
2662 rm -rf conftest*
2663 ac_cv_struct_tm=sys/time.h
2665 rm -f conftest*
2667 echo "$ac_t""$ac_cv_struct_tm" 1>&6
2668 if test $ac_cv_struct_tm = sys/time.h; then
2669 cat >>confdefs.h <<\EOF
2670 #define TM_IN_SYS_TIME 1
2675 echo $ac_n "checking whether time.h and sys/time.h may both be included... $ac_c" 1>&6
2676 echo "configure:2677: checking whether time.h and sys/time.h may both be included" 1>&5
2677 if test "${ac_cv_header_time+set}" = set; then
2678 echo $ac_n "(cached) $ac_c" 1>&6
2679 else
2680 cat >conftest.$ac_ext <<EOF
2681 #line 2682 "configure"
2682 #include "confdefs.h"
2683 #include <sys/types.h>
2684 #include <sys/time.h>
2685 #include <time.h>
2688 main ()
2690 struct tm *tp;
2692 return 0;
2695 if { (eval echo configure:2696: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2696 rm -rf conftest*
2697 ac_cv_header_time=yes
2698 else
2699 echo "configure: failed program was:" >&5
2700 cat conftest.$ac_ext >&5
2701 rm -rf conftest*
2702 ac_cv_header_time=no
2704 rm -f conftest*
2706 echo "$ac_t""$ac_cv_header_time" 1>&6
2707 if test $ac_cv_header_time = yes; then
2708 cat >>confdefs.h <<\EOF
2709 #define TIME_WITH_SYS_TIME 1
2714 echo $ac_n "checking for struct tm.tm_zone... $ac_c" 1>&6
2715 echo "configure:2716: checking for struct tm.tm_zone" 1>&5
2716 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
2717 echo $ac_n "(cached) $ac_c" 1>&6
2718 else
2719 cat >conftest.$ac_ext <<EOF
2720 #line 2721 "configure"
2721 #include "confdefs.h"
2722 #include <sys/types.h>
2723 #include <$ac_cv_struct_tm>
2726 main ()
2728 struct tm foo;
2729 foo.tm_zone;
2731 return 0;
2734 if { (eval echo configure:2735: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2735 rm -rf conftest*
2736 ac_cv_member_struct_tm_tm_zone=yes
2737 else
2738 echo "configure: failed program was:" >&5
2739 cat conftest.$ac_ext >&5
2740 rm -rf conftest*
2741 ac_cv_member_struct_tm_tm_zone=no
2743 rm -f conftest*
2745 echo "$ac_t""$ac_cv_member_struct_tm_tm_zone" 1>&6
2746 if test $ac_cv_member_struct_tm_tm_zone = yes; then
2747 cat >>confdefs.h <<EOF
2748 #define HAVE_STRUCT_TM_TM_ZONE 1
2753 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
2754 cat >>confdefs.h <<\EOF
2755 #define HAVE_TM_ZONE 1
2758 else
2759 echo $ac_n "checking for tzname... $ac_c" 1>&6
2760 echo "configure:2761: checking for tzname" 1>&5
2761 if test "${ac_cv_var_tzname+set}" = set; then
2762 echo $ac_n "(cached) $ac_c" 1>&6
2763 else
2764 cat >conftest.$ac_ext <<EOF
2765 #line 2766 "configure"
2766 #include "confdefs.h"
2767 #include <time.h>
2768 #ifndef tzname /* For SGI. */
2769 extern char *tzname[]; /* RS6000 and others reject char **tzname. */
2770 #endif
2773 main()
2775 atoi(*tzname);
2777 return 0;
2780 if { (eval echo configure:2781: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2781 rm -rf conftest*
2782 ac_cv_var_tzname=yes
2783 else
2784 echo "configure: failed program was:" >&5
2785 cat conftest.$ac_ext >&5
2786 rm -rf conftest*
2787 ac_cv_var_tzname=no
2789 rm -f conftest*
2792 echo "$ac_t""$ac_cv_var_tzname" 1>&6
2793 if test $ac_cv_var_tzname = yes; then
2794 cat >>confdefs.h <<\EOF
2795 #define HAVE_TZNAME 1
2801 echo $ac_n "checking whether stat file-mode macros are broken... $ac_c" 1>&6
2802 echo "configure:2803: checking whether stat file-mode macros are broken" 1>&5
2803 if test "${ac_cv_header_stat_broken+set}" = set; then
2804 echo $ac_n "(cached) $ac_c" 1>&6
2805 else
2806 cat >conftest.$ac_ext <<EOF
2807 #line 2808 "configure"
2808 #include "confdefs.h"
2809 #include <sys/types.h>
2810 #include <sys/stat.h>
2812 #if defined(S_ISBLK) && defined(S_IFDIR)
2813 # if S_ISBLK (S_IFDIR)
2814 You lose.
2815 # endif
2816 #endif
2818 #if defined(S_ISBLK) && defined(S_IFCHR)
2819 # if S_ISBLK (S_IFCHR)
2820 You lose.
2821 # endif
2822 #endif
2824 #if defined(S_ISLNK) && defined(S_IFREG)
2825 # if S_ISLNK (S_IFREG)
2826 You lose.
2827 # endif
2828 #endif
2830 #if defined(S_ISSOCK) && defined(S_IFREG)
2831 # if S_ISSOCK (S_IFREG)
2832 You lose.
2833 # endif
2834 #endif
2837 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2838 egrep "You lose" >/dev/null 2>&1; then
2839 rm -rf conftest*
2840 ac_cv_header_stat_broken=yes
2841 else
2842 rm -rf conftest*
2843 ac_cv_header_stat_broken=no
2845 rm -f conftest*
2848 echo "$ac_t""$ac_cv_header_stat_broken" 1>&6
2849 if test $ac_cv_header_stat_broken = yes; then
2850 cat >>confdefs.h <<\EOF
2851 #define STAT_MACROS_BROKEN 1
2856 echo $ac_n "checking for nanoseconds member of struct stat.st_mtim... $ac_c" 1>&6
2857 echo "configure:2858: checking for nanoseconds member of struct stat.st_mtim" 1>&5
2858 if test "${ac_cv_struct_st_mtim_nsec+set}" = set; then
2859 echo $ac_n "(cached) $ac_c" 1>&6
2860 else
2861 ac_save_CPPFLAGS="$CPPFLAGS"
2862 ac_cv_struct_st_mtim_nsec=no
2863 # tv_nsec -- the usual case
2864 # _tv_nsec -- Solaris 2.6, if
2865 # (defined _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED == 1
2866 # && !defined __EXTENSIONS__)
2867 # st__tim.tv_nsec -- UnixWare 2.1.2
2868 for ac_val in tv_nsec _tv_nsec st__tim.tv_nsec; do
2869 CPPFLAGS="$ac_save_CPPFLAGS -DST_MTIM_NSEC=$ac_val"
2870 cat >conftest.$ac_ext <<EOF
2871 #line 2872 "configure"
2872 #include "confdefs.h"
2873 #include <sys/types.h>
2874 #include <sys/stat.h>
2876 main ()
2878 struct stat s; s.st_mtim.ST_MTIM_NSEC;
2880 return 0;
2883 if { (eval echo configure:2884: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2884 rm -rf conftest*
2885 ac_cv_struct_st_mtim_nsec=$ac_val; break
2886 else
2887 echo "configure: failed program was:" >&5
2888 cat conftest.$ac_ext >&5
2890 rm -f conftest*
2891 done
2892 CPPFLAGS="$ac_save_CPPFLAGS"
2894 echo "$ac_t""$ac_cv_struct_st_mtim_nsec" 1>&6
2896 if test $ac_cv_struct_st_mtim_nsec != no; then
2897 cat >>confdefs.h <<EOF
2898 #define ST_MTIM_NSEC $ac_cv_struct_st_mtim_nsec
2903 echo $ac_n "checking for st_dm_mode in struct stat... $ac_c" 1>&6
2904 echo "configure:2905: checking for st_dm_mode in struct stat" 1>&5
2905 if test "${ac_cv_struct_st_dm_mode+set}" = set; then
2906 echo $ac_n "(cached) $ac_c" 1>&6
2907 else
2908 cat >conftest.$ac_ext <<EOF
2909 #line 2910 "configure"
2910 #include "confdefs.h"
2911 #include <sys/types.h>
2912 #include <sys/stat.h>
2914 main ()
2916 struct stat s; s.st_dm_mode;
2918 return 0;
2921 if { (eval echo configure:2922: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2922 rm -rf conftest*
2923 ac_cv_struct_st_dm_mode=yes
2924 else
2925 echo "configure: failed program was:" >&5
2926 cat conftest.$ac_ext >&5
2927 rm -rf conftest*
2928 ac_cv_struct_st_dm_mode=no
2930 rm -f conftest*
2932 echo "$ac_t""$ac_cv_struct_st_dm_mode" 1>&6
2934 if test $ac_cv_struct_st_dm_mode = yes; then
2935 cat >>confdefs.h <<EOF
2936 #define HAVE_ST_DM_MODE 1
2941 echo $ac_n "checking type of array argument to getgroups... $ac_c" 1>&6
2942 echo "configure:2943: checking type of array argument to getgroups" 1>&5
2943 if test "${ac_cv_type_getgroups+set}" = set; then
2944 echo $ac_n "(cached) $ac_c" 1>&6
2945 else
2946 if test "$cross_compiling" = yes; then
2947 ac_cv_type_getgroups=cross
2948 else
2949 cat >conftest.$ac_ext <<EOF
2950 #line 2951 "configure"
2951 #include "confdefs.h"
2952 /* Thanks to Mike Rendell for this test. */
2953 #include <sys/types.h>
2954 #define NGID 256
2955 #undef MAX
2956 #define MAX(x, y) ((x) > (y) ? (x) : (y))
2958 main ()
2960 gid_t gidset[NGID];
2961 int i, n;
2962 union { gid_t gval; long lval; } val;
2964 val.lval = -1;
2965 for (i = 0; i < NGID; i++)
2966 gidset[i] = val.gval;
2967 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
2968 gidset);
2969 /* Exit non-zero if getgroups seems to require an array of ints. This
2970 happens when gid_t is short but getgroups modifies an array of ints. */
2971 exit ((n > 0 && gidset[n] != val.gval) ? 1 : 0);
2974 if { (eval echo configure:2975: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2975 then
2976 ac_cv_type_getgroups=gid_t
2977 else
2978 echo "configure: failed program was:" >&5
2979 cat conftest.$ac_ext >&5
2980 rm -fr conftest*
2981 ac_cv_type_getgroups=int
2983 rm -fr conftest*
2987 if test $ac_cv_type_getgroups = cross; then
2988 cat >conftest.$ac_ext <<EOF
2989 #line 2990 "configure"
2990 #include "confdefs.h"
2991 #include <unistd.h>
2994 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2995 egrep "getgroups.*int.*gid_t" >/dev/null 2>&1; then
2996 rm -rf conftest*
2997 ac_cv_type_getgroups=gid_t
2998 else
2999 rm -rf conftest*
3000 ac_cv_type_getgroups=int
3002 rm -f conftest*
3006 echo "$ac_t""$ac_cv_type_getgroups" 1>&6
3007 cat >>confdefs.h <<EOF
3008 #define GETGROUPS_T $ac_cv_type_getgroups
3011 for ac_header in unistd.h
3013 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
3014 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
3015 echo "configure:3016: checking for $ac_header" 1>&5
3016 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
3017 echo $ac_n "(cached) $ac_c" 1>&6
3018 else
3019 cat >conftest.$ac_ext <<EOF
3020 #line 3021 "configure"
3021 #include "confdefs.h"
3022 #include <$ac_header>
3025 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3026 { (eval echo configure:3027: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3027 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3028 if test -z "$ac_err"; then
3029 rm -rf conftest*
3030 eval "$ac_ac_Header=yes"
3031 else
3032 echo "$ac_err" >&5
3033 echo "configure: failed program was:" >&5
3034 cat conftest.$ac_ext >&5
3035 rm -rf conftest*
3036 eval "$ac_ac_Header=no"
3038 rm -f conftest*
3040 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
3041 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
3042 cat >>confdefs.h <<EOF
3043 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
3047 done
3049 echo $ac_n "checking for mode_t... $ac_c" 1>&6
3050 echo "configure:3051: checking for mode_t" 1>&5
3051 if test "${ac_cv_type_mode_t+set}" = set; then
3052 echo $ac_n "(cached) $ac_c" 1>&6
3053 else
3054 cat >conftest.$ac_ext <<EOF
3055 #line 3056 "configure"
3056 #include "confdefs.h"
3057 #include <sys/types.h>
3058 #if STDC_HEADERS
3059 # include <stdlib.h>
3060 # include <stddef.h>
3061 #endif
3062 #if HAVE_UNISTD_H
3063 # include <unistd.h>
3064 #endif
3066 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3067 egrep "mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3068 rm -rf conftest*
3069 ac_cv_type_mode_t=yes
3070 else
3071 rm -rf conftest*
3072 ac_cv_type_mode_t=no
3074 rm -f conftest*
3077 echo "$ac_t""$ac_cv_type_mode_t" 1>&6
3078 if test $ac_cv_type_mode_t = no; then
3079 cat >>confdefs.h <<\EOF
3080 #define mode_t int
3085 for ac_header in unistd.h
3087 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
3088 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
3089 echo "configure:3090: checking for $ac_header" 1>&5
3090 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
3091 echo $ac_n "(cached) $ac_c" 1>&6
3092 else
3093 cat >conftest.$ac_ext <<EOF
3094 #line 3095 "configure"
3095 #include "confdefs.h"
3096 #include <$ac_header>
3099 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3100 { (eval echo configure:3101: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3101 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3102 if test -z "$ac_err"; then
3103 rm -rf conftest*
3104 eval "$ac_ac_Header=yes"
3105 else
3106 echo "$ac_err" >&5
3107 echo "configure: failed program was:" >&5
3108 cat conftest.$ac_ext >&5
3109 rm -rf conftest*
3110 eval "$ac_ac_Header=no"
3112 rm -f conftest*
3114 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
3115 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
3116 cat >>confdefs.h <<EOF
3117 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
3121 done
3123 echo $ac_n "checking for off_t... $ac_c" 1>&6
3124 echo "configure:3125: checking for off_t" 1>&5
3125 if test "${ac_cv_type_off_t+set}" = set; then
3126 echo $ac_n "(cached) $ac_c" 1>&6
3127 else
3128 cat >conftest.$ac_ext <<EOF
3129 #line 3130 "configure"
3130 #include "confdefs.h"
3131 #include <sys/types.h>
3132 #if STDC_HEADERS
3133 # include <stdlib.h>
3134 # include <stddef.h>
3135 #endif
3136 #if HAVE_UNISTD_H
3137 # include <unistd.h>
3138 #endif
3140 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3141 egrep "off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3142 rm -rf conftest*
3143 ac_cv_type_off_t=yes
3144 else
3145 rm -rf conftest*
3146 ac_cv_type_off_t=no
3148 rm -f conftest*
3151 echo "$ac_t""$ac_cv_type_off_t" 1>&6
3152 if test $ac_cv_type_off_t = no; then
3153 cat >>confdefs.h <<\EOF
3154 #define off_t long
3159 for ac_header in unistd.h
3161 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
3162 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
3163 echo "configure:3164: checking for $ac_header" 1>&5
3164 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
3165 echo $ac_n "(cached) $ac_c" 1>&6
3166 else
3167 cat >conftest.$ac_ext <<EOF
3168 #line 3169 "configure"
3169 #include "confdefs.h"
3170 #include <$ac_header>
3173 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3174 { (eval echo configure:3175: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3175 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3176 if test -z "$ac_err"; then
3177 rm -rf conftest*
3178 eval "$ac_ac_Header=yes"
3179 else
3180 echo "$ac_err" >&5
3181 echo "configure: failed program was:" >&5
3182 cat conftest.$ac_ext >&5
3183 rm -rf conftest*
3184 eval "$ac_ac_Header=no"
3186 rm -f conftest*
3188 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
3189 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
3190 cat >>confdefs.h <<EOF
3191 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
3195 done
3197 echo $ac_n "checking for pid_t... $ac_c" 1>&6
3198 echo "configure:3199: checking for pid_t" 1>&5
3199 if test "${ac_cv_type_pid_t+set}" = set; then
3200 echo $ac_n "(cached) $ac_c" 1>&6
3201 else
3202 cat >conftest.$ac_ext <<EOF
3203 #line 3204 "configure"
3204 #include "confdefs.h"
3205 #include <sys/types.h>
3206 #if STDC_HEADERS
3207 # include <stdlib.h>
3208 # include <stddef.h>
3209 #endif
3210 #if HAVE_UNISTD_H
3211 # include <unistd.h>
3212 #endif
3214 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3215 egrep "pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3216 rm -rf conftest*
3217 ac_cv_type_pid_t=yes
3218 else
3219 rm -rf conftest*
3220 ac_cv_type_pid_t=no
3222 rm -f conftest*
3225 echo "$ac_t""$ac_cv_type_pid_t" 1>&6
3226 if test $ac_cv_type_pid_t = no; then
3227 cat >>confdefs.h <<\EOF
3228 #define pid_t int
3233 echo $ac_n "checking return type of signal handlers... $ac_c" 1>&6
3234 echo "configure:3235: checking return type of signal handlers" 1>&5
3235 if test "${ac_cv_type_signal+set}" = set; then
3236 echo $ac_n "(cached) $ac_c" 1>&6
3237 else
3238 cat >conftest.$ac_ext <<EOF
3239 #line 3240 "configure"
3240 #include "confdefs.h"
3241 #include <sys/types.h>
3242 #include <signal.h>
3243 #ifdef signal
3244 # undef signal
3245 #endif
3246 #ifdef __cplusplus
3247 extern "C" void (*signal (int, void (*)(int)))(int);
3248 #else
3249 void (*signal ()) ();
3250 #endif
3253 main ()
3255 int i;
3257 return 0;
3260 if { (eval echo configure:3261: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3261 rm -rf conftest*
3262 ac_cv_type_signal=void
3263 else
3264 echo "configure: failed program was:" >&5
3265 cat conftest.$ac_ext >&5
3266 rm -rf conftest*
3267 ac_cv_type_signal=int
3269 rm -f conftest*
3271 echo "$ac_t""$ac_cv_type_signal" 1>&6
3272 cat >>confdefs.h <<EOF
3273 #define RETSIGTYPE $ac_cv_type_signal
3276 for ac_header in unistd.h
3278 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
3279 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
3280 echo "configure:3281: checking for $ac_header" 1>&5
3281 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
3282 echo $ac_n "(cached) $ac_c" 1>&6
3283 else
3284 cat >conftest.$ac_ext <<EOF
3285 #line 3286 "configure"
3286 #include "confdefs.h"
3287 #include <$ac_header>
3290 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3291 { (eval echo configure:3292: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3292 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3293 if test -z "$ac_err"; then
3294 rm -rf conftest*
3295 eval "$ac_ac_Header=yes"
3296 else
3297 echo "$ac_err" >&5
3298 echo "configure: failed program was:" >&5
3299 cat conftest.$ac_ext >&5
3300 rm -rf conftest*
3301 eval "$ac_ac_Header=no"
3303 rm -f conftest*
3305 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
3306 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
3307 cat >>confdefs.h <<EOF
3308 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
3312 done
3314 echo $ac_n "checking for size_t... $ac_c" 1>&6
3315 echo "configure:3316: checking for size_t" 1>&5
3316 if test "${ac_cv_type_size_t+set}" = set; then
3317 echo $ac_n "(cached) $ac_c" 1>&6
3318 else
3319 cat >conftest.$ac_ext <<EOF
3320 #line 3321 "configure"
3321 #include "confdefs.h"
3322 #include <sys/types.h>
3323 #if STDC_HEADERS
3324 # include <stdlib.h>
3325 # include <stddef.h>
3326 #endif
3327 #if HAVE_UNISTD_H
3328 # include <unistd.h>
3329 #endif
3331 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3332 egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3333 rm -rf conftest*
3334 ac_cv_type_size_t=yes
3335 else
3336 rm -rf conftest*
3337 ac_cv_type_size_t=no
3339 rm -f conftest*
3342 echo "$ac_t""$ac_cv_type_size_t" 1>&6
3343 if test $ac_cv_type_size_t = no; then
3344 cat >>confdefs.h <<\EOF
3345 #define size_t unsigned
3350 echo $ac_n "checking for uid_t in sys/types.h... $ac_c" 1>&6
3351 echo "configure:3352: checking for uid_t in sys/types.h" 1>&5
3352 if test "${ac_cv_type_uid_t+set}" = set; then
3353 echo $ac_n "(cached) $ac_c" 1>&6
3354 else
3355 cat >conftest.$ac_ext <<EOF
3356 #line 3357 "configure"
3357 #include "confdefs.h"
3358 #include <sys/types.h>
3361 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3362 egrep "uid_t" >/dev/null 2>&1; then
3363 rm -rf conftest*
3364 ac_cv_type_uid_t=yes
3365 else
3366 rm -rf conftest*
3367 ac_cv_type_uid_t=no
3369 rm -f conftest*
3372 echo "$ac_t""$ac_cv_type_uid_t" 1>&6
3373 if test $ac_cv_type_uid_t = no; then
3374 cat >>confdefs.h <<\EOF
3375 #define uid_t int
3378 cat >>confdefs.h <<\EOF
3379 #define gid_t int
3384 for ac_header in unistd.h
3386 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
3387 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
3388 echo "configure:3389: checking for $ac_header" 1>&5
3389 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
3390 echo $ac_n "(cached) $ac_c" 1>&6
3391 else
3392 cat >conftest.$ac_ext <<EOF
3393 #line 3394 "configure"
3394 #include "confdefs.h"
3395 #include <$ac_header>
3398 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3399 { (eval echo configure:3400: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3400 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3401 if test -z "$ac_err"; then
3402 rm -rf conftest*
3403 eval "$ac_ac_Header=yes"
3404 else
3405 echo "$ac_err" >&5
3406 echo "configure: failed program was:" >&5
3407 cat conftest.$ac_ext >&5
3408 rm -rf conftest*
3409 eval "$ac_ac_Header=no"
3411 rm -f conftest*
3413 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
3414 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
3415 cat >>confdefs.h <<EOF
3416 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
3420 done
3422 echo $ac_n "checking for ino_t... $ac_c" 1>&6
3423 echo "configure:3424: checking for ino_t" 1>&5
3424 if test "${ac_cv_type_ino_t+set}" = set; then
3425 echo $ac_n "(cached) $ac_c" 1>&6
3426 else
3427 cat >conftest.$ac_ext <<EOF
3428 #line 3429 "configure"
3429 #include "confdefs.h"
3430 #include <sys/types.h>
3431 #if STDC_HEADERS
3432 # include <stdlib.h>
3433 # include <stddef.h>
3434 #endif
3435 #if HAVE_UNISTD_H
3436 # include <unistd.h>
3437 #endif
3439 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3440 egrep "ino_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3441 rm -rf conftest*
3442 ac_cv_type_ino_t=yes
3443 else
3444 rm -rf conftest*
3445 ac_cv_type_ino_t=no
3447 rm -f conftest*
3450 echo "$ac_t""$ac_cv_type_ino_t" 1>&6
3451 if test $ac_cv_type_ino_t = no; then
3452 cat >>confdefs.h <<\EOF
3453 #define ino_t unsigned long
3458 for ac_header in unistd.h
3460 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
3461 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
3462 echo "configure:3463: checking for $ac_header" 1>&5
3463 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
3464 echo $ac_n "(cached) $ac_c" 1>&6
3465 else
3466 cat >conftest.$ac_ext <<EOF
3467 #line 3468 "configure"
3468 #include "confdefs.h"
3469 #include <$ac_header>
3472 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3473 { (eval echo configure:3474: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3474 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3475 if test -z "$ac_err"; then
3476 rm -rf conftest*
3477 eval "$ac_ac_Header=yes"
3478 else
3479 echo "$ac_err" >&5
3480 echo "configure: failed program was:" >&5
3481 cat conftest.$ac_ext >&5
3482 rm -rf conftest*
3483 eval "$ac_ac_Header=no"
3485 rm -f conftest*
3487 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
3488 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
3489 cat >>confdefs.h <<EOF
3490 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
3494 done
3496 echo $ac_n "checking for ssize_t... $ac_c" 1>&6
3497 echo "configure:3498: checking for ssize_t" 1>&5
3498 if test "${ac_cv_type_ssize_t+set}" = set; then
3499 echo $ac_n "(cached) $ac_c" 1>&6
3500 else
3501 cat >conftest.$ac_ext <<EOF
3502 #line 3503 "configure"
3503 #include "confdefs.h"
3504 #include <sys/types.h>
3505 #if STDC_HEADERS
3506 # include <stdlib.h>
3507 # include <stddef.h>
3508 #endif
3509 #if HAVE_UNISTD_H
3510 # include <unistd.h>
3511 #endif
3513 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3514 egrep "ssize_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3515 rm -rf conftest*
3516 ac_cv_type_ssize_t=yes
3517 else
3518 rm -rf conftest*
3519 ac_cv_type_ssize_t=no
3521 rm -f conftest*
3524 echo "$ac_t""$ac_cv_type_ssize_t" 1>&6
3525 if test $ac_cv_type_ssize_t = no; then
3526 cat >>confdefs.h <<\EOF
3527 #define ssize_t int
3532 echo $ac_n "checking for getpwnam in -lsun... $ac_c" 1>&6
3533 echo "configure:3534: checking for getpwnam in -lsun" 1>&5
3534 if test "${ac_cv_lib_sun_getpwnam+set}" = set; then
3535 echo $ac_n "(cached) $ac_c" 1>&6
3536 else
3537 ac_save_LIBS="$LIBS"
3538 LIBS="-lsun $LIBS"
3539 cat >conftest.$ac_ext <<EOF
3540 #line 3541 "configure"
3541 #include "confdefs.h"
3542 /* Override any gcc2 internal prototype to avoid an error. */
3543 /* We use char because int might match the return type of a gcc2
3544 builtin and then its argument prototype would still apply. */
3545 char getpwnam();
3548 main()
3550 getpwnam()
3552 return 0;
3555 if { (eval echo configure:3556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3556 rm -rf conftest*
3557 ac_cv_lib_sun_getpwnam=yes
3558 else
3559 echo "configure: failed program was:" >&5
3560 cat conftest.$ac_ext >&5
3561 rm -rf conftest*
3562 ac_cv_lib_sun_getpwnam=no
3564 rm -f conftest*
3566 LIBS="$ac_save_LIBS"
3568 echo "$ac_t""$ac_cv_lib_sun_getpwnam" 1>&6
3569 if test $ac_cv_lib_sun_getpwnam = yes; then
3570 cat >>confdefs.h <<EOF
3571 #define HAVE_LIBSUN 1
3574 LIBS="-lsun $LIBS"
3578 for ac_header in fcntl.h string.h limits.h unistd.h errno.h
3580 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
3581 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
3582 echo "configure:3583: checking for $ac_header" 1>&5
3583 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
3584 echo $ac_n "(cached) $ac_c" 1>&6
3585 else
3586 cat >conftest.$ac_ext <<EOF
3587 #line 3588 "configure"
3588 #include "confdefs.h"
3589 #include <$ac_header>
3592 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3593 { (eval echo configure:3594: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3594 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3595 if test -z "$ac_err"; then
3596 rm -rf conftest*
3597 eval "$ac_ac_Header=yes"
3598 else
3599 echo "$ac_err" >&5
3600 echo "configure: failed program was:" >&5
3601 cat conftest.$ac_ext >&5
3602 rm -rf conftest*
3603 eval "$ac_ac_Header=no"
3605 rm -f conftest*
3607 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
3608 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
3609 cat >>confdefs.h <<EOF
3610 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
3614 done
3616 echo $ac_n "checking for ANSI C header files... $ac_c" 1>&6
3617 echo "configure:3618: checking for ANSI C header files" 1>&5
3618 if test "${ac_cv_header_stdc+set}" = set; then
3619 echo $ac_n "(cached) $ac_c" 1>&6
3620 else
3621 cat >conftest.$ac_ext <<EOF
3622 #line 3623 "configure"
3623 #include "confdefs.h"
3624 #include <stdlib.h>
3625 #include <stdarg.h>
3626 #include <string.h>
3627 #include <float.h>
3630 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3631 { (eval echo configure:3632: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3632 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3633 if test -z "$ac_err"; then
3634 rm -rf conftest*
3635 ac_cv_header_stdc=yes
3636 else
3637 echo "$ac_err" >&5
3638 echo "configure: failed program was:" >&5
3639 cat conftest.$ac_ext >&5
3640 rm -rf conftest*
3641 ac_cv_header_stdc=no
3643 rm -f conftest*
3645 if test $ac_cv_header_stdc = yes; then
3646 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3647 cat >conftest.$ac_ext <<EOF
3648 #line 3649 "configure"
3649 #include "confdefs.h"
3650 #include <string.h>
3653 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3654 egrep "memchr" >/dev/null 2>&1; then
3656 else
3657 rm -rf conftest*
3658 ac_cv_header_stdc=no
3660 rm -f conftest*
3664 if test $ac_cv_header_stdc = yes; then
3665 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3666 cat >conftest.$ac_ext <<EOF
3667 #line 3668 "configure"
3668 #include "confdefs.h"
3669 #include <stdlib.h>
3672 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3673 egrep "free" >/dev/null 2>&1; then
3675 else
3676 rm -rf conftest*
3677 ac_cv_header_stdc=no
3679 rm -f conftest*
3683 if test $ac_cv_header_stdc = yes; then
3684 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3685 if test "$cross_compiling" = yes; then
3687 else
3688 cat >conftest.$ac_ext <<EOF
3689 #line 3690 "configure"
3690 #include "confdefs.h"
3691 #include <ctype.h>
3692 #if ((' ' & 0x0FF) == 0x020)
3693 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3694 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3695 #else
3696 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
3697 || ('j' <= (c) && (c) <= 'r') \
3698 || ('s' <= (c) && (c) <= 'z'))
3699 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3700 #endif
3702 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3704 main ()
3706 int i;
3707 for (i = 0; i < 256; i++)
3708 if (XOR (islower (i), ISLOWER (i))
3709 || toupper (i) != TOUPPER (i))
3710 exit(2);
3711 exit (0);
3714 if { (eval echo configure:3715: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3715 then
3717 else
3718 echo "configure: failed program was:" >&5
3719 cat conftest.$ac_ext >&5
3720 rm -fr conftest*
3721 ac_cv_header_stdc=no
3723 rm -fr conftest*
3729 echo "$ac_t""$ac_cv_header_stdc" 1>&6
3730 if test $ac_cv_header_stdc = yes; then
3731 cat >>confdefs.h <<\EOF
3732 #define STDC_HEADERS 1
3737 echo $ac_n "checking whether sys/types.h defines makedev... $ac_c" 1>&6
3738 echo "configure:3739: checking whether sys/types.h defines makedev" 1>&5
3739 if test "${ac_cv_header_sys_types_h_makedev+set}" = set; then
3740 echo $ac_n "(cached) $ac_c" 1>&6
3741 else
3742 cat >conftest.$ac_ext <<EOF
3743 #line 3744 "configure"
3744 #include "confdefs.h"
3745 #include <sys/types.h>
3748 main()
3750 return makedev(0, 0);
3752 return 0;
3755 if { (eval echo configure:3756: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3756 rm -rf conftest*
3757 ac_cv_header_sys_types_h_makedev=yes
3758 else
3759 echo "configure: failed program was:" >&5
3760 cat conftest.$ac_ext >&5
3761 rm -rf conftest*
3762 ac_cv_header_sys_types_h_makedev=no
3764 rm -f conftest*
3767 echo "$ac_t""$ac_cv_header_sys_types_h_makedev" 1>&6
3769 if test $ac_cv_header_sys_types_h_makedev = no; then
3770 echo $ac_n "checking for sys/mkdev.h... $ac_c" 1>&6
3771 echo "configure:3772: checking for sys/mkdev.h" 1>&5
3772 if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
3773 echo $ac_n "(cached) $ac_c" 1>&6
3774 else
3775 cat >conftest.$ac_ext <<EOF
3776 #line 3777 "configure"
3777 #include "confdefs.h"
3778 #include <sys/mkdev.h>
3781 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3782 { (eval echo configure:3783: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3783 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3784 if test -z "$ac_err"; then
3785 rm -rf conftest*
3786 ac_cv_header_sys_mkdev_h=yes
3787 else
3788 echo "$ac_err" >&5
3789 echo "configure: failed program was:" >&5
3790 cat conftest.$ac_ext >&5
3791 rm -rf conftest*
3792 ac_cv_header_sys_mkdev_h=no
3794 rm -f conftest*
3796 echo "$ac_t""$ac_cv_header_sys_mkdev_h" 1>&6
3797 if test $ac_cv_header_sys_mkdev_h = yes; then
3798 cat >>confdefs.h <<\EOF
3799 #define MAJOR_IN_MKDEV 1
3804 if test $ac_cv_header_sys_mkdev_h = no; then
3805 echo $ac_n "checking for sys/sysmacros.h... $ac_c" 1>&6
3806 echo "configure:3807: checking for sys/sysmacros.h" 1>&5
3807 if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
3808 echo $ac_n "(cached) $ac_c" 1>&6
3809 else
3810 cat >conftest.$ac_ext <<EOF
3811 #line 3812 "configure"
3812 #include "confdefs.h"
3813 #include <sys/sysmacros.h>
3816 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3817 { (eval echo configure:3818: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3818 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3819 if test -z "$ac_err"; then
3820 rm -rf conftest*
3821 ac_cv_header_sys_sysmacros_h=yes
3822 else
3823 echo "$ac_err" >&5
3824 echo "configure: failed program was:" >&5
3825 cat conftest.$ac_ext >&5
3826 rm -rf conftest*
3827 ac_cv_header_sys_sysmacros_h=no
3829 rm -f conftest*
3831 echo "$ac_t""$ac_cv_header_sys_sysmacros_h" 1>&6
3832 if test $ac_cv_header_sys_sysmacros_h = yes; then
3833 cat >>confdefs.h <<\EOF
3834 #define MAJOR_IN_SYSMACROS 1
3842 ac_header_dirent=no
3843 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
3845 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3846 echo $ac_n "checking for $ac_hdr that defines DIR... $ac_c" 1>&6
3847 echo "configure:3848: checking for $ac_hdr that defines DIR" 1>&5
3848 if eval "test \"\${ac_cv_header_dirent_$ac_safe+set}\" = set"; then
3849 echo $ac_n "(cached) $ac_c" 1>&6
3850 else
3851 cat >conftest.$ac_ext <<EOF
3852 #line 3853 "configure"
3853 #include "confdefs.h"
3854 #include <sys/types.h>
3855 #include <$ac_hdr>
3858 main ()
3860 DIR *dirp = 0;
3862 return 0;
3865 if { (eval echo configure:3866: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3866 rm -rf conftest*
3867 eval "ac_cv_header_dirent_$ac_safe=yes"
3868 else
3869 echo "configure: failed program was:" >&5
3870 cat conftest.$ac_ext >&5
3871 rm -rf conftest*
3872 eval "ac_cv_header_dirent_$ac_safe=no"
3874 rm -f conftest*
3876 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
3877 echo "$ac_t""yes" 1>&6
3878 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3879 cat >>confdefs.h <<EOF
3880 #define $ac_tr_hdr 1
3882 ac_header_dirent=$ac_hdr; break
3883 else
3884 echo "$ac_t""no" 1>&6
3886 done
3887 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
3888 if test $ac_header_dirent = dirent.h; then
3889 echo $ac_n "checking for opendir in -ldir... $ac_c" 1>&6
3890 echo "configure:3891: checking for opendir in -ldir" 1>&5
3891 if test "${ac_cv_lib_dir_opendir+set}" = set; then
3892 echo $ac_n "(cached) $ac_c" 1>&6
3893 else
3894 ac_save_LIBS="$LIBS"
3895 LIBS="-ldir $LIBS"
3896 cat >conftest.$ac_ext <<EOF
3897 #line 3898 "configure"
3898 #include "confdefs.h"
3899 /* Override any gcc2 internal prototype to avoid an error. */
3900 /* We use char because int might match the return type of a gcc2
3901 builtin and then its argument prototype would still apply. */
3902 char opendir();
3905 main()
3907 opendir()
3909 return 0;
3912 if { (eval echo configure:3913: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3913 rm -rf conftest*
3914 ac_cv_lib_dir_opendir=yes
3915 else
3916 echo "configure: failed program was:" >&5
3917 cat conftest.$ac_ext >&5
3918 rm -rf conftest*
3919 ac_cv_lib_dir_opendir=no
3921 rm -f conftest*
3923 LIBS="$ac_save_LIBS"
3925 echo "$ac_t""$ac_cv_lib_dir_opendir" 1>&6
3926 if test $ac_cv_lib_dir_opendir = yes; then
3927 LIBS="$LIBS -ldir"
3930 else
3931 echo $ac_n "checking for opendir in -lx... $ac_c" 1>&6
3932 echo "configure:3933: checking for opendir in -lx" 1>&5
3933 if test "${ac_cv_lib_x_opendir+set}" = set; then
3934 echo $ac_n "(cached) $ac_c" 1>&6
3935 else
3936 ac_save_LIBS="$LIBS"
3937 LIBS="-lx $LIBS"
3938 cat >conftest.$ac_ext <<EOF
3939 #line 3940 "configure"
3940 #include "confdefs.h"
3941 /* Override any gcc2 internal prototype to avoid an error. */
3942 /* We use char because int might match the return type of a gcc2
3943 builtin and then its argument prototype would still apply. */
3944 char opendir();
3947 main()
3949 opendir()
3951 return 0;
3954 if { (eval echo configure:3955: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3955 rm -rf conftest*
3956 ac_cv_lib_x_opendir=yes
3957 else
3958 echo "configure: failed program was:" >&5
3959 cat conftest.$ac_ext >&5
3960 rm -rf conftest*
3961 ac_cv_lib_x_opendir=no
3963 rm -f conftest*
3965 LIBS="$ac_save_LIBS"
3967 echo "$ac_t""$ac_cv_lib_x_opendir" 1>&6
3968 if test $ac_cv_lib_x_opendir = yes; then
3969 LIBS="$LIBS -lx"
3974 echo $ac_n "checking whether stat file-mode macros are broken... $ac_c" 1>&6
3975 echo "configure:3976: checking whether stat file-mode macros are broken" 1>&5
3976 if test "${ac_cv_header_stat_broken+set}" = set; then
3977 echo $ac_n "(cached) $ac_c" 1>&6
3978 else
3979 cat >conftest.$ac_ext <<EOF
3980 #line 3981 "configure"
3981 #include "confdefs.h"
3982 #include <sys/types.h>
3983 #include <sys/stat.h>
3985 #if defined(S_ISBLK) && defined(S_IFDIR)
3986 # if S_ISBLK (S_IFDIR)
3987 You lose.
3988 # endif
3989 #endif
3991 #if defined(S_ISBLK) && defined(S_IFCHR)
3992 # if S_ISBLK (S_IFCHR)
3993 You lose.
3994 # endif
3995 #endif
3997 #if defined(S_ISLNK) && defined(S_IFREG)
3998 # if S_ISLNK (S_IFREG)
3999 You lose.
4000 # endif
4001 #endif
4003 #if defined(S_ISSOCK) && defined(S_IFREG)
4004 # if S_ISSOCK (S_IFREG)
4005 You lose.
4006 # endif
4007 #endif
4010 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4011 egrep "You lose" >/dev/null 2>&1; then
4012 rm -rf conftest*
4013 ac_cv_header_stat_broken=yes
4014 else
4015 rm -rf conftest*
4016 ac_cv_header_stat_broken=no
4018 rm -f conftest*
4021 echo "$ac_t""$ac_cv_header_stat_broken" 1>&6
4022 if test $ac_cv_header_stat_broken = yes; then
4023 cat >>confdefs.h <<\EOF
4024 #define STAT_MACROS_BROKEN 1
4029 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible... $ac_c" 1>&6
4030 echo "configure:4031: checking for sys/wait.h that is POSIX.1 compatible" 1>&5
4031 if test "${ac_cv_header_sys_wait_h+set}" = set; then
4032 echo $ac_n "(cached) $ac_c" 1>&6
4033 else
4034 cat >conftest.$ac_ext <<EOF
4035 #line 4036 "configure"
4036 #include "confdefs.h"
4037 #include <sys/types.h>
4038 #include <sys/wait.h>
4039 #ifndef WEXITSTATUS
4040 # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
4041 #endif
4042 #ifndef WIFEXITED
4043 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
4044 #endif
4046 main ()
4048 int s;
4049 wait (&s);
4050 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
4052 return 0;
4055 if { (eval echo configure:4056: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4056 rm -rf conftest*
4057 ac_cv_header_sys_wait_h=yes
4058 else
4059 echo "configure: failed program was:" >&5
4060 cat conftest.$ac_ext >&5
4061 rm -rf conftest*
4062 ac_cv_header_sys_wait_h=no
4064 rm -f conftest*
4066 echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
4067 if test $ac_cv_header_sys_wait_h = yes; then
4068 cat >>confdefs.h <<\EOF
4069 #define HAVE_SYS_WAIT_H 1
4074 echo $ac_n "checking how to get filesystem type... $ac_c" 1>&6
4075 echo "configure:4076: checking how to get filesystem type" 1>&5
4076 fstype=no
4077 # The order of these tests is important.
4078 cat >conftest.$ac_ext <<EOF
4079 #line 4080 "configure"
4080 #include "confdefs.h"
4081 #include <sys/statvfs.h>
4082 #include <sys/fstyp.h>
4084 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4085 { (eval echo configure:4086: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4086 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4087 if test -z "$ac_err"; then
4088 rm -rf conftest*
4089 cat >>confdefs.h <<\EOF
4090 #define FSTYPE_STATVFS 1
4092 fstype=SVR4
4093 else
4094 echo "$ac_err" >&5
4095 echo "configure: failed program was:" >&5
4096 cat conftest.$ac_ext >&5
4098 rm -f conftest*
4099 if test $fstype = no; then
4100 cat >conftest.$ac_ext <<EOF
4101 #line 4102 "configure"
4102 #include "confdefs.h"
4103 #include <sys/statfs.h>
4104 #include <sys/fstyp.h>
4106 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4107 { (eval echo configure:4108: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4108 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4109 if test -z "$ac_err"; then
4110 rm -rf conftest*
4111 cat >>confdefs.h <<\EOF
4112 #define FSTYPE_USG_STATFS 1
4114 fstype=SVR3
4115 else
4116 echo "$ac_err" >&5
4117 echo "configure: failed program was:" >&5
4118 cat conftest.$ac_ext >&5
4120 rm -f conftest*
4122 if test $fstype = no; then
4123 cat >conftest.$ac_ext <<EOF
4124 #line 4125 "configure"
4125 #include "confdefs.h"
4126 #include <sys/statfs.h>
4127 #include <sys/vmount.h>
4129 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4130 { (eval echo configure:4131: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4131 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4132 if test -z "$ac_err"; then
4133 rm -rf conftest*
4134 cat >>confdefs.h <<\EOF
4135 #define FSTYPE_AIX_STATFS 1
4137 fstype=AIX
4138 else
4139 echo "$ac_err" >&5
4140 echo "configure: failed program was:" >&5
4141 cat conftest.$ac_ext >&5
4143 rm -f conftest*
4145 if test $fstype = no; then
4146 cat >conftest.$ac_ext <<EOF
4147 #line 4148 "configure"
4148 #include "confdefs.h"
4149 #include <mntent.h>
4151 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4152 { (eval echo configure:4153: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4153 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4154 if test -z "$ac_err"; then
4155 rm -rf conftest*
4156 cat >>confdefs.h <<\EOF
4157 #define FSTYPE_MNTENT 1
4159 fstype=4.3BSD
4160 else
4161 echo "$ac_err" >&5
4162 echo "configure: failed program was:" >&5
4163 cat conftest.$ac_ext >&5
4165 rm -f conftest*
4167 if test $fstype = no; then
4168 cat >conftest.$ac_ext <<EOF
4169 #line 4170 "configure"
4170 #include "confdefs.h"
4171 #include <sys/mount.h>
4174 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4175 egrep "f_type;" >/dev/null 2>&1; then
4176 rm -rf conftest*
4177 cat >>confdefs.h <<\EOF
4178 #define FSTYPE_STATFS 1
4180 fstype=4.4BSD/OSF1
4182 rm -f conftest*
4185 if test $fstype = no; then
4186 cat >conftest.$ac_ext <<EOF
4187 #line 4188 "configure"
4188 #include "confdefs.h"
4189 #include <sys/mount.h>
4190 #include <sys/fs_types.h>
4192 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4193 { (eval echo configure:4194: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4194 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4195 if test -z "$ac_err"; then
4196 rm -rf conftest*
4197 cat >>confdefs.h <<\EOF
4198 #define FSTYPE_GETMNT 1
4200 fstype=Ultrix
4201 else
4202 echo "$ac_err" >&5
4203 echo "configure: failed program was:" >&5
4204 cat conftest.$ac_ext >&5
4206 rm -f conftest*
4208 echo "$ac_t""$fstype" 1>&6
4210 echo $ac_n "checking for uid_t in sys/types.h... $ac_c" 1>&6
4211 echo "configure:4212: checking for uid_t in sys/types.h" 1>&5
4212 if test "${ac_cv_type_uid_t+set}" = set; then
4213 echo $ac_n "(cached) $ac_c" 1>&6
4214 else
4215 cat >conftest.$ac_ext <<EOF
4216 #line 4217 "configure"
4217 #include "confdefs.h"
4218 #include <sys/types.h>
4221 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4222 egrep "uid_t" >/dev/null 2>&1; then
4223 rm -rf conftest*
4224 ac_cv_type_uid_t=yes
4225 else
4226 rm -rf conftest*
4227 ac_cv_type_uid_t=no
4229 rm -f conftest*
4232 echo "$ac_t""$ac_cv_type_uid_t" 1>&6
4233 if test $ac_cv_type_uid_t = no; then
4234 cat >>confdefs.h <<\EOF
4235 #define uid_t int
4238 cat >>confdefs.h <<\EOF
4239 #define gid_t int
4244 for ac_header in unistd.h
4246 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
4247 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
4248 echo "configure:4249: checking for $ac_header" 1>&5
4249 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
4250 echo $ac_n "(cached) $ac_c" 1>&6
4251 else
4252 cat >conftest.$ac_ext <<EOF
4253 #line 4254 "configure"
4254 #include "confdefs.h"
4255 #include <$ac_header>
4258 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4259 { (eval echo configure:4260: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4260 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4261 if test -z "$ac_err"; then
4262 rm -rf conftest*
4263 eval "$ac_ac_Header=yes"
4264 else
4265 echo "$ac_err" >&5
4266 echo "configure: failed program was:" >&5
4267 cat conftest.$ac_ext >&5
4268 rm -rf conftest*
4269 eval "$ac_ac_Header=no"
4271 rm -f conftest*
4273 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
4274 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
4275 cat >>confdefs.h <<EOF
4276 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
4280 done
4282 echo $ac_n "checking for size_t... $ac_c" 1>&6
4283 echo "configure:4284: checking for size_t" 1>&5
4284 if test "${ac_cv_type_size_t+set}" = set; then
4285 echo $ac_n "(cached) $ac_c" 1>&6
4286 else
4287 cat >conftest.$ac_ext <<EOF
4288 #line 4289 "configure"
4289 #include "confdefs.h"
4290 #include <sys/types.h>
4291 #if STDC_HEADERS
4292 # include <stdlib.h>
4293 # include <stddef.h>
4294 #endif
4295 #if HAVE_UNISTD_H
4296 # include <unistd.h>
4297 #endif
4299 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4300 egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4301 rm -rf conftest*
4302 ac_cv_type_size_t=yes
4303 else
4304 rm -rf conftest*
4305 ac_cv_type_size_t=no
4307 rm -f conftest*
4310 echo "$ac_t""$ac_cv_type_size_t" 1>&6
4311 if test $ac_cv_type_size_t = no; then
4312 cat >>confdefs.h <<\EOF
4313 #define size_t unsigned
4318 for ac_header in unistd.h
4320 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
4321 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
4322 echo "configure:4323: checking for $ac_header" 1>&5
4323 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
4324 echo $ac_n "(cached) $ac_c" 1>&6
4325 else
4326 cat >conftest.$ac_ext <<EOF
4327 #line 4328 "configure"
4328 #include "confdefs.h"
4329 #include <$ac_header>
4332 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4333 { (eval echo configure:4334: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4334 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4335 if test -z "$ac_err"; then
4336 rm -rf conftest*
4337 eval "$ac_ac_Header=yes"
4338 else
4339 echo "$ac_err" >&5
4340 echo "configure: failed program was:" >&5
4341 cat conftest.$ac_ext >&5
4342 rm -rf conftest*
4343 eval "$ac_ac_Header=no"
4345 rm -f conftest*
4347 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
4348 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
4349 cat >>confdefs.h <<EOF
4350 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
4354 done
4356 echo $ac_n "checking for pid_t... $ac_c" 1>&6
4357 echo "configure:4358: checking for pid_t" 1>&5
4358 if test "${ac_cv_type_pid_t+set}" = set; then
4359 echo $ac_n "(cached) $ac_c" 1>&6
4360 else
4361 cat >conftest.$ac_ext <<EOF
4362 #line 4363 "configure"
4363 #include "confdefs.h"
4364 #include <sys/types.h>
4365 #if STDC_HEADERS
4366 # include <stdlib.h>
4367 # include <stddef.h>
4368 #endif
4369 #if HAVE_UNISTD_H
4370 # include <unistd.h>
4371 #endif
4373 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4374 egrep "pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4375 rm -rf conftest*
4376 ac_cv_type_pid_t=yes
4377 else
4378 rm -rf conftest*
4379 ac_cv_type_pid_t=no
4381 rm -f conftest*
4384 echo "$ac_t""$ac_cv_type_pid_t" 1>&6
4385 if test $ac_cv_type_pid_t = no; then
4386 cat >>confdefs.h <<\EOF
4387 #define pid_t int
4392 for ac_header in unistd.h
4394 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
4395 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
4396 echo "configure:4397: checking for $ac_header" 1>&5
4397 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
4398 echo $ac_n "(cached) $ac_c" 1>&6
4399 else
4400 cat >conftest.$ac_ext <<EOF
4401 #line 4402 "configure"
4402 #include "confdefs.h"
4403 #include <$ac_header>
4406 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4407 { (eval echo configure:4408: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4408 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4409 if test -z "$ac_err"; then
4410 rm -rf conftest*
4411 eval "$ac_ac_Header=yes"
4412 else
4413 echo "$ac_err" >&5
4414 echo "configure: failed program was:" >&5
4415 cat conftest.$ac_ext >&5
4416 rm -rf conftest*
4417 eval "$ac_ac_Header=no"
4419 rm -f conftest*
4421 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
4422 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
4423 cat >>confdefs.h <<EOF
4424 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
4428 done
4430 echo $ac_n "checking for ino_t... $ac_c" 1>&6
4431 echo "configure:4432: checking for ino_t" 1>&5
4432 if test "${ac_cv_type_ino_t+set}" = set; then
4433 echo $ac_n "(cached) $ac_c" 1>&6
4434 else
4435 cat >conftest.$ac_ext <<EOF
4436 #line 4437 "configure"
4437 #include "confdefs.h"
4438 #include <sys/types.h>
4439 #if STDC_HEADERS
4440 # include <stdlib.h>
4441 # include <stddef.h>
4442 #endif
4443 #if HAVE_UNISTD_H
4444 # include <unistd.h>
4445 #endif
4447 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4448 egrep "ino_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4449 rm -rf conftest*
4450 ac_cv_type_ino_t=yes
4451 else
4452 rm -rf conftest*
4453 ac_cv_type_ino_t=no
4455 rm -f conftest*
4458 echo "$ac_t""$ac_cv_type_ino_t" 1>&6
4459 if test $ac_cv_type_ino_t = no; then
4460 cat >>confdefs.h <<\EOF
4461 #define ino_t unsigned long
4466 for ac_header in unistd.h
4468 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
4469 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
4470 echo "configure:4471: checking for $ac_header" 1>&5
4471 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
4472 echo $ac_n "(cached) $ac_c" 1>&6
4473 else
4474 cat >conftest.$ac_ext <<EOF
4475 #line 4476 "configure"
4476 #include "confdefs.h"
4477 #include <$ac_header>
4480 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4481 { (eval echo configure:4482: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4482 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4483 if test -z "$ac_err"; then
4484 rm -rf conftest*
4485 eval "$ac_ac_Header=yes"
4486 else
4487 echo "$ac_err" >&5
4488 echo "configure: failed program was:" >&5
4489 cat conftest.$ac_ext >&5
4490 rm -rf conftest*
4491 eval "$ac_ac_Header=no"
4493 rm -f conftest*
4495 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
4496 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
4497 cat >>confdefs.h <<EOF
4498 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
4502 done
4504 echo $ac_n "checking for dev_t... $ac_c" 1>&6
4505 echo "configure:4506: checking for dev_t" 1>&5
4506 if test "${ac_cv_type_dev_t+set}" = set; then
4507 echo $ac_n "(cached) $ac_c" 1>&6
4508 else
4509 cat >conftest.$ac_ext <<EOF
4510 #line 4511 "configure"
4511 #include "confdefs.h"
4512 #include <sys/types.h>
4513 #if STDC_HEADERS
4514 # include <stdlib.h>
4515 # include <stddef.h>
4516 #endif
4517 #if HAVE_UNISTD_H
4518 # include <unistd.h>
4519 #endif
4521 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4522 egrep "dev_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4523 rm -rf conftest*
4524 ac_cv_type_dev_t=yes
4525 else
4526 rm -rf conftest*
4527 ac_cv_type_dev_t=no
4529 rm -f conftest*
4532 echo "$ac_t""$ac_cv_type_dev_t" 1>&6
4533 if test $ac_cv_type_dev_t = no; then
4534 cat >>confdefs.h <<\EOF
4535 #define dev_t unsigned long
4540 for ac_header in unistd.h
4542 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
4543 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
4544 echo "configure:4545: checking for $ac_header" 1>&5
4545 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
4546 echo $ac_n "(cached) $ac_c" 1>&6
4547 else
4548 cat >conftest.$ac_ext <<EOF
4549 #line 4550 "configure"
4550 #include "confdefs.h"
4551 #include <$ac_header>
4554 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4555 { (eval echo configure:4556: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4556 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4557 if test -z "$ac_err"; then
4558 rm -rf conftest*
4559 eval "$ac_ac_Header=yes"
4560 else
4561 echo "$ac_err" >&5
4562 echo "configure: failed program was:" >&5
4563 cat conftest.$ac_ext >&5
4564 rm -rf conftest*
4565 eval "$ac_ac_Header=no"
4567 rm -f conftest*
4569 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
4570 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
4571 cat >>confdefs.h <<EOF
4572 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
4576 done
4578 echo $ac_n "checking for mode_t... $ac_c" 1>&6
4579 echo "configure:4580: checking for mode_t" 1>&5
4580 if test "${ac_cv_type_mode_t+set}" = set; then
4581 echo $ac_n "(cached) $ac_c" 1>&6
4582 else
4583 cat >conftest.$ac_ext <<EOF
4584 #line 4585 "configure"
4585 #include "confdefs.h"
4586 #include <sys/types.h>
4587 #if STDC_HEADERS
4588 # include <stdlib.h>
4589 # include <stddef.h>
4590 #endif
4591 #if HAVE_UNISTD_H
4592 # include <unistd.h>
4593 #endif
4595 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4596 egrep "mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4597 rm -rf conftest*
4598 ac_cv_type_mode_t=yes
4599 else
4600 rm -rf conftest*
4601 ac_cv_type_mode_t=no
4603 rm -f conftest*
4606 echo "$ac_t""$ac_cv_type_mode_t" 1>&6
4607 if test $ac_cv_type_mode_t = no; then
4608 cat >>confdefs.h <<\EOF
4609 #define mode_t int
4614 echo $ac_n "checking for struct stat.st_blocks... $ac_c" 1>&6
4615 echo "configure:4616: checking for struct stat.st_blocks" 1>&5
4616 if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
4617 echo $ac_n "(cached) $ac_c" 1>&6
4618 else
4619 cat >conftest.$ac_ext <<EOF
4620 #line 4621 "configure"
4621 #include "confdefs.h"
4622 #include <sys/types.h>
4623 #include <sys/stat.h>
4626 main ()
4628 struct stat foo;
4629 foo.st_blocks;
4631 return 0;
4634 if { (eval echo configure:4635: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4635 rm -rf conftest*
4636 ac_cv_member_struct_stat_st_blocks=yes
4637 else
4638 echo "configure: failed program was:" >&5
4639 cat conftest.$ac_ext >&5
4640 rm -rf conftest*
4641 ac_cv_member_struct_stat_st_blocks=no
4643 rm -f conftest*
4645 echo "$ac_t""$ac_cv_member_struct_stat_st_blocks" 1>&6
4646 if test $ac_cv_member_struct_stat_st_blocks = yes; then
4647 cat >>confdefs.h <<EOF
4648 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
4651 cat >>confdefs.h <<\EOF
4652 #define HAVE_ST_BLOCKS 1
4655 else
4656 LIBOBJS="$LIBOBJS fileblocks.${ac_objext}"
4660 echo $ac_n "checking for struct stat.st_rdev... $ac_c" 1>&6
4661 echo "configure:4662: checking for struct stat.st_rdev" 1>&5
4662 if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then
4663 echo $ac_n "(cached) $ac_c" 1>&6
4664 else
4665 cat >conftest.$ac_ext <<EOF
4666 #line 4667 "configure"
4667 #include "confdefs.h"
4668 $ac_includes_default
4670 main ()
4672 struct stat foo;
4673 foo.st_rdev;
4675 return 0;
4678 if { (eval echo configure:4679: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4679 rm -rf conftest*
4680 ac_cv_member_struct_stat_st_rdev=yes
4681 else
4682 echo "configure: failed program was:" >&5
4683 cat conftest.$ac_ext >&5
4684 rm -rf conftest*
4685 ac_cv_member_struct_stat_st_rdev=no
4687 rm -f conftest*
4689 echo "$ac_t""$ac_cv_member_struct_stat_st_rdev" 1>&6
4690 if test $ac_cv_member_struct_stat_st_rdev = yes; then
4691 cat >>confdefs.h <<EOF
4692 #define HAVE_STRUCT_STAT_ST_RDEV 1
4697 echo $ac_n "checking whether struct tm is in sys/time.h or time.h... $ac_c" 1>&6
4698 echo "configure:4699: checking whether struct tm is in sys/time.h or time.h" 1>&5
4699 if test "${ac_cv_struct_tm+set}" = set; then
4700 echo $ac_n "(cached) $ac_c" 1>&6
4701 else
4702 cat >conftest.$ac_ext <<EOF
4703 #line 4704 "configure"
4704 #include "confdefs.h"
4705 #include <sys/types.h>
4706 #include <time.h>
4709 main ()
4711 struct tm *tp; tp->tm_sec;
4713 return 0;
4716 if { (eval echo configure:4717: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4717 rm -rf conftest*
4718 ac_cv_struct_tm=time.h
4719 else
4720 echo "configure: failed program was:" >&5
4721 cat conftest.$ac_ext >&5
4722 rm -rf conftest*
4723 ac_cv_struct_tm=sys/time.h
4725 rm -f conftest*
4727 echo "$ac_t""$ac_cv_struct_tm" 1>&6
4728 if test $ac_cv_struct_tm = sys/time.h; then
4729 cat >>confdefs.h <<\EOF
4730 #define TM_IN_SYS_TIME 1
4735 echo $ac_n "checking for struct tm.tm_zone... $ac_c" 1>&6
4736 echo "configure:4737: checking for struct tm.tm_zone" 1>&5
4737 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
4738 echo $ac_n "(cached) $ac_c" 1>&6
4739 else
4740 cat >conftest.$ac_ext <<EOF
4741 #line 4742 "configure"
4742 #include "confdefs.h"
4743 #include <sys/types.h>
4744 #include <$ac_cv_struct_tm>
4747 main ()
4749 struct tm foo;
4750 foo.tm_zone;
4752 return 0;
4755 if { (eval echo configure:4756: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4756 rm -rf conftest*
4757 ac_cv_member_struct_tm_tm_zone=yes
4758 else
4759 echo "configure: failed program was:" >&5
4760 cat conftest.$ac_ext >&5
4761 rm -rf conftest*
4762 ac_cv_member_struct_tm_tm_zone=no
4764 rm -f conftest*
4766 echo "$ac_t""$ac_cv_member_struct_tm_tm_zone" 1>&6
4767 if test $ac_cv_member_struct_tm_tm_zone = yes; then
4768 cat >>confdefs.h <<EOF
4769 #define HAVE_STRUCT_TM_TM_ZONE 1
4774 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
4775 cat >>confdefs.h <<\EOF
4776 #define HAVE_TM_ZONE 1
4779 else
4780 echo $ac_n "checking for tzname... $ac_c" 1>&6
4781 echo "configure:4782: checking for tzname" 1>&5
4782 if test "${ac_cv_var_tzname+set}" = set; then
4783 echo $ac_n "(cached) $ac_c" 1>&6
4784 else
4785 cat >conftest.$ac_ext <<EOF
4786 #line 4787 "configure"
4787 #include "confdefs.h"
4788 #include <time.h>
4789 #ifndef tzname /* For SGI. */
4790 extern char *tzname[]; /* RS6000 and others reject char **tzname. */
4791 #endif
4794 main()
4796 atoi(*tzname);
4798 return 0;
4801 if { (eval echo configure:4802: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4802 rm -rf conftest*
4803 ac_cv_var_tzname=yes
4804 else
4805 echo "configure: failed program was:" >&5
4806 cat conftest.$ac_ext >&5
4807 rm -rf conftest*
4808 ac_cv_var_tzname=no
4810 rm -f conftest*
4813 echo "$ac_t""$ac_cv_var_tzname" 1>&6
4814 if test $ac_cv_var_tzname = yes; then
4815 cat >>confdefs.h <<\EOF
4816 #define HAVE_TZNAME 1
4822 echo $ac_n "checking for strftime... $ac_c" 1>&6
4823 echo "configure:4824: checking for strftime" 1>&5
4824 if test "${ac_cv_func_strftime+set}" = set; then
4825 echo $ac_n "(cached) $ac_c" 1>&6
4826 else
4827 cat >conftest.$ac_ext <<EOF
4828 #line 4829 "configure"
4829 #include "confdefs.h"
4830 /* System header to define __stub macros and hopefully few prototypes,
4831 which can conflict with char strftime(); below. */
4832 #include <assert.h>
4833 /* Override any gcc2 internal prototype to avoid an error. */
4834 /* We use char because int might match the return type of a gcc2
4835 builtin and then its argument prototype would still apply. */
4836 char strftime();
4837 char (*f)();
4840 main()
4843 /* The GNU C library defines this for functions which it implements
4844 to always fail with ENOSYS. Some functions are actually named
4845 something starting with __ and the normal name is an alias. */
4846 #if defined (__stub_strftime) || defined (__stub___strftime)
4847 choke me
4848 #else
4849 f = strftime;
4850 #endif
4853 return 0;
4856 if { (eval echo configure:4857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4857 rm -rf conftest*
4858 ac_cv_func_strftime=yes
4859 else
4860 echo "configure: failed program was:" >&5
4861 cat conftest.$ac_ext >&5
4862 rm -rf conftest*
4863 ac_cv_func_strftime=no
4865 rm -f conftest*
4868 echo "$ac_t""$ac_cv_func_strftime" 1>&6
4869 if test $ac_cv_func_strftime = yes; then
4870 cat >>confdefs.h <<\EOF
4871 #define HAVE_STRFTIME 1
4874 else
4875 # strftime is in -lintl on SCO UNIX.
4876 echo $ac_n "checking for strftime in -lintl... $ac_c" 1>&6
4877 echo "configure:4878: checking for strftime in -lintl" 1>&5
4878 if test "${ac_cv_lib_intl_strftime+set}" = set; then
4879 echo $ac_n "(cached) $ac_c" 1>&6
4880 else
4881 ac_save_LIBS="$LIBS"
4882 LIBS="-lintl $LIBS"
4883 cat >conftest.$ac_ext <<EOF
4884 #line 4885 "configure"
4885 #include "confdefs.h"
4886 /* Override any gcc2 internal prototype to avoid an error. */
4887 /* We use char because int might match the return type of a gcc2
4888 builtin and then its argument prototype would still apply. */
4889 char strftime();
4892 main()
4894 strftime()
4896 return 0;
4899 if { (eval echo configure:4900: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4900 rm -rf conftest*
4901 ac_cv_lib_intl_strftime=yes
4902 else
4903 echo "configure: failed program was:" >&5
4904 cat conftest.$ac_ext >&5
4905 rm -rf conftest*
4906 ac_cv_lib_intl_strftime=no
4908 rm -f conftest*
4910 LIBS="$ac_save_LIBS"
4912 echo "$ac_t""$ac_cv_lib_intl_strftime" 1>&6
4913 if test $ac_cv_lib_intl_strftime = yes; then
4914 cat >>confdefs.h <<\EOF
4915 #define HAVE_STRFTIME 1
4918 LIBS="-lintl $LIBS"
4923 for ac_func in memcmp memset stpcpy strdup strftime strspn strstr \
4924 strtol strtoul
4926 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
4927 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
4928 echo "configure:4929: checking for $ac_func" 1>&5
4929 if eval "test \"\${$ac_ac_var+set}\" = set"; then
4930 echo $ac_n "(cached) $ac_c" 1>&6
4931 else
4932 cat >conftest.$ac_ext <<EOF
4933 #line 4934 "configure"
4934 #include "confdefs.h"
4935 /* System header to define __stub macros and hopefully few prototypes,
4936 which can conflict with char $ac_func(); below. */
4937 #include <assert.h>
4938 /* Override any gcc2 internal prototype to avoid an error. */
4939 /* We use char because int might match the return type of a gcc2
4940 builtin and then its argument prototype would still apply. */
4941 char $ac_func();
4942 char (*f)();
4945 main()
4948 /* The GNU C library defines this for functions which it implements
4949 to always fail with ENOSYS. Some functions are actually named
4950 something starting with __ and the normal name is an alias. */
4951 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4952 choke me
4953 #else
4954 f = $ac_func;
4955 #endif
4958 return 0;
4961 if { (eval echo configure:4962: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4962 rm -rf conftest*
4963 eval "$ac_ac_var=yes"
4964 else
4965 echo "configure: failed program was:" >&5
4966 cat conftest.$ac_ext >&5
4967 rm -rf conftest*
4968 eval "$ac_ac_var=no"
4970 rm -f conftest*
4973 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
4974 if test `eval echo '${'$ac_ac_var'}'` = yes; then
4975 cat >>confdefs.h <<EOF
4976 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
4979 else
4980 LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
4982 done
4984 echo $ac_n "checking for working memcmp... $ac_c" 1>&6
4985 echo "configure:4986: checking for working memcmp" 1>&5
4986 if test "${jm_cv_func_memcmp_working+set}" = set; then
4987 echo $ac_n "(cached) $ac_c" 1>&6
4988 else
4989 if test "$cross_compiling" = yes; then
4990 jm_cv_func_memcmp_working=no
4991 else
4992 cat >conftest.$ac_ext <<EOF
4993 #line 4994 "configure"
4994 #include "confdefs.h"
4996 main()
4998 /* Some versions of memcmp are not 8-bit clean. */
4999 char c0 = 0x40, c1 = 0x80, c2 = 0x81;
5000 if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
5001 exit (1);
5003 /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
5004 or more and with at least one buffer not starting on a 4-byte boundary.
5005 William Lewis provided this test program. */
5007 char foo[21];
5008 char bar[21];
5009 int i;
5010 for (i = 0; i < 4; i++)
5012 char *a = foo + i;
5013 char *b = bar + i;
5014 strcpy (a, "--------01111111");
5015 strcpy (b, "--------10000000");
5016 if (memcmp (a, b, 16) >= 0)
5017 exit (1);
5019 exit (0);
5024 if { (eval echo configure:5025: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
5025 then
5026 jm_cv_func_memcmp_working=yes
5027 else
5028 echo "configure: failed program was:" >&5
5029 cat conftest.$ac_ext >&5
5030 rm -fr conftest*
5031 jm_cv_func_memcmp_working=no
5033 rm -fr conftest*
5038 echo "$ac_t""$jm_cv_func_memcmp_working" 1>&6
5039 test $jm_cv_func_memcmp_working = no \
5040 && LIBOBJS="$LIBOBJS memcmp.$ac_objext"
5042 echo $ac_n "checking whether we are using the GNU C Library... $ac_c" 1>&6
5043 echo "configure:5044: checking whether we are using the GNU C Library" 1>&5
5044 if test "${ac_cv_gnu_library+set}" = set; then
5045 echo $ac_n "(cached) $ac_c" 1>&6
5046 else
5047 cat >conftest.$ac_ext <<EOF
5048 #line 5049 "configure"
5049 #include "confdefs.h"
5051 #include <features.h>
5052 #ifdef __GNU_LIBRARY__
5053 Thanks for using GNU
5054 #endif
5057 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5058 egrep "Thanks for using GNU" >/dev/null 2>&1; then
5059 rm -rf conftest*
5060 ac_cv_gnu_library=yes
5061 else
5062 rm -rf conftest*
5063 ac_cv_gnu_library=no
5065 rm -f conftest*
5068 echo "$ac_t""$ac_cv_gnu_library" 1>&6
5069 echo $ac_n "checking for version 2 of the GNU C Library... $ac_c" 1>&6
5070 echo "configure:5071: checking for version 2 of the GNU C Library" 1>&5
5071 if test "${ac_cv_glibc+set}" = set; then
5072 echo $ac_n "(cached) $ac_c" 1>&6
5073 else
5074 cat >conftest.$ac_ext <<EOF
5075 #line 5076 "configure"
5076 #include "confdefs.h"
5078 #include <features.h>
5079 #ifdef __GLIBC__
5080 Thanks for using GNU too
5081 #endif
5084 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5085 egrep "Thanks for using GNU too" >/dev/null 2>&1; then
5086 rm -rf conftest*
5087 ac_cv_glibc=yes
5088 else
5089 rm -rf conftest*
5090 ac_cv_glibc=no
5092 rm -f conftest*
5095 echo "$ac_t""$ac_cv_glibc" 1>&6
5097 echo $ac_n "checking whether to enable assertions... $ac_c" 1>&6
5098 echo "configure:5099: checking whether to enable assertions" 1>&5
5099 # Check whether --enable-assert or --disable-assert was given.
5100 if test "${enable_assert+set}" = set; then
5101 enableval="$enable_assert"
5102 echo "$ac_t""no" 1>&6
5103 cat >>confdefs.h <<\EOF
5104 #define NDEBUG 1
5107 else
5108 echo "$ac_t""yes" 1>&6
5112 for ac_header in utime.h
5114 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
5115 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
5116 echo "configure:5117: checking for $ac_header" 1>&5
5117 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
5118 echo $ac_n "(cached) $ac_c" 1>&6
5119 else
5120 cat >conftest.$ac_ext <<EOF
5121 #line 5122 "configure"
5122 #include "confdefs.h"
5123 #include <$ac_header>
5126 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5127 { (eval echo configure:5128: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5128 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5129 if test -z "$ac_err"; then
5130 rm -rf conftest*
5131 eval "$ac_ac_Header=yes"
5132 else
5133 echo "$ac_err" >&5
5134 echo "configure: failed program was:" >&5
5135 cat conftest.$ac_ext >&5
5136 rm -rf conftest*
5137 eval "$ac_ac_Header=no"
5139 rm -f conftest*
5141 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
5142 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
5143 cat >>confdefs.h <<EOF
5144 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
5148 done
5150 echo $ac_n "checking for struct utimbuf... $ac_c" 1>&6
5151 echo "configure:5152: checking for struct utimbuf" 1>&5
5152 if test "${fu_cv_sys_struct_utimbuf+set}" = set; then
5153 echo $ac_n "(cached) $ac_c" 1>&6
5154 else
5155 cat >conftest.$ac_ext <<EOF
5156 #line 5157 "configure"
5157 #include "confdefs.h"
5159 #ifdef TIME_WITH_SYS_TIME
5160 # include <sys/time.h>
5161 # include <time.h>
5162 #else
5163 # ifdef HAVE_SYS_TIME_H
5164 # include <sys/time.h>
5165 # else
5166 # include <time.h>
5167 # endif
5168 #endif
5169 #ifdef HAVE_UTIME_H
5170 # include <utime.h>
5171 #endif
5174 main ()
5176 static struct utimbuf x; x.actime = x.modtime;
5178 return 0;
5181 if { (eval echo configure:5182: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5182 rm -rf conftest*
5183 fu_cv_sys_struct_utimbuf=yes
5184 else
5185 echo "configure: failed program was:" >&5
5186 cat conftest.$ac_ext >&5
5187 rm -rf conftest*
5188 fu_cv_sys_struct_utimbuf=no
5190 rm -f conftest*
5193 echo "$ac_t""$fu_cv_sys_struct_utimbuf" 1>&6
5195 if test $fu_cv_sys_struct_utimbuf = yes; then
5196 cat >>confdefs.h <<EOF
5197 #define HAVE_STRUCT_UTIMBUF 1
5202 echo $ac_n "checking for d_type member in directory struct... $ac_c" 1>&6
5203 echo "configure:5204: checking for d_type member in directory struct" 1>&5
5204 if test "${jm_cv_struct_dirent_d_type+set}" = set; then
5205 echo $ac_n "(cached) $ac_c" 1>&6
5206 else
5207 cat >conftest.$ac_ext <<EOF
5208 #line 5209 "configure"
5209 #include "confdefs.h"
5211 #include <sys/types.h>
5212 #ifdef HAVE_DIRENT_H
5213 # include <dirent.h>
5214 #else /* not HAVE_DIRENT_H */
5215 # define dirent direct
5216 # ifdef HAVE_SYS_NDIR_H
5217 # include <sys/ndir.h>
5218 # endif /* HAVE_SYS_NDIR_H */
5219 # ifdef HAVE_SYS_DIR_H
5220 # include <sys/dir.h>
5221 # endif /* HAVE_SYS_DIR_H */
5222 # ifdef HAVE_NDIR_H
5223 # include <ndir.h>
5224 # endif /* HAVE_NDIR_H */
5225 #endif /* HAVE_DIRENT_H */
5228 main()
5230 struct dirent dp; dp.d_type = 0;
5232 return 0;
5235 if { (eval echo configure:5236: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5236 rm -rf conftest*
5237 jm_cv_struct_dirent_d_type=yes
5238 else
5239 echo "configure: failed program was:" >&5
5240 cat conftest.$ac_ext >&5
5241 rm -rf conftest*
5242 jm_cv_struct_dirent_d_type=no
5244 rm -f conftest*
5247 echo "$ac_t""$jm_cv_struct_dirent_d_type" 1>&6
5248 if test $jm_cv_struct_dirent_d_type = yes; then
5249 cat >>confdefs.h <<\EOF
5250 #define D_TYPE_IN_DIRENT 1
5255 echo $ac_n "checking for d_ino member in directory struct... $ac_c" 1>&6
5256 echo "configure:5257: checking for d_ino member in directory struct" 1>&5
5257 if test "${jm_cv_struct_dirent_d_ino+set}" = set; then
5258 echo $ac_n "(cached) $ac_c" 1>&6
5259 else
5260 cat >conftest.$ac_ext <<EOF
5261 #line 5262 "configure"
5262 #include "confdefs.h"
5264 #include <sys/types.h>
5265 #ifdef HAVE_DIRENT_H
5266 # include <dirent.h>
5267 #else /* not HAVE_DIRENT_H */
5268 # define dirent direct
5269 # ifdef HAVE_SYS_NDIR_H
5270 # include <sys/ndir.h>
5271 # endif /* HAVE_SYS_NDIR_H */
5272 # ifdef HAVE_SYS_DIR_H
5273 # include <sys/dir.h>
5274 # endif /* HAVE_SYS_DIR_H */
5275 # ifdef HAVE_NDIR_H
5276 # include <ndir.h>
5277 # endif /* HAVE_NDIR_H */
5278 #endif /* HAVE_DIRENT_H */
5281 main()
5283 struct dirent dp; dp.d_ino = 0;
5285 return 0;
5288 if { (eval echo configure:5289: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5289 rm -rf conftest*
5290 jm_cv_struct_dirent_d_ino=yes
5291 else
5292 echo "configure: failed program was:" >&5
5293 cat conftest.$ac_ext >&5
5294 rm -rf conftest*
5295 jm_cv_struct_dirent_d_ino=no
5297 rm -f conftest*
5300 echo "$ac_t""$jm_cv_struct_dirent_d_ino" 1>&6
5301 if test $jm_cv_struct_dirent_d_ino = yes; then
5302 cat >>confdefs.h <<\EOF
5303 #define D_INO_IN_DIRENT 1
5308 headers='
5309 #include <stdio.h>
5310 #ifdef HAVE_STRING_H
5311 # if !STDC_HEADERS && HAVE_MEMORY_H
5312 # include <memory.h>
5313 # endif
5314 # include <string.h>
5315 #else
5316 # ifdef HAVE_STRINGS_H
5317 # include <strings.h>
5318 # endif
5319 #endif
5320 #ifdef HAVE_STDLIB_H
5321 # include <stdlib.h>
5322 #endif
5323 #ifdef HAVE_UNISTD_H
5324 # include <unistd.h>
5325 #endif
5328 if test x = y; then
5329 cat >>confdefs.h <<\EOF
5330 #define HAVE_DECL_FREE 1
5333 cat >>confdefs.h <<\EOF
5334 #define HAVE_DECL_LSEEK 1
5337 cat >>confdefs.h <<\EOF
5338 #define HAVE_DECL_MALLOC 1
5341 cat >>confdefs.h <<\EOF
5342 #define HAVE_DECL_MEMCHR 1
5345 cat >>confdefs.h <<\EOF
5346 #define HAVE_DECL_REALLOC 1
5349 cat >>confdefs.h <<\EOF
5350 #define HAVE_DECL_STPCPY 1
5353 cat >>confdefs.h <<\EOF
5354 #define HAVE_DECL_STRSTR 1
5359 for jm_func in free lseek malloc \
5360 memchr realloc stpcpy strstr
5363 test -z "$ac_cv_header_memory_h" && for ac_header in memory.h
5365 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
5366 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
5367 echo "configure:5368: checking for $ac_header" 1>&5
5368 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
5369 echo $ac_n "(cached) $ac_c" 1>&6
5370 else
5371 cat >conftest.$ac_ext <<EOF
5372 #line 5373 "configure"
5373 #include "confdefs.h"
5374 #include <$ac_header>
5377 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5378 { (eval echo configure:5379: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5379 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5380 if test -z "$ac_err"; then
5381 rm -rf conftest*
5382 eval "$ac_ac_Header=yes"
5383 else
5384 echo "$ac_err" >&5
5385 echo "configure: failed program was:" >&5
5386 cat conftest.$ac_ext >&5
5387 rm -rf conftest*
5388 eval "$ac_ac_Header=no"
5390 rm -f conftest*
5392 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
5393 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
5394 cat >>confdefs.h <<EOF
5395 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
5399 done
5401 test -z "$ac_cv_header_string_h" && for ac_header in string.h
5403 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
5404 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
5405 echo "configure:5406: checking for $ac_header" 1>&5
5406 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
5407 echo $ac_n "(cached) $ac_c" 1>&6
5408 else
5409 cat >conftest.$ac_ext <<EOF
5410 #line 5411 "configure"
5411 #include "confdefs.h"
5412 #include <$ac_header>
5415 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5416 { (eval echo configure:5417: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5417 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5418 if test -z "$ac_err"; then
5419 rm -rf conftest*
5420 eval "$ac_ac_Header=yes"
5421 else
5422 echo "$ac_err" >&5
5423 echo "configure: failed program was:" >&5
5424 cat conftest.$ac_ext >&5
5425 rm -rf conftest*
5426 eval "$ac_ac_Header=no"
5428 rm -f conftest*
5430 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
5431 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
5432 cat >>confdefs.h <<EOF
5433 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
5437 done
5439 test -z "$ac_cv_header_strings_h" && for ac_header in strings.h
5441 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
5442 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
5443 echo "configure:5444: checking for $ac_header" 1>&5
5444 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
5445 echo $ac_n "(cached) $ac_c" 1>&6
5446 else
5447 cat >conftest.$ac_ext <<EOF
5448 #line 5449 "configure"
5449 #include "confdefs.h"
5450 #include <$ac_header>
5453 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5454 { (eval echo configure:5455: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5455 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5456 if test -z "$ac_err"; then
5457 rm -rf conftest*
5458 eval "$ac_ac_Header=yes"
5459 else
5460 echo "$ac_err" >&5
5461 echo "configure: failed program was:" >&5
5462 cat conftest.$ac_ext >&5
5463 rm -rf conftest*
5464 eval "$ac_ac_Header=no"
5466 rm -f conftest*
5468 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
5469 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
5470 cat >>confdefs.h <<EOF
5471 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
5475 done
5477 test -z "$ac_cv_header_stdlib_h" && for ac_header in stdlib.h
5479 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
5480 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
5481 echo "configure:5482: checking for $ac_header" 1>&5
5482 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
5483 echo $ac_n "(cached) $ac_c" 1>&6
5484 else
5485 cat >conftest.$ac_ext <<EOF
5486 #line 5487 "configure"
5487 #include "confdefs.h"
5488 #include <$ac_header>
5491 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5492 { (eval echo configure:5493: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5493 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5494 if test -z "$ac_err"; then
5495 rm -rf conftest*
5496 eval "$ac_ac_Header=yes"
5497 else
5498 echo "$ac_err" >&5
5499 echo "configure: failed program was:" >&5
5500 cat conftest.$ac_ext >&5
5501 rm -rf conftest*
5502 eval "$ac_ac_Header=no"
5504 rm -f conftest*
5506 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
5507 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
5508 cat >>confdefs.h <<EOF
5509 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
5513 done
5515 test -z "$ac_cv_header_unistd_h" && for ac_header in unistd.h
5517 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
5518 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
5519 echo "configure:5520: checking for $ac_header" 1>&5
5520 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
5521 echo $ac_n "(cached) $ac_c" 1>&6
5522 else
5523 cat >conftest.$ac_ext <<EOF
5524 #line 5525 "configure"
5525 #include "confdefs.h"
5526 #include <$ac_header>
5529 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5530 { (eval echo configure:5531: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5531 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5532 if test -z "$ac_err"; then
5533 rm -rf conftest*
5534 eval "$ac_ac_Header=yes"
5535 else
5536 echo "$ac_err" >&5
5537 echo "configure: failed program was:" >&5
5538 cat conftest.$ac_ext >&5
5539 rm -rf conftest*
5540 eval "$ac_ac_Header=no"
5542 rm -f conftest*
5544 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
5545 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
5546 cat >>confdefs.h <<EOF
5547 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
5551 done
5553 echo $ac_n "checking whether $jm_func is declared... $ac_c" 1>&6
5554 echo "configure:5555: checking whether $jm_func is declared" 1>&5
5555 if eval "test \"\${jm_cv_func_decl_$jm_func+set}\" = set"; then
5556 echo $ac_n "(cached) $ac_c" 1>&6
5557 else
5558 cat >conftest.$ac_ext <<EOF
5559 #line 5560 "configure"
5560 #include "confdefs.h"
5561 $headers
5563 main ()
5566 #ifndef $jm_func
5567 char *(*pfn) = (char *(*)) $jm_func
5568 #endif
5571 return 0;
5574 if { (eval echo configure:5575: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5575 rm -rf conftest*
5576 eval "jm_cv_func_decl_$jm_func=yes"
5577 else
5578 echo "configure: failed program was:" >&5
5579 cat conftest.$ac_ext >&5
5580 rm -rf conftest*
5581 eval "jm_cv_func_decl_$jm_func=no"
5583 rm -f conftest*
5586 if eval "test \"`echo '$jm_cv_func_decl_'$jm_func`\" = yes"; then
5587 echo "$ac_t""yes" 1>&6
5589 jm_tr_func=HAVE_DECL_`echo $jm_func | tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ`
5590 cat >>confdefs.h <<EOF
5591 #define $jm_tr_func 1
5594 else
5595 echo "$ac_t""no" 1>&6
5597 done
5599 for ac_func in strerror strerror_r vprintf doprnt
5601 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
5602 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
5603 echo "configure:5604: checking for $ac_func" 1>&5
5604 if eval "test \"\${$ac_ac_var+set}\" = set"; then
5605 echo $ac_n "(cached) $ac_c" 1>&6
5606 else
5607 cat >conftest.$ac_ext <<EOF
5608 #line 5609 "configure"
5609 #include "confdefs.h"
5610 /* System header to define __stub macros and hopefully few prototypes,
5611 which can conflict with char $ac_func(); below. */
5612 #include <assert.h>
5613 /* Override any gcc2 internal prototype to avoid an error. */
5614 /* We use char because int might match the return type of a gcc2
5615 builtin and then its argument prototype would still apply. */
5616 char $ac_func();
5617 char (*f)();
5620 main()
5623 /* The GNU C library defines this for functions which it implements
5624 to always fail with ENOSYS. Some functions are actually named
5625 something starting with __ and the normal name is an alias. */
5626 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5627 choke me
5628 #else
5629 f = $ac_func;
5630 #endif
5633 return 0;
5636 if { (eval echo configure:5637: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5637 rm -rf conftest*
5638 eval "$ac_ac_var=yes"
5639 else
5640 echo "configure: failed program was:" >&5
5641 cat conftest.$ac_ext >&5
5642 rm -rf conftest*
5643 eval "$ac_ac_var=no"
5645 rm -f conftest*
5648 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
5649 if test `eval echo '${'$ac_ac_var'}'` = yes; then
5650 cat >>confdefs.h <<EOF
5651 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
5655 done
5657 echo $ac_n "checking for ANSI C header files... $ac_c" 1>&6
5658 echo "configure:5659: checking for ANSI C header files" 1>&5
5659 if test "${ac_cv_header_stdc+set}" = set; then
5660 echo $ac_n "(cached) $ac_c" 1>&6
5661 else
5662 cat >conftest.$ac_ext <<EOF
5663 #line 5664 "configure"
5664 #include "confdefs.h"
5665 #include <stdlib.h>
5666 #include <stdarg.h>
5667 #include <string.h>
5668 #include <float.h>
5671 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5672 { (eval echo configure:5673: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5673 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5674 if test -z "$ac_err"; then
5675 rm -rf conftest*
5676 ac_cv_header_stdc=yes
5677 else
5678 echo "$ac_err" >&5
5679 echo "configure: failed program was:" >&5
5680 cat conftest.$ac_ext >&5
5681 rm -rf conftest*
5682 ac_cv_header_stdc=no
5684 rm -f conftest*
5686 if test $ac_cv_header_stdc = yes; then
5687 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5688 cat >conftest.$ac_ext <<EOF
5689 #line 5690 "configure"
5690 #include "confdefs.h"
5691 #include <string.h>
5694 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5695 egrep "memchr" >/dev/null 2>&1; then
5697 else
5698 rm -rf conftest*
5699 ac_cv_header_stdc=no
5701 rm -f conftest*
5705 if test $ac_cv_header_stdc = yes; then
5706 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5707 cat >conftest.$ac_ext <<EOF
5708 #line 5709 "configure"
5709 #include "confdefs.h"
5710 #include <stdlib.h>
5713 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5714 egrep "free" >/dev/null 2>&1; then
5716 else
5717 rm -rf conftest*
5718 ac_cv_header_stdc=no
5720 rm -f conftest*
5724 if test $ac_cv_header_stdc = yes; then
5725 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5726 if test "$cross_compiling" = yes; then
5728 else
5729 cat >conftest.$ac_ext <<EOF
5730 #line 5731 "configure"
5731 #include "confdefs.h"
5732 #include <ctype.h>
5733 #if ((' ' & 0x0FF) == 0x020)
5734 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5735 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5736 #else
5737 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
5738 || ('j' <= (c) && (c) <= 'r') \
5739 || ('s' <= (c) && (c) <= 'z'))
5740 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5741 #endif
5743 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5745 main ()
5747 int i;
5748 for (i = 0; i < 256; i++)
5749 if (XOR (islower (i), ISLOWER (i))
5750 || toupper (i) != TOUPPER (i))
5751 exit(2);
5752 exit (0);
5755 if { (eval echo configure:5756: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
5756 then
5758 else
5759 echo "configure: failed program was:" >&5
5760 cat conftest.$ac_ext >&5
5761 rm -fr conftest*
5762 ac_cv_header_stdc=no
5764 rm -fr conftest*
5770 echo "$ac_t""$ac_cv_header_stdc" 1>&6
5771 if test $ac_cv_header_stdc = yes; then
5772 cat >>confdefs.h <<\EOF
5773 #define STDC_HEADERS 1
5778 for ac_func in bzero bcopy isascii btowc
5780 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
5781 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
5782 echo "configure:5783: checking for $ac_func" 1>&5
5783 if eval "test \"\${$ac_ac_var+set}\" = set"; then
5784 echo $ac_n "(cached) $ac_c" 1>&6
5785 else
5786 cat >conftest.$ac_ext <<EOF
5787 #line 5788 "configure"
5788 #include "confdefs.h"
5789 /* System header to define __stub macros and hopefully few prototypes,
5790 which can conflict with char $ac_func(); below. */
5791 #include <assert.h>
5792 /* Override any gcc2 internal prototype to avoid an error. */
5793 /* We use char because int might match the return type of a gcc2
5794 builtin and then its argument prototype would still apply. */
5795 char $ac_func();
5796 char (*f)();
5799 main()
5802 /* The GNU C library defines this for functions which it implements
5803 to always fail with ENOSYS. Some functions are actually named
5804 something starting with __ and the normal name is an alias. */
5805 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5806 choke me
5807 #else
5808 f = $ac_func;
5809 #endif
5812 return 0;
5815 if { (eval echo configure:5816: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5816 rm -rf conftest*
5817 eval "$ac_ac_var=yes"
5818 else
5819 echo "configure: failed program was:" >&5
5820 cat conftest.$ac_ext >&5
5821 rm -rf conftest*
5822 eval "$ac_ac_var=no"
5824 rm -f conftest*
5827 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
5828 if test `eval echo '${'$ac_ac_var'}'` = yes; then
5829 cat >>confdefs.h <<EOF
5830 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
5834 done
5836 for ac_header in alloca.h libintl.h wctype.h wchar.h
5838 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
5839 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
5840 echo "configure:5841: checking for $ac_header" 1>&5
5841 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
5842 echo $ac_n "(cached) $ac_c" 1>&6
5843 else
5844 cat >conftest.$ac_ext <<EOF
5845 #line 5846 "configure"
5846 #include "confdefs.h"
5847 #include <$ac_header>
5850 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5851 { (eval echo configure:5852: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5852 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5853 if test -z "$ac_err"; then
5854 rm -rf conftest*
5855 eval "$ac_ac_Header=yes"
5856 else
5857 echo "$ac_err" >&5
5858 echo "configure: failed program was:" >&5
5859 cat conftest.$ac_ext >&5
5860 rm -rf conftest*
5861 eval "$ac_ac_Header=no"
5863 rm -f conftest*
5865 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
5866 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
5867 cat >>confdefs.h <<EOF
5868 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
5872 done
5874 echo $ac_n "checking for ANSI C header files... $ac_c" 1>&6
5875 echo "configure:5876: checking for ANSI C header files" 1>&5
5876 if test "${ac_cv_header_stdc+set}" = set; then
5877 echo $ac_n "(cached) $ac_c" 1>&6
5878 else
5879 cat >conftest.$ac_ext <<EOF
5880 #line 5881 "configure"
5881 #include "confdefs.h"
5882 #include <stdlib.h>
5883 #include <stdarg.h>
5884 #include <string.h>
5885 #include <float.h>
5888 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5889 { (eval echo configure:5890: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5890 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5891 if test -z "$ac_err"; then
5892 rm -rf conftest*
5893 ac_cv_header_stdc=yes
5894 else
5895 echo "$ac_err" >&5
5896 echo "configure: failed program was:" >&5
5897 cat conftest.$ac_ext >&5
5898 rm -rf conftest*
5899 ac_cv_header_stdc=no
5901 rm -f conftest*
5903 if test $ac_cv_header_stdc = yes; then
5904 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5905 cat >conftest.$ac_ext <<EOF
5906 #line 5907 "configure"
5907 #include "confdefs.h"
5908 #include <string.h>
5911 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5912 egrep "memchr" >/dev/null 2>&1; then
5914 else
5915 rm -rf conftest*
5916 ac_cv_header_stdc=no
5918 rm -f conftest*
5922 if test $ac_cv_header_stdc = yes; then
5923 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5924 cat >conftest.$ac_ext <<EOF
5925 #line 5926 "configure"
5926 #include "confdefs.h"
5927 #include <stdlib.h>
5930 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5931 egrep "free" >/dev/null 2>&1; then
5933 else
5934 rm -rf conftest*
5935 ac_cv_header_stdc=no
5937 rm -f conftest*
5941 if test $ac_cv_header_stdc = yes; then
5942 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5943 if test "$cross_compiling" = yes; then
5945 else
5946 cat >conftest.$ac_ext <<EOF
5947 #line 5948 "configure"
5948 #include "confdefs.h"
5949 #include <ctype.h>
5950 #if ((' ' & 0x0FF) == 0x020)
5951 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5952 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5953 #else
5954 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
5955 || ('j' <= (c) && (c) <= 'r') \
5956 || ('s' <= (c) && (c) <= 'z'))
5957 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5958 #endif
5960 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5962 main ()
5964 int i;
5965 for (i = 0; i < 256; i++)
5966 if (XOR (islower (i), ISLOWER (i))
5967 || toupper (i) != TOUPPER (i))
5968 exit(2);
5969 exit (0);
5972 if { (eval echo configure:5973: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
5973 then
5975 else
5976 echo "configure: failed program was:" >&5
5977 cat conftest.$ac_ext >&5
5978 rm -fr conftest*
5979 ac_cv_header_stdc=no
5981 rm -fr conftest*
5987 echo "$ac_t""$ac_cv_header_stdc" 1>&6
5988 if test $ac_cv_header_stdc = yes; then
5989 cat >>confdefs.h <<\EOF
5990 #define STDC_HEADERS 1
5995 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
5996 # for constant arguments. Useless!
5997 echo $ac_n "checking for working alloca.h... $ac_c" 1>&6
5998 echo "configure:5999: checking for working alloca.h" 1>&5
5999 if test "${ac_cv_working_alloca_h+set}" = set; then
6000 echo $ac_n "(cached) $ac_c" 1>&6
6001 else
6002 cat >conftest.$ac_ext <<EOF
6003 #line 6004 "configure"
6004 #include "confdefs.h"
6005 #include <alloca.h>
6007 main()
6009 char *p = alloca(2 * sizeof(int));
6011 return 0;
6014 if { (eval echo configure:6015: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6015 rm -rf conftest*
6016 ac_cv_working_alloca_h=yes
6017 else
6018 echo "configure: failed program was:" >&5
6019 cat conftest.$ac_ext >&5
6020 rm -rf conftest*
6021 ac_cv_working_alloca_h=no
6023 rm -f conftest*
6026 echo "$ac_t""$ac_cv_working_alloca_h" 1>&6
6027 if test $ac_cv_working_alloca_h = yes; then
6028 cat >>confdefs.h <<\EOF
6029 #define HAVE_ALLOCA_H 1
6034 echo $ac_n "checking for alloca... $ac_c" 1>&6
6035 echo "configure:6036: checking for alloca" 1>&5
6036 if test "${ac_cv_func_alloca_works+set}" = set; then
6037 echo $ac_n "(cached) $ac_c" 1>&6
6038 else
6039 cat >conftest.$ac_ext <<EOF
6040 #line 6041 "configure"
6041 #include "confdefs.h"
6042 #ifdef __GNUC__
6043 # define alloca __builtin_alloca
6044 #else
6045 # ifdef _MSC_VER
6046 # include <malloc.h>
6047 # define alloca _alloca
6048 # else
6049 # if HAVE_ALLOCA_H
6050 # include <alloca.h>
6051 # else
6052 # ifdef _AIX
6053 #pragma alloca
6054 # else
6055 # ifndef alloca /* predefined by HP cc +Olibcalls */
6056 char *alloca ();
6057 # endif
6058 # endif
6059 # endif
6060 # endif
6061 #endif
6064 main()
6066 char *p = (char *) alloca(1);
6068 return 0;
6071 if { (eval echo configure:6072: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6072 rm -rf conftest*
6073 ac_cv_func_alloca_works=yes
6074 else
6075 echo "configure: failed program was:" >&5
6076 cat conftest.$ac_ext >&5
6077 rm -rf conftest*
6078 ac_cv_func_alloca_works=no
6080 rm -f conftest*
6083 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
6084 if test $ac_cv_func_alloca_works = yes; then
6085 cat >>confdefs.h <<\EOF
6086 #define HAVE_ALLOCA 1
6091 if test $ac_cv_func_alloca_works = no; then
6092 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
6093 # that cause trouble. Some versions do not even contain alloca or
6094 # contain a buggy version. If you still want to use their alloca,
6095 # use ar to extract alloca.o from them instead of compiling alloca.c.
6096 ALLOCA=alloca.${ac_objext}
6097 cat >>confdefs.h <<\EOF
6098 #define C_ALLOCA 1
6101 echo $ac_n "checking whether alloca needs Cray hooks... $ac_c" 1>&6
6102 echo "configure:6103: checking whether alloca needs Cray hooks" 1>&5
6103 if test "${ac_cv_os_cray+set}" = set; then
6104 echo $ac_n "(cached) $ac_c" 1>&6
6105 else
6106 cat >conftest.$ac_ext <<EOF
6107 #line 6108 "configure"
6108 #include "confdefs.h"
6109 #if defined(CRAY) && ! defined(CRAY2)
6110 webecray
6111 #else
6112 wenotbecray
6113 #endif
6116 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6117 egrep "webecray" >/dev/null 2>&1; then
6118 rm -rf conftest*
6119 ac_cv_os_cray=yes
6120 else
6121 rm -rf conftest*
6122 ac_cv_os_cray=no
6124 rm -f conftest*
6127 echo "$ac_t""$ac_cv_os_cray" 1>&6
6128 if test $ac_cv_os_cray = yes; then
6129 for ac_func in _getb67 GETB67 getb67; do
6130 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
6131 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
6132 echo "configure:6133: checking for $ac_func" 1>&5
6133 if eval "test \"\${$ac_ac_var+set}\" = set"; then
6134 echo $ac_n "(cached) $ac_c" 1>&6
6135 else
6136 cat >conftest.$ac_ext <<EOF
6137 #line 6138 "configure"
6138 #include "confdefs.h"
6139 /* System header to define __stub macros and hopefully few prototypes,
6140 which can conflict with char $ac_func(); below. */
6141 #include <assert.h>
6142 /* Override any gcc2 internal prototype to avoid an error. */
6143 /* We use char because int might match the return type of a gcc2
6144 builtin and then its argument prototype would still apply. */
6145 char $ac_func();
6146 char (*f)();
6149 main()
6152 /* The GNU C library defines this for functions which it implements
6153 to always fail with ENOSYS. Some functions are actually named
6154 something starting with __ and the normal name is an alias. */
6155 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6156 choke me
6157 #else
6158 f = $ac_func;
6159 #endif
6162 return 0;
6165 if { (eval echo configure:6166: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6166 rm -rf conftest*
6167 eval "$ac_ac_var=yes"
6168 else
6169 echo "configure: failed program was:" >&5
6170 cat conftest.$ac_ext >&5
6171 rm -rf conftest*
6172 eval "$ac_ac_var=no"
6174 rm -f conftest*
6177 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
6178 if test `eval echo '${'$ac_ac_var'}'` = yes; then
6179 cat >>confdefs.h <<EOF
6180 #define CRAY_STACKSEG_END $ac_func
6183 break
6186 done
6189 echo $ac_n "checking stack direction for C alloca... $ac_c" 1>&6
6190 echo "configure:6191: checking stack direction for C alloca" 1>&5
6191 if test "${ac_cv_c_stack_direction+set}" = set; then
6192 echo $ac_n "(cached) $ac_c" 1>&6
6193 else
6194 if test "$cross_compiling" = yes; then
6195 ac_cv_c_stack_direction=0
6196 else
6197 cat >conftest.$ac_ext <<EOF
6198 #line 6199 "configure"
6199 #include "confdefs.h"
6200 find_stack_direction ()
6202 static char *addr = 0;
6203 auto char dummy;
6204 if (addr == 0)
6206 addr = &dummy;
6207 return find_stack_direction ();
6209 else
6210 return (&dummy > addr) ? 1 : -1;
6214 main ()
6216 exit (find_stack_direction () < 0);
6219 if { (eval echo configure:6220: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6220 then
6221 ac_cv_c_stack_direction=1
6222 else
6223 echo "configure: failed program was:" >&5
6224 cat conftest.$ac_ext >&5
6225 rm -fr conftest*
6226 ac_cv_c_stack_direction=-1
6228 rm -fr conftest*
6233 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
6234 cat >>confdefs.h <<EOF
6235 #define STACK_DIRECTION $ac_cv_c_stack_direction
6240 echo $ac_n "checking whether lstat accepts an empty string... $ac_c" 1>&6
6241 echo "configure:6242: checking whether lstat accepts an empty string" 1>&5
6242 if test "${jm_cv_func_lstat_empty_string_bug+set}" = set; then
6243 echo $ac_n "(cached) $ac_c" 1>&6
6244 else
6245 if test "$cross_compiling" = yes; then
6246 jm_cv_func_lstat_empty_string_bug=yes
6247 else
6248 cat >conftest.$ac_ext <<EOF
6249 #line 6250 "configure"
6250 #include "confdefs.h"
6252 # include <sys/types.h>
6253 # include <sys/stat.h>
6256 main ()
6258 struct stat sbuf;
6259 exit (lstat ("", &sbuf) ? 1 : 0);
6263 if { (eval echo configure:6264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6264 then
6265 jm_cv_func_lstat_empty_string_bug=yes
6266 else
6267 echo "configure: failed program was:" >&5
6268 cat conftest.$ac_ext >&5
6269 rm -fr conftest*
6270 jm_cv_func_lstat_empty_string_bug=no
6272 rm -fr conftest*
6277 echo "$ac_t""$jm_cv_func_lstat_empty_string_bug" 1>&6
6278 if test $jm_cv_func_lstat_empty_string_bug = yes; then
6280 LIBOBJS="$LIBOBJS lstat.$ac_objext"
6281 cat >>confdefs.h <<EOF
6282 #define HAVE_LSTAT_EMPTY_STRING_BUG 1
6287 echo $ac_n "checking whether lstat dereferences a symlink specified with a trailing slash... $ac_c" 1>&6
6288 echo "configure:6289: checking whether lstat dereferences a symlink specified with a trailing slash" 1>&5
6289 if test "${jm_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then
6290 echo $ac_n "(cached) $ac_c" 1>&6
6291 else
6293 rm -f conftest.sym conftest.file
6294 : > conftest.file
6295 if ln -s conftest.file conftest.sym; then
6296 if test "$cross_compiling" = yes; then
6297 jm_cv_func_lstat_dereferences_slashed_symlink=no
6299 else
6300 cat >conftest.$ac_ext <<EOF
6301 #line 6302 "configure"
6302 #include "confdefs.h"
6304 # include <sys/types.h>
6305 # include <sys/stat.h>
6308 main ()
6310 struct stat sbuf;
6311 /* Linux will dereference the symlink and fail.
6312 That is better in the sense that it means we will not
6313 have to compile and use the lstat wrapper. */
6314 exit (lstat ("conftest.sym/", &sbuf) ? 0 : 1);
6318 if { (eval echo configure:6319: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6319 then
6320 jm_cv_func_lstat_dereferences_slashed_symlink=yes
6321 else
6322 echo "configure: failed program was:" >&5
6323 cat conftest.$ac_ext >&5
6324 rm -fr conftest*
6325 jm_cv_func_lstat_dereferences_slashed_symlink=no
6327 rm -fr conftest*
6331 else
6332 # If the `ln -s' command failed, then we probably don't even
6333 # have an lstat function.
6334 jm_cv_func_lstat_dereferences_slashed_symlink=no
6338 echo "$ac_t""$jm_cv_func_lstat_dereferences_slashed_symlink" 1>&6
6340 test $jm_cv_func_lstat_dereferences_slashed_symlink = yes \
6341 && zero_one=1 \
6342 || zero_one=0
6343 cat >>confdefs.h <<EOF
6344 #define LSTAT_FOLLOWS_SLASHED_SYMLINK $zero_one
6347 if test $jm_cv_func_lstat_dereferences_slashed_symlink = no; then
6349 # Append lstat.o if it's not already in $LIBOBJS.
6350 case "$LIBOBJS" in
6351 *lstat.$ac_objext*) ;;
6352 *) LIBOBJS="$LIBOBJS lstat.$ac_objext" ;;
6353 esac
6356 echo $ac_n "checking whether stat accepts an empty string... $ac_c" 1>&6
6357 echo "configure:6358: checking whether stat accepts an empty string" 1>&5
6358 if test "${jm_cv_func_stat_empty_string_bug+set}" = set; then
6359 echo $ac_n "(cached) $ac_c" 1>&6
6360 else
6361 if test "$cross_compiling" = yes; then
6362 jm_cv_func_stat_empty_string_bug=yes
6363 else
6364 cat >conftest.$ac_ext <<EOF
6365 #line 6366 "configure"
6366 #include "confdefs.h"
6368 # include <sys/types.h>
6369 # include <sys/stat.h>
6372 main ()
6374 struct stat sbuf;
6375 exit (stat ("", &sbuf) ? 1 : 0);
6379 if { (eval echo configure:6380: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6380 then
6381 jm_cv_func_stat_empty_string_bug=yes
6382 else
6383 echo "configure: failed program was:" >&5
6384 cat conftest.$ac_ext >&5
6385 rm -fr conftest*
6386 jm_cv_func_stat_empty_string_bug=no
6388 rm -fr conftest*
6393 echo "$ac_t""$jm_cv_func_stat_empty_string_bug" 1>&6
6394 if test $jm_cv_func_stat_empty_string_bug = yes; then
6396 LIBOBJS="$LIBOBJS stat.$ac_objext"
6397 cat >>confdefs.h <<EOF
6398 #define HAVE_STAT_EMPTY_STRING_BUG 1
6403 cat >>confdefs.h <<EOF
6404 #define HAVE_DONE_WORKING_REALLOC_CHECK 1
6407 echo $ac_n "checking for working realloc... $ac_c" 1>&6
6408 echo "configure:6409: checking for working realloc" 1>&5
6409 if test "${jm_cv_func_working_realloc+set}" = set; then
6410 echo $ac_n "(cached) $ac_c" 1>&6
6411 else
6412 if test "$cross_compiling" = yes; then
6413 jm_cv_func_working_realloc=no
6414 else
6415 cat >conftest.$ac_ext <<EOF
6416 #line 6417 "configure"
6417 #include "confdefs.h"
6419 char *realloc ();
6421 main ()
6423 exit (realloc (0, 0) ? 0 : 1);
6427 if { (eval echo configure:6428: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6428 then
6429 jm_cv_func_working_realloc=yes
6430 else
6431 echo "configure: failed program was:" >&5
6432 cat conftest.$ac_ext >&5
6433 rm -fr conftest*
6434 jm_cv_func_working_realloc=no
6436 rm -fr conftest*
6441 echo "$ac_t""$jm_cv_func_working_realloc" 1>&6
6442 if test $jm_cv_func_working_realloc = no; then
6444 LIBOBJS="$LIBOBJS realloc.$ac_objext"
6445 cat >>confdefs.h <<EOF
6446 #define realloc rpl_realloc
6451 cat >>confdefs.h <<EOF
6452 #define HAVE_DONE_WORKING_MALLOC_CHECK 1
6455 echo $ac_n "checking for working malloc... $ac_c" 1>&6
6456 echo "configure:6457: checking for working malloc" 1>&5
6457 if test "${jm_cv_func_working_malloc+set}" = set; then
6458 echo $ac_n "(cached) $ac_c" 1>&6
6459 else
6460 if test "$cross_compiling" = yes; then
6461 jm_cv_func_working_malloc=no
6462 else
6463 cat >conftest.$ac_ext <<EOF
6464 #line 6465 "configure"
6465 #include "confdefs.h"
6467 char *malloc ();
6469 main ()
6471 exit (malloc (0) ? 0 : 1);
6475 if { (eval echo configure:6476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6476 then
6477 jm_cv_func_working_malloc=yes
6478 else
6479 echo "configure: failed program was:" >&5
6480 cat conftest.$ac_ext >&5
6481 rm -fr conftest*
6482 jm_cv_func_working_malloc=no
6484 rm -fr conftest*
6489 echo "$ac_t""$jm_cv_func_working_malloc" 1>&6
6490 if test $jm_cv_func_working_malloc = no; then
6492 LIBOBJS="$LIBOBJS malloc.$ac_objext"
6493 cat >>confdefs.h <<EOF
6494 #define malloc rpl_malloc
6499 for ac_header in string.h
6501 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
6502 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
6503 echo "configure:6504: checking for $ac_header" 1>&5
6504 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
6505 echo $ac_n "(cached) $ac_c" 1>&6
6506 else
6507 cat >conftest.$ac_ext <<EOF
6508 #line 6509 "configure"
6509 #include "confdefs.h"
6510 #include <$ac_header>
6513 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6514 { (eval echo configure:6515: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6515 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6516 if test -z "$ac_err"; then
6517 rm -rf conftest*
6518 eval "$ac_ac_Header=yes"
6519 else
6520 echo "$ac_err" >&5
6521 echo "configure: failed program was:" >&5
6522 cat conftest.$ac_ext >&5
6523 rm -rf conftest*
6524 eval "$ac_ac_Header=no"
6526 rm -f conftest*
6528 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
6529 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
6530 cat >>confdefs.h <<EOF
6531 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
6535 done
6537 echo $ac_n "checking for working readdir... $ac_c" 1>&6
6538 echo "configure:6539: checking for working readdir" 1>&5
6539 if test "${jm_cv_func_working_readdir+set}" = set; then
6540 echo $ac_n "(cached) $ac_c" 1>&6
6541 else
6542 # Arrange for deletion of the temporary directory this test creates, in
6543 # case the test itself fails to delete everything -- as happens on Sunos.
6544 ac_clean_files="$ac_clean_files conf-dir"
6546 if test "$cross_compiling" = yes; then
6547 jm_cv_func_working_readdir=no
6548 else
6549 cat >conftest.$ac_ext <<EOF
6550 #line 6551 "configure"
6551 #include "confdefs.h"
6553 # include <stdio.h>
6554 # include <sys/types.h>
6555 # if HAVE_STRING_H
6556 # include <string.h>
6557 # endif
6559 # ifdef HAVE_DIRENT_H
6560 # include <dirent.h>
6561 # define NLENGTH(direct) (strlen((direct)->d_name))
6562 # else /* not HAVE_DIRENT_H */
6563 # define dirent direct
6564 # define NLENGTH(direct) ((direct)->d_namlen)
6565 # ifdef HAVE_SYS_NDIR_H
6566 # include <sys/ndir.h>
6567 # endif /* HAVE_SYS_NDIR_H */
6568 # ifdef HAVE_SYS_DIR_H
6569 # include <sys/dir.h>
6570 # endif /* HAVE_SYS_DIR_H */
6571 # ifdef HAVE_NDIR_H
6572 # include <ndir.h>
6573 # endif /* HAVE_NDIR_H */
6574 # endif /* HAVE_DIRENT_H */
6576 # define DOT_OR_DOTDOT(Basename) \
6577 (Basename[0] == '.' && (Basename[1] == '\0' \
6578 || (Basename[1] == '.' && Basename[2] == '\0')))
6580 static void
6581 create_300_file_dir (const char *dir)
6583 int i;
6585 if (mkdir (dir, 0700))
6586 abort ();
6587 if (chdir (dir))
6588 abort ();
6590 for (i = 0; i < 300; i++)
6592 char file_name[4];
6593 FILE *out;
6595 sprintf (file_name, "%03d", i);
6596 out = fopen (file_name, "w");
6597 if (!out)
6598 abort ();
6599 if (fclose (out) == EOF)
6600 abort ();
6603 if (chdir (".."))
6604 abort ();
6607 static void
6608 remove_dir (const char *dir)
6610 DIR *dirp;
6612 if (chdir (dir))
6613 abort ();
6615 dirp = opendir (".");
6616 if (dirp == NULL)
6617 abort ();
6619 while (1)
6621 struct dirent *dp = readdir (dirp);
6622 if (dp == NULL)
6623 break;
6625 if (DOT_OR_DOTDOT (dp->d_name))
6626 continue;
6628 if (unlink (dp->d_name))
6629 abort ();
6631 closedir (dirp);
6633 if (chdir (".."))
6634 abort ();
6636 if (rmdir (dir))
6637 exit (1);
6641 main ()
6643 const char *dir = "conf-dir";
6644 create_300_file_dir (dir);
6645 remove_dir (dir);
6646 exit (0);
6650 if { (eval echo configure:6651: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6651 then
6652 jm_cv_func_working_readdir=yes
6653 else
6654 echo "configure: failed program was:" >&5
6655 cat conftest.$ac_ext >&5
6656 rm -fr conftest*
6657 jm_cv_func_working_readdir=no
6659 rm -fr conftest*
6664 echo "$ac_t""$jm_cv_func_working_readdir" 1>&6
6666 if test $jm_cv_func_working_readdir = yes; then
6667 cat >>confdefs.h <<EOF
6668 #define HAVE_WORKING_READDIR 1
6673 if test $jm_cv_func_memcmp_working = no; then
6674 cat >>confdefs.h <<EOF
6675 #define memcmp rpl_memcmp
6680 io_functions='clearerr_unlocked feof_unlocked ferror_unlocked
6681 fflush_unlocked fputc_unlocked fread_unlocked fwrite_unlocked
6682 getc_unlocked getchar_unlocked putc_unlocked putchar_unlocked'
6683 for jm_io_func in $io_functions; do
6684 # Check for the existence of each function only if its declared.
6685 # Otherwise, we'd get the Solaris5.5.1 functions that are not
6686 # declared, and that have been removed from Solaris5.6. The resulting
6687 # 5.5.1 binaries would not run on 5.6 due to shared library differences.
6689 for jm_func in $jm_io_func
6692 test -z "$ac_cv_header_memory_h" && for ac_header in memory.h
6694 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
6695 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
6696 echo "configure:6697: checking for $ac_header" 1>&5
6697 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
6698 echo $ac_n "(cached) $ac_c" 1>&6
6699 else
6700 cat >conftest.$ac_ext <<EOF
6701 #line 6702 "configure"
6702 #include "confdefs.h"
6703 #include <$ac_header>
6706 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6707 { (eval echo configure:6708: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6708 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6709 if test -z "$ac_err"; then
6710 rm -rf conftest*
6711 eval "$ac_ac_Header=yes"
6712 else
6713 echo "$ac_err" >&5
6714 echo "configure: failed program was:" >&5
6715 cat conftest.$ac_ext >&5
6716 rm -rf conftest*
6717 eval "$ac_ac_Header=no"
6719 rm -f conftest*
6721 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
6722 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
6723 cat >>confdefs.h <<EOF
6724 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
6728 done
6730 test -z "$ac_cv_header_string_h" && for ac_header in string.h
6732 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
6733 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
6734 echo "configure:6735: checking for $ac_header" 1>&5
6735 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
6736 echo $ac_n "(cached) $ac_c" 1>&6
6737 else
6738 cat >conftest.$ac_ext <<EOF
6739 #line 6740 "configure"
6740 #include "confdefs.h"
6741 #include <$ac_header>
6744 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6745 { (eval echo configure:6746: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6746 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6747 if test -z "$ac_err"; then
6748 rm -rf conftest*
6749 eval "$ac_ac_Header=yes"
6750 else
6751 echo "$ac_err" >&5
6752 echo "configure: failed program was:" >&5
6753 cat conftest.$ac_ext >&5
6754 rm -rf conftest*
6755 eval "$ac_ac_Header=no"
6757 rm -f conftest*
6759 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
6760 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
6761 cat >>confdefs.h <<EOF
6762 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
6766 done
6768 test -z "$ac_cv_header_strings_h" && for ac_header in strings.h
6770 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
6771 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
6772 echo "configure:6773: checking for $ac_header" 1>&5
6773 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
6774 echo $ac_n "(cached) $ac_c" 1>&6
6775 else
6776 cat >conftest.$ac_ext <<EOF
6777 #line 6778 "configure"
6778 #include "confdefs.h"
6779 #include <$ac_header>
6782 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6783 { (eval echo configure:6784: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6784 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6785 if test -z "$ac_err"; then
6786 rm -rf conftest*
6787 eval "$ac_ac_Header=yes"
6788 else
6789 echo "$ac_err" >&5
6790 echo "configure: failed program was:" >&5
6791 cat conftest.$ac_ext >&5
6792 rm -rf conftest*
6793 eval "$ac_ac_Header=no"
6795 rm -f conftest*
6797 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
6798 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
6799 cat >>confdefs.h <<EOF
6800 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
6804 done
6806 test -z "$ac_cv_header_stdlib_h" && for ac_header in stdlib.h
6808 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
6809 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
6810 echo "configure:6811: checking for $ac_header" 1>&5
6811 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
6812 echo $ac_n "(cached) $ac_c" 1>&6
6813 else
6814 cat >conftest.$ac_ext <<EOF
6815 #line 6816 "configure"
6816 #include "confdefs.h"
6817 #include <$ac_header>
6820 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6821 { (eval echo configure:6822: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6822 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6823 if test -z "$ac_err"; then
6824 rm -rf conftest*
6825 eval "$ac_ac_Header=yes"
6826 else
6827 echo "$ac_err" >&5
6828 echo "configure: failed program was:" >&5
6829 cat conftest.$ac_ext >&5
6830 rm -rf conftest*
6831 eval "$ac_ac_Header=no"
6833 rm -f conftest*
6835 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
6836 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
6837 cat >>confdefs.h <<EOF
6838 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
6842 done
6844 test -z "$ac_cv_header_unistd_h" && for ac_header in unistd.h
6846 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
6847 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
6848 echo "configure:6849: checking for $ac_header" 1>&5
6849 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
6850 echo $ac_n "(cached) $ac_c" 1>&6
6851 else
6852 cat >conftest.$ac_ext <<EOF
6853 #line 6854 "configure"
6854 #include "confdefs.h"
6855 #include <$ac_header>
6858 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6859 { (eval echo configure:6860: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6860 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6861 if test -z "$ac_err"; then
6862 rm -rf conftest*
6863 eval "$ac_ac_Header=yes"
6864 else
6865 echo "$ac_err" >&5
6866 echo "configure: failed program was:" >&5
6867 cat conftest.$ac_ext >&5
6868 rm -rf conftest*
6869 eval "$ac_ac_Header=no"
6871 rm -f conftest*
6873 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
6874 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
6875 cat >>confdefs.h <<EOF
6876 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
6880 done
6882 echo $ac_n "checking whether $jm_func is declared... $ac_c" 1>&6
6883 echo "configure:6884: checking whether $jm_func is declared" 1>&5
6884 if eval "test \"\${jm_cv_func_decl_$jm_func+set}\" = set"; then
6885 echo $ac_n "(cached) $ac_c" 1>&6
6886 else
6887 cat >conftest.$ac_ext <<EOF
6888 #line 6889 "configure"
6889 #include "confdefs.h"
6890 #include <stdio.h>
6893 main ()
6896 #ifndef $jm_func
6897 char *(*pfn) = (char *(*)) $jm_func
6898 #endif
6901 return 0;
6904 if { (eval echo configure:6905: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6905 rm -rf conftest*
6906 eval "jm_cv_func_decl_$jm_func=yes"
6907 else
6908 echo "configure: failed program was:" >&5
6909 cat conftest.$ac_ext >&5
6910 rm -rf conftest*
6911 eval "jm_cv_func_decl_$jm_func=no"
6913 rm -f conftest*
6916 if eval "test \"`echo '$jm_cv_func_decl_'$jm_func`\" = yes"; then
6917 echo "$ac_t""yes" 1>&6
6919 jm_tr_func=HAVE_DECL_`echo $jm_func | tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ`
6920 cat >>confdefs.h <<EOF
6921 #define $jm_tr_func 1
6923 jm_declared=yes
6924 else
6925 echo "$ac_t""no" 1>&6
6926 jm_declared=no
6928 done
6930 if test $jm_declared = yes; then
6931 for ac_func in $jm_io_func
6933 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
6934 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
6935 echo "configure:6936: checking for $ac_func" 1>&5
6936 if eval "test \"\${$ac_ac_var+set}\" = set"; then
6937 echo $ac_n "(cached) $ac_c" 1>&6
6938 else
6939 cat >conftest.$ac_ext <<EOF
6940 #line 6941 "configure"
6941 #include "confdefs.h"
6942 /* System header to define __stub macros and hopefully few prototypes,
6943 which can conflict with char $ac_func(); below. */
6944 #include <assert.h>
6945 /* Override any gcc2 internal prototype to avoid an error. */
6946 /* We use char because int might match the return type of a gcc2
6947 builtin and then its argument prototype would still apply. */
6948 char $ac_func();
6949 char (*f)();
6952 main()
6955 /* The GNU C library defines this for functions which it implements
6956 to always fail with ENOSYS. Some functions are actually named
6957 something starting with __ and the normal name is an alias. */
6958 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6959 choke me
6960 #else
6961 f = $ac_func;
6962 #endif
6965 return 0;
6968 if { (eval echo configure:6969: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6969 rm -rf conftest*
6970 eval "$ac_ac_var=yes"
6971 else
6972 echo "configure: failed program was:" >&5
6973 cat conftest.$ac_ext >&5
6974 rm -rf conftest*
6975 eval "$ac_ac_var=no"
6977 rm -f conftest*
6980 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
6981 if test `eval echo '${'$ac_ac_var'}'` = yes; then
6982 cat >>confdefs.h <<EOF
6983 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
6987 done
6990 done
6992 for ac_header in fnmatch.h
6994 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
6995 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
6996 echo "configure:6997: checking for $ac_header" 1>&5
6997 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
6998 echo $ac_n "(cached) $ac_c" 1>&6
6999 else
7000 cat >conftest.$ac_ext <<EOF
7001 #line 7002 "configure"
7002 #include "confdefs.h"
7003 #include <$ac_header>
7006 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7007 { (eval echo configure:7008: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7008 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7009 if test -z "$ac_err"; then
7010 rm -rf conftest*
7011 eval "$ac_ac_Header=yes"
7012 else
7013 echo "$ac_err" >&5
7014 echo "configure: failed program was:" >&5
7015 cat conftest.$ac_ext >&5
7016 rm -rf conftest*
7017 eval "$ac_ac_Header=no"
7019 rm -f conftest*
7021 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
7022 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
7023 cat >>confdefs.h <<EOF
7024 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
7028 done
7030 echo $ac_n "checking for working fnmatch... $ac_c" 1>&6
7031 echo "configure:7032: checking for working fnmatch" 1>&5
7032 if test "${ac_cv_func_fnmatch_works+set}" = set; then
7033 echo $ac_n "(cached) $ac_c" 1>&6
7034 else
7035 # Some versions of Solaris or SCO have a broken fnmatch function.
7036 # So we run a test program. If we are cross-compiling, take no chance.
7037 # Thanks to John Oleynick and Franc,ois Pinard for this test.
7038 if test "$cross_compiling" = yes; then
7039 ac_cv_func_fnmatch_works=no
7040 else
7041 cat >conftest.$ac_ext <<EOF
7042 #line 7043 "configure"
7043 #include "confdefs.h"
7044 #if HAVE_FNMATCH_H
7045 # include <fnmatch.h>
7046 #endif
7049 main ()
7051 exit (fnmatch ("a*", "abc", 0) != 0);
7054 if { (eval echo configure:7055: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7055 then
7056 ac_cv_func_fnmatch_works=yes
7057 else
7058 echo "configure: failed program was:" >&5
7059 cat conftest.$ac_ext >&5
7060 rm -fr conftest*
7061 ac_cv_func_fnmatch_works=no
7063 rm -fr conftest*
7068 echo "$ac_t""$ac_cv_func_fnmatch_works" 1>&6
7069 if test $ac_cv_func_fnmatch_works = yes; then
7070 cat >>confdefs.h <<\EOF
7071 #define HAVE_FNMATCH 1
7076 if test $ac_cv_func_fnmatch_works = no \
7077 && test $ac_cv_gnu_library = no; then
7079 LIBOBJS="$LIBOBJS fnmatch.$ac_objext"
7080 cat >>confdefs.h <<EOF
7081 #define fnmatch rpl_fnmatch
7086 echo "checking for AFS" 1>&6
7087 echo "configure:7088: checking for AFS" 1>&5
7088 test -d /afs \
7089 && cat >>confdefs.h <<\EOF
7090 #define AFS 1
7093 GNU_PACKAGE="GNU $PACKAGE"
7094 cat >>confdefs.h <<EOF
7095 #define GNU_PACKAGE "$GNU_PACKAGE"
7098 # Assume we'll default to using the included regex.c.
7099 ac_use_included_regex=yes
7101 # However, if the system regex support is good enough that it passes the
7102 # the following run test, then default to *not* using the included regex.c.
7103 # If cross compiling, assume the test would fail and use the included
7104 # regex.c. The failing regular expression is from `Spencer ere test #75'
7105 # in grep-2.3.
7106 echo $ac_n "checking for working re_compile_pattern... $ac_c" 1>&6
7107 echo "configure:7108: checking for working re_compile_pattern" 1>&5
7108 if test "${jm_cv_func_working_re_compile_pattern+set}" = set; then
7109 echo $ac_n "(cached) $ac_c" 1>&6
7110 else
7111 if test "$cross_compiling" = yes; then
7112 jm_cv_func_working_re_compile_pattern=no
7113 else
7114 cat >conftest.$ac_ext <<EOF
7115 #line 7116 "configure"
7116 #include "confdefs.h"
7118 #include <stdio.h>
7119 #include <regex.h>
7121 main ()
7123 static struct re_pattern_buffer regex;
7124 const char *s;
7125 re_set_syntax (RE_SYNTAX_POSIX_EGREP);
7126 /* Add this third left square bracket, , to balance the
7127 three right ones below. Otherwise autoconf-2.14 chokes. */
7128 s = re_compile_pattern ("a[[:]:]b\n", 9, &regex);
7129 /* This should fail with _Invalid character class name_ error. */
7130 exit (s ? 0 : 1);
7134 if { (eval echo configure:7135: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7135 then
7137 jm_cv_func_working_re_compile_pattern=yes
7138 else
7139 echo "configure: failed program was:" >&5
7140 cat conftest.$ac_ext >&5
7141 rm -fr conftest*
7142 jm_cv_func_working_re_compile_pattern=no
7144 rm -fr conftest*
7149 echo "$ac_t""$jm_cv_func_working_re_compile_pattern" 1>&6
7150 if test $jm_cv_func_working_re_compile_pattern = yes; then
7151 ac_use_included_regex=no
7154 test -n "lib/regex.c" || { echo "configure: error: missing argument" 1>&2; exit 1; }
7156 # Check whether --with-included-regex or --without-included-regex was given.
7157 if test "${with_included_regex+set}" = set; then
7158 withval="$with_included_regex"
7159 jm_with_regex=$withval
7160 else
7161 jm_with_regex=$ac_use_included_regex
7164 if test "$jm_with_regex" = yes; then
7166 LIBOBJS="$LIBOBJS regex.$ac_objext"
7169 for ac_func in strcasecmp strncasecmp
7171 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
7172 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
7173 echo "configure:7174: checking for $ac_func" 1>&5
7174 if eval "test \"\${$ac_ac_var+set}\" = set"; then
7175 echo $ac_n "(cached) $ac_c" 1>&6
7176 else
7177 cat >conftest.$ac_ext <<EOF
7178 #line 7179 "configure"
7179 #include "confdefs.h"
7180 /* System header to define __stub macros and hopefully few prototypes,
7181 which can conflict with char $ac_func(); below. */
7182 #include <assert.h>
7183 /* Override any gcc2 internal prototype to avoid an error. */
7184 /* We use char because int might match the return type of a gcc2
7185 builtin and then its argument prototype would still apply. */
7186 char $ac_func();
7187 char (*f)();
7190 main()
7193 /* The GNU C library defines this for functions which it implements
7194 to always fail with ENOSYS. Some functions are actually named
7195 something starting with __ and the normal name is an alias. */
7196 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7197 choke me
7198 #else
7199 f = $ac_func;
7200 #endif
7203 return 0;
7206 if { (eval echo configure:7207: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7207 rm -rf conftest*
7208 eval "$ac_ac_var=yes"
7209 else
7210 echo "configure: failed program was:" >&5
7211 cat conftest.$ac_ext >&5
7212 rm -rf conftest*
7213 eval "$ac_ac_var=no"
7215 rm -f conftest*
7218 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
7219 if test `eval echo '${'$ac_ac_var'}'` = yes; then
7220 cat >>confdefs.h <<EOF
7221 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
7224 else
7225 LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
7227 done
7229 for ac_func in strdup
7231 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
7232 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
7233 echo "configure:7234: checking for $ac_func" 1>&5
7234 if eval "test \"\${$ac_ac_var+set}\" = set"; then
7235 echo $ac_n "(cached) $ac_c" 1>&6
7236 else
7237 cat >conftest.$ac_ext <<EOF
7238 #line 7239 "configure"
7239 #include "confdefs.h"
7240 /* System header to define __stub macros and hopefully few prototypes,
7241 which can conflict with char $ac_func(); below. */
7242 #include <assert.h>
7243 /* Override any gcc2 internal prototype to avoid an error. */
7244 /* We use char because int might match the return type of a gcc2
7245 builtin and then its argument prototype would still apply. */
7246 char $ac_func();
7247 char (*f)();
7250 main()
7253 /* The GNU C library defines this for functions which it implements
7254 to always fail with ENOSYS. Some functions are actually named
7255 something starting with __ and the normal name is an alias. */
7256 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7257 choke me
7258 #else
7259 f = $ac_func;
7260 #endif
7263 return 0;
7266 if { (eval echo configure:7267: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7267 rm -rf conftest*
7268 eval "$ac_ac_var=yes"
7269 else
7270 echo "configure: failed program was:" >&5
7271 cat conftest.$ac_ext >&5
7272 rm -rf conftest*
7273 eval "$ac_ac_var=no"
7275 rm -f conftest*
7278 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
7279 if test `eval echo '${'$ac_ac_var'}'` = yes; then
7280 cat >>confdefs.h <<EOF
7281 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
7284 else
7285 LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
7287 done
7289 for ac_func in getpagesize
7291 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
7292 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
7293 echo "configure:7294: checking for $ac_func" 1>&5
7294 if eval "test \"\${$ac_ac_var+set}\" = set"; then
7295 echo $ac_n "(cached) $ac_c" 1>&6
7296 else
7297 cat >conftest.$ac_ext <<EOF
7298 #line 7299 "configure"
7299 #include "confdefs.h"
7300 /* System header to define __stub macros and hopefully few prototypes,
7301 which can conflict with char $ac_func(); below. */
7302 #include <assert.h>
7303 /* Override any gcc2 internal prototype to avoid an error. */
7304 /* We use char because int might match the return type of a gcc2
7305 builtin and then its argument prototype would still apply. */
7306 char $ac_func();
7307 char (*f)();
7310 main()
7313 /* The GNU C library defines this for functions which it implements
7314 to always fail with ENOSYS. Some functions are actually named
7315 something starting with __ and the normal name is an alias. */
7316 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7317 choke me
7318 #else
7319 f = $ac_func;
7320 #endif
7323 return 0;
7326 if { (eval echo configure:7327: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7327 rm -rf conftest*
7328 eval "$ac_ac_var=yes"
7329 else
7330 echo "configure: failed program was:" >&5
7331 cat conftest.$ac_ext >&5
7332 rm -rf conftest*
7333 eval "$ac_ac_var=no"
7335 rm -f conftest*
7338 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
7339 if test `eval echo '${'$ac_ac_var'}'` = yes; then
7340 cat >>confdefs.h <<EOF
7341 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
7345 done
7347 # By default, argmatch should fail calling usage (1).
7348 cat >>confdefs.h <<\EOF
7349 #define ARGMATCH_DIE usage (1)
7352 cat >>confdefs.h <<\EOF
7353 #define ARGMATCH_DIE_DECL extern void usage ()
7356 echo $ac_n "checking whether setvbuf arguments are reversed... $ac_c" 1>&6
7357 echo "configure:7358: checking whether setvbuf arguments are reversed" 1>&5
7358 if test "${ac_cv_func_setvbuf_reversed+set}" = set; then
7359 echo $ac_n "(cached) $ac_c" 1>&6
7360 else
7361 if test "$cross_compiling" = yes; then
7362 { echo "configure: error: cannot run test program while cross compiling" 1>&2; exit 1; }
7363 else
7364 cat >conftest.$ac_ext <<EOF
7365 #line 7366 "configure"
7366 #include "confdefs.h"
7367 #include <stdio.h>
7368 /* If setvbuf has the reversed format, exit 0. */
7370 main ()
7372 /* This call has the arguments reversed.
7373 A reversed system may check and see that the address of main
7374 is not _IOLBF, _IONBF, or _IOFBF, and return nonzero. */
7375 if (setvbuf(stdout, _IOLBF, (char *) main, BUFSIZ) != 0)
7376 exit(1);
7377 putc('\r', stdout);
7378 exit(0); /* Non-reversed systems segv here. */
7381 if { (eval echo configure:7382: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7382 then
7383 ac_cv_func_setvbuf_reversed=yes
7384 else
7385 echo "configure: failed program was:" >&5
7386 cat conftest.$ac_ext >&5
7387 rm -fr conftest*
7388 ac_cv_func_setvbuf_reversed=no
7390 rm -fr conftest*
7394 rm -f core core.* *.core
7396 echo "$ac_t""$ac_cv_func_setvbuf_reversed" 1>&6
7397 if test $ac_cv_func_setvbuf_reversed = yes; then
7398 cat >>confdefs.h <<\EOF
7399 #define SETVBUF_REVERSED 1
7404 # used by sleep and shred
7405 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
7406 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
7407 echo $ac_n "checking for library containing clock_gettime... $ac_c" 1>&6
7408 echo "configure:7409: checking for library containing clock_gettime" 1>&5
7409 if test "${ac_cv_search_clock_gettime+set}" = set; then
7410 echo $ac_n "(cached) $ac_c" 1>&6
7411 else
7412 ac_func_search_save_LIBS="$LIBS"
7413 ac_cv_search_clock_gettime="no"
7414 cat >conftest.$ac_ext <<EOF
7415 #line 7416 "configure"
7416 #include "confdefs.h"
7417 /* Override any gcc2 internal prototype to avoid an error. */
7418 /* We use char because int might match the return type of a gcc2
7419 builtin and then its argument prototype would still apply. */
7420 char clock_gettime();
7423 main()
7425 clock_gettime()
7427 return 0;
7430 if { (eval echo configure:7431: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7431 rm -rf conftest*
7432 ac_cv_search_clock_gettime="none required"
7433 else
7434 echo "configure: failed program was:" >&5
7435 cat conftest.$ac_ext >&5
7437 rm -f conftest*
7439 test "$ac_cv_search_clock_gettime" = "no" && for ac_lib in rt posix4; do
7440 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7441 cat >conftest.$ac_ext <<EOF
7442 #line 7443 "configure"
7443 #include "confdefs.h"
7444 /* Override any gcc2 internal prototype to avoid an error. */
7445 /* We use char because int might match the return type of a gcc2
7446 builtin and then its argument prototype would still apply. */
7447 char clock_gettime();
7450 main()
7452 clock_gettime()
7454 return 0;
7457 if { (eval echo configure:7458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7458 rm -rf conftest*
7459 ac_cv_search_clock_gettime="-l$ac_lib"
7460 break
7461 else
7462 echo "configure: failed program was:" >&5
7463 cat conftest.$ac_ext >&5
7465 rm -f conftest*
7467 done
7468 LIBS="$ac_func_search_save_LIBS"
7470 echo "$ac_t""$ac_cv_search_clock_gettime" 1>&6
7471 if test "$ac_cv_search_clock_gettime" != "no"; then
7472 test "$ac_cv_search_clock_gettime" = "none required" || LIBS="$ac_cv_search_clock_gettime $LIBS"
7474 else :
7477 for ac_func in clock_gettime
7479 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
7480 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
7481 echo "configure:7482: checking for $ac_func" 1>&5
7482 if eval "test \"\${$ac_ac_var+set}\" = set"; then
7483 echo $ac_n "(cached) $ac_c" 1>&6
7484 else
7485 cat >conftest.$ac_ext <<EOF
7486 #line 7487 "configure"
7487 #include "confdefs.h"
7488 /* System header to define __stub macros and hopefully few prototypes,
7489 which can conflict with char $ac_func(); below. */
7490 #include <assert.h>
7491 /* Override any gcc2 internal prototype to avoid an error. */
7492 /* We use char because int might match the return type of a gcc2
7493 builtin and then its argument prototype would still apply. */
7494 char $ac_func();
7495 char (*f)();
7498 main()
7501 /* The GNU C library defines this for functions which it implements
7502 to always fail with ENOSYS. Some functions are actually named
7503 something starting with __ and the normal name is an alias. */
7504 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7505 choke me
7506 #else
7507 f = $ac_func;
7508 #endif
7511 return 0;
7514 if { (eval echo configure:7515: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7515 rm -rf conftest*
7516 eval "$ac_ac_var=yes"
7517 else
7518 echo "configure: failed program was:" >&5
7519 cat conftest.$ac_ext >&5
7520 rm -rf conftest*
7521 eval "$ac_ac_var=no"
7523 rm -f conftest*
7526 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
7527 if test `eval echo '${'$ac_ac_var'}'` = yes; then
7528 cat >>confdefs.h <<EOF
7529 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
7533 done
7535 for ac_func in gettimeofday
7537 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
7538 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
7539 echo "configure:7540: checking for $ac_func" 1>&5
7540 if eval "test \"\${$ac_ac_var+set}\" = set"; then
7541 echo $ac_n "(cached) $ac_c" 1>&6
7542 else
7543 cat >conftest.$ac_ext <<EOF
7544 #line 7545 "configure"
7545 #include "confdefs.h"
7546 /* System header to define __stub macros and hopefully few prototypes,
7547 which can conflict with char $ac_func(); below. */
7548 #include <assert.h>
7549 /* Override any gcc2 internal prototype to avoid an error. */
7550 /* We use char because int might match the return type of a gcc2
7551 builtin and then its argument prototype would still apply. */
7552 char $ac_func();
7553 char (*f)();
7556 main()
7559 /* The GNU C library defines this for functions which it implements
7560 to always fail with ENOSYS. Some functions are actually named
7561 something starting with __ and the normal name is an alias. */
7562 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7563 choke me
7564 #else
7565 f = $ac_func;
7566 #endif
7569 return 0;
7572 if { (eval echo configure:7573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7573 rm -rf conftest*
7574 eval "$ac_ac_var=yes"
7575 else
7576 echo "configure: failed program was:" >&5
7577 cat conftest.$ac_ext >&5
7578 rm -rf conftest*
7579 eval "$ac_ac_var=no"
7581 rm -f conftest*
7584 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
7585 if test `eval echo '${'$ac_ac_var'}'` = yes; then
7586 cat >>confdefs.h <<EOF
7587 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
7591 done
7593 am_getline_needs_run_time_check=no
7594 echo $ac_n "checking for getline... $ac_c" 1>&6
7595 echo "configure:7596: checking for getline" 1>&5
7596 if test "${ac_cv_func_getline+set}" = set; then
7597 echo $ac_n "(cached) $ac_c" 1>&6
7598 else
7599 cat >conftest.$ac_ext <<EOF
7600 #line 7601 "configure"
7601 #include "confdefs.h"
7602 /* System header to define __stub macros and hopefully few prototypes,
7603 which can conflict with char getline(); below. */
7604 #include <assert.h>
7605 /* Override any gcc2 internal prototype to avoid an error. */
7606 /* We use char because int might match the return type of a gcc2
7607 builtin and then its argument prototype would still apply. */
7608 char getline();
7609 char (*f)();
7612 main()
7615 /* The GNU C library defines this for functions which it implements
7616 to always fail with ENOSYS. Some functions are actually named
7617 something starting with __ and the normal name is an alias. */
7618 #if defined (__stub_getline) || defined (__stub___getline)
7619 choke me
7620 #else
7621 f = getline;
7622 #endif
7625 return 0;
7628 if { (eval echo configure:7629: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7629 rm -rf conftest*
7630 ac_cv_func_getline=yes
7631 else
7632 echo "configure: failed program was:" >&5
7633 cat conftest.$ac_ext >&5
7634 rm -rf conftest*
7635 ac_cv_func_getline=no
7637 rm -f conftest*
7640 echo "$ac_t""$ac_cv_func_getline" 1>&6
7641 if test $ac_cv_func_getline = yes; then
7642 am_getline_needs_run_time_check=yes
7643 else
7644 am_cv_func_working_getline=no
7647 if test $am_getline_needs_run_time_check = yes; then
7648 for ac_header in string.h
7650 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
7651 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
7652 echo "configure:7653: checking for $ac_header" 1>&5
7653 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
7654 echo $ac_n "(cached) $ac_c" 1>&6
7655 else
7656 cat >conftest.$ac_ext <<EOF
7657 #line 7658 "configure"
7658 #include "confdefs.h"
7659 #include <$ac_header>
7662 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7663 { (eval echo configure:7664: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7664 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7665 if test -z "$ac_err"; then
7666 rm -rf conftest*
7667 eval "$ac_ac_Header=yes"
7668 else
7669 echo "$ac_err" >&5
7670 echo "configure: failed program was:" >&5
7671 cat conftest.$ac_ext >&5
7672 rm -rf conftest*
7673 eval "$ac_ac_Header=no"
7675 rm -f conftest*
7677 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
7678 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
7679 cat >>confdefs.h <<EOF
7680 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
7684 done
7686 echo $ac_n "checking for working getline function... $ac_c" 1>&6
7687 echo "configure:7688: checking for working getline function" 1>&5
7688 if test "${am_cv_func_working_getline+set}" = set; then
7689 echo $ac_n "(cached) $ac_c" 1>&6
7690 else
7691 echo fooN |tr -d '\012'|tr N '\012' > conftest.data
7692 if test "$cross_compiling" = yes; then
7693 am_cv_func_working_getline=no
7694 else
7695 cat >conftest.$ac_ext <<EOF
7696 #line 7697 "configure"
7697 #include "confdefs.h"
7699 # include <stdio.h>
7700 # include <sys/types.h>
7701 # if HAVE_STRING_H
7702 # include <string.h>
7703 # endif
7704 int main ()
7705 { /* Based on a test program from Karl Heuer. */
7706 char *line = NULL;
7707 size_t siz = 0;
7708 int len;
7709 FILE *in = fopen ("./conftest.data", "r");
7710 if (!in)
7711 return 1;
7712 len = getline (&line, &siz, in);
7713 exit ((len == 4 && line && strcmp (line, "foo\n") == 0) ? 0 : 1);
7717 if { (eval echo configure:7718: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7718 then
7719 am_cv_func_working_getline=yes
7720 else
7721 echo "configure: failed program was:" >&5
7722 cat conftest.$ac_ext >&5
7723 rm -fr conftest*
7724 am_cv_func_working_getline=no
7726 rm -fr conftest*
7731 echo "$ac_t""$am_cv_func_working_getline" 1>&6
7734 if test $am_cv_func_working_getline = yes; then
7735 cat >>confdefs.h <<\EOF
7736 #define HAVE_GETLINE 1
7740 for ac_func in getdelim
7742 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
7743 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
7744 echo "configure:7745: checking for $ac_func" 1>&5
7745 if eval "test \"\${$ac_ac_var+set}\" = set"; then
7746 echo $ac_n "(cached) $ac_c" 1>&6
7747 else
7748 cat >conftest.$ac_ext <<EOF
7749 #line 7750 "configure"
7750 #include "confdefs.h"
7751 /* System header to define __stub macros and hopefully few prototypes,
7752 which can conflict with char $ac_func(); below. */
7753 #include <assert.h>
7754 /* Override any gcc2 internal prototype to avoid an error. */
7755 /* We use char because int might match the return type of a gcc2
7756 builtin and then its argument prototype would still apply. */
7757 char $ac_func();
7758 char (*f)();
7761 main()
7764 /* The GNU C library defines this for functions which it implements
7765 to always fail with ENOSYS. Some functions are actually named
7766 something starting with __ and the normal name is an alias. */
7767 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7768 choke me
7769 #else
7770 f = $ac_func;
7771 #endif
7774 return 0;
7777 if { (eval echo configure:7778: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7778 rm -rf conftest*
7779 eval "$ac_ac_var=yes"
7780 else
7781 echo "configure: failed program was:" >&5
7782 cat conftest.$ac_ext >&5
7783 rm -rf conftest*
7784 eval "$ac_ac_var=no"
7786 rm -f conftest*
7789 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
7790 if test `eval echo '${'$ac_ac_var'}'` = yes; then
7791 cat >>confdefs.h <<EOF
7792 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
7796 done
7798 for ac_func in fchdir getcwd strerror basename endgrent endpwent
7800 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
7801 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
7802 echo "configure:7803: checking for $ac_func" 1>&5
7803 if eval "test \"\${$ac_ac_var+set}\" = set"; then
7804 echo $ac_n "(cached) $ac_c" 1>&6
7805 else
7806 cat >conftest.$ac_ext <<EOF
7807 #line 7808 "configure"
7808 #include "confdefs.h"
7809 /* System header to define __stub macros and hopefully few prototypes,
7810 which can conflict with char $ac_func(); below. */
7811 #include <assert.h>
7812 /* Override any gcc2 internal prototype to avoid an error. */
7813 /* We use char because int might match the return type of a gcc2
7814 builtin and then its argument prototype would still apply. */
7815 char $ac_func();
7816 char (*f)();
7819 main()
7822 /* The GNU C library defines this for functions which it implements
7823 to always fail with ENOSYS. Some functions are actually named
7824 something starting with __ and the normal name is an alias. */
7825 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7826 choke me
7827 #else
7828 f = $ac_func;
7829 #endif
7832 return 0;
7835 if { (eval echo configure:7836: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7836 rm -rf conftest*
7837 eval "$ac_ac_var=yes"
7838 else
7839 echo "configure: failed program was:" >&5
7840 cat conftest.$ac_ext >&5
7841 rm -rf conftest*
7842 eval "$ac_ac_var=no"
7844 rm -f conftest*
7847 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
7848 if test `eval echo '${'$ac_ac_var'}'` = yes; then
7849 cat >>confdefs.h <<EOF
7850 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
7854 done
7856 for ac_header in sys/time.h unistd.h
7858 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
7859 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
7860 echo "configure:7861: checking for $ac_header" 1>&5
7861 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
7862 echo $ac_n "(cached) $ac_c" 1>&6
7863 else
7864 cat >conftest.$ac_ext <<EOF
7865 #line 7866 "configure"
7866 #include "confdefs.h"
7867 #include <$ac_header>
7870 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7871 { (eval echo configure:7872: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7872 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7873 if test -z "$ac_err"; then
7874 rm -rf conftest*
7875 eval "$ac_ac_Header=yes"
7876 else
7877 echo "$ac_err" >&5
7878 echo "configure: failed program was:" >&5
7879 cat conftest.$ac_ext >&5
7880 rm -rf conftest*
7881 eval "$ac_ac_Header=no"
7883 rm -f conftest*
7885 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
7886 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
7887 cat >>confdefs.h <<EOF
7888 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
7892 done
7894 for ac_func in alarm
7896 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
7897 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
7898 echo "configure:7899: checking for $ac_func" 1>&5
7899 if eval "test \"\${$ac_ac_var+set}\" = set"; then
7900 echo $ac_n "(cached) $ac_c" 1>&6
7901 else
7902 cat >conftest.$ac_ext <<EOF
7903 #line 7904 "configure"
7904 #include "confdefs.h"
7905 /* System header to define __stub macros and hopefully few prototypes,
7906 which can conflict with char $ac_func(); below. */
7907 #include <assert.h>
7908 /* Override any gcc2 internal prototype to avoid an error. */
7909 /* We use char because int might match the return type of a gcc2
7910 builtin and then its argument prototype would still apply. */
7911 char $ac_func();
7912 char (*f)();
7915 main()
7918 /* The GNU C library defines this for functions which it implements
7919 to always fail with ENOSYS. Some functions are actually named
7920 something starting with __ and the normal name is an alias. */
7921 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7922 choke me
7923 #else
7924 f = $ac_func;
7925 #endif
7928 return 0;
7931 if { (eval echo configure:7932: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7932 rm -rf conftest*
7933 eval "$ac_ac_var=yes"
7934 else
7935 echo "configure: failed program was:" >&5
7936 cat conftest.$ac_ext >&5
7937 rm -rf conftest*
7938 eval "$ac_ac_var=no"
7940 rm -f conftest*
7943 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
7944 if test `eval echo '${'$ac_ac_var'}'` = yes; then
7945 cat >>confdefs.h <<EOF
7946 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
7950 done
7952 echo $ac_n "checking for working mktime... $ac_c" 1>&6
7953 echo "configure:7954: checking for working mktime" 1>&5
7954 if test "${ac_cv_func_working_mktime+set}" = set; then
7955 echo $ac_n "(cached) $ac_c" 1>&6
7956 else
7957 if test "$cross_compiling" = yes; then
7958 ac_cv_func_working_mktime=no
7959 else
7960 cat >conftest.$ac_ext <<EOF
7961 #line 7962 "configure"
7962 #include "confdefs.h"
7963 /* Test program from Paul Eggert (eggert@twinsun.com)
7964 and Tony Leneis (tony@plaza.ds.adp.com). */
7965 #if TIME_WITH_SYS_TIME
7966 # include <sys/time.h>
7967 # include <time.h>
7968 #else
7969 # if HAVE_SYS_TIME_H
7970 # include <sys/time.h>
7971 # else
7972 # include <time.h>
7973 # endif
7974 #endif
7976 #if HAVE_UNISTD_H
7977 # include <unistd.h>
7978 #endif
7980 #if !HAVE_ALARM
7981 # define alarm(X) /* empty */
7982 #endif
7984 /* Work around redefinition to rpl_putenv by other config tests. */
7985 #undef putenv
7987 static time_t time_t_max;
7989 /* Values we'll use to set the TZ environment variable. */
7990 static const char *const tz_strings[] = {
7991 (const char *) 0, "TZ=GMT0", "TZ=JST-9",
7992 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
7994 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
7996 /* Fail if mktime fails to convert a date in the spring-forward gap.
7997 Based on a problem report from Andreas Jaeger. */
7998 static void
7999 spring_forward_gap ()
8001 /* glibc (up to about 1998-10-07) failed this test) */
8002 struct tm tm;
8004 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
8005 instead of "TZ=America/Vancouver" in order to detect the bug even
8006 on systems that don't support the Olson extension, or don't have the
8007 full zoneinfo tables installed. */
8008 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
8010 tm.tm_year = 98;
8011 tm.tm_mon = 3;
8012 tm.tm_mday = 5;
8013 tm.tm_hour = 2;
8014 tm.tm_min = 0;
8015 tm.tm_sec = 0;
8016 tm.tm_isdst = -1;
8017 if (mktime (&tm) == (time_t)-1)
8018 exit (1);
8021 static void
8022 mktime_test (now)
8023 time_t now;
8025 struct tm *lt;
8026 if ((lt = localtime (&now)) && mktime (lt) != now)
8027 exit (1);
8028 now = time_t_max - now;
8029 if ((lt = localtime (&now)) && mktime (lt) != now)
8030 exit (1);
8033 static void
8034 irix_6_4_bug ()
8036 /* Based on code from Ariel Faigon. */
8037 struct tm tm;
8038 tm.tm_year = 96;
8039 tm.tm_mon = 3;
8040 tm.tm_mday = 0;
8041 tm.tm_hour = 0;
8042 tm.tm_min = 0;
8043 tm.tm_sec = 0;
8044 tm.tm_isdst = -1;
8045 mktime (&tm);
8046 if (tm.tm_mon != 2 || tm.tm_mday != 31)
8047 exit (1);
8050 static void
8051 bigtime_test (j)
8052 int j;
8054 struct tm tm;
8055 time_t now;
8056 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
8057 now = mktime (&tm);
8058 if (now != (time_t) -1)
8060 struct tm *lt = localtime (&now);
8061 if (! (lt
8062 && lt->tm_year == tm.tm_year
8063 && lt->tm_mon == tm.tm_mon
8064 && lt->tm_mday == tm.tm_mday
8065 && lt->tm_hour == tm.tm_hour
8066 && lt->tm_min == tm.tm_min
8067 && lt->tm_sec == tm.tm_sec
8068 && lt->tm_yday == tm.tm_yday
8069 && lt->tm_wday == tm.tm_wday
8070 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
8071 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
8072 exit (1);
8077 main ()
8079 time_t t, delta;
8080 int i, j;
8082 /* This test makes some buggy mktime implementations loop.
8083 Give up after 60 seconds; a mktime slower than that
8084 isn't worth using anyway. */
8085 alarm (60);
8087 for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
8088 continue;
8089 time_t_max--;
8090 delta = time_t_max / 997; /* a suitable prime number */
8091 for (i = 0; i < N_STRINGS; i++)
8093 if (tz_strings[i])
8094 putenv (tz_strings[i]);
8096 for (t = 0; t <= time_t_max - delta; t += delta)
8097 mktime_test (t);
8098 mktime_test ((time_t) 60 * 60);
8099 mktime_test ((time_t) 60 * 60 * 24);
8101 for (j = 1; 0 < j; j *= 2)
8102 bigtime_test (j);
8103 bigtime_test (j - 1);
8105 irix_6_4_bug ();
8106 spring_forward_gap ();
8107 exit (0);
8110 if { (eval echo configure:8111: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8111 then
8112 ac_cv_func_working_mktime=yes
8113 else
8114 echo "configure: failed program was:" >&5
8115 cat conftest.$ac_ext >&5
8116 rm -fr conftest*
8117 ac_cv_func_working_mktime=no
8119 rm -fr conftest*
8124 echo "$ac_t""$ac_cv_func_working_mktime" 1>&6
8125 if test $ac_cv_func_working_mktime = no; then
8126 LIBOBJS="$LIBOBJS mktime.${ac_objext}"
8129 echo $ac_n "checking for vprintf... $ac_c" 1>&6
8130 echo "configure:8131: checking for vprintf" 1>&5
8131 if test "${ac_cv_func_vprintf+set}" = set; then
8132 echo $ac_n "(cached) $ac_c" 1>&6
8133 else
8134 cat >conftest.$ac_ext <<EOF
8135 #line 8136 "configure"
8136 #include "confdefs.h"
8137 /* System header to define __stub macros and hopefully few prototypes,
8138 which can conflict with char vprintf(); below. */
8139 #include <assert.h>
8140 /* Override any gcc2 internal prototype to avoid an error. */
8141 /* We use char because int might match the return type of a gcc2
8142 builtin and then its argument prototype would still apply. */
8143 char vprintf();
8144 char (*f)();
8147 main()
8150 /* The GNU C library defines this for functions which it implements
8151 to always fail with ENOSYS. Some functions are actually named
8152 something starting with __ and the normal name is an alias. */
8153 #if defined (__stub_vprintf) || defined (__stub___vprintf)
8154 choke me
8155 #else
8156 f = vprintf;
8157 #endif
8160 return 0;
8163 if { (eval echo configure:8164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8164 rm -rf conftest*
8165 ac_cv_func_vprintf=yes
8166 else
8167 echo "configure: failed program was:" >&5
8168 cat conftest.$ac_ext >&5
8169 rm -rf conftest*
8170 ac_cv_func_vprintf=no
8172 rm -f conftest*
8175 echo "$ac_t""$ac_cv_func_vprintf" 1>&6
8176 if test $ac_cv_func_vprintf = yes; then
8177 cat >>confdefs.h <<\EOF
8178 #define HAVE_VPRINTF 1
8183 if test "$ac_cv_func_vprintf" != yes; then
8184 echo $ac_n "checking for _doprnt... $ac_c" 1>&6
8185 echo "configure:8186: checking for _doprnt" 1>&5
8186 if test "${ac_cv_func__doprnt+set}" = set; then
8187 echo $ac_n "(cached) $ac_c" 1>&6
8188 else
8189 cat >conftest.$ac_ext <<EOF
8190 #line 8191 "configure"
8191 #include "confdefs.h"
8192 /* System header to define __stub macros and hopefully few prototypes,
8193 which can conflict with char _doprnt(); below. */
8194 #include <assert.h>
8195 /* Override any gcc2 internal prototype to avoid an error. */
8196 /* We use char because int might match the return type of a gcc2
8197 builtin and then its argument prototype would still apply. */
8198 char _doprnt();
8199 char (*f)();
8202 main()
8205 /* The GNU C library defines this for functions which it implements
8206 to always fail with ENOSYS. Some functions are actually named
8207 something starting with __ and the normal name is an alias. */
8208 #if defined (__stub__doprnt) || defined (__stub____doprnt)
8209 choke me
8210 #else
8211 f = _doprnt;
8212 #endif
8215 return 0;
8218 if { (eval echo configure:8219: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8219 rm -rf conftest*
8220 ac_cv_func__doprnt=yes
8221 else
8222 echo "configure: failed program was:" >&5
8223 cat conftest.$ac_ext >&5
8224 rm -rf conftest*
8225 ac_cv_func__doprnt=no
8227 rm -f conftest*
8230 echo "$ac_t""$ac_cv_func__doprnt" 1>&6
8231 if test $ac_cv_func__doprnt = yes; then
8232 cat >>confdefs.h <<\EOF
8233 #define HAVE_DOPRNT 1
8240 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
8241 # for constant arguments. Useless!
8242 echo $ac_n "checking for working alloca.h... $ac_c" 1>&6
8243 echo "configure:8244: checking for working alloca.h" 1>&5
8244 if test "${ac_cv_working_alloca_h+set}" = set; then
8245 echo $ac_n "(cached) $ac_c" 1>&6
8246 else
8247 cat >conftest.$ac_ext <<EOF
8248 #line 8249 "configure"
8249 #include "confdefs.h"
8250 #include <alloca.h>
8252 main()
8254 char *p = alloca(2 * sizeof(int));
8256 return 0;
8259 if { (eval echo configure:8260: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8260 rm -rf conftest*
8261 ac_cv_working_alloca_h=yes
8262 else
8263 echo "configure: failed program was:" >&5
8264 cat conftest.$ac_ext >&5
8265 rm -rf conftest*
8266 ac_cv_working_alloca_h=no
8268 rm -f conftest*
8271 echo "$ac_t""$ac_cv_working_alloca_h" 1>&6
8272 if test $ac_cv_working_alloca_h = yes; then
8273 cat >>confdefs.h <<\EOF
8274 #define HAVE_ALLOCA_H 1
8279 echo $ac_n "checking for alloca... $ac_c" 1>&6
8280 echo "configure:8281: checking for alloca" 1>&5
8281 if test "${ac_cv_func_alloca_works+set}" = set; then
8282 echo $ac_n "(cached) $ac_c" 1>&6
8283 else
8284 cat >conftest.$ac_ext <<EOF
8285 #line 8286 "configure"
8286 #include "confdefs.h"
8287 #ifdef __GNUC__
8288 # define alloca __builtin_alloca
8289 #else
8290 # ifdef _MSC_VER
8291 # include <malloc.h>
8292 # define alloca _alloca
8293 # else
8294 # if HAVE_ALLOCA_H
8295 # include <alloca.h>
8296 # else
8297 # ifdef _AIX
8298 #pragma alloca
8299 # else
8300 # ifndef alloca /* predefined by HP cc +Olibcalls */
8301 char *alloca ();
8302 # endif
8303 # endif
8304 # endif
8305 # endif
8306 #endif
8309 main()
8311 char *p = (char *) alloca(1);
8313 return 0;
8316 if { (eval echo configure:8317: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8317 rm -rf conftest*
8318 ac_cv_func_alloca_works=yes
8319 else
8320 echo "configure: failed program was:" >&5
8321 cat conftest.$ac_ext >&5
8322 rm -rf conftest*
8323 ac_cv_func_alloca_works=no
8325 rm -f conftest*
8328 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
8329 if test $ac_cv_func_alloca_works = yes; then
8330 cat >>confdefs.h <<\EOF
8331 #define HAVE_ALLOCA 1
8336 if test $ac_cv_func_alloca_works = no; then
8337 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
8338 # that cause trouble. Some versions do not even contain alloca or
8339 # contain a buggy version. If you still want to use their alloca,
8340 # use ar to extract alloca.o from them instead of compiling alloca.c.
8341 ALLOCA=alloca.${ac_objext}
8342 cat >>confdefs.h <<\EOF
8343 #define C_ALLOCA 1
8346 echo $ac_n "checking whether alloca needs Cray hooks... $ac_c" 1>&6
8347 echo "configure:8348: checking whether alloca needs Cray hooks" 1>&5
8348 if test "${ac_cv_os_cray+set}" = set; then
8349 echo $ac_n "(cached) $ac_c" 1>&6
8350 else
8351 cat >conftest.$ac_ext <<EOF
8352 #line 8353 "configure"
8353 #include "confdefs.h"
8354 #if defined(CRAY) && ! defined(CRAY2)
8355 webecray
8356 #else
8357 wenotbecray
8358 #endif
8361 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8362 egrep "webecray" >/dev/null 2>&1; then
8363 rm -rf conftest*
8364 ac_cv_os_cray=yes
8365 else
8366 rm -rf conftest*
8367 ac_cv_os_cray=no
8369 rm -f conftest*
8372 echo "$ac_t""$ac_cv_os_cray" 1>&6
8373 if test $ac_cv_os_cray = yes; then
8374 for ac_func in _getb67 GETB67 getb67; do
8375 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
8376 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
8377 echo "configure:8378: checking for $ac_func" 1>&5
8378 if eval "test \"\${$ac_ac_var+set}\" = set"; then
8379 echo $ac_n "(cached) $ac_c" 1>&6
8380 else
8381 cat >conftest.$ac_ext <<EOF
8382 #line 8383 "configure"
8383 #include "confdefs.h"
8384 /* System header to define __stub macros and hopefully few prototypes,
8385 which can conflict with char $ac_func(); below. */
8386 #include <assert.h>
8387 /* Override any gcc2 internal prototype to avoid an error. */
8388 /* We use char because int might match the return type of a gcc2
8389 builtin and then its argument prototype would still apply. */
8390 char $ac_func();
8391 char (*f)();
8394 main()
8397 /* The GNU C library defines this for functions which it implements
8398 to always fail with ENOSYS. Some functions are actually named
8399 something starting with __ and the normal name is an alias. */
8400 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8401 choke me
8402 #else
8403 f = $ac_func;
8404 #endif
8407 return 0;
8410 if { (eval echo configure:8411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8411 rm -rf conftest*
8412 eval "$ac_ac_var=yes"
8413 else
8414 echo "configure: failed program was:" >&5
8415 cat conftest.$ac_ext >&5
8416 rm -rf conftest*
8417 eval "$ac_ac_var=no"
8419 rm -f conftest*
8422 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
8423 if test `eval echo '${'$ac_ac_var'}'` = yes; then
8424 cat >>confdefs.h <<EOF
8425 #define CRAY_STACKSEG_END $ac_func
8428 break
8431 done
8434 echo $ac_n "checking stack direction for C alloca... $ac_c" 1>&6
8435 echo "configure:8436: checking stack direction for C alloca" 1>&5
8436 if test "${ac_cv_c_stack_direction+set}" = set; then
8437 echo $ac_n "(cached) $ac_c" 1>&6
8438 else
8439 if test "$cross_compiling" = yes; then
8440 ac_cv_c_stack_direction=0
8441 else
8442 cat >conftest.$ac_ext <<EOF
8443 #line 8444 "configure"
8444 #include "confdefs.h"
8445 find_stack_direction ()
8447 static char *addr = 0;
8448 auto char dummy;
8449 if (addr == 0)
8451 addr = &dummy;
8452 return find_stack_direction ();
8454 else
8455 return (&dummy > addr) ? 1 : -1;
8459 main ()
8461 exit (find_stack_direction () < 0);
8464 if { (eval echo configure:8465: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8465 then
8466 ac_cv_c_stack_direction=1
8467 else
8468 echo "configure: failed program was:" >&5
8469 cat conftest.$ac_ext >&5
8470 rm -fr conftest*
8471 ac_cv_c_stack_direction=-1
8473 rm -fr conftest*
8478 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
8479 cat >>confdefs.h <<EOF
8480 #define STACK_DIRECTION $ac_cv_c_stack_direction
8485 # getmntent is in -lsun on Irix 4, -lseq on Dynix/PTX, -lgen on Unixware.
8486 echo $ac_n "checking for getmntent in -lsun... $ac_c" 1>&6
8487 echo "configure:8488: checking for getmntent in -lsun" 1>&5
8488 if test "${ac_cv_lib_sun_getmntent+set}" = set; then
8489 echo $ac_n "(cached) $ac_c" 1>&6
8490 else
8491 ac_save_LIBS="$LIBS"
8492 LIBS="-lsun $LIBS"
8493 cat >conftest.$ac_ext <<EOF
8494 #line 8495 "configure"
8495 #include "confdefs.h"
8496 /* Override any gcc2 internal prototype to avoid an error. */
8497 /* We use char because int might match the return type of a gcc2
8498 builtin and then its argument prototype would still apply. */
8499 char getmntent();
8502 main()
8504 getmntent()
8506 return 0;
8509 if { (eval echo configure:8510: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8510 rm -rf conftest*
8511 ac_cv_lib_sun_getmntent=yes
8512 else
8513 echo "configure: failed program was:" >&5
8514 cat conftest.$ac_ext >&5
8515 rm -rf conftest*
8516 ac_cv_lib_sun_getmntent=no
8518 rm -f conftest*
8520 LIBS="$ac_save_LIBS"
8522 echo "$ac_t""$ac_cv_lib_sun_getmntent" 1>&6
8523 if test $ac_cv_lib_sun_getmntent = yes; then
8524 LIBS="-lsun $LIBS"
8525 else
8526 echo $ac_n "checking for getmntent in -lseq... $ac_c" 1>&6
8527 echo "configure:8528: checking for getmntent in -lseq" 1>&5
8528 if test "${ac_cv_lib_seq_getmntent+set}" = set; then
8529 echo $ac_n "(cached) $ac_c" 1>&6
8530 else
8531 ac_save_LIBS="$LIBS"
8532 LIBS="-lseq $LIBS"
8533 cat >conftest.$ac_ext <<EOF
8534 #line 8535 "configure"
8535 #include "confdefs.h"
8536 /* Override any gcc2 internal prototype to avoid an error. */
8537 /* We use char because int might match the return type of a gcc2
8538 builtin and then its argument prototype would still apply. */
8539 char getmntent();
8542 main()
8544 getmntent()
8546 return 0;
8549 if { (eval echo configure:8550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8550 rm -rf conftest*
8551 ac_cv_lib_seq_getmntent=yes
8552 else
8553 echo "configure: failed program was:" >&5
8554 cat conftest.$ac_ext >&5
8555 rm -rf conftest*
8556 ac_cv_lib_seq_getmntent=no
8558 rm -f conftest*
8560 LIBS="$ac_save_LIBS"
8562 echo "$ac_t""$ac_cv_lib_seq_getmntent" 1>&6
8563 if test $ac_cv_lib_seq_getmntent = yes; then
8564 LIBS="-lseq $LIBS"
8565 else
8566 echo $ac_n "checking for getmntent in -lgen... $ac_c" 1>&6
8567 echo "configure:8568: checking for getmntent in -lgen" 1>&5
8568 if test "${ac_cv_lib_gen_getmntent+set}" = set; then
8569 echo $ac_n "(cached) $ac_c" 1>&6
8570 else
8571 ac_save_LIBS="$LIBS"
8572 LIBS="-lgen $LIBS"
8573 cat >conftest.$ac_ext <<EOF
8574 #line 8575 "configure"
8575 #include "confdefs.h"
8576 /* Override any gcc2 internal prototype to avoid an error. */
8577 /* We use char because int might match the return type of a gcc2
8578 builtin and then its argument prototype would still apply. */
8579 char getmntent();
8582 main()
8584 getmntent()
8586 return 0;
8589 if { (eval echo configure:8590: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8590 rm -rf conftest*
8591 ac_cv_lib_gen_getmntent=yes
8592 else
8593 echo "configure: failed program was:" >&5
8594 cat conftest.$ac_ext >&5
8595 rm -rf conftest*
8596 ac_cv_lib_gen_getmntent=no
8598 rm -f conftest*
8600 LIBS="$ac_save_LIBS"
8602 echo "$ac_t""$ac_cv_lib_gen_getmntent" 1>&6
8603 if test $ac_cv_lib_gen_getmntent = yes; then
8604 LIBS="-lgen $LIBS"
8611 echo $ac_n "checking for getmntent... $ac_c" 1>&6
8612 echo "configure:8613: checking for getmntent" 1>&5
8613 if test "${ac_cv_func_getmntent+set}" = set; then
8614 echo $ac_n "(cached) $ac_c" 1>&6
8615 else
8616 cat >conftest.$ac_ext <<EOF
8617 #line 8618 "configure"
8618 #include "confdefs.h"
8619 /* System header to define __stub macros and hopefully few prototypes,
8620 which can conflict with char getmntent(); below. */
8621 #include <assert.h>
8622 /* Override any gcc2 internal prototype to avoid an error. */
8623 /* We use char because int might match the return type of a gcc2
8624 builtin and then its argument prototype would still apply. */
8625 char getmntent();
8626 char (*f)();
8629 main()
8632 /* The GNU C library defines this for functions which it implements
8633 to always fail with ENOSYS. Some functions are actually named
8634 something starting with __ and the normal name is an alias. */
8635 #if defined (__stub_getmntent) || defined (__stub___getmntent)
8636 choke me
8637 #else
8638 f = getmntent;
8639 #endif
8642 return 0;
8645 if { (eval echo configure:8646: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8646 rm -rf conftest*
8647 ac_cv_func_getmntent=yes
8648 else
8649 echo "configure: failed program was:" >&5
8650 cat conftest.$ac_ext >&5
8651 rm -rf conftest*
8652 ac_cv_func_getmntent=no
8654 rm -f conftest*
8657 echo "$ac_t""$ac_cv_func_getmntent" 1>&6
8658 if test $ac_cv_func_getmntent = yes; then
8659 cat >>confdefs.h <<\EOF
8660 #define HAVE_GETMNTENT 1
8665 echo $ac_n "checking whether closedir returns void... $ac_c" 1>&6
8666 echo "configure:8667: checking whether closedir returns void" 1>&5
8667 if test "${ac_cv_func_closedir_void+set}" = set; then
8668 echo $ac_n "(cached) $ac_c" 1>&6
8669 else
8670 if test "$cross_compiling" = yes; then
8671 ac_cv_func_closedir_void=yes
8672 else
8673 cat >conftest.$ac_ext <<EOF
8674 #line 8675 "configure"
8675 #include "confdefs.h"
8676 #include <sys/types.h>
8677 #include <$ac_header_dirent>
8679 int closedir ();
8681 main ()
8683 exit (closedir (opendir (".")) != 0);
8686 if { (eval echo configure:8687: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8687 then
8688 ac_cv_func_closedir_void=no
8689 else
8690 echo "configure: failed program was:" >&5
8691 cat conftest.$ac_ext >&5
8692 rm -fr conftest*
8693 ac_cv_func_closedir_void=yes
8695 rm -fr conftest*
8700 echo "$ac_t""$ac_cv_func_closedir_void" 1>&6
8701 if test $ac_cv_func_closedir_void = yes; then
8702 cat >>confdefs.h <<\EOF
8703 #define CLOSEDIR_VOID 1
8708 for ac_header in unistd.h
8710 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
8711 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
8712 echo "configure:8713: checking for $ac_header" 1>&5
8713 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
8714 echo $ac_n "(cached) $ac_c" 1>&6
8715 else
8716 cat >conftest.$ac_ext <<EOF
8717 #line 8718 "configure"
8718 #include "confdefs.h"
8719 #include <$ac_header>
8722 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8723 { (eval echo configure:8724: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8724 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
8725 if test -z "$ac_err"; then
8726 rm -rf conftest*
8727 eval "$ac_ac_Header=yes"
8728 else
8729 echo "$ac_err" >&5
8730 echo "configure: failed program was:" >&5
8731 cat conftest.$ac_ext >&5
8732 rm -rf conftest*
8733 eval "$ac_ac_Header=no"
8735 rm -f conftest*
8737 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
8738 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
8739 cat >>confdefs.h <<EOF
8740 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
8744 done
8746 for ac_func in getpagesize
8748 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
8749 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
8750 echo "configure:8751: checking for $ac_func" 1>&5
8751 if eval "test \"\${$ac_ac_var+set}\" = set"; then
8752 echo $ac_n "(cached) $ac_c" 1>&6
8753 else
8754 cat >conftest.$ac_ext <<EOF
8755 #line 8756 "configure"
8756 #include "confdefs.h"
8757 /* System header to define __stub macros and hopefully few prototypes,
8758 which can conflict with char $ac_func(); below. */
8759 #include <assert.h>
8760 /* Override any gcc2 internal prototype to avoid an error. */
8761 /* We use char because int might match the return type of a gcc2
8762 builtin and then its argument prototype would still apply. */
8763 char $ac_func();
8764 char (*f)();
8767 main()
8770 /* The GNU C library defines this for functions which it implements
8771 to always fail with ENOSYS. Some functions are actually named
8772 something starting with __ and the normal name is an alias. */
8773 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8774 choke me
8775 #else
8776 f = $ac_func;
8777 #endif
8780 return 0;
8783 if { (eval echo configure:8784: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8784 rm -rf conftest*
8785 eval "$ac_ac_var=yes"
8786 else
8787 echo "configure: failed program was:" >&5
8788 cat conftest.$ac_ext >&5
8789 rm -rf conftest*
8790 eval "$ac_ac_var=no"
8792 rm -f conftest*
8795 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
8796 if test `eval echo '${'$ac_ac_var'}'` = yes; then
8797 cat >>confdefs.h <<EOF
8798 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
8802 done
8804 echo $ac_n "checking for working mmap... $ac_c" 1>&6
8805 echo "configure:8806: checking for working mmap" 1>&5
8806 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
8807 echo $ac_n "(cached) $ac_c" 1>&6
8808 else
8809 if test "$cross_compiling" = yes; then
8810 ac_cv_func_mmap_fixed_mapped=no
8811 else
8812 cat >conftest.$ac_ext <<EOF
8813 #line 8814 "configure"
8814 #include "confdefs.h"
8815 /* Thanks to Mike Haertel and Jim Avera for this test.
8816 Here is a matrix of mmap possibilities:
8817 mmap private not fixed
8818 mmap private fixed at somewhere currently unmapped
8819 mmap private fixed at somewhere already mapped
8820 mmap shared not fixed
8821 mmap shared fixed at somewhere currently unmapped
8822 mmap shared fixed at somewhere already mapped
8823 For private mappings, we should verify that changes cannot be read()
8824 back from the file, nor mmap's back from the file at a different
8825 address. (There have been systems where private was not correctly
8826 implemented like the infamous i386 svr4.0, and systems where the
8827 VM page cache was not coherent with the file system buffer cache
8828 like early versions of FreeBSD and possibly contemporary NetBSD.)
8829 For shared mappings, we should conversely verify that changes get
8830 propogated back to all the places they're supposed to be.
8832 Grep wants private fixed already mapped.
8833 The main things grep needs to know about mmap are:
8834 * does it exist and is it safe to write into the mmap'd area
8835 * how to use it (BSD variants) */
8836 #include <sys/types.h>
8837 #include <fcntl.h>
8838 #include <sys/mman.h>
8840 /* This mess was copied from the GNU getpagesize.h. */
8841 #if !HAVE_GETPAGESIZE
8842 # if HAVE_UNISTD_H
8843 # include <unistd.h>
8844 # endif
8846 /* Assume that all systems that can run configure have sys/param.h. */
8847 # if !HAVE_SYS_PARAM_H
8848 # define HAVE_SYS_PARAM_H 1
8849 # endif
8851 # ifdef _SC_PAGESIZE
8852 # define getpagesize() sysconf(_SC_PAGESIZE)
8853 # else /* no _SC_PAGESIZE */
8854 # if HAVE_SYS_PARAM_H
8855 # include <sys/param.h>
8856 # ifdef EXEC_PAGESIZE
8857 # define getpagesize() EXEC_PAGESIZE
8858 # else /* no EXEC_PAGESIZE */
8859 # ifdef NBPG
8860 # define getpagesize() NBPG * CLSIZE
8861 # ifndef CLSIZE
8862 # define CLSIZE 1
8863 # endif /* no CLSIZE */
8864 # else /* no NBPG */
8865 # ifdef NBPC
8866 # define getpagesize() NBPC
8867 # else /* no NBPC */
8868 # ifdef PAGESIZE
8869 # define getpagesize() PAGESIZE
8870 # endif /* PAGESIZE */
8871 # endif /* no NBPC */
8872 # endif /* no NBPG */
8873 # endif /* no EXEC_PAGESIZE */
8874 # else /* no HAVE_SYS_PARAM_H */
8875 # define getpagesize() 8192 /* punt totally */
8876 # endif /* no HAVE_SYS_PARAM_H */
8877 # endif /* no _SC_PAGESIZE */
8879 #endif /* no HAVE_GETPAGESIZE */
8881 #ifdef __cplusplus
8882 extern "C" { void *malloc(unsigned); }
8883 #else
8884 char *malloc();
8885 #endif
8888 main ()
8890 char *data, *data2, *data3;
8891 int i, pagesize;
8892 int fd;
8894 pagesize = getpagesize ();
8896 /* First, make a file with some known garbage in it. */
8897 data = malloc (pagesize);
8898 if (!data)
8899 exit (1);
8900 for (i = 0; i < pagesize; ++i)
8901 *(data + i) = rand ();
8902 umask (0);
8903 fd = creat ("conftestmmap", 0600);
8904 if (fd < 0)
8905 exit (1);
8906 if (write (fd, data, pagesize) != pagesize)
8907 exit (1);
8908 close (fd);
8910 /* Next, try to mmap the file at a fixed address which already has
8911 something else allocated at it. If we can, also make sure that
8912 we see the same garbage. */
8913 fd = open ("conftestmmap", O_RDWR);
8914 if (fd < 0)
8915 exit (1);
8916 data2 = malloc (2 * pagesize);
8917 if (!data2)
8918 exit (1);
8919 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
8920 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
8921 MAP_PRIVATE | MAP_FIXED, fd, 0L))
8922 exit (1);
8923 for (i = 0; i < pagesize; ++i)
8924 if (*(data + i) != *(data2 + i))
8925 exit (1);
8927 /* Finally, make sure that changes to the mapped area do not
8928 percolate back to the file as seen by read(). (This is a bug on
8929 some variants of i386 svr4.0.) */
8930 for (i = 0; i < pagesize; ++i)
8931 *(data2 + i) = *(data2 + i) + 1;
8932 data3 = malloc (pagesize);
8933 if (!data3)
8934 exit (1);
8935 if (read (fd, data3, pagesize) != pagesize)
8936 exit (1);
8937 for (i = 0; i < pagesize; ++i)
8938 if (*(data + i) != *(data3 + i))
8939 exit (1);
8940 close (fd);
8941 unlink ("conftestmmap");
8942 exit (0);
8945 if { (eval echo configure:8946: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8946 then
8947 ac_cv_func_mmap_fixed_mapped=yes
8948 else
8949 echo "configure: failed program was:" >&5
8950 cat conftest.$ac_ext >&5
8951 rm -fr conftest*
8952 ac_cv_func_mmap_fixed_mapped=no
8954 rm -fr conftest*
8959 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
8960 if test $ac_cv_func_mmap_fixed_mapped = yes; then
8961 cat >>confdefs.h <<\EOF
8962 #define HAVE_MMAP 1
8967 for ac_header in argz.h limits.h locale.h nl_types.h malloc.h string.h \
8968 unistd.h sys/param.h
8970 ac_ac_Header=`echo "ac_cv_header_$ac_header" | $ac_tr_sh`
8971 echo $ac_n "checking for $ac_header... $ac_c" 1>&6
8972 echo "configure:8973: checking for $ac_header" 1>&5
8973 if eval "test \"\${$ac_ac_Header+set}\" = set"; then
8974 echo $ac_n "(cached) $ac_c" 1>&6
8975 else
8976 cat >conftest.$ac_ext <<EOF
8977 #line 8978 "configure"
8978 #include "confdefs.h"
8979 #include <$ac_header>
8982 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8983 { (eval echo configure:8984: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8984 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
8985 if test -z "$ac_err"; then
8986 rm -rf conftest*
8987 eval "$ac_ac_Header=yes"
8988 else
8989 echo "$ac_err" >&5
8990 echo "configure: failed program was:" >&5
8991 cat conftest.$ac_ext >&5
8992 rm -rf conftest*
8993 eval "$ac_ac_Header=no"
8995 rm -f conftest*
8997 echo "$ac_t""`eval echo '${'$ac_ac_Header'}'`" 1>&6
8998 if test `eval echo '${'$ac_ac_Header'}'` = yes; then
8999 cat >>confdefs.h <<EOF
9000 #define `echo "HAVE_$ac_header" | $ac_tr_cpp` 1
9004 done
9006 for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
9007 strdup __argz_count __argz_stringify __argz_next
9009 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
9010 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
9011 echo "configure:9012: checking for $ac_func" 1>&5
9012 if eval "test \"\${$ac_ac_var+set}\" = set"; then
9013 echo $ac_n "(cached) $ac_c" 1>&6
9014 else
9015 cat >conftest.$ac_ext <<EOF
9016 #line 9017 "configure"
9017 #include "confdefs.h"
9018 /* System header to define __stub macros and hopefully few prototypes,
9019 which can conflict with char $ac_func(); below. */
9020 #include <assert.h>
9021 /* Override any gcc2 internal prototype to avoid an error. */
9022 /* We use char because int might match the return type of a gcc2
9023 builtin and then its argument prototype would still apply. */
9024 char $ac_func();
9025 char (*f)();
9028 main()
9031 /* The GNU C library defines this for functions which it implements
9032 to always fail with ENOSYS. Some functions are actually named
9033 something starting with __ and the normal name is an alias. */
9034 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9035 choke me
9036 #else
9037 f = $ac_func;
9038 #endif
9041 return 0;
9044 if { (eval echo configure:9045: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9045 rm -rf conftest*
9046 eval "$ac_ac_var=yes"
9047 else
9048 echo "configure: failed program was:" >&5
9049 cat conftest.$ac_ext >&5
9050 rm -rf conftest*
9051 eval "$ac_ac_var=no"
9053 rm -f conftest*
9056 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
9057 if test `eval echo '${'$ac_ac_var'}'` = yes; then
9058 cat >>confdefs.h <<EOF
9059 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
9063 done
9065 if test "${ac_cv_func_stpcpy+set}" != "set"; then
9066 for ac_func in stpcpy
9068 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
9069 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
9070 echo "configure:9071: checking for $ac_func" 1>&5
9071 if eval "test \"\${$ac_ac_var+set}\" = set"; then
9072 echo $ac_n "(cached) $ac_c" 1>&6
9073 else
9074 cat >conftest.$ac_ext <<EOF
9075 #line 9076 "configure"
9076 #include "confdefs.h"
9077 /* System header to define __stub macros and hopefully few prototypes,
9078 which can conflict with char $ac_func(); below. */
9079 #include <assert.h>
9080 /* Override any gcc2 internal prototype to avoid an error. */
9081 /* We use char because int might match the return type of a gcc2
9082 builtin and then its argument prototype would still apply. */
9083 char $ac_func();
9084 char (*f)();
9087 main()
9090 /* The GNU C library defines this for functions which it implements
9091 to always fail with ENOSYS. Some functions are actually named
9092 something starting with __ and the normal name is an alias. */
9093 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9094 choke me
9095 #else
9096 f = $ac_func;
9097 #endif
9100 return 0;
9103 if { (eval echo configure:9104: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9104 rm -rf conftest*
9105 eval "$ac_ac_var=yes"
9106 else
9107 echo "configure: failed program was:" >&5
9108 cat conftest.$ac_ext >&5
9109 rm -rf conftest*
9110 eval "$ac_ac_var=no"
9112 rm -f conftest*
9115 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
9116 if test `eval echo '${'$ac_ac_var'}'` = yes; then
9117 cat >>confdefs.h <<EOF
9118 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
9122 done
9125 if test "${ac_cv_func_stpcpy}" = "yes"; then
9126 cat >>confdefs.h <<\EOF
9127 #define HAVE_STPCPY 1
9132 if test $ac_cv_header_locale_h = yes; then
9133 echo $ac_n "checking for LC_MESSAGES... $ac_c" 1>&6
9134 echo "configure:9135: checking for LC_MESSAGES" 1>&5
9135 if test "${am_cv_val_LC_MESSAGES+set}" = set; then
9136 echo $ac_n "(cached) $ac_c" 1>&6
9137 else
9138 cat >conftest.$ac_ext <<EOF
9139 #line 9140 "configure"
9140 #include "confdefs.h"
9141 #include <locale.h>
9143 main()
9145 return LC_MESSAGES
9147 return 0;
9150 if { (eval echo configure:9151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9151 rm -rf conftest*
9152 am_cv_val_LC_MESSAGES=yes
9153 else
9154 echo "configure: failed program was:" >&5
9155 cat conftest.$ac_ext >&5
9156 rm -rf conftest*
9157 am_cv_val_LC_MESSAGES=no
9159 rm -f conftest*
9162 echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
9163 if test $am_cv_val_LC_MESSAGES = yes; then
9164 cat >>confdefs.h <<\EOF
9165 #define HAVE_LC_MESSAGES 1
9170 echo $ac_n "checking whether NLS is requested... $ac_c" 1>&6
9171 echo "configure:9172: checking whether NLS is requested" 1>&5
9172 # Check whether --enable-nls or --disable-nls was given.
9173 if test "${enable_nls+set}" = set; then
9174 enableval="$enable_nls"
9175 USE_NLS=$enableval
9176 else
9177 USE_NLS=yes
9180 echo "$ac_t""$USE_NLS" 1>&6
9182 USE_INCLUDED_LIBINTL=no
9184 if test "$USE_NLS" = "yes"; then
9185 cat >>confdefs.h <<\EOF
9186 #define ENABLE_NLS 1
9189 echo $ac_n "checking whether included gettext is requested... $ac_c" 1>&6
9190 echo "configure:9191: checking whether included gettext is requested" 1>&5
9191 # Check whether --with-included-gettext or --without-included-gettext was given.
9192 if test "${with_included_gettext+set}" = set; then
9193 withval="$with_included_gettext"
9194 nls_cv_force_use_gnu_gettext=$withval
9195 else
9196 nls_cv_force_use_gnu_gettext=no
9199 echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
9201 nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
9202 if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
9203 nls_cv_header_intl=
9204 nls_cv_header_libgt=
9205 CATOBJEXT=NONE
9207 echo $ac_n "checking for libintl.h... $ac_c" 1>&6
9208 echo "configure:9209: checking for libintl.h" 1>&5
9209 if test "${ac_cv_header_libintl_h+set}" = set; then
9210 echo $ac_n "(cached) $ac_c" 1>&6
9211 else
9212 cat >conftest.$ac_ext <<EOF
9213 #line 9214 "configure"
9214 #include "confdefs.h"
9215 #include <libintl.h>
9218 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
9219 { (eval echo configure:9220: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
9220 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
9221 if test -z "$ac_err"; then
9222 rm -rf conftest*
9223 ac_cv_header_libintl_h=yes
9224 else
9225 echo "$ac_err" >&5
9226 echo "configure: failed program was:" >&5
9227 cat conftest.$ac_ext >&5
9228 rm -rf conftest*
9229 ac_cv_header_libintl_h=no
9231 rm -f conftest*
9233 echo "$ac_t""$ac_cv_header_libintl_h" 1>&6
9234 if test $ac_cv_header_libintl_h = yes; then
9235 echo $ac_n "checking for gettext in libc... $ac_c" 1>&6
9236 echo "configure:9237: checking for gettext in libc" 1>&5
9237 if test "${gt_cv_func_gettext_libc+set}" = set; then
9238 echo $ac_n "(cached) $ac_c" 1>&6
9239 else
9240 cat >conftest.$ac_ext <<EOF
9241 #line 9242 "configure"
9242 #include "confdefs.h"
9243 #include <libintl.h>
9245 main()
9247 return (int) gettext ("")
9249 return 0;
9252 if { (eval echo configure:9253: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9253 rm -rf conftest*
9254 gt_cv_func_gettext_libc=yes
9255 else
9256 echo "configure: failed program was:" >&5
9257 cat conftest.$ac_ext >&5
9258 rm -rf conftest*
9259 gt_cv_func_gettext_libc=no
9261 rm -f conftest*
9264 echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
9266 if test "$gt_cv_func_gettext_libc" != "yes"; then
9267 echo $ac_n "checking for bindtextdomain in -lintl... $ac_c" 1>&6
9268 echo "configure:9269: checking for bindtextdomain in -lintl" 1>&5
9269 if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then
9270 echo $ac_n "(cached) $ac_c" 1>&6
9271 else
9272 ac_save_LIBS="$LIBS"
9273 LIBS="-lintl $LIBS"
9274 cat >conftest.$ac_ext <<EOF
9275 #line 9276 "configure"
9276 #include "confdefs.h"
9277 /* Override any gcc2 internal prototype to avoid an error. */
9278 /* We use char because int might match the return type of a gcc2
9279 builtin and then its argument prototype would still apply. */
9280 char bindtextdomain();
9283 main()
9285 bindtextdomain()
9287 return 0;
9290 if { (eval echo configure:9291: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9291 rm -rf conftest*
9292 ac_cv_lib_intl_bindtextdomain=yes
9293 else
9294 echo "configure: failed program was:" >&5
9295 cat conftest.$ac_ext >&5
9296 rm -rf conftest*
9297 ac_cv_lib_intl_bindtextdomain=no
9299 rm -f conftest*
9301 LIBS="$ac_save_LIBS"
9303 echo "$ac_t""$ac_cv_lib_intl_bindtextdomain" 1>&6
9304 if test $ac_cv_lib_intl_bindtextdomain = yes; then
9305 echo $ac_n "checking for gettext in libintl... $ac_c" 1>&6
9306 echo "configure:9307: checking for gettext in libintl" 1>&5
9307 if test "${gt_cv_func_gettext_libintl+set}" = set; then
9308 echo $ac_n "(cached) $ac_c" 1>&6
9309 else
9310 echo $ac_n "checking for gettext in -lintl... $ac_c" 1>&6
9311 echo "configure:9312: checking for gettext in -lintl" 1>&5
9312 if test "${ac_cv_lib_intl_gettext+set}" = set; then
9313 echo $ac_n "(cached) $ac_c" 1>&6
9314 else
9315 ac_save_LIBS="$LIBS"
9316 LIBS="-lintl $LIBS"
9317 cat >conftest.$ac_ext <<EOF
9318 #line 9319 "configure"
9319 #include "confdefs.h"
9320 /* Override any gcc2 internal prototype to avoid an error. */
9321 /* We use char because int might match the return type of a gcc2
9322 builtin and then its argument prototype would still apply. */
9323 char gettext();
9326 main()
9328 gettext()
9330 return 0;
9333 if { (eval echo configure:9334: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9334 rm -rf conftest*
9335 ac_cv_lib_intl_gettext=yes
9336 else
9337 echo "configure: failed program was:" >&5
9338 cat conftest.$ac_ext >&5
9339 rm -rf conftest*
9340 ac_cv_lib_intl_gettext=no
9342 rm -f conftest*
9344 LIBS="$ac_save_LIBS"
9346 echo "$ac_t""$ac_cv_lib_intl_gettext" 1>&6
9347 if test $ac_cv_lib_intl_gettext = yes; then
9348 gt_cv_func_gettext_libintl=yes
9349 else
9350 gt_cv_func_gettext_libintl=no
9354 echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
9359 if test "$gt_cv_func_gettext_libc" = "yes" \
9360 || test "$gt_cv_func_gettext_libintl" = "yes"; then
9361 cat >>confdefs.h <<\EOF
9362 #define HAVE_GETTEXT 1
9365 # Extract the first word of "msgfmt", so it can be a program name with args.
9366 set dummy msgfmt; ac_word=$2
9367 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9368 echo "configure:9369: checking for $ac_word" 1>&5
9369 if test "${ac_cv_path_MSGFMT+set}" = set; then
9370 echo $ac_n "(cached) $ac_c" 1>&6
9371 else
9372 case "$MSGFMT" in
9374 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
9377 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
9378 for ac_dir in $PATH; do
9379 test -z "$ac_dir" && ac_dir=.
9380 if test -f $ac_dir/$ac_word; then
9381 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
9382 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
9383 break
9386 done
9387 IFS="$ac_save_ifs"
9388 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
9390 esac
9392 MSGFMT="$ac_cv_path_MSGFMT"
9393 if test -n "$MSGFMT"; then
9394 echo "$ac_t""$MSGFMT" 1>&6
9395 else
9396 echo "$ac_t""no" 1>&6
9398 if test "$MSGFMT" != "no"; then
9399 for ac_func in dcgettext
9401 ac_ac_var=`echo "ac_cv_func_$ac_func" | $ac_tr_sh`
9402 echo $ac_n "checking for $ac_func... $ac_c" 1>&6
9403 echo "configure:9404: checking for $ac_func" 1>&5
9404 if eval "test \"\${$ac_ac_var+set}\" = set"; then
9405 echo $ac_n "(cached) $ac_c" 1>&6
9406 else
9407 cat >conftest.$ac_ext <<EOF
9408 #line 9409 "configure"
9409 #include "confdefs.h"
9410 /* System header to define __stub macros and hopefully few prototypes,
9411 which can conflict with char $ac_func(); below. */
9412 #include <assert.h>
9413 /* Override any gcc2 internal prototype to avoid an error. */
9414 /* We use char because int might match the return type of a gcc2
9415 builtin and then its argument prototype would still apply. */
9416 char $ac_func();
9417 char (*f)();
9420 main()
9423 /* The GNU C library defines this for functions which it implements
9424 to always fail with ENOSYS. Some functions are actually named
9425 something starting with __ and the normal name is an alias. */
9426 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9427 choke me
9428 #else
9429 f = $ac_func;
9430 #endif
9433 return 0;
9436 if { (eval echo configure:9437: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9437 rm -rf conftest*
9438 eval "$ac_ac_var=yes"
9439 else
9440 echo "configure: failed program was:" >&5
9441 cat conftest.$ac_ext >&5
9442 rm -rf conftest*
9443 eval "$ac_ac_var=no"
9445 rm -f conftest*
9448 echo "$ac_t""`eval echo '${'$ac_ac_var'}'`" 1>&6
9449 if test `eval echo '${'$ac_ac_var'}'` = yes; then
9450 cat >>confdefs.h <<EOF
9451 #define `echo "HAVE_$ac_func" | $ac_tr_cpp` 1
9455 done
9457 # Extract the first word of "gmsgfmt", so it can be a program name with args.
9458 set dummy gmsgfmt; ac_word=$2
9459 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9460 echo "configure:9461: checking for $ac_word" 1>&5
9461 if test "${ac_cv_path_GMSGFMT+set}" = set; then
9462 echo $ac_n "(cached) $ac_c" 1>&6
9463 else
9464 case "$GMSGFMT" in
9465 /* | ?:/*)
9466 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
9469 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
9470 ac_dummy="$PATH"
9471 for ac_dir in $ac_dummy; do
9472 test -z "$ac_dir" && ac_dir=.
9473 if test -f "$ac_dir/$ac_word"; then
9474 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
9475 break
9477 done
9478 IFS="$ac_save_ifs"
9479 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
9481 esac
9483 GMSGFMT="$ac_cv_path_GMSGFMT"
9484 if test -n "$GMSGFMT"; then
9485 echo "$ac_t""$GMSGFMT" 1>&6
9486 else
9487 echo "$ac_t""no" 1>&6
9490 # Extract the first word of "xgettext", so it can be a program name with args.
9491 set dummy xgettext; ac_word=$2
9492 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9493 echo "configure:9494: checking for $ac_word" 1>&5
9494 if test "${ac_cv_path_XGETTEXT+set}" = set; then
9495 echo $ac_n "(cached) $ac_c" 1>&6
9496 else
9497 case "$XGETTEXT" in
9499 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
9502 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
9503 for ac_dir in $PATH; do
9504 test -z "$ac_dir" && ac_dir=.
9505 if test -f $ac_dir/$ac_word; then
9506 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
9507 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
9508 break
9511 done
9512 IFS="$ac_save_ifs"
9513 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
9515 esac
9517 XGETTEXT="$ac_cv_path_XGETTEXT"
9518 if test -n "$XGETTEXT"; then
9519 echo "$ac_t""$XGETTEXT" 1>&6
9520 else
9521 echo "$ac_t""no" 1>&6
9524 cat >conftest.$ac_ext <<EOF
9525 #line 9526 "configure"
9526 #include "confdefs.h"
9529 main()
9531 extern int _nl_msg_cat_cntr;
9532 return _nl_msg_cat_cntr
9534 return 0;
9537 if { (eval echo configure:9538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9538 rm -rf conftest*
9539 CATOBJEXT=.gmo
9540 DATADIRNAME=share
9541 else
9542 echo "configure: failed program was:" >&5
9543 cat conftest.$ac_ext >&5
9544 rm -rf conftest*
9545 CATOBJEXT=.mo
9546 DATADIRNAME=lib
9548 rm -f conftest*
9550 INSTOBJEXT=.mo
9556 if test "$CATOBJEXT" = "NONE"; then
9557 echo $ac_n "checking whether catgets can be used... $ac_c" 1>&6
9558 echo "configure:9559: checking whether catgets can be used" 1>&5
9559 # Check whether --with-catgets or --without-catgets was given.
9560 if test "${with_catgets+set}" = set; then
9561 withval="$with_catgets"
9562 nls_cv_use_catgets=$withval
9563 else
9564 nls_cv_use_catgets=no
9567 echo "$ac_t""$nls_cv_use_catgets" 1>&6
9569 if test "$nls_cv_use_catgets" = "yes"; then
9570 echo $ac_n "checking for main in -li... $ac_c" 1>&6
9571 echo "configure:9572: checking for main in -li" 1>&5
9572 if test "${ac_cv_lib_i_main+set}" = set; then
9573 echo $ac_n "(cached) $ac_c" 1>&6
9574 else
9575 ac_save_LIBS="$LIBS"
9576 LIBS="-li $LIBS"
9577 cat >conftest.$ac_ext <<EOF
9578 #line 9579 "configure"
9579 #include "confdefs.h"
9582 main()
9584 main()
9586 return 0;
9589 if { (eval echo configure:9590: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9590 rm -rf conftest*
9591 ac_cv_lib_i_main=yes
9592 else
9593 echo "configure: failed program was:" >&5
9594 cat conftest.$ac_ext >&5
9595 rm -rf conftest*
9596 ac_cv_lib_i_main=no
9598 rm -f conftest*
9600 LIBS="$ac_save_LIBS"
9602 echo "$ac_t""$ac_cv_lib_i_main" 1>&6
9603 if test $ac_cv_lib_i_main = yes; then
9604 cat >>confdefs.h <<EOF
9605 #define HAVE_LIBI 1
9608 LIBS="-li $LIBS"
9612 echo $ac_n "checking for catgets... $ac_c" 1>&6
9613 echo "configure:9614: checking for catgets" 1>&5
9614 if test "${ac_cv_func_catgets+set}" = set; then
9615 echo $ac_n "(cached) $ac_c" 1>&6
9616 else
9617 cat >conftest.$ac_ext <<EOF
9618 #line 9619 "configure"
9619 #include "confdefs.h"
9620 /* System header to define __stub macros and hopefully few prototypes,
9621 which can conflict with char catgets(); below. */
9622 #include <assert.h>
9623 /* Override any gcc2 internal prototype to avoid an error. */
9624 /* We use char because int might match the return type of a gcc2
9625 builtin and then its argument prototype would still apply. */
9626 char catgets();
9627 char (*f)();
9630 main()
9633 /* The GNU C library defines this for functions which it implements
9634 to always fail with ENOSYS. Some functions are actually named
9635 something starting with __ and the normal name is an alias. */
9636 #if defined (__stub_catgets) || defined (__stub___catgets)
9637 choke me
9638 #else
9639 f = catgets;
9640 #endif
9643 return 0;
9646 if { (eval echo configure:9647: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9647 rm -rf conftest*
9648 ac_cv_func_catgets=yes
9649 else
9650 echo "configure: failed program was:" >&5
9651 cat conftest.$ac_ext >&5
9652 rm -rf conftest*
9653 ac_cv_func_catgets=no
9655 rm -f conftest*
9658 echo "$ac_t""$ac_cv_func_catgets" 1>&6
9659 if test $ac_cv_func_catgets = yes; then
9660 cat >>confdefs.h <<\EOF
9661 #define HAVE_CATGETS 1
9664 INTLOBJS="\$(CATOBJS)"
9665 # Extract the first word of "gencat", so it can be a program name with args.
9666 set dummy gencat; ac_word=$2
9667 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9668 echo "configure:9669: checking for $ac_word" 1>&5
9669 if test "${ac_cv_path_GENCAT+set}" = set; then
9670 echo $ac_n "(cached) $ac_c" 1>&6
9671 else
9672 case "$GENCAT" in
9673 /* | ?:/*)
9674 ac_cv_path_GENCAT="$GENCAT" # Let the user override the test with a path.
9677 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
9678 ac_dummy="$PATH"
9679 for ac_dir in $ac_dummy; do
9680 test -z "$ac_dir" && ac_dir=.
9681 if test -f "$ac_dir/$ac_word"; then
9682 ac_cv_path_GENCAT="$ac_dir/$ac_word"
9683 break
9685 done
9686 IFS="$ac_save_ifs"
9687 test -z "$ac_cv_path_GENCAT" && ac_cv_path_GENCAT="no"
9689 esac
9691 GENCAT="$ac_cv_path_GENCAT"
9692 if test -n "$GENCAT"; then
9693 echo "$ac_t""$GENCAT" 1>&6
9694 else
9695 echo "$ac_t""no" 1>&6
9697 if test "$GENCAT" != "no"; then
9698 # Extract the first word of "gmsgfmt", so it can be a program name with args.
9699 set dummy gmsgfmt; ac_word=$2
9700 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9701 echo "configure:9702: checking for $ac_word" 1>&5
9702 if test "${ac_cv_path_GMSGFMT+set}" = set; then
9703 echo $ac_n "(cached) $ac_c" 1>&6
9704 else
9705 case "$GMSGFMT" in
9706 /* | ?:/*)
9707 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
9710 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
9711 ac_dummy="$PATH"
9712 for ac_dir in $ac_dummy; do
9713 test -z "$ac_dir" && ac_dir=.
9714 if test -f "$ac_dir/$ac_word"; then
9715 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
9716 break
9718 done
9719 IFS="$ac_save_ifs"
9720 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="no"
9722 esac
9724 GMSGFMT="$ac_cv_path_GMSGFMT"
9725 if test -n "$GMSGFMT"; then
9726 echo "$ac_t""$GMSGFMT" 1>&6
9727 else
9728 echo "$ac_t""no" 1>&6
9731 if test "$GMSGFMT" = "no"; then
9732 # Extract the first word of "msgfmt", so it can be a program name with args.
9733 set dummy msgfmt; ac_word=$2
9734 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9735 echo "configure:9736: checking for $ac_word" 1>&5
9736 if test "${ac_cv_path_GMSGFMT+set}" = set; then
9737 echo $ac_n "(cached) $ac_c" 1>&6
9738 else
9739 case "$GMSGFMT" in
9741 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
9744 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
9745 for ac_dir in $PATH; do
9746 test -z "$ac_dir" && ac_dir=.
9747 if test -f $ac_dir/$ac_word; then
9748 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
9749 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
9750 break
9753 done
9754 IFS="$ac_save_ifs"
9755 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="no"
9757 esac
9759 GMSGFMT="$ac_cv_path_GMSGFMT"
9760 if test -n "$GMSGFMT"; then
9761 echo "$ac_t""$GMSGFMT" 1>&6
9762 else
9763 echo "$ac_t""no" 1>&6
9767 # Extract the first word of "xgettext", so it can be a program name with args.
9768 set dummy xgettext; ac_word=$2
9769 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9770 echo "configure:9771: checking for $ac_word" 1>&5
9771 if test "${ac_cv_path_XGETTEXT+set}" = set; then
9772 echo $ac_n "(cached) $ac_c" 1>&6
9773 else
9774 case "$XGETTEXT" in
9776 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
9779 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
9780 for ac_dir in $PATH; do
9781 test -z "$ac_dir" && ac_dir=.
9782 if test -f $ac_dir/$ac_word; then
9783 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
9784 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
9785 break
9788 done
9789 IFS="$ac_save_ifs"
9790 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
9792 esac
9794 XGETTEXT="$ac_cv_path_XGETTEXT"
9795 if test -n "$XGETTEXT"; then
9796 echo "$ac_t""$XGETTEXT" 1>&6
9797 else
9798 echo "$ac_t""no" 1>&6
9801 USE_INCLUDED_LIBINTL=yes
9802 CATOBJEXT=.cat
9803 INSTOBJEXT=.cat
9804 DATADIRNAME=lib
9805 INTLDEPS='$(top_builddir)/intl/libintl.a'
9806 INTLLIBS=$INTLDEPS
9807 LIBS=`echo $LIBS | sed -e 's/-lintl//'`
9808 nls_cv_header_intl=intl/libintl.h
9809 nls_cv_header_libgt=intl/libgettext.h
9816 if test "$CATOBJEXT" = "NONE"; then
9817 nls_cv_use_gnu_gettext=yes
9821 if test "$nls_cv_use_gnu_gettext" = "yes"; then
9822 INTLOBJS="\$(GETTOBJS)"
9823 # Extract the first word of "msgfmt", so it can be a program name with args.
9824 set dummy msgfmt; ac_word=$2
9825 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9826 echo "configure:9827: checking for $ac_word" 1>&5
9827 if test "${ac_cv_path_MSGFMT+set}" = set; then
9828 echo $ac_n "(cached) $ac_c" 1>&6
9829 else
9830 case "$MSGFMT" in
9832 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
9835 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
9836 for ac_dir in $PATH; do
9837 test -z "$ac_dir" && ac_dir=.
9838 if test -f $ac_dir/$ac_word; then
9839 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
9840 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
9841 break
9844 done
9845 IFS="$ac_save_ifs"
9846 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
9848 esac
9850 MSGFMT="$ac_cv_path_MSGFMT"
9851 if test -n "$MSGFMT"; then
9852 echo "$ac_t""$MSGFMT" 1>&6
9853 else
9854 echo "$ac_t""no" 1>&6
9857 # Extract the first word of "gmsgfmt", so it can be a program name with args.
9858 set dummy gmsgfmt; ac_word=$2
9859 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9860 echo "configure:9861: checking for $ac_word" 1>&5
9861 if test "${ac_cv_path_GMSGFMT+set}" = set; then
9862 echo $ac_n "(cached) $ac_c" 1>&6
9863 else
9864 case "$GMSGFMT" in
9865 /* | ?:/*)
9866 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
9869 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
9870 ac_dummy="$PATH"
9871 for ac_dir in $ac_dummy; do
9872 test -z "$ac_dir" && ac_dir=.
9873 if test -f "$ac_dir/$ac_word"; then
9874 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
9875 break
9877 done
9878 IFS="$ac_save_ifs"
9879 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
9881 esac
9883 GMSGFMT="$ac_cv_path_GMSGFMT"
9884 if test -n "$GMSGFMT"; then
9885 echo "$ac_t""$GMSGFMT" 1>&6
9886 else
9887 echo "$ac_t""no" 1>&6
9890 # Extract the first word of "xgettext", so it can be a program name with args.
9891 set dummy xgettext; ac_word=$2
9892 echo $ac_n "checking for $ac_word... $ac_c" 1>&6
9893 echo "configure:9894: checking for $ac_word" 1>&5
9894 if test "${ac_cv_path_XGETTEXT+set}" = set; then
9895 echo $ac_n "(cached) $ac_c" 1>&6
9896 else
9897 case "$XGETTEXT" in
9899 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
9902 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
9903 for ac_dir in $PATH; do
9904 test -z "$ac_dir" && ac_dir=.
9905 if test -f $ac_dir/$ac_word; then
9906 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
9907 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
9908 break
9911 done
9912 IFS="$ac_save_ifs"
9913 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
9915 esac
9917 XGETTEXT="$ac_cv_path_XGETTEXT"
9918 if test -n "$XGETTEXT"; then
9919 echo "$ac_t""$XGETTEXT" 1>&6
9920 else
9921 echo "$ac_t""no" 1>&6
9924 USE_INCLUDED_LIBINTL=yes
9925 CATOBJEXT=.gmo
9926 INSTOBJEXT=.mo
9927 DATADIRNAME=share
9928 INTLDEPS='$(top_builddir)/intl/libintl.a'
9929 INTLLIBS=$INTLDEPS
9930 LIBS=`echo $LIBS | sed -e 's/-lintl//'`
9931 nls_cv_header_intl=intl/libintl.h
9932 nls_cv_header_libgt=intl/libgettext.h
9935 if test "$XGETTEXT" != ":"; then
9936 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
9938 else
9939 echo "$ac_t""found xgettext program is not GNU xgettext; ignore it" 1>&6
9940 XGETTEXT=":"
9944 # We need to process the po/ directory.
9945 POSUB=po
9946 else
9947 DATADIRNAME=share
9948 nls_cv_header_intl=intl/libintl.h
9949 nls_cv_header_libgt=intl/libgettext.h
9951 ac_sources="$nls_cv_header_libgt"
9952 ac_dests="$nls_cv_header_intl"
9953 while test -n "$ac_sources"; do
9954 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
9955 set $ac_sources; ac_source=$1; shift; ac_sources=$*
9956 ac_config_links_1="$ac_config_links_1 $ac_dest:$ac_source"
9957 done
9959 # If this is used in GNU gettext we have to set USE_NLS to `yes'
9960 # because some of the sources are only built for this goal.
9961 if test "$PACKAGE" = gettext; then
9962 USE_NLS=yes
9963 USE_INCLUDED_LIBINTL=yes
9966 for lang in $ALL_LINGUAS; do
9967 GMOFILES="$GMOFILES $lang.gmo"
9968 POFILES="$POFILES $lang.po"
9969 done
9971 if test "x$CATOBJEXT" != "x"; then
9972 if test "x$ALL_LINGUAS" = "x"; then
9973 LINGUAS=
9974 else
9975 echo $ac_n "checking for catalogs to be installed... $ac_c" 1>&6
9976 echo "configure:9977: checking for catalogs to be installed" 1>&5
9977 NEW_LINGUAS=
9978 for lang in ${LINGUAS=$ALL_LINGUAS}; do
9979 case "$ALL_LINGUAS" in
9980 *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
9981 esac
9982 done
9983 LINGUAS=$NEW_LINGUAS
9984 echo "$ac_t""$LINGUAS" 1>&6
9987 if test -n "$LINGUAS"; then
9988 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
9992 if test $ac_cv_header_locale_h = yes; then
9993 INCLUDE_LOCALE_H="#include <locale.h>"
9994 else
9995 INCLUDE_LOCALE_H="\
9996 /* The system does not provide the header <locale.h>. Take care yourself. */"
9999 test -d intl || mkdir intl
10000 if test "$CATOBJEXT" = ".cat"; then
10001 echo $ac_n "checking for linux/version.h... $ac_c" 1>&6
10002 echo "configure:10003: checking for linux/version.h" 1>&5
10003 if test "${ac_cv_header_linux_version_h+set}" = set; then
10004 echo $ac_n "(cached) $ac_c" 1>&6
10005 else
10006 cat >conftest.$ac_ext <<EOF
10007 #line 10008 "configure"
10008 #include "confdefs.h"
10009 #include <linux/version.h>
10012 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
10013 { (eval echo configure:10014: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
10014 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
10015 if test -z "$ac_err"; then
10016 rm -rf conftest*
10017 ac_cv_header_linux_version_h=yes
10018 else
10019 echo "$ac_err" >&5
10020 echo "configure: failed program was:" >&5
10021 cat conftest.$ac_ext >&5
10022 rm -rf conftest*
10023 ac_cv_header_linux_version_h=no
10025 rm -f conftest*
10027 echo "$ac_t""$ac_cv_header_linux_version_h" 1>&6
10028 if test $ac_cv_header_linux_version_h = yes; then
10029 msgformat=linux
10030 else
10031 msgformat=xopen
10034 sed -e '/^#/d' $srcdir/intl/$msgformat-msg.sed > intl/po2msg.sed
10036 sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
10037 $srcdir/intl/po2tbl.sed.in > intl/po2tbl.sed
10039 if test "$PACKAGE" = "gettext"; then
10040 GT_NO="#NO#"
10041 GT_YES=
10042 else
10043 GT_NO=
10044 GT_YES="#YES#"
10047 MKINSTALLDIRS=
10048 if test -n "$ac_aux_dir"; then
10049 MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
10051 if test -z "$MKINSTALLDIRS"; then
10052 MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
10057 test -d po || mkdir po
10058 if test "x$srcdir" != "x."; then
10059 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
10060 posrcprefix="$srcdir/"
10061 else
10062 posrcprefix="../$srcdir/"
10064 else
10065 posrcprefix="../"
10067 rm -f po/POTFILES
10068 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
10069 < $srcdir/po/POTFILES.in > po/POTFILES
10071 # This is necessary so that .o files in LIBOBJS are also built via
10072 # the ANSI2KNR-filtering rules.
10073 LIBOBJS=`echo $LIBOBJS|sed 's/\.o /\$U.o /g;s/\.o$/\$U.o/'`
10074 trap '' 1 2 15
10075 cat >confcache <<\EOF
10076 # This file is a shell script that caches the results of configure
10077 # tests run on this system so they can be shared between configure
10078 # scripts and configure runs. It is not useful on other systems.
10079 # If it contains results you don't want to keep, you may remove or edit it.
10081 # By default, configure uses ./config.cache as the cache file,
10082 # creating it if it does not exist already. You can give configure
10083 # the --cache-file=FILE option to use a different cache file; that is
10084 # what configure does when it calls configure scripts in
10085 # subdirectories, so they share the cache.
10086 # Giving --cache-file=/dev/null disables caching, for debugging configure.
10087 # config.status only pays attention to the cache file if you give it the
10088 # --recheck option to rerun configure.
10091 # The following way of writing the cache mishandles newlines in values,
10092 # but we know of no workaround that is simple, portable, and efficient.
10093 # So, don't put newlines in cache variables' values.
10094 # Ultrix sh set writes to stderr and can't be redirected directly,
10095 # and sets the high bit in the cache file unless we assign to the vars.
10096 (set) 2>&1 |
10097 case `(ac_space=' '; set | grep ac_space) 2>&1` in
10098 *ac_space=\ *)
10099 # `set' does not quote correctly, so add quotes (double-quote substitution
10100 # turns \\\\ into \\, and sed turns \\ into \).
10101 sed -n \
10102 -e "s/'/'\\\\''/g" \
10103 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
10106 # `set' quotes correctly as required by POSIX, so do not add quotes.
10107 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
10109 esac >>confcache
10110 if cmp -s $cache_file confcache; then :; else
10111 if test -w $cache_file; then
10112 echo "updating cache $cache_file"
10113 cat confcache >$cache_file
10114 else
10115 echo "not updating unwritable cache $cache_file"
10118 rm -f confcache
10120 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
10122 test "x$prefix" = xNONE && prefix=$ac_default_prefix
10123 # Let make expand exec_prefix.
10124 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
10126 # Any assignment to VPATH causes Sun make to only execute
10127 # the first set of double-colon rules, so remove it if not needed.
10128 # If there is a colon in the path, we need to keep it.
10129 if test "x$srcdir" = x.; then
10130 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
10133 DEFS=-DHAVE_CONFIG_H
10135 : ${CONFIG_STATUS=./config.status}
10136 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
10137 echo creating $CONFIG_STATUS
10138 cat >$CONFIG_STATUS <<EOF
10139 #! /bin/sh
10140 # Generated automatically by configure.
10141 # Run this file to recreate the current configuration.
10142 # This directory was configured as follows,
10143 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
10145 # $0 $ac_configure_args
10147 # Compiler output produced by configure, useful for debugging
10148 # configure, is in ./config.log if it exists.
10150 # Files that config.status was made for.
10151 config_files="\\
10152 Makefile lib/Makefile find/Makefile find/testsuite/Makefile xargs/Makefile
10153 xargs/testsuite/Makefile locate/Makefile intl/Makefile po/Makefile.in
10154 doc/Makefile m4/Makefile"
10155 config_headers="\\
10156 config.h"
10157 config_links="\\
10158 $ac_config_links_1"
10159 config_commands="\\
10160 default-1 default-2 default-3"
10162 ac_cs_usage="\\
10163 \\\`$CONFIG_STATUS' instantiates files from templates according to the
10164 current configuration.
10166 Usage: $CONFIG_STATUS [OPTIONS] FILE...
10168 --recheck Update $CONFIG_STATUS by reconfiguring in the same conditions
10169 --version Print the version of Autoconf and exit
10170 --help Display this help and exit
10171 --file=FILE[:TEMPLATE]
10172 Instantiate the configuration file FILE
10173 --header=FILE[:TEMPLATE]
10174 Instantiate the configuration header FILE
10176 Configuration files:
10177 \$config_files
10179 Configuration headers:
10180 \$config_headers
10182 Configuration links:
10183 \$config_links
10185 Configuration commands:
10186 \$config_commands
10188 Report bugs to <bug-autoconf@gnu.org>."
10190 ac_cs_version="\\
10191 $CONFIG_STATUS generated by autoconf version 2.14a.
10192 Configured on host `(hostname || uname -n) 2>/dev/null | sed 1q` by
10193 `echo "$0 $ac_configure_args" | sed 's/[\\"\`\$]/\\\\&/g'`"
10195 # Root of the tmp file names. Use pid to allow concurrent executions.
10196 ac_cs_root=cs\$\$
10197 ac_given_srcdir=$srcdir
10198 ac_given_INSTALL="$INSTALL"
10200 # If no file are specified by the user, then we need to provide default
10201 # value. By we need to know if files were specified by the user.
10202 ac_need_defaults=:
10203 while test \$# != 0
10205 case "\$1" in
10206 --*=*)
10207 ac_option=\`echo "\$1" | sed -e 's/=.*//'\`
10208 ac_optarg=\`echo "\$1" | sed -e 's/[^=]*=//'\`
10209 shift
10210 set dummy "\$ac_option" "\$ac_optarg" \${1+"\$@"}
10211 shift
10213 -*);;
10214 *) # This is not an option, so the user has probably given explicit
10215 # arguments.
10216 ac_need_defaults=false;;
10217 esac
10219 case "\$1" in
10221 # Handling of the options.
10222 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
10223 echo "running \${CONFIG_SHELL-/bin/sh} $0 `echo "$ac_configure_args" | sed 's/[\\"\`\$]/\\\\&/g'` --no-create --no-recursion"
10224 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
10225 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
10226 echo "\$ac_cs_version"; exit 0 ;;
10227 --he | --h)
10228 # Conflict between --help and --header
10229 echo "$CONFIG_STATUS: ambiguous option: \$ac_option
10230 Try \\\`$CONFIG_STATUS --help' for more information."; exit 1 ;;
10231 -help | --help | --hel )
10232 echo "\$ac_cs_usage"; exit 0 ;;
10233 --file | --fil | --fi | --f )
10234 shift
10235 CONFIG_FILES="\$CONFIG_FILES \$1"
10236 ac_need_defaults=false;;
10237 --header | --heade | --head | --hea )
10238 shift
10239 CONFIG_HEADERS="\$CONFIG_FILES \$1"
10240 ac_need_defaults=false;;
10242 # Handling of arguments.
10243 'Makefile' ) CONFIG_FILES="\$CONFIG_FILES Makefile" ;;
10244 'lib/Makefile' ) CONFIG_FILES="\$CONFIG_FILES lib/Makefile" ;;
10245 'find/Makefile' ) CONFIG_FILES="\$CONFIG_FILES find/Makefile" ;;
10246 'find/testsuite/Makefile' ) CONFIG_FILES="\$CONFIG_FILES find/testsuite/Makefile" ;;
10247 'xargs/Makefile' ) CONFIG_FILES="\$CONFIG_FILES xargs/Makefile" ;;
10248 'xargs/testsuite/Makefile' ) CONFIG_FILES="\$CONFIG_FILES xargs/testsuite/Makefile" ;;
10249 'locate/Makefile' ) CONFIG_FILES="\$CONFIG_FILES locate/Makefile" ;;
10250 'intl/Makefile' ) CONFIG_FILES="\$CONFIG_FILES intl/Makefile" ;;
10251 'po/Makefile.in' ) CONFIG_FILES="\$CONFIG_FILES po/Makefile.in" ;;
10252 'doc/Makefile' ) CONFIG_FILES="\$CONFIG_FILES doc/Makefile" ;;
10253 'm4/Makefile' ) CONFIG_FILES="\$CONFIG_FILES m4/Makefile" ;;
10254 '$ac_config_links_1' ) CONFIG_LINKS="\$CONFIG_LINKS $ac_config_links_1" ;;
10255 'default-1' ) CONFIG_COMMANDS="\$CONFIG_COMMANDS default-1" ;;
10256 'default-2' ) CONFIG_COMMANDS="\$CONFIG_COMMANDS default-2" ;;
10257 'default-3' ) CONFIG_COMMANDS="\$CONFIG_COMMANDS default-3" ;;
10258 'config.h' ) CONFIG_HEADERS="\$CONFIG_HEADERS config.h" ;;
10260 # This is an error.
10261 -*) echo "$CONFIG_STATUS: unrecognized option: \$1
10262 Try \\\`$CONFIG_STATUS --help' for more information."; exit 1 ;;
10263 *) echo "$CONFIG_STATUS: invalid argument: \$1"; exit 1 ;;
10264 esac
10265 shift
10266 done
10270 cat >>$CONFIG_STATUS <<\EOF
10271 # If the user did not use the arguments to specify the items to instantiate,
10272 # then the envvar interface is used. Set only those that are not.
10273 if $ac_need_defaults; then
10274 : ${CONFIG_FILES=$config_files}
10275 : ${CONFIG_HEADERS=$config_headers}
10276 : ${CONFIG_LINKS=$config_links}
10277 : ${CONFIG_COMMANDS=$config_commands}
10280 # Trap to remove the temp files.
10281 trap 'rm -fr $ac_cs_root*; exit 1' 1 2 15
10285 cat >>$CONFIG_STATUS <<EOF
10287 # INIT-COMMANDS section.
10290 AMDEP="$AMDEP"
10291 ac_aux_dir="$ac_aux_dir"
10295 cat >>$CONFIG_STATUS <<EOF
10298 # CONFIG_FILES section.
10301 # No need to generate the scripts if there are no CONFIG_FILES.
10302 # This happens for instance when ./config.status config.h
10303 if test -n "\$CONFIG_FILES"; then
10304 # Protect against being on the right side of a sed subst in config.status.
10305 sed 's/%@/@@/; s/@%/@@/; s/%;t t\$/@;t t/; /@;t t\$/s/[\\\\&%]/\\\\&/g;
10306 s/@@/%@/; s/@@/@%/; s/@;t t\$/%;t t/' >\$ac_cs_root.subs <<\\CEOF
10307 s%@SHELL@%$SHELL%;t t
10308 s%@CFLAGS@%$CFLAGS%;t t
10309 s%@CPPFLAGS@%$CPPFLAGS%;t t
10310 s%@CXXFLAGS@%$CXXFLAGS%;t t
10311 s%@FFLAGS@%$FFLAGS%;t t
10312 s%@DEFS@%$DEFS%;t t
10313 s%@LDFLAGS@%$LDFLAGS%;t t
10314 s%@LIBS@%$LIBS%;t t
10315 s%@exec_prefix@%$exec_prefix%;t t
10316 s%@prefix@%$prefix%;t t
10317 s%@program_transform_name@%$program_transform_name%;t t
10318 s%@bindir@%$bindir%;t t
10319 s%@sbindir@%$sbindir%;t t
10320 s%@libexecdir@%$libexecdir%;t t
10321 s%@datadir@%$datadir%;t t
10322 s%@sysconfdir@%$sysconfdir%;t t
10323 s%@sharedstatedir@%$sharedstatedir%;t t
10324 s%@localstatedir@%$localstatedir%;t t
10325 s%@libdir@%$libdir%;t t
10326 s%@includedir@%$includedir%;t t
10327 s%@oldincludedir@%$oldincludedir%;t t
10328 s%@infodir@%$infodir%;t t
10329 s%@mandir@%$mandir%;t t
10330 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%;t t
10331 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%;t t
10332 s%@INSTALL_DATA@%$INSTALL_DATA%;t t
10333 s%@PACKAGE@%$PACKAGE%;t t
10334 s%@VERSION@%$VERSION%;t t
10335 s%@ACLOCAL@%$ACLOCAL%;t t
10336 s%@AUTOCONF@%$AUTOCONF%;t t
10337 s%@AUTOMAKE@%$AUTOMAKE%;t t
10338 s%@AUTOHEADER@%$AUTOHEADER%;t t
10339 s%@MAKEINFO@%$MAKEINFO%;t t
10340 s%@AMTAR@%$AMTAR%;t t
10341 s%@install_sh@%$install_sh%;t t
10342 s%@AWK@%$AWK%;t t
10343 s%@SET_MAKE@%$SET_MAKE%;t t
10344 s%@AMDEP@%$AMDEP%;t t
10345 s%@AMDEPBACKSLASH@%$AMDEPBACKSLASH%;t t
10346 s%@DEPDIR@%$DEPDIR%;t t
10347 s%@INCLUDES@%$INCLUDES%;t t
10348 s%@CC@%$CC%;t t
10349 s%@CPP@%$CPP%;t t
10350 s%@CCDEPMODE@%$CCDEPMODE%;t t
10351 s%@U@%$U%;t t
10352 s%@ANSI2KNR@%$ANSI2KNR%;t t
10353 s%@RANLIB@%$RANLIB%;t t
10354 s%@LIBOBJS@%$LIBOBJS%;t t
10355 s%@GNU_PACKAGE@%$GNU_PACKAGE%;t t
10356 s%@ALLOCA@%$ALLOCA%;t t
10357 s%@USE_NLS@%$USE_NLS%;t t
10358 s%@MSGFMT@%$MSGFMT%;t t
10359 s%@GMSGFMT@%$GMSGFMT%;t t
10360 s%@XGETTEXT@%$XGETTEXT%;t t
10361 s%@GENCAT@%$GENCAT%;t t
10362 s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%;t t
10363 s%@CATALOGS@%$CATALOGS%;t t
10364 s%@CATOBJEXT@%$CATOBJEXT%;t t
10365 s%@DATADIRNAME@%$DATADIRNAME%;t t
10366 s%@GMOFILES@%$GMOFILES%;t t
10367 s%@INSTOBJEXT@%$INSTOBJEXT%;t t
10368 s%@INTLDEPS@%$INTLDEPS%;t t
10369 s%@INTLLIBS@%$INTLLIBS%;t t
10370 s%@INTLOBJS@%$INTLOBJS%;t t
10371 s%@POFILES@%$POFILES%;t t
10372 s%@POSUB@%$POSUB%;t t
10373 s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%;t t
10374 s%@GT_NO@%$GT_NO%;t t
10375 s%@GT_YES@%$GT_YES%;t t
10376 s%@MKINSTALLDIRS@%$MKINSTALLDIRS%;t t
10377 s%@l@%$l%;t t
10378 CEOF
10382 cat >>$CONFIG_STATUS <<\EOF
10383 # Split the substitutions into bite-sized pieces for seds with
10384 # small command number limits, like on Digital OSF/1 and HP-UX.
10385 ac_max_sed_lines=48
10386 ac_sed_frag=1 # Number of current file.
10387 ac_beg=1 # First line for current file.
10388 ac_end=$ac_max_sed_lines # Line after last line for current file.
10389 ac_more_lines=:
10390 ac_sed_cmds=""
10391 while $ac_more_lines; do
10392 if test $ac_beg -gt 1; then
10393 sed "1,${ac_beg}d; ${ac_end}q" $ac_cs_root.subs >$ac_cs_root.sfrag
10394 else
10395 sed "${ac_end}q" $ac_cs_root.subs >$ac_cs_root.sfrag
10397 if test ! -s $ac_cs_root.sfrag; then
10398 ac_more_lines=false
10399 rm -f $ac_cs_root.sfrag
10400 else
10401 # The purpose of the label and of the branching condition is to
10402 # speed up the sed processing (if there are no `@' at all, there
10403 # is no need to browse any of the substitutions).
10404 # These are the two extra sed commands mentioned above.
10405 (echo ':t
10406 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $ac_cs_root.sfrag) >$ac_cs_root.s$ac_sed_frag
10407 if test -z "$ac_sed_cmds"; then
10408 ac_sed_cmds="sed -f $ac_cs_root.s$ac_sed_frag"
10409 else
10410 ac_sed_cmds="$ac_sed_cmds | sed -f $ac_cs_root.s$ac_sed_frag"
10412 ac_sed_frag=`expr $ac_sed_frag + 1`
10413 ac_beg=$ac_end
10414 ac_end=`expr $ac_end + $ac_max_sed_lines`
10416 done
10417 if test -z "$ac_sed_cmds"; then
10418 ac_sed_cmds=cat
10420 fi # test -n "$CONFIG_FILES"
10423 cat >>$CONFIG_STATUS <<\EOF
10424 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
10425 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
10426 case "$ac_file" in
10427 *:*) ac_file_in=`echo "$ac_file" | sed 's%[^:]*:%%'`
10428 ac_file=`echo "$ac_file" | sed 's%:.*%%'` ;;
10429 *) ac_file_in="${ac_file}.in" ;;
10430 esac
10432 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
10434 # Remove last slash and all that follows it. Not all systems have dirname.
10435 ac_dir=`echo "$ac_file" | sed 's%/[^/][^/]*$%%'`
10436 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
10437 # The file is in a subdirectory.
10438 test ! -d "$ac_dir" && mkdir "$ac_dir"
10439 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
10440 # A "../" for each directory in $ac_dir_suffix.
10441 ac_dots=`echo "$ac_dir_suffix" | sed 's%/[^/]*%../%g'`
10442 else
10443 ac_dir_suffix= ac_dots=
10446 case "$ac_given_srcdir" in
10447 .) srcdir=.
10448 if test -z "$ac_dots"; then top_srcdir=.
10449 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
10450 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
10451 *) # Relative path.
10452 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
10453 top_srcdir="$ac_dots$ac_given_srcdir" ;;
10454 esac
10456 case "$ac_given_INSTALL" in
10457 [/$]*) INSTALL="$ac_given_INSTALL" ;;
10458 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
10459 esac
10461 echo creating "$ac_file"
10462 rm -f "$ac_file"
10463 configure_input="Generated automatically from `echo $ac_file_in |
10464 sed 's%.*/%%'` by configure."
10465 case "$ac_file" in
10466 *[Mm]akefile*) ac_comsub="1i\\
10467 # $configure_input" ;;
10468 *) ac_comsub= ;;
10469 esac
10471 # Don't redirect the output to AC_FILE directly: use `mv' so that updating
10472 # is atomic, and doesn't need trapping.
10473 ac_file_inputs=`echo "$ac_file_in" |
10474 sed -e "s%^%$ac_given_srcdir/%;s%:% $ac_given_srcdir/%g"`
10475 for ac_file_input in $ac_file_inputs;
10477 test -f "$ac_file_input" ||
10478 { echo "configure: error: cannot find input file \`$ac_file_input'" 1>&2; exit 1; }
10479 done
10481 cat >>$CONFIG_STATUS <<EOF
10482 sed -e "$ac_comsub
10483 $ac_vpsub
10484 $extrasub
10486 cat >>$CONFIG_STATUS <<\EOF
10488 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
10489 s%@configure_input@%$configure_input%;t t
10490 s%@srcdir@%$srcdir%;t t
10491 s%@top_srcdir@%$top_srcdir%;t t
10492 s%@INSTALL@%$INSTALL%;t t
10493 " $ac_file_inputs | (eval "$ac_sed_cmds") >$ac_cs_root.out
10494 mv $ac_cs_root.out $ac_file
10496 fi; done
10497 rm -f $ac_cs_root.s*
10499 cat >>$CONFIG_STATUS <<\EOF
10502 # CONFIG_HEADER section.
10505 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
10506 # NAME is the cpp macro being defined and VALUE is the value it is being given.
10508 # ac_d sets the value in "#define NAME VALUE" lines.
10509 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
10510 ac_dB='[ ].*$%\1#\2'
10511 ac_dC=' '
10512 ac_dD='%;t'
10513 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
10514 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
10515 ac_uB='$%\1#\2define\3'
10516 ac_uC=' '
10517 ac_uD='%;t'
10519 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
10520 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
10521 case "$ac_file" in
10522 *:*) ac_file_in=`echo "$ac_file" | sed 's%[^:]*:%%'`
10523 ac_file=`echo "$ac_file" | sed 's%:.*%%'` ;;
10524 *) ac_file_in="${ac_file}.in" ;;
10525 esac
10527 echo creating $ac_file
10529 rm -f $ac_cs_root.frag $ac_cs_root.in $ac_cs_root.out
10530 ac_file_inputs=`echo "$ac_file_in" |
10531 sed -e "s%^%$ac_given_srcdir/%;s%:% $ac_given_srcdir/%g"`
10532 for ac_file_input in $ac_file_inputs;
10534 test -f "$ac_file_input" ||
10535 { echo "configure: error: cannot find input file \`$ac_file_input'" 1>&2; exit 1; }
10536 done
10537 # Remove the trailing spaces.
10538 sed -e 's/[ ]*$//' $ac_file_inputs >$ac_cs_root.in
10542 # Transform confdefs.h into two sed scripts, `conftest.defines' and
10543 # `conftest.undefs', that substitutes the proper values into
10544 # config.h.in to produce config.h. The first handles `#define'
10545 # templates, and the second `#undef' templates.
10546 # And first: Protect against being on the right side of a sed subst in
10547 # config.status. Protect against being in an unquoted here document
10548 # in config.status.
10549 rm -f conftest.defines conftest.undefs
10550 cat >$ac_cs_root.hdr <<\EOF
10551 s/[\\&%]/\\&/g
10552 s%[\\$`]%\\&%g
10553 t clear
10554 : clear
10555 s%^[ ]*#[ ]*define[ ][ ]*\(\([^ (][^ (]*\)([^)]*)\)[ ]*\(.*\)$%${ac_dA}\2${ac_dB}\1${ac_dC}\3${ac_dD}%gp
10556 t cleanup
10557 s%^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
10558 : cleanup
10560 # If some macros were called several times there might be several times
10561 # the same #defines, which is useless. Nevertheless, we may not want to
10562 # sort them, since we want the *last* AC_DEFINE to be honored.
10563 uniq confdefs.h | sed -n -f $ac_cs_root.hdr >conftest.defines
10564 sed -e 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
10565 rm -f $ac_cs_root.hdr
10567 # This sed command replaces #undef with comments. This is necessary, for
10568 # example, in the case of _POSIX_SOURCE, which is predefined and required
10569 # on some systems where configure will not decide to define it.
10570 cat >>conftest.undefs <<\EOF
10571 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
10574 # Break up conftest.defines because some shells have a limit on the size
10575 # of here documents, and old seds have small limits too (100 cmds).
10576 echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
10577 echo ' if egrep "^[ ]*#[ ]*define" $ac_cs_root.in >/dev/null; then' >>$CONFIG_STATUS
10578 echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
10579 echo ' :' >>$CONFIG_STATUS
10580 rm -f conftest.tail
10581 while grep . conftest.defines >/dev/null
10583 # Write a limited-size here document to $ac_cs_root.frag.
10584 echo ' cat >$ac_cs_root.frag <<CEOF' >>$CONFIG_STATUS
10585 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
10586 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
10587 echo 'CEOF
10588 sed -f $ac_cs_root.frag $ac_cs_root.in >$ac_cs_root.out
10589 rm -f $ac_cs_root.in
10590 mv $ac_cs_root.out $ac_cs_root.in
10591 ' >>$CONFIG_STATUS
10592 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
10593 rm -f conftest.defines
10594 mv conftest.tail conftest.defines
10595 done
10596 rm -f conftest.defines
10597 echo ' fi # egrep' >>$CONFIG_STATUS
10598 echo >>$CONFIG_STATUS
10600 # Break up conftest.undefs because some shells have a limit on the size
10601 # of here documents, and old seds have small limits too (100 cmds).
10602 echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
10603 rm -f conftest.tail
10604 while grep . conftest.undefs >/dev/null
10606 # Write a limited-size here document to $ac_cs_root.frag.
10607 echo ' cat >$ac_cs_root.frag <<CEOF' >>$CONFIG_STATUS
10608 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
10609 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
10610 echo 'CEOF
10611 sed -f $ac_cs_root.frag $ac_cs_root.in >$ac_cs_root.out
10612 rm -f $ac_cs_root.in
10613 mv $ac_cs_root.out $ac_cs_root.in
10614 ' >>$CONFIG_STATUS
10615 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
10616 rm -f conftest.undefs
10617 mv conftest.tail conftest.undefs
10618 done
10619 rm -f conftest.undefs
10621 cat >>$CONFIG_STATUS <<\EOF
10622 rm -f $ac_cs_root.frag $ac_cs_root.h
10623 echo "/* $ac_file. Generated automatically by configure. */" >$ac_cs_root.h
10624 cat $ac_cs_root.in >>$ac_cs_root.h
10625 rm -f $ac_cs_root.in
10626 if cmp -s $ac_file $ac_cs_root.h 2>/dev/null; then
10627 echo "$ac_file is unchanged"
10628 rm -f $ac_cs_root.h
10629 else
10630 # Remove last slash and all that follows it. Not all systems have dirname.
10631 ac_dir=`echo "$ac_file" | sed 's%/[^/][^/]*$%%'`
10632 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
10633 # The file is in a subdirectory.
10634 test ! -d "$ac_dir" && mkdir "$ac_dir"
10636 rm -f $ac_file
10637 mv $ac_cs_root.h $ac_file
10639 fi; done
10641 cat >>$CONFIG_STATUS <<\EOF
10644 # CONFIG_LINKS section.
10646 srcdir=$ac_given_srcdir
10648 for ac_file in : $CONFIG_LINKS; do if test "x$ac_file" != x:; then
10649 ac_dest=`echo "$ac_file" | sed 's%:.*%%'`
10650 ac_source=`echo "$ac_file" | sed 's%[^:]*:%%'`
10652 echo "linking $srcdir/$ac_source to $ac_dest"
10654 if test ! -r $srcdir/$ac_source; then
10655 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
10657 rm -f $ac_dest
10659 # Make relative symlinks.
10660 # Remove last slash and all that follows it. Not all systems have dirname.
10661 ac_dest_dir=`echo $ac_dest | sed 's%/[^/][^/]*$%%'`
10662 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
10663 # The dest file is in a subdirectory.
10664 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
10665 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
10666 # A "../" for each directory in $ac_dest_dir_suffix.
10667 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
10668 else
10669 ac_dest_dir_suffix= ac_dots=
10672 case "$srcdir" in
10673 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
10674 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
10675 esac
10677 # Make a symlink if possible; otherwise try a hard link.
10678 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
10679 ln $srcdir/$ac_source $ac_dest; then :
10680 else
10681 { echo "configure: error: cannot link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
10683 fi; done
10685 cat >>$CONFIG_STATUS <<\EOF
10688 # CONFIG_COMMANDS section.
10690 for ac_file in .. $CONFIG_COMMANDS; do if test "x$ac_file" != x..; then
10691 ac_dest=`echo "$ac_file" | sed 's%:.*%%'`
10692 ac_source=`echo "$ac_file" | sed 's%[^:]*:%%'`
10694 case "$ac_dest" in
10695 default-1 ) test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h ;;
10696 default-2 )
10697 test x"$AMDEP" != x"" ||
10698 for mf in $CONFIG_FILES; do
10699 case "$mf" in
10700 Makefile) dirpart=.;;
10701 */Makefile) dirpart=`echo "$mf" | sed -e 's|/[^/]*$||'`;;
10702 *) continue;;
10703 esac
10704 grep '^DEP_FILES *= *[^ #]' < "$mf" > /dev/null || continue
10705 # Extract the definition of DEP_FILES from the Makefile without
10706 # running `make'.
10707 DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
10708 test -z "$DEPDIR" && continue
10709 # When using ansi2knr, U may be empty or an underscore; expand it
10710 U=`sed -n -e '/^U = / s///p' < "$mf"`
10711 test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
10712 # We invoke sed twice because it is the simplest approach to
10713 # changing $(DEPDIR) to its actual value in the expansion.
10714 for file in `sed -n -e '
10715 /^DEP_FILES = .*\\\\$/ {
10716 s/^DEP_FILES = //
10717 :loop
10718 s/\\\\$//
10721 /\\\\$/ b loop
10724 /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
10725 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
10726 # Make sure the directory exists.
10727 test -f "$dirpart/$file" && continue
10728 fdir=`echo "$file" | sed -e 's|/[^/]*$||'`
10729 $ac_aux_dir/mkinstalldirs "$dirpart/$fdir" > /dev/null 2>&1
10730 # echo "creating $dirpart/$file"
10731 echo '# dummy' > "$dirpart/$file"
10732 done
10733 done
10735 default-3 ) case "$CONFIG_FILES" in *po/Makefile.in*)
10736 sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
10737 esac ;;
10738 esac
10739 fi;done
10742 cat >>$CONFIG_STATUS <<\EOF
10745 # CONFIG_COMMANDS section.
10748 exit 0
10750 chmod +x $CONFIG_STATUS
10751 rm -fr confdefs* $ac_clean_files
10752 trap 'exit 1' 1 2 15
10754 test "$no_create" = yes || $SHELL $CONFIG_STATUS || exit 1