Name changes
[privoxy.git] / configure
1 #! /bin/sh
2
3 # From configure.in Revision: 1.45 
4 # Guess values for system-dependent variables and create Makefiles.
5 # Generated automatically using autoconf version 2.13 
6 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
7 #
8 # This configure script is free software; the Free Software Foundation
9 # gives unlimited permission to copy, distribute and modify it.
10
11 # Defaults:
12 ac_help=
13 ac_default_prefix=/usr/local
14 # Any additions from configure.in:
15 ac_help="$ac_help
16   --with-docbook=[yes|no|directory]     
17                            Enable docbook documentation creation 
18                            (default = yes, for gnu and linux)"
19 ac_help="$ac_help
20   --with-db2html=<path/executable>
21                           Set the location of the docbook to html converter
22                           (default = search)"
23 ac_help="$ac_help
24   --with-debug            Enable debug mode"
25 ac_help="$ac_help
26   --enable-mingw32        Use mingw32 for a Windows GUI"
27 ac_help="$ac_help
28   --disable-pthread       Don't use POSIX threads (pthreads)"
29 ac_help="$ac_help
30   --disable-toggle         Don't support temporary disable"
31 ac_help="$ac_help
32   --disable-force          Don't allow single-page disable"
33 ac_help="$ac_help
34   --disable-fast-redirects Don't support fast redirects"
35 ac_help="$ac_help
36   --disable-killpopup      Never block popups"
37 ac_help="$ac_help
38   --disable-stats          Don't keep statistics"
39 ac_help="$ac_help
40   --disable-ie-images      Don't auto-detect whether a request from MS Internet
41                            Explorer is for an image or HTML."
42 ac_help="$ac_help
43   --disable-image-blocking Don't try to figure out whether a request is 
44                            for an image or HTML - assume HTML."
45 ac_help="$ac_help
46   --disable-acl-files      Prevents the use of ACL files to control access to
47                            the proxy by IP address."
48 ac_help="$ac_help
49   --disable-trust-files    Prevents the use of trust files."
50 ac_help="$ac_help
51   --disable-jar-files      Prevents the use of jar files to capture cookies."
52 ac_help="$ac_help
53   --disable-editor         Prevents the use of the web-based actions file
54                            editor and web-based temporary disable setting."
55 ac_help="$ac_help
56   --enable-no-gifs         Use politically correct PNG format instead of GIF
57                            for built-in images. May not work with all browsers."
58 ac_help="$ac_help
59   --enable-regex-matching=pcre  Use perl-compatible regex for actionsfile
60                                 pattern matching (default)
61   --enable-regex-matching=gnu   Use gnu style regex for actionsfile pattern
62                                 matching (-> bigger binary)
63   --disable-regex-matching      Don't use regex matching, compare URL
64                                 prefix instead (won't shrink birary)"
65 ac_help="$ac_help
66   --disable-dynamic-pcre        Use the built-in, static pcre, even if
67                                 libpcre is available"
68 ac_help="$ac_help
69   --disable-dynamic-pcrs        Use the built-in, static pcrs, even if
70                                 libpcrs is available"
71
72 # Initialize some variables set by options.
73 # The variables have the same names as the options, with
74 # dashes changed to underlines.
75 build=NONE
76 cache_file=./config.cache
77 exec_prefix=NONE
78 host=NONE
79 no_create=
80 nonopt=NONE
81 no_recursion=
82 prefix=NONE
83 program_prefix=NONE
84 program_suffix=NONE
85 program_transform_name=s,x,x,
86 silent=
87 site=
88 srcdir=
89 target=NONE
90 verbose=
91 x_includes=NONE
92 x_libraries=NONE
93 bindir='${exec_prefix}/bin'
94 sbindir='${exec_prefix}/sbin'
95 libexecdir='${exec_prefix}/libexec'
96 datadir='${prefix}/share'
97 sysconfdir='${prefix}/etc'
98 sharedstatedir='${prefix}/com'
99 localstatedir='${prefix}/var'
100 libdir='${exec_prefix}/lib'
101 includedir='${prefix}/include'
102 oldincludedir='/usr/include'
103 infodir='${prefix}/info'
104 mandir='${prefix}/man'
105
106 # Initialize some other variables.
107 subdirs=
108 MFLAGS= MAKEFLAGS=
109 SHELL=${CONFIG_SHELL-/bin/sh}
110 # Maximum number of lines to put in a shell here document.
111 ac_max_here_lines=12
112
113 ac_prev=
114 for ac_option
115 do
116
117   # If the previous option needs an argument, assign it.
118   if test -n "$ac_prev"; then
119     eval "$ac_prev=\$ac_option"
120     ac_prev=
121     continue
122   fi
123
124   case "$ac_option" in
125   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
126   *) ac_optarg= ;;
127   esac
128
129   # Accept the important Cygnus configure options, so we can diagnose typos.
130
131   case "$ac_option" in
132
133   -bindir | --bindir | --bindi | --bind | --bin | --bi)
134     ac_prev=bindir ;;
135   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
136     bindir="$ac_optarg" ;;
137
138   -build | --build | --buil | --bui | --bu)
139     ac_prev=build ;;
140   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
141     build="$ac_optarg" ;;
142
143   -cache-file | --cache-file | --cache-fil | --cache-fi \
144   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
145     ac_prev=cache_file ;;
146   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
147   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
148     cache_file="$ac_optarg" ;;
149
150   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
151     ac_prev=datadir ;;
152   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
153   | --da=*)
154     datadir="$ac_optarg" ;;
155
156   -disable-* | --disable-*)
157     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
158     # Reject names that are not valid shell variable names.
159     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
160       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
161     fi
162     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
163     eval "enable_${ac_feature}=no" ;;
164
165   -enable-* | --enable-*)
166     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
167     # Reject names that are not valid shell variable names.
168     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
169       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
170     fi
171     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
172     case "$ac_option" in
173       *=*) ;;
174       *) ac_optarg=yes ;;
175     esac
176     eval "enable_${ac_feature}='$ac_optarg'" ;;
177
178   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
179   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
180   | --exec | --exe | --ex)
181     ac_prev=exec_prefix ;;
182   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
183   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
184   | --exec=* | --exe=* | --ex=*)
185     exec_prefix="$ac_optarg" ;;
186
187   -gas | --gas | --ga | --g)
188     # Obsolete; use --with-gas.
189     with_gas=yes ;;
190
191   -help | --help | --hel | --he)
192     # Omit some internal or obsolete options to make the list less imposing.
193     # This message is too long to be a string in the A/UX 3.1 sh.
194     cat << EOF
195 Usage: configure [options] [host]
196 Options: [defaults in brackets after descriptions]
197 Configuration:
198   --cache-file=FILE       cache test results in FILE
199   --help                  print this message
200   --no-create             do not create output files
201   --quiet, --silent       do not print \`checking...' messages
202   --version               print the version of autoconf that created configure
203 Directory and file names:
204   --prefix=PREFIX         install architecture-independent files in PREFIX
205                           [$ac_default_prefix]
206   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
207                           [same as prefix]
208   --bindir=DIR            user executables in DIR [EPREFIX/bin]
209   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
210   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
211   --datadir=DIR           read-only architecture-independent data in DIR
212                           [PREFIX/share]
213   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
214   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
215                           [PREFIX/com]
216   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
217   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
218   --includedir=DIR        C header files in DIR [PREFIX/include]
219   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
220   --infodir=DIR           info documentation in DIR [PREFIX/info]
221   --mandir=DIR            man documentation in DIR [PREFIX/man]
222   --srcdir=DIR            find the sources in DIR [configure dir or ..]
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
227 EOF
228     cat << EOF
229 Host type:
230   --build=BUILD           configure for building on BUILD [BUILD=HOST]
231   --host=HOST             configure for HOST [guessed]
232   --target=TARGET         configure for TARGET [TARGET=HOST]
233 Features and packages:
234   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
235   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
236   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
237   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
238   --x-includes=DIR        X include files are in DIR
239   --x-libraries=DIR       X library files are in DIR
240 EOF
241     if test -n "$ac_help"; then
242       echo "--enable and --with options recognized:$ac_help"
243     fi
244     exit 0 ;;
245
246   -host | --host | --hos | --ho)
247     ac_prev=host ;;
248   -host=* | --host=* | --hos=* | --ho=*)
249     host="$ac_optarg" ;;
250
251   -includedir | --includedir | --includedi | --included | --include \
252   | --includ | --inclu | --incl | --inc)
253     ac_prev=includedir ;;
254   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
255   | --includ=* | --inclu=* | --incl=* | --inc=*)
256     includedir="$ac_optarg" ;;
257
258   -infodir | --infodir | --infodi | --infod | --info | --inf)
259     ac_prev=infodir ;;
260   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
261     infodir="$ac_optarg" ;;
262
263   -libdir | --libdir | --libdi | --libd)
264     ac_prev=libdir ;;
265   -libdir=* | --libdir=* | --libdi=* | --libd=*)
266     libdir="$ac_optarg" ;;
267
268   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
269   | --libexe | --libex | --libe)
270     ac_prev=libexecdir ;;
271   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
272   | --libexe=* | --libex=* | --libe=*)
273     libexecdir="$ac_optarg" ;;
274
275   -localstatedir | --localstatedir | --localstatedi | --localstated \
276   | --localstate | --localstat | --localsta | --localst \
277   | --locals | --local | --loca | --loc | --lo)
278     ac_prev=localstatedir ;;
279   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
280   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
281   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
282     localstatedir="$ac_optarg" ;;
283
284   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
285     ac_prev=mandir ;;
286   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
287     mandir="$ac_optarg" ;;
288
289   -nfp | --nfp | --nf)
290     # Obsolete; use --without-fp.
291     with_fp=no ;;
292
293   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
294   | --no-cr | --no-c)
295     no_create=yes ;;
296
297   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
298   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
299     no_recursion=yes ;;
300
301   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
302   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
303   | --oldin | --oldi | --old | --ol | --o)
304     ac_prev=oldincludedir ;;
305   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
306   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
307   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
308     oldincludedir="$ac_optarg" ;;
309
310   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
311     ac_prev=prefix ;;
312   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
313     prefix="$ac_optarg" ;;
314
315   -program-prefix | --program-prefix | --program-prefi | --program-pref \
316   | --program-pre | --program-pr | --program-p)
317     ac_prev=program_prefix ;;
318   -program-prefix=* | --program-prefix=* | --program-prefi=* \
319   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
320     program_prefix="$ac_optarg" ;;
321
322   -program-suffix | --program-suffix | --program-suffi | --program-suff \
323   | --program-suf | --program-su | --program-s)
324     ac_prev=program_suffix ;;
325   -program-suffix=* | --program-suffix=* | --program-suffi=* \
326   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
327     program_suffix="$ac_optarg" ;;
328
329   -program-transform-name | --program-transform-name \
330   | --program-transform-nam | --program-transform-na \
331   | --program-transform-n | --program-transform- \
332   | --program-transform | --program-transfor \
333   | --program-transfo | --program-transf \
334   | --program-trans | --program-tran \
335   | --progr-tra | --program-tr | --program-t)
336     ac_prev=program_transform_name ;;
337   -program-transform-name=* | --program-transform-name=* \
338   | --program-transform-nam=* | --program-transform-na=* \
339   | --program-transform-n=* | --program-transform-=* \
340   | --program-transform=* | --program-transfor=* \
341   | --program-transfo=* | --program-transf=* \
342   | --program-trans=* | --program-tran=* \
343   | --progr-tra=* | --program-tr=* | --program-t=*)
344     program_transform_name="$ac_optarg" ;;
345
346   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
347   | -silent | --silent | --silen | --sile | --sil)
348     silent=yes ;;
349
350   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
351     ac_prev=sbindir ;;
352   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
353   | --sbi=* | --sb=*)
354     sbindir="$ac_optarg" ;;
355
356   -sharedstatedir | --sharedstatedir | --sharedstatedi \
357   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
358   | --sharedst | --shareds | --shared | --share | --shar \
359   | --sha | --sh)
360     ac_prev=sharedstatedir ;;
361   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
362   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
363   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
364   | --sha=* | --sh=*)
365     sharedstatedir="$ac_optarg" ;;
366
367   -site | --site | --sit)
368     ac_prev=site ;;
369   -site=* | --site=* | --sit=*)
370     site="$ac_optarg" ;;
371
372   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
373     ac_prev=srcdir ;;
374   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
375     srcdir="$ac_optarg" ;;
376
377   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
378   | --syscon | --sysco | --sysc | --sys | --sy)
379     ac_prev=sysconfdir ;;
380   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
381   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
382     sysconfdir="$ac_optarg" ;;
383
384   -target | --target | --targe | --targ | --tar | --ta | --t)
385     ac_prev=target ;;
386   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
387     target="$ac_optarg" ;;
388
389   -v | -verbose | --verbose | --verbos | --verbo | --verb)
390     verbose=yes ;;
391
392   -version | --version | --versio | --versi | --vers)
393     echo "configure generated by autoconf version 2.13"
394     exit 0 ;;
395
396   -with-* | --with-*)
397     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
398     # Reject names that are not valid shell variable names.
399     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
400       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
401     fi
402     ac_package=`echo $ac_package| sed 's/-/_/g'`
403     case "$ac_option" in
404       *=*) ;;
405       *) ac_optarg=yes ;;
406     esac
407     eval "with_${ac_package}='$ac_optarg'" ;;
408
409   -without-* | --without-*)
410     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
411     # Reject names that are not valid shell variable names.
412     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
413       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
414     fi
415     ac_package=`echo $ac_package| sed 's/-/_/g'`
416     eval "with_${ac_package}=no" ;;
417
418   --x)
419     # Obsolete; use --with-x.
420     with_x=yes ;;
421
422   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
423   | --x-incl | --x-inc | --x-in | --x-i)
424     ac_prev=x_includes ;;
425   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
426   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
427     x_includes="$ac_optarg" ;;
428
429   -x-libraries | --x-libraries | --x-librarie | --x-librari \
430   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
431     ac_prev=x_libraries ;;
432   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
433   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
434     x_libraries="$ac_optarg" ;;
435
436   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
437     ;;
438
439   *)
440     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
441       echo "configure: warning: $ac_option: invalid host type" 1>&2
442     fi
443     if test "x$nonopt" != xNONE; then
444       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
445     fi
446     nonopt="$ac_option"
447     ;;
448
449   esac
450 done
451
452 if test -n "$ac_prev"; then
453   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
454 fi
455
456 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
457
458 # File descriptor usage:
459 # 0 standard input
460 # 1 file creation
461 # 2 errors and warnings
462 # 3 some systems may open it to /dev/tty
463 # 4 used on the Kubota Titan
464 # 6 checking for... messages and results
465 # 5 compiler messages saved in config.log
466 if test "$silent" = yes; then
467   exec 6>/dev/null
468 else
469   exec 6>&1
470 fi
471 exec 5>./config.log
472
473 echo "\
474 This file contains any messages produced by compilers while
475 running configure, to aid debugging if configure makes a mistake.
476 " 1>&5
477
478 # Strip out --no-create and --no-recursion so they do not pile up.
479 # Also quote any args containing shell metacharacters.
480 ac_configure_args=
481 for ac_arg
482 do
483   case "$ac_arg" in
484   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
485   | --no-cr | --no-c) ;;
486   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
487   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
488   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
489   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
490   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
491   esac
492 done
493
494 # NLS nuisances.
495 # Only set these to C if already set.  These must not be set unconditionally
496 # because not all systems understand e.g. LANG=C (notably SCO).
497 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
498 # Non-C LC_CTYPE values break the ctype check.
499 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
500 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
501 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
502 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
503
504 # confdefs.h avoids OS command line length limits that DEFS can exceed.
505 rm -rf conftest* confdefs.h
506 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
507 echo > confdefs.h
508
509 # A filename unique to this package, relative to the directory that
510 # configure is in, which we can look for to find out if srcdir is correct.
511 ac_unique_file=jcc.c
512
513 # Find the source files, if location was not specified.
514 if test -z "$srcdir"; then
515   ac_srcdir_defaulted=yes
516   # Try the directory containing this script, then its parent.
517   ac_prog=$0
518   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
519   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
520   srcdir=$ac_confdir
521   if test ! -r $srcdir/$ac_unique_file; then
522     srcdir=..
523   fi
524 else
525   ac_srcdir_defaulted=no
526 fi
527 if test ! -r $srcdir/$ac_unique_file; then
528   if test "$ac_srcdir_defaulted" = yes; then
529     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
530   else
531     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
532   fi
533 fi
534 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
535
536 # Prefer explicitly selected file to automatically selected ones.
537 if test -z "$CONFIG_SITE"; then
538   if test "x$prefix" != xNONE; then
539     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
540   else
541     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
542   fi
543 fi
544 for ac_site_file in $CONFIG_SITE; do
545   if test -r "$ac_site_file"; then
546     echo "loading site script $ac_site_file"
547     . "$ac_site_file"
548   fi
549 done
550
551 if test -r "$cache_file"; then
552   echo "loading cache $cache_file"
553   . $cache_file
554 else
555   echo "creating cache $cache_file"
556   > $cache_file
557 fi
558
559 ac_ext=c
560 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
561 ac_cpp='$CPP $CPPFLAGS'
562 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
563 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
564 cross_compiling=$ac_cv_prog_cc_cross
565
566 ac_exeext=
567 ac_objext=o
568 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
569   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
570   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
571     ac_n= ac_c='
572 ' ac_t='        '
573   else
574     ac_n=-n ac_c= ac_t=
575   fi
576 else
577   ac_n= ac_c='\c' ac_t=
578 fi
579
580
581
582 ac_aux_dir=
583 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
584   if test -f $ac_dir/install-sh; then
585     ac_aux_dir=$ac_dir
586     ac_install_sh="$ac_aux_dir/install-sh -c"
587     break
588   elif test -f $ac_dir/install.sh; then
589     ac_aux_dir=$ac_dir
590     ac_install_sh="$ac_aux_dir/install.sh -c"
591     break
592   fi
593 done
594 if test -z "$ac_aux_dir"; then
595   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
596 fi
597 ac_config_guess=$ac_aux_dir/config.guess
598 ac_config_sub=$ac_aux_dir/config.sub
599 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
600
601
602 # Make sure we can run config.sub.
603 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
604 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
605 fi
606
607 echo $ac_n "checking host system type""... $ac_c" 1>&6
608 echo "configure:609: checking host system type" >&5
609
610 host_alias=$host
611 case "$host_alias" in
612 NONE)
613   case $nonopt in
614   NONE)
615     if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
616     else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
617     fi ;;
618   *) host_alias=$nonopt ;;
619   esac ;;
620 esac
621
622 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
623 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
624 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
625 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
626 echo "$ac_t""$host" 1>&6
627
628
629 dodk=auto
630 DKPREFIX=none
631 # Check whether --with-docbook or --without-docbook was given.
632 if test "${with_docbook+set}" = set; then
633   withval="$with_docbook"
634   case "$with_docbook" in
635 yes) dodk=yes;;
636 no) dodk=no;;
637 *) 
638         dodk=no
639         DKPREFIX=$withval
640         ;;
641 esac
642
643 fi
644
645 DB2HTML=false
646 # Check whether --with-db2html or --without-db2html was given.
647 if test "${with_db2html+set}" = set; then
648   withval="$with_db2html"
649   DB2HTML=$withval
650
651 fi
652
653
654
655 VERSION_MAJOR=2
656 VERSION_MINOR=9
657 VERSION_POINT=13
658 VERSION_RPM_PACKAGE=1
659 CODE_STATUS="beta"
660
661
662
663
664
665
666
667
668
669 cat >> confdefs.h <<EOF
670 #define VERSION_MAJOR ${VERSION_MAJOR}
671 EOF
672
673 cat >> confdefs.h <<EOF
674 #define VERSION_MINOR ${VERSION_MINOR}
675 EOF
676
677 cat >> confdefs.h <<EOF
678 #define VERSION_POINT ${VERSION_POINT}
679 EOF
680
681 cat >> confdefs.h <<EOF
682 #define VERSION_RPM_PACKAGE ${VERSION_RPM_PACKAGE}
683 EOF
684
685 cat >> confdefs.h <<EOF
686 #define VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_POINT}"
687 EOF
688
689 cat >> confdefs.h <<EOF
690 #define CODE_STATUS "${CODE_STATUS}"
691 EOF
692
693
694 # Extract the first word of "gcc", so it can be a program name with args.
695 set dummy gcc; ac_word=$2
696 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
697 echo "configure:698: checking for $ac_word" >&5
698 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
699   echo $ac_n "(cached) $ac_c" 1>&6
700 else
701   if test -n "$CC"; then
702   ac_cv_prog_CC="$CC" # Let the user override the test.
703 else
704   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
705   ac_dummy="$PATH"
706   for ac_dir in $ac_dummy; do
707     test -z "$ac_dir" && ac_dir=.
708     if test -f $ac_dir/$ac_word; then
709       ac_cv_prog_CC="gcc"
710       break
711     fi
712   done
713   IFS="$ac_save_ifs"
714 fi
715 fi
716 CC="$ac_cv_prog_CC"
717 if test -n "$CC"; then
718   echo "$ac_t""$CC" 1>&6
719 else
720   echo "$ac_t""no" 1>&6
721 fi
722
723 if test -z "$CC"; then
724   # Extract the first word of "cc", so it can be a program name with args.
725 set dummy cc; ac_word=$2
726 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
727 echo "configure:728: checking for $ac_word" >&5
728 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
729   echo $ac_n "(cached) $ac_c" 1>&6
730 else
731   if test -n "$CC"; then
732   ac_cv_prog_CC="$CC" # Let the user override the test.
733 else
734   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
735   ac_prog_rejected=no
736   ac_dummy="$PATH"
737   for ac_dir in $ac_dummy; do
738     test -z "$ac_dir" && ac_dir=.
739     if test -f $ac_dir/$ac_word; then
740       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
741         ac_prog_rejected=yes
742         continue
743       fi
744       ac_cv_prog_CC="cc"
745       break
746     fi
747   done
748   IFS="$ac_save_ifs"
749 if test $ac_prog_rejected = yes; then
750   # We found a bogon in the path, so make sure we never use it.
751   set dummy $ac_cv_prog_CC
752   shift
753   if test $# -gt 0; then
754     # We chose a different compiler from the bogus one.
755     # However, it has the same basename, so the bogon will be chosen
756     # first if we set CC to just the basename; use the full file name.
757     shift
758     set dummy "$ac_dir/$ac_word" "$@"
759     shift
760     ac_cv_prog_CC="$@"
761   fi
762 fi
763 fi
764 fi
765 CC="$ac_cv_prog_CC"
766 if test -n "$CC"; then
767   echo "$ac_t""$CC" 1>&6
768 else
769   echo "$ac_t""no" 1>&6
770 fi
771
772   if test -z "$CC"; then
773     case "`uname -s`" in
774     *win32* | *WIN32*)
775       # Extract the first word of "cl", so it can be a program name with args.
776 set dummy cl; ac_word=$2
777 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
778 echo "configure:779: checking for $ac_word" >&5
779 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
780   echo $ac_n "(cached) $ac_c" 1>&6
781 else
782   if test -n "$CC"; then
783   ac_cv_prog_CC="$CC" # Let the user override the test.
784 else
785   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
786   ac_dummy="$PATH"
787   for ac_dir in $ac_dummy; do
788     test -z "$ac_dir" && ac_dir=.
789     if test -f $ac_dir/$ac_word; then
790       ac_cv_prog_CC="cl"
791       break
792     fi
793   done
794   IFS="$ac_save_ifs"
795 fi
796 fi
797 CC="$ac_cv_prog_CC"
798 if test -n "$CC"; then
799   echo "$ac_t""$CC" 1>&6
800 else
801   echo "$ac_t""no" 1>&6
802 fi
803  ;;
804     esac
805   fi
806   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
807 fi
808
809 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
810 echo "configure:811: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
811
812 ac_ext=c
813 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
814 ac_cpp='$CPP $CPPFLAGS'
815 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
816 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
817 cross_compiling=$ac_cv_prog_cc_cross
818
819 cat > conftest.$ac_ext << EOF
820
821 #line 822 "configure"
822 #include "confdefs.h"
823
824 main(){return(0);}
825 EOF
826 if { (eval echo configure:827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
827   ac_cv_prog_cc_works=yes
828   # If we can't run a trivial program, we are probably using a cross compiler.
829   if (./conftest; exit) 2>/dev/null; then
830     ac_cv_prog_cc_cross=no
831   else
832     ac_cv_prog_cc_cross=yes
833   fi
834 else
835   echo "configure: failed program was:" >&5
836   cat conftest.$ac_ext >&5
837   ac_cv_prog_cc_works=no
838 fi
839 rm -fr conftest*
840 ac_ext=c
841 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
842 ac_cpp='$CPP $CPPFLAGS'
843 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
844 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
845 cross_compiling=$ac_cv_prog_cc_cross
846
847 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
848 if test $ac_cv_prog_cc_works = no; then
849   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
850 fi
851 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
852 echo "configure:853: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
853 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
854 cross_compiling=$ac_cv_prog_cc_cross
855
856 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
857 echo "configure:858: checking whether we are using GNU C" >&5
858 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
859   echo $ac_n "(cached) $ac_c" 1>&6
860 else
861   cat > conftest.c <<EOF
862 #ifdef __GNUC__
863   yes;
864 #endif
865 EOF
866 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:867: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
867   ac_cv_prog_gcc=yes
868 else
869   ac_cv_prog_gcc=no
870 fi
871 fi
872
873 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
874
875 if test $ac_cv_prog_gcc = yes; then
876   GCC=yes
877 else
878   GCC=
879 fi
880
881 ac_test_CFLAGS="${CFLAGS+set}"
882 ac_save_CFLAGS="$CFLAGS"
883 CFLAGS=
884 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
885 echo "configure:886: checking whether ${CC-cc} accepts -g" >&5
886 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
887   echo $ac_n "(cached) $ac_c" 1>&6
888 else
889   echo 'void f(){}' > conftest.c
890 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
891   ac_cv_prog_cc_g=yes
892 else
893   ac_cv_prog_cc_g=no
894 fi
895 rm -f conftest*
896
897 fi
898
899 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
900 if test "$ac_test_CFLAGS" = set; then
901   CFLAGS="$ac_save_CFLAGS"
902 elif test $ac_cv_prog_cc_g = yes; then
903   if test "$GCC" = yes; then
904     CFLAGS="-g -O2"
905   else
906     CFLAGS="-g"
907   fi
908 else
909   if test "$GCC" = yes; then
910     CFLAGS="-O2"
911   else
912     CFLAGS=
913   fi
914 fi
915
916 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
917 echo "configure:918: checking how to run the C preprocessor" >&5
918 # On Suns, sometimes $CPP names a directory.
919 if test -n "$CPP" && test -d "$CPP"; then
920   CPP=
921 fi
922 if test -z "$CPP"; then
923 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
924   echo $ac_n "(cached) $ac_c" 1>&6
925 else
926     # This must be in double quotes, not single quotes, because CPP may get
927   # substituted into the Makefile and "${CC-cc}" will confuse make.
928   CPP="${CC-cc} -E"
929   # On the NeXT, cc -E runs the code through the compiler's parser,
930   # not just through cpp.
931   cat > conftest.$ac_ext <<EOF
932 #line 933 "configure"
933 #include "confdefs.h"
934 #include <assert.h>
935 Syntax Error
936 EOF
937 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
938 { (eval echo configure:939: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
939 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
940 if test -z "$ac_err"; then
941   :
942 else
943   echo "$ac_err" >&5
944   echo "configure: failed program was:" >&5
945   cat conftest.$ac_ext >&5
946   rm -rf conftest*
947   CPP="${CC-cc} -E -traditional-cpp"
948   cat > conftest.$ac_ext <<EOF
949 #line 950 "configure"
950 #include "confdefs.h"
951 #include <assert.h>
952 Syntax Error
953 EOF
954 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
955 { (eval echo configure:956: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
956 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
957 if test -z "$ac_err"; then
958   :
959 else
960   echo "$ac_err" >&5
961   echo "configure: failed program was:" >&5
962   cat conftest.$ac_ext >&5
963   rm -rf conftest*
964   CPP="${CC-cc} -nologo -E"
965   cat > conftest.$ac_ext <<EOF
966 #line 967 "configure"
967 #include "confdefs.h"
968 #include <assert.h>
969 Syntax Error
970 EOF
971 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
972 { (eval echo configure:973: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
973 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
974 if test -z "$ac_err"; then
975   :
976 else
977   echo "$ac_err" >&5
978   echo "configure: failed program was:" >&5
979   cat conftest.$ac_ext >&5
980   rm -rf conftest*
981   CPP=/lib/cpp
982 fi
983 rm -f conftest*
984 fi
985 rm -f conftest*
986 fi
987 rm -f conftest*
988   ac_cv_prog_CPP="$CPP"
989 fi
990   CPP="$ac_cv_prog_CPP"
991 else
992   ac_cv_prog_CPP="$CPP"
993 fi
994 echo "$ac_t""$CPP" 1>&6
995
996
997 # Extract the first word of "gdb", so it can be a program name with args.
998 set dummy gdb; ac_word=$2
999 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1000 echo "configure:1001: checking for $ac_word" >&5
1001 if eval "test \"`echo '$''{'ac_cv_prog_GDB'+set}'`\" = set"; then
1002   echo $ac_n "(cached) $ac_c" 1>&6
1003 else
1004   if test -n "$GDB"; then
1005   ac_cv_prog_GDB="$GDB" # Let the user override the test.
1006 else
1007   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1008   ac_dummy="$PATH"
1009   for ac_dir in $ac_dummy; do
1010     test -z "$ac_dir" && ac_dir=.
1011     if test -f $ac_dir/$ac_word; then
1012       ac_cv_prog_GDB="yes"
1013       break
1014     fi
1015   done
1016   IFS="$ac_save_ifs"
1017   test -z "$ac_cv_prog_GDB" && ac_cv_prog_GDB="no"
1018 fi
1019 fi
1020 GDB="$ac_cv_prog_GDB"
1021 if test -n "$GDB"; then
1022   echo "$ac_t""$GDB" 1>&6
1023 else
1024   echo "$ac_t""no" 1>&6
1025 fi
1026
1027
1028
1029 # Check whether --with-debug or --without-debug was given.
1030 if test "${with_debug+set}" = set; then
1031   withval="$with_debug"
1032   
1033                 if test "x$withval" != "xno" ; then
1034                     if test $ac_cv_prog_cc_g = yes; then
1035                       if test "$GCC" = yes; then
1036                         if test "$GDB"; then
1037                           CFLAGS="-ggdb"
1038                         else
1039                           CFLAGS="-g"
1040                         fi
1041                         CFLAGS="$CFLAGS -Wshadow  -Wconversion"
1042                       else
1043                         CFLAGS="-g"
1044                       fi
1045                    fi
1046                 fi
1047         
1048 else
1049   
1050             if test "X$CFLAGS" = "X"; then # if CFLAGS are unset
1051               if test "$GCC" = yes; then
1052                 CFLAGS="-O2"
1053               else
1054                 CFLAGS=
1055               fi
1056             fi
1057         
1058
1059 fi
1060
1061
1062 if test "$GCC"; then
1063   CFLAGS="-pipe $CFLAGS"
1064 fi
1065
1066
1067
1068 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
1069 echo "configure:1070: checking for mingw32 environment" >&5
1070 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
1071   echo $ac_n "(cached) $ac_c" 1>&6
1072 else
1073   cat > conftest.$ac_ext <<EOF
1074 #line 1075 "configure"
1075 #include "confdefs.h"
1076
1077 int main() {
1078 return __MINGW32__;
1079 ; return 0; }
1080 EOF
1081 if { (eval echo configure:1082: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1082   rm -rf conftest*
1083   ac_cv_mingw32=yes
1084 else
1085   echo "configure: failed program was:" >&5
1086   cat conftest.$ac_ext >&5
1087   rm -rf conftest*
1088   ac_cv_mingw32=no
1089 fi
1090 rm -f conftest*
1091 rm -f conftest*
1092 fi
1093
1094 echo "$ac_t""$ac_cv_mingw32" 1>&6
1095 MINGW32=
1096 test "$ac_cv_mingw32" = yes && MINGW32=yes
1097 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
1098 echo "configure:1099: checking for Cygwin environment" >&5
1099 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
1100   echo $ac_n "(cached) $ac_c" 1>&6
1101 else
1102   cat > conftest.$ac_ext <<EOF
1103 #line 1104 "configure"
1104 #include "confdefs.h"
1105
1106 int main() {
1107
1108 #ifndef __CYGWIN__
1109 #define __CYGWIN__ __CYGWIN32__
1110 #endif
1111 return __CYGWIN__;
1112 ; return 0; }
1113 EOF
1114 if { (eval echo configure:1115: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1115   rm -rf conftest*
1116   ac_cv_cygwin=yes
1117 else
1118   echo "configure: failed program was:" >&5
1119   cat conftest.$ac_ext >&5
1120   rm -rf conftest*
1121   ac_cv_cygwin=no
1122 fi
1123 rm -f conftest*
1124 rm -f conftest*
1125 fi
1126
1127 echo "$ac_t""$ac_cv_cygwin" 1>&6
1128 CYGWIN=
1129 test "$ac_cv_cygwin" = yes && CYGWIN=yes
1130
1131 if test "$MINGW32" = "yes"; then
1132   target_type=mingw
1133 else
1134   if test "$CYGWIN" = "yes"; then
1135     target_type=cygwin
1136   else
1137     target_type=unix
1138   fi
1139 fi
1140
1141 if test $dodk = auto; then
1142         dodk=no
1143         if test $target_type = unix; then
1144                 case "$host_os" in
1145                 linux* | gnu*)
1146                         dodk=yes
1147                 ;;
1148                 esac
1149         fi
1150 fi
1151
1152
1153 # Check whether --enable-mingw32 or --disable-mingw32 was given.
1154 if test "${enable_mingw32+set}" = set; then
1155   enableval="$enable_mingw32"
1156   if test $enableval = yes; then
1157   target_type=mingw
1158 fi
1159 fi
1160
1161
1162 if test $target_type = mingw; then
1163   WIN_ONLY=
1164   SPECIAL_CFLAGS="-mwindows -mno-cygwin"
1165   PTHREAD_LIB=-lpthreadGC
1166   echo "Using mingw32 (Win32 GUI)"
1167 else
1168   WIN_ONLY=#
1169   if test $target_type = cygwin; then
1170     SPECIAL_CFLAGS="-mno-win32"
1171     PTHREAD_LIB=
1172     echo "Using Cygnus (Win32 command line)"
1173   else
1174     SPECIAL_CFLAGS=
1175     PTHREAD_LIB=-lpthread
1176   fi
1177 fi
1178
1179
1180 if test $dodk != no; then
1181         for ac_prog in w3m lynx links
1182 do
1183 # Extract the first word of "$ac_prog", so it can be a program name with args.
1184 set dummy $ac_prog; ac_word=$2
1185 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1186 echo "configure:1187: checking for $ac_word" >&5
1187 if eval "test \"`echo '$''{'ac_cv_prog_WDUMP'+set}'`\" = set"; then
1188   echo $ac_n "(cached) $ac_c" 1>&6
1189 else
1190   if test -n "$WDUMP"; then
1191   ac_cv_prog_WDUMP="$WDUMP" # Let the user override the test.
1192 else
1193   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1194   ac_dummy="$PATH"
1195   for ac_dir in $ac_dummy; do
1196     test -z "$ac_dir" && ac_dir=.
1197     if test -f $ac_dir/$ac_word; then
1198       ac_cv_prog_WDUMP="$ac_prog"
1199       break
1200     fi
1201   done
1202   IFS="$ac_save_ifs"
1203 fi
1204 fi
1205 WDUMP="$ac_cv_prog_WDUMP"
1206 if test -n "$WDUMP"; then
1207   echo "$ac_t""$WDUMP" 1>&6
1208 else
1209   echo "$ac_t""no" 1>&6
1210 fi
1211
1212 test -n "$WDUMP" && break
1213 done
1214 test -n "$WDUMP" || WDUMP="false"
1215
1216         if test "$WDUMP" = false; then
1217                 { echo "configure: error: You need some kind of text browser to continue \(w3m, lynx and links are supported\)" 1>&2; exit 1; }
1218         fi
1219         if test $DB2HTML = false; then
1220                                                 DB2HTML=""
1221                 for ac_prog in db2html docbook2html
1222 do
1223 # Extract the first word of "$ac_prog", so it can be a program name with args.
1224 set dummy $ac_prog; ac_word=$2
1225 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1226 echo "configure:1227: checking for $ac_word" >&5
1227 if eval "test \"`echo '$''{'ac_cv_prog_DB2HTML'+set}'`\" = set"; then
1228   echo $ac_n "(cached) $ac_c" 1>&6
1229 else
1230   if test -n "$DB2HTML"; then
1231   ac_cv_prog_DB2HTML="$DB2HTML" # Let the user override the test.
1232 else
1233   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1234   ac_dummy="$PATH"
1235   for ac_dir in $ac_dummy; do
1236     test -z "$ac_dir" && ac_dir=.
1237     if test -f $ac_dir/$ac_word; then
1238       ac_cv_prog_DB2HTML="$ac_prog"
1239       break
1240     fi
1241   done
1242   IFS="$ac_save_ifs"
1243 fi
1244 fi
1245 DB2HTML="$ac_cv_prog_DB2HTML"
1246 if test -n "$DB2HTML"; then
1247   echo "$ac_t""$DB2HTML" 1>&6
1248 else
1249   echo "$ac_t""no" 1>&6
1250 fi
1251
1252 test -n "$DB2HTML" && break
1253 done
1254 test -n "$DB2HTML" || DB2HTML="false"
1255
1256         fi
1257 fi
1258
1259
1260
1261 for ac_prog in rpm
1262 do
1263 # Extract the first word of "$ac_prog", so it can be a program name with args.
1264 set dummy $ac_prog; ac_word=$2
1265 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1266 echo "configure:1267: checking for $ac_word" >&5
1267 if eval "test \"`echo '$''{'ac_cv_prog_RPMBIN'+set}'`\" = set"; then
1268   echo $ac_n "(cached) $ac_c" 1>&6
1269 else
1270   if test -n "$RPMBIN"; then
1271   ac_cv_prog_RPMBIN="$RPMBIN" # Let the user override the test.
1272 else
1273   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1274   ac_dummy="$PATH"
1275   for ac_dir in $ac_dummy; do
1276     test -z "$ac_dir" && ac_dir=.
1277     if test -f $ac_dir/$ac_word; then
1278       ac_cv_prog_RPMBIN="$ac_prog"
1279       break
1280     fi
1281   done
1282   IFS="$ac_save_ifs"
1283 fi
1284 fi
1285 RPMBIN="$ac_cv_prog_RPMBIN"
1286 if test -n "$RPMBIN"; then
1287   echo "$ac_t""$RPMBIN" 1>&6
1288 else
1289   echo "$ac_t""no" 1>&6
1290 fi
1291
1292 test -n "$RPMBIN" && break
1293 done
1294 test -n "$RPMBIN" || RPMBIN="false"
1295
1296 if test $RPMBIN != false; then
1297                 RPM_BASE=`rpm --eval "%{_topdir}"`
1298                 if test "$RPM_BASE" = ""; then
1299                         RPM_BASE=/usr/src/redhat
1300                 fi
1301 fi
1302
1303
1304 for ac_prog in jade openjade
1305 do
1306 # Extract the first word of "$ac_prog", so it can be a program name with args.
1307 set dummy $ac_prog; ac_word=$2
1308 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1309 echo "configure:1310: checking for $ac_word" >&5
1310 if eval "test \"`echo '$''{'ac_cv_prog_JADEBIN'+set}'`\" = set"; then
1311   echo $ac_n "(cached) $ac_c" 1>&6
1312 else
1313   if test -n "$JADEBIN"; then
1314   ac_cv_prog_JADEBIN="$JADEBIN" # Let the user override the test.
1315 else
1316   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1317   ac_dummy="$PATH"
1318   for ac_dir in $ac_dummy; do
1319     test -z "$ac_dir" && ac_dir=.
1320     if test -f $ac_dir/$ac_word; then
1321       ac_cv_prog_JADEBIN="$ac_prog"
1322       break
1323     fi
1324   done
1325   IFS="$ac_save_ifs"
1326 fi
1327 fi
1328 JADEBIN="$ac_cv_prog_JADEBIN"
1329 if test -n "$JADEBIN"; then
1330   echo "$ac_t""$JADEBIN" 1>&6
1331 else
1332   echo "$ac_t""no" 1>&6
1333 fi
1334
1335 test -n "$JADEBIN" && break
1336 done
1337 test -n "$JADEBIN" || JADEBIN="false"
1338
1339
1340
1341 if test $dodk = yes; then
1342   if test $DKPREFIX = none; then
1343     for i in /usr/share/sgml/docbook/dsssl-stylesheets /usr/share/sgml/docbkdsl; do
1344       echo -n "checking for $i/html/docbook.dsl..."
1345       if test -f $i/html/docbook.dsl; then
1346         echo "yes"
1347         DKPREFIX=$i
1348         break
1349       else
1350         echo "no"
1351       fi
1352     done
1353   fi
1354 fi
1355
1356
1357 old_CFLAGS_nospecial=$CFLAGS
1358 CFLAGS="$CFLAGS $SPECIAL_CFLAGS"
1359
1360 # Hack to force AutoConf to use the CFLAGS we just set
1361 ac_cpp='$CPP $CPPFLAGS $SPECIAL_CFLAGS'
1362 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1363 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1364
1365
1366
1367 ac_safe=`echo "pthread.h" | sed 'y%./+-%__p_%'`
1368 echo $ac_n "checking for pthread.h""... $ac_c" 1>&6
1369 echo "configure:1370: checking for pthread.h" >&5
1370 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1371   echo $ac_n "(cached) $ac_c" 1>&6
1372 else
1373   cat > conftest.$ac_ext <<EOF
1374 #line 1375 "configure"
1375 #include "confdefs.h"
1376 #include <pthread.h>
1377 EOF
1378 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1379 { (eval echo configure:1380: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1380 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1381 if test -z "$ac_err"; then
1382   rm -rf conftest*
1383   eval "ac_cv_header_$ac_safe=yes"
1384 else
1385   echo "$ac_err" >&5
1386   echo "configure: failed program was:" >&5
1387   cat conftest.$ac_ext >&5
1388   rm -rf conftest*
1389   eval "ac_cv_header_$ac_safe=no"
1390 fi
1391 rm -f conftest*
1392 fi
1393 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1394   echo "$ac_t""yes" 1>&6
1395   have_pthread=yes
1396 else
1397   echo "$ac_t""no" 1>&6
1398 have_pthread=no
1399 fi
1400
1401
1402 # Check whether --enable-pthread or --disable-pthread was given.
1403 if test "${enable_pthread+set}" = set; then
1404   enableval="$enable_pthread"
1405   if test $enableval = no; then
1406   # Disable pthreads
1407   have_pthread=no
1408 fi
1409 fi
1410
1411
1412 if test $have_pthread = yes; then
1413   PTHREAD_ONLY=
1414   cat >> confdefs.h <<\EOF
1415 #define FEATURE_PTHREAD 1
1416 EOF
1417
1418   echo Using POSIX threads
1419   if test "$GCC" = "yes"; then
1420     # Set a GCC specific switch:
1421     if test "$target_type" = "unix"; then
1422       # This compiler switch makes Linux thread-safe
1423       # Don't know about other OS's?  Is this switch
1424       # supported?
1425       PTHREAD_LIB=
1426       SPECIAL_CFLAGS="-pthread"
1427     fi
1428   fi
1429 else
1430   PTHREAD_ONLY=#
1431   echo Using native threads
1432 fi
1433
1434
1435
1436
1437 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
1438 echo "configure:1439: checking for gethostbyname in -lnsl" >&5
1439 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
1440 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1441   echo $ac_n "(cached) $ac_c" 1>&6
1442 else
1443   ac_save_LIBS="$LIBS"
1444 LIBS="-lnsl  $LIBS"
1445 cat > conftest.$ac_ext <<EOF
1446 #line 1447 "configure"
1447 #include "confdefs.h"
1448 /* Override any gcc2 internal prototype to avoid an error.  */
1449 /* We use char because int might match the return type of a gcc2
1450     builtin and then its argument prototype would still apply.  */
1451 char gethostbyname();
1452
1453 int main() {
1454 gethostbyname()
1455 ; return 0; }
1456 EOF
1457 if { (eval echo configure:1458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1458   rm -rf conftest*
1459   eval "ac_cv_lib_$ac_lib_var=yes"
1460 else
1461   echo "configure: failed program was:" >&5
1462   cat conftest.$ac_ext >&5
1463   rm -rf conftest*
1464   eval "ac_cv_lib_$ac_lib_var=no"
1465 fi
1466 rm -f conftest*
1467 LIBS="$ac_save_LIBS"
1468
1469 fi
1470 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1471   echo "$ac_t""yes" 1>&6
1472     ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
1473     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
1474   cat >> confdefs.h <<EOF
1475 #define $ac_tr_lib 1
1476 EOF
1477
1478   LIBS="-lnsl $LIBS"
1479
1480 else
1481   echo "$ac_t""no" 1>&6
1482 fi
1483
1484
1485 echo $ac_n "checking for gethostbyaddr_r""... $ac_c" 1>&6
1486 echo "configure:1487: checking for gethostbyaddr_r" >&5
1487 if eval "test \"`echo '$''{'ac_cv_func_gethostbyaddr_r'+set}'`\" = set"; then
1488   echo $ac_n "(cached) $ac_c" 1>&6
1489 else
1490   cat > conftest.$ac_ext <<EOF
1491 #line 1492 "configure"
1492 #include "confdefs.h"
1493 /* System header to define __stub macros and hopefully few prototypes,
1494     which can conflict with char gethostbyaddr_r(); below.  */
1495 #include <assert.h>
1496 /* Override any gcc2 internal prototype to avoid an error.  */
1497 /* We use char because int might match the return type of a gcc2
1498     builtin and then its argument prototype would still apply.  */
1499 char gethostbyaddr_r();
1500
1501 int main() {
1502
1503 /* The GNU C library defines this for functions which it implements
1504     to always fail with ENOSYS.  Some functions are actually named
1505     something starting with __ and the normal name is an alias.  */
1506 #if defined (__stub_gethostbyaddr_r) || defined (__stub___gethostbyaddr_r)
1507 choke me
1508 #else
1509 gethostbyaddr_r();
1510 #endif
1511
1512 ; return 0; }
1513 EOF
1514 if { (eval echo configure:1515: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1515   rm -rf conftest*
1516   eval "ac_cv_func_gethostbyaddr_r=yes"
1517 else
1518   echo "configure: failed program was:" >&5
1519   cat conftest.$ac_ext >&5
1520   rm -rf conftest*
1521   eval "ac_cv_func_gethostbyaddr_r=no"
1522 fi
1523 rm -f conftest*
1524 fi
1525
1526 if eval "test \"`echo '$ac_cv_func_'gethostbyaddr_r`\" = yes"; then
1527   echo "$ac_t""yes" 1>&6
1528   
1529   echo $ac_n "checking signature of gethostbyaddr_r""... $ac_c" 1>&6
1530 echo "configure:1531: checking signature of gethostbyaddr_r" >&5
1531   cat > conftest.$ac_ext <<EOF
1532 #line 1533 "configure"
1533 #include "confdefs.h"
1534
1535 #   include <netdb.h>
1536   
1537 int main() {
1538
1539     struct hostent *h, *hp;
1540     char *a, *b;
1541     int l, bl, t, e;
1542     (void) gethostbyaddr_r(a, l, t, h, b, bl, &hp, &e)
1543   
1544 ; return 0; }
1545 EOF
1546 if { (eval echo configure:1547: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1547   rm -rf conftest*
1548   
1549     cat >> confdefs.h <<\EOF
1550 #define HAVE_GETHOSTBYADDR_R_8_ARGS 1
1551 EOF
1552
1553     echo "$ac_t""8 args" 1>&6
1554   
1555 else
1556   echo "configure: failed program was:" >&5
1557   cat conftest.$ac_ext >&5
1558   rm -rf conftest*
1559   
1560     cat > conftest.$ac_ext <<EOF
1561 #line 1562 "configure"
1562 #include "confdefs.h"
1563
1564 #     include <netdb.h>
1565     
1566 int main() {
1567
1568       struct hostent *h;
1569       char *a, *b;
1570       int l, bl, t, e;
1571       (void) gethostbyaddr_r(a, l, t, h, b, bl, &e)
1572     
1573 ; return 0; }
1574 EOF
1575 if { (eval echo configure:1576: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1576   rm -rf conftest*
1577   
1578       cat >> confdefs.h <<\EOF
1579 #define HAVE_GETHOSTBYADDR_R_7_ARGS 1
1580 EOF
1581
1582       echo "$ac_t""7 args" 1>&6
1583     
1584 else
1585   echo "configure: failed program was:" >&5
1586   cat conftest.$ac_ext >&5
1587   rm -rf conftest*
1588   
1589       cat > conftest.$ac_ext <<EOF
1590 #line 1591 "configure"
1591 #include "confdefs.h"
1592
1593 #       include <netdb.h>
1594       
1595 int main() {
1596
1597         struct hostent_data *d;
1598         struct hostent *h;
1599         char a,
1600         int l, t;
1601         (void) gethostbyaddr_r(a, l, t, h, d)
1602       
1603 ; return 0; }
1604 EOF
1605 if { (eval echo configure:1606: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1606   rm -rf conftest*
1607   
1608         cat >> confdefs.h <<\EOF
1609 #define HAVE_GETHOSTBYADDR_R_5_ARGS 1
1610 EOF
1611
1612         echo "$ac_t""5 args" 1>&6
1613       
1614 else
1615   echo "configure: failed program was:" >&5
1616   cat conftest.$ac_ext >&5
1617   rm -rf conftest*
1618   
1619         echo "$ac_t""unrecognised" 1>&6
1620       
1621 fi
1622 rm -f conftest*
1623     
1624 fi
1625 rm -f conftest*
1626   
1627 fi
1628 rm -f conftest*
1629
1630 else
1631   echo "$ac_t""no" 1>&6
1632
1633   echo "$ac_t""no" 1>&6
1634
1635 fi
1636
1637
1638 echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6
1639 echo "configure:1640: checking for gethostbyname_r" >&5
1640 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then
1641   echo $ac_n "(cached) $ac_c" 1>&6
1642 else
1643   cat > conftest.$ac_ext <<EOF
1644 #line 1645 "configure"
1645 #include "confdefs.h"
1646 /* System header to define __stub macros and hopefully few prototypes,
1647     which can conflict with char gethostbyname_r(); below.  */
1648 #include <assert.h>
1649 /* Override any gcc2 internal prototype to avoid an error.  */
1650 /* We use char because int might match the return type of a gcc2
1651     builtin and then its argument prototype would still apply.  */
1652 char gethostbyname_r();
1653
1654 int main() {
1655
1656 /* The GNU C library defines this for functions which it implements
1657     to always fail with ENOSYS.  Some functions are actually named
1658     something starting with __ and the normal name is an alias.  */
1659 #if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r)
1660 choke me
1661 #else
1662 gethostbyname_r();
1663 #endif
1664
1665 ; return 0; }
1666 EOF
1667 if { (eval echo configure:1668: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1668   rm -rf conftest*
1669   eval "ac_cv_func_gethostbyname_r=yes"
1670 else
1671   echo "configure: failed program was:" >&5
1672   cat conftest.$ac_ext >&5
1673   rm -rf conftest*
1674   eval "ac_cv_func_gethostbyname_r=no"
1675 fi
1676 rm -f conftest*
1677 fi
1678
1679 if eval "test \"`echo '$ac_cv_func_'gethostbyname_r`\" = yes"; then
1680   echo "$ac_t""yes" 1>&6
1681   
1682   echo $ac_n "checking signature of gethostbyname_r""... $ac_c" 1>&6
1683 echo "configure:1684: checking signature of gethostbyname_r" >&5
1684   cat > conftest.$ac_ext <<EOF
1685 #line 1686 "configure"
1686 #include "confdefs.h"
1687
1688 #   include <netdb.h>
1689   
1690 int main() {
1691
1692     struct hostent *h, *r;
1693     char *n, *b;
1694     int bl, e;
1695     (void) gethostbyname_r(n, h, b, bl, &r, &e)
1696   
1697 ; return 0; }
1698 EOF
1699 if { (eval echo configure:1700: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1700   rm -rf conftest*
1701   
1702     cat >> confdefs.h <<\EOF
1703 #define HAVE_GETHOSTBYNAME_R_6_ARGS 1
1704 EOF
1705
1706     echo "$ac_t""6 args" 1>&6
1707   
1708 else
1709   echo "configure: failed program was:" >&5
1710   cat conftest.$ac_ext >&5
1711   rm -rf conftest*
1712   
1713     cat > conftest.$ac_ext <<EOF
1714 #line 1715 "configure"
1715 #include "confdefs.h"
1716
1717 #     include <netdb.h>
1718     
1719 int main() {
1720
1721       struct hostent *h;
1722       char *n, *b;
1723       int bl, e;
1724       (void) gethostbyname_r(n, h, b, bl, &e)
1725     
1726 ; return 0; }
1727 EOF
1728 if { (eval echo configure:1729: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1729   rm -rf conftest*
1730   
1731       cat >> confdefs.h <<\EOF
1732 #define HAVE_GETHOSTBYNAME_R_5_ARGS 1
1733 EOF
1734
1735       echo "$ac_t""5 args" 1>&6
1736     
1737 else
1738   echo "configure: failed program was:" >&5
1739   cat conftest.$ac_ext >&5
1740   rm -rf conftest*
1741   
1742       cat > conftest.$ac_ext <<EOF
1743 #line 1744 "configure"
1744 #include "confdefs.h"
1745
1746 #       include <netdb.h>
1747       
1748 int main() {
1749
1750         struct hostent_data *d;
1751         struct hostent *h;
1752         char *n,
1753         (void) gethostbyname_r(n, h, d)
1754       
1755 ; return 0; }
1756 EOF
1757 if { (eval echo configure:1758: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1758   rm -rf conftest*
1759   
1760         cat >> confdefs.h <<\EOF
1761 #define HAVE_GETHOSTBYNAME_R_3_ARGS 1
1762 EOF
1763
1764         echo "$ac_t""3 args" 1>&6
1765       
1766 else
1767   echo "configure: failed program was:" >&5
1768   cat conftest.$ac_ext >&5
1769   rm -rf conftest*
1770   
1771         echo "$ac_t""unrecognised" 1>&6
1772       
1773 fi
1774 rm -f conftest*
1775     
1776 fi
1777 rm -f conftest*
1778   
1779 fi
1780 rm -f conftest*
1781
1782 else
1783   echo "$ac_t""no" 1>&6
1784
1785   echo "$ac_t""no" 1>&6
1786
1787 fi
1788
1789
1790 echo $ac_n "checking for gmtime_r""... $ac_c" 1>&6
1791 echo "configure:1792: checking for gmtime_r" >&5
1792 if eval "test \"`echo '$''{'ac_cv_func_gmtime_r'+set}'`\" = set"; then
1793   echo $ac_n "(cached) $ac_c" 1>&6
1794 else
1795   cat > conftest.$ac_ext <<EOF
1796 #line 1797 "configure"
1797 #include "confdefs.h"
1798 /* System header to define __stub macros and hopefully few prototypes,
1799     which can conflict with char gmtime_r(); below.  */
1800 #include <assert.h>
1801 /* Override any gcc2 internal prototype to avoid an error.  */
1802 /* We use char because int might match the return type of a gcc2
1803     builtin and then its argument prototype would still apply.  */
1804 char gmtime_r();
1805
1806 int main() {
1807
1808 /* The GNU C library defines this for functions which it implements
1809     to always fail with ENOSYS.  Some functions are actually named
1810     something starting with __ and the normal name is an alias.  */
1811 #if defined (__stub_gmtime_r) || defined (__stub___gmtime_r)
1812 choke me
1813 #else
1814 gmtime_r();
1815 #endif
1816
1817 ; return 0; }
1818 EOF
1819 if { (eval echo configure:1820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1820   rm -rf conftest*
1821   eval "ac_cv_func_gmtime_r=yes"
1822 else
1823   echo "configure: failed program was:" >&5
1824   cat conftest.$ac_ext >&5
1825   rm -rf conftest*
1826   eval "ac_cv_func_gmtime_r=no"
1827 fi
1828 rm -f conftest*
1829 fi
1830
1831 if eval "test \"`echo '$ac_cv_func_'gmtime_r`\" = yes"; then
1832   echo "$ac_t""yes" 1>&6
1833   
1834   echo $ac_n "checking signature of gmtime_r""... $ac_c" 1>&6
1835 echo "configure:1836: checking signature of gmtime_r" >&5
1836   cat > conftest.$ac_ext <<EOF
1837 #line 1838 "configure"
1838 #include "confdefs.h"
1839
1840 #   include <time.h>
1841   
1842 int main() {
1843
1844     struct time *t;
1845     struct tm *tm;
1846     (void) gmtime_r(t, tm)
1847   
1848 ; return 0; }
1849 EOF
1850 if { (eval echo configure:1851: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1851   rm -rf conftest*
1852   
1853     echo "$ac_t""ok" 1>&6
1854     cat >> confdefs.h <<\EOF
1855 #define HAVE_GMTIME_R 1
1856 EOF
1857
1858   
1859 else
1860   echo "configure: failed program was:" >&5
1861   cat conftest.$ac_ext >&5
1862   rm -rf conftest*
1863   
1864     echo "$ac_t""unrecognised" 1>&6
1865   
1866 fi
1867 rm -f conftest*
1868
1869 else
1870   echo "$ac_t""no" 1>&6
1871
1872   echo "$ac_t""no" 1>&6
1873
1874 fi
1875
1876
1877 echo $ac_n "checking for localtime_r""... $ac_c" 1>&6
1878 echo "configure:1879: checking for localtime_r" >&5
1879 if eval "test \"`echo '$''{'ac_cv_func_localtime_r'+set}'`\" = set"; then
1880   echo $ac_n "(cached) $ac_c" 1>&6
1881 else
1882   cat > conftest.$ac_ext <<EOF
1883 #line 1884 "configure"
1884 #include "confdefs.h"
1885 /* System header to define __stub macros and hopefully few prototypes,
1886     which can conflict with char localtime_r(); below.  */
1887 #include <assert.h>
1888 /* Override any gcc2 internal prototype to avoid an error.  */
1889 /* We use char because int might match the return type of a gcc2
1890     builtin and then its argument prototype would still apply.  */
1891 char localtime_r();
1892
1893 int main() {
1894
1895 /* The GNU C library defines this for functions which it implements
1896     to always fail with ENOSYS.  Some functions are actually named
1897     something starting with __ and the normal name is an alias.  */
1898 #if defined (__stub_localtime_r) || defined (__stub___localtime_r)
1899 choke me
1900 #else
1901 localtime_r();
1902 #endif
1903
1904 ; return 0; }
1905 EOF
1906 if { (eval echo configure:1907: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1907   rm -rf conftest*
1908   eval "ac_cv_func_localtime_r=yes"
1909 else
1910   echo "configure: failed program was:" >&5
1911   cat conftest.$ac_ext >&5
1912   rm -rf conftest*
1913   eval "ac_cv_func_localtime_r=no"
1914 fi
1915 rm -f conftest*
1916 fi
1917
1918 if eval "test \"`echo '$ac_cv_func_'localtime_r`\" = yes"; then
1919   echo "$ac_t""yes" 1>&6
1920   
1921   echo $ac_n "checking signature of localtime_r""... $ac_c" 1>&6
1922 echo "configure:1923: checking signature of localtime_r" >&5
1923   cat > conftest.$ac_ext <<EOF
1924 #line 1925 "configure"
1925 #include "confdefs.h"
1926
1927 #   include <time.h>
1928   
1929 int main() {
1930
1931     struct time *t;
1932     struct tm *tm;
1933     (void) localtime_r(t, tm)
1934   
1935 ; return 0; }
1936 EOF
1937 if { (eval echo configure:1938: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1938   rm -rf conftest*
1939   
1940     echo "$ac_t""ok" 1>&6
1941     cat >> confdefs.h <<\EOF
1942 #define HAVE_LOCALTIME_R 1
1943 EOF
1944
1945   
1946 else
1947   echo "configure: failed program was:" >&5
1948   cat conftest.$ac_ext >&5
1949   rm -rf conftest*
1950   
1951     echo "$ac_t""unrecognised" 1>&6
1952   
1953 fi
1954 rm -f conftest*
1955
1956 else
1957   echo "$ac_t""no" 1>&6
1958
1959   echo "$ac_t""no" 1>&6
1960
1961 fi
1962
1963
1964
1965
1966 SOCKET_LIB=
1967
1968 case "$host" in
1969 *-solaris*) SOCKET_LIB="-lsocket -lnsl"
1970             cat >> confdefs.h <<\EOF
1971 #define __EXTENSIONS__ 1
1972 EOF
1973
1974             if test "$GCC" = "yes"; then
1975               # Set a GCC specific switch:
1976               # This compiler switch makes Solaris thread-safe
1977               PTHREAD_LIB=
1978               SPECIAL_CFLAGS="-pthreads"
1979             else
1980               # What do we do without GCC? Guess this:
1981               SPECIAL_CFLAGS="-D_REENTRANT"
1982             fi
1983 ;;
1984 esac
1985
1986
1987
1988
1989 case "$host" in
1990 *-os2-emx*) SOCKET_LIB=-lsocket
1991 ;;
1992 esac
1993
1994
1995
1996
1997 AMIGAOS_ONLY=#
1998
1999 case "$host" in
2000 *-amigaos) AMIGAOS_ONLY=
2001 ;;
2002 esac
2003
2004
2005
2006
2007
2008
2009 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
2010 echo "configure:2011: checking for executable suffix" >&5
2011 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
2012   echo $ac_n "(cached) $ac_c" 1>&6
2013 else
2014   if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
2015   ac_cv_exeext=.exe
2016 else
2017   rm -f conftest*
2018   echo 'int main () { return 0; }' > conftest.$ac_ext
2019   ac_cv_exeext=
2020   if { (eval echo configure:2021: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
2021     for file in conftest.*; do
2022       case $file in
2023       *.c | *.o | *.obj) ;;
2024       *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
2025       esac
2026     done
2027   else
2028     { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
2029   fi
2030   rm -f conftest*
2031   test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
2032 fi
2033 fi
2034
2035 EXEEXT=""
2036 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
2037 echo "$ac_t""${ac_cv_exeext}" 1>&6
2038 ac_exeext=$EXEEXT
2039
2040 echo $ac_n "checking for object suffix""... $ac_c" 1>&6
2041 echo "configure:2042: checking for object suffix" >&5
2042 if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
2043   echo $ac_n "(cached) $ac_c" 1>&6
2044 else
2045   rm -f conftest*
2046 echo 'int i = 1;' > conftest.$ac_ext
2047 if { (eval echo configure:2048: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2048   for ac_file in conftest.*; do
2049     case $ac_file in
2050     *.c) ;;
2051     *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
2052     esac
2053   done
2054 else
2055   { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
2056 fi
2057 rm -f conftest*
2058 fi
2059
2060 echo "$ac_t""$ac_cv_objext" 1>&6
2061 OBJEXT=$ac_cv_objext
2062 ac_objext=$ac_cv_objext
2063
2064 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
2065 echo "configure:2066: checking for ANSI C header files" >&5
2066 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
2067   echo $ac_n "(cached) $ac_c" 1>&6
2068 else
2069   cat > conftest.$ac_ext <<EOF
2070 #line 2071 "configure"
2071 #include "confdefs.h"
2072 #include <stdlib.h>
2073 #include <stdarg.h>
2074 #include <string.h>
2075 #include <float.h>
2076 EOF
2077 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2078 { (eval echo configure:2079: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2079 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2080 if test -z "$ac_err"; then
2081   rm -rf conftest*
2082   ac_cv_header_stdc=yes
2083 else
2084   echo "$ac_err" >&5
2085   echo "configure: failed program was:" >&5
2086   cat conftest.$ac_ext >&5
2087   rm -rf conftest*
2088   ac_cv_header_stdc=no
2089 fi
2090 rm -f conftest*
2091
2092 if test $ac_cv_header_stdc = yes; then
2093   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2094 cat > conftest.$ac_ext <<EOF
2095 #line 2096 "configure"
2096 #include "confdefs.h"
2097 #include <string.h>
2098 EOF
2099 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2100   egrep "memchr" >/dev/null 2>&1; then
2101   :
2102 else
2103   rm -rf conftest*
2104   ac_cv_header_stdc=no
2105 fi
2106 rm -f conftest*
2107
2108 fi
2109
2110 if test $ac_cv_header_stdc = yes; then
2111   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2112 cat > conftest.$ac_ext <<EOF
2113 #line 2114 "configure"
2114 #include "confdefs.h"
2115 #include <stdlib.h>
2116 EOF
2117 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2118   egrep "free" >/dev/null 2>&1; then
2119   :
2120 else
2121   rm -rf conftest*
2122   ac_cv_header_stdc=no
2123 fi
2124 rm -f conftest*
2125
2126 fi
2127
2128 if test $ac_cv_header_stdc = yes; then
2129   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2130 if test "$cross_compiling" = yes; then
2131   :
2132 else
2133   cat > conftest.$ac_ext <<EOF
2134 #line 2135 "configure"
2135 #include "confdefs.h"
2136 #include <ctype.h>
2137 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2138 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2139 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2140 int main () { int i; for (i = 0; i < 256; i++)
2141 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
2142 exit (0); }
2143
2144 EOF
2145 if { (eval echo configure:2146: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2146 then
2147   :
2148 else
2149   echo "configure: failed program was:" >&5
2150   cat conftest.$ac_ext >&5
2151   rm -fr conftest*
2152   ac_cv_header_stdc=no
2153 fi
2154 rm -fr conftest*
2155 fi
2156
2157 fi
2158 fi
2159
2160 echo "$ac_t""$ac_cv_header_stdc" 1>&6
2161 if test $ac_cv_header_stdc = yes; then
2162   cat >> confdefs.h <<\EOF
2163 #define STDC_HEADERS 1
2164 EOF
2165
2166 fi
2167
2168 echo $ac_n "checking for working const""... $ac_c" 1>&6
2169 echo "configure:2170: checking for working const" >&5
2170 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
2171   echo $ac_n "(cached) $ac_c" 1>&6
2172 else
2173   cat > conftest.$ac_ext <<EOF
2174 #line 2175 "configure"
2175 #include "confdefs.h"
2176
2177 int main() {
2178
2179 /* Ultrix mips cc rejects this.  */
2180 typedef int charset[2]; const charset x;
2181 /* SunOS 4.1.1 cc rejects this.  */
2182 char const *const *ccp;
2183 char **p;
2184 /* NEC SVR4.0.2 mips cc rejects this.  */
2185 struct point {int x, y;};
2186 static struct point const zero = {0,0};
2187 /* AIX XL C 1.02.0.0 rejects this.
2188    It does not let you subtract one const X* pointer from another in an arm
2189    of an if-expression whose if-part is not a constant expression */
2190 const char *g = "string";
2191 ccp = &g + (g ? g-g : 0);
2192 /* HPUX 7.0 cc rejects these. */
2193 ++ccp;
2194 p = (char**) ccp;
2195 ccp = (char const *const *) p;
2196 { /* SCO 3.2v4 cc rejects this.  */
2197   char *t;
2198   char const *s = 0 ? (char *) 0 : (char const *) 0;
2199
2200   *t++ = 0;
2201 }
2202 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
2203   int x[] = {25, 17};
2204   const int *foo = &x[0];
2205   ++foo;
2206 }
2207 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2208   typedef const int *iptr;
2209   iptr p = 0;
2210   ++p;
2211 }
2212 { /* AIX XL C 1.02.0.0 rejects this saying
2213      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2214   struct s { int j; const int *ap[3]; };
2215   struct s *b; b->j = 5;
2216 }
2217 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2218   const int foo = 10;
2219 }
2220
2221 ; return 0; }
2222 EOF
2223 if { (eval echo configure:2224: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2224   rm -rf conftest*
2225   ac_cv_c_const=yes
2226 else
2227   echo "configure: failed program was:" >&5
2228   cat conftest.$ac_ext >&5
2229   rm -rf conftest*
2230   ac_cv_c_const=no
2231 fi
2232 rm -f conftest*
2233 fi
2234
2235 echo "$ac_t""$ac_cv_c_const" 1>&6
2236 if test $ac_cv_c_const = no; then
2237   cat >> confdefs.h <<\EOF
2238 #define const 
2239 EOF
2240
2241 fi
2242
2243 echo $ac_n "checking for size_t""... $ac_c" 1>&6
2244 echo "configure:2245: checking for size_t" >&5
2245 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
2246   echo $ac_n "(cached) $ac_c" 1>&6
2247 else
2248   cat > conftest.$ac_ext <<EOF
2249 #line 2250 "configure"
2250 #include "confdefs.h"
2251 #include <sys/types.h>
2252 #if STDC_HEADERS
2253 #include <stdlib.h>
2254 #include <stddef.h>
2255 #endif
2256 EOF
2257 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2258   egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2259   rm -rf conftest*
2260   ac_cv_type_size_t=yes
2261 else
2262   rm -rf conftest*
2263   ac_cv_type_size_t=no
2264 fi
2265 rm -f conftest*
2266
2267 fi
2268 echo "$ac_t""$ac_cv_type_size_t" 1>&6
2269 if test $ac_cv_type_size_t = no; then
2270   cat >> confdefs.h <<\EOF
2271 #define size_t unsigned
2272 EOF
2273
2274 fi
2275
2276 echo $ac_n "checking size of int""... $ac_c" 1>&6
2277 echo "configure:2278: checking size of int" >&5
2278 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
2279   echo $ac_n "(cached) $ac_c" 1>&6
2280 else
2281   if test "$cross_compiling" = yes; then
2282   ac_cv_sizeof_int=4
2283 else
2284   cat > conftest.$ac_ext <<EOF
2285 #line 2286 "configure"
2286 #include "confdefs.h"
2287 #include <stdio.h>
2288 main()
2289 {
2290   FILE *f=fopen("conftestval", "w");
2291   if (!f) exit(1);
2292   fprintf(f, "%d\n", sizeof(int));
2293   exit(0);
2294 }
2295 EOF
2296 if { (eval echo configure:2297: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2297 then
2298   ac_cv_sizeof_int=`cat conftestval`
2299 else
2300   echo "configure: failed program was:" >&5
2301   cat conftest.$ac_ext >&5
2302   rm -fr conftest*
2303   ac_cv_sizeof_int=0
2304 fi
2305 rm -fr conftest*
2306 fi
2307
2308 fi
2309 echo "$ac_t""$ac_cv_sizeof_int" 1>&6
2310 cat >> confdefs.h <<EOF
2311 #define SIZEOF_INT $ac_cv_sizeof_int
2312 EOF
2313
2314
2315 echo $ac_n "checking size of char *""... $ac_c" 1>&6
2316 echo "configure:2317: checking size of char *" >&5
2317 if eval "test \"`echo '$''{'ac_cv_sizeof_char_p'+set}'`\" = set"; then
2318   echo $ac_n "(cached) $ac_c" 1>&6
2319 else
2320   if test "$cross_compiling" = yes; then
2321   ac_cv_sizeof_char_p=4
2322 else
2323   cat > conftest.$ac_ext <<EOF
2324 #line 2325 "configure"
2325 #include "confdefs.h"
2326 #include <stdio.h>
2327 main()
2328 {
2329   FILE *f=fopen("conftestval", "w");
2330   if (!f) exit(1);
2331   fprintf(f, "%d\n", sizeof(char *));
2332   exit(0);
2333 }
2334 EOF
2335 if { (eval echo configure:2336: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2336 then
2337   ac_cv_sizeof_char_p=`cat conftestval`
2338 else
2339   echo "configure: failed program was:" >&5
2340   cat conftest.$ac_ext >&5
2341   rm -fr conftest*
2342   ac_cv_sizeof_char_p=0
2343 fi
2344 rm -fr conftest*
2345 fi
2346
2347 fi
2348 echo "$ac_t""$ac_cv_sizeof_char_p" 1>&6
2349 cat >> confdefs.h <<EOF
2350 #define SIZEOF_CHAR_P $ac_cv_sizeof_char_p
2351 EOF
2352
2353
2354 echo $ac_n "checking size of long""... $ac_c" 1>&6
2355 echo "configure:2356: checking size of long" >&5
2356 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
2357   echo $ac_n "(cached) $ac_c" 1>&6
2358 else
2359   if test "$cross_compiling" = yes; then
2360   ac_cv_sizeof_long=4
2361 else
2362   cat > conftest.$ac_ext <<EOF
2363 #line 2364 "configure"
2364 #include "confdefs.h"
2365 #include <stdio.h>
2366 main()
2367 {
2368   FILE *f=fopen("conftestval", "w");
2369   if (!f) exit(1);
2370   fprintf(f, "%d\n", sizeof(long));
2371   exit(0);
2372 }
2373 EOF
2374 if { (eval echo configure:2375: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2375 then
2376   ac_cv_sizeof_long=`cat conftestval`
2377 else
2378   echo "configure: failed program was:" >&5
2379   cat conftest.$ac_ext >&5
2380   rm -fr conftest*
2381   ac_cv_sizeof_long=0
2382 fi
2383 rm -fr conftest*
2384 fi
2385
2386 fi
2387 echo "$ac_t""$ac_cv_sizeof_long" 1>&6
2388 cat >> confdefs.h <<EOF
2389 #define SIZEOF_LONG $ac_cv_sizeof_long
2390 EOF
2391
2392
2393 echo $ac_n "checking size of long long""... $ac_c" 1>&6
2394 echo "configure:2395: checking size of long long" >&5
2395 if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
2396   echo $ac_n "(cached) $ac_c" 1>&6
2397 else
2398   if test "$cross_compiling" = yes; then
2399   ac_cv_sizeof_long_long=8
2400 else
2401   cat > conftest.$ac_ext <<EOF
2402 #line 2403 "configure"
2403 #include "confdefs.h"
2404 #include <stdio.h>
2405 main()
2406 {
2407   FILE *f=fopen("conftestval", "w");
2408   if (!f) exit(1);
2409   fprintf(f, "%d\n", sizeof(long long));
2410   exit(0);
2411 }
2412 EOF
2413 if { (eval echo configure:2414: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2414 then
2415   ac_cv_sizeof_long_long=`cat conftestval`
2416 else
2417   echo "configure: failed program was:" >&5
2418   cat conftest.$ac_ext >&5
2419   rm -fr conftest*
2420   ac_cv_sizeof_long_long=0
2421 fi
2422 rm -fr conftest*
2423 fi
2424
2425 fi
2426 echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6
2427 cat >> confdefs.h <<EOF
2428 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
2429 EOF
2430
2431
2432 echo $ac_n "checking size of size_t""... $ac_c" 1>&6
2433 echo "configure:2434: checking size of size_t" >&5
2434 if eval "test \"`echo '$''{'ac_cv_sizeof_size_t'+set}'`\" = set"; then
2435   echo $ac_n "(cached) $ac_c" 1>&6
2436 else
2437   if test "$cross_compiling" = yes; then
2438   ac_cv_sizeof_size_t=4
2439 else
2440   cat > conftest.$ac_ext <<EOF
2441 #line 2442 "configure"
2442 #include "confdefs.h"
2443 #include <stdio.h>
2444 main()
2445 {
2446   FILE *f=fopen("conftestval", "w");
2447   if (!f) exit(1);
2448   fprintf(f, "%d\n", sizeof(size_t));
2449   exit(0);
2450 }
2451 EOF
2452 if { (eval echo configure:2453: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2453 then
2454   ac_cv_sizeof_size_t=`cat conftestval`
2455 else
2456   echo "configure: failed program was:" >&5
2457   cat conftest.$ac_ext >&5
2458   rm -fr conftest*
2459   ac_cv_sizeof_size_t=0
2460 fi
2461 rm -fr conftest*
2462 fi
2463
2464 fi
2465 echo "$ac_t""$ac_cv_sizeof_size_t" 1>&6
2466 cat >> confdefs.h <<EOF
2467 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
2468 EOF
2469
2470
2471
2472
2473 for ac_func in strerror bcopy memmove
2474 do
2475 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2476 echo "configure:2477: checking for $ac_func" >&5
2477 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2478   echo $ac_n "(cached) $ac_c" 1>&6
2479 else
2480   cat > conftest.$ac_ext <<EOF
2481 #line 2482 "configure"
2482 #include "confdefs.h"
2483 /* System header to define __stub macros and hopefully few prototypes,
2484     which can conflict with char $ac_func(); below.  */
2485 #include <assert.h>
2486 /* Override any gcc2 internal prototype to avoid an error.  */
2487 /* We use char because int might match the return type of a gcc2
2488     builtin and then its argument prototype would still apply.  */
2489 char $ac_func();
2490
2491 int main() {
2492
2493 /* The GNU C library defines this for functions which it implements
2494     to always fail with ENOSYS.  Some functions are actually named
2495     something starting with __ and the normal name is an alias.  */
2496 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2497 choke me
2498 #else
2499 $ac_func();
2500 #endif
2501
2502 ; return 0; }
2503 EOF
2504 if { (eval echo configure:2505: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2505   rm -rf conftest*
2506   eval "ac_cv_func_$ac_func=yes"
2507 else
2508   echo "configure: failed program was:" >&5
2509   cat conftest.$ac_ext >&5
2510   rm -rf conftest*
2511   eval "ac_cv_func_$ac_func=no"
2512 fi
2513 rm -f conftest*
2514 fi
2515
2516 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2517   echo "$ac_t""yes" 1>&6
2518     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2519   cat >> confdefs.h <<EOF
2520 #define $ac_tr_func 1
2521 EOF
2522  
2523 else
2524   echo "$ac_t""no" 1>&6
2525 fi
2526 done
2527
2528
2529
2530 echo $ac_n "checking for pcre_compile in -lpcre""... $ac_c" 1>&6
2531 echo "configure:2532: checking for pcre_compile in -lpcre" >&5
2532 ac_lib_var=`echo pcre'_'pcre_compile | sed 'y%./+-%__p_%'`
2533 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2534   echo $ac_n "(cached) $ac_c" 1>&6
2535 else
2536   ac_save_LIBS="$LIBS"
2537 LIBS="-lpcre  $LIBS"
2538 cat > conftest.$ac_ext <<EOF
2539 #line 2540 "configure"
2540 #include "confdefs.h"
2541 /* Override any gcc2 internal prototype to avoid an error.  */
2542 /* We use char because int might match the return type of a gcc2
2543     builtin and then its argument prototype would still apply.  */
2544 char pcre_compile();
2545
2546 int main() {
2547 pcre_compile()
2548 ; return 0; }
2549 EOF
2550 if { (eval echo configure:2551: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2551   rm -rf conftest*
2552   eval "ac_cv_lib_$ac_lib_var=yes"
2553 else
2554   echo "configure: failed program was:" >&5
2555   cat conftest.$ac_ext >&5
2556   rm -rf conftest*
2557   eval "ac_cv_lib_$ac_lib_var=no"
2558 fi
2559 rm -f conftest*
2560 LIBS="$ac_save_LIBS"
2561
2562 fi
2563 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2564   echo "$ac_t""yes" 1>&6
2565   ac_safe=`echo "pcre.h" | sed 'y%./+-%__p_%'`
2566 echo $ac_n "checking for pcre.h""... $ac_c" 1>&6
2567 echo "configure:2568: checking for pcre.h" >&5
2568 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2569   echo $ac_n "(cached) $ac_c" 1>&6
2570 else
2571   cat > conftest.$ac_ext <<EOF
2572 #line 2573 "configure"
2573 #include "confdefs.h"
2574 #include <pcre.h>
2575 EOF
2576 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2577 { (eval echo configure:2578: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2578 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2579 if test -z "$ac_err"; then
2580   rm -rf conftest*
2581   eval "ac_cv_header_$ac_safe=yes"
2582 else
2583   echo "$ac_err" >&5
2584   echo "configure: failed program was:" >&5
2585   cat conftest.$ac_ext >&5
2586   rm -rf conftest*
2587   eval "ac_cv_header_$ac_safe=no"
2588 fi
2589 rm -f conftest*
2590 fi
2591 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2592   echo "$ac_t""yes" 1>&6
2593   have_pcre=yes
2594 else
2595   echo "$ac_t""no" 1>&6
2596 have_pcre=no
2597 fi
2598
2599 else
2600   echo "$ac_t""no" 1>&6
2601 have_pcre=no
2602 fi
2603
2604 echo $ac_n "checking for regcomp in -lpcreposix""... $ac_c" 1>&6
2605 echo "configure:2606: checking for regcomp in -lpcreposix" >&5
2606 ac_lib_var=`echo pcreposix'_'regcomp | sed 'y%./+-%__p_%'`
2607 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2608   echo $ac_n "(cached) $ac_c" 1>&6
2609 else
2610   ac_save_LIBS="$LIBS"
2611 LIBS="-lpcreposix -lpcre $LIBS"
2612 cat > conftest.$ac_ext <<EOF
2613 #line 2614 "configure"
2614 #include "confdefs.h"
2615 /* Override any gcc2 internal prototype to avoid an error.  */
2616 /* We use char because int might match the return type of a gcc2
2617     builtin and then its argument prototype would still apply.  */
2618 char regcomp();
2619
2620 int main() {
2621 regcomp()
2622 ; return 0; }
2623 EOF
2624 if { (eval echo configure:2625: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2625   rm -rf conftest*
2626   eval "ac_cv_lib_$ac_lib_var=yes"
2627 else
2628   echo "configure: failed program was:" >&5
2629   cat conftest.$ac_ext >&5
2630   rm -rf conftest*
2631   eval "ac_cv_lib_$ac_lib_var=no"
2632 fi
2633 rm -f conftest*
2634 LIBS="$ac_save_LIBS"
2635
2636 fi
2637 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2638   echo "$ac_t""yes" 1>&6
2639   ac_safe=`echo "pcreposix.h" | sed 'y%./+-%__p_%'`
2640 echo $ac_n "checking for pcreposix.h""... $ac_c" 1>&6
2641 echo "configure:2642: checking for pcreposix.h" >&5
2642 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2643   echo $ac_n "(cached) $ac_c" 1>&6
2644 else
2645   cat > conftest.$ac_ext <<EOF
2646 #line 2647 "configure"
2647 #include "confdefs.h"
2648 #include <pcreposix.h>
2649 EOF
2650 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2651 { (eval echo configure:2652: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2652 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2653 if test -z "$ac_err"; then
2654   rm -rf conftest*
2655   eval "ac_cv_header_$ac_safe=yes"
2656 else
2657   echo "$ac_err" >&5
2658   echo "configure: failed program was:" >&5
2659   cat conftest.$ac_ext >&5
2660   rm -rf conftest*
2661   eval "ac_cv_header_$ac_safe=no"
2662 fi
2663 rm -f conftest*
2664 fi
2665 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2666   echo "$ac_t""yes" 1>&6
2667   have_pcreposix=yes
2668 else
2669   echo "$ac_t""no" 1>&6
2670 have_pcreposix=no
2671 fi
2672
2673 else
2674   echo "$ac_t""no" 1>&6
2675 have_pcreposix=no
2676 fi
2677
2678 echo $ac_n "checking for pcrs_compile in -lpcrs""... $ac_c" 1>&6
2679 echo "configure:2680: checking for pcrs_compile in -lpcrs" >&5
2680 ac_lib_var=`echo pcrs'_'pcrs_compile | sed 'y%./+-%__p_%'`
2681 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2682   echo $ac_n "(cached) $ac_c" 1>&6
2683 else
2684   ac_save_LIBS="$LIBS"
2685 LIBS="-lpcrs  $LIBS"
2686 cat > conftest.$ac_ext <<EOF
2687 #line 2688 "configure"
2688 #include "confdefs.h"
2689 /* Override any gcc2 internal prototype to avoid an error.  */
2690 /* We use char because int might match the return type of a gcc2
2691     builtin and then its argument prototype would still apply.  */
2692 char pcrs_compile();
2693
2694 int main() {
2695 pcrs_compile()
2696 ; return 0; }
2697 EOF
2698 if { (eval echo configure:2699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2699   rm -rf conftest*
2700   eval "ac_cv_lib_$ac_lib_var=yes"
2701 else
2702   echo "configure: failed program was:" >&5
2703   cat conftest.$ac_ext >&5
2704   rm -rf conftest*
2705   eval "ac_cv_lib_$ac_lib_var=no"
2706 fi
2707 rm -f conftest*
2708 LIBS="$ac_save_LIBS"
2709
2710 fi
2711 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2712   echo "$ac_t""yes" 1>&6
2713   ac_safe=`echo "pcrs.h" | sed 'y%./+-%__p_%'`
2714 echo $ac_n "checking for pcrs.h""... $ac_c" 1>&6
2715 echo "configure:2716: checking for pcrs.h" >&5
2716 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+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 <pcrs.h>
2723 EOF
2724 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2725 { (eval echo configure:2726: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2726 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2727 if test -z "$ac_err"; then
2728   rm -rf conftest*
2729   eval "ac_cv_header_$ac_safe=yes"
2730 else
2731   echo "$ac_err" >&5
2732   echo "configure: failed program was:" >&5
2733   cat conftest.$ac_ext >&5
2734   rm -rf conftest*
2735   eval "ac_cv_header_$ac_safe=no"
2736 fi
2737 rm -f conftest*
2738 fi
2739 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2740   echo "$ac_t""yes" 1>&6
2741   have_pcrs=yes
2742 else
2743   echo "$ac_t""no" 1>&6
2744 have_pcrs=no
2745 fi
2746
2747 else
2748   echo "$ac_t""no" 1>&6
2749 have_pcrs=no
2750 fi
2751
2752
2753
2754
2755 cat >> confdefs.h <<\EOF
2756 #define __MT__ 1
2757 EOF
2758
2759
2760
2761 # Check whether --enable-toggle or --disable-toggle was given.
2762 if test "${enable_toggle+set}" = set; then
2763   enableval="$enable_toggle"
2764   if test $enableval = yes; then
2765   cat >> confdefs.h <<\EOF
2766 #define FEATURE_TOGGLE 1
2767 EOF
2768
2769 fi
2770 else
2771   cat >> confdefs.h <<\EOF
2772 #define FEATURE_TOGGLE 1
2773 EOF
2774
2775 fi
2776
2777
2778 # Check whether --enable-force or --disable-force was given.
2779 if test "${enable_force+set}" = set; then
2780   enableval="$enable_force"
2781   if test $enableval = yes; then
2782   cat >> confdefs.h <<\EOF
2783 #define FEATURE_FORCE_LOAD 1
2784 EOF
2785
2786 fi
2787 else
2788   cat >> confdefs.h <<\EOF
2789 #define FEATURE_FORCE_LOAD 1
2790 EOF
2791
2792 fi
2793
2794
2795 # Check whether --enable-fast-redirects or --disable-fast-redirects was given.
2796 if test "${enable_fast_redirects+set}" = set; then
2797   enableval="$enable_fast_redirects"
2798   if test $enableval = yes; then
2799   cat >> confdefs.h <<\EOF
2800 #define FEATURE_FAST_REDIRECTS 1
2801 EOF
2802
2803 fi
2804 else
2805   cat >> confdefs.h <<\EOF
2806 #define FEATURE_FAST_REDIRECTS 1
2807 EOF
2808
2809 fi
2810
2811
2812 # Check whether --enable-killpopup or --disable-killpopup was given.
2813 if test "${enable_killpopup+set}" = set; then
2814   enableval="$enable_killpopup"
2815   if test $enableval = yes; then
2816   cat >> confdefs.h <<\EOF
2817 #define FEATURE_KILL_POPUPS 1
2818 EOF
2819
2820 fi
2821 else
2822   cat >> confdefs.h <<\EOF
2823 #define FEATURE_KILL_POPUPS 1
2824 EOF
2825
2826 fi
2827
2828
2829 # Check whether --enable-stats or --disable-stats was given.
2830 if test "${enable_stats+set}" = set; then
2831   enableval="$enable_stats"
2832   if test $enableval = yes; then
2833   cat >> confdefs.h <<\EOF
2834 #define FEATURE_STATISTICS 1
2835 EOF
2836
2837 fi
2838 else
2839   cat >> confdefs.h <<\EOF
2840 #define FEATURE_STATISTICS 1
2841 EOF
2842
2843 fi
2844
2845
2846 # Check whether --enable-ie-images or --disable-ie-images was given.
2847 if test "${enable_ie_images+set}" = set; then
2848   enableval="$enable_ie_images"
2849   if test $enableval = yes; then
2850   cat >> confdefs.h <<\EOF
2851 #define FEATURE_IMAGE_DETECT_MSIE 1
2852 EOF
2853
2854 fi
2855 else
2856   cat >> confdefs.h <<\EOF
2857 #define FEATURE_IMAGE_DETECT_MSIE 1
2858 EOF
2859
2860 fi
2861
2862
2863 # Check whether --enable-image-blocking or --disable-image-blocking was given.
2864 if test "${enable_image_blocking+set}" = set; then
2865   enableval="$enable_image_blocking"
2866   if test $enableval = yes; then
2867   cat >> confdefs.h <<\EOF
2868 #define FEATURE_IMAGE_BLOCKING 1
2869 EOF
2870
2871 fi
2872 else
2873   cat >> confdefs.h <<\EOF
2874 #define FEATURE_IMAGE_BLOCKING 1
2875 EOF
2876
2877 fi
2878
2879
2880 # Check whether --enable-acl-files or --disable-acl-files was given.
2881 if test "${enable_acl_files+set}" = set; then
2882   enableval="$enable_acl_files"
2883   if test $enableval = yes; then
2884   cat >> confdefs.h <<\EOF
2885 #define FEATURE_ACL 1
2886 EOF
2887
2888 fi
2889 else
2890   cat >> confdefs.h <<\EOF
2891 #define FEATURE_ACL 1
2892 EOF
2893
2894 fi
2895
2896
2897 # Check whether --enable-trust-files or --disable-trust-files was given.
2898 if test "${enable_trust_files+set}" = set; then
2899   enableval="$enable_trust_files"
2900   if test $enableval = yes; then
2901   cat >> confdefs.h <<\EOF
2902 #define FEATURE_TRUST 1
2903 EOF
2904
2905 fi
2906 else
2907   cat >> confdefs.h <<\EOF
2908 #define FEATURE_TRUST 1
2909 EOF
2910
2911 fi
2912
2913
2914 # Check whether --enable-jar-files or --disable-jar-files was given.
2915 if test "${enable_jar_files+set}" = set; then
2916   enableval="$enable_jar_files"
2917   if test $enableval = yes; then
2918   cat >> confdefs.h <<\EOF
2919 #define FEATURE_COOKIE_JAR 1
2920 EOF
2921
2922 fi
2923 else
2924   cat >> confdefs.h <<\EOF
2925 #define FEATURE_COOKIE_JAR 1
2926 EOF
2927
2928 fi
2929
2930
2931 # Check whether --enable-editor or --disable-editor was given.
2932 if test "${enable_editor+set}" = set; then
2933   enableval="$enable_editor"
2934   if test $enableval = yes; then
2935   cat >> confdefs.h <<\EOF
2936 #define FEATURE_CGI_EDIT_ACTIONS 1
2937 EOF
2938
2939 fi
2940 else
2941   cat >> confdefs.h <<\EOF
2942 #define FEATURE_CGI_EDIT_ACTIONS 1
2943 EOF
2944
2945 fi
2946
2947
2948 # Check whether --enable-no-gifs or --disable-no-gifs was given.
2949 if test "${enable_no_gifs+set}" = set; then
2950   enableval="$enable_no_gifs"
2951   if test $enableval = yes; then
2952   cat >> confdefs.h <<\EOF
2953 #define FEATURE_NO_GIFS 1
2954 EOF
2955
2956 fi
2957 fi
2958
2959
2960
2961
2962 # Check whether --enable-regex-matching or --disable-regex-matching was given.
2963 if test "${enable_regex_matching+set}" = set; then
2964   enableval="$enable_regex_matching"
2965    regex_matching=$enableval 
2966 else
2967    regex_matching=pcre 
2968 fi
2969
2970
2971 # Check whether --enable-dynamic-pcre or --disable-dynamic-pcre was given.
2972 if test "${enable_dynamic_pcre+set}" = set; then
2973   enableval="$enable_dynamic_pcre"
2974    if test $enableval = "no"; then have_pcre=no; fi 
2975 fi
2976
2977
2978 # Check whether --enable-dynamic-pcrs or --disable-dynamic-pcrs was given.
2979 if test "${enable_dynamic_pcrs+set}" = set; then
2980   enableval="$enable_dynamic_pcrs"
2981    if test $enableval = "no"; then have_pcrs=no; fi 
2982 fi
2983
2984
2985
2986 # Is the regex URL matching based on libpcreposix, but we
2987 # don't have that library?
2988 #
2989 if test $have_pcreposix = "yes" -o $regex_matching != "pcre"; then
2990   dont_miss_pcreposix=yes
2991 else
2992   dont_miss_pcreposix=no
2993 fi
2994
2995 # If we have libpcre and either we also have pcreposix or
2996 # we don't need pcreposix, then link pcre dynamically; else
2997 # build it and link statically
2998 #
2999 if test $have_pcre = "yes" -a $dont_miss_pcreposix = "yes"; then
3000   echo "using libpcre"
3001   pcre_dyn=yes
3002   STATIC_PCRE_ONLY=#
3003   LIBS="$LIBS -lpcre"
3004 else
3005   echo "using built-in static pcre"
3006   pcre_dyn=no
3007   cat >> confdefs.h <<\EOF
3008 #define STATIC_PCRE 1
3009 EOF
3010
3011   STATIC_PCRE_ONLY=
3012 fi
3013
3014 # If we have libpcrs and pcre is linked dynamically
3015 # then also link pcrs dynamically, else build and link
3016 # pcrs statically
3017 #
3018 if test $have_pcrs = "yes" -a $pcre_dyn = "yes"; then
3019   echo "using libpcrs"
3020   STATIC_PCRS_ONLY=#
3021   LIBS="$LIBS -lpcrs"
3022 else
3023   echo "using built-in static pcrs"
3024   cat >> confdefs.h <<\EOF
3025 #define STATIC_PCRS 1
3026 EOF
3027
3028   STATIC_PCRS_ONLY=
3029 fi
3030
3031 # Which method should be used for URL matching?
3032 # pcre, gnu regex or prefix matching?
3033 #
3034 if test $regex_matching = "gnu"; then
3035   echo "using gnu regex for URL matching"
3036   cat >> confdefs.h <<\EOF
3037 #define REGEX_GNU 1
3038 EOF
3039
3040   GNU_REGEX_ONLY=
3041   PCRE_REGEX_ONLY=#
3042 elif test $regex_matching = "pcre"; then
3043   echo "using pcre regex for URL matching"
3044   cat >> confdefs.h <<\EOF
3045 #define REGEX_PCRE 1
3046 EOF
3047
3048   GNU_REGEX_ONLY=#
3049   PCRE_REGEX_ONLY=
3050   if test $pcre_dyn = "yes"; then
3051     LIBS="$LIBS -lpcreposix"
3052   fi
3053 else
3054   echo -e "using prefix matching for URLs\nHint: This does NOT make the executable any smaller!"
3055   GNU_REGEX_ONLY=#
3056   PCRE_REGEX_ONLY=#
3057 fi
3058
3059
3060
3061
3062
3063
3064
3065 CFLAGS=$old_CFLAGS_nospecial
3066
3067
3068
3069
3070 trap '' 1 2 15
3071 cat > confcache <<\EOF
3072 # This file is a shell script that caches the results of configure
3073 # tests run on this system so they can be shared between configure
3074 # scripts and configure runs.  It is not useful on other systems.
3075 # If it contains results you don't want to keep, you may remove or edit it.
3076 #
3077 # By default, configure uses ./config.cache as the cache file,
3078 # creating it if it does not exist already.  You can give configure
3079 # the --cache-file=FILE option to use a different cache file; that is
3080 # what configure does when it calls configure scripts in
3081 # subdirectories, so they share the cache.
3082 # Giving --cache-file=/dev/null disables caching, for debugging configure.
3083 # config.status only pays attention to the cache file if you give it the
3084 # --recheck option to rerun configure.
3085 #
3086 EOF
3087 # The following way of writing the cache mishandles newlines in values,
3088 # but we know of no workaround that is simple, portable, and efficient.
3089 # So, don't put newlines in cache variables' values.
3090 # Ultrix sh set writes to stderr and can't be redirected directly,
3091 # and sets the high bit in the cache file unless we assign to the vars.
3092 (set) 2>&1 |
3093   case `(ac_space=' '; set | grep ac_space) 2>&1` in
3094   *ac_space=\ *)
3095     # `set' does not quote correctly, so add quotes (double-quote substitution
3096     # turns \\\\ into \\, and sed turns \\ into \).
3097     sed -n \
3098       -e "s/'/'\\\\''/g" \
3099       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3100     ;;
3101   *)
3102     # `set' quotes correctly as required by POSIX, so do not add quotes.
3103     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3104     ;;
3105   esac >> confcache
3106 if cmp -s $cache_file confcache; then
3107   :
3108 else
3109   if test -w $cache_file; then
3110     echo "updating cache $cache_file"
3111     cat confcache > $cache_file
3112   else
3113     echo "not updating unwritable cache $cache_file"
3114   fi
3115 fi
3116 rm -f confcache
3117
3118 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
3119
3120 test "x$prefix" = xNONE && prefix=$ac_default_prefix
3121 # Let make expand exec_prefix.
3122 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3123
3124 # Any assignment to VPATH causes Sun make to only execute
3125 # the first set of double-colon rules, so remove it if not needed.
3126 # If there is a colon in the path, we need to keep it.
3127 if test "x$srcdir" = x.; then
3128   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
3129 fi
3130
3131 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
3132
3133 DEFS=-DHAVE_CONFIG_H
3134
3135 # Without the "./", some shells look in PATH for config.status.
3136 : ${CONFIG_STATUS=./config.status}
3137
3138 echo creating $CONFIG_STATUS
3139 rm -f $CONFIG_STATUS
3140 cat > $CONFIG_STATUS <<EOF
3141 #! /bin/sh
3142 # Generated automatically by configure.
3143 # Run this file to recreate the current configuration.
3144 # This directory was configured as follows,
3145 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3146 #
3147 # $0 $ac_configure_args
3148 #
3149 # Compiler output produced by configure, useful for debugging
3150 # configure, is in ./config.log if it exists.
3151
3152 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
3153 for ac_option
3154 do
3155   case "\$ac_option" in
3156   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3157     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3158     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
3159   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
3160     echo "$CONFIG_STATUS generated by autoconf version 2.13"
3161     exit 0 ;;
3162   -help | --help | --hel | --he | --h)
3163     echo "\$ac_cs_usage"; exit 0 ;;
3164   *) echo "\$ac_cs_usage"; exit 1 ;;
3165   esac
3166 done
3167
3168 ac_given_srcdir=$srcdir
3169
3170 trap 'rm -fr `echo "GNUmakefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
3171 EOF
3172 cat >> $CONFIG_STATUS <<EOF
3173
3174 # Protect against being on the right side of a sed subst in config.status.
3175 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3176  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
3177 $ac_vpsub
3178 $extrasub
3179 s%@SHELL@%$SHELL%g
3180 s%@CFLAGS@%$CFLAGS%g
3181 s%@CPPFLAGS@%$CPPFLAGS%g
3182 s%@CXXFLAGS@%$CXXFLAGS%g
3183 s%@FFLAGS@%$FFLAGS%g
3184 s%@DEFS@%$DEFS%g
3185 s%@LDFLAGS@%$LDFLAGS%g
3186 s%@LIBS@%$LIBS%g
3187 s%@exec_prefix@%$exec_prefix%g
3188 s%@prefix@%$prefix%g
3189 s%@program_transform_name@%$program_transform_name%g
3190 s%@bindir@%$bindir%g
3191 s%@sbindir@%$sbindir%g
3192 s%@libexecdir@%$libexecdir%g
3193 s%@datadir@%$datadir%g
3194 s%@sysconfdir@%$sysconfdir%g
3195 s%@sharedstatedir@%$sharedstatedir%g
3196 s%@localstatedir@%$localstatedir%g
3197 s%@libdir@%$libdir%g
3198 s%@includedir@%$includedir%g
3199 s%@oldincludedir@%$oldincludedir%g
3200 s%@infodir@%$infodir%g
3201 s%@mandir@%$mandir%g
3202 s%@host@%$host%g
3203 s%@host_alias@%$host_alias%g
3204 s%@host_cpu@%$host_cpu%g
3205 s%@host_vendor@%$host_vendor%g
3206 s%@host_os@%$host_os%g
3207 s%@VERSION_MAJOR@%$VERSION_MAJOR%g
3208 s%@VERSION_MINOR@%$VERSION_MINOR%g
3209 s%@VERSION_POINT@%$VERSION_POINT%g
3210 s%@VERSION_RPM_PACKAGE@%$VERSION_RPM_PACKAGE%g
3211 s%@CODE_STATUS@%$CODE_STATUS%g
3212 s%@CC@%$CC%g
3213 s%@CPP@%$CPP%g
3214 s%@GDB@%$GDB%g
3215 s%@WIN_ONLY@%$WIN_ONLY%g
3216 s%@WDUMP@%$WDUMP%g
3217 s%@DB2HTML@%$DB2HTML%g
3218 s%@RPMBIN@%$RPMBIN%g
3219 s%@RPM_BASE@%$RPM_BASE%g
3220 s%@JADEBIN@%$JADEBIN%g
3221 s%@DKPREFIX@%$DKPREFIX%g
3222 s%@PTHREAD_ONLY@%$PTHREAD_ONLY%g
3223 s%@SOCKET_LIB@%$SOCKET_LIB%g
3224 s%@AMIGAOS_ONLY@%$AMIGAOS_ONLY%g
3225 s%@EXEEXT@%$EXEEXT%g
3226 s%@OBJEXT@%$OBJEXT%g
3227 s%@GNU_REGEX_ONLY@%$GNU_REGEX_ONLY%g
3228 s%@PCRE_REGEX_ONLY@%$PCRE_REGEX_ONLY%g
3229 s%@STATIC_PCRE_ONLY@%$STATIC_PCRE_ONLY%g
3230 s%@STATIC_PCRS_ONLY@%$STATIC_PCRS_ONLY%g
3231 s%@SPECIAL_CFLAGS@%$SPECIAL_CFLAGS%g
3232 s%@PTHREAD_LIB@%$PTHREAD_LIB%g
3233
3234 CEOF
3235 EOF
3236
3237 cat >> $CONFIG_STATUS <<\EOF
3238
3239 # Split the substitutions into bite-sized pieces for seds with
3240 # small command number limits, like on Digital OSF/1 and HP-UX.
3241 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
3242 ac_file=1 # Number of current file.
3243 ac_beg=1 # First line for current file.
3244 ac_end=$ac_max_sed_cmds # Line after last line for current file.
3245 ac_more_lines=:
3246 ac_sed_cmds=""
3247 while $ac_more_lines; do
3248   if test $ac_beg -gt 1; then
3249     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
3250   else
3251     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
3252   fi
3253   if test ! -s conftest.s$ac_file; then
3254     ac_more_lines=false
3255     rm -f conftest.s$ac_file
3256   else
3257     if test -z "$ac_sed_cmds"; then
3258       ac_sed_cmds="sed -f conftest.s$ac_file"
3259     else
3260       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
3261     fi
3262     ac_file=`expr $ac_file + 1`
3263     ac_beg=$ac_end
3264     ac_end=`expr $ac_end + $ac_max_sed_cmds`
3265   fi
3266 done
3267 if test -z "$ac_sed_cmds"; then
3268   ac_sed_cmds=cat
3269 fi
3270 EOF
3271
3272 cat >> $CONFIG_STATUS <<EOF
3273
3274 CONFIG_FILES=\${CONFIG_FILES-"GNUmakefile"}
3275 EOF
3276 cat >> $CONFIG_STATUS <<\EOF
3277 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
3278   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3279   case "$ac_file" in
3280   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3281        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3282   *) ac_file_in="${ac_file}.in" ;;
3283   esac
3284
3285   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
3286
3287   # Remove last slash and all that follows it.  Not all systems have dirname.
3288   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3289   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3290     # The file is in a subdirectory.
3291     test ! -d "$ac_dir" && mkdir "$ac_dir"
3292     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
3293     # A "../" for each directory in $ac_dir_suffix.
3294     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
3295   else
3296     ac_dir_suffix= ac_dots=
3297   fi
3298
3299   case "$ac_given_srcdir" in
3300   .)  srcdir=.
3301       if test -z "$ac_dots"; then top_srcdir=.
3302       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
3303   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
3304   *) # Relative path.
3305     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
3306     top_srcdir="$ac_dots$ac_given_srcdir" ;;
3307   esac
3308
3309
3310   echo creating "$ac_file"
3311   rm -f "$ac_file"
3312   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
3313   case "$ac_file" in
3314   *Makefile*) ac_comsub="1i\\
3315 # $configure_input" ;;
3316   *) ac_comsub= ;;
3317   esac
3318
3319   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3320   sed -e "$ac_comsub
3321 s%@configure_input@%$configure_input%g
3322 s%@srcdir@%$srcdir%g
3323 s%@top_srcdir@%$top_srcdir%g
3324 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
3325 fi; done
3326 rm -f conftest.s*
3327
3328 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
3329 # NAME is the cpp macro being defined and VALUE is the value it is being given.
3330 #
3331 # ac_d sets the value in "#define NAME VALUE" lines.
3332 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
3333 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
3334 ac_dC='\3'
3335 ac_dD='%g'
3336 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
3337 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3338 ac_uB='\([      ]\)%\1#\2define\3'
3339 ac_uC=' '
3340 ac_uD='\4%g'
3341 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
3342 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3343 ac_eB='$%\1#\2define\3'
3344 ac_eC=' '
3345 ac_eD='%g'
3346
3347 if test "${CONFIG_HEADERS+set}" != set; then
3348 EOF
3349 cat >> $CONFIG_STATUS <<EOF
3350   CONFIG_HEADERS="config.h"
3351 EOF
3352 cat >> $CONFIG_STATUS <<\EOF
3353 fi
3354 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
3355   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3356   case "$ac_file" in
3357   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3358        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3359   *) ac_file_in="${ac_file}.in" ;;
3360   esac
3361
3362   echo creating $ac_file
3363
3364   rm -f conftest.frag conftest.in conftest.out
3365   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3366   cat $ac_file_inputs > conftest.in
3367
3368 EOF
3369
3370 # Transform confdefs.h into a sed script conftest.vals that substitutes
3371 # the proper values into config.h.in to produce config.h.  And first:
3372 # Protect against being on the right side of a sed subst in config.status.
3373 # Protect against being in an unquoted here document in config.status.
3374 rm -f conftest.vals
3375 cat > conftest.hdr <<\EOF
3376 s/[\\&%]/\\&/g
3377 s%[\\$`]%\\&%g
3378 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
3379 s%ac_d%ac_u%gp
3380 s%ac_u%ac_e%gp
3381 EOF
3382 sed -n -f conftest.hdr confdefs.h > conftest.vals
3383 rm -f conftest.hdr
3384
3385 # This sed command replaces #undef with comments.  This is necessary, for
3386 # example, in the case of _POSIX_SOURCE, which is predefined and required
3387 # on some systems where configure will not decide to define it.
3388 cat >> conftest.vals <<\EOF
3389 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
3390 EOF
3391
3392 # Break up conftest.vals because some shells have a limit on
3393 # the size of here documents, and old seds have small limits too.
3394
3395 rm -f conftest.tail
3396 while :
3397 do
3398   ac_lines=`grep -c . conftest.vals`
3399   # grep -c gives empty output for an empty file on some AIX systems.
3400   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
3401   # Write a limited-size here document to conftest.frag.
3402   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
3403   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
3404   echo 'CEOF
3405   sed -f conftest.frag conftest.in > conftest.out
3406   rm -f conftest.in
3407   mv conftest.out conftest.in
3408 ' >> $CONFIG_STATUS
3409   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
3410   rm -f conftest.vals
3411   mv conftest.tail conftest.vals
3412 done
3413 rm -f conftest.vals
3414
3415 cat >> $CONFIG_STATUS <<\EOF
3416   rm -f conftest.frag conftest.h
3417   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
3418   cat conftest.in >> conftest.h
3419   rm -f conftest.in
3420   if cmp -s $ac_file conftest.h 2>/dev/null; then
3421     echo "$ac_file is unchanged"
3422     rm -f conftest.h
3423   else
3424     # Remove last slash and all that follows it.  Not all systems have dirname.
3425       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3426       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3427       # The file is in a subdirectory.
3428       test ! -d "$ac_dir" && mkdir "$ac_dir"
3429     fi
3430     rm -f $ac_file
3431     mv conftest.h $ac_file
3432   fi
3433 fi; done
3434
3435 EOF
3436 cat >> $CONFIG_STATUS <<EOF
3437
3438 EOF
3439 cat >> $CONFIG_STATUS <<\EOF
3440
3441 exit 0
3442 EOF
3443 chmod +x $CONFIG_STATUS
3444 rm -fr confdefs* $ac_clean_files
3445 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
3446