xref: /netbsd-src/external/bsd/openldap/dist/contrib/ldaptcl/configure (revision 6d322f2f4598f0d8a138f10ea648ec4fabe41f8b)
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:
11ac_help=
12ac_default_prefix=/usr/local
13# Any additions from configure.in:
14ac_help="$ac_help
15  --enable-gcc            allow use of gcc if available"
16ac_help="$ac_help
17  --with-tk=DIR          use Tk 8.0 binaries from DIR"
18ac_help="$ac_help
19  --without-x            do not build/install ldapwish"
20ac_help="$ac_help
21  --enable-shared         build libldaptcl as a shared library"
22ac_help="$ac_help
23  --with-ldap=<dir>           common parent of ldap include and lib dirs"
24ac_help="$ac_help
25  --with-ldap-incdir=<dir>    path to ldap.h"
26ac_help="$ac_help
27  --with-ldap-libdir=<dir>    path to ldap and lber libs"
28ac_help="$ac_help
29  --with-ldap-libflags=<libnames>   -l flags for ldap libraries"
30
31# Initialize some variables set by options.
32# The variables have the same names as the options, with
33# dashes changed to underlines.
34build=NONE
35cache_file=./config.cache
36exec_prefix=NONE
37host=NONE
38no_create=
39nonopt=NONE
40no_recursion=
41prefix=NONE
42program_prefix=NONE
43program_suffix=NONE
44program_transform_name=s,x,x,
45silent=
46site=
47srcdir=
48target=NONE
49verbose=
50x_includes=NONE
51x_libraries=NONE
52bindir='${exec_prefix}/bin'
53sbindir='${exec_prefix}/sbin'
54libexecdir='${exec_prefix}/libexec'
55datadir='${prefix}/share'
56sysconfdir='${prefix}/etc'
57sharedstatedir='${prefix}/com'
58localstatedir='${prefix}/var'
59libdir='${exec_prefix}/lib'
60includedir='${prefix}/include'
61oldincludedir='/usr/include'
62infodir='${prefix}/info'
63mandir='${prefix}/man'
64
65# Initialize some other variables.
66subdirs=
67MFLAGS= MAKEFLAGS=
68SHELL=${CONFIG_SHELL-/bin/sh}
69# Maximum number of lines to put in a shell here document.
70ac_max_here_lines=12
71
72ac_prev=
73for ac_option
74do
75
76  # If the previous option needs an argument, assign it.
77  if test -n "$ac_prev"; then
78    eval "$ac_prev=\$ac_option"
79    ac_prev=
80    continue
81  fi
82
83  case "$ac_option" in
84  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
85  *) ac_optarg= ;;
86  esac
87
88  # Accept the important Cygnus configure options, so we can diagnose typos.
89
90  case "$ac_option" in
91
92  -bindir | --bindir | --bindi | --bind | --bin | --bi)
93    ac_prev=bindir ;;
94  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
95    bindir="$ac_optarg" ;;
96
97  -build | --build | --buil | --bui | --bu)
98    ac_prev=build ;;
99  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
100    build="$ac_optarg" ;;
101
102  -cache-file | --cache-file | --cache-fil | --cache-fi \
103  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
104    ac_prev=cache_file ;;
105  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
106  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
107    cache_file="$ac_optarg" ;;
108
109  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
110    ac_prev=datadir ;;
111  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
112  | --da=*)
113    datadir="$ac_optarg" ;;
114
115  -disable-* | --disable-*)
116    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
117    # Reject names that are not valid shell variable names.
118    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
119      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
120    fi
121    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
122    eval "enable_${ac_feature}=no" ;;
123
124  -enable-* | --enable-*)
125    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
126    # Reject names that are not valid shell variable names.
127    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
128      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
129    fi
130    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
131    case "$ac_option" in
132      *=*) ;;
133      *) ac_optarg=yes ;;
134    esac
135    eval "enable_${ac_feature}='$ac_optarg'" ;;
136
137  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
138  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
139  | --exec | --exe | --ex)
140    ac_prev=exec_prefix ;;
141  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
142  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
143  | --exec=* | --exe=* | --ex=*)
144    exec_prefix="$ac_optarg" ;;
145
146  -gas | --gas | --ga | --g)
147    # Obsolete; use --with-gas.
148    with_gas=yes ;;
149
150  -help | --help | --hel | --he)
151    # Omit some internal or obsolete options to make the list less imposing.
152    # This message is too long to be a string in the A/UX 3.1 sh.
153    cat << EOF
154Usage: configure [options] [host]
155Options: [defaults in brackets after descriptions]
156Configuration:
157  --cache-file=FILE       cache test results in FILE
158  --help                  print this message
159  --no-create             do not create output files
160  --quiet, --silent       do not print \`checking...' messages
161  --version               print the version of autoconf that created configure
162Directory and file names:
163  --prefix=PREFIX         install architecture-independent files in PREFIX
164                          [$ac_default_prefix]
165  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
166                          [same as prefix]
167  --bindir=DIR            user executables in DIR [EPREFIX/bin]
168  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
169  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
170  --datadir=DIR           read-only architecture-independent data in DIR
171                          [PREFIX/share]
172  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
173  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
174                          [PREFIX/com]
175  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
176  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
177  --includedir=DIR        C header files in DIR [PREFIX/include]
178  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
179  --infodir=DIR           info documentation in DIR [PREFIX/info]
180  --mandir=DIR            man documentation in DIR [PREFIX/man]
181  --srcdir=DIR            find the sources in DIR [configure dir or ..]
182  --program-prefix=PREFIX prepend PREFIX to installed program names
183  --program-suffix=SUFFIX append SUFFIX to installed program names
184  --program-transform-name=PROGRAM
185                          run sed PROGRAM on installed program names
186EOF
187    cat << EOF
188Host type:
189  --build=BUILD           configure for building on BUILD [BUILD=HOST]
190  --host=HOST             configure for HOST [guessed]
191  --target=TARGET         configure for TARGET [TARGET=HOST]
192Features and packages:
193  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
194  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
195  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
196  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
197  --x-includes=DIR        X include files are in DIR
198  --x-libraries=DIR       X library files are in DIR
199EOF
200    if test -n "$ac_help"; then
201      echo "--enable and --with options recognized:$ac_help"
202    fi
203    exit 0 ;;
204
205  -host | --host | --hos | --ho)
206    ac_prev=host ;;
207  -host=* | --host=* | --hos=* | --ho=*)
208    host="$ac_optarg" ;;
209
210  -includedir | --includedir | --includedi | --included | --include \
211  | --includ | --inclu | --incl | --inc)
212    ac_prev=includedir ;;
213  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
214  | --includ=* | --inclu=* | --incl=* | --inc=*)
215    includedir="$ac_optarg" ;;
216
217  -infodir | --infodir | --infodi | --infod | --info | --inf)
218    ac_prev=infodir ;;
219  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
220    infodir="$ac_optarg" ;;
221
222  -libdir | --libdir | --libdi | --libd)
223    ac_prev=libdir ;;
224  -libdir=* | --libdir=* | --libdi=* | --libd=*)
225    libdir="$ac_optarg" ;;
226
227  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
228  | --libexe | --libex | --libe)
229    ac_prev=libexecdir ;;
230  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
231  | --libexe=* | --libex=* | --libe=*)
232    libexecdir="$ac_optarg" ;;
233
234  -localstatedir | --localstatedir | --localstatedi | --localstated \
235  | --localstate | --localstat | --localsta | --localst \
236  | --locals | --local | --loca | --loc | --lo)
237    ac_prev=localstatedir ;;
238  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
239  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
240  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
241    localstatedir="$ac_optarg" ;;
242
243  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
244    ac_prev=mandir ;;
245  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
246    mandir="$ac_optarg" ;;
247
248  -nfp | --nfp | --nf)
249    # Obsolete; use --without-fp.
250    with_fp=no ;;
251
252  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
253  | --no-cr | --no-c)
254    no_create=yes ;;
255
256  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
257  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
258    no_recursion=yes ;;
259
260  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
261  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
262  | --oldin | --oldi | --old | --ol | --o)
263    ac_prev=oldincludedir ;;
264  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
265  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
266  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
267    oldincludedir="$ac_optarg" ;;
268
269  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
270    ac_prev=prefix ;;
271  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
272    prefix="$ac_optarg" ;;
273
274  -program-prefix | --program-prefix | --program-prefi | --program-pref \
275  | --program-pre | --program-pr | --program-p)
276    ac_prev=program_prefix ;;
277  -program-prefix=* | --program-prefix=* | --program-prefi=* \
278  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
279    program_prefix="$ac_optarg" ;;
280
281  -program-suffix | --program-suffix | --program-suffi | --program-suff \
282  | --program-suf | --program-su | --program-s)
283    ac_prev=program_suffix ;;
284  -program-suffix=* | --program-suffix=* | --program-suffi=* \
285  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
286    program_suffix="$ac_optarg" ;;
287
288  -program-transform-name | --program-transform-name \
289  | --program-transform-nam | --program-transform-na \
290  | --program-transform-n | --program-transform- \
291  | --program-transform | --program-transfor \
292  | --program-transfo | --program-transf \
293  | --program-trans | --program-tran \
294  | --progr-tra | --program-tr | --program-t)
295    ac_prev=program_transform_name ;;
296  -program-transform-name=* | --program-transform-name=* \
297  | --program-transform-nam=* | --program-transform-na=* \
298  | --program-transform-n=* | --program-transform-=* \
299  | --program-transform=* | --program-transfor=* \
300  | --program-transfo=* | --program-transf=* \
301  | --program-trans=* | --program-tran=* \
302  | --progr-tra=* | --program-tr=* | --program-t=*)
303    program_transform_name="$ac_optarg" ;;
304
305  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
306  | -silent | --silent | --silen | --sile | --sil)
307    silent=yes ;;
308
309  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
310    ac_prev=sbindir ;;
311  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
312  | --sbi=* | --sb=*)
313    sbindir="$ac_optarg" ;;
314
315  -sharedstatedir | --sharedstatedir | --sharedstatedi \
316  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
317  | --sharedst | --shareds | --shared | --share | --shar \
318  | --sha | --sh)
319    ac_prev=sharedstatedir ;;
320  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
321  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
322  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
323  | --sha=* | --sh=*)
324    sharedstatedir="$ac_optarg" ;;
325
326  -site | --site | --sit)
327    ac_prev=site ;;
328  -site=* | --site=* | --sit=*)
329    site="$ac_optarg" ;;
330
331  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
332    ac_prev=srcdir ;;
333  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
334    srcdir="$ac_optarg" ;;
335
336  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
337  | --syscon | --sysco | --sysc | --sys | --sy)
338    ac_prev=sysconfdir ;;
339  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
340  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
341    sysconfdir="$ac_optarg" ;;
342
343  -target | --target | --targe | --targ | --tar | --ta | --t)
344    ac_prev=target ;;
345  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
346    target="$ac_optarg" ;;
347
348  -v | -verbose | --verbose | --verbos | --verbo | --verb)
349    verbose=yes ;;
350
351  -version | --version | --versio | --versi | --vers)
352    echo "configure generated by autoconf version 2.13"
353    exit 0 ;;
354
355  -with-* | --with-*)
356    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
357    # Reject names that are not valid shell variable names.
358    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
359      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
360    fi
361    ac_package=`echo $ac_package| sed 's/-/_/g'`
362    case "$ac_option" in
363      *=*) ;;
364      *) ac_optarg=yes ;;
365    esac
366    eval "with_${ac_package}='$ac_optarg'" ;;
367
368  -without-* | --without-*)
369    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
370    # Reject names that are not valid shell variable names.
371    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
372      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
373    fi
374    ac_package=`echo $ac_package| sed 's/-/_/g'`
375    eval "with_${ac_package}=no" ;;
376
377  --x)
378    # Obsolete; use --with-x.
379    with_x=yes ;;
380
381  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
382  | --x-incl | --x-inc | --x-in | --x-i)
383    ac_prev=x_includes ;;
384  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
385  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
386    x_includes="$ac_optarg" ;;
387
388  -x-libraries | --x-libraries | --x-librarie | --x-librari \
389  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
390    ac_prev=x_libraries ;;
391  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
392  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
393    x_libraries="$ac_optarg" ;;
394
395  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
396    ;;
397
398  *)
399    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
400      echo "configure: warning: $ac_option: invalid host type" 1>&2
401    fi
402    if test "x$nonopt" != xNONE; then
403      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
404    fi
405    nonopt="$ac_option"
406    ;;
407
408  esac
409done
410
411if test -n "$ac_prev"; then
412  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
413fi
414
415trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
416
417# File descriptor usage:
418# 0 standard input
419# 1 file creation
420# 2 errors and warnings
421# 3 some systems may open it to /dev/tty
422# 4 used on the Kubota Titan
423# 6 checking for... messages and results
424# 5 compiler messages saved in config.log
425if test "$silent" = yes; then
426  exec 6>/dev/null
427else
428  exec 6>&1
429fi
430exec 5>./config.log
431
432echo "\
433This file contains any messages produced by compilers while
434running configure, to aid debugging if configure makes a mistake.
435" 1>&5
436
437# Strip out --no-create and --no-recursion so they do not pile up.
438# Also quote any args containing shell metacharacters.
439ac_configure_args=
440for ac_arg
441do
442  case "$ac_arg" in
443  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
444  | --no-cr | --no-c) ;;
445  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
446  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
447  *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
448  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
449  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
450  esac
451done
452
453# NLS nuisances.
454# Only set these to C if already set.  These must not be set unconditionally
455# because not all systems understand e.g. LANG=C (notably SCO).
456# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
457# Non-C LC_CTYPE values break the ctype check.
458if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
459if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
460if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
461if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
462
463# confdefs.h avoids OS command line length limits that DEFS can exceed.
464rm -rf conftest* confdefs.h
465# AIX cpp loses on an empty file, so make sure it contains at least a newline.
466echo > confdefs.h
467
468# A filename unique to this package, relative to the directory that
469# configure is in, which we can look for to find out if srcdir is correct.
470ac_unique_file=neoXldap.c
471
472# Find the source files, if location was not specified.
473if test -z "$srcdir"; then
474  ac_srcdir_defaulted=yes
475  # Try the directory containing this script, then its parent.
476  ac_prog=$0
477  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
478  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
479  srcdir=$ac_confdir
480  if test ! -r $srcdir/$ac_unique_file; then
481    srcdir=..
482  fi
483else
484  ac_srcdir_defaulted=no
485fi
486if test ! -r $srcdir/$ac_unique_file; then
487  if test "$ac_srcdir_defaulted" = yes; then
488    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
489  else
490    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
491  fi
492fi
493srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
494
495# Prefer explicitly selected file to automatically selected ones.
496if test -z "$CONFIG_SITE"; then
497  if test "x$prefix" != xNONE; then
498    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
499  else
500    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
501  fi
502fi
503for ac_site_file in $CONFIG_SITE; do
504  if test -r "$ac_site_file"; then
505    echo "loading site script $ac_site_file"
506    . "$ac_site_file"
507  fi
508done
509
510if test -r "$cache_file"; then
511  echo "loading cache $cache_file"
512  . $cache_file
513else
514  echo "creating cache $cache_file"
515  > $cache_file
516fi
517
518ac_ext=c
519# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
520ac_cpp='$CPP $CPPFLAGS'
521ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
522ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
523cross_compiling=$ac_cv_prog_cc_cross
524
525ac_exeext=
526ac_objext=o
527if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
528  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
529  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
530    ac_n= ac_c='
531' ac_t='	'
532  else
533    ac_n=-n ac_c= ac_t=
534  fi
535else
536  ac_n= ac_c='\c' ac_t=
537fi
538
539
540# OpenLDAP: pkg/ldap/contrib/ldaptcl/configure,v 1.7.2.1 2007/08/31 23:13:51 quanah Exp
541
542NEO_VERSION=2.0
543NEO_MAJOR_VERSION=2
544NEO_MINOR_VERSION=0
545VERSION=${NEO_VERSION}
546
547if test "${prefix}" = "NONE"; then
548    prefix=/usr/local
549fi
550if test "${exec_prefix}" = "NONE"; then
551    exec_prefix=$prefix
552fi
553
554# Check whether --enable-gcc or --disable-gcc was given.
555if test "${enable_gcc+set}" = set; then
556  enableval="$enable_gcc"
557  neo_ok=$enableval
558else
559  neo_ok=no
560fi
561
562if test "$neo_ok" = "yes"; then
563    # Extract the first word of "gcc", so it can be a program name with args.
564set dummy gcc; ac_word=$2
565echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
566echo "configure:567: checking for $ac_word" >&5
567if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
568  echo $ac_n "(cached) $ac_c" 1>&6
569else
570  if test -n "$CC"; then
571  ac_cv_prog_CC="$CC" # Let the user override the test.
572else
573  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
574  ac_dummy="$PATH"
575  for ac_dir in $ac_dummy; do
576    test -z "$ac_dir" && ac_dir=.
577    if test -f $ac_dir/$ac_word; then
578      ac_cv_prog_CC="gcc"
579      break
580    fi
581  done
582  IFS="$ac_save_ifs"
583fi
584fi
585CC="$ac_cv_prog_CC"
586if test -n "$CC"; then
587  echo "$ac_t""$CC" 1>&6
588else
589  echo "$ac_t""no" 1>&6
590fi
591
592if test -z "$CC"; then
593  # Extract the first word of "cc", so it can be a program name with args.
594set dummy cc; ac_word=$2
595echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
596echo "configure:597: checking for $ac_word" >&5
597if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
598  echo $ac_n "(cached) $ac_c" 1>&6
599else
600  if test -n "$CC"; then
601  ac_cv_prog_CC="$CC" # Let the user override the test.
602else
603  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
604  ac_prog_rejected=no
605  ac_dummy="$PATH"
606  for ac_dir in $ac_dummy; do
607    test -z "$ac_dir" && ac_dir=.
608    if test -f $ac_dir/$ac_word; then
609      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
610        ac_prog_rejected=yes
611	continue
612      fi
613      ac_cv_prog_CC="cc"
614      break
615    fi
616  done
617  IFS="$ac_save_ifs"
618if test $ac_prog_rejected = yes; then
619  # We found a bogon in the path, so make sure we never use it.
620  set dummy $ac_cv_prog_CC
621  shift
622  if test $# -gt 0; then
623    # We chose a different compiler from the bogus one.
624    # However, it has the same basename, so the bogon will be chosen
625    # first if we set CC to just the basename; use the full file name.
626    shift
627    set dummy "$ac_dir/$ac_word" "$@"
628    shift
629    ac_cv_prog_CC="$@"
630  fi
631fi
632fi
633fi
634CC="$ac_cv_prog_CC"
635if test -n "$CC"; then
636  echo "$ac_t""$CC" 1>&6
637else
638  echo "$ac_t""no" 1>&6
639fi
640
641  if test -z "$CC"; then
642    case "`uname -s`" in
643    *win32* | *WIN32*)
644      # Extract the first word of "cl", so it can be a program name with args.
645set dummy cl; ac_word=$2
646echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
647echo "configure:648: checking for $ac_word" >&5
648if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
649  echo $ac_n "(cached) $ac_c" 1>&6
650else
651  if test -n "$CC"; then
652  ac_cv_prog_CC="$CC" # Let the user override the test.
653else
654  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
655  ac_dummy="$PATH"
656  for ac_dir in $ac_dummy; do
657    test -z "$ac_dir" && ac_dir=.
658    if test -f $ac_dir/$ac_word; then
659      ac_cv_prog_CC="cl"
660      break
661    fi
662  done
663  IFS="$ac_save_ifs"
664fi
665fi
666CC="$ac_cv_prog_CC"
667if test -n "$CC"; then
668  echo "$ac_t""$CC" 1>&6
669else
670  echo "$ac_t""no" 1>&6
671fi
672 ;;
673    esac
674  fi
675  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
676fi
677
678echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
679echo "configure:680: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
680
681ac_ext=c
682# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
683ac_cpp='$CPP $CPPFLAGS'
684ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
685ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
686cross_compiling=$ac_cv_prog_cc_cross
687
688cat > conftest.$ac_ext << EOF
689
690#line 691 "configure"
691#include "confdefs.h"
692
693main(){return(0);}
694EOF
695if { (eval echo configure:696: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
696  ac_cv_prog_cc_works=yes
697  # If we can't run a trivial program, we are probably using a cross compiler.
698  if (./conftest; exit) 2>/dev/null; then
699    ac_cv_prog_cc_cross=no
700  else
701    ac_cv_prog_cc_cross=yes
702  fi
703else
704  echo "configure: failed program was:" >&5
705  cat conftest.$ac_ext >&5
706  ac_cv_prog_cc_works=no
707fi
708rm -fr conftest*
709ac_ext=c
710# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
711ac_cpp='$CPP $CPPFLAGS'
712ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
713ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
714cross_compiling=$ac_cv_prog_cc_cross
715
716echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
717if test $ac_cv_prog_cc_works = no; then
718  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
719fi
720echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
721echo "configure:722: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
722echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
723cross_compiling=$ac_cv_prog_cc_cross
724
725echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
726echo "configure:727: checking whether we are using GNU C" >&5
727if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
728  echo $ac_n "(cached) $ac_c" 1>&6
729else
730  cat > conftest.c <<EOF
731#ifdef __GNUC__
732  yes;
733#endif
734EOF
735if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:736: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
736  ac_cv_prog_gcc=yes
737else
738  ac_cv_prog_gcc=no
739fi
740fi
741
742echo "$ac_t""$ac_cv_prog_gcc" 1>&6
743
744if test $ac_cv_prog_gcc = yes; then
745  GCC=yes
746else
747  GCC=
748fi
749
750ac_test_CFLAGS="${CFLAGS+set}"
751ac_save_CFLAGS="$CFLAGS"
752CFLAGS=
753echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
754echo "configure:755: checking whether ${CC-cc} accepts -g" >&5
755if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
756  echo $ac_n "(cached) $ac_c" 1>&6
757else
758  echo 'void f(){}' > conftest.c
759if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
760  ac_cv_prog_cc_g=yes
761else
762  ac_cv_prog_cc_g=no
763fi
764rm -f conftest*
765
766fi
767
768echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
769if test "$ac_test_CFLAGS" = set; then
770  CFLAGS="$ac_save_CFLAGS"
771elif test $ac_cv_prog_cc_g = yes; then
772  if test "$GCC" = yes; then
773    CFLAGS="-g -O2"
774  else
775    CFLAGS="-g"
776  fi
777else
778  if test "$GCC" = yes; then
779    CFLAGS="-O2"
780  else
781    CFLAGS=
782  fi
783fi
784
785else
786    CC=${CC-cc}
787
788fi
789
790ac_aux_dir=
791for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
792  if test -f $ac_dir/install-sh; then
793    ac_aux_dir=$ac_dir
794    ac_install_sh="$ac_aux_dir/install-sh -c"
795    break
796  elif test -f $ac_dir/install.sh; then
797    ac_aux_dir=$ac_dir
798    ac_install_sh="$ac_aux_dir/install.sh -c"
799    break
800  fi
801done
802if test -z "$ac_aux_dir"; then
803  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
804fi
805ac_config_guess=$ac_aux_dir/config.guess
806ac_config_sub=$ac_aux_dir/config.sub
807ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
808
809# Find a good install program.  We prefer a C program (faster),
810# so one script is as good as another.  But avoid the broken or
811# incompatible versions:
812# SysV /etc/install, /usr/sbin/install
813# SunOS /usr/etc/install
814# IRIX /sbin/install
815# AIX /bin/install
816# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
817# AFS /usr/afsws/bin/install, which mishandles nonexistent args
818# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
819# ./install, which can be erroneously created by make from ./install.sh.
820echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
821echo "configure:822: checking for a BSD compatible install" >&5
822if test -z "$INSTALL"; then
823if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
824  echo $ac_n "(cached) $ac_c" 1>&6
825else
826    IFS="${IFS= 	}"; ac_save_IFS="$IFS"; IFS=":"
827  for ac_dir in $PATH; do
828    # Account for people who put trailing slashes in PATH elements.
829    case "$ac_dir/" in
830    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
831    *)
832      # OSF1 and SCO ODT 3.0 have their own names for install.
833      # Don't use installbsd from OSF since it installs stuff as root
834      # by default.
835      for ac_prog in ginstall scoinst install; do
836        if test -f $ac_dir/$ac_prog; then
837	  if test $ac_prog = install &&
838            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
839	    # AIX install.  It has an incompatible calling convention.
840	    :
841	  else
842	    ac_cv_path_install="$ac_dir/$ac_prog -c"
843	    break 2
844	  fi
845	fi
846      done
847      ;;
848    esac
849  done
850  IFS="$ac_save_IFS"
851
852fi
853  if test "${ac_cv_path_install+set}" = set; then
854    INSTALL="$ac_cv_path_install"
855  else
856    # As a last resort, use the slow shell script.  We don't cache a
857    # path for INSTALL within a source directory, because that will
858    # break other packages using the cache if that directory is
859    # removed, or if the path is relative.
860    INSTALL="$ac_install_sh"
861  fi
862fi
863echo "$ac_t""$INSTALL" 1>&6
864
865# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
866# It thinks the first close brace ends the variable substitution.
867test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
868
869test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
870
871test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
872
873# Extract the first word of "ranlib", so it can be a program name with args.
874set dummy ranlib; ac_word=$2
875echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
876echo "configure:877: checking for $ac_word" >&5
877if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
878  echo $ac_n "(cached) $ac_c" 1>&6
879else
880  if test -n "$RANLIB"; then
881  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
882else
883  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
884  ac_dummy="$PATH"
885  for ac_dir in $ac_dummy; do
886    test -z "$ac_dir" && ac_dir=.
887    if test -f $ac_dir/$ac_word; then
888      ac_cv_prog_RANLIB="ranlib"
889      break
890    fi
891  done
892  IFS="$ac_save_ifs"
893  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
894fi
895fi
896RANLIB="$ac_cv_prog_RANLIB"
897if test -n "$RANLIB"; then
898  echo "$ac_t""$RANLIB" 1>&6
899else
900  echo "$ac_t""no" 1>&6
901fi
902
903
904if test ! -f $exec_prefix/lib/tclConfig.sh
905then
906    { echo "configure: error: Tcl must be installed first" 1>&2; exit 1; }
907fi
908
909. $exec_prefix/lib/tclConfig.sh
910
911if test ! -f $exec_prefix/lib/tclxConfig.sh
912then
913    { echo "configure: error: Extended Tcl must be installed first" 1>&2; exit 1; }
914fi
915. $exec_prefix/lib/tclxConfig.sh
916
917
918#--------------------------------------------------------------------
919#	See if there was a command-line option for where Tk is;  if
920#	not, assume that its top-level directory is a sibling of ours.
921#--------------------------------------------------------------------
922
923# Check whether --with-tk or --without-tk was given.
924if test "${with_tk+set}" = set; then
925  withval="$with_tk"
926  :
927else
928  with_tk=yes
929fi
930
931
932case "$with_tk" in
933    yes)
934	if test -f $exec_prefix/lib/tkConfig.sh &&
935	   test -f $exec_prefix/lib/tkxConfig.sh
936	then
937	    :
938	else
939	    { echo "configure: error: Tk does not appear to be installed at $exec_prefix" 1>&2; exit 1; }
940	fi
941	;;
942    no) ;;
943    *)  { echo "configure: error: Tk cannot be specified and must be in $exec_prefix" 1>&2; exit 1; }
944	;;
945esac
946
947# Check whether --with-x or --without-x was given.
948if test "${with_x+set}" = set; then
949  withval="$with_x"
950  :
951fi
952
953if test "$with_x" = "no"
954then
955    with_tk=no
956fi
957
958if test "$with_tk" != "no"
959then
960    LDAPWISH=ldapwish
961    . $exec_prefix/lib/tkConfig.sh
962    . $exec_prefix/lib/tkxConfig.sh
963fi
964
965
966
967
968
969
970
971#--------------------------------------------------------------------
972#	Read in configuration information generated by Tcl for shared
973#	libraries, and arrange for it to be substituted into our
974#	Makefile.
975#--------------------------------------------------------------------
976
977CC=$TCL_CC
978SHLIB_CFLAGS=$TCL_SHLIB_CFLAGS
979SHLIB_LD=$TCL_SHLIB_LD
980SHLIB_LD_LIBS=$TCL_SHLIB_LD_LIBS
981SHLIB_SUFFIX=$TCL_SHLIB_SUFFIX
982SHLIB_VERSION=$TCL_SHLIB_VERSION
983DL_LIBS=$TCL_DL_LIBS
984LD_FLAGS=$TCL_LD_FLAGS
985NEO_LD_SEARCH_FLAGS=$TCL_LD_SEARCH_FLAGS
986
987eval "NEO_SHARED_LIB_FILE=libldaptcl${TCL_SHARED_LIB_SUFFIX}"
988eval "NEO_UNSHARED_LIB_FILE=libldaptcl${TCL_UNSHARED_LIB_SUFFIX}"
989
990#--------------------------------------------------------------------
991#	The statements below define a collection of symbols related to
992#	building libldap as a shared library instead of a static library.
993#--------------------------------------------------------------------
994
995# Warning: in order to use the following code for libldap and libdb versions,
996# the VERSION shell variable is modified, and then is restored after.
997
998# Check whether --enable-shared or --disable-shared was given.
999if test "${enable_shared+set}" = set; then
1000  enableval="$enable_shared"
1001  ok=$enableval
1002else
1003  ok=no
1004fi
1005
1006if test "$ok" = "yes" && test "${SHLIB_SUFFIX}" != ""; then
1007    NEO_SHLIB_CFLAGS="${SHLIB_CFLAGS}"
1008    eval "NEO_LIB_FILE=libldaptcl${TCL_SHARED_LIB_SUFFIX}"
1009    MAKE_LIB="\${SHLIB_LD} $TCL_LIB_HNAME -o ${NEO_LIB_FILE} \${OBJS} \${LDAP_LIBFLAGS}"
1010    RANLIB=":"
1011else
1012    NEO_SHLIB_CFLAGS=""
1013    eval "NEO_LIB_FILE=libldaptcl${TCL_UNSHARED_LIB_SUFFIX}"
1014    MAKE_LIB="ar cr ${NEO_LIB_FILE} \${OBJS}"
1015fi
1016
1017# Check whether --with-ldap or --without-ldap was given.
1018if test "${with_ldap+set}" = set; then
1019  withval="$with_ldap"
1020  neo_ldap=$withval
1021	case $withval in
1022	    yes) ldapdir=/usr/local
1023		 ;;
1024	    no)  ;;
1025	    *)	 ldapdir=$withval
1026		 neo_ldap=yes
1027		 ;;
1028	esac
1029
1030else
1031
1032	    neo_ldap=yes
1033	    ldapdir=/usr/local
1034
1035fi
1036
1037
1038ldapincdir=$ldapdir/include
1039# Check whether --with-ldap-incdir or --without-ldap-incdir was given.
1040if test "${with_ldap_incdir+set}" = set; then
1041  withval="$with_ldap_incdir"
1042  ldapincdir=$withval
1043fi
1044
1045
1046ldaplibdir=$ldapdir/lib
1047# Check whether --with-ldap-libdir or --without-ldap-libdir was given.
1048if test "${with_ldap_libdir+set}" = set; then
1049  withval="$with_ldap_libdir"
1050  ldaplibdir=$withval
1051fi
1052
1053
1054# Check whether --with-ldap-libraries or --without-ldap-libraries was given.
1055if test "${with_ldap_libraries+set}" = set; then
1056  withval="$with_ldap_libraries"
1057  ldaplibflags="-L$ldaplibdir $withval"
1058else
1059  ldaplibflags="-L$ldaplibdir -lldap -llber"
1060fi
1061
1062
1063ldapinclude="-I$ldapincdir"
1064
1065ldapbuild=yes
1066
1067
1068
1069
1070
1071
1072
1073
1074VERSION=${NEO_VERSION}
1075# Note:  in the following variable, it's important to use the absolute
1076# path name of the Tcl directory rather than "..":  this is because
1077# AIX remembers this path and will attempt to use it at run-time to look
1078# up the Tcl library.
1079
1080if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
1081    NEO_BUILD_LIB_SPEC="-L`pwd` -lldaptcl${VERSION}"
1082    NEO_LIB_SPEC="-L${exec_prefix}/lib -lldaptcl${VERSION}"
1083else
1084    NEO_BUILD_LIB_SPEC="-L`pwd` -lldaptcl`echo ${VERSION} | tr -d .`"
1085    NEO_LIB_SPEC="-L${exec_prefix}/lib -lldaptcl`echo ${VERSION} | tr -d .`"
1086fi
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122trap '' 1 2 15
1123cat > confcache <<\EOF
1124# This file is a shell script that caches the results of configure
1125# tests run on this system so they can be shared between configure
1126# scripts and configure runs.  It is not useful on other systems.
1127# If it contains results you don't want to keep, you may remove or edit it.
1128#
1129# By default, configure uses ./config.cache as the cache file,
1130# creating it if it does not exist already.  You can give configure
1131# the --cache-file=FILE option to use a different cache file; that is
1132# what configure does when it calls configure scripts in
1133# subdirectories, so they share the cache.
1134# Giving --cache-file=/dev/null disables caching, for debugging configure.
1135# config.status only pays attention to the cache file if you give it the
1136# --recheck option to rerun configure.
1137#
1138EOF
1139# The following way of writing the cache mishandles newlines in values,
1140# but we know of no workaround that is simple, portable, and efficient.
1141# So, don't put newlines in cache variables' values.
1142# Ultrix sh set writes to stderr and can't be redirected directly,
1143# and sets the high bit in the cache file unless we assign to the vars.
1144(set) 2>&1 |
1145  case `(ac_space=' '; set | grep ac_space) 2>&1` in
1146  *ac_space=\ *)
1147    # `set' does not quote correctly, so add quotes (double-quote substitution
1148    # turns \\\\ into \\, and sed turns \\ into \).
1149    sed -n \
1150      -e "s/'/'\\\\''/g" \
1151      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1152    ;;
1153  *)
1154    # `set' quotes correctly as required by POSIX, so do not add quotes.
1155    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1156    ;;
1157  esac >> confcache
1158if cmp -s $cache_file confcache; then
1159  :
1160else
1161  if test -w $cache_file; then
1162    echo "updating cache $cache_file"
1163    cat confcache > $cache_file
1164  else
1165    echo "not updating unwritable cache $cache_file"
1166  fi
1167fi
1168rm -f confcache
1169
1170trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
1171
1172test "x$prefix" = xNONE && prefix=$ac_default_prefix
1173# Let make expand exec_prefix.
1174test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1175
1176# Any assignment to VPATH causes Sun make to only execute
1177# the first set of double-colon rules, so remove it if not needed.
1178# If there is a colon in the path, we need to keep it.
1179if test "x$srcdir" = x.; then
1180  ac_vpsub='/^[ 	]*VPATH[ 	]*=[^:]*$/d'
1181fi
1182
1183trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1184
1185# Transform confdefs.h into DEFS.
1186# Protect against shell expansion while executing Makefile rules.
1187# Protect against Makefile macro expansion.
1188cat > conftest.defs <<\EOF
1189s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
1190s%[ 	`~#$^&*(){}\\|;'"<>?]%\\&%g
1191s%\[%\\&%g
1192s%\]%\\&%g
1193s%\$%$$%g
1194EOF
1195DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
1196rm -f conftest.defs
1197
1198
1199# Without the "./", some shells look in PATH for config.status.
1200: ${CONFIG_STATUS=./config.status}
1201
1202echo creating $CONFIG_STATUS
1203rm -f $CONFIG_STATUS
1204cat > $CONFIG_STATUS <<EOF
1205#! /bin/sh
1206# Generated automatically by configure.
1207# Run this file to recreate the current configuration.
1208# This directory was configured as follows,
1209# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1210#
1211# $0 $ac_configure_args
1212#
1213# Compiler output produced by configure, useful for debugging
1214# configure, is in ./config.log if it exists.
1215
1216ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1217for ac_option
1218do
1219  case "\$ac_option" in
1220  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1221    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1222    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1223  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
1224    echo "$CONFIG_STATUS generated by autoconf version 2.13"
1225    exit 0 ;;
1226  -help | --help | --hel | --he | --h)
1227    echo "\$ac_cs_usage"; exit 0 ;;
1228  *) echo "\$ac_cs_usage"; exit 1 ;;
1229  esac
1230done
1231
1232ac_given_srcdir=$srcdir
1233ac_given_INSTALL="$INSTALL"
1234
1235trap 'rm -fr `echo "Makefile pkgIndex.tcl" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
1236EOF
1237cat >> $CONFIG_STATUS <<EOF
1238
1239# Protect against being on the right side of a sed subst in config.status.
1240sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
1241 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
1242$ac_vpsub
1243$extrasub
1244s%@SHELL@%$SHELL%g
1245s%@CFLAGS@%$CFLAGS%g
1246s%@CPPFLAGS@%$CPPFLAGS%g
1247s%@CXXFLAGS@%$CXXFLAGS%g
1248s%@FFLAGS@%$FFLAGS%g
1249s%@DEFS@%$DEFS%g
1250s%@LDFLAGS@%$LDFLAGS%g
1251s%@LIBS@%$LIBS%g
1252s%@exec_prefix@%$exec_prefix%g
1253s%@prefix@%$prefix%g
1254s%@program_transform_name@%$program_transform_name%g
1255s%@bindir@%$bindir%g
1256s%@sbindir@%$sbindir%g
1257s%@libexecdir@%$libexecdir%g
1258s%@datadir@%$datadir%g
1259s%@sysconfdir@%$sysconfdir%g
1260s%@sharedstatedir@%$sharedstatedir%g
1261s%@localstatedir@%$localstatedir%g
1262s%@libdir@%$libdir%g
1263s%@includedir@%$includedir%g
1264s%@oldincludedir@%$oldincludedir%g
1265s%@infodir@%$infodir%g
1266s%@mandir@%$mandir%g
1267s%@CC@%$CC%g
1268s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
1269s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
1270s%@INSTALL_DATA@%$INSTALL_DATA%g
1271s%@RANLIB@%$RANLIB%g
1272s%@TK_LIBS@%$TK_LIBS%g
1273s%@TK_LIB_SPEC@%$TK_LIB_SPEC%g
1274s%@TK_XINCLUDES@%$TK_XINCLUDES%g
1275s%@TK_VERSION@%$TK_VERSION%g
1276s%@TKX_LIB_SPEC@%$TKX_LIB_SPEC%g
1277s%@LDAPWISH@%$LDAPWISH%g
1278s%@ldaplibflags@%$ldaplibflags%g
1279s%@ldapinclude@%$ldapinclude%g
1280s%@ldapbuild@%$ldapbuild%g
1281s%@ldapdir@%$ldapdir%g
1282s%@ldapincdir@%$ldapincdir%g
1283s%@DL_LIBS@%$DL_LIBS%g
1284s%@LD_FLAGS@%$LD_FLAGS%g
1285s%@MATH_LIBS@%$MATH_LIBS%g
1286s%@MAKE_LIB@%$MAKE_LIB%g
1287s%@SHLIB_CFLAGS@%$SHLIB_CFLAGS%g
1288s%@SHLIB_LD@%$SHLIB_LD%g
1289s%@SHLIB_LD_LIBS@%$SHLIB_LD_LIBS%g
1290s%@SHLIB_SUFFIX@%$SHLIB_SUFFIX%g
1291s%@SHLIB_VERSION@%$SHLIB_VERSION%g
1292s%@TCLX_TOP_DIR@%$TCLX_TOP_DIR%g
1293s%@TCLX_TCL_DIR@%$TCLX_TCL_DIR%g
1294s%@TCLX_LIB_SPEC@%$TCLX_LIB_SPEC%g
1295s%@ITCL_LIB_SPEC@%$ITCL_LIB_SPEC%g
1296s%@TCL_LIBS@%$TCL_LIBS%g
1297s%@TCL_SRC_DIR@%$TCL_SRC_DIR%g
1298s%@TCL_BIN_DIR@%$TCL_BIN_DIR%g
1299s%@TCL_LIB_SPEC@%$TCL_LIB_SPEC%g
1300s%@TCL_LD_SEARCH_FLAGS@%$TCL_LD_SEARCH_FLAGS%g
1301s%@TCL_LIB_HNAME@%$TCL_LIB_HNAME%g
1302s%@TCL_VERSION@%$TCL_VERSION%g
1303s%@NEO_BUILD_LIB_SPEC@%$NEO_BUILD_LIB_SPEC%g
1304s%@NEO_LD_SEARCH_FLAGS@%$NEO_LD_SEARCH_FLAGS%g
1305s%@NEO_SHARED_LIB_FILE@%$NEO_SHARED_LIB_FILE%g
1306s%@NEO_UNSHARED_LIB_FILE@%$NEO_UNSHARED_LIB_FILE%g
1307s%@NEO_LIB_FILE@%$NEO_LIB_FILE%g
1308s%@NEO_LIB_SPEC@%$NEO_LIB_SPEC%g
1309s%@NEO_MAJOR_VERSION@%$NEO_MAJOR_VERSION%g
1310s%@NEO_MINOR_VERSION@%$NEO_MINOR_VERSION%g
1311s%@NEO_SHLIB_CFLAGS@%$NEO_SHLIB_CFLAGS%g
1312s%@NEO_VERSION@%$NEO_VERSION%g
1313
1314CEOF
1315EOF
1316
1317cat >> $CONFIG_STATUS <<\EOF
1318
1319# Split the substitutions into bite-sized pieces for seds with
1320# small command number limits, like on Digital OSF/1 and HP-UX.
1321ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
1322ac_file=1 # Number of current file.
1323ac_beg=1 # First line for current file.
1324ac_end=$ac_max_sed_cmds # Line after last line for current file.
1325ac_more_lines=:
1326ac_sed_cmds=""
1327while $ac_more_lines; do
1328  if test $ac_beg -gt 1; then
1329    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
1330  else
1331    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
1332  fi
1333  if test ! -s conftest.s$ac_file; then
1334    ac_more_lines=false
1335    rm -f conftest.s$ac_file
1336  else
1337    if test -z "$ac_sed_cmds"; then
1338      ac_sed_cmds="sed -f conftest.s$ac_file"
1339    else
1340      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
1341    fi
1342    ac_file=`expr $ac_file + 1`
1343    ac_beg=$ac_end
1344    ac_end=`expr $ac_end + $ac_max_sed_cmds`
1345  fi
1346done
1347if test -z "$ac_sed_cmds"; then
1348  ac_sed_cmds=cat
1349fi
1350EOF
1351
1352cat >> $CONFIG_STATUS <<EOF
1353
1354CONFIG_FILES=\${CONFIG_FILES-"Makefile pkgIndex.tcl"}
1355EOF
1356cat >> $CONFIG_STATUS <<\EOF
1357for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
1358  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
1359  case "$ac_file" in
1360  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
1361       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1362  *) ac_file_in="${ac_file}.in" ;;
1363  esac
1364
1365  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
1366
1367  # Remove last slash and all that follows it.  Not all systems have dirname.
1368  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1369  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1370    # The file is in a subdirectory.
1371    test ! -d "$ac_dir" && mkdir "$ac_dir"
1372    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
1373    # A "../" for each directory in $ac_dir_suffix.
1374    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
1375  else
1376    ac_dir_suffix= ac_dots=
1377  fi
1378
1379  case "$ac_given_srcdir" in
1380  .)  srcdir=.
1381      if test -z "$ac_dots"; then top_srcdir=.
1382      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
1383  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
1384  *) # Relative path.
1385    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
1386    top_srcdir="$ac_dots$ac_given_srcdir" ;;
1387  esac
1388
1389  case "$ac_given_INSTALL" in
1390  [/$]*) INSTALL="$ac_given_INSTALL" ;;
1391  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
1392  esac
1393
1394  echo creating "$ac_file"
1395  rm -f "$ac_file"
1396  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1397  case "$ac_file" in
1398  *Makefile*) ac_comsub="1i\\
1399# $configure_input" ;;
1400  *) ac_comsub= ;;
1401  esac
1402
1403  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
1404  sed -e "$ac_comsub
1405s%@configure_input@%$configure_input%g
1406s%@srcdir@%$srcdir%g
1407s%@top_srcdir@%$top_srcdir%g
1408s%@INSTALL@%$INSTALL%g
1409" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
1410fi; done
1411rm -f conftest.s*
1412
1413EOF
1414cat >> $CONFIG_STATUS <<EOF
1415
1416EOF
1417cat >> $CONFIG_STATUS <<\EOF
1418
1419exit 0
1420EOF
1421chmod +x $CONFIG_STATUS
1422rm -fr confdefs* $ac_clean_files
1423test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
1424
1425