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