Renaming #define STATIC to STATIC_PCRE
[privoxy.git] / configure
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13 
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6 #
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15   --enable-mingw32        Use mingw32 for a Windows GUI"
16 ac_help="$ac_help
17   --disable-toggle        Don't support temporary disable"
18 ac_help="$ac_help
19   --disable-pthread       Don't use POSIX threads (pthreads)"
20 ac_help="$ac_help
21   --enable-gzip           Allow gzip'ed transfer of documents. Note that this will make content modification impossible."
22 ac_help="$ac_help
23   --disable-force         Don't allow blockfle to be bypassed"
24 ac_help="$ac_help
25   --disable-fast-redirects Don't support fast redirects"
26 ac_help="$ac_help
27   --disable-killpopup     Never block popups"
28 ac_help="$ac_help
29   --disable-stats         Don't keep statistics"
30 ac_help="$ac_help
31   --disable-split-proxy-args  One big show-proxy-args page, not one per file."
32 ac_help="$ac_help
33   --disable-webdav        Don't support WebDAV.  This option stops MS Outlook
34                           Express from accessing HotMail e-mail."
35 ac_help="$ac_help
36   --disable-ie-images     Don't auto-detect whether a request from MS Internet
37                           Explorer is for an image or HTML."
38 ac_help="$ac_help
39   --disable-image-blocking  Don't try to figure out whether a request is 
40                             for an image or HTML - assume HTML."
41 ac_help="$ac_help
42   --disable-acl-files     Prevents the use of ACL files to control access to
43                           the proxy by IP address."
44 ac_help="$ac_help
45   --disable-trust-files   Prevents the use of trust files."
46 ac_help="$ac_help
47   --disable-jar-files     Prevents the use of jar files to capture cookies."
48 ac_help="$ac_help
49   --enable-regex-matching=pcre     Use perl-compatible regex for actionsfile pattern matching (default)
50   --enable-regex-matching=gnu      Use gnu style regex for actionsfile pattern matching (-> bigger binary)
51   --disable-regex-matching         Don't use regex matching, compare URL prefix instead (won't shrink birary)"
52 ac_help="$ac_help
53   --disable-dynamic-pcre           Use the built-in, static pcre, even if libpcre is available"
54 ac_help="$ac_help
55   --disable-dynamic-pcrs           Use the built-in, static pcrs, even if libpcrs is available"
56
57 # Initialize some variables set by options.
58 # The variables have the same names as the options, with
59 # dashes changed to underlines.
60 build=NONE
61 cache_file=./config.cache
62 exec_prefix=NONE
63 host=NONE
64 no_create=
65 nonopt=NONE
66 no_recursion=
67 prefix=NONE
68 program_prefix=NONE
69 program_suffix=NONE
70 program_transform_name=s,x,x,
71 silent=
72 site=
73 srcdir=
74 target=NONE
75 verbose=
76 x_includes=NONE
77 x_libraries=NONE
78 bindir='${exec_prefix}/bin'
79 sbindir='${exec_prefix}/sbin'
80 libexecdir='${exec_prefix}/libexec'
81 datadir='${prefix}/share'
82 sysconfdir='${prefix}/etc'
83 sharedstatedir='${prefix}/com'
84 localstatedir='${prefix}/var'
85 libdir='${exec_prefix}/lib'
86 includedir='${prefix}/include'
87 oldincludedir='/usr/include'
88 infodir='${prefix}/info'
89 mandir='${prefix}/man'
90
91 # Initialize some other variables.
92 subdirs=
93 MFLAGS= MAKEFLAGS=
94 SHELL=${CONFIG_SHELL-/bin/sh}
95 # Maximum number of lines to put in a shell here document.
96 ac_max_here_lines=12
97
98 ac_prev=
99 for ac_option
100 do
101
102   # If the previous option needs an argument, assign it.
103   if test -n "$ac_prev"; then
104     eval "$ac_prev=\$ac_option"
105     ac_prev=
106     continue
107   fi
108
109   case "$ac_option" in
110   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
111   *) ac_optarg= ;;
112   esac
113
114   # Accept the important Cygnus configure options, so we can diagnose typos.
115
116   case "$ac_option" in
117
118   -bindir | --bindir | --bindi | --bind | --bin | --bi)
119     ac_prev=bindir ;;
120   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
121     bindir="$ac_optarg" ;;
122
123   -build | --build | --buil | --bui | --bu)
124     ac_prev=build ;;
125   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
126     build="$ac_optarg" ;;
127
128   -cache-file | --cache-file | --cache-fil | --cache-fi \
129   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
130     ac_prev=cache_file ;;
131   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
132   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
133     cache_file="$ac_optarg" ;;
134
135   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
136     ac_prev=datadir ;;
137   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
138   | --da=*)
139     datadir="$ac_optarg" ;;
140
141   -disable-* | --disable-*)
142     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
143     # Reject names that are not valid shell variable names.
144     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
145       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
146     fi
147     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
148     eval "enable_${ac_feature}=no" ;;
149
150   -enable-* | --enable-*)
151     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
152     # Reject names that are not valid shell variable names.
153     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
154       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
155     fi
156     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
157     case "$ac_option" in
158       *=*) ;;
159       *) ac_optarg=yes ;;
160     esac
161     eval "enable_${ac_feature}='$ac_optarg'" ;;
162
163   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
164   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
165   | --exec | --exe | --ex)
166     ac_prev=exec_prefix ;;
167   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
168   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
169   | --exec=* | --exe=* | --ex=*)
170     exec_prefix="$ac_optarg" ;;
171
172   -gas | --gas | --ga | --g)
173     # Obsolete; use --with-gas.
174     with_gas=yes ;;
175
176   -help | --help | --hel | --he)
177     # Omit some internal or obsolete options to make the list less imposing.
178     # This message is too long to be a string in the A/UX 3.1 sh.
179     cat << EOF
180 Usage: configure [options] [host]
181 Options: [defaults in brackets after descriptions]
182 Configuration:
183   --cache-file=FILE       cache test results in FILE
184   --help                  print this message
185   --no-create             do not create output files
186   --quiet, --silent       do not print \`checking...' messages
187   --version               print the version of autoconf that created configure
188 Directory and file names:
189   --prefix=PREFIX         install architecture-independent files in PREFIX
190                           [$ac_default_prefix]
191   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
192                           [same as prefix]
193   --bindir=DIR            user executables in DIR [EPREFIX/bin]
194   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
195   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
196   --datadir=DIR           read-only architecture-independent data in DIR
197                           [PREFIX/share]
198   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
199   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
200                           [PREFIX/com]
201   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
202   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
203   --includedir=DIR        C header files in DIR [PREFIX/include]
204   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
205   --infodir=DIR           info documentation in DIR [PREFIX/info]
206   --mandir=DIR            man documentation in DIR [PREFIX/man]
207   --srcdir=DIR            find the sources in DIR [configure dir or ..]
208   --program-prefix=PREFIX prepend PREFIX to installed program names
209   --program-suffix=SUFFIX append SUFFIX to installed program names
210   --program-transform-name=PROGRAM
211                           run sed PROGRAM on installed program names
212 EOF
213     cat << EOF
214 Host type:
215   --build=BUILD           configure for building on BUILD [BUILD=HOST]
216   --host=HOST             configure for HOST [guessed]
217   --target=TARGET         configure for TARGET [TARGET=HOST]
218 Features and packages:
219   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
220   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
221   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
222   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
223   --x-includes=DIR        X include files are in DIR
224   --x-libraries=DIR       X library files are in DIR
225 EOF
226     if test -n "$ac_help"; then
227       echo "--enable and --with options recognized:$ac_help"
228     fi
229     exit 0 ;;
230
231   -host | --host | --hos | --ho)
232     ac_prev=host ;;
233   -host=* | --host=* | --hos=* | --ho=*)
234     host="$ac_optarg" ;;
235
236   -includedir | --includedir | --includedi | --included | --include \
237   | --includ | --inclu | --incl | --inc)
238     ac_prev=includedir ;;
239   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
240   | --includ=* | --inclu=* | --incl=* | --inc=*)
241     includedir="$ac_optarg" ;;
242
243   -infodir | --infodir | --infodi | --infod | --info | --inf)
244     ac_prev=infodir ;;
245   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
246     infodir="$ac_optarg" ;;
247
248   -libdir | --libdir | --libdi | --libd)
249     ac_prev=libdir ;;
250   -libdir=* | --libdir=* | --libdi=* | --libd=*)
251     libdir="$ac_optarg" ;;
252
253   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
254   | --libexe | --libex | --libe)
255     ac_prev=libexecdir ;;
256   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
257   | --libexe=* | --libex=* | --libe=*)
258     libexecdir="$ac_optarg" ;;
259
260   -localstatedir | --localstatedir | --localstatedi | --localstated \
261   | --localstate | --localstat | --localsta | --localst \
262   | --locals | --local | --loca | --loc | --lo)
263     ac_prev=localstatedir ;;
264   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
265   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
266   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
267     localstatedir="$ac_optarg" ;;
268
269   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
270     ac_prev=mandir ;;
271   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
272     mandir="$ac_optarg" ;;
273
274   -nfp | --nfp | --nf)
275     # Obsolete; use --without-fp.
276     with_fp=no ;;
277
278   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
279   | --no-cr | --no-c)
280     no_create=yes ;;
281
282   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
283   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
284     no_recursion=yes ;;
285
286   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
287   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
288   | --oldin | --oldi | --old | --ol | --o)
289     ac_prev=oldincludedir ;;
290   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
291   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
292   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
293     oldincludedir="$ac_optarg" ;;
294
295   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
296     ac_prev=prefix ;;
297   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
298     prefix="$ac_optarg" ;;
299
300   -program-prefix | --program-prefix | --program-prefi | --program-pref \
301   | --program-pre | --program-pr | --program-p)
302     ac_prev=program_prefix ;;
303   -program-prefix=* | --program-prefix=* | --program-prefi=* \
304   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
305     program_prefix="$ac_optarg" ;;
306
307   -program-suffix | --program-suffix | --program-suffi | --program-suff \
308   | --program-suf | --program-su | --program-s)
309     ac_prev=program_suffix ;;
310   -program-suffix=* | --program-suffix=* | --program-suffi=* \
311   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
312     program_suffix="$ac_optarg" ;;
313
314   -program-transform-name | --program-transform-name \
315   | --program-transform-nam | --program-transform-na \
316   | --program-transform-n | --program-transform- \
317   | --program-transform | --program-transfor \
318   | --program-transfo | --program-transf \
319   | --program-trans | --program-tran \
320   | --progr-tra | --program-tr | --program-t)
321     ac_prev=program_transform_name ;;
322   -program-transform-name=* | --program-transform-name=* \
323   | --program-transform-nam=* | --program-transform-na=* \
324   | --program-transform-n=* | --program-transform-=* \
325   | --program-transform=* | --program-transfor=* \
326   | --program-transfo=* | --program-transf=* \
327   | --program-trans=* | --program-tran=* \
328   | --progr-tra=* | --program-tr=* | --program-t=*)
329     program_transform_name="$ac_optarg" ;;
330
331   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
332   | -silent | --silent | --silen | --sile | --sil)
333     silent=yes ;;
334
335   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
336     ac_prev=sbindir ;;
337   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
338   | --sbi=* | --sb=*)
339     sbindir="$ac_optarg" ;;
340
341   -sharedstatedir | --sharedstatedir | --sharedstatedi \
342   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
343   | --sharedst | --shareds | --shared | --share | --shar \
344   | --sha | --sh)
345     ac_prev=sharedstatedir ;;
346   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
347   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
348   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
349   | --sha=* | --sh=*)
350     sharedstatedir="$ac_optarg" ;;
351
352   -site | --site | --sit)
353     ac_prev=site ;;
354   -site=* | --site=* | --sit=*)
355     site="$ac_optarg" ;;
356
357   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
358     ac_prev=srcdir ;;
359   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
360     srcdir="$ac_optarg" ;;
361
362   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
363   | --syscon | --sysco | --sysc | --sys | --sy)
364     ac_prev=sysconfdir ;;
365   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
366   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
367     sysconfdir="$ac_optarg" ;;
368
369   -target | --target | --targe | --targ | --tar | --ta | --t)
370     ac_prev=target ;;
371   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
372     target="$ac_optarg" ;;
373
374   -v | -verbose | --verbose | --verbos | --verbo | --verb)
375     verbose=yes ;;
376
377   -version | --version | --versio | --versi | --vers)
378     echo "configure generated by autoconf version 2.13"
379     exit 0 ;;
380
381   -with-* | --with-*)
382     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
383     # Reject names that are not valid shell variable names.
384     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
385       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
386     fi
387     ac_package=`echo $ac_package| sed 's/-/_/g'`
388     case "$ac_option" in
389       *=*) ;;
390       *) ac_optarg=yes ;;
391     esac
392     eval "with_${ac_package}='$ac_optarg'" ;;
393
394   -without-* | --without-*)
395     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
396     # Reject names that are not valid shell variable names.
397     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
398       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
399     fi
400     ac_package=`echo $ac_package| sed 's/-/_/g'`
401     eval "with_${ac_package}=no" ;;
402
403   --x)
404     # Obsolete; use --with-x.
405     with_x=yes ;;
406
407   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
408   | --x-incl | --x-inc | --x-in | --x-i)
409     ac_prev=x_includes ;;
410   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
411   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
412     x_includes="$ac_optarg" ;;
413
414   -x-libraries | --x-libraries | --x-librarie | --x-librari \
415   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
416     ac_prev=x_libraries ;;
417   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
418   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
419     x_libraries="$ac_optarg" ;;
420
421   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
422     ;;
423
424   *)
425     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
426       echo "configure: warning: $ac_option: invalid host type" 1>&2
427     fi
428     if test "x$nonopt" != xNONE; then
429       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
430     fi
431     nonopt="$ac_option"
432     ;;
433
434   esac
435 done
436
437 if test -n "$ac_prev"; then
438   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
439 fi
440
441 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
442
443 # File descriptor usage:
444 # 0 standard input
445 # 1 file creation
446 # 2 errors and warnings
447 # 3 some systems may open it to /dev/tty
448 # 4 used on the Kubota Titan
449 # 6 checking for... messages and results
450 # 5 compiler messages saved in config.log
451 if test "$silent" = yes; then
452   exec 6>/dev/null
453 else
454   exec 6>&1
455 fi
456 exec 5>./config.log
457
458 echo "\
459 This file contains any messages produced by compilers while
460 running configure, to aid debugging if configure makes a mistake.
461 " 1>&5
462
463 # Strip out --no-create and --no-recursion so they do not pile up.
464 # Also quote any args containing shell metacharacters.
465 ac_configure_args=
466 for ac_arg
467 do
468   case "$ac_arg" in
469   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
470   | --no-cr | --no-c) ;;
471   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
472   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
473   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
474   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
475   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
476   esac
477 done
478
479 # NLS nuisances.
480 # Only set these to C if already set.  These must not be set unconditionally
481 # because not all systems understand e.g. LANG=C (notably SCO).
482 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
483 # Non-C LC_CTYPE values break the ctype check.
484 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
485 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
486 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
487 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
488
489 # confdefs.h avoids OS command line length limits that DEFS can exceed.
490 rm -rf conftest* confdefs.h
491 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
492 echo > confdefs.h
493
494 # A filename unique to this package, relative to the directory that
495 # configure is in, which we can look for to find out if srcdir is correct.
496 ac_unique_file=jcc.c
497
498 # Find the source files, if location was not specified.
499 if test -z "$srcdir"; then
500   ac_srcdir_defaulted=yes
501   # Try the directory containing this script, then its parent.
502   ac_prog=$0
503   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
504   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
505   srcdir=$ac_confdir
506   if test ! -r $srcdir/$ac_unique_file; then
507     srcdir=..
508   fi
509 else
510   ac_srcdir_defaulted=no
511 fi
512 if test ! -r $srcdir/$ac_unique_file; then
513   if test "$ac_srcdir_defaulted" = yes; then
514     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
515   else
516     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
517   fi
518 fi
519 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
520
521 # Prefer explicitly selected file to automatically selected ones.
522 if test -z "$CONFIG_SITE"; then
523   if test "x$prefix" != xNONE; then
524     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
525   else
526     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
527   fi
528 fi
529 for ac_site_file in $CONFIG_SITE; do
530   if test -r "$ac_site_file"; then
531     echo "loading site script $ac_site_file"
532     . "$ac_site_file"
533   fi
534 done
535
536 if test -r "$cache_file"; then
537   echo "loading cache $cache_file"
538   . $cache_file
539 else
540   echo "creating cache $cache_file"
541   > $cache_file
542 fi
543
544 ac_ext=c
545 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
546 ac_cpp='$CPP $CPPFLAGS'
547 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
548 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
549 cross_compiling=$ac_cv_prog_cc_cross
550
551 ac_exeext=
552 ac_objext=o
553 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
554   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
555   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
556     ac_n= ac_c='
557 ' ac_t='        '
558   else
559     ac_n=-n ac_c= ac_t=
560   fi
561 else
562   ac_n= ac_c='\c' ac_t=
563 fi
564
565
566
567
568 VERSION_MAJOR=2
569 VERSION_MINOR=9
570 VERSION_POINT=8
571
572
573
574
575
576 cat >> confdefs.h <<\EOF
577 #define CODE_STATUS "alpha"
578 EOF
579
580
581 cat >> confdefs.h <<EOF
582 #define VERSION_MAJOR ${VERSION_MAJOR}
583 EOF
584
585 cat >> confdefs.h <<EOF
586 #define VERSION_MINOR ${VERSION_MINOR}
587 EOF
588
589 cat >> confdefs.h <<EOF
590 #define VERSION_POINT ${VERSION_POINT}
591 EOF
592
593 cat >> confdefs.h <<EOF
594 #define VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_POINT}"
595 EOF
596
597
598 # Extract the first word of "gcc", so it can be a program name with args.
599 set dummy gcc; ac_word=$2
600 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
601 echo "configure:602: checking for $ac_word" >&5
602 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
603   echo $ac_n "(cached) $ac_c" 1>&6
604 else
605   if test -n "$CC"; then
606   ac_cv_prog_CC="$CC" # Let the user override the test.
607 else
608   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
609   ac_dummy="$PATH"
610   for ac_dir in $ac_dummy; do
611     test -z "$ac_dir" && ac_dir=.
612     if test -f $ac_dir/$ac_word; then
613       ac_cv_prog_CC="gcc"
614       break
615     fi
616   done
617   IFS="$ac_save_ifs"
618 fi
619 fi
620 CC="$ac_cv_prog_CC"
621 if test -n "$CC"; then
622   echo "$ac_t""$CC" 1>&6
623 else
624   echo "$ac_t""no" 1>&6
625 fi
626
627 if test -z "$CC"; then
628   # Extract the first word of "cc", so it can be a program name with args.
629 set dummy cc; ac_word=$2
630 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
631 echo "configure:632: checking for $ac_word" >&5
632 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
633   echo $ac_n "(cached) $ac_c" 1>&6
634 else
635   if test -n "$CC"; then
636   ac_cv_prog_CC="$CC" # Let the user override the test.
637 else
638   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
639   ac_prog_rejected=no
640   ac_dummy="$PATH"
641   for ac_dir in $ac_dummy; do
642     test -z "$ac_dir" && ac_dir=.
643     if test -f $ac_dir/$ac_word; then
644       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
645         ac_prog_rejected=yes
646         continue
647       fi
648       ac_cv_prog_CC="cc"
649       break
650     fi
651   done
652   IFS="$ac_save_ifs"
653 if test $ac_prog_rejected = yes; then
654   # We found a bogon in the path, so make sure we never use it.
655   set dummy $ac_cv_prog_CC
656   shift
657   if test $# -gt 0; then
658     # We chose a different compiler from the bogus one.
659     # However, it has the same basename, so the bogon will be chosen
660     # first if we set CC to just the basename; use the full file name.
661     shift
662     set dummy "$ac_dir/$ac_word" "$@"
663     shift
664     ac_cv_prog_CC="$@"
665   fi
666 fi
667 fi
668 fi
669 CC="$ac_cv_prog_CC"
670 if test -n "$CC"; then
671   echo "$ac_t""$CC" 1>&6
672 else
673   echo "$ac_t""no" 1>&6
674 fi
675
676   if test -z "$CC"; then
677     case "`uname -s`" in
678     *win32* | *WIN32*)
679       # Extract the first word of "cl", so it can be a program name with args.
680 set dummy cl; ac_word=$2
681 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
682 echo "configure:683: checking for $ac_word" >&5
683 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
684   echo $ac_n "(cached) $ac_c" 1>&6
685 else
686   if test -n "$CC"; then
687   ac_cv_prog_CC="$CC" # Let the user override the test.
688 else
689   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
690   ac_dummy="$PATH"
691   for ac_dir in $ac_dummy; do
692     test -z "$ac_dir" && ac_dir=.
693     if test -f $ac_dir/$ac_word; then
694       ac_cv_prog_CC="cl"
695       break
696     fi
697   done
698   IFS="$ac_save_ifs"
699 fi
700 fi
701 CC="$ac_cv_prog_CC"
702 if test -n "$CC"; then
703   echo "$ac_t""$CC" 1>&6
704 else
705   echo "$ac_t""no" 1>&6
706 fi
707  ;;
708     esac
709   fi
710   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
711 fi
712
713 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
714 echo "configure:715: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
715
716 ac_ext=c
717 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
718 ac_cpp='$CPP $CPPFLAGS'
719 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
720 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
721 cross_compiling=$ac_cv_prog_cc_cross
722
723 cat > conftest.$ac_ext << EOF
724
725 #line 726 "configure"
726 #include "confdefs.h"
727
728 main(){return(0);}
729 EOF
730 if { (eval echo configure:731: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
731   ac_cv_prog_cc_works=yes
732   # If we can't run a trivial program, we are probably using a cross compiler.
733   if (./conftest; exit) 2>/dev/null; then
734     ac_cv_prog_cc_cross=no
735   else
736     ac_cv_prog_cc_cross=yes
737   fi
738 else
739   echo "configure: failed program was:" >&5
740   cat conftest.$ac_ext >&5
741   ac_cv_prog_cc_works=no
742 fi
743 rm -fr conftest*
744 ac_ext=c
745 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
746 ac_cpp='$CPP $CPPFLAGS'
747 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
748 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
749 cross_compiling=$ac_cv_prog_cc_cross
750
751 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
752 if test $ac_cv_prog_cc_works = no; then
753   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
754 fi
755 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
756 echo "configure:757: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
757 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
758 cross_compiling=$ac_cv_prog_cc_cross
759
760 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
761 echo "configure:762: checking whether we are using GNU C" >&5
762 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
763   echo $ac_n "(cached) $ac_c" 1>&6
764 else
765   cat > conftest.c <<EOF
766 #ifdef __GNUC__
767   yes;
768 #endif
769 EOF
770 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:771: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
771   ac_cv_prog_gcc=yes
772 else
773   ac_cv_prog_gcc=no
774 fi
775 fi
776
777 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
778
779 if test $ac_cv_prog_gcc = yes; then
780   GCC=yes
781 else
782   GCC=
783 fi
784
785 ac_test_CFLAGS="${CFLAGS+set}"
786 ac_save_CFLAGS="$CFLAGS"
787 CFLAGS=
788 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
789 echo "configure:790: checking whether ${CC-cc} accepts -g" >&5
790 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
791   echo $ac_n "(cached) $ac_c" 1>&6
792 else
793   echo 'void f(){}' > conftest.c
794 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
795   ac_cv_prog_cc_g=yes
796 else
797   ac_cv_prog_cc_g=no
798 fi
799 rm -f conftest*
800
801 fi
802
803 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
804 if test "$ac_test_CFLAGS" = set; then
805   CFLAGS="$ac_save_CFLAGS"
806 elif test $ac_cv_prog_cc_g = yes; then
807   if test "$GCC" = yes; then
808     CFLAGS="-g -O2"
809   else
810     CFLAGS="-g"
811   fi
812 else
813   if test "$GCC" = yes; then
814     CFLAGS="-O2"
815   else
816     CFLAGS=
817   fi
818 fi
819
820 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
821 echo "configure:822: checking how to run the C preprocessor" >&5
822 # On Suns, sometimes $CPP names a directory.
823 if test -n "$CPP" && test -d "$CPP"; then
824   CPP=
825 fi
826 if test -z "$CPP"; then
827 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
828   echo $ac_n "(cached) $ac_c" 1>&6
829 else
830     # This must be in double quotes, not single quotes, because CPP may get
831   # substituted into the Makefile and "${CC-cc}" will confuse make.
832   CPP="${CC-cc} -E"
833   # On the NeXT, cc -E runs the code through the compiler's parser,
834   # not just through cpp.
835   cat > conftest.$ac_ext <<EOF
836 #line 837 "configure"
837 #include "confdefs.h"
838 #include <assert.h>
839 Syntax Error
840 EOF
841 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
842 { (eval echo configure:843: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
843 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
844 if test -z "$ac_err"; then
845   :
846 else
847   echo "$ac_err" >&5
848   echo "configure: failed program was:" >&5
849   cat conftest.$ac_ext >&5
850   rm -rf conftest*
851   CPP="${CC-cc} -E -traditional-cpp"
852   cat > conftest.$ac_ext <<EOF
853 #line 854 "configure"
854 #include "confdefs.h"
855 #include <assert.h>
856 Syntax Error
857 EOF
858 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
859 { (eval echo configure:860: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
860 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
861 if test -z "$ac_err"; then
862   :
863 else
864   echo "$ac_err" >&5
865   echo "configure: failed program was:" >&5
866   cat conftest.$ac_ext >&5
867   rm -rf conftest*
868   CPP="${CC-cc} -nologo -E"
869   cat > conftest.$ac_ext <<EOF
870 #line 871 "configure"
871 #include "confdefs.h"
872 #include <assert.h>
873 Syntax Error
874 EOF
875 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
876 { (eval echo configure:877: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
877 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
878 if test -z "$ac_err"; then
879   :
880 else
881   echo "$ac_err" >&5
882   echo "configure: failed program was:" >&5
883   cat conftest.$ac_ext >&5
884   rm -rf conftest*
885   CPP=/lib/cpp
886 fi
887 rm -f conftest*
888 fi
889 rm -f conftest*
890 fi
891 rm -f conftest*
892   ac_cv_prog_CPP="$CPP"
893 fi
894   CPP="$ac_cv_prog_CPP"
895 else
896   ac_cv_prog_CPP="$CPP"
897 fi
898 echo "$ac_t""$CPP" 1>&6
899
900
901 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
902 echo "configure:903: checking for mingw32 environment" >&5
903 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
904   echo $ac_n "(cached) $ac_c" 1>&6
905 else
906   cat > conftest.$ac_ext <<EOF
907 #line 908 "configure"
908 #include "confdefs.h"
909
910 int main() {
911 return __MINGW32__;
912 ; return 0; }
913 EOF
914 if { (eval echo configure:915: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
915   rm -rf conftest*
916   ac_cv_mingw32=yes
917 else
918   echo "configure: failed program was:" >&5
919   cat conftest.$ac_ext >&5
920   rm -rf conftest*
921   ac_cv_mingw32=no
922 fi
923 rm -f conftest*
924 rm -f conftest*
925 fi
926
927 echo "$ac_t""$ac_cv_mingw32" 1>&6
928 MINGW32=
929 test "$ac_cv_mingw32" = yes && MINGW32=yes
930 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
931 echo "configure:932: checking for Cygwin environment" >&5
932 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
933   echo $ac_n "(cached) $ac_c" 1>&6
934 else
935   cat > conftest.$ac_ext <<EOF
936 #line 937 "configure"
937 #include "confdefs.h"
938
939 int main() {
940
941 #ifndef __CYGWIN__
942 #define __CYGWIN__ __CYGWIN32__
943 #endif
944 return __CYGWIN__;
945 ; return 0; }
946 EOF
947 if { (eval echo configure:948: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
948   rm -rf conftest*
949   ac_cv_cygwin=yes
950 else
951   echo "configure: failed program was:" >&5
952   cat conftest.$ac_ext >&5
953   rm -rf conftest*
954   ac_cv_cygwin=no
955 fi
956 rm -f conftest*
957 rm -f conftest*
958 fi
959
960 echo "$ac_t""$ac_cv_cygwin" 1>&6
961 CYGWIN=
962 test "$ac_cv_cygwin" = yes && CYGWIN=yes
963
964
965 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
966 echo "configure:967: checking for executable suffix" >&5
967 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
968   echo $ac_n "(cached) $ac_c" 1>&6
969 else
970   if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
971   ac_cv_exeext=.exe
972 else
973   rm -f conftest*
974   echo 'int main () { return 0; }' > conftest.$ac_ext
975   ac_cv_exeext=
976   if { (eval echo configure:977: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
977     for file in conftest.*; do
978       case $file in
979       *.c | *.o | *.obj) ;;
980       *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
981       esac
982     done
983   else
984     { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
985   fi
986   rm -f conftest*
987   test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
988 fi
989 fi
990
991 EXEEXT=""
992 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
993 echo "$ac_t""${ac_cv_exeext}" 1>&6
994 ac_exeext=$EXEEXT
995
996 echo $ac_n "checking for object suffix""... $ac_c" 1>&6
997 echo "configure:998: checking for object suffix" >&5
998 if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
999   echo $ac_n "(cached) $ac_c" 1>&6
1000 else
1001   rm -f conftest*
1002 echo 'int i = 1;' > conftest.$ac_ext
1003 if { (eval echo configure:1004: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1004   for ac_file in conftest.*; do
1005     case $ac_file in
1006     *.c) ;;
1007     *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
1008     esac
1009   done
1010 else
1011   { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
1012 fi
1013 rm -f conftest*
1014 fi
1015
1016 echo "$ac_t""$ac_cv_objext" 1>&6
1017 OBJEXT=$ac_cv_objext
1018 ac_objext=$ac_cv_objext
1019
1020
1021 echo $ac_n "checking for pcre_compile in -lpcre""... $ac_c" 1>&6
1022 echo "configure:1023: checking for pcre_compile in -lpcre" >&5
1023 ac_lib_var=`echo pcre'_'pcre_compile | sed 'y%./+-%__p_%'`
1024 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1025   echo $ac_n "(cached) $ac_c" 1>&6
1026 else
1027   ac_save_LIBS="$LIBS"
1028 LIBS="-lpcre  $LIBS"
1029 cat > conftest.$ac_ext <<EOF
1030 #line 1031 "configure"
1031 #include "confdefs.h"
1032 /* Override any gcc2 internal prototype to avoid an error.  */
1033 /* We use char because int might match the return type of a gcc2
1034     builtin and then its argument prototype would still apply.  */
1035 char pcre_compile();
1036
1037 int main() {
1038 pcre_compile()
1039 ; return 0; }
1040 EOF
1041 if { (eval echo configure:1042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1042   rm -rf conftest*
1043   eval "ac_cv_lib_$ac_lib_var=yes"
1044 else
1045   echo "configure: failed program was:" >&5
1046   cat conftest.$ac_ext >&5
1047   rm -rf conftest*
1048   eval "ac_cv_lib_$ac_lib_var=no"
1049 fi
1050 rm -f conftest*
1051 LIBS="$ac_save_LIBS"
1052
1053 fi
1054 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1055   echo "$ac_t""yes" 1>&6
1056   ac_safe=`echo "pcre.h" | sed 'y%./+-%__p_%'`
1057 echo $ac_n "checking for pcre.h""... $ac_c" 1>&6
1058 echo "configure:1059: checking for pcre.h" >&5
1059 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1060   echo $ac_n "(cached) $ac_c" 1>&6
1061 else
1062   cat > conftest.$ac_ext <<EOF
1063 #line 1064 "configure"
1064 #include "confdefs.h"
1065 #include <pcre.h>
1066 EOF
1067 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1068 { (eval echo configure:1069: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1069 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1070 if test -z "$ac_err"; then
1071   rm -rf conftest*
1072   eval "ac_cv_header_$ac_safe=yes"
1073 else
1074   echo "$ac_err" >&5
1075   echo "configure: failed program was:" >&5
1076   cat conftest.$ac_ext >&5
1077   rm -rf conftest*
1078   eval "ac_cv_header_$ac_safe=no"
1079 fi
1080 rm -f conftest*
1081 fi
1082 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1083   echo "$ac_t""yes" 1>&6
1084   have_pcre=yes
1085 else
1086   echo "$ac_t""no" 1>&6
1087 have_pcre=no
1088 fi
1089
1090 else
1091   echo "$ac_t""no" 1>&6
1092 have_pcre=no
1093 fi
1094
1095 echo $ac_n "checking for regcomp in -lpcreposix""... $ac_c" 1>&6
1096 echo "configure:1097: checking for regcomp in -lpcreposix" >&5
1097 ac_lib_var=`echo pcreposix'_'regcomp | sed 'y%./+-%__p_%'`
1098 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1099   echo $ac_n "(cached) $ac_c" 1>&6
1100 else
1101   ac_save_LIBS="$LIBS"
1102 LIBS="-lpcreposix -lpcre $LIBS"
1103 cat > conftest.$ac_ext <<EOF
1104 #line 1105 "configure"
1105 #include "confdefs.h"
1106 /* Override any gcc2 internal prototype to avoid an error.  */
1107 /* We use char because int might match the return type of a gcc2
1108     builtin and then its argument prototype would still apply.  */
1109 char regcomp();
1110
1111 int main() {
1112 regcomp()
1113 ; return 0; }
1114 EOF
1115 if { (eval echo configure:1116: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1116   rm -rf conftest*
1117   eval "ac_cv_lib_$ac_lib_var=yes"
1118 else
1119   echo "configure: failed program was:" >&5
1120   cat conftest.$ac_ext >&5
1121   rm -rf conftest*
1122   eval "ac_cv_lib_$ac_lib_var=no"
1123 fi
1124 rm -f conftest*
1125 LIBS="$ac_save_LIBS"
1126
1127 fi
1128 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1129   echo "$ac_t""yes" 1>&6
1130   ac_safe=`echo "pcreposix.h" | sed 'y%./+-%__p_%'`
1131 echo $ac_n "checking for pcreposix.h""... $ac_c" 1>&6
1132 echo "configure:1133: checking for pcreposix.h" >&5
1133 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1134   echo $ac_n "(cached) $ac_c" 1>&6
1135 else
1136   cat > conftest.$ac_ext <<EOF
1137 #line 1138 "configure"
1138 #include "confdefs.h"
1139 #include <pcreposix.h>
1140 EOF
1141 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1142 { (eval echo configure:1143: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1143 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1144 if test -z "$ac_err"; then
1145   rm -rf conftest*
1146   eval "ac_cv_header_$ac_safe=yes"
1147 else
1148   echo "$ac_err" >&5
1149   echo "configure: failed program was:" >&5
1150   cat conftest.$ac_ext >&5
1151   rm -rf conftest*
1152   eval "ac_cv_header_$ac_safe=no"
1153 fi
1154 rm -f conftest*
1155 fi
1156 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1157   echo "$ac_t""yes" 1>&6
1158   have_pcreposix=yes
1159 else
1160   echo "$ac_t""no" 1>&6
1161 have_pcreposix=no
1162 fi
1163
1164 else
1165   echo "$ac_t""no" 1>&6
1166 have_pcreposix=no
1167 fi
1168
1169 echo $ac_n "checking for pcrs_compile in -lpcrs""... $ac_c" 1>&6
1170 echo "configure:1171: checking for pcrs_compile in -lpcrs" >&5
1171 ac_lib_var=`echo pcrs'_'pcrs_compile | sed 'y%./+-%__p_%'`
1172 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1173   echo $ac_n "(cached) $ac_c" 1>&6
1174 else
1175   ac_save_LIBS="$LIBS"
1176 LIBS="-lpcrs  $LIBS"
1177 cat > conftest.$ac_ext <<EOF
1178 #line 1179 "configure"
1179 #include "confdefs.h"
1180 /* Override any gcc2 internal prototype to avoid an error.  */
1181 /* We use char because int might match the return type of a gcc2
1182     builtin and then its argument prototype would still apply.  */
1183 char pcrs_compile();
1184
1185 int main() {
1186 pcrs_compile()
1187 ; return 0; }
1188 EOF
1189 if { (eval echo configure:1190: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1190   rm -rf conftest*
1191   eval "ac_cv_lib_$ac_lib_var=yes"
1192 else
1193   echo "configure: failed program was:" >&5
1194   cat conftest.$ac_ext >&5
1195   rm -rf conftest*
1196   eval "ac_cv_lib_$ac_lib_var=no"
1197 fi
1198 rm -f conftest*
1199 LIBS="$ac_save_LIBS"
1200
1201 fi
1202 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1203   echo "$ac_t""yes" 1>&6
1204   ac_safe=`echo "pcrs.h" | sed 'y%./+-%__p_%'`
1205 echo $ac_n "checking for pcrs.h""... $ac_c" 1>&6
1206 echo "configure:1207: checking for pcrs.h" >&5
1207 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1208   echo $ac_n "(cached) $ac_c" 1>&6
1209 else
1210   cat > conftest.$ac_ext <<EOF
1211 #line 1212 "configure"
1212 #include "confdefs.h"
1213 #include <pcrs.h>
1214 EOF
1215 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1216 { (eval echo configure:1217: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1217 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1218 if test -z "$ac_err"; then
1219   rm -rf conftest*
1220   eval "ac_cv_header_$ac_safe=yes"
1221 else
1222   echo "$ac_err" >&5
1223   echo "configure: failed program was:" >&5
1224   cat conftest.$ac_ext >&5
1225   rm -rf conftest*
1226   eval "ac_cv_header_$ac_safe=no"
1227 fi
1228 rm -f conftest*
1229 fi
1230 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1231   echo "$ac_t""yes" 1>&6
1232   have_pcrs=yes
1233 else
1234   echo "$ac_t""no" 1>&6
1235 have_pcrs=no
1236 fi
1237
1238 else
1239   echo "$ac_t""no" 1>&6
1240 have_pcrs=no
1241 fi
1242
1243
1244 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1245 echo "configure:1246: checking for ANSI C header files" >&5
1246 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1247   echo $ac_n "(cached) $ac_c" 1>&6
1248 else
1249   cat > conftest.$ac_ext <<EOF
1250 #line 1251 "configure"
1251 #include "confdefs.h"
1252 #include <stdlib.h>
1253 #include <stdarg.h>
1254 #include <string.h>
1255 #include <float.h>
1256 EOF
1257 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1258 { (eval echo configure:1259: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1259 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1260 if test -z "$ac_err"; then
1261   rm -rf conftest*
1262   ac_cv_header_stdc=yes
1263 else
1264   echo "$ac_err" >&5
1265   echo "configure: failed program was:" >&5
1266   cat conftest.$ac_ext >&5
1267   rm -rf conftest*
1268   ac_cv_header_stdc=no
1269 fi
1270 rm -f conftest*
1271
1272 if test $ac_cv_header_stdc = yes; then
1273   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1274 cat > conftest.$ac_ext <<EOF
1275 #line 1276 "configure"
1276 #include "confdefs.h"
1277 #include <string.h>
1278 EOF
1279 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1280   egrep "memchr" >/dev/null 2>&1; then
1281   :
1282 else
1283   rm -rf conftest*
1284   ac_cv_header_stdc=no
1285 fi
1286 rm -f conftest*
1287
1288 fi
1289
1290 if test $ac_cv_header_stdc = yes; then
1291   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1292 cat > conftest.$ac_ext <<EOF
1293 #line 1294 "configure"
1294 #include "confdefs.h"
1295 #include <stdlib.h>
1296 EOF
1297 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1298   egrep "free" >/dev/null 2>&1; then
1299   :
1300 else
1301   rm -rf conftest*
1302   ac_cv_header_stdc=no
1303 fi
1304 rm -f conftest*
1305
1306 fi
1307
1308 if test $ac_cv_header_stdc = yes; then
1309   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1310 if test "$cross_compiling" = yes; then
1311   :
1312 else
1313   cat > conftest.$ac_ext <<EOF
1314 #line 1315 "configure"
1315 #include "confdefs.h"
1316 #include <ctype.h>
1317 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1318 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1319 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1320 int main () { int i; for (i = 0; i < 256; i++)
1321 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1322 exit (0); }
1323
1324 EOF
1325 if { (eval echo configure:1326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1326 then
1327   :
1328 else
1329   echo "configure: failed program was:" >&5
1330   cat conftest.$ac_ext >&5
1331   rm -fr conftest*
1332   ac_cv_header_stdc=no
1333 fi
1334 rm -fr conftest*
1335 fi
1336
1337 fi
1338 fi
1339
1340 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1341 if test $ac_cv_header_stdc = yes; then
1342   cat >> confdefs.h <<\EOF
1343 #define STDC_HEADERS 1
1344 EOF
1345
1346 fi
1347
1348
1349 echo $ac_n "checking for working const""... $ac_c" 1>&6
1350 echo "configure:1351: checking for working const" >&5
1351 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1352   echo $ac_n "(cached) $ac_c" 1>&6
1353 else
1354   cat > conftest.$ac_ext <<EOF
1355 #line 1356 "configure"
1356 #include "confdefs.h"
1357
1358 int main() {
1359
1360 /* Ultrix mips cc rejects this.  */
1361 typedef int charset[2]; const charset x;
1362 /* SunOS 4.1.1 cc rejects this.  */
1363 char const *const *ccp;
1364 char **p;
1365 /* NEC SVR4.0.2 mips cc rejects this.  */
1366 struct point {int x, y;};
1367 static struct point const zero = {0,0};
1368 /* AIX XL C 1.02.0.0 rejects this.
1369    It does not let you subtract one const X* pointer from another in an arm
1370    of an if-expression whose if-part is not a constant expression */
1371 const char *g = "string";
1372 ccp = &g + (g ? g-g : 0);
1373 /* HPUX 7.0 cc rejects these. */
1374 ++ccp;
1375 p = (char**) ccp;
1376 ccp = (char const *const *) p;
1377 { /* SCO 3.2v4 cc rejects this.  */
1378   char *t;
1379   char const *s = 0 ? (char *) 0 : (char const *) 0;
1380
1381   *t++ = 0;
1382 }
1383 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
1384   int x[] = {25, 17};
1385   const int *foo = &x[0];
1386   ++foo;
1387 }
1388 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1389   typedef const int *iptr;
1390   iptr p = 0;
1391   ++p;
1392 }
1393 { /* AIX XL C 1.02.0.0 rejects this saying
1394      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1395   struct s { int j; const int *ap[3]; };
1396   struct s *b; b->j = 5;
1397 }
1398 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1399   const int foo = 10;
1400 }
1401
1402 ; return 0; }
1403 EOF
1404 if { (eval echo configure:1405: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1405   rm -rf conftest*
1406   ac_cv_c_const=yes
1407 else
1408   echo "configure: failed program was:" >&5
1409   cat conftest.$ac_ext >&5
1410   rm -rf conftest*
1411   ac_cv_c_const=no
1412 fi
1413 rm -f conftest*
1414 fi
1415
1416 echo "$ac_t""$ac_cv_c_const" 1>&6
1417 if test $ac_cv_c_const = no; then
1418   cat >> confdefs.h <<\EOF
1419 #define const 
1420 EOF
1421
1422 fi
1423
1424 echo $ac_n "checking for size_t""... $ac_c" 1>&6
1425 echo "configure:1426: checking for size_t" >&5
1426 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1427   echo $ac_n "(cached) $ac_c" 1>&6
1428 else
1429   cat > conftest.$ac_ext <<EOF
1430 #line 1431 "configure"
1431 #include "confdefs.h"
1432 #include <sys/types.h>
1433 #if STDC_HEADERS
1434 #include <stdlib.h>
1435 #include <stddef.h>
1436 #endif
1437 EOF
1438 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1439   egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1440   rm -rf conftest*
1441   ac_cv_type_size_t=yes
1442 else
1443   rm -rf conftest*
1444   ac_cv_type_size_t=no
1445 fi
1446 rm -f conftest*
1447
1448 fi
1449 echo "$ac_t""$ac_cv_type_size_t" 1>&6
1450 if test $ac_cv_type_size_t = no; then
1451   cat >> confdefs.h <<\EOF
1452 #define size_t unsigned
1453 EOF
1454
1455 fi
1456
1457
1458 for ac_func in strerror bcopy memmove
1459 do
1460 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1461 echo "configure:1462: checking for $ac_func" >&5
1462 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1463   echo $ac_n "(cached) $ac_c" 1>&6
1464 else
1465   cat > conftest.$ac_ext <<EOF
1466 #line 1467 "configure"
1467 #include "confdefs.h"
1468 /* System header to define __stub macros and hopefully few prototypes,
1469     which can conflict with char $ac_func(); below.  */
1470 #include <assert.h>
1471 /* Override any gcc2 internal prototype to avoid an error.  */
1472 /* We use char because int might match the return type of a gcc2
1473     builtin and then its argument prototype would still apply.  */
1474 char $ac_func();
1475
1476 int main() {
1477
1478 /* The GNU C library defines this for functions which it implements
1479     to always fail with ENOSYS.  Some functions are actually named
1480     something starting with __ and the normal name is an alias.  */
1481 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1482 choke me
1483 #else
1484 $ac_func();
1485 #endif
1486
1487 ; return 0; }
1488 EOF
1489 if { (eval echo configure:1490: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1490   rm -rf conftest*
1491   eval "ac_cv_func_$ac_func=yes"
1492 else
1493   echo "configure: failed program was:" >&5
1494   cat conftest.$ac_ext >&5
1495   rm -rf conftest*
1496   eval "ac_cv_func_$ac_func=no"
1497 fi
1498 rm -f conftest*
1499 fi
1500
1501 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1502   echo "$ac_t""yes" 1>&6
1503     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1504   cat >> confdefs.h <<EOF
1505 #define $ac_tr_func 1
1506 EOF
1507  
1508 else
1509   echo "$ac_t""no" 1>&6
1510 fi
1511 done
1512
1513
1514
1515
1516 # Check whether --enable-mingw32 or --disable-mingw32 was given.
1517 if test "${enable_mingw32+set}" = set; then
1518   enableval="$enable_mingw32"
1519   if test $enableval = yes; then
1520     WIN_ONLY=
1521     CYGWIN_FLAGS="-mwindows -mno-cygwin"
1522     PTHREAD_LIB=-lpthreadGC
1523     echo "Using mingw32 (Win32 GUI)"
1524   else
1525     WIN_ONLY=#
1526     if test "$CYGWIN" = "yes"; then
1527       CYGWIN_FLAGS="-mno-win32"
1528       PTHREAD_LIB=
1529       echo "Using Cygnus (Win32 command line)"
1530     else
1531       CYGWIN_FLAGS=
1532       PTHREAD_LIB=-lpthread
1533     fi
1534   fi
1535 else
1536   if test "$MINGW32" = "yes"; then
1537     WIN_ONLY=
1538     CYGWIN_FLAGS="-mwindows -mno-cygwin"
1539     PTHREAD_LIB=-lpthreadGC
1540     echo "Using mingw32 (Win32 GUI)"
1541   else
1542     WIN_ONLY=#
1543     if test "$CYGWIN" = "yes"; then
1544       CYGWIN_FLAGS="-mno-win32"
1545       PTHREAD_LIB=
1546       echo "Using Cygnus (Win32 command line)"
1547     else
1548       CYGWIN_FLAGS=
1549       PTHREAD_LIB=-lpthread
1550     fi
1551   fi
1552 fi
1553
1554
1555
1556
1557
1558
1559 SOLARIS_ONLY=#
1560
1561
1562
1563 # Check whether --enable-toggle or --disable-toggle was given.
1564 if test "${enable_toggle+set}" = set; then
1565   enableval="$enable_toggle"
1566   if test $enableval = yes; then
1567   cat >> confdefs.h <<\EOF
1568 #define TOGGLE 1
1569 EOF
1570
1571 fi
1572 else
1573   cat >> confdefs.h <<\EOF
1574 #define TOGGLE 1
1575 EOF
1576
1577 fi
1578
1579
1580 # Check whether --enable-pthread or --disable-pthread was given.
1581 if test "${enable_pthread+set}" = set; then
1582   enableval="$enable_pthread"
1583   if test $enableval = yes; then
1584   PTHREAD_ONLY=
1585   cat >> confdefs.h <<\EOF
1586 #define FEATURE_PTHREAD 1
1587 EOF
1588
1589 else
1590   PTHREAD_ONLY=#
1591 fi
1592 else
1593   cat >> confdefs.h <<\EOF
1594 #define FEATURE_PTHREAD 1
1595 EOF
1596
1597   PTHREAD_ONLY=
1598
1599 fi
1600
1601
1602
1603 # Check whether --enable-gzip or --disable-gzip was given.
1604 if test "${enable_gzip+set}" = set; then
1605   enableval="$enable_gzip"
1606   if test $enableval = "no"; then
1607   cat >> confdefs.h <<\EOF
1608 #define DENY_GZIP 1
1609 EOF
1610
1611 fi
1612 fi
1613
1614
1615 # Check whether --enable-force or --disable-force was given.
1616 if test "${enable_force+set}" = set; then
1617   enableval="$enable_force"
1618   if test $enableval = yes; then
1619   cat >> confdefs.h <<\EOF
1620 #define FORCE_LOAD 1
1621 EOF
1622
1623 fi
1624 else
1625   cat >> confdefs.h <<\EOF
1626 #define FORCE_LOAD 1
1627 EOF
1628
1629 fi
1630
1631
1632 # Check whether --enable-fast-redirects or --disable-fast-redirects was given.
1633 if test "${enable_fast_redirects+set}" = set; then
1634   enableval="$enable_fast_redirects"
1635   if test $enableval = yes; then
1636   cat >> confdefs.h <<\EOF
1637 #define FAST_REDIRECTS 1
1638 EOF
1639
1640 fi
1641 else
1642   cat >> confdefs.h <<\EOF
1643 #define FAST_REDIRECTS 1
1644 EOF
1645
1646 fi
1647
1648
1649 # Check whether --enable-killpopup or --disable-killpopup was given.
1650 if test "${enable_killpopup+set}" = set; then
1651   enableval="$enable_killpopup"
1652   if test $enableval = yes; then
1653   cat >> confdefs.h <<\EOF
1654 #define KILLPOPUPS 1
1655 EOF
1656
1657 fi
1658 else
1659   cat >> confdefs.h <<\EOF
1660 #define KILLPOPUPS 1
1661 EOF
1662
1663 fi
1664
1665
1666 # Check whether --enable-stats or --disable-stats was given.
1667 if test "${enable_stats+set}" = set; then
1668   enableval="$enable_stats"
1669   if test $enableval = yes; then
1670   cat >> confdefs.h <<\EOF
1671 #define STATISTICS 1
1672 EOF
1673
1674 fi
1675 else
1676   cat >> confdefs.h <<\EOF
1677 #define STATISTICS 1
1678 EOF
1679
1680 fi
1681
1682
1683 # Check whether --enable-split-proxy-args or --disable-split-proxy-args was given.
1684 if test "${enable_split_proxy_args+set}" = set; then
1685   enableval="$enable_split_proxy_args"
1686   if test $enableval = yes; then
1687   cat >> confdefs.h <<\EOF
1688 #define SPLIT_PROXY_ARGS 1
1689 EOF
1690
1691 fi
1692 else
1693   cat >> confdefs.h <<\EOF
1694 #define SPLIT_PROXY_ARGS 1
1695 EOF
1696
1697 fi
1698
1699
1700 # Check whether --enable-webdav or --disable-webdav was given.
1701 if test "${enable_webdav+set}" = set; then
1702   enableval="$enable_webdav"
1703   if test $enableval = yes; then
1704   cat >> confdefs.h <<\EOF
1705 #define WEBDAV 1
1706 EOF
1707
1708 fi
1709 else
1710   cat >> confdefs.h <<\EOF
1711 #define WEBDAV 1
1712 EOF
1713
1714 fi
1715
1716
1717 # Check whether --enable-ie-images or --disable-ie-images was given.
1718 if test "${enable_ie_images+set}" = set; then
1719   enableval="$enable_ie_images"
1720   if test $enableval = yes; then
1721   cat >> confdefs.h <<\EOF
1722 #define DETECT_MSIE_IMAGES 1
1723 EOF
1724
1725 fi
1726 else
1727   cat >> confdefs.h <<\EOF
1728 #define DETECT_MSIE_IMAGES 1
1729 EOF
1730
1731 fi
1732
1733
1734 # Check whether --enable-image-blocking or --disable-image-blocking was given.
1735 if test "${enable_image_blocking+set}" = set; then
1736   enableval="$enable_image_blocking"
1737   if test $enableval = yes; then
1738   cat >> confdefs.h <<\EOF
1739 #define IMAGE_BLOCKING 1
1740 EOF
1741
1742 fi
1743 else
1744   cat >> confdefs.h <<\EOF
1745 #define IMAGE_BLOCKING 1
1746 EOF
1747
1748 fi
1749
1750
1751 # Check whether --enable-acl-files or --disable-acl-files was given.
1752 if test "${enable_acl_files+set}" = set; then
1753   enableval="$enable_acl_files"
1754   if test $enableval = yes; then
1755   cat >> confdefs.h <<\EOF
1756 #define ACL_FILES 1
1757 EOF
1758
1759 fi
1760 else
1761   cat >> confdefs.h <<\EOF
1762 #define ACL_FILES 1
1763 EOF
1764
1765 fi
1766
1767
1768 # Check whether --enable-trust-files or --disable-trust-files was given.
1769 if test "${enable_trust_files+set}" = set; then
1770   enableval="$enable_trust_files"
1771   if test $enableval = yes; then
1772   cat >> confdefs.h <<\EOF
1773 #define TRUST_FILES 1
1774 EOF
1775
1776 fi
1777 else
1778   cat >> confdefs.h <<\EOF
1779 #define TRUST_FILES 1
1780 EOF
1781
1782 fi
1783
1784
1785 # Check whether --enable-jar-files or --disable-jar-files was given.
1786 if test "${enable_jar_files+set}" = set; then
1787   enableval="$enable_jar_files"
1788   if test $enableval = yes; then
1789   cat >> confdefs.h <<\EOF
1790 #define JAR_FILES 1
1791 EOF
1792
1793 fi
1794 else
1795   cat >> confdefs.h <<\EOF
1796 #define JAR_FILES 1
1797 EOF
1798
1799 fi
1800
1801
1802
1803 # Check whether --enable-regex-matching or --disable-regex-matching was given.
1804 if test "${enable_regex_matching+set}" = set; then
1805   enableval="$enable_regex_matching"
1806    regex_matching=$enableval 
1807 else
1808    regex_matching=pcre 
1809 fi
1810
1811
1812 # Check whether --enable-dynamic-pcre or --disable-dynamic-pcre was given.
1813 if test "${enable_dynamic_pcre+set}" = set; then
1814   enableval="$enable_dynamic_pcre"
1815    if test $enableval = "no"; then have_pcre=no; fi 
1816 fi
1817
1818
1819 # Check whether --enable-dynamic-pcrs or --disable-dynamic-pcrs was given.
1820 if test "${enable_dynamic_pcrs+set}" = set; then
1821   enableval="$enable_dynamic_pcrs"
1822    if test $enableval = "no"; then have_pcrs=no; fi 
1823 fi
1824
1825
1826
1827 # Is the regex URL matching based on libpcreposix, but we
1828 # don't have that library?
1829 #
1830 if test $have_pcreposix = "yes" -o $regex_matching != "pcre"; then
1831   dont_miss_pcreposix=yes
1832 else
1833   dont_miss_pcreposix=no
1834 fi
1835
1836 # If we have libpcre and either we also have pcreposix or
1837 # we don't need pcreposix, then link pcre dynamically; else
1838 # build it and link statically
1839 #
1840 if test $have_pcre = "yes" -a $dont_miss_pcreposix = "yes"; then
1841   echo "using libpcre"
1842   pcre_dyn=yes
1843   STATIC_PCRE_ONLY=#
1844   LIBS="$LIBS -lpcre"
1845 else
1846   echo "using built-in static pcre"
1847   pcre_dyn=no
1848   cat >> confdefs.h <<\EOF
1849 #define STATIC_PCRE 1
1850 EOF
1851
1852   STATIC_PCRE_ONLY=
1853 fi
1854
1855 # If we have libpcrs and pcre is linked dynamically
1856 # then also link pcrs dynamically, else build and link
1857 # pcrs statically
1858 #
1859 if test $have_pcrs = "yes" -a $pcre_dyn = "yes"; then
1860   echo "using libpcrs"
1861   STATIC_PCRS_ONLY=#
1862   LIBS="$LIBS -lpcrs"
1863 else
1864   echo "using built-in static pcrs"
1865   cat >> confdefs.h <<\EOF
1866 #define STATIC_PCRS 1
1867 EOF
1868
1869   STATIC_PCRS_ONLY=
1870 fi
1871
1872 # Which method should be used for URL matching?
1873 # pcre, gnu regex or prefix matching?
1874 #
1875 if test $regex_matching = "gnu"; then
1876   echo "using gnu regex for URL matching"
1877   cat >> confdefs.h <<\EOF
1878 #define REGEX_GNU 1
1879 EOF
1880
1881   GNU_REGEX_ONLY=
1882   PCRE_REGEX_ONLY=#
1883 elif test $regex_matching = "pcre"; then
1884   echo "using pcre regex for URL matching"
1885   cat >> confdefs.h <<\EOF
1886 #define REGEX_PCRE 1
1887 EOF
1888
1889   GNU_REGEX_ONLY=#
1890   PCRE_REGEX_ONLY=
1891   if test $pcre_dyn = "yes"; then
1892     LIBS="$LIBS -lpcreposix"
1893   fi
1894 else
1895   echo -e "using prefix matching for URLs\nHint: This does NOT make the executable any smaller!"
1896   GNU_REGEX_ONLY=#
1897   PCRE_REGEX_ONLY=#
1898 fi
1899
1900
1901
1902
1903
1904
1905 trap '' 1 2 15
1906 cat > confcache <<\EOF
1907 # This file is a shell script that caches the results of configure
1908 # tests run on this system so they can be shared between configure
1909 # scripts and configure runs.  It is not useful on other systems.
1910 # If it contains results you don't want to keep, you may remove or edit it.
1911 #
1912 # By default, configure uses ./config.cache as the cache file,
1913 # creating it if it does not exist already.  You can give configure
1914 # the --cache-file=FILE option to use a different cache file; that is
1915 # what configure does when it calls configure scripts in
1916 # subdirectories, so they share the cache.
1917 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1918 # config.status only pays attention to the cache file if you give it the
1919 # --recheck option to rerun configure.
1920 #
1921 EOF
1922 # The following way of writing the cache mishandles newlines in values,
1923 # but we know of no workaround that is simple, portable, and efficient.
1924 # So, don't put newlines in cache variables' values.
1925 # Ultrix sh set writes to stderr and can't be redirected directly,
1926 # and sets the high bit in the cache file unless we assign to the vars.
1927 (set) 2>&1 |
1928   case `(ac_space=' '; set | grep ac_space) 2>&1` in
1929   *ac_space=\ *)
1930     # `set' does not quote correctly, so add quotes (double-quote substitution
1931     # turns \\\\ into \\, and sed turns \\ into \).
1932     sed -n \
1933       -e "s/'/'\\\\''/g" \
1934       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1935     ;;
1936   *)
1937     # `set' quotes correctly as required by POSIX, so do not add quotes.
1938     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1939     ;;
1940   esac >> confcache
1941 if cmp -s $cache_file confcache; then
1942   :
1943 else
1944   if test -w $cache_file; then
1945     echo "updating cache $cache_file"
1946     cat confcache > $cache_file
1947   else
1948     echo "not updating unwritable cache $cache_file"
1949   fi
1950 fi
1951 rm -f confcache
1952
1953 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
1954
1955 test "x$prefix" = xNONE && prefix=$ac_default_prefix
1956 # Let make expand exec_prefix.
1957 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1958
1959 # Any assignment to VPATH causes Sun make to only execute
1960 # the first set of double-colon rules, so remove it if not needed.
1961 # If there is a colon in the path, we need to keep it.
1962 if test "x$srcdir" = x.; then
1963   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
1964 fi
1965
1966 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1967
1968 DEFS=-DHAVE_CONFIG_H
1969
1970 # Without the "./", some shells look in PATH for config.status.
1971 : ${CONFIG_STATUS=./config.status}
1972
1973 echo creating $CONFIG_STATUS
1974 rm -f $CONFIG_STATUS
1975 cat > $CONFIG_STATUS <<EOF
1976 #! /bin/sh
1977 # Generated automatically by configure.
1978 # Run this file to recreate the current configuration.
1979 # This directory was configured as follows,
1980 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1981 #
1982 # $0 $ac_configure_args
1983 #
1984 # Compiler output produced by configure, useful for debugging
1985 # configure, is in ./config.log if it exists.
1986
1987 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1988 for ac_option
1989 do
1990   case "\$ac_option" in
1991   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1992     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1993     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1994   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
1995     echo "$CONFIG_STATUS generated by autoconf version 2.13"
1996     exit 0 ;;
1997   -help | --help | --hel | --he | --h)
1998     echo "\$ac_cs_usage"; exit 0 ;;
1999   *) echo "\$ac_cs_usage"; exit 1 ;;
2000   esac
2001 done
2002
2003 ac_given_srcdir=$srcdir
2004
2005 trap 'rm -fr `echo "Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2006 EOF
2007 cat >> $CONFIG_STATUS <<EOF
2008
2009 # Protect against being on the right side of a sed subst in config.status.
2010 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2011  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2012 $ac_vpsub
2013 $extrasub
2014 s%@SHELL@%$SHELL%g
2015 s%@CFLAGS@%$CFLAGS%g
2016 s%@CPPFLAGS@%$CPPFLAGS%g
2017 s%@CXXFLAGS@%$CXXFLAGS%g
2018 s%@FFLAGS@%$FFLAGS%g
2019 s%@DEFS@%$DEFS%g
2020 s%@LDFLAGS@%$LDFLAGS%g
2021 s%@LIBS@%$LIBS%g
2022 s%@exec_prefix@%$exec_prefix%g
2023 s%@prefix@%$prefix%g
2024 s%@program_transform_name@%$program_transform_name%g
2025 s%@bindir@%$bindir%g
2026 s%@sbindir@%$sbindir%g
2027 s%@libexecdir@%$libexecdir%g
2028 s%@datadir@%$datadir%g
2029 s%@sysconfdir@%$sysconfdir%g
2030 s%@sharedstatedir@%$sharedstatedir%g
2031 s%@localstatedir@%$localstatedir%g
2032 s%@libdir@%$libdir%g
2033 s%@includedir@%$includedir%g
2034 s%@oldincludedir@%$oldincludedir%g
2035 s%@infodir@%$infodir%g
2036 s%@mandir@%$mandir%g
2037 s%@VERSION_MAJOR@%$VERSION_MAJOR%g
2038 s%@VERSION_MINOR@%$VERSION_MINOR%g
2039 s%@VERSION_POINT@%$VERSION_POINT%g
2040 s%@CC@%$CC%g
2041 s%@CPP@%$CPP%g
2042 s%@EXEEXT@%$EXEEXT%g
2043 s%@OBJEXT@%$OBJEXT%g
2044 s%@WIN_ONLY@%$WIN_ONLY%g
2045 s%@CYGWIN_FLAGS@%$CYGWIN_FLAGS%g
2046 s%@PTHREAD_LIB@%$PTHREAD_LIB%g
2047 s%@SOLARIS_ONLY@%$SOLARIS_ONLY%g
2048 s%@PTHREAD_ONLY@%$PTHREAD_ONLY%g
2049 s%@GNU_REGEX_ONLY@%$GNU_REGEX_ONLY%g
2050 s%@PCRE_REGEX_ONLY@%$PCRE_REGEX_ONLY%g
2051 s%@STATIC_PCRE_ONLY@%$STATIC_PCRE_ONLY%g
2052 s%@STATIC_PCRS_ONLY@%$STATIC_PCRS_ONLY%g
2053
2054 CEOF
2055 EOF
2056
2057 cat >> $CONFIG_STATUS <<\EOF
2058
2059 # Split the substitutions into bite-sized pieces for seds with
2060 # small command number limits, like on Digital OSF/1 and HP-UX.
2061 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
2062 ac_file=1 # Number of current file.
2063 ac_beg=1 # First line for current file.
2064 ac_end=$ac_max_sed_cmds # Line after last line for current file.
2065 ac_more_lines=:
2066 ac_sed_cmds=""
2067 while $ac_more_lines; do
2068   if test $ac_beg -gt 1; then
2069     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
2070   else
2071     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
2072   fi
2073   if test ! -s conftest.s$ac_file; then
2074     ac_more_lines=false
2075     rm -f conftest.s$ac_file
2076   else
2077     if test -z "$ac_sed_cmds"; then
2078       ac_sed_cmds="sed -f conftest.s$ac_file"
2079     else
2080       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
2081     fi
2082     ac_file=`expr $ac_file + 1`
2083     ac_beg=$ac_end
2084     ac_end=`expr $ac_end + $ac_max_sed_cmds`
2085   fi
2086 done
2087 if test -z "$ac_sed_cmds"; then
2088   ac_sed_cmds=cat
2089 fi
2090 EOF
2091
2092 cat >> $CONFIG_STATUS <<EOF
2093
2094 CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
2095 EOF
2096 cat >> $CONFIG_STATUS <<\EOF
2097 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2098   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2099   case "$ac_file" in
2100   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2101        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2102   *) ac_file_in="${ac_file}.in" ;;
2103   esac
2104
2105   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
2106
2107   # Remove last slash and all that follows it.  Not all systems have dirname.
2108   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2109   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2110     # The file is in a subdirectory.
2111     test ! -d "$ac_dir" && mkdir "$ac_dir"
2112     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2113     # A "../" for each directory in $ac_dir_suffix.
2114     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2115   else
2116     ac_dir_suffix= ac_dots=
2117   fi
2118
2119   case "$ac_given_srcdir" in
2120   .)  srcdir=.
2121       if test -z "$ac_dots"; then top_srcdir=.
2122       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2123   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2124   *) # Relative path.
2125     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2126     top_srcdir="$ac_dots$ac_given_srcdir" ;;
2127   esac
2128
2129
2130   echo creating "$ac_file"
2131   rm -f "$ac_file"
2132   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2133   case "$ac_file" in
2134   *Makefile*) ac_comsub="1i\\
2135 # $configure_input" ;;
2136   *) ac_comsub= ;;
2137   esac
2138
2139   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2140   sed -e "$ac_comsub
2141 s%@configure_input@%$configure_input%g
2142 s%@srcdir@%$srcdir%g
2143 s%@top_srcdir@%$top_srcdir%g
2144 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
2145 fi; done
2146 rm -f conftest.s*
2147
2148 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
2149 # NAME is the cpp macro being defined and VALUE is the value it is being given.
2150 #
2151 # ac_d sets the value in "#define NAME VALUE" lines.
2152 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
2153 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
2154 ac_dC='\3'
2155 ac_dD='%g'
2156 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
2157 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
2158 ac_uB='\([      ]\)%\1#\2define\3'
2159 ac_uC=' '
2160 ac_uD='\4%g'
2161 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
2162 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
2163 ac_eB='$%\1#\2define\3'
2164 ac_eC=' '
2165 ac_eD='%g'
2166
2167 if test "${CONFIG_HEADERS+set}" != set; then
2168 EOF
2169 cat >> $CONFIG_STATUS <<EOF
2170   CONFIG_HEADERS="config.h"
2171 EOF
2172 cat >> $CONFIG_STATUS <<\EOF
2173 fi
2174 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
2175   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2176   case "$ac_file" in
2177   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2178        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2179   *) ac_file_in="${ac_file}.in" ;;
2180   esac
2181
2182   echo creating $ac_file
2183
2184   rm -f conftest.frag conftest.in conftest.out
2185   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2186   cat $ac_file_inputs > conftest.in
2187
2188 EOF
2189
2190 # Transform confdefs.h into a sed script conftest.vals that substitutes
2191 # the proper values into config.h.in to produce config.h.  And first:
2192 # Protect against being on the right side of a sed subst in config.status.
2193 # Protect against being in an unquoted here document in config.status.
2194 rm -f conftest.vals
2195 cat > conftest.hdr <<\EOF
2196 s/[\\&%]/\\&/g
2197 s%[\\$`]%\\&%g
2198 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
2199 s%ac_d%ac_u%gp
2200 s%ac_u%ac_e%gp
2201 EOF
2202 sed -n -f conftest.hdr confdefs.h > conftest.vals
2203 rm -f conftest.hdr
2204
2205 # This sed command replaces #undef with comments.  This is necessary, for
2206 # example, in the case of _POSIX_SOURCE, which is predefined and required
2207 # on some systems where configure will not decide to define it.
2208 cat >> conftest.vals <<\EOF
2209 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
2210 EOF
2211
2212 # Break up conftest.vals because some shells have a limit on
2213 # the size of here documents, and old seds have small limits too.
2214
2215 rm -f conftest.tail
2216 while :
2217 do
2218   ac_lines=`grep -c . conftest.vals`
2219   # grep -c gives empty output for an empty file on some AIX systems.
2220   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
2221   # Write a limited-size here document to conftest.frag.
2222   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
2223   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
2224   echo 'CEOF
2225   sed -f conftest.frag conftest.in > conftest.out
2226   rm -f conftest.in
2227   mv conftest.out conftest.in
2228 ' >> $CONFIG_STATUS
2229   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
2230   rm -f conftest.vals
2231   mv conftest.tail conftest.vals
2232 done
2233 rm -f conftest.vals
2234
2235 cat >> $CONFIG_STATUS <<\EOF
2236   rm -f conftest.frag conftest.h
2237   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
2238   cat conftest.in >> conftest.h
2239   rm -f conftest.in
2240   if cmp -s $ac_file conftest.h 2>/dev/null; then
2241     echo "$ac_file is unchanged"
2242     rm -f conftest.h
2243   else
2244     # Remove last slash and all that follows it.  Not all systems have dirname.
2245       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2246       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2247       # The file is in a subdirectory.
2248       test ! -d "$ac_dir" && mkdir "$ac_dir"
2249     fi
2250     rm -f $ac_file
2251     mv conftest.h $ac_file
2252   fi
2253 fi; done
2254
2255 EOF
2256 cat >> $CONFIG_STATUS <<EOF
2257
2258 EOF
2259 cat >> $CONFIG_STATUS <<\EOF
2260
2261 exit 0
2262 EOF
2263 chmod +x $CONFIG_STATUS
2264 rm -fr confdefs* $ac_clean_files
2265 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2266
2267