1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.70 for tdbcpostgres 1.1.3.
4#
5#
6# Copyright (C) 1992-1996, 1998-2017, 2020 Free Software Foundation, Inc.
7#
8#
9# This configure script is free software; the Free Software Foundation
10# gives unlimited permission to copy, distribute and modify it.
11## -------------------- ##
12## M4sh Initialization. ##
13## -------------------- ##
14
15# Be more Bourne compatible
16DUALCASE=1; export DUALCASE # for MKS sh
17as_nop=:
18if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
19then :
20  emulate sh
21  NULLCMD=:
22  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23  # is contrary to our usage.  Disable this feature.
24  alias -g '${1+"$@"}'='"$@"'
25  setopt NO_GLOB_SUBST
26else $as_nop
27  case `(set -o) 2>/dev/null` in #(
28  *posix*) :
29    set -o posix ;; #(
30  *) :
31     ;;
32esac
33fi
34
35
36
37# Reset variables that may have inherited troublesome values from
38# the environment.
39
40# IFS needs to be set, to space, tab, and newline, in precisely that order.
41# (If _AS_PATH_WALK were called with IFS unset, it would have the
42# side effect of setting IFS to empty, thus disabling word splitting.)
43# Quoting is to prevent editors from complaining about space-tab.
44as_nl='
45'
46export as_nl
47IFS=" ""	$as_nl"
48
49PS1='$ '
50PS2='> '
51PS4='+ '
52
53# Ensure predictable behavior from utilities with locale-dependent output.
54LC_ALL=C
55export LC_ALL
56LANGUAGE=C
57export LANGUAGE
58
59# We cannot yet rely on "unset" to work, but we need these variables
60# to be unset--not just set to an empty or harmless value--now, to
61# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh).  This construct
62# also avoids known problems related to "unset" and subshell syntax
63# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
64for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
65do eval test \${$as_var+y} \
66  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
67done
68
69# Ensure that fds 0, 1, and 2 are open.
70if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
71if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
72if (exec 3>&2)            ; then :; else exec 2>/dev/null; fi
73
74# The user is always right.
75if ${PATH_SEPARATOR+false} :; then
76  PATH_SEPARATOR=:
77  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79      PATH_SEPARATOR=';'
80  }
81fi
82
83
84# Find who we are.  Look in the path if we contain no directory separator.
85as_myself=
86case $0 in #((
87  *[\\/]* ) as_myself=$0 ;;
88  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
89for as_dir in $PATH
90do
91  IFS=$as_save_IFS
92  case $as_dir in #(((
93    '') as_dir=./ ;;
94    */) ;;
95    *) as_dir=$as_dir/ ;;
96  esac
97    test -r "$as_dir$0" && as_myself=$as_dir$0 && break
98  done
99IFS=$as_save_IFS
100
101     ;;
102esac
103# We did not find ourselves, most probably we were run as `sh COMMAND'
104# in which case we are not to be found in the path.
105if test "x$as_myself" = x; then
106  as_myself=$0
107fi
108if test ! -f "$as_myself"; then
109  printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
110  exit 1
111fi
112
113
114# Use a proper internal environment variable to ensure we don't fall
115  # into an infinite loop, continuously re-executing ourselves.
116  if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
117    _as_can_reexec=no; export _as_can_reexec;
118    # We cannot yet assume a decent shell, so we have to provide a
119# neutralization value for shells without unset; and this also
120# works around shells that cannot unset nonexistent variables.
121# Preserve -v and -x to the replacement shell.
122BASH_ENV=/dev/null
123ENV=/dev/null
124(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
125case $- in # ((((
126  *v*x* | *x*v* ) as_opts=-vx ;;
127  *v* ) as_opts=-v ;;
128  *x* ) as_opts=-x ;;
129  * ) as_opts= ;;
130esac
131exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
132# Admittedly, this is quite paranoid, since all the known shells bail
133# out after a failed `exec'.
134printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
135exit 255
136  fi
137  # We don't want this to propagate to other subprocesses.
138          { _as_can_reexec=; unset _as_can_reexec;}
139if test "x$CONFIG_SHELL" = x; then
140  as_bourne_compatible="as_nop=:
141if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
142then :
143  emulate sh
144  NULLCMD=:
145  # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
146  # is contrary to our usage.  Disable this feature.
147  alias -g '\${1+\"\$@\"}'='\"\$@\"'
148  setopt NO_GLOB_SUBST
149else \$as_nop
150  case \`(set -o) 2>/dev/null\` in #(
151  *posix*) :
152    set -o posix ;; #(
153  *) :
154     ;;
155esac
156fi
157"
158  as_required="as_fn_return () { (exit \$1); }
159as_fn_success () { as_fn_return 0; }
160as_fn_failure () { as_fn_return 1; }
161as_fn_ret_success () { return 0; }
162as_fn_ret_failure () { return 1; }
163
164exitcode=0
165as_fn_success || { exitcode=1; echo as_fn_success failed.; }
166as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
167as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
168as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
169if ( set x; as_fn_ret_success y && test x = \"\$1\" )
170then :
171
172else \$as_nop
173  exitcode=1; echo positional parameters were not saved.
174fi
175test x\$exitcode = x0 || exit 1
176blah=\$(echo \$(echo blah))
177test x\"\$blah\" = xblah || exit 1
178test -x / || exit 1"
179  as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
180  as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
181  eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
182  test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
183test \$(( 1 + 1 )) = 2 || exit 1"
184  if (eval "$as_required") 2>/dev/null
185then :
186  as_have_required=yes
187else $as_nop
188  as_have_required=no
189fi
190  if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null
191then :
192
193else $as_nop
194  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
195as_found=false
196for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
197do
198  IFS=$as_save_IFS
199  case $as_dir in #(((
200    '') as_dir=./ ;;
201    */) ;;
202    *) as_dir=$as_dir/ ;;
203  esac
204  as_found=:
205  case $as_dir in #(
206	 /*)
207	   for as_base in sh bash ksh sh5; do
208	     # Try only shells that exist, to save several forks.
209	     as_shell=$as_dir$as_base
210	     if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
211		    as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null
212then :
213  CONFIG_SHELL=$as_shell as_have_required=yes
214		   if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null
215then :
216  break 2
217fi
218fi
219	   done;;
220       esac
221  as_found=false
222done
223IFS=$as_save_IFS
224if $as_found
225then :
226
227else $as_nop
228  if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
229	      as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null
230then :
231  CONFIG_SHELL=$SHELL as_have_required=yes
232fi
233fi
234
235
236      if test "x$CONFIG_SHELL" != x
237then :
238  export CONFIG_SHELL
239             # We cannot yet assume a decent shell, so we have to provide a
240# neutralization value for shells without unset; and this also
241# works around shells that cannot unset nonexistent variables.
242# Preserve -v and -x to the replacement shell.
243BASH_ENV=/dev/null
244ENV=/dev/null
245(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
246case $- in # ((((
247  *v*x* | *x*v* ) as_opts=-vx ;;
248  *v* ) as_opts=-v ;;
249  *x* ) as_opts=-x ;;
250  * ) as_opts= ;;
251esac
252exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
253# Admittedly, this is quite paranoid, since all the known shells bail
254# out after a failed `exec'.
255printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
256exit 255
257fi
258
259    if test x$as_have_required = xno
260then :
261  printf "%s\n" "$0: This script requires a shell more modern than all"
262  printf "%s\n" "$0: the shells that I found on your system."
263  if test ${ZSH_VERSION+y} ; then
264    printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should"
265    printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later."
266  else
267    printf "%s\n" "$0: Please tell bug-autoconf@gnu.org about your system,
268$0: including any error possibly output before this
269$0: message. Then install a modern shell, or manually run
270$0: the script under such a shell if you do have one."
271  fi
272  exit 1
273fi
274fi
275fi
276SHELL=${CONFIG_SHELL-/bin/sh}
277export SHELL
278# Unset more variables known to interfere with behavior of common tools.
279CLICOLOR_FORCE= GREP_OPTIONS=
280unset CLICOLOR_FORCE GREP_OPTIONS
281
282## --------------------- ##
283## M4sh Shell Functions. ##
284## --------------------- ##
285# as_fn_unset VAR
286# ---------------
287# Portably unset VAR.
288as_fn_unset ()
289{
290  { eval $1=; unset $1;}
291}
292as_unset=as_fn_unset
293
294
295# as_fn_set_status STATUS
296# -----------------------
297# Set $? to STATUS, without forking.
298as_fn_set_status ()
299{
300  return $1
301} # as_fn_set_status
302
303# as_fn_exit STATUS
304# -----------------
305# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
306as_fn_exit ()
307{
308  set +e
309  as_fn_set_status $1
310  exit $1
311} # as_fn_exit
312# as_fn_nop
313# ---------
314# Do nothing but, unlike ":", preserve the value of $?.
315as_fn_nop ()
316{
317  return $?
318}
319as_nop=as_fn_nop
320
321# as_fn_mkdir_p
322# -------------
323# Create "$as_dir" as a directory, including parents if necessary.
324as_fn_mkdir_p ()
325{
326
327  case $as_dir in #(
328  -*) as_dir=./$as_dir;;
329  esac
330  test -d "$as_dir" || eval $as_mkdir_p || {
331    as_dirs=
332    while :; do
333      case $as_dir in #(
334      *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
335      *) as_qdir=$as_dir;;
336      esac
337      as_dirs="'$as_qdir' $as_dirs"
338      as_dir=`$as_dirname -- "$as_dir" ||
339$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
340	 X"$as_dir" : 'X\(//\)[^/]' \| \
341	 X"$as_dir" : 'X\(//\)$' \| \
342	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
343printf "%s\n" X"$as_dir" |
344    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
345	    s//\1/
346	    q
347	  }
348	  /^X\(\/\/\)[^/].*/{
349	    s//\1/
350	    q
351	  }
352	  /^X\(\/\/\)$/{
353	    s//\1/
354	    q
355	  }
356	  /^X\(\/\).*/{
357	    s//\1/
358	    q
359	  }
360	  s/.*/./; q'`
361      test -d "$as_dir" && break
362    done
363    test -z "$as_dirs" || eval "mkdir $as_dirs"
364  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
365
366
367} # as_fn_mkdir_p
368
369# as_fn_executable_p FILE
370# -----------------------
371# Test if FILE is an executable regular file.
372as_fn_executable_p ()
373{
374  test -f "$1" && test -x "$1"
375} # as_fn_executable_p
376# as_fn_append VAR VALUE
377# ----------------------
378# Append the text in VALUE to the end of the definition contained in VAR. Take
379# advantage of any shell optimizations that allow amortized linear growth over
380# repeated appends, instead of the typical quadratic growth present in naive
381# implementations.
382if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
383then :
384  eval 'as_fn_append ()
385  {
386    eval $1+=\$2
387  }'
388else $as_nop
389  as_fn_append ()
390  {
391    eval $1=\$$1\$2
392  }
393fi # as_fn_append
394
395# as_fn_arith ARG...
396# ------------------
397# Perform arithmetic evaluation on the ARGs, and store the result in the
398# global $as_val. Take advantage of shells that can avoid forks. The arguments
399# must be portable across $(()) and expr.
400if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
401then :
402  eval 'as_fn_arith ()
403  {
404    as_val=$(( $* ))
405  }'
406else $as_nop
407  as_fn_arith ()
408  {
409    as_val=`expr "$@" || test $? -eq 1`
410  }
411fi # as_fn_arith
412
413# as_fn_nop
414# ---------
415# Do nothing but, unlike ":", preserve the value of $?.
416as_fn_nop ()
417{
418  return $?
419}
420as_nop=as_fn_nop
421
422# as_fn_error STATUS ERROR [LINENO LOG_FD]
423# ----------------------------------------
424# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
425# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
426# script with STATUS, using 1 if that was 0.
427as_fn_error ()
428{
429  as_status=$1; test $as_status -eq 0 && as_status=1
430  if test "$4"; then
431    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
432    printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
433  fi
434  printf "%s\n" "$as_me: error: $2" >&2
435  as_fn_exit $as_status
436} # as_fn_error
437
438if expr a : '\(a\)' >/dev/null 2>&1 &&
439   test "X`expr 00001 : '.*\(...\)'`" = X001; then
440  as_expr=expr
441else
442  as_expr=false
443fi
444
445if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
446  as_basename=basename
447else
448  as_basename=false
449fi
450
451if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
452  as_dirname=dirname
453else
454  as_dirname=false
455fi
456
457as_me=`$as_basename -- "$0" ||
458$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
459	 X"$0" : 'X\(//\)$' \| \
460	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
461printf "%s\n" X/"$0" |
462    sed '/^.*\/\([^/][^/]*\)\/*$/{
463	    s//\1/
464	    q
465	  }
466	  /^X\/\(\/\/\)$/{
467	    s//\1/
468	    q
469	  }
470	  /^X\/\(\/\).*/{
471	    s//\1/
472	    q
473	  }
474	  s/.*/./; q'`
475
476# Avoid depending upon Character Ranges.
477as_cr_letters='abcdefghijklmnopqrstuvwxyz'
478as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
479as_cr_Letters=$as_cr_letters$as_cr_LETTERS
480as_cr_digits='0123456789'
481as_cr_alnum=$as_cr_Letters$as_cr_digits
482
483
484  as_lineno_1=$LINENO as_lineno_1a=$LINENO
485  as_lineno_2=$LINENO as_lineno_2a=$LINENO
486  eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
487  test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
488  # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
489  sed -n '
490    p
491    /[$]LINENO/=
492  ' <$as_myself |
493    sed '
494      s/[$]LINENO.*/&-/
495      t lineno
496      b
497      :lineno
498      N
499      :loop
500      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
501      t loop
502      s/-\n.*//
503    ' >$as_me.lineno &&
504  chmod +x "$as_me.lineno" ||
505    { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
506
507  # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
508  # already done that, so ensure we don't try to do so again and fall
509  # in an infinite loop.  This has already happened in practice.
510  _as_can_reexec=no; export _as_can_reexec
511  # Don't try to exec as it changes $[0], causing all sort of problems
512  # (the dirname of $[0] is not the place where we might find the
513  # original and so on.  Autoconf is especially sensitive to this).
514  . "./$as_me.lineno"
515  # Exit status is that of the last command.
516  exit
517}
518
519
520# Determine whether it's possible to make 'echo' print without a newline.
521# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
522# for compatibility with existing Makefiles.
523ECHO_C= ECHO_N= ECHO_T=
524case `echo -n x` in #(((((
525-n*)
526  case `echo 'xy\c'` in
527  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
528  xy)  ECHO_C='\c';;
529  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
530       ECHO_T='	';;
531  esac;;
532*)
533  ECHO_N='-n';;
534esac
535
536# For backward compatibility with old third-party macros, we provide
537# the shell variables $as_echo and $as_echo_n.  New code should use
538# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
539as_echo='printf %s\n'
540as_echo_n='printf %s'
541
542
543rm -f conf$$ conf$$.exe conf$$.file
544if test -d conf$$.dir; then
545  rm -f conf$$.dir/conf$$.file
546else
547  rm -f conf$$.dir
548  mkdir conf$$.dir 2>/dev/null
549fi
550if (echo >conf$$.file) 2>/dev/null; then
551  if ln -s conf$$.file conf$$ 2>/dev/null; then
552    as_ln_s='ln -s'
553    # ... but there are two gotchas:
554    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
555    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
556    # In both cases, we have to default to `cp -pR'.
557    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
558      as_ln_s='cp -pR'
559  elif ln conf$$.file conf$$ 2>/dev/null; then
560    as_ln_s=ln
561  else
562    as_ln_s='cp -pR'
563  fi
564else
565  as_ln_s='cp -pR'
566fi
567rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
568rmdir conf$$.dir 2>/dev/null
569
570if mkdir -p . 2>/dev/null; then
571  as_mkdir_p='mkdir -p "$as_dir"'
572else
573  test -d ./-p && rmdir ./-p
574  as_mkdir_p=false
575fi
576
577as_test_x='test -x'
578as_executable_p=as_fn_executable_p
579
580# Sed expression to map a string onto a valid CPP name.
581as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
582
583# Sed expression to map a string onto a valid variable name.
584as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
585
586
587test -n "$DJDIR" || exec 7<&0 </dev/null
588exec 6>&1
589
590# Name of the host.
591# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
592# so uname gets run too.
593ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
594
595#
596# Initializations.
597#
598ac_default_prefix=/usr/local
599ac_clean_files=
600ac_config_libobj_dir=.
601LIBOBJS=
602cross_compiling=no
603subdirs=
604MFLAGS=
605MAKEFLAGS=
606
607# Identity of this package.
608PACKAGE_NAME='tdbcpostgres'
609PACKAGE_TARNAME='tdbcpostgres'
610PACKAGE_VERSION='1.1.3'
611PACKAGE_STRING='tdbcpostgres 1.1.3'
612PACKAGE_BUGREPORT=''
613PACKAGE_URL=''
614
615# Factoring default headers for most tests.
616ac_includes_default="\
617#include <stddef.h>
618#ifdef HAVE_STDIO_H
619# include <stdio.h>
620#endif
621#ifdef HAVE_STDLIB_H
622# include <stdlib.h>
623#endif
624#ifdef HAVE_STRING_H
625# include <string.h>
626#endif
627#ifdef HAVE_INTTYPES_H
628# include <inttypes.h>
629#endif
630#ifdef HAVE_STDINT_H
631# include <stdint.h>
632#endif
633#ifdef HAVE_STRINGS_H
634# include <strings.h>
635#endif
636#ifdef HAVE_SYS_TYPES_H
637# include <sys/types.h>
638#endif
639#ifdef HAVE_SYS_STAT_H
640# include <sys/stat.h>
641#endif
642#ifdef HAVE_UNISTD_H
643# include <unistd.h>
644#endif"
645
646ac_header_c_list=
647ac_subst_vars='LTLIBOBJS
648TCLSH_PROG
649VC_MANIFEST_EMBED_EXE
650VC_MANIFEST_EMBED_DLL
651RANLIB_STUB
652MAKE_STUB_LIB
653MAKE_STATIC_LIB
654MAKE_SHARED_LIB
655MAKE_LIB
656EGREP
657GREP
658LDFLAGS_DEFAULT
659CFLAGS_DEFAULT
660LD_LIBRARY_PATH_VAR
661SHLIB_CFLAGS
662SHLIB_LD_LIBS
663SHLIB_LD
664STLIB_LD
665LDFLAGS_OPTIMIZE
666LDFLAGS_DEBUG
667CFLAGS_WARNING
668CFLAGS_OPTIMIZE
669CFLAGS_DEBUG
670LIBOBJS
671RC
672AR
673STUBS_BUILD
674SHARED_BUILD
675TCL_THREADS
676TCL_INCLUDES
677PKG_OBJECTS
678PKG_SOURCES
679RANLIB
680SET_MAKE
681CPP
682TDBC_LIB_FILE
683TDBC_VERSION
684tdbc_LIBRARY_PATH
685tdbc_STUB_LIB_PATH
686tdbc_STUB_LIB_SPEC
687tdbc_STUB_LIB_FILE
688tdbc_LIB_SPEC
689tdbc_LIB_FILE
690tdbc_SRC_DIR
691tdbc_BIN_DIR
692tdbc_VERSION
693TCL_VERSION_REQ
694TCL_SHLIB_LD_LIBS
695TCL_LD_FLAGS
696TCL_EXTRA_CFLAGS
697TCL_DEFS
698TCL_LIBS
699CLEANFILES
700OBJEXT
701ac_ct_CC
702CPPFLAGS
703LDFLAGS
704CFLAGS
705CC
706TCL_STUB_LIB_SPEC
707TCL_STUB_LIB_FLAG
708TCL_STUB_LIB_FILE
709TCL_LIB_SPEC
710TCL_LIB_FLAG
711TCL_LIB_FILE
712TCL_SRC_DIR
713TCL_BIN_DIR
714TCL_PATCH_LEVEL
715TCL_VERSION
716INSTALL_LIBRARY
717INSTALL_SCRIPT
718INSTALL_PROGRAM
719INSTALL_DATA
720INSTALL_DATA_DIR
721INSTALL
722PKG_CFLAGS
723PKG_LIBS
724PKG_INCLUDES
725PKG_HEADERS
726PKG_TCL_SOURCES
727PKG_STUB_OBJECTS
728PKG_STUB_SOURCES
729PKG_STUB_LIB_FILE
730PKG_LIB_FILE9
731PKG_LIB_FILE8
732PKG_LIB_FILE
733EXEEXT
734CYGPATH
735target_alias
736host_alias
737build_alias
738LIBS
739ECHO_T
740ECHO_N
741ECHO_C
742DEFS
743mandir
744localedir
745libdir
746psdir
747pdfdir
748dvidir
749htmldir
750infodir
751docdir
752oldincludedir
753includedir
754runstatedir
755localstatedir
756sharedstatedir
757sysconfdir
758datadir
759datarootdir
760libexecdir
761sbindir
762bindir
763program_transform_name
764prefix
765exec_prefix
766PACKAGE_URL
767PACKAGE_BUGREPORT
768PACKAGE_STRING
769PACKAGE_VERSION
770PACKAGE_TARNAME
771PACKAGE_NAME
772PATH_SEPARATOR
773SHELL'
774ac_subst_files=''
775ac_user_opts='
776enable_option_checking
777with_tcl
778with_tdbc
779with_tclinclude
780enable_threads
781enable_shared
782enable_stubs
783enable_64bit
784enable_64bit_vis
785enable_rpath
786enable_symbols
787'
788      ac_precious_vars='build_alias
789host_alias
790target_alias
791CC
792CFLAGS
793LDFLAGS
794LIBS
795CPPFLAGS
796CPP'
797
798
799# Initialize some variables set by options.
800ac_init_help=
801ac_init_version=false
802ac_unrecognized_opts=
803ac_unrecognized_sep=
804# The variables have the same names as the options, with
805# dashes changed to underlines.
806cache_file=/dev/null
807exec_prefix=NONE
808no_create=
809no_recursion=
810prefix=NONE
811program_prefix=NONE
812program_suffix=NONE
813program_transform_name=s,x,x,
814silent=
815site=
816srcdir=
817verbose=
818x_includes=NONE
819x_libraries=NONE
820
821# Installation directory options.
822# These are left unexpanded so users can "make install exec_prefix=/foo"
823# and all the variables that are supposed to be based on exec_prefix
824# by default will actually change.
825# Use braces instead of parens because sh, perl, etc. also accept them.
826# (The list follows the same order as the GNU Coding Standards.)
827bindir='${exec_prefix}/bin'
828sbindir='${exec_prefix}/sbin'
829libexecdir='${exec_prefix}/libexec'
830datarootdir='${prefix}/share'
831datadir='${datarootdir}'
832sysconfdir='${prefix}/etc'
833sharedstatedir='${prefix}/com'
834localstatedir='${prefix}/var'
835runstatedir='${localstatedir}/run'
836includedir='${prefix}/include'
837oldincludedir='/usr/include'
838docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
839infodir='${datarootdir}/info'
840htmldir='${docdir}'
841dvidir='${docdir}'
842pdfdir='${docdir}'
843psdir='${docdir}'
844libdir='${exec_prefix}/lib'
845localedir='${datarootdir}/locale'
846mandir='${datarootdir}/man'
847
848ac_prev=
849ac_dashdash=
850for ac_option
851do
852  # If the previous option needs an argument, assign it.
853  if test -n "$ac_prev"; then
854    eval $ac_prev=\$ac_option
855    ac_prev=
856    continue
857  fi
858
859  case $ac_option in
860  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
861  *=)   ac_optarg= ;;
862  *)    ac_optarg=yes ;;
863  esac
864
865  case $ac_dashdash$ac_option in
866  --)
867    ac_dashdash=yes ;;
868
869  -bindir | --bindir | --bindi | --bind | --bin | --bi)
870    ac_prev=bindir ;;
871  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
872    bindir=$ac_optarg ;;
873
874  -build | --build | --buil | --bui | --bu)
875    ac_prev=build_alias ;;
876  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
877    build_alias=$ac_optarg ;;
878
879  -cache-file | --cache-file | --cache-fil | --cache-fi \
880  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
881    ac_prev=cache_file ;;
882  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
883  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
884    cache_file=$ac_optarg ;;
885
886  --config-cache | -C)
887    cache_file=config.cache ;;
888
889  -datadir | --datadir | --datadi | --datad)
890    ac_prev=datadir ;;
891  -datadir=* | --datadir=* | --datadi=* | --datad=*)
892    datadir=$ac_optarg ;;
893
894  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
895  | --dataroo | --dataro | --datar)
896    ac_prev=datarootdir ;;
897  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
898  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
899    datarootdir=$ac_optarg ;;
900
901  -disable-* | --disable-*)
902    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
903    # Reject names that are not valid shell variable names.
904    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
905      as_fn_error $? "invalid feature name: \`$ac_useropt'"
906    ac_useropt_orig=$ac_useropt
907    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
908    case $ac_user_opts in
909      *"
910"enable_$ac_useropt"
911"*) ;;
912      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
913	 ac_unrecognized_sep=', ';;
914    esac
915    eval enable_$ac_useropt=no ;;
916
917  -docdir | --docdir | --docdi | --doc | --do)
918    ac_prev=docdir ;;
919  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
920    docdir=$ac_optarg ;;
921
922  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
923    ac_prev=dvidir ;;
924  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
925    dvidir=$ac_optarg ;;
926
927  -enable-* | --enable-*)
928    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
929    # Reject names that are not valid shell variable names.
930    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
931      as_fn_error $? "invalid feature name: \`$ac_useropt'"
932    ac_useropt_orig=$ac_useropt
933    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
934    case $ac_user_opts in
935      *"
936"enable_$ac_useropt"
937"*) ;;
938      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
939	 ac_unrecognized_sep=', ';;
940    esac
941    eval enable_$ac_useropt=\$ac_optarg ;;
942
943  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
944  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
945  | --exec | --exe | --ex)
946    ac_prev=exec_prefix ;;
947  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
948  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
949  | --exec=* | --exe=* | --ex=*)
950    exec_prefix=$ac_optarg ;;
951
952  -gas | --gas | --ga | --g)
953    # Obsolete; use --with-gas.
954    with_gas=yes ;;
955
956  -help | --help | --hel | --he | -h)
957    ac_init_help=long ;;
958  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
959    ac_init_help=recursive ;;
960  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
961    ac_init_help=short ;;
962
963  -host | --host | --hos | --ho)
964    ac_prev=host_alias ;;
965  -host=* | --host=* | --hos=* | --ho=*)
966    host_alias=$ac_optarg ;;
967
968  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
969    ac_prev=htmldir ;;
970  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
971  | --ht=*)
972    htmldir=$ac_optarg ;;
973
974  -includedir | --includedir | --includedi | --included | --include \
975  | --includ | --inclu | --incl | --inc)
976    ac_prev=includedir ;;
977  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
978  | --includ=* | --inclu=* | --incl=* | --inc=*)
979    includedir=$ac_optarg ;;
980
981  -infodir | --infodir | --infodi | --infod | --info | --inf)
982    ac_prev=infodir ;;
983  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
984    infodir=$ac_optarg ;;
985
986  -libdir | --libdir | --libdi | --libd)
987    ac_prev=libdir ;;
988  -libdir=* | --libdir=* | --libdi=* | --libd=*)
989    libdir=$ac_optarg ;;
990
991  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
992  | --libexe | --libex | --libe)
993    ac_prev=libexecdir ;;
994  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
995  | --libexe=* | --libex=* | --libe=*)
996    libexecdir=$ac_optarg ;;
997
998  -localedir | --localedir | --localedi | --localed | --locale)
999    ac_prev=localedir ;;
1000  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1001    localedir=$ac_optarg ;;
1002
1003  -localstatedir | --localstatedir | --localstatedi | --localstated \
1004  | --localstate | --localstat | --localsta | --localst | --locals)
1005    ac_prev=localstatedir ;;
1006  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1007  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1008    localstatedir=$ac_optarg ;;
1009
1010  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1011    ac_prev=mandir ;;
1012  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1013    mandir=$ac_optarg ;;
1014
1015  -nfp | --nfp | --nf)
1016    # Obsolete; use --without-fp.
1017    with_fp=no ;;
1018
1019  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1020  | --no-cr | --no-c | -n)
1021    no_create=yes ;;
1022
1023  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1024  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1025    no_recursion=yes ;;
1026
1027  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1028  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1029  | --oldin | --oldi | --old | --ol | --o)
1030    ac_prev=oldincludedir ;;
1031  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1032  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1033  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1034    oldincludedir=$ac_optarg ;;
1035
1036  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1037    ac_prev=prefix ;;
1038  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1039    prefix=$ac_optarg ;;
1040
1041  -program-prefix | --program-prefix | --program-prefi | --program-pref \
1042  | --program-pre | --program-pr | --program-p)
1043    ac_prev=program_prefix ;;
1044  -program-prefix=* | --program-prefix=* | --program-prefi=* \
1045  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1046    program_prefix=$ac_optarg ;;
1047
1048  -program-suffix | --program-suffix | --program-suffi | --program-suff \
1049  | --program-suf | --program-su | --program-s)
1050    ac_prev=program_suffix ;;
1051  -program-suffix=* | --program-suffix=* | --program-suffi=* \
1052  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1053    program_suffix=$ac_optarg ;;
1054
1055  -program-transform-name | --program-transform-name \
1056  | --program-transform-nam | --program-transform-na \
1057  | --program-transform-n | --program-transform- \
1058  | --program-transform | --program-transfor \
1059  | --program-transfo | --program-transf \
1060  | --program-trans | --program-tran \
1061  | --progr-tra | --program-tr | --program-t)
1062    ac_prev=program_transform_name ;;
1063  -program-transform-name=* | --program-transform-name=* \
1064  | --program-transform-nam=* | --program-transform-na=* \
1065  | --program-transform-n=* | --program-transform-=* \
1066  | --program-transform=* | --program-transfor=* \
1067  | --program-transfo=* | --program-transf=* \
1068  | --program-trans=* | --program-tran=* \
1069  | --progr-tra=* | --program-tr=* | --program-t=*)
1070    program_transform_name=$ac_optarg ;;
1071
1072  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1073    ac_prev=pdfdir ;;
1074  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1075    pdfdir=$ac_optarg ;;
1076
1077  -psdir | --psdir | --psdi | --psd | --ps)
1078    ac_prev=psdir ;;
1079  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1080    psdir=$ac_optarg ;;
1081
1082  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1083  | -silent | --silent | --silen | --sile | --sil)
1084    silent=yes ;;
1085
1086  -runstatedir | --runstatedir | --runstatedi | --runstated \
1087  | --runstate | --runstat | --runsta | --runst | --runs \
1088  | --run | --ru | --r)
1089    ac_prev=runstatedir ;;
1090  -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1091  | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1092  | --run=* | --ru=* | --r=*)
1093    runstatedir=$ac_optarg ;;
1094
1095  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1096    ac_prev=sbindir ;;
1097  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1098  | --sbi=* | --sb=*)
1099    sbindir=$ac_optarg ;;
1100
1101  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1102  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1103  | --sharedst | --shareds | --shared | --share | --shar \
1104  | --sha | --sh)
1105    ac_prev=sharedstatedir ;;
1106  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1107  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1108  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1109  | --sha=* | --sh=*)
1110    sharedstatedir=$ac_optarg ;;
1111
1112  -site | --site | --sit)
1113    ac_prev=site ;;
1114  -site=* | --site=* | --sit=*)
1115    site=$ac_optarg ;;
1116
1117  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1118    ac_prev=srcdir ;;
1119  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1120    srcdir=$ac_optarg ;;
1121
1122  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1123  | --syscon | --sysco | --sysc | --sys | --sy)
1124    ac_prev=sysconfdir ;;
1125  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1126  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1127    sysconfdir=$ac_optarg ;;
1128
1129  -target | --target | --targe | --targ | --tar | --ta | --t)
1130    ac_prev=target_alias ;;
1131  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1132    target_alias=$ac_optarg ;;
1133
1134  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1135    verbose=yes ;;
1136
1137  -version | --version | --versio | --versi | --vers | -V)
1138    ac_init_version=: ;;
1139
1140  -with-* | --with-*)
1141    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1142    # Reject names that are not valid shell variable names.
1143    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1144      as_fn_error $? "invalid package name: \`$ac_useropt'"
1145    ac_useropt_orig=$ac_useropt
1146    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1147    case $ac_user_opts in
1148      *"
1149"with_$ac_useropt"
1150"*) ;;
1151      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1152	 ac_unrecognized_sep=', ';;
1153    esac
1154    eval with_$ac_useropt=\$ac_optarg ;;
1155
1156  -without-* | --without-*)
1157    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1158    # Reject names that are not valid shell variable names.
1159    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1160      as_fn_error $? "invalid package name: \`$ac_useropt'"
1161    ac_useropt_orig=$ac_useropt
1162    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1163    case $ac_user_opts in
1164      *"
1165"with_$ac_useropt"
1166"*) ;;
1167      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1168	 ac_unrecognized_sep=', ';;
1169    esac
1170    eval with_$ac_useropt=no ;;
1171
1172  --x)
1173    # Obsolete; use --with-x.
1174    with_x=yes ;;
1175
1176  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1177  | --x-incl | --x-inc | --x-in | --x-i)
1178    ac_prev=x_includes ;;
1179  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1180  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1181    x_includes=$ac_optarg ;;
1182
1183  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1184  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1185    ac_prev=x_libraries ;;
1186  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1187  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1188    x_libraries=$ac_optarg ;;
1189
1190  -*) as_fn_error $? "unrecognized option: \`$ac_option'
1191Try \`$0 --help' for more information"
1192    ;;
1193
1194  *=*)
1195    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1196    # Reject names that are not valid shell variable names.
1197    case $ac_envvar in #(
1198      '' | [0-9]* | *[!_$as_cr_alnum]* )
1199      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1200    esac
1201    eval $ac_envvar=\$ac_optarg
1202    export $ac_envvar ;;
1203
1204  *)
1205    # FIXME: should be removed in autoconf 3.0.
1206    printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2
1207    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1208      printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2
1209    : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1210    ;;
1211
1212  esac
1213done
1214
1215if test -n "$ac_prev"; then
1216  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1217  as_fn_error $? "missing argument to $ac_option"
1218fi
1219
1220if test -n "$ac_unrecognized_opts"; then
1221  case $enable_option_checking in
1222    no) ;;
1223    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1224    *)     printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1225  esac
1226fi
1227
1228# Check all directory arguments for consistency.
1229for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1230		datadir sysconfdir sharedstatedir localstatedir includedir \
1231		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1232		libdir localedir mandir runstatedir
1233do
1234  eval ac_val=\$$ac_var
1235  # Remove trailing slashes.
1236  case $ac_val in
1237    */ )
1238      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1239      eval $ac_var=\$ac_val;;
1240  esac
1241  # Be sure to have absolute directory names.
1242  case $ac_val in
1243    [\\/$]* | ?:[\\/]* )  continue;;
1244    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1245  esac
1246  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1247done
1248
1249# There might be people who depend on the old broken behavior: `$host'
1250# used to hold the argument of --host etc.
1251# FIXME: To remove some day.
1252build=$build_alias
1253host=$host_alias
1254target=$target_alias
1255
1256# FIXME: To remove some day.
1257if test "x$host_alias" != x; then
1258  if test "x$build_alias" = x; then
1259    cross_compiling=maybe
1260  elif test "x$build_alias" != "x$host_alias"; then
1261    cross_compiling=yes
1262  fi
1263fi
1264
1265ac_tool_prefix=
1266test -n "$host_alias" && ac_tool_prefix=$host_alias-
1267
1268test "$silent" = yes && exec 6>/dev/null
1269
1270
1271ac_pwd=`pwd` && test -n "$ac_pwd" &&
1272ac_ls_di=`ls -di .` &&
1273ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1274  as_fn_error $? "working directory cannot be determined"
1275test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1276  as_fn_error $? "pwd does not report name of working directory"
1277
1278
1279# Find the source files, if location was not specified.
1280if test -z "$srcdir"; then
1281  ac_srcdir_defaulted=yes
1282  # Try the directory containing this script, then the parent directory.
1283  ac_confdir=`$as_dirname -- "$as_myself" ||
1284$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1285	 X"$as_myself" : 'X\(//\)[^/]' \| \
1286	 X"$as_myself" : 'X\(//\)$' \| \
1287	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1288printf "%s\n" X"$as_myself" |
1289    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1290	    s//\1/
1291	    q
1292	  }
1293	  /^X\(\/\/\)[^/].*/{
1294	    s//\1/
1295	    q
1296	  }
1297	  /^X\(\/\/\)$/{
1298	    s//\1/
1299	    q
1300	  }
1301	  /^X\(\/\).*/{
1302	    s//\1/
1303	    q
1304	  }
1305	  s/.*/./; q'`
1306  srcdir=$ac_confdir
1307  if test ! -r "$srcdir/$ac_unique_file"; then
1308    srcdir=..
1309  fi
1310else
1311  ac_srcdir_defaulted=no
1312fi
1313if test ! -r "$srcdir/$ac_unique_file"; then
1314  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1315  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1316fi
1317ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1318ac_abs_confdir=`(
1319	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1320	pwd)`
1321# When building in place, set srcdir=.
1322if test "$ac_abs_confdir" = "$ac_pwd"; then
1323  srcdir=.
1324fi
1325# Remove unnecessary trailing slashes from srcdir.
1326# Double slashes in file names in object file debugging info
1327# mess up M-x gdb in Emacs.
1328case $srcdir in
1329*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1330esac
1331for ac_var in $ac_precious_vars; do
1332  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1333  eval ac_env_${ac_var}_value=\$${ac_var}
1334  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1335  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1336done
1337
1338#
1339# Report the --help message.
1340#
1341if test "$ac_init_help" = "long"; then
1342  # Omit some internal or obsolete options to make the list less imposing.
1343  # This message is too long to be a string in the A/UX 3.1 sh.
1344  cat <<_ACEOF
1345\`configure' configures tdbcpostgres 1.1.3 to adapt to many kinds of systems.
1346
1347Usage: $0 [OPTION]... [VAR=VALUE]...
1348
1349To assign environment variables (e.g., CC, CFLAGS...), specify them as
1350VAR=VALUE.  See below for descriptions of some of the useful variables.
1351
1352Defaults for the options are specified in brackets.
1353
1354Configuration:
1355  -h, --help              display this help and exit
1356      --help=short        display options specific to this package
1357      --help=recursive    display the short help of all the included packages
1358  -V, --version           display version information and exit
1359  -q, --quiet, --silent   do not print \`checking ...' messages
1360      --cache-file=FILE   cache test results in FILE [disabled]
1361  -C, --config-cache      alias for \`--cache-file=config.cache'
1362  -n, --no-create         do not create output files
1363      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1364
1365Installation directories:
1366  --prefix=PREFIX         install architecture-independent files in PREFIX
1367                          [$ac_default_prefix]
1368  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1369                          [PREFIX]
1370
1371By default, \`make install' will install all the files in
1372\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1373an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1374for instance \`--prefix=\$HOME'.
1375
1376For better control, use the options below.
1377
1378Fine tuning of the installation directories:
1379  --bindir=DIR            user executables [EPREFIX/bin]
1380  --sbindir=DIR           system admin executables [EPREFIX/sbin]
1381  --libexecdir=DIR        program executables [EPREFIX/libexec]
1382  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1383  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1384  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1385  --runstatedir=DIR       modifiable per-process data [LOCALSTATEDIR/run]
1386  --libdir=DIR            object code libraries [EPREFIX/lib]
1387  --includedir=DIR        C header files [PREFIX/include]
1388  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1389  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1390  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1391  --infodir=DIR           info documentation [DATAROOTDIR/info]
1392  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1393  --mandir=DIR            man documentation [DATAROOTDIR/man]
1394  --docdir=DIR            documentation root [DATAROOTDIR/doc/tdbcpostgres]
1395  --htmldir=DIR           html documentation [DOCDIR]
1396  --dvidir=DIR            dvi documentation [DOCDIR]
1397  --pdfdir=DIR            pdf documentation [DOCDIR]
1398  --psdir=DIR             ps documentation [DOCDIR]
1399_ACEOF
1400
1401  cat <<\_ACEOF
1402_ACEOF
1403fi
1404
1405if test -n "$ac_init_help"; then
1406  case $ac_init_help in
1407     short | recursive ) echo "Configuration of tdbcpostgres 1.1.3:";;
1408   esac
1409  cat <<\_ACEOF
1410
1411Optional Features:
1412  --disable-option-checking  ignore unrecognized --enable/--with options
1413  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1414  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1415  --enable-threads        build with threads (default: on)
1416  --enable-shared         build and link with shared libraries (default: on)
1417  --enable-stubs          build and link with stub libraries. Always true for
1418                          shared builds (default: on)
1419  --enable-64bit          enable 64bit support (default: off)
1420  --enable-64bit-vis      enable 64bit Sparc VIS support (default: off)
1421  --disable-rpath         disable rpath support (default: on)
1422  --enable-symbols        build with debugging symbols (default: off)
1423
1424Optional Packages:
1425  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1426  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1427  --with-tcl              directory containing tcl configuration
1428                          (tclConfig.sh)
1429  --with-tdbc              directory containing tdbc configuration (tdbcConfig.sh)
1430  --with-tclinclude       directory containing the public Tcl header files
1431
1432Some influential environment variables:
1433  CC          C compiler command
1434  CFLAGS      C compiler flags
1435  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1436              nonstandard directory <lib dir>
1437  LIBS        libraries to pass to the linker, e.g. -l<library>
1438  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1439              you have headers in a nonstandard directory <include dir>
1440  CPP         C preprocessor
1441
1442Use these variables to override the choices made by `configure' or to help
1443it to find libraries and programs with nonstandard names/locations.
1444
1445Report bugs to the package provider.
1446_ACEOF
1447ac_status=$?
1448fi
1449
1450if test "$ac_init_help" = "recursive"; then
1451  # If there are subdirs, report their specific --help.
1452  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1453    test -d "$ac_dir" ||
1454      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1455      continue
1456    ac_builddir=.
1457
1458case "$ac_dir" in
1459.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1460*)
1461  ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
1462  # A ".." for each directory in $ac_dir_suffix.
1463  ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1464  case $ac_top_builddir_sub in
1465  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1466  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1467  esac ;;
1468esac
1469ac_abs_top_builddir=$ac_pwd
1470ac_abs_builddir=$ac_pwd$ac_dir_suffix
1471# for backward compatibility:
1472ac_top_builddir=$ac_top_build_prefix
1473
1474case $srcdir in
1475  .)  # We are building in place.
1476    ac_srcdir=.
1477    ac_top_srcdir=$ac_top_builddir_sub
1478    ac_abs_top_srcdir=$ac_pwd ;;
1479  [\\/]* | ?:[\\/]* )  # Absolute name.
1480    ac_srcdir=$srcdir$ac_dir_suffix;
1481    ac_top_srcdir=$srcdir
1482    ac_abs_top_srcdir=$srcdir ;;
1483  *) # Relative name.
1484    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1485    ac_top_srcdir=$ac_top_build_prefix$srcdir
1486    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1487esac
1488ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1489
1490    cd "$ac_dir" || { ac_status=$?; continue; }
1491    # Check for configure.gnu first; this name is used for a wrapper for
1492    # Metaconfig's "Configure" on case-insensitive file systems.
1493    if test -f "$ac_srcdir/configure.gnu"; then
1494      echo &&
1495      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1496    elif test -f "$ac_srcdir/configure"; then
1497      echo &&
1498      $SHELL "$ac_srcdir/configure" --help=recursive
1499    else
1500      printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1501    fi || ac_status=$?
1502    cd "$ac_pwd" || { ac_status=$?; break; }
1503  done
1504fi
1505
1506test -n "$ac_init_help" && exit $ac_status
1507if $ac_init_version; then
1508  cat <<\_ACEOF
1509tdbcpostgres configure 1.1.3
1510generated by GNU Autoconf 2.70
1511
1512Copyright (C) 2020 Free Software Foundation, Inc.
1513This configure script is free software; the Free Software Foundation
1514gives unlimited permission to copy, distribute and modify it.
1515_ACEOF
1516  exit
1517fi
1518
1519## ------------------------ ##
1520## Autoconf initialization. ##
1521## ------------------------ ##
1522
1523# ac_fn_c_try_compile LINENO
1524# --------------------------
1525# Try to compile conftest.$ac_ext, and return whether this succeeded.
1526ac_fn_c_try_compile ()
1527{
1528  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1529  rm -f conftest.$ac_objext conftest.beam
1530  if { { ac_try="$ac_compile"
1531case "(($ac_try" in
1532  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1533  *) ac_try_echo=$ac_try;;
1534esac
1535eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1536printf "%s\n" "$ac_try_echo"; } >&5
1537  (eval "$ac_compile") 2>conftest.err
1538  ac_status=$?
1539  if test -s conftest.err; then
1540    grep -v '^ *+' conftest.err >conftest.er1
1541    cat conftest.er1 >&5
1542    mv -f conftest.er1 conftest.err
1543  fi
1544  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1545  test $ac_status = 0; } && {
1546	 test -z "$ac_c_werror_flag" ||
1547	 test ! -s conftest.err
1548       } && test -s conftest.$ac_objext
1549then :
1550  ac_retval=0
1551else $as_nop
1552  printf "%s\n" "$as_me: failed program was:" >&5
1553sed 's/^/| /' conftest.$ac_ext >&5
1554
1555	ac_retval=1
1556fi
1557  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1558  as_fn_set_status $ac_retval
1559
1560} # ac_fn_c_try_compile
1561
1562# ac_fn_c_try_cpp LINENO
1563# ----------------------
1564# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1565ac_fn_c_try_cpp ()
1566{
1567  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1568  if { { ac_try="$ac_cpp conftest.$ac_ext"
1569case "(($ac_try" in
1570  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1571  *) ac_try_echo=$ac_try;;
1572esac
1573eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1574printf "%s\n" "$ac_try_echo"; } >&5
1575  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1576  ac_status=$?
1577  if test -s conftest.err; then
1578    grep -v '^ *+' conftest.err >conftest.er1
1579    cat conftest.er1 >&5
1580    mv -f conftest.er1 conftest.err
1581  fi
1582  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1583  test $ac_status = 0; } > conftest.i && {
1584	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1585	 test ! -s conftest.err
1586       }
1587then :
1588  ac_retval=0
1589else $as_nop
1590  printf "%s\n" "$as_me: failed program was:" >&5
1591sed 's/^/| /' conftest.$ac_ext >&5
1592
1593    ac_retval=1
1594fi
1595  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1596  as_fn_set_status $ac_retval
1597
1598} # ac_fn_c_try_cpp
1599
1600# ac_fn_c_try_run LINENO
1601# ----------------------
1602# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that
1603# executables *can* be run.
1604ac_fn_c_try_run ()
1605{
1606  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1607  if { { ac_try="$ac_link"
1608case "(($ac_try" in
1609  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1610  *) ac_try_echo=$ac_try;;
1611esac
1612eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1613printf "%s\n" "$ac_try_echo"; } >&5
1614  (eval "$ac_link") 2>&5
1615  ac_status=$?
1616  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1617  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1618  { { case "(($ac_try" in
1619  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1620  *) ac_try_echo=$ac_try;;
1621esac
1622eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1623printf "%s\n" "$ac_try_echo"; } >&5
1624  (eval "$ac_try") 2>&5
1625  ac_status=$?
1626  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1627  test $ac_status = 0; }; }
1628then :
1629  ac_retval=0
1630else $as_nop
1631  printf "%s\n" "$as_me: program exited with status $ac_status" >&5
1632       printf "%s\n" "$as_me: failed program was:" >&5
1633sed 's/^/| /' conftest.$ac_ext >&5
1634
1635       ac_retval=$ac_status
1636fi
1637  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1638  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1639  as_fn_set_status $ac_retval
1640
1641} # ac_fn_c_try_run
1642
1643# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1644# -------------------------------------------------------
1645# Tests whether HEADER exists and can be compiled using the include files in
1646# INCLUDES, setting the cache variable VAR accordingly.
1647ac_fn_c_check_header_compile ()
1648{
1649  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1650  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1651printf %s "checking for $2... " >&6; }
1652if eval test \${$3+y}
1653then :
1654  printf %s "(cached) " >&6
1655else $as_nop
1656  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1657/* end confdefs.h.  */
1658$4
1659#include <$2>
1660_ACEOF
1661if ac_fn_c_try_compile "$LINENO"
1662then :
1663  eval "$3=yes"
1664else $as_nop
1665  eval "$3=no"
1666fi
1667rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1668fi
1669eval ac_res=\$$3
1670	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1671printf "%s\n" "$ac_res" >&6; }
1672  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1673
1674} # ac_fn_c_check_header_compile
1675
1676# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1677# -------------------------------------------
1678# Tests whether TYPE exists after having included INCLUDES, setting cache
1679# variable VAR accordingly.
1680ac_fn_c_check_type ()
1681{
1682  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1683  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1684printf %s "checking for $2... " >&6; }
1685if eval test \${$3+y}
1686then :
1687  printf %s "(cached) " >&6
1688else $as_nop
1689  eval "$3=no"
1690  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1691/* end confdefs.h.  */
1692$4
1693int
1694main (void)
1695{
1696if (sizeof ($2))
1697	 return 0;
1698  ;
1699  return 0;
1700}
1701_ACEOF
1702if ac_fn_c_try_compile "$LINENO"
1703then :
1704  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1705/* end confdefs.h.  */
1706$4
1707int
1708main (void)
1709{
1710if (sizeof (($2)))
1711	    return 0;
1712  ;
1713  return 0;
1714}
1715_ACEOF
1716if ac_fn_c_try_compile "$LINENO"
1717then :
1718
1719else $as_nop
1720  eval "$3=yes"
1721fi
1722rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1723fi
1724rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1725fi
1726eval ac_res=\$$3
1727	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1728printf "%s\n" "$ac_res" >&6; }
1729  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1730
1731} # ac_fn_c_check_type
1732
1733# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
1734# --------------------------------------------
1735# Tries to find the compile-time value of EXPR in a program that includes
1736# INCLUDES, setting VAR accordingly. Returns whether the value could be
1737# computed
1738ac_fn_c_compute_int ()
1739{
1740  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1741  if test "$cross_compiling" = yes; then
1742    # Depending upon the size, compute the lo and hi bounds.
1743cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1744/* end confdefs.h.  */
1745$4
1746int
1747main (void)
1748{
1749static int test_array [1 - 2 * !(($2) >= 0)];
1750test_array [0] = 0;
1751return test_array [0];
1752
1753  ;
1754  return 0;
1755}
1756_ACEOF
1757if ac_fn_c_try_compile "$LINENO"
1758then :
1759  ac_lo=0 ac_mid=0
1760  while :; do
1761    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1762/* end confdefs.h.  */
1763$4
1764int
1765main (void)
1766{
1767static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1768test_array [0] = 0;
1769return test_array [0];
1770
1771  ;
1772  return 0;
1773}
1774_ACEOF
1775if ac_fn_c_try_compile "$LINENO"
1776then :
1777  ac_hi=$ac_mid; break
1778else $as_nop
1779  as_fn_arith $ac_mid + 1 && ac_lo=$as_val
1780			if test $ac_lo -le $ac_mid; then
1781			  ac_lo= ac_hi=
1782			  break
1783			fi
1784			as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
1785fi
1786rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1787  done
1788else $as_nop
1789  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1790/* end confdefs.h.  */
1791$4
1792int
1793main (void)
1794{
1795static int test_array [1 - 2 * !(($2) < 0)];
1796test_array [0] = 0;
1797return test_array [0];
1798
1799  ;
1800  return 0;
1801}
1802_ACEOF
1803if ac_fn_c_try_compile "$LINENO"
1804then :
1805  ac_hi=-1 ac_mid=-1
1806  while :; do
1807    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1808/* end confdefs.h.  */
1809$4
1810int
1811main (void)
1812{
1813static int test_array [1 - 2 * !(($2) >= $ac_mid)];
1814test_array [0] = 0;
1815return test_array [0];
1816
1817  ;
1818  return 0;
1819}
1820_ACEOF
1821if ac_fn_c_try_compile "$LINENO"
1822then :
1823  ac_lo=$ac_mid; break
1824else $as_nop
1825  as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
1826			if test $ac_mid -le $ac_hi; then
1827			  ac_lo= ac_hi=
1828			  break
1829			fi
1830			as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
1831fi
1832rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1833  done
1834else $as_nop
1835  ac_lo= ac_hi=
1836fi
1837rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1838fi
1839rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1840# Binary search between lo and hi bounds.
1841while test "x$ac_lo" != "x$ac_hi"; do
1842  as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
1843  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1844/* end confdefs.h.  */
1845$4
1846int
1847main (void)
1848{
1849static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1850test_array [0] = 0;
1851return test_array [0];
1852
1853  ;
1854  return 0;
1855}
1856_ACEOF
1857if ac_fn_c_try_compile "$LINENO"
1858then :
1859  ac_hi=$ac_mid
1860else $as_nop
1861  as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
1862fi
1863rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1864done
1865case $ac_lo in #((
1866?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
1867'') ac_retval=1 ;;
1868esac
1869  else
1870    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1871/* end confdefs.h.  */
1872$4
1873static long int longval (void) { return $2; }
1874static unsigned long int ulongval (void) { return $2; }
1875#include <stdio.h>
1876#include <stdlib.h>
1877int
1878main (void)
1879{
1880
1881  FILE *f = fopen ("conftest.val", "w");
1882  if (! f)
1883    return 1;
1884  if (($2) < 0)
1885    {
1886      long int i = longval ();
1887      if (i != ($2))
1888	return 1;
1889      fprintf (f, "%ld", i);
1890    }
1891  else
1892    {
1893      unsigned long int i = ulongval ();
1894      if (i != ($2))
1895	return 1;
1896      fprintf (f, "%lu", i);
1897    }
1898  /* Do not output a trailing newline, as this causes \r\n confusion
1899     on some platforms.  */
1900  return ferror (f) || fclose (f) != 0;
1901
1902  ;
1903  return 0;
1904}
1905_ACEOF
1906if ac_fn_c_try_run "$LINENO"
1907then :
1908  echo >>conftest.val; read $3 <conftest.val; ac_retval=0
1909else $as_nop
1910  ac_retval=1
1911fi
1912rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
1913  conftest.$ac_objext conftest.beam conftest.$ac_ext
1914rm -f conftest.val
1915
1916  fi
1917  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1918  as_fn_set_status $ac_retval
1919
1920} # ac_fn_c_compute_int
1921
1922# ac_fn_c_try_link LINENO
1923# -----------------------
1924# Try to link conftest.$ac_ext, and return whether this succeeded.
1925ac_fn_c_try_link ()
1926{
1927  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1928  rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext
1929  if { { ac_try="$ac_link"
1930case "(($ac_try" in
1931  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1932  *) ac_try_echo=$ac_try;;
1933esac
1934eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1935printf "%s\n" "$ac_try_echo"; } >&5
1936  (eval "$ac_link") 2>conftest.err
1937  ac_status=$?
1938  if test -s conftest.err; then
1939    grep -v '^ *+' conftest.err >conftest.er1
1940    cat conftest.er1 >&5
1941    mv -f conftest.er1 conftest.err
1942  fi
1943  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1944  test $ac_status = 0; } && {
1945	 test -z "$ac_c_werror_flag" ||
1946	 test ! -s conftest.err
1947       } && test -s conftest$ac_exeext && {
1948	 test "$cross_compiling" = yes ||
1949	 test -x conftest$ac_exeext
1950       }
1951then :
1952  ac_retval=0
1953else $as_nop
1954  printf "%s\n" "$as_me: failed program was:" >&5
1955sed 's/^/| /' conftest.$ac_ext >&5
1956
1957	ac_retval=1
1958fi
1959  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1960  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1961  # interfere with the next link command; also delete a directory that is
1962  # left behind by Apple's compiler.  We do this before executing the actions.
1963  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1964  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1965  as_fn_set_status $ac_retval
1966
1967} # ac_fn_c_try_link
1968
1969# ac_fn_c_check_func LINENO FUNC VAR
1970# ----------------------------------
1971# Tests whether FUNC exists, setting the cache variable VAR accordingly
1972ac_fn_c_check_func ()
1973{
1974  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1975  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1976printf %s "checking for $2... " >&6; }
1977if eval test \${$3+y}
1978then :
1979  printf %s "(cached) " >&6
1980else $as_nop
1981  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1982/* end confdefs.h.  */
1983/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1984   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
1985#define $2 innocuous_$2
1986
1987/* System header to define __stub macros and hopefully few prototypes,
1988   which can conflict with char $2 (); below.  */
1989
1990#include <limits.h>
1991#undef $2
1992
1993/* Override any GCC internal prototype to avoid an error.
1994   Use char because int might match the return type of a GCC
1995   builtin and then its argument prototype would still apply.  */
1996#ifdef __cplusplus
1997extern "C"
1998#endif
1999char $2 ();
2000/* The GNU C library defines this for functions which it implements
2001    to always fail with ENOSYS.  Some functions are actually named
2002    something starting with __ and the normal name is an alias.  */
2003#if defined __stub_$2 || defined __stub___$2
2004choke me
2005#endif
2006
2007int
2008main (void)
2009{
2010return $2 ();
2011  ;
2012  return 0;
2013}
2014_ACEOF
2015if ac_fn_c_try_link "$LINENO"
2016then :
2017  eval "$3=yes"
2018else $as_nop
2019  eval "$3=no"
2020fi
2021rm -f core conftest.err conftest.$ac_objext conftest.beam \
2022    conftest$ac_exeext conftest.$ac_ext
2023fi
2024eval ac_res=\$$3
2025	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2026printf "%s\n" "$ac_res" >&6; }
2027  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2028
2029} # ac_fn_c_check_func
2030ac_configure_args_raw=
2031for ac_arg
2032do
2033  case $ac_arg in
2034  *\'*)
2035    ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2036  esac
2037  as_fn_append ac_configure_args_raw " '$ac_arg'"
2038done
2039
2040case $ac_configure_args_raw in
2041  *$as_nl*)
2042    ac_safe_unquote= ;;
2043  *)
2044    ac_unsafe_z='|&;<>()$`\\"*?[ ''	' # This string ends in space, tab.
2045    ac_unsafe_a="$ac_unsafe_z#~"
2046    ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g"
2047    ac_configure_args_raw=`      printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;;
2048esac
2049
2050cat >config.log <<_ACEOF
2051This file contains any messages produced by compilers while
2052running configure, to aid debugging if configure makes a mistake.
2053
2054It was created by tdbcpostgres $as_me 1.1.3, which was
2055generated by GNU Autoconf 2.70.  Invocation command line was
2056
2057  $ $0$ac_configure_args_raw
2058
2059_ACEOF
2060exec 5>>config.log
2061{
2062cat <<_ASUNAME
2063## --------- ##
2064## Platform. ##
2065## --------- ##
2066
2067hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2068uname -m = `(uname -m) 2>/dev/null || echo unknown`
2069uname -r = `(uname -r) 2>/dev/null || echo unknown`
2070uname -s = `(uname -s) 2>/dev/null || echo unknown`
2071uname -v = `(uname -v) 2>/dev/null || echo unknown`
2072
2073/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2074/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2075
2076/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2077/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2078/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2079/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2080/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2081/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2082/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2083
2084_ASUNAME
2085
2086as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2087for as_dir in $PATH
2088do
2089  IFS=$as_save_IFS
2090  case $as_dir in #(((
2091    '') as_dir=./ ;;
2092    */) ;;
2093    *) as_dir=$as_dir/ ;;
2094  esac
2095    printf "%s\n" "PATH: $as_dir"
2096  done
2097IFS=$as_save_IFS
2098
2099} >&5
2100
2101cat >&5 <<_ACEOF
2102
2103
2104## ----------- ##
2105## Core tests. ##
2106## ----------- ##
2107
2108_ACEOF
2109
2110
2111# Keep a trace of the command line.
2112# Strip out --no-create and --no-recursion so they do not pile up.
2113# Strip out --silent because we don't want to record it for future runs.
2114# Also quote any args containing shell meta-characters.
2115# Make two passes to allow for proper duplicate-argument suppression.
2116ac_configure_args=
2117ac_configure_args0=
2118ac_configure_args1=
2119ac_must_keep_next=false
2120for ac_pass in 1 2
2121do
2122  for ac_arg
2123  do
2124    case $ac_arg in
2125    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2126    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2127    | -silent | --silent | --silen | --sile | --sil)
2128      continue ;;
2129    *\'*)
2130      ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2131    esac
2132    case $ac_pass in
2133    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2134    2)
2135      as_fn_append ac_configure_args1 " '$ac_arg'"
2136      if test $ac_must_keep_next = true; then
2137	ac_must_keep_next=false # Got value, back to normal.
2138      else
2139	case $ac_arg in
2140	  *=* | --config-cache | -C | -disable-* | --disable-* \
2141	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2142	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2143	  | -with-* | --with-* | -without-* | --without-* | --x)
2144	    case "$ac_configure_args0 " in
2145	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2146	    esac
2147	    ;;
2148	  -* ) ac_must_keep_next=true ;;
2149	esac
2150      fi
2151      as_fn_append ac_configure_args " '$ac_arg'"
2152      ;;
2153    esac
2154  done
2155done
2156{ ac_configure_args0=; unset ac_configure_args0;}
2157{ ac_configure_args1=; unset ac_configure_args1;}
2158
2159# When interrupted or exit'd, cleanup temporary files, and complete
2160# config.log.  We remove comments because anyway the quotes in there
2161# would cause problems or look ugly.
2162# WARNING: Use '\'' to represent an apostrophe within the trap.
2163# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2164trap 'exit_status=$?
2165  # Sanitize IFS.
2166  IFS=" ""	$as_nl"
2167  # Save into config.log some information that might help in debugging.
2168  {
2169    echo
2170
2171    printf "%s\n" "## ---------------- ##
2172## Cache variables. ##
2173## ---------------- ##"
2174    echo
2175    # The following way of writing the cache mishandles newlines in values,
2176(
2177  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2178    eval ac_val=\$$ac_var
2179    case $ac_val in #(
2180    *${as_nl}*)
2181      case $ac_var in #(
2182      *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2183printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2184      esac
2185      case $ac_var in #(
2186      _ | IFS | as_nl) ;; #(
2187      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2188      *) { eval $ac_var=; unset $ac_var;} ;;
2189      esac ;;
2190    esac
2191  done
2192  (set) 2>&1 |
2193    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2194    *${as_nl}ac_space=\ *)
2195      sed -n \
2196	"s/'\''/'\''\\\\'\'''\''/g;
2197	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2198      ;; #(
2199    *)
2200      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2201      ;;
2202    esac |
2203    sort
2204)
2205    echo
2206
2207    printf "%s\n" "## ----------------- ##
2208## Output variables. ##
2209## ----------------- ##"
2210    echo
2211    for ac_var in $ac_subst_vars
2212    do
2213      eval ac_val=\$$ac_var
2214      case $ac_val in
2215      *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2216      esac
2217      printf "%s\n" "$ac_var='\''$ac_val'\''"
2218    done | sort
2219    echo
2220
2221    if test -n "$ac_subst_files"; then
2222      printf "%s\n" "## ------------------- ##
2223## File substitutions. ##
2224## ------------------- ##"
2225      echo
2226      for ac_var in $ac_subst_files
2227      do
2228	eval ac_val=\$$ac_var
2229	case $ac_val in
2230	*\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2231	esac
2232	printf "%s\n" "$ac_var='\''$ac_val'\''"
2233      done | sort
2234      echo
2235    fi
2236
2237    if test -s confdefs.h; then
2238      printf "%s\n" "## ----------- ##
2239## confdefs.h. ##
2240## ----------- ##"
2241      echo
2242      cat confdefs.h
2243      echo
2244    fi
2245    test "$ac_signal" != 0 &&
2246      printf "%s\n" "$as_me: caught signal $ac_signal"
2247    printf "%s\n" "$as_me: exit $exit_status"
2248  } >&5
2249  rm -f core *.core core.conftest.* &&
2250    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2251    exit $exit_status
2252' 0
2253for ac_signal in 1 2 13 15; do
2254  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2255done
2256ac_signal=0
2257
2258# confdefs.h avoids OS command line length limits that DEFS can exceed.
2259rm -f -r conftest* confdefs.h
2260
2261printf "%s\n" "/* confdefs.h */" > confdefs.h
2262
2263# Predefined preprocessor variables.
2264
2265printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h
2266
2267printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h
2268
2269printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h
2270
2271printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h
2272
2273printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h
2274
2275printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h
2276
2277
2278# Let the site file select an alternate cache file if it wants to.
2279# Prefer an explicitly selected file to automatically selected ones.
2280if test -n "$CONFIG_SITE"; then
2281  ac_site_files="$CONFIG_SITE"
2282elif test "x$prefix" != xNONE; then
2283  ac_site_files="$prefix/share/config.site $prefix/etc/config.site"
2284else
2285  ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
2286fi
2287
2288for ac_site_file in $ac_site_files
2289do
2290  case $ac_site_file in #(
2291  */*) :
2292     ;; #(
2293  *) :
2294    ac_site_file=./$ac_site_file ;;
2295esac
2296  if test -f "$ac_site_file" && test -r "$ac_site_file"; then
2297    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2298printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;}
2299    sed 's/^/| /' "$ac_site_file" >&5
2300    . "$ac_site_file" \
2301      || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2302printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
2303as_fn_error $? "failed to load site script $ac_site_file
2304See \`config.log' for more details" "$LINENO" 5; }
2305  fi
2306done
2307
2308if test -r "$cache_file"; then
2309  # Some versions of bash will fail to source /dev/null (special files
2310  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2311  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2312    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2313printf "%s\n" "$as_me: loading cache $cache_file" >&6;}
2314    case $cache_file in
2315      [\\/]* | ?:[\\/]* ) . "$cache_file";;
2316      *)                      . "./$cache_file";;
2317    esac
2318  fi
2319else
2320  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2321printf "%s\n" "$as_me: creating cache $cache_file" >&6;}
2322  >$cache_file
2323fi
2324
2325# Test code for whether the C compiler supports C89 (global declarations)
2326ac_c_conftest_c89_globals='
2327/* Does the compiler advertise C89 conformance?
2328   Do not test the value of __STDC__, because some compilers set it to 0
2329   while being otherwise adequately conformant. */
2330#if !defined __STDC__
2331# error "Compiler does not advertise C89 conformance"
2332#endif
2333
2334#include <stddef.h>
2335#include <stdarg.h>
2336struct stat;
2337/* Most of the following tests are stolen from RCS 5.7 src/conf.sh.  */
2338struct buf { int x; };
2339struct buf * (*rcsopen) (struct buf *, struct stat *, int);
2340static char *e (p, i)
2341     char **p;
2342     int i;
2343{
2344  return p[i];
2345}
2346static char *f (char * (*g) (char **, int), char **p, ...)
2347{
2348  char *s;
2349  va_list v;
2350  va_start (v,p);
2351  s = g (p, va_arg (v,int));
2352  va_end (v);
2353  return s;
2354}
2355
2356/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
2357   function prototypes and stuff, but not \xHH hex character constants.
2358   These do not provoke an error unfortunately, instead are silently treated
2359   as an "x".  The following induces an error, until -std is added to get
2360   proper ANSI mode.  Curiously \x00 != x always comes out true, for an
2361   array size at least.  It is necessary to write \x00 == 0 to get something
2362   that is true only with -std.  */
2363int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1];
2364
2365/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
2366   inside strings and character constants.  */
2367#define FOO(x) '\''x'\''
2368int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1];
2369
2370int test (int i, double x);
2371struct s1 {int (*f) (int a);};
2372struct s2 {int (*f) (double a);};
2373int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int),
2374               int, int);'
2375
2376# Test code for whether the C compiler supports C89 (body of main).
2377ac_c_conftest_c89_main='
2378ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]);
2379'
2380
2381# Test code for whether the C compiler supports C99 (global declarations)
2382ac_c_conftest_c99_globals='
2383// Does the compiler advertise C99 conformance?
2384#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L
2385# error "Compiler does not advertise C99 conformance"
2386#endif
2387
2388#include <stdbool.h>
2389extern int puts (const char *);
2390extern int printf (const char *, ...);
2391extern int dprintf (int, const char *, ...);
2392extern void *malloc (size_t);
2393
2394// Check varargs macros.  These examples are taken from C99 6.10.3.5.
2395// dprintf is used instead of fprintf to avoid needing to declare
2396// FILE and stderr.
2397#define debug(...) dprintf (2, __VA_ARGS__)
2398#define showlist(...) puts (#__VA_ARGS__)
2399#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
2400static void
2401test_varargs_macros (void)
2402{
2403  int x = 1234;
2404  int y = 5678;
2405  debug ("Flag");
2406  debug ("X = %d\n", x);
2407  showlist (The first, second, and third items.);
2408  report (x>y, "x is %d but y is %d", x, y);
2409}
2410
2411// Check long long types.
2412#define BIG64 18446744073709551615ull
2413#define BIG32 4294967295ul
2414#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
2415#if !BIG_OK
2416  #error "your preprocessor is broken"
2417#endif
2418#if BIG_OK
2419#else
2420  #error "your preprocessor is broken"
2421#endif
2422static long long int bignum = -9223372036854775807LL;
2423static unsigned long long int ubignum = BIG64;
2424
2425struct incomplete_array
2426{
2427  int datasize;
2428  double data[];
2429};
2430
2431struct named_init {
2432  int number;
2433  const wchar_t *name;
2434  double average;
2435};
2436
2437typedef const char *ccp;
2438
2439static inline int
2440test_restrict (ccp restrict text)
2441{
2442  // See if C++-style comments work.
2443  // Iterate through items via the restricted pointer.
2444  // Also check for declarations in for loops.
2445  for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i)
2446    continue;
2447  return 0;
2448}
2449
2450// Check varargs and va_copy.
2451static bool
2452test_varargs (const char *format, ...)
2453{
2454  va_list args;
2455  va_start (args, format);
2456  va_list args_copy;
2457  va_copy (args_copy, args);
2458
2459  const char *str = "";
2460  int number = 0;
2461  float fnumber = 0;
2462
2463  while (*format)
2464    {
2465      switch (*format++)
2466	{
2467	case '\''s'\'': // string
2468	  str = va_arg (args_copy, const char *);
2469	  break;
2470	case '\''d'\'': // int
2471	  number = va_arg (args_copy, int);
2472	  break;
2473	case '\''f'\'': // float
2474	  fnumber = va_arg (args_copy, double);
2475	  break;
2476	default:
2477	  break;
2478	}
2479    }
2480  va_end (args_copy);
2481  va_end (args);
2482
2483  return *str && number && fnumber;
2484}
2485'
2486
2487# Test code for whether the C compiler supports C99 (body of main).
2488ac_c_conftest_c99_main='
2489  // Check bool.
2490  _Bool success = false;
2491  success |= (argc != 0);
2492
2493  // Check restrict.
2494  if (test_restrict ("String literal") == 0)
2495    success = true;
2496  char *restrict newvar = "Another string";
2497
2498  // Check varargs.
2499  success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234);
2500  test_varargs_macros ();
2501
2502  // Check flexible array members.
2503  struct incomplete_array *ia =
2504    malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
2505  ia->datasize = 10;
2506  for (int i = 0; i < ia->datasize; ++i)
2507    ia->data[i] = i * 1.234;
2508
2509  // Check named initializers.
2510  struct named_init ni = {
2511    .number = 34,
2512    .name = L"Test wide string",
2513    .average = 543.34343,
2514  };
2515
2516  ni.number = 58;
2517
2518  int dynamic_array[ni.number];
2519  dynamic_array[0] = argv[0][0];
2520  dynamic_array[ni.number - 1] = 543;
2521
2522  // work around unused variable warnings
2523  ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\''
2524	 || dynamic_array[ni.number - 1] != 543);
2525'
2526
2527# Test code for whether the C compiler supports C11 (global declarations)
2528ac_c_conftest_c11_globals='
2529// Does the compiler advertise C11 conformance?
2530#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L
2531# error "Compiler does not advertise C11 conformance"
2532#endif
2533
2534// Check _Alignas.
2535char _Alignas (double) aligned_as_double;
2536char _Alignas (0) no_special_alignment;
2537extern char aligned_as_int;
2538char _Alignas (0) _Alignas (int) aligned_as_int;
2539
2540// Check _Alignof.
2541enum
2542{
2543  int_alignment = _Alignof (int),
2544  int_array_alignment = _Alignof (int[100]),
2545  char_alignment = _Alignof (char)
2546};
2547_Static_assert (0 < -_Alignof (int), "_Alignof is signed");
2548
2549// Check _Noreturn.
2550int _Noreturn does_not_return (void) { for (;;) continue; }
2551
2552// Check _Static_assert.
2553struct test_static_assert
2554{
2555  int x;
2556  _Static_assert (sizeof (int) <= sizeof (long int),
2557                  "_Static_assert does not work in struct");
2558  long int y;
2559};
2560
2561// Check UTF-8 literals.
2562#define u8 syntax error!
2563char const utf8_literal[] = u8"happens to be ASCII" "another string";
2564
2565// Check duplicate typedefs.
2566typedef long *long_ptr;
2567typedef long int *long_ptr;
2568typedef long_ptr long_ptr;
2569
2570// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
2571struct anonymous
2572{
2573  union {
2574    struct { int i; int j; };
2575    struct { int k; long int l; } w;
2576  };
2577  int m;
2578} v1;
2579'
2580
2581# Test code for whether the C compiler supports C11 (body of main).
2582ac_c_conftest_c11_main='
2583  _Static_assert ((offsetof (struct anonymous, i)
2584		   == offsetof (struct anonymous, w.k)),
2585		  "Anonymous union alignment botch");
2586  v1.i = 2;
2587  v1.w.k = 5;
2588  ok |= v1.i != 5;
2589'
2590
2591# Test code for whether the C compiler supports C11 (complete).
2592ac_c_conftest_c11_program="${ac_c_conftest_c89_globals}
2593${ac_c_conftest_c99_globals}
2594${ac_c_conftest_c11_globals}
2595
2596int
2597main (int argc, char **argv)
2598{
2599  int ok = 0;
2600  ${ac_c_conftest_c89_main}
2601  ${ac_c_conftest_c99_main}
2602  ${ac_c_conftest_c11_main}
2603  return ok;
2604}
2605"
2606
2607# Test code for whether the C compiler supports C99 (complete).
2608ac_c_conftest_c99_program="${ac_c_conftest_c89_globals}
2609${ac_c_conftest_c99_globals}
2610
2611int
2612main (int argc, char **argv)
2613{
2614  int ok = 0;
2615  ${ac_c_conftest_c89_main}
2616  ${ac_c_conftest_c99_main}
2617  return ok;
2618}
2619"
2620
2621# Test code for whether the C compiler supports C89 (complete).
2622ac_c_conftest_c89_program="${ac_c_conftest_c89_globals}
2623
2624int
2625main (int argc, char **argv)
2626{
2627  int ok = 0;
2628  ${ac_c_conftest_c89_main}
2629  return ok;
2630}
2631"
2632
2633as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H"
2634as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H"
2635as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H"
2636as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H"
2637as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H"
2638as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H"
2639as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H"
2640as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H"
2641as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H"
2642# Check that the precious variables saved in the cache have kept the same
2643# value.
2644ac_cache_corrupted=false
2645for ac_var in $ac_precious_vars; do
2646  eval ac_old_set=\$ac_cv_env_${ac_var}_set
2647  eval ac_new_set=\$ac_env_${ac_var}_set
2648  eval ac_old_val=\$ac_cv_env_${ac_var}_value
2649  eval ac_new_val=\$ac_env_${ac_var}_value
2650  case $ac_old_set,$ac_new_set in
2651    set,)
2652      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2653printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2654      ac_cache_corrupted=: ;;
2655    ,set)
2656      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2657printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2658      ac_cache_corrupted=: ;;
2659    ,);;
2660    *)
2661      if test "x$ac_old_val" != "x$ac_new_val"; then
2662	# differences in whitespace do not lead to failure.
2663	ac_old_val_w=`echo x $ac_old_val`
2664	ac_new_val_w=`echo x $ac_new_val`
2665	if test "$ac_old_val_w" != "$ac_new_val_w"; then
2666	  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2667printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2668	  ac_cache_corrupted=:
2669	else
2670	  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2671printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2672	  eval $ac_var=\$ac_old_val
2673	fi
2674	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2675printf "%s\n" "$as_me:   former value:  \`$ac_old_val'" >&2;}
2676	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2677printf "%s\n" "$as_me:   current value: \`$ac_new_val'" >&2;}
2678      fi;;
2679  esac
2680  # Pass precious variables to config.status.
2681  if test "$ac_new_set" = set; then
2682    case $ac_new_val in
2683    *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2684    *) ac_arg=$ac_var=$ac_new_val ;;
2685    esac
2686    case " $ac_configure_args " in
2687      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2688      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2689    esac
2690  fi
2691done
2692if $ac_cache_corrupted; then
2693  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2694printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
2695  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2696printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;}
2697  as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file'
2698	    and start over" "$LINENO" 5
2699fi
2700## -------------------- ##
2701## Main body of script. ##
2702## -------------------- ##
2703
2704ac_ext=c
2705ac_cpp='$CPP $CPPFLAGS'
2706ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2707ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2708ac_compiler_gnu=$ac_cv_c_compiler_gnu
2709
2710
2711
2712#--------------------------------------------------------------------
2713# Call TEA_INIT as the first TEA_ macro to set up initial vars.
2714# This will define a ${TEA_PLATFORM} variable == "unix" or "windows"
2715# as well as PKG_LIB_FILE and PKG_STUB_LIB_FILE.
2716#--------------------------------------------------------------------
2717
2718
2719    TEA_VERSION="3.13"
2720
2721    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking TEA configuration" >&5
2722printf %s "checking TEA configuration... " >&6; }
2723    if test x"${PACKAGE_NAME}" = x ; then
2724	as_fn_error $? "
2725The PACKAGE_NAME variable must be defined by your TEA configure.ac" "$LINENO" 5
2726    fi
2727    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok (TEA ${TEA_VERSION})" >&5
2728printf "%s\n" "ok (TEA ${TEA_VERSION})" >&6; }
2729
2730    # If the user did not set CFLAGS, set it now to keep macros
2731    # like AC_PROG_CC and AC_TRY_COMPILE from adding "-g -O2".
2732    if test "${CFLAGS+set}" != "set" ; then
2733	CFLAGS=""
2734    fi
2735
2736    case "`uname -s`" in
2737	*win32*|*WIN32*|*MINGW32_*|*MINGW64_*|*MSYS_*)
2738	    # Extract the first word of "cygpath", so it can be a program name with args.
2739set dummy cygpath; ac_word=$2
2740{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2741printf %s "checking for $ac_word... " >&6; }
2742if test ${ac_cv_prog_CYGPATH+y}
2743then :
2744  printf %s "(cached) " >&6
2745else $as_nop
2746  if test -n "$CYGPATH"; then
2747  ac_cv_prog_CYGPATH="$CYGPATH" # Let the user override the test.
2748else
2749as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2750for as_dir in $PATH
2751do
2752  IFS=$as_save_IFS
2753  case $as_dir in #(((
2754    '') as_dir=./ ;;
2755    */) ;;
2756    *) as_dir=$as_dir/ ;;
2757  esac
2758    for ac_exec_ext in '' $ac_executable_extensions; do
2759  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
2760    ac_cv_prog_CYGPATH="cygpath -m"
2761    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
2762    break 2
2763  fi
2764done
2765  done
2766IFS=$as_save_IFS
2767
2768  test -z "$ac_cv_prog_CYGPATH" && ac_cv_prog_CYGPATH="echo"
2769fi
2770fi
2771CYGPATH=$ac_cv_prog_CYGPATH
2772if test -n "$CYGPATH"; then
2773  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
2774printf "%s\n" "$CYGPATH" >&6; }
2775else
2776  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
2777printf "%s\n" "no" >&6; }
2778fi
2779
2780
2781	    EXEEXT=".exe"
2782	    TEA_PLATFORM="windows"
2783	    ;;
2784	*CYGWIN_*)
2785	    EXEEXT=".exe"
2786	    # CYGPATH and TEA_PLATFORM are determined later in LOAD_TCLCONFIG
2787	    ;;
2788	*)
2789	    CYGPATH=echo
2790	    # Maybe we are cross-compiling....
2791	    case ${host_alias} in
2792		*mingw32*)
2793		EXEEXT=".exe"
2794		TEA_PLATFORM="windows"
2795		;;
2796	    *)
2797		EXEEXT=""
2798		TEA_PLATFORM="unix"
2799		;;
2800	    esac
2801	    ;;
2802    esac
2803
2804    # Check if exec_prefix is set. If not use fall back to prefix.
2805    # Note when adjusted, so that TEA_PREFIX can correct for this.
2806    # This is needed for recursive configures, since autoconf propagates
2807    # $prefix, but not $exec_prefix (doh!).
2808    if test x$exec_prefix = xNONE ; then
2809	exec_prefix_default=yes
2810	exec_prefix=$prefix
2811    fi
2812
2813    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: configuring ${PACKAGE_NAME} ${PACKAGE_VERSION}" >&5
2814printf "%s\n" "$as_me: configuring ${PACKAGE_NAME} ${PACKAGE_VERSION}" >&6;}
2815
2816
2817
2818
2819    # This package name must be replaced statically for AC_SUBST to work
2820
2821
2822
2823    # Substitute STUB_LIB_FILE in case package creates a stub library too.
2824
2825
2826    # We AC_SUBST these here to ensure they are subst'ed,
2827    # in case the user doesn't call TEA_ADD_...
2828
2829
2830
2831
2832
2833
2834
2835
2836    # Configure the installer.
2837
2838    INSTALL='$(SHELL) $(srcdir)/tclconfig/install-sh -c'
2839    INSTALL_DATA_DIR='${INSTALL} -d -m 755'
2840    INSTALL_DATA='${INSTALL} -m 644'
2841    INSTALL_PROGRAM='${INSTALL} -m 755'
2842    INSTALL_SCRIPT='${INSTALL} -m 755'
2843
2844
2845    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking system version" >&5
2846printf %s "checking system version... " >&6; }
2847if test ${tcl_cv_sys_version+y}
2848then :
2849  printf %s "(cached) " >&6
2850else $as_nop
2851
2852	# TEA specific:
2853	if test "${TEA_PLATFORM}" = "windows" ; then
2854	    tcl_cv_sys_version=windows
2855	else
2856	    tcl_cv_sys_version=`uname -s`-`uname -r`
2857	    if test "$?" -ne 0 ; then
2858		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: can't find uname command" >&5
2859printf "%s\n" "$as_me: WARNING: can't find uname command" >&2;}
2860		tcl_cv_sys_version=unknown
2861	    else
2862		if test "`uname -s`" = "AIX" ; then
2863		    tcl_cv_sys_version=AIX-`uname -v`.`uname -r`
2864		fi
2865		if test "`uname -s`" = "NetBSD" -a -f /etc/debian_version ; then
2866		    tcl_cv_sys_version=NetBSD-Debian
2867		fi
2868	    fi
2869	fi
2870
2871fi
2872{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_sys_version" >&5
2873printf "%s\n" "$tcl_cv_sys_version" >&6; }
2874    system=$tcl_cv_sys_version
2875
2876    case $system in
2877	HP-UX-*) INSTALL_LIBRARY='${INSTALL} -m 755' ;;
2878	      *) INSTALL_LIBRARY='${INSTALL} -m 644' ;;
2879    esac
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892#--------------------------------------------------------------------
2893# Load the tclConfig.sh file
2894#--------------------------------------------------------------------
2895
2896
2897
2898    #
2899    # Ok, lets find the tcl configuration
2900    # First, look for one uninstalled.
2901    # the alternative search directory is invoked by --with-tcl
2902    #
2903
2904    if test x"${no_tcl}" = x ; then
2905	# we reset no_tcl in case something fails here
2906	no_tcl=true
2907
2908# Check whether --with-tcl was given.
2909if test ${with_tcl+y}
2910then :
2911  withval=$with_tcl; with_tclconfig="${withval}"
2912fi
2913
2914	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5
2915printf %s "checking for Tcl configuration... " >&6; }
2916	if test ${ac_cv_c_tclconfig+y}
2917then :
2918  printf %s "(cached) " >&6
2919else $as_nop
2920
2921
2922	    # First check to see if --with-tcl was specified.
2923	    if test x"${with_tclconfig}" != x ; then
2924		case "${with_tclconfig}" in
2925		    */tclConfig.sh )
2926			if test -f "${with_tclconfig}"; then
2927			    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: --with-tcl argument should refer to directory containing tclConfig.sh, not to tclConfig.sh itself" >&5
2928printf "%s\n" "$as_me: WARNING: --with-tcl argument should refer to directory containing tclConfig.sh, not to tclConfig.sh itself" >&2;}
2929			    with_tclconfig="`echo "${with_tclconfig}" | sed 's!/tclConfig\.sh$!!'`"
2930			fi ;;
2931		esac
2932		if test -f "${with_tclconfig}/tclConfig.sh" ; then
2933		    ac_cv_c_tclconfig="`(cd "${with_tclconfig}"; pwd)`"
2934		else
2935		    as_fn_error $? "${with_tclconfig} directory doesn't contain tclConfig.sh" "$LINENO" 5
2936		fi
2937	    fi
2938
2939	    # then check for a private Tcl installation
2940	    if test x"${ac_cv_c_tclconfig}" = x ; then
2941		for i in \
2942			../tcl \
2943			`ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
2944			`ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
2945			`ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
2946			../../tcl \
2947			`ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
2948			`ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
2949			`ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
2950			../../../tcl \
2951			`ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
2952			`ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
2953			`ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
2954		    if test "${TEA_PLATFORM}" = "windows" \
2955			    -a -f "$i/win/tclConfig.sh" ; then
2956			ac_cv_c_tclconfig="`(cd $i/win; pwd)`"
2957			break
2958		    fi
2959		    if test -f "$i/unix/tclConfig.sh" ; then
2960			ac_cv_c_tclconfig="`(cd $i/unix; pwd)`"
2961			break
2962		    fi
2963		done
2964	    fi
2965
2966	    # on Darwin, check in Framework installation locations
2967	    if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
2968		for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
2969			`ls -d /Library/Frameworks 2>/dev/null` \
2970			`ls -d /Network/Library/Frameworks 2>/dev/null` \
2971			`ls -d /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/Library/Frameworks/Tcl.framework 2>/dev/null` \
2972			`ls -d /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/Network/Library/Frameworks/Tcl.framework 2>/dev/null` \
2973			`ls -d /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Tcl.framework 2>/dev/null` \
2974			; do
2975		    if test -f "$i/Tcl.framework/tclConfig.sh" ; then
2976			ac_cv_c_tclconfig="`(cd $i/Tcl.framework; pwd)`"
2977			break
2978		    fi
2979		done
2980	    fi
2981
2982	    # TEA specific: on Windows, check in common installation locations
2983	    if test "${TEA_PLATFORM}" = "windows" \
2984		-a x"${ac_cv_c_tclconfig}" = x ; then
2985		for i in `ls -d C:/Tcl/lib 2>/dev/null` \
2986			`ls -d C:/Progra~1/Tcl/lib 2>/dev/null` \
2987			; do
2988		    if test -f "$i/tclConfig.sh" ; then
2989			ac_cv_c_tclconfig="`(cd $i; pwd)`"
2990			break
2991		    fi
2992		done
2993	    fi
2994
2995	    # check in a few common install locations
2996	    if test x"${ac_cv_c_tclconfig}" = x ; then
2997		for i in `ls -d ${libdir} 2>/dev/null` \
2998			`ls -d ${exec_prefix}/lib 2>/dev/null` \
2999			`ls -d ${prefix}/lib 2>/dev/null` \
3000			`ls -d /usr/local/lib 2>/dev/null` \
3001			`ls -d /usr/contrib/lib 2>/dev/null` \
3002			`ls -d /usr/pkg/lib 2>/dev/null` \
3003			`ls -d /usr/lib 2>/dev/null` \
3004			`ls -d /usr/lib64 2>/dev/null` \
3005			`ls -d /usr/lib/tcl8.6 2>/dev/null` \
3006			`ls -d /usr/lib/tcl8.5 2>/dev/null` \
3007			`ls -d /usr/local/lib/tcl8.6 2>/dev/null` \
3008			`ls -d /usr/local/lib/tcl8.5 2>/dev/null` \
3009			`ls -d /usr/local/lib/tcl/tcl8.6 2>/dev/null` \
3010			`ls -d /usr/local/lib/tcl/tcl8.5 2>/dev/null` \
3011			; do
3012		    if test -f "$i/tclConfig.sh" ; then
3013			ac_cv_c_tclconfig="`(cd $i; pwd)`"
3014			break
3015		    fi
3016		done
3017	    fi
3018
3019	    # check in a few other private locations
3020	    if test x"${ac_cv_c_tclconfig}" = x ; then
3021		for i in \
3022			${srcdir}/../tcl \
3023			`ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
3024			`ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
3025			`ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
3026		    if test "${TEA_PLATFORM}" = "windows" \
3027			    -a -f "$i/win/tclConfig.sh" ; then
3028			ac_cv_c_tclconfig="`(cd $i/win; pwd)`"
3029			break
3030		    fi
3031		    if test -f "$i/unix/tclConfig.sh" ; then
3032			ac_cv_c_tclconfig="`(cd $i/unix; pwd)`"
3033			break
3034		    fi
3035		done
3036	    fi
3037
3038fi
3039
3040
3041	if test x"${ac_cv_c_tclconfig}" = x ; then
3042	    TCL_BIN_DIR="# no Tcl configs found"
3043	    as_fn_error $? "Can't find Tcl configuration definitions. Use --with-tcl to specify a directory containing tclConfig.sh" "$LINENO" 5
3044	else
3045	    no_tcl=
3046	    TCL_BIN_DIR="${ac_cv_c_tclconfig}"
3047	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
3048printf "%s\n" "found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
3049	fi
3050    fi
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061ac_ext=c
3062ac_cpp='$CPP $CPPFLAGS'
3063ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3064ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3065ac_compiler_gnu=$ac_cv_c_compiler_gnu
3066if test -n "$ac_tool_prefix"; then
3067  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3068set dummy ${ac_tool_prefix}gcc; ac_word=$2
3069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3070printf %s "checking for $ac_word... " >&6; }
3071if test ${ac_cv_prog_CC+y}
3072then :
3073  printf %s "(cached) " >&6
3074else $as_nop
3075  if test -n "$CC"; then
3076  ac_cv_prog_CC="$CC" # Let the user override the test.
3077else
3078as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3079for as_dir in $PATH
3080do
3081  IFS=$as_save_IFS
3082  case $as_dir in #(((
3083    '') as_dir=./ ;;
3084    */) ;;
3085    *) as_dir=$as_dir/ ;;
3086  esac
3087    for ac_exec_ext in '' $ac_executable_extensions; do
3088  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3089    ac_cv_prog_CC="${ac_tool_prefix}gcc"
3090    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3091    break 2
3092  fi
3093done
3094  done
3095IFS=$as_save_IFS
3096
3097fi
3098fi
3099CC=$ac_cv_prog_CC
3100if test -n "$CC"; then
3101  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3102printf "%s\n" "$CC" >&6; }
3103else
3104  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3105printf "%s\n" "no" >&6; }
3106fi
3107
3108
3109fi
3110if test -z "$ac_cv_prog_CC"; then
3111  ac_ct_CC=$CC
3112  # Extract the first word of "gcc", so it can be a program name with args.
3113set dummy gcc; ac_word=$2
3114{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3115printf %s "checking for $ac_word... " >&6; }
3116if test ${ac_cv_prog_ac_ct_CC+y}
3117then :
3118  printf %s "(cached) " >&6
3119else $as_nop
3120  if test -n "$ac_ct_CC"; then
3121  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3122else
3123as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3124for as_dir in $PATH
3125do
3126  IFS=$as_save_IFS
3127  case $as_dir in #(((
3128    '') as_dir=./ ;;
3129    */) ;;
3130    *) as_dir=$as_dir/ ;;
3131  esac
3132    for ac_exec_ext in '' $ac_executable_extensions; do
3133  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3134    ac_cv_prog_ac_ct_CC="gcc"
3135    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3136    break 2
3137  fi
3138done
3139  done
3140IFS=$as_save_IFS
3141
3142fi
3143fi
3144ac_ct_CC=$ac_cv_prog_ac_ct_CC
3145if test -n "$ac_ct_CC"; then
3146  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3147printf "%s\n" "$ac_ct_CC" >&6; }
3148else
3149  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3150printf "%s\n" "no" >&6; }
3151fi
3152
3153  if test "x$ac_ct_CC" = x; then
3154    CC=""
3155  else
3156    case $cross_compiling:$ac_tool_warned in
3157yes:)
3158{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3159printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3160ac_tool_warned=yes ;;
3161esac
3162    CC=$ac_ct_CC
3163  fi
3164else
3165  CC="$ac_cv_prog_CC"
3166fi
3167
3168if test -z "$CC"; then
3169          if test -n "$ac_tool_prefix"; then
3170    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3171set dummy ${ac_tool_prefix}cc; ac_word=$2
3172{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3173printf %s "checking for $ac_word... " >&6; }
3174if test ${ac_cv_prog_CC+y}
3175then :
3176  printf %s "(cached) " >&6
3177else $as_nop
3178  if test -n "$CC"; then
3179  ac_cv_prog_CC="$CC" # Let the user override the test.
3180else
3181as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3182for as_dir in $PATH
3183do
3184  IFS=$as_save_IFS
3185  case $as_dir in #(((
3186    '') as_dir=./ ;;
3187    */) ;;
3188    *) as_dir=$as_dir/ ;;
3189  esac
3190    for ac_exec_ext in '' $ac_executable_extensions; do
3191  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3192    ac_cv_prog_CC="${ac_tool_prefix}cc"
3193    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3194    break 2
3195  fi
3196done
3197  done
3198IFS=$as_save_IFS
3199
3200fi
3201fi
3202CC=$ac_cv_prog_CC
3203if test -n "$CC"; then
3204  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3205printf "%s\n" "$CC" >&6; }
3206else
3207  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3208printf "%s\n" "no" >&6; }
3209fi
3210
3211
3212  fi
3213fi
3214if test -z "$CC"; then
3215  # Extract the first word of "cc", so it can be a program name with args.
3216set dummy cc; ac_word=$2
3217{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3218printf %s "checking for $ac_word... " >&6; }
3219if test ${ac_cv_prog_CC+y}
3220then :
3221  printf %s "(cached) " >&6
3222else $as_nop
3223  if test -n "$CC"; then
3224  ac_cv_prog_CC="$CC" # Let the user override the test.
3225else
3226  ac_prog_rejected=no
3227as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3228for as_dir in $PATH
3229do
3230  IFS=$as_save_IFS
3231  case $as_dir in #(((
3232    '') as_dir=./ ;;
3233    */) ;;
3234    *) as_dir=$as_dir/ ;;
3235  esac
3236    for ac_exec_ext in '' $ac_executable_extensions; do
3237  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3238    if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3239       ac_prog_rejected=yes
3240       continue
3241     fi
3242    ac_cv_prog_CC="cc"
3243    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3244    break 2
3245  fi
3246done
3247  done
3248IFS=$as_save_IFS
3249
3250if test $ac_prog_rejected = yes; then
3251  # We found a bogon in the path, so make sure we never use it.
3252  set dummy $ac_cv_prog_CC
3253  shift
3254  if test $# != 0; then
3255    # We chose a different compiler from the bogus one.
3256    # However, it has the same basename, so the bogon will be chosen
3257    # first if we set CC to just the basename; use the full file name.
3258    shift
3259    ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
3260  fi
3261fi
3262fi
3263fi
3264CC=$ac_cv_prog_CC
3265if test -n "$CC"; then
3266  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3267printf "%s\n" "$CC" >&6; }
3268else
3269  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3270printf "%s\n" "no" >&6; }
3271fi
3272
3273
3274fi
3275if test -z "$CC"; then
3276  if test -n "$ac_tool_prefix"; then
3277  for ac_prog in cl.exe
3278  do
3279    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3280set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3281{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3282printf %s "checking for $ac_word... " >&6; }
3283if test ${ac_cv_prog_CC+y}
3284then :
3285  printf %s "(cached) " >&6
3286else $as_nop
3287  if test -n "$CC"; then
3288  ac_cv_prog_CC="$CC" # Let the user override the test.
3289else
3290as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3291for as_dir in $PATH
3292do
3293  IFS=$as_save_IFS
3294  case $as_dir in #(((
3295    '') as_dir=./ ;;
3296    */) ;;
3297    *) as_dir=$as_dir/ ;;
3298  esac
3299    for ac_exec_ext in '' $ac_executable_extensions; do
3300  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3301    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3302    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3303    break 2
3304  fi
3305done
3306  done
3307IFS=$as_save_IFS
3308
3309fi
3310fi
3311CC=$ac_cv_prog_CC
3312if test -n "$CC"; then
3313  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3314printf "%s\n" "$CC" >&6; }
3315else
3316  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3317printf "%s\n" "no" >&6; }
3318fi
3319
3320
3321    test -n "$CC" && break
3322  done
3323fi
3324if test -z "$CC"; then
3325  ac_ct_CC=$CC
3326  for ac_prog in cl.exe
3327do
3328  # Extract the first word of "$ac_prog", so it can be a program name with args.
3329set dummy $ac_prog; ac_word=$2
3330{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3331printf %s "checking for $ac_word... " >&6; }
3332if test ${ac_cv_prog_ac_ct_CC+y}
3333then :
3334  printf %s "(cached) " >&6
3335else $as_nop
3336  if test -n "$ac_ct_CC"; then
3337  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3338else
3339as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3340for as_dir in $PATH
3341do
3342  IFS=$as_save_IFS
3343  case $as_dir in #(((
3344    '') as_dir=./ ;;
3345    */) ;;
3346    *) as_dir=$as_dir/ ;;
3347  esac
3348    for ac_exec_ext in '' $ac_executable_extensions; do
3349  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3350    ac_cv_prog_ac_ct_CC="$ac_prog"
3351    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3352    break 2
3353  fi
3354done
3355  done
3356IFS=$as_save_IFS
3357
3358fi
3359fi
3360ac_ct_CC=$ac_cv_prog_ac_ct_CC
3361if test -n "$ac_ct_CC"; then
3362  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3363printf "%s\n" "$ac_ct_CC" >&6; }
3364else
3365  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3366printf "%s\n" "no" >&6; }
3367fi
3368
3369
3370  test -n "$ac_ct_CC" && break
3371done
3372
3373  if test "x$ac_ct_CC" = x; then
3374    CC=""
3375  else
3376    case $cross_compiling:$ac_tool_warned in
3377yes:)
3378{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3379printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3380ac_tool_warned=yes ;;
3381esac
3382    CC=$ac_ct_CC
3383  fi
3384fi
3385
3386fi
3387if test -z "$CC"; then
3388  if test -n "$ac_tool_prefix"; then
3389  # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
3390set dummy ${ac_tool_prefix}clang; ac_word=$2
3391{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3392printf %s "checking for $ac_word... " >&6; }
3393if test ${ac_cv_prog_CC+y}
3394then :
3395  printf %s "(cached) " >&6
3396else $as_nop
3397  if test -n "$CC"; then
3398  ac_cv_prog_CC="$CC" # Let the user override the test.
3399else
3400as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3401for as_dir in $PATH
3402do
3403  IFS=$as_save_IFS
3404  case $as_dir in #(((
3405    '') as_dir=./ ;;
3406    */) ;;
3407    *) as_dir=$as_dir/ ;;
3408  esac
3409    for ac_exec_ext in '' $ac_executable_extensions; do
3410  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3411    ac_cv_prog_CC="${ac_tool_prefix}clang"
3412    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3413    break 2
3414  fi
3415done
3416  done
3417IFS=$as_save_IFS
3418
3419fi
3420fi
3421CC=$ac_cv_prog_CC
3422if test -n "$CC"; then
3423  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3424printf "%s\n" "$CC" >&6; }
3425else
3426  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3427printf "%s\n" "no" >&6; }
3428fi
3429
3430
3431fi
3432if test -z "$ac_cv_prog_CC"; then
3433  ac_ct_CC=$CC
3434  # Extract the first word of "clang", so it can be a program name with args.
3435set dummy clang; ac_word=$2
3436{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3437printf %s "checking for $ac_word... " >&6; }
3438if test ${ac_cv_prog_ac_ct_CC+y}
3439then :
3440  printf %s "(cached) " >&6
3441else $as_nop
3442  if test -n "$ac_ct_CC"; then
3443  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3444else
3445as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3446for as_dir in $PATH
3447do
3448  IFS=$as_save_IFS
3449  case $as_dir in #(((
3450    '') as_dir=./ ;;
3451    */) ;;
3452    *) as_dir=$as_dir/ ;;
3453  esac
3454    for ac_exec_ext in '' $ac_executable_extensions; do
3455  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3456    ac_cv_prog_ac_ct_CC="clang"
3457    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3458    break 2
3459  fi
3460done
3461  done
3462IFS=$as_save_IFS
3463
3464fi
3465fi
3466ac_ct_CC=$ac_cv_prog_ac_ct_CC
3467if test -n "$ac_ct_CC"; then
3468  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3469printf "%s\n" "$ac_ct_CC" >&6; }
3470else
3471  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3472printf "%s\n" "no" >&6; }
3473fi
3474
3475  if test "x$ac_ct_CC" = x; then
3476    CC=""
3477  else
3478    case $cross_compiling:$ac_tool_warned in
3479yes:)
3480{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3481printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3482ac_tool_warned=yes ;;
3483esac
3484    CC=$ac_ct_CC
3485  fi
3486else
3487  CC="$ac_cv_prog_CC"
3488fi
3489
3490fi
3491
3492
3493test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3494printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3495as_fn_error $? "no acceptable C compiler found in \$PATH
3496See \`config.log' for more details" "$LINENO" 5; }
3497
3498# Provide some information about the compiler.
3499printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3500set X $ac_compile
3501ac_compiler=$2
3502for ac_option in --version -v -V -qversion -version; do
3503  { { ac_try="$ac_compiler $ac_option >&5"
3504case "(($ac_try" in
3505  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3506  *) ac_try_echo=$ac_try;;
3507esac
3508eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3509printf "%s\n" "$ac_try_echo"; } >&5
3510  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3511  ac_status=$?
3512  if test -s conftest.err; then
3513    sed '10a\
3514... rest of stderr output deleted ...
3515         10q' conftest.err >conftest.er1
3516    cat conftest.er1 >&5
3517  fi
3518  rm -f conftest.er1 conftest.err
3519  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3520  test $ac_status = 0; }
3521done
3522
3523cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3524/* end confdefs.h.  */
3525
3526int
3527main (void)
3528{
3529
3530  ;
3531  return 0;
3532}
3533_ACEOF
3534ac_clean_files_save=$ac_clean_files
3535ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3536# Try to create an executable without -o first, disregard a.out.
3537# It will help us diagnose broken compilers, and finding out an intuition
3538# of exeext.
3539{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3540printf %s "checking whether the C compiler works... " >&6; }
3541ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3542
3543# The possible output files:
3544ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3545
3546ac_rmfiles=
3547for ac_file in $ac_files
3548do
3549  case $ac_file in
3550    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3551    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3552  esac
3553done
3554rm -f $ac_rmfiles
3555
3556if { { ac_try="$ac_link_default"
3557case "(($ac_try" in
3558  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3559  *) ac_try_echo=$ac_try;;
3560esac
3561eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3562printf "%s\n" "$ac_try_echo"; } >&5
3563  (eval "$ac_link_default") 2>&5
3564  ac_status=$?
3565  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3566  test $ac_status = 0; }
3567then :
3568  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3569# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3570# in a Makefile.  We should not override ac_cv_exeext if it was cached,
3571# so that the user can short-circuit this test for compilers unknown to
3572# Autoconf.
3573for ac_file in $ac_files ''
3574do
3575  test -f "$ac_file" || continue
3576  case $ac_file in
3577    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3578	;;
3579    [ab].out )
3580	# We found the default executable, but exeext='' is most
3581	# certainly right.
3582	break;;
3583    *.* )
3584	if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no;
3585	then :; else
3586	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3587	fi
3588	# We set ac_cv_exeext here because the later test for it is not
3589	# safe: cross compilers may not add the suffix if given an `-o'
3590	# argument, so we may need to know it at that point already.
3591	# Even if this section looks crufty: it has the advantage of
3592	# actually working.
3593	break;;
3594    * )
3595	break;;
3596  esac
3597done
3598test "$ac_cv_exeext" = no && ac_cv_exeext=
3599
3600else $as_nop
3601  ac_file=''
3602fi
3603if test -z "$ac_file"
3604then :
3605  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3606printf "%s\n" "no" >&6; }
3607printf "%s\n" "$as_me: failed program was:" >&5
3608sed 's/^/| /' conftest.$ac_ext >&5
3609
3610{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3611printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3612as_fn_error 77 "C compiler cannot create executables
3613See \`config.log' for more details" "$LINENO" 5; }
3614else $as_nop
3615  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3616printf "%s\n" "yes" >&6; }
3617fi
3618{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3619printf %s "checking for C compiler default output file name... " >&6; }
3620{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3621printf "%s\n" "$ac_file" >&6; }
3622ac_exeext=$ac_cv_exeext
3623
3624rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3625ac_clean_files=$ac_clean_files_save
3626{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3627printf %s "checking for suffix of executables... " >&6; }
3628if { { ac_try="$ac_link"
3629case "(($ac_try" in
3630  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3631  *) ac_try_echo=$ac_try;;
3632esac
3633eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3634printf "%s\n" "$ac_try_echo"; } >&5
3635  (eval "$ac_link") 2>&5
3636  ac_status=$?
3637  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3638  test $ac_status = 0; }
3639then :
3640  # If both `conftest.exe' and `conftest' are `present' (well, observable)
3641# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3642# work properly (i.e., refer to `conftest.exe'), while it won't with
3643# `rm'.
3644for ac_file in conftest.exe conftest conftest.*; do
3645  test -f "$ac_file" || continue
3646  case $ac_file in
3647    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3648    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3649	  break;;
3650    * ) break;;
3651  esac
3652done
3653else $as_nop
3654  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3655printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3656as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3657See \`config.log' for more details" "$LINENO" 5; }
3658fi
3659rm -f conftest conftest$ac_cv_exeext
3660{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3661printf "%s\n" "$ac_cv_exeext" >&6; }
3662
3663rm -f conftest.$ac_ext
3664EXEEXT=$ac_cv_exeext
3665ac_exeext=$EXEEXT
3666cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3667/* end confdefs.h.  */
3668#include <stdio.h>
3669int
3670main (void)
3671{
3672FILE *f = fopen ("conftest.out", "w");
3673 return ferror (f) || fclose (f) != 0;
3674
3675  ;
3676  return 0;
3677}
3678_ACEOF
3679ac_clean_files="$ac_clean_files conftest.out"
3680# Check that the compiler produces executables we can run.  If not, either
3681# the compiler is broken, or we cross compile.
3682{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3683printf %s "checking whether we are cross compiling... " >&6; }
3684if test "$cross_compiling" != yes; then
3685  { { ac_try="$ac_link"
3686case "(($ac_try" in
3687  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3688  *) ac_try_echo=$ac_try;;
3689esac
3690eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3691printf "%s\n" "$ac_try_echo"; } >&5
3692  (eval "$ac_link") 2>&5
3693  ac_status=$?
3694  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3695  test $ac_status = 0; }
3696  if { ac_try='./conftest$ac_cv_exeext'
3697  { { case "(($ac_try" in
3698  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3699  *) ac_try_echo=$ac_try;;
3700esac
3701eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3702printf "%s\n" "$ac_try_echo"; } >&5
3703  (eval "$ac_try") 2>&5
3704  ac_status=$?
3705  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3706  test $ac_status = 0; }; }; then
3707    cross_compiling=no
3708  else
3709    if test "$cross_compiling" = maybe; then
3710	cross_compiling=yes
3711    else
3712	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3713printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3714as_fn_error 77 "cannot run C compiled programs.
3715If you meant to cross compile, use \`--host'.
3716See \`config.log' for more details" "$LINENO" 5; }
3717    fi
3718  fi
3719fi
3720{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3721printf "%s\n" "$cross_compiling" >&6; }
3722
3723rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3724ac_clean_files=$ac_clean_files_save
3725{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3726printf %s "checking for suffix of object files... " >&6; }
3727if test ${ac_cv_objext+y}
3728then :
3729  printf %s "(cached) " >&6
3730else $as_nop
3731  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3732/* end confdefs.h.  */
3733
3734int
3735main (void)
3736{
3737
3738  ;
3739  return 0;
3740}
3741_ACEOF
3742rm -f conftest.o conftest.obj
3743if { { ac_try="$ac_compile"
3744case "(($ac_try" in
3745  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3746  *) ac_try_echo=$ac_try;;
3747esac
3748eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3749printf "%s\n" "$ac_try_echo"; } >&5
3750  (eval "$ac_compile") 2>&5
3751  ac_status=$?
3752  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3753  test $ac_status = 0; }
3754then :
3755  for ac_file in conftest.o conftest.obj conftest.*; do
3756  test -f "$ac_file" || continue;
3757  case $ac_file in
3758    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3759    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3760       break;;
3761  esac
3762done
3763else $as_nop
3764  printf "%s\n" "$as_me: failed program was:" >&5
3765sed 's/^/| /' conftest.$ac_ext >&5
3766
3767{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3768printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3769as_fn_error $? "cannot compute suffix of object files: cannot compile
3770See \`config.log' for more details" "$LINENO" 5; }
3771fi
3772rm -f conftest.$ac_cv_objext conftest.$ac_ext
3773fi
3774{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3775printf "%s\n" "$ac_cv_objext" >&6; }
3776OBJEXT=$ac_cv_objext
3777ac_objext=$OBJEXT
3778{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
3779printf %s "checking whether the compiler supports GNU C... " >&6; }
3780if test ${ac_cv_c_compiler_gnu+y}
3781then :
3782  printf %s "(cached) " >&6
3783else $as_nop
3784  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3785/* end confdefs.h.  */
3786
3787int
3788main (void)
3789{
3790#ifndef __GNUC__
3791       choke me
3792#endif
3793
3794  ;
3795  return 0;
3796}
3797_ACEOF
3798if ac_fn_c_try_compile "$LINENO"
3799then :
3800  ac_compiler_gnu=yes
3801else $as_nop
3802  ac_compiler_gnu=no
3803fi
3804rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
3805ac_cv_c_compiler_gnu=$ac_compiler_gnu
3806
3807fi
3808{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3809printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
3810ac_compiler_gnu=$ac_cv_c_compiler_gnu
3811
3812if test $ac_compiler_gnu = yes; then
3813  GCC=yes
3814else
3815  GCC=
3816fi
3817ac_test_CFLAGS=${CFLAGS+y}
3818ac_save_CFLAGS=$CFLAGS
3819{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3820printf %s "checking whether $CC accepts -g... " >&6; }
3821if test ${ac_cv_prog_cc_g+y}
3822then :
3823  printf %s "(cached) " >&6
3824else $as_nop
3825  ac_save_c_werror_flag=$ac_c_werror_flag
3826   ac_c_werror_flag=yes
3827   ac_cv_prog_cc_g=no
3828   CFLAGS="-g"
3829   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3830/* end confdefs.h.  */
3831
3832int
3833main (void)
3834{
3835
3836  ;
3837  return 0;
3838}
3839_ACEOF
3840if ac_fn_c_try_compile "$LINENO"
3841then :
3842  ac_cv_prog_cc_g=yes
3843else $as_nop
3844  CFLAGS=""
3845      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3846/* end confdefs.h.  */
3847
3848int
3849main (void)
3850{
3851
3852  ;
3853  return 0;
3854}
3855_ACEOF
3856if ac_fn_c_try_compile "$LINENO"
3857then :
3858
3859else $as_nop
3860  ac_c_werror_flag=$ac_save_c_werror_flag
3861	 CFLAGS="-g"
3862	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3863/* end confdefs.h.  */
3864
3865int
3866main (void)
3867{
3868
3869  ;
3870  return 0;
3871}
3872_ACEOF
3873if ac_fn_c_try_compile "$LINENO"
3874then :
3875  ac_cv_prog_cc_g=yes
3876fi
3877rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
3878fi
3879rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
3880fi
3881rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
3882   ac_c_werror_flag=$ac_save_c_werror_flag
3883fi
3884{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3885printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
3886if test $ac_test_CFLAGS; then
3887  CFLAGS=$ac_save_CFLAGS
3888elif test $ac_cv_prog_cc_g = yes; then
3889  if test "$GCC" = yes; then
3890    CFLAGS="-g -O2"
3891  else
3892    CFLAGS="-g"
3893  fi
3894else
3895  if test "$GCC" = yes; then
3896    CFLAGS="-O2"
3897  else
3898    CFLAGS=
3899  fi
3900fi
3901{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
3902printf %s "checking for $CC option to enable C11 features... " >&6; }
3903if test ${ac_cv_prog_cc_c11+y}
3904then :
3905  printf %s "(cached) " >&6
3906else $as_nop
3907  ac_cv_prog_cc_c11=no
3908ac_save_CC=$CC
3909cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3910/* end confdefs.h.  */
3911$ac_c_conftest_c11_program
3912_ACEOF
3913for ac_arg in '' -std=gnu11
3914do
3915  CC="$ac_save_CC $ac_arg"
3916  if ac_fn_c_try_compile "$LINENO"
3917then :
3918  ac_cv_prog_cc_c11=$ac_arg
3919fi
3920rm -f core conftest.err conftest.$ac_objext conftest.beam
3921  test "x$ac_cv_prog_cc_c11" != "xno" && break
3922done
3923rm -f conftest.$ac_ext
3924CC=$ac_save_CC
3925
3926fi
3927# AC_CACHE_VAL
3928ac_prog_cc_stdc_options=
3929case "x$ac_cv_prog_cc_c11" in #(
3930  x) :
3931    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3932printf "%s\n" "none needed" >&6; } ;; #(
3933  xno) :
3934    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3935printf "%s\n" "unsupported" >&6; } ;; #(
3936  *) :
3937    ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c11"
3938    CC="$CC$ac_prog_cc_stdc_options"
3939    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
3940printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } ;;
3941esac
3942if test "x$ac_cv_prog_cc_c11" != xno
3943then :
3944  ac_prog_cc_stdc=c11
3945		 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
3946else $as_nop
3947  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
3948printf %s "checking for $CC option to enable C99 features... " >&6; }
3949if test ${ac_cv_prog_cc_c99+y}
3950then :
3951  printf %s "(cached) " >&6
3952else $as_nop
3953  ac_cv_prog_cc_c99=no
3954ac_save_CC=$CC
3955cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3956/* end confdefs.h.  */
3957$ac_c_conftest_c89_program
3958_ACEOF
3959for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc1x -qlanglvl=extc99
3960do
3961  CC="$ac_save_CC $ac_arg"
3962  if ac_fn_c_try_compile "$LINENO"
3963then :
3964  ac_cv_prog_cc_c99=$ac_arg
3965fi
3966rm -f core conftest.err conftest.$ac_objext conftest.beam
3967  test "x$ac_cv_prog_cc_c99" != "xno" && break
3968done
3969rm -f conftest.$ac_ext
3970CC=$ac_save_CC
3971
3972fi
3973# AC_CACHE_VAL
3974ac_prog_cc_stdc_options=
3975case "x$ac_cv_prog_cc_c99" in #(
3976  x) :
3977    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3978printf "%s\n" "none needed" >&6; } ;; #(
3979  xno) :
3980    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3981printf "%s\n" "unsupported" >&6; } ;; #(
3982  *) :
3983    ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c99"
3984    CC="$CC$ac_prog_cc_stdc_options"
3985    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
3986printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } ;;
3987esac
3988if test "x$ac_cv_prog_cc_c99" != xno
3989then :
3990  ac_prog_cc_stdc=c99
3991		    ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
3992else $as_nop
3993  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
3994printf %s "checking for $CC option to enable C89 features... " >&6; }
3995if test ${ac_cv_prog_cc_c89+y}
3996then :
3997  printf %s "(cached) " >&6
3998else $as_nop
3999  ac_cv_prog_cc_c89=no
4000ac_save_CC=$CC
4001cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4002/* end confdefs.h.  */
4003$ac_c_conftest_c89_program
4004_ACEOF
4005for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4006	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4007do
4008  CC="$ac_save_CC $ac_arg"
4009  if ac_fn_c_try_compile "$LINENO"
4010then :
4011  ac_cv_prog_cc_c89=$ac_arg
4012fi
4013rm -f core conftest.err conftest.$ac_objext conftest.beam
4014  test "x$ac_cv_prog_cc_c89" != "xno" && break
4015done
4016rm -f conftest.$ac_ext
4017CC=$ac_save_CC
4018
4019fi
4020# AC_CACHE_VAL
4021ac_prog_cc_stdc_options=
4022case "x$ac_cv_prog_cc_c89" in #(
4023  x) :
4024    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4025printf "%s\n" "none needed" >&6; } ;; #(
4026  xno) :
4027    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4028printf "%s\n" "unsupported" >&6; } ;; #(
4029  *) :
4030    ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c89"
4031    CC="$CC$ac_prog_cc_stdc_options"
4032    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4033printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } ;;
4034esac
4035if test "x$ac_cv_prog_cc_c89" != xno
4036then :
4037  ac_prog_cc_stdc=c89
4038		       ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
4039else $as_nop
4040  ac_prog_cc_stdc=no
4041		       ac_cv_prog_cc_stdc=no
4042fi
4043
4044fi
4045
4046fi
4047
4048ac_ext=c
4049ac_cpp='$CPP $CPPFLAGS'
4050ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4051ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4052ac_compiler_gnu=$ac_cv_c_compiler_gnu
4053
4054
4055
4056    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
4057printf %s "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... " >&6; }
4058
4059    if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
4060        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: loading" >&5
4061printf "%s\n" "loading" >&6; }
4062	. "${TCL_BIN_DIR}/tclConfig.sh"
4063    else
4064        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
4065printf "%s\n" "could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
4066    fi
4067
4068    # If the TCL_BIN_DIR is the build directory (not the install directory),
4069    # then set the common variable name to the value of the build variables.
4070    # For example, the variable TCL_LIB_SPEC will be set to the value
4071    # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
4072    # instead of TCL_BUILD_LIB_SPEC since it will work with both an
4073    # installed and uninstalled version of Tcl.
4074    if test -f "${TCL_BIN_DIR}/Makefile" ; then
4075        TCL_LIB_SPEC="${TCL_BUILD_LIB_SPEC}"
4076        TCL_STUB_LIB_SPEC="${TCL_BUILD_STUB_LIB_SPEC}"
4077        TCL_STUB_LIB_PATH="${TCL_BUILD_STUB_LIB_PATH}"
4078    elif test "`uname -s`" = "Darwin"; then
4079	# If Tcl was built as a framework, attempt to use the libraries
4080	# from the framework at the given location so that linking works
4081	# against Tcl.framework installed in an arbitrary location.
4082	case ${TCL_DEFS} in
4083	    *TCL_FRAMEWORK*)
4084		if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
4085		    for i in "`cd "${TCL_BIN_DIR}"; pwd`" \
4086			     "`cd "${TCL_BIN_DIR}"/../..; pwd`"; do
4087			if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
4088			    TCL_LIB_SPEC="-F`dirname "$i" | sed -e 's/ /\\\\ /g'` -framework ${TCL_LIB_FILE}"
4089			    break
4090			fi
4091		    done
4092		fi
4093		if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
4094		    TCL_STUB_LIB_SPEC="-L`echo "${TCL_BIN_DIR}"  | sed -e 's/ /\\\\ /g'` ${TCL_STUB_LIB_FLAG}"
4095		    TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
4096		fi
4097		;;
4098	esac
4099    fi
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking platform" >&5
4115printf %s "checking platform... " >&6; }
4116    hold_cc=$CC; CC="$TCL_CC"
4117    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4118/* end confdefs.h.  */
4119
4120int
4121main (void)
4122{
4123
4124	    #ifdef _WIN32
4125		#error win32
4126	    #endif
4127
4128  ;
4129  return 0;
4130}
4131_ACEOF
4132if ac_fn_c_try_compile "$LINENO"
4133then :
4134
4135	    # first test we've already retrieved platform (cross-compile), fallback to unix otherwise:
4136	    TEA_PLATFORM="${TEA_PLATFORM-unix}"
4137	    CYGPATH=echo
4138
4139else $as_nop
4140
4141	    TEA_PLATFORM="windows"
4142	    # Extract the first word of "cygpath", so it can be a program name with args.
4143set dummy cygpath; ac_word=$2
4144{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4145printf %s "checking for $ac_word... " >&6; }
4146if test ${ac_cv_prog_CYGPATH+y}
4147then :
4148  printf %s "(cached) " >&6
4149else $as_nop
4150  if test -n "$CYGPATH"; then
4151  ac_cv_prog_CYGPATH="$CYGPATH" # Let the user override the test.
4152else
4153as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4154for as_dir in $PATH
4155do
4156  IFS=$as_save_IFS
4157  case $as_dir in #(((
4158    '') as_dir=./ ;;
4159    */) ;;
4160    *) as_dir=$as_dir/ ;;
4161  esac
4162    for ac_exec_ext in '' $ac_executable_extensions; do
4163  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4164    ac_cv_prog_CYGPATH="cygpath -m"
4165    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4166    break 2
4167  fi
4168done
4169  done
4170IFS=$as_save_IFS
4171
4172  test -z "$ac_cv_prog_CYGPATH" && ac_cv_prog_CYGPATH="echo"
4173fi
4174fi
4175CYGPATH=$ac_cv_prog_CYGPATH
4176if test -n "$CYGPATH"; then
4177  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
4178printf "%s\n" "$CYGPATH" >&6; }
4179else
4180  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4181printf "%s\n" "no" >&6; }
4182fi
4183
4184
4185
4186fi
4187rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
4188    CC=$hold_cc
4189    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $TEA_PLATFORM" >&5
4190printf "%s\n" "$TEA_PLATFORM" >&6; }
4191
4192    # The BUILD_$pkg is to define the correct extern storage class
4193    # handling when making this package
4194
4195printf "%s\n" "#define BUILD_${PACKAGE_NAME} /**/" >>confdefs.h
4196
4197    # Do this here as we have fully defined TEA_PLATFORM now
4198    if test "${TEA_PLATFORM}" = "windows" ; then
4199	EXEEXT=".exe"
4200	CLEANFILES="$CLEANFILES *.lib *.dll *.pdb *.exp"
4201    fi
4202
4203    # TEA specific:
4204
4205
4206
4207
4208
4209
4210
4211
4212#--------------------------------------------------------------------
4213# Load the tkConfig.sh file if necessary (Tk extension)
4214#--------------------------------------------------------------------
4215
4216#TEA_PATH_TKCONFIG
4217#TEA_LOAD_TKCONFIG
4218
4219#--------------------------------------------------------------------
4220# Load the tclooConfig.sh file on Tcl versions where oo is an
4221# extension.
4222#--------------------------------------------------------------------
4223
4224if test "${TCL_MAJOR_VERSION}" -lt 8 ; then
4225    as_fn_error $? "${PACKAGE_NAME} ${PACKAGE_VERSION} requires Tcl 8.6 or newer.
4226Found configuration for Tcl ${TCL_VERSION}." "$LINENO" 5
4227fi
4228if test "${TCL_MAJOR_VERSION}" -eq 8 ; then
4229   if test "${TCL_MINOR_VERSION}" -lt 6 ; then
4230      as_fn_error $? "${PACKAGE_NAME} ${PACKAGE_VERSION} requires Tcl 8.6 or newer.
4231Found configuration for Tcl ${TCL_VERSION}." "$LINENO" 5
4232   fi
4233   TCLOO_CFLAGS=''
4234fi
4235TCL_VERSION_REQ=8.6;
4236
4237
4238    #
4239    # Ok, lets find the tdbc configuration
4240    # First, look for one uninstalled.
4241    # the alternative search directory is invoked by --with-tdbc
4242    #
4243
4244    if test x"${no_tdbc}" = x ; then
4245	# we reset no_tdbc in case something fails here
4246	no_tdbc=true
4247
4248# Check whether --with-tdbc was given.
4249if test ${with_tdbc+y}
4250then :
4251  withval=$with_tdbc; with_tdbcconfig=${withval}
4252fi
4253
4254	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tdbc configuration" >&5
4255printf %s "checking for tdbc configuration... " >&6; }
4256	if test ${ac_cv_c_tdbcconfig+y}
4257then :
4258  printf %s "(cached) " >&6
4259else $as_nop
4260
4261
4262	    # First check to see if --with-tdbc was specified.
4263	    if test x"${with_tdbcconfig}" != x ; then
4264		case ${with_tdbcconfig} in
4265		    */tdbcConfig.sh )
4266			if test -f ${with_tdbcconfig}; then
4267			    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: --with-tdbc argument should refer to directory containing tdbcConfig.sh, not to tdbcConfig.sh itself" >&5
4268printf "%s\n" "$as_me: WARNING: --with-tdbc argument should refer to directory containing tdbcConfig.sh, not to tdbcConfig.sh itself" >&2;}
4269			    with_tdbcconfig=`echo ${with_tdbcconfig} | sed 's!/tdbcConfig\.sh$!!'`
4270			fi;;
4271		esac
4272		if test -f "${with_tdbcconfig}/tdbcConfig.sh" ; then
4273		    ac_cv_c_tdbcconfig=`(cd ${with_tdbcconfig}; pwd)`
4274		else
4275		    as_fn_error $? "${with_tdbcconfig} directory doesn't contain tdbcConfig.sh" "$LINENO" 5
4276		fi
4277	    fi
4278
4279	    # then check for a private tdbc installation
4280	    if test x"${ac_cv_c_tdbcconfig}" = x ; then
4281		for i in \
4282			../tdbc \
4283			`ls -dr ../tdbc*[0-9].[0-9]*.[0-9]* 2>/dev/null` \
4284			`ls -dr ../tdbc*[0-9].[0-9][0-9] 2>/dev/null` \
4285			`ls -dr ../tdbc*[0-9].[0-9] 2>/dev/null` \
4286			`ls -dr ../tdbc*[0-9].[0-9]* 2>/dev/null` \
4287			../../tdbc \
4288			`ls -dr ../../tdbc*[0-9].[0-9]*.[0-9]* 2>/dev/null` \
4289			`ls -dr ../../tdbc*[0-9].[0-9][0-9] 2>/dev/null` \
4290			`ls -dr ../../tdbc*[0-9].[0-9] 2>/dev/null` \
4291			`ls -dr ../../tdbc*[0-9].[0-9]* 2>/dev/null` \
4292			../../../tdbc \
4293			`ls -dr ../../../tdbc*[0-9].[0-9]*.[0-9]* 2>/dev/null` \
4294			`ls -dr ../../../tdbc*[0-9].[0-9][0-9] 2>/dev/null` \
4295			`ls -dr ../../../tdbc*[0-9].[0-9] 2>/dev/null` \
4296			`ls -dr ../../../tdbc*[0-9].[0-9]* 2>/dev/null` \
4297			${srcdir}/../tdbc \
4298			`ls -dr ${srcdir}/../tdbc*[0-9].[0-9]*.[0-9]* 2>/dev/null` \
4299			`ls -dr ${srcdir}/../tdbc*[0-9].[0-9][0-9] 2>/dev/null` \
4300			`ls -dr ${srcdir}/../tdbc*[0-9].[0-9] 2>/dev/null` \
4301			`ls -dr ${srcdir}/../tdbc*[0-9].[0-9]* 2>/dev/null` \
4302			; do
4303		    if test -f "$i/tdbcConfig.sh" ; then
4304			ac_cv_c_tdbcconfig=`(cd $i; pwd)`
4305			break
4306		    fi
4307		    if test -f "$i/unix/tdbcConfig.sh" ; then
4308			ac_cv_c_tdbcconfig=`(cd $i/unix; pwd)`
4309			break
4310		    fi
4311		done
4312	    fi
4313
4314	    # check in a few common install locations
4315	    if test x"${ac_cv_c_tdbcconfig}" = x ; then
4316		for i in `ls -d ${libdir} 2>/dev/null` \
4317			`ls -d ${exec_prefix}/lib 2>/dev/null` \
4318			`ls -d ${prefix}/lib 2>/dev/null` \
4319			`ls -d /usr/local/lib 2>/dev/null` \
4320			`ls -d /usr/contrib/lib 2>/dev/null` \
4321			`ls -d /usr/pkg/lib 2>/dev/null` \
4322			`ls -d /usr/lib 2>/dev/null` \
4323			`ls -d /usr/lib64 2>/dev/null` \
4324			; do
4325		    if test -f "$i/tdbcConfig.sh" ; then
4326			ac_cv_c_tdbcconfig=`(cd $i; pwd)`
4327			break
4328		    fi
4329		done
4330	    fi
4331
4332fi
4333
4334
4335	if test x"${ac_cv_c_tdbcconfig}" = x ; then
4336	    tdbc_BIN_DIR="# no tdbc configs found"
4337	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find tdbc configuration definitions" >&5
4338printf "%s\n" "$as_me: WARNING: Cannot find tdbc configuration definitions" >&2;}
4339	    exit 0
4340	else
4341	    no_tdbc=
4342	    tdbc_BIN_DIR=${ac_cv_c_tdbcconfig}
4343	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: found $tdbc_BIN_DIR/tdbcConfig.sh" >&5
4344printf "%s\n" "found $tdbc_BIN_DIR/tdbcConfig.sh" >&6; }
4345	fi
4346    fi
4347
4348
4349    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for existence of ${tdbc_BIN_DIR}/tdbcConfig.sh" >&5
4350printf %s "checking for existence of ${tdbc_BIN_DIR}/tdbcConfig.sh... " >&6; }
4351
4352    if test -f "${tdbc_BIN_DIR}/tdbcConfig.sh" ; then
4353        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: loading" >&5
4354printf "%s\n" "loading" >&6; }
4355	. "${tdbc_BIN_DIR}/tdbcConfig.sh"
4356    else
4357        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: file not found" >&5
4358printf "%s\n" "file not found" >&6; }
4359    fi
4360
4361    #
4362    # If the tdbc_BIN_DIR is the build directory (not the install directory),
4363    # then set the common variable name to the value of the build variables.
4364    # For example, the variable tdbc_LIB_SPEC will be set to the value
4365    # of tdbc_BUILD_LIB_SPEC. An extension should make use of tdbc_LIB_SPEC
4366    # instead of tdbc_BUILD_LIB_SPEC since it will work with both an
4367    # installed and uninstalled version of Tcl.
4368    #
4369
4370    if test -f "${tdbc_BIN_DIR}/Makefile" ; then
4371	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Found Makefile - using build library specs for tdbc" >&5
4372printf "%s\n" "$as_me: WARNING: Found Makefile - using build library specs for tdbc" >&2;}
4373        tdbc_LIB_SPEC=${tdbc_BUILD_LIB_SPEC}
4374        tdbc_STUB_LIB_SPEC=${tdbc_BUILD_STUB_LIB_SPEC}
4375        tdbc_STUB_LIB_PATH=${tdbc_BUILD_STUB_LIB_PATH}
4376        tdbc_INCLUDE_SPEC=${tdbc_BUILD_INCLUDE_SPEC}
4377        tdbc_LIBRARY_PATH=${tdbc_LIBRARY_PATH}
4378    fi
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391    # Allow the caller to prevent this auto-check by specifying any 2nd arg
4392    if test "x" = x
4393then :
4394
4395	# Check both upper and lower-case variants
4396	# If a dev wanted non-stubs libs, this function could take an option
4397	# to not use _STUB in the paths below
4398	if test "x${tdbc_STUB_LIB_SPEC}" = x
4399then :
4400
4401    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking For TDBC_STUB library for LIBS" >&5
4402printf %s "checking For TDBC_STUB library for LIBS... " >&6; }
4403    # This simplifies the use of stub libraries by automatically adding
4404    # the stub lib to your path.  Normally this would add to SHLIB_LD_LIBS,
4405    # but this is called before CONFIG_CFLAGS.  More importantly, this adds
4406    # to PKG_LIBS, which becomes LIBS, and that is only used by SHLIB_LD.
4407    if test "x${TDBC_STUB_LIB_SPEC}" != "x" ; then
4408	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes" ; then
4409
4410    vars="\"`${CYGPATH} ${TDBC_STUB_LIB_PATH}`\""
4411    for i in $vars; do
4412	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
4413	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
4414	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.[lL][iI][bB]$/-l\1/'`
4415	fi
4416	PKG_LIBS="$PKG_LIBS $i"
4417    done
4418
4419
4420	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: using TDBC_STUB_LIB_PATH ${TDBC_STUB_LIB_PATH}" >&5
4421printf "%s\n" "using TDBC_STUB_LIB_PATH ${TDBC_STUB_LIB_PATH}" >&6; }
4422	else
4423
4424    vars="${TDBC_STUB_LIB_SPEC}"
4425    for i in $vars; do
4426	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
4427	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
4428	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.[lL][iI][bB]$/-l\1/'`
4429	fi
4430	PKG_LIBS="$PKG_LIBS $i"
4431    done
4432
4433
4434	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: using TDBC_STUB_LIB_SPEC ${TDBC_STUB_LIB_SPEC}" >&5
4435printf "%s\n" "using TDBC_STUB_LIB_SPEC ${TDBC_STUB_LIB_SPEC}" >&6; }
4436	fi
4437    else
4438	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: file not found" >&5
4439printf "%s\n" "file not found" >&6; }
4440    fi
4441
4442else $as_nop
4443
4444    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking For tdbc_STUB library for LIBS" >&5
4445printf %s "checking For tdbc_STUB library for LIBS... " >&6; }
4446    # This simplifies the use of stub libraries by automatically adding
4447    # the stub lib to your path.  Normally this would add to SHLIB_LD_LIBS,
4448    # but this is called before CONFIG_CFLAGS.  More importantly, this adds
4449    # to PKG_LIBS, which becomes LIBS, and that is only used by SHLIB_LD.
4450    if test "x${tdbc_STUB_LIB_SPEC}" != "x" ; then
4451	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes" ; then
4452
4453    vars="\"`${CYGPATH} ${tdbc_STUB_LIB_PATH}`\""
4454    for i in $vars; do
4455	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
4456	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
4457	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.[lL][iI][bB]$/-l\1/'`
4458	fi
4459	PKG_LIBS="$PKG_LIBS $i"
4460    done
4461
4462
4463	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: using tdbc_STUB_LIB_PATH ${tdbc_STUB_LIB_PATH}" >&5
4464printf "%s\n" "using tdbc_STUB_LIB_PATH ${tdbc_STUB_LIB_PATH}" >&6; }
4465	else
4466
4467    vars="${tdbc_STUB_LIB_SPEC}"
4468    for i in $vars; do
4469	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
4470	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
4471	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.[lL][iI][bB]$/-l\1/'`
4472	fi
4473	PKG_LIBS="$PKG_LIBS $i"
4474    done
4475
4476
4477	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: using tdbc_STUB_LIB_SPEC ${tdbc_STUB_LIB_SPEC}" >&5
4478printf "%s\n" "using tdbc_STUB_LIB_SPEC ${tdbc_STUB_LIB_SPEC}" >&6; }
4479	fi
4480    else
4481	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: file not found" >&5
4482printf "%s\n" "file not found" >&6; }
4483    fi
4484
4485fi
4486
4487fi
4488
4489# The next bit probably ought to be in TEA_LOAD_CONFIG
4490{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Looking for \"${tdbc_BIN_DIR}/Makefile\"" >&5
4491printf "%s\n" "$as_me: WARNING: Looking for \"${tdbc_BIN_DIR}/Makefile\"" >&2;}
4492if test -f "${tdbc_BIN_DIR}/Makefile" ; then
4493    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Found Makefile - using build include spec and lib specs for tdbc" >&5
4494printf "%s\n" "$as_me: WARNING: Found Makefile - using build include spec and lib specs for tdbc" >&2;}
4495    tdbc_INCLUDE_SPEC=${tdbc_BUILD_INCLUDE_SPEC}
4496    tdbc_LIBRARY_PATH=${tdbc_BUILD_LIBRARY_PATH}
4497fi
4498
4499
4500
4501
4502
4503
4504#-----------------------------------------------------------------------
4505# Handle the --prefix=... option by defaulting to what Tcl gave.
4506# Must be called after TEA_LOAD_TCLCONFIG and before TEA_SETUP_COMPILER.
4507#-----------------------------------------------------------------------
4508
4509
4510    if test "${prefix}" = "NONE"; then
4511	prefix_default=yes
4512	if test x"${TCL_PREFIX}" != x; then
4513	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: --prefix defaulting to TCL_PREFIX ${TCL_PREFIX}" >&5
4514printf "%s\n" "$as_me: --prefix defaulting to TCL_PREFIX ${TCL_PREFIX}" >&6;}
4515	    prefix=${TCL_PREFIX}
4516	else
4517	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: --prefix defaulting to /usr/local" >&5
4518printf "%s\n" "$as_me: --prefix defaulting to /usr/local" >&6;}
4519	    prefix=/usr/local
4520	fi
4521    fi
4522    if test "${exec_prefix}" = "NONE" -a x"${prefix_default}" = x"yes" \
4523	-o x"${exec_prefix_default}" = x"yes" ; then
4524	if test x"${TCL_EXEC_PREFIX}" != x; then
4525	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: --exec-prefix defaulting to TCL_EXEC_PREFIX ${TCL_EXEC_PREFIX}" >&5
4526printf "%s\n" "$as_me: --exec-prefix defaulting to TCL_EXEC_PREFIX ${TCL_EXEC_PREFIX}" >&6;}
4527	    exec_prefix=${TCL_EXEC_PREFIX}
4528	else
4529	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: --exec-prefix defaulting to ${prefix}" >&5
4530printf "%s\n" "$as_me: --exec-prefix defaulting to ${prefix}" >&6;}
4531	    exec_prefix=$prefix
4532	fi
4533    fi
4534
4535
4536#-----------------------------------------------------------------------
4537# Standard compiler checks.
4538# This sets up CC by using the CC env var, or looks for gcc otherwise.
4539# This also calls AC_PROG_CC and a few others to create the basic setup
4540# necessary to compile executables.
4541#-----------------------------------------------------------------------
4542
4543
4544    # Don't put any macros that use the compiler (e.g. AC_TRY_COMPILE)
4545    # in this macro, they need to go into TEA_SETUP_COMPILER instead.
4546
4547    ac_ext=c
4548ac_cpp='$CPP $CPPFLAGS'
4549ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4550ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4551ac_compiler_gnu=$ac_cv_c_compiler_gnu
4552if test -n "$ac_tool_prefix"; then
4553  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4554set dummy ${ac_tool_prefix}gcc; ac_word=$2
4555{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4556printf %s "checking for $ac_word... " >&6; }
4557if test ${ac_cv_prog_CC+y}
4558then :
4559  printf %s "(cached) " >&6
4560else $as_nop
4561  if test -n "$CC"; then
4562  ac_cv_prog_CC="$CC" # Let the user override the test.
4563else
4564as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4565for as_dir in $PATH
4566do
4567  IFS=$as_save_IFS
4568  case $as_dir in #(((
4569    '') as_dir=./ ;;
4570    */) ;;
4571    *) as_dir=$as_dir/ ;;
4572  esac
4573    for ac_exec_ext in '' $ac_executable_extensions; do
4574  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4575    ac_cv_prog_CC="${ac_tool_prefix}gcc"
4576    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4577    break 2
4578  fi
4579done
4580  done
4581IFS=$as_save_IFS
4582
4583fi
4584fi
4585CC=$ac_cv_prog_CC
4586if test -n "$CC"; then
4587  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4588printf "%s\n" "$CC" >&6; }
4589else
4590  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4591printf "%s\n" "no" >&6; }
4592fi
4593
4594
4595fi
4596if test -z "$ac_cv_prog_CC"; then
4597  ac_ct_CC=$CC
4598  # Extract the first word of "gcc", so it can be a program name with args.
4599set dummy gcc; ac_word=$2
4600{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4601printf %s "checking for $ac_word... " >&6; }
4602if test ${ac_cv_prog_ac_ct_CC+y}
4603then :
4604  printf %s "(cached) " >&6
4605else $as_nop
4606  if test -n "$ac_ct_CC"; then
4607  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4608else
4609as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4610for as_dir in $PATH
4611do
4612  IFS=$as_save_IFS
4613  case $as_dir in #(((
4614    '') as_dir=./ ;;
4615    */) ;;
4616    *) as_dir=$as_dir/ ;;
4617  esac
4618    for ac_exec_ext in '' $ac_executable_extensions; do
4619  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4620    ac_cv_prog_ac_ct_CC="gcc"
4621    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4622    break 2
4623  fi
4624done
4625  done
4626IFS=$as_save_IFS
4627
4628fi
4629fi
4630ac_ct_CC=$ac_cv_prog_ac_ct_CC
4631if test -n "$ac_ct_CC"; then
4632  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4633printf "%s\n" "$ac_ct_CC" >&6; }
4634else
4635  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4636printf "%s\n" "no" >&6; }
4637fi
4638
4639  if test "x$ac_ct_CC" = x; then
4640    CC=""
4641  else
4642    case $cross_compiling:$ac_tool_warned in
4643yes:)
4644{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4645printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4646ac_tool_warned=yes ;;
4647esac
4648    CC=$ac_ct_CC
4649  fi
4650else
4651  CC="$ac_cv_prog_CC"
4652fi
4653
4654if test -z "$CC"; then
4655          if test -n "$ac_tool_prefix"; then
4656    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4657set dummy ${ac_tool_prefix}cc; ac_word=$2
4658{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4659printf %s "checking for $ac_word... " >&6; }
4660if test ${ac_cv_prog_CC+y}
4661then :
4662  printf %s "(cached) " >&6
4663else $as_nop
4664  if test -n "$CC"; then
4665  ac_cv_prog_CC="$CC" # Let the user override the test.
4666else
4667as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4668for as_dir in $PATH
4669do
4670  IFS=$as_save_IFS
4671  case $as_dir in #(((
4672    '') as_dir=./ ;;
4673    */) ;;
4674    *) as_dir=$as_dir/ ;;
4675  esac
4676    for ac_exec_ext in '' $ac_executable_extensions; do
4677  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4678    ac_cv_prog_CC="${ac_tool_prefix}cc"
4679    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4680    break 2
4681  fi
4682done
4683  done
4684IFS=$as_save_IFS
4685
4686fi
4687fi
4688CC=$ac_cv_prog_CC
4689if test -n "$CC"; then
4690  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4691printf "%s\n" "$CC" >&6; }
4692else
4693  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4694printf "%s\n" "no" >&6; }
4695fi
4696
4697
4698  fi
4699fi
4700if test -z "$CC"; then
4701  # Extract the first word of "cc", so it can be a program name with args.
4702set dummy cc; ac_word=$2
4703{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4704printf %s "checking for $ac_word... " >&6; }
4705if test ${ac_cv_prog_CC+y}
4706then :
4707  printf %s "(cached) " >&6
4708else $as_nop
4709  if test -n "$CC"; then
4710  ac_cv_prog_CC="$CC" # Let the user override the test.
4711else
4712  ac_prog_rejected=no
4713as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4714for as_dir in $PATH
4715do
4716  IFS=$as_save_IFS
4717  case $as_dir in #(((
4718    '') as_dir=./ ;;
4719    */) ;;
4720    *) as_dir=$as_dir/ ;;
4721  esac
4722    for ac_exec_ext in '' $ac_executable_extensions; do
4723  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4724    if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4725       ac_prog_rejected=yes
4726       continue
4727     fi
4728    ac_cv_prog_CC="cc"
4729    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4730    break 2
4731  fi
4732done
4733  done
4734IFS=$as_save_IFS
4735
4736if test $ac_prog_rejected = yes; then
4737  # We found a bogon in the path, so make sure we never use it.
4738  set dummy $ac_cv_prog_CC
4739  shift
4740  if test $# != 0; then
4741    # We chose a different compiler from the bogus one.
4742    # However, it has the same basename, so the bogon will be chosen
4743    # first if we set CC to just the basename; use the full file name.
4744    shift
4745    ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
4746  fi
4747fi
4748fi
4749fi
4750CC=$ac_cv_prog_CC
4751if test -n "$CC"; then
4752  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4753printf "%s\n" "$CC" >&6; }
4754else
4755  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4756printf "%s\n" "no" >&6; }
4757fi
4758
4759
4760fi
4761if test -z "$CC"; then
4762  if test -n "$ac_tool_prefix"; then
4763  for ac_prog in cl.exe
4764  do
4765    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4766set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4767{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4768printf %s "checking for $ac_word... " >&6; }
4769if test ${ac_cv_prog_CC+y}
4770then :
4771  printf %s "(cached) " >&6
4772else $as_nop
4773  if test -n "$CC"; then
4774  ac_cv_prog_CC="$CC" # Let the user override the test.
4775else
4776as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4777for as_dir in $PATH
4778do
4779  IFS=$as_save_IFS
4780  case $as_dir in #(((
4781    '') as_dir=./ ;;
4782    */) ;;
4783    *) as_dir=$as_dir/ ;;
4784  esac
4785    for ac_exec_ext in '' $ac_executable_extensions; do
4786  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4787    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4788    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4789    break 2
4790  fi
4791done
4792  done
4793IFS=$as_save_IFS
4794
4795fi
4796fi
4797CC=$ac_cv_prog_CC
4798if test -n "$CC"; then
4799  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4800printf "%s\n" "$CC" >&6; }
4801else
4802  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4803printf "%s\n" "no" >&6; }
4804fi
4805
4806
4807    test -n "$CC" && break
4808  done
4809fi
4810if test -z "$CC"; then
4811  ac_ct_CC=$CC
4812  for ac_prog in cl.exe
4813do
4814  # Extract the first word of "$ac_prog", so it can be a program name with args.
4815set dummy $ac_prog; ac_word=$2
4816{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4817printf %s "checking for $ac_word... " >&6; }
4818if test ${ac_cv_prog_ac_ct_CC+y}
4819then :
4820  printf %s "(cached) " >&6
4821else $as_nop
4822  if test -n "$ac_ct_CC"; then
4823  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4824else
4825as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4826for as_dir in $PATH
4827do
4828  IFS=$as_save_IFS
4829  case $as_dir in #(((
4830    '') as_dir=./ ;;
4831    */) ;;
4832    *) as_dir=$as_dir/ ;;
4833  esac
4834    for ac_exec_ext in '' $ac_executable_extensions; do
4835  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4836    ac_cv_prog_ac_ct_CC="$ac_prog"
4837    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4838    break 2
4839  fi
4840done
4841  done
4842IFS=$as_save_IFS
4843
4844fi
4845fi
4846ac_ct_CC=$ac_cv_prog_ac_ct_CC
4847if test -n "$ac_ct_CC"; then
4848  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4849printf "%s\n" "$ac_ct_CC" >&6; }
4850else
4851  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4852printf "%s\n" "no" >&6; }
4853fi
4854
4855
4856  test -n "$ac_ct_CC" && break
4857done
4858
4859  if test "x$ac_ct_CC" = x; then
4860    CC=""
4861  else
4862    case $cross_compiling:$ac_tool_warned in
4863yes:)
4864{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4865printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4866ac_tool_warned=yes ;;
4867esac
4868    CC=$ac_ct_CC
4869  fi
4870fi
4871
4872fi
4873if test -z "$CC"; then
4874  if test -n "$ac_tool_prefix"; then
4875  # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
4876set dummy ${ac_tool_prefix}clang; ac_word=$2
4877{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4878printf %s "checking for $ac_word... " >&6; }
4879if test ${ac_cv_prog_CC+y}
4880then :
4881  printf %s "(cached) " >&6
4882else $as_nop
4883  if test -n "$CC"; then
4884  ac_cv_prog_CC="$CC" # Let the user override the test.
4885else
4886as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4887for as_dir in $PATH
4888do
4889  IFS=$as_save_IFS
4890  case $as_dir in #(((
4891    '') as_dir=./ ;;
4892    */) ;;
4893    *) as_dir=$as_dir/ ;;
4894  esac
4895    for ac_exec_ext in '' $ac_executable_extensions; do
4896  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4897    ac_cv_prog_CC="${ac_tool_prefix}clang"
4898    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4899    break 2
4900  fi
4901done
4902  done
4903IFS=$as_save_IFS
4904
4905fi
4906fi
4907CC=$ac_cv_prog_CC
4908if test -n "$CC"; then
4909  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4910printf "%s\n" "$CC" >&6; }
4911else
4912  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4913printf "%s\n" "no" >&6; }
4914fi
4915
4916
4917fi
4918if test -z "$ac_cv_prog_CC"; then
4919  ac_ct_CC=$CC
4920  # Extract the first word of "clang", so it can be a program name with args.
4921set dummy clang; ac_word=$2
4922{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4923printf %s "checking for $ac_word... " >&6; }
4924if test ${ac_cv_prog_ac_ct_CC+y}
4925then :
4926  printf %s "(cached) " >&6
4927else $as_nop
4928  if test -n "$ac_ct_CC"; then
4929  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4930else
4931as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4932for as_dir in $PATH
4933do
4934  IFS=$as_save_IFS
4935  case $as_dir in #(((
4936    '') as_dir=./ ;;
4937    */) ;;
4938    *) as_dir=$as_dir/ ;;
4939  esac
4940    for ac_exec_ext in '' $ac_executable_extensions; do
4941  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4942    ac_cv_prog_ac_ct_CC="clang"
4943    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4944    break 2
4945  fi
4946done
4947  done
4948IFS=$as_save_IFS
4949
4950fi
4951fi
4952ac_ct_CC=$ac_cv_prog_ac_ct_CC
4953if test -n "$ac_ct_CC"; then
4954  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4955printf "%s\n" "$ac_ct_CC" >&6; }
4956else
4957  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4958printf "%s\n" "no" >&6; }
4959fi
4960
4961  if test "x$ac_ct_CC" = x; then
4962    CC=""
4963  else
4964    case $cross_compiling:$ac_tool_warned in
4965yes:)
4966{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4967printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4968ac_tool_warned=yes ;;
4969esac
4970    CC=$ac_ct_CC
4971  fi
4972else
4973  CC="$ac_cv_prog_CC"
4974fi
4975
4976fi
4977
4978
4979test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4980printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4981as_fn_error $? "no acceptable C compiler found in \$PATH
4982See \`config.log' for more details" "$LINENO" 5; }
4983
4984# Provide some information about the compiler.
4985printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4986set X $ac_compile
4987ac_compiler=$2
4988for ac_option in --version -v -V -qversion -version; do
4989  { { ac_try="$ac_compiler $ac_option >&5"
4990case "(($ac_try" in
4991  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4992  *) ac_try_echo=$ac_try;;
4993esac
4994eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4995printf "%s\n" "$ac_try_echo"; } >&5
4996  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4997  ac_status=$?
4998  if test -s conftest.err; then
4999    sed '10a\
5000... rest of stderr output deleted ...
5001         10q' conftest.err >conftest.er1
5002    cat conftest.er1 >&5
5003  fi
5004  rm -f conftest.er1 conftest.err
5005  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5006  test $ac_status = 0; }
5007done
5008
5009{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
5010printf %s "checking whether the compiler supports GNU C... " >&6; }
5011if test ${ac_cv_c_compiler_gnu+y}
5012then :
5013  printf %s "(cached) " >&6
5014else $as_nop
5015  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5016/* end confdefs.h.  */
5017
5018int
5019main (void)
5020{
5021#ifndef __GNUC__
5022       choke me
5023#endif
5024
5025  ;
5026  return 0;
5027}
5028_ACEOF
5029if ac_fn_c_try_compile "$LINENO"
5030then :
5031  ac_compiler_gnu=yes
5032else $as_nop
5033  ac_compiler_gnu=no
5034fi
5035rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5036ac_cv_c_compiler_gnu=$ac_compiler_gnu
5037
5038fi
5039{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5040printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
5041ac_compiler_gnu=$ac_cv_c_compiler_gnu
5042
5043if test $ac_compiler_gnu = yes; then
5044  GCC=yes
5045else
5046  GCC=
5047fi
5048ac_test_CFLAGS=${CFLAGS+y}
5049ac_save_CFLAGS=$CFLAGS
5050{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5051printf %s "checking whether $CC accepts -g... " >&6; }
5052if test ${ac_cv_prog_cc_g+y}
5053then :
5054  printf %s "(cached) " >&6
5055else $as_nop
5056  ac_save_c_werror_flag=$ac_c_werror_flag
5057   ac_c_werror_flag=yes
5058   ac_cv_prog_cc_g=no
5059   CFLAGS="-g"
5060   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5061/* end confdefs.h.  */
5062
5063int
5064main (void)
5065{
5066
5067  ;
5068  return 0;
5069}
5070_ACEOF
5071if ac_fn_c_try_compile "$LINENO"
5072then :
5073  ac_cv_prog_cc_g=yes
5074else $as_nop
5075  CFLAGS=""
5076      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5077/* end confdefs.h.  */
5078
5079int
5080main (void)
5081{
5082
5083  ;
5084  return 0;
5085}
5086_ACEOF
5087if ac_fn_c_try_compile "$LINENO"
5088then :
5089
5090else $as_nop
5091  ac_c_werror_flag=$ac_save_c_werror_flag
5092	 CFLAGS="-g"
5093	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5094/* end confdefs.h.  */
5095
5096int
5097main (void)
5098{
5099
5100  ;
5101  return 0;
5102}
5103_ACEOF
5104if ac_fn_c_try_compile "$LINENO"
5105then :
5106  ac_cv_prog_cc_g=yes
5107fi
5108rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5109fi
5110rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5111fi
5112rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5113   ac_c_werror_flag=$ac_save_c_werror_flag
5114fi
5115{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5116printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
5117if test $ac_test_CFLAGS; then
5118  CFLAGS=$ac_save_CFLAGS
5119elif test $ac_cv_prog_cc_g = yes; then
5120  if test "$GCC" = yes; then
5121    CFLAGS="-g -O2"
5122  else
5123    CFLAGS="-g"
5124  fi
5125else
5126  if test "$GCC" = yes; then
5127    CFLAGS="-O2"
5128  else
5129    CFLAGS=
5130  fi
5131fi
5132{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
5133printf %s "checking for $CC option to enable C11 features... " >&6; }
5134if test ${ac_cv_prog_cc_c11+y}
5135then :
5136  printf %s "(cached) " >&6
5137else $as_nop
5138  ac_cv_prog_cc_c11=no
5139ac_save_CC=$CC
5140cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5141/* end confdefs.h.  */
5142$ac_c_conftest_c11_program
5143_ACEOF
5144for ac_arg in '' -std=gnu11
5145do
5146  CC="$ac_save_CC $ac_arg"
5147  if ac_fn_c_try_compile "$LINENO"
5148then :
5149  ac_cv_prog_cc_c11=$ac_arg
5150fi
5151rm -f core conftest.err conftest.$ac_objext conftest.beam
5152  test "x$ac_cv_prog_cc_c11" != "xno" && break
5153done
5154rm -f conftest.$ac_ext
5155CC=$ac_save_CC
5156
5157fi
5158# AC_CACHE_VAL
5159ac_prog_cc_stdc_options=
5160case "x$ac_cv_prog_cc_c11" in #(
5161  x) :
5162    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5163printf "%s\n" "none needed" >&6; } ;; #(
5164  xno) :
5165    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5166printf "%s\n" "unsupported" >&6; } ;; #(
5167  *) :
5168    ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c11"
5169    CC="$CC$ac_prog_cc_stdc_options"
5170    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
5171printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } ;;
5172esac
5173if test "x$ac_cv_prog_cc_c11" != xno
5174then :
5175  ac_prog_cc_stdc=c11
5176		 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
5177else $as_nop
5178  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
5179printf %s "checking for $CC option to enable C99 features... " >&6; }
5180if test ${ac_cv_prog_cc_c99+y}
5181then :
5182  printf %s "(cached) " >&6
5183else $as_nop
5184  ac_cv_prog_cc_c99=no
5185ac_save_CC=$CC
5186cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5187/* end confdefs.h.  */
5188$ac_c_conftest_c89_program
5189_ACEOF
5190for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc1x -qlanglvl=extc99
5191do
5192  CC="$ac_save_CC $ac_arg"
5193  if ac_fn_c_try_compile "$LINENO"
5194then :
5195  ac_cv_prog_cc_c99=$ac_arg
5196fi
5197rm -f core conftest.err conftest.$ac_objext conftest.beam
5198  test "x$ac_cv_prog_cc_c99" != "xno" && break
5199done
5200rm -f conftest.$ac_ext
5201CC=$ac_save_CC
5202
5203fi
5204# AC_CACHE_VAL
5205ac_prog_cc_stdc_options=
5206case "x$ac_cv_prog_cc_c99" in #(
5207  x) :
5208    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5209printf "%s\n" "none needed" >&6; } ;; #(
5210  xno) :
5211    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5212printf "%s\n" "unsupported" >&6; } ;; #(
5213  *) :
5214    ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c99"
5215    CC="$CC$ac_prog_cc_stdc_options"
5216    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5217printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } ;;
5218esac
5219if test "x$ac_cv_prog_cc_c99" != xno
5220then :
5221  ac_prog_cc_stdc=c99
5222		    ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
5223else $as_nop
5224  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
5225printf %s "checking for $CC option to enable C89 features... " >&6; }
5226if test ${ac_cv_prog_cc_c89+y}
5227then :
5228  printf %s "(cached) " >&6
5229else $as_nop
5230  ac_cv_prog_cc_c89=no
5231ac_save_CC=$CC
5232cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5233/* end confdefs.h.  */
5234$ac_c_conftest_c89_program
5235_ACEOF
5236for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5237	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5238do
5239  CC="$ac_save_CC $ac_arg"
5240  if ac_fn_c_try_compile "$LINENO"
5241then :
5242  ac_cv_prog_cc_c89=$ac_arg
5243fi
5244rm -f core conftest.err conftest.$ac_objext conftest.beam
5245  test "x$ac_cv_prog_cc_c89" != "xno" && break
5246done
5247rm -f conftest.$ac_ext
5248CC=$ac_save_CC
5249
5250fi
5251# AC_CACHE_VAL
5252ac_prog_cc_stdc_options=
5253case "x$ac_cv_prog_cc_c89" in #(
5254  x) :
5255    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5256printf "%s\n" "none needed" >&6; } ;; #(
5257  xno) :
5258    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5259printf "%s\n" "unsupported" >&6; } ;; #(
5260  *) :
5261    ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c89"
5262    CC="$CC$ac_prog_cc_stdc_options"
5263    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5264printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } ;;
5265esac
5266if test "x$ac_cv_prog_cc_c89" != xno
5267then :
5268  ac_prog_cc_stdc=c89
5269		       ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
5270else $as_nop
5271  ac_prog_cc_stdc=no
5272		       ac_cv_prog_cc_stdc=no
5273fi
5274
5275fi
5276
5277fi
5278
5279ac_ext=c
5280ac_cpp='$CPP $CPPFLAGS'
5281ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5282ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5283ac_compiler_gnu=$ac_cv_c_compiler_gnu
5284
5285    ac_ext=c
5286ac_cpp='$CPP $CPPFLAGS'
5287ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5288ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5289ac_compiler_gnu=$ac_cv_c_compiler_gnu
5290{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5291printf %s "checking how to run the C preprocessor... " >&6; }
5292# On Suns, sometimes $CPP names a directory.
5293if test -n "$CPP" && test -d "$CPP"; then
5294  CPP=
5295fi
5296if test -z "$CPP"; then
5297  if test ${ac_cv_prog_CPP+y}
5298then :
5299  printf %s "(cached) " >&6
5300else $as_nop
5301      # Double quotes because $CC needs to be expanded
5302    for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp
5303    do
5304      ac_preproc_ok=false
5305for ac_c_preproc_warn_flag in '' yes
5306do
5307  # Use a header file that comes with gcc, so configuring glibc
5308  # with a fresh cross-compiler works.
5309  # On the NeXT, cc -E runs the code through the compiler's parser,
5310  # not just through cpp. "Syntax error" is here to catch this case.
5311  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5312/* end confdefs.h.  */
5313#include <limits.h>
5314		     Syntax error
5315_ACEOF
5316if ac_fn_c_try_cpp "$LINENO"
5317then :
5318
5319else $as_nop
5320  # Broken: fails on valid input.
5321continue
5322fi
5323rm -f conftest.err conftest.i conftest.$ac_ext
5324
5325  # OK, works on sane cases.  Now check whether nonexistent headers
5326  # can be detected and how.
5327  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5328/* end confdefs.h.  */
5329#include <ac_nonexistent.h>
5330_ACEOF
5331if ac_fn_c_try_cpp "$LINENO"
5332then :
5333  # Broken: success on invalid input.
5334continue
5335else $as_nop
5336  # Passes both tests.
5337ac_preproc_ok=:
5338break
5339fi
5340rm -f conftest.err conftest.i conftest.$ac_ext
5341
5342done
5343# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5344rm -f conftest.i conftest.err conftest.$ac_ext
5345if $ac_preproc_ok
5346then :
5347  break
5348fi
5349
5350    done
5351    ac_cv_prog_CPP=$CPP
5352
5353fi
5354  CPP=$ac_cv_prog_CPP
5355else
5356  ac_cv_prog_CPP=$CPP
5357fi
5358{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5359printf "%s\n" "$CPP" >&6; }
5360ac_preproc_ok=false
5361for ac_c_preproc_warn_flag in '' yes
5362do
5363  # Use a header file that comes with gcc, so configuring glibc
5364  # with a fresh cross-compiler works.
5365  # On the NeXT, cc -E runs the code through the compiler's parser,
5366  # not just through cpp. "Syntax error" is here to catch this case.
5367  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5368/* end confdefs.h.  */
5369#include <limits.h>
5370		     Syntax error
5371_ACEOF
5372if ac_fn_c_try_cpp "$LINENO"
5373then :
5374
5375else $as_nop
5376  # Broken: fails on valid input.
5377continue
5378fi
5379rm -f conftest.err conftest.i conftest.$ac_ext
5380
5381  # OK, works on sane cases.  Now check whether nonexistent headers
5382  # can be detected and how.
5383  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5384/* end confdefs.h.  */
5385#include <ac_nonexistent.h>
5386_ACEOF
5387if ac_fn_c_try_cpp "$LINENO"
5388then :
5389  # Broken: success on invalid input.
5390continue
5391else $as_nop
5392  # Passes both tests.
5393ac_preproc_ok=:
5394break
5395fi
5396rm -f conftest.err conftest.i conftest.$ac_ext
5397
5398done
5399# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5400rm -f conftest.i conftest.err conftest.$ac_ext
5401if $ac_preproc_ok
5402then :
5403
5404else $as_nop
5405  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5406printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5407as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
5408See \`config.log' for more details" "$LINENO" 5; }
5409fi
5410
5411ac_ext=c
5412ac_cpp='$CPP $CPPFLAGS'
5413ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5414ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5415ac_compiler_gnu=$ac_cv_c_compiler_gnu
5416
5417
5418    #--------------------------------------------------------------------
5419    # Checks to see if the make program sets the $MAKE variable.
5420    #--------------------------------------------------------------------
5421
5422    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
5423printf %s "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
5424set x ${MAKE-make}
5425ac_make=`printf "%s\n" "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
5426if eval test \${ac_cv_prog_make_${ac_make}_set+y}
5427then :
5428  printf %s "(cached) " >&6
5429else $as_nop
5430  cat >conftest.make <<\_ACEOF
5431SHELL = /bin/sh
5432all:
5433	@echo '@@@%%%=$(MAKE)=@@@%%%'
5434_ACEOF
5435# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
5436case `${MAKE-make} -f conftest.make 2>/dev/null` in
5437  *@@@%%%=?*=@@@%%%*)
5438    eval ac_cv_prog_make_${ac_make}_set=yes;;
5439  *)
5440    eval ac_cv_prog_make_${ac_make}_set=no;;
5441esac
5442rm -f conftest.make
5443fi
5444if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
5445  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5446printf "%s\n" "yes" >&6; }
5447  SET_MAKE=
5448else
5449  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5450printf "%s\n" "no" >&6; }
5451  SET_MAKE="MAKE=${MAKE-make}"
5452fi
5453
5454
5455    #--------------------------------------------------------------------
5456    # Find ranlib
5457    #--------------------------------------------------------------------
5458
5459    if test -n "$ac_tool_prefix"; then
5460  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5461set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5462{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5463printf %s "checking for $ac_word... " >&6; }
5464if test ${ac_cv_prog_RANLIB+y}
5465then :
5466  printf %s "(cached) " >&6
5467else $as_nop
5468  if test -n "$RANLIB"; then
5469  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5470else
5471as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5472for as_dir in $PATH
5473do
5474  IFS=$as_save_IFS
5475  case $as_dir in #(((
5476    '') as_dir=./ ;;
5477    */) ;;
5478    *) as_dir=$as_dir/ ;;
5479  esac
5480    for ac_exec_ext in '' $ac_executable_extensions; do
5481  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5482    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5483    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
5484    break 2
5485  fi
5486done
5487  done
5488IFS=$as_save_IFS
5489
5490fi
5491fi
5492RANLIB=$ac_cv_prog_RANLIB
5493if test -n "$RANLIB"; then
5494  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5495printf "%s\n" "$RANLIB" >&6; }
5496else
5497  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5498printf "%s\n" "no" >&6; }
5499fi
5500
5501
5502fi
5503if test -z "$ac_cv_prog_RANLIB"; then
5504  ac_ct_RANLIB=$RANLIB
5505  # Extract the first word of "ranlib", so it can be a program name with args.
5506set dummy ranlib; ac_word=$2
5507{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5508printf %s "checking for $ac_word... " >&6; }
5509if test ${ac_cv_prog_ac_ct_RANLIB+y}
5510then :
5511  printf %s "(cached) " >&6
5512else $as_nop
5513  if test -n "$ac_ct_RANLIB"; then
5514  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5515else
5516as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5517for as_dir in $PATH
5518do
5519  IFS=$as_save_IFS
5520  case $as_dir in #(((
5521    '') as_dir=./ ;;
5522    */) ;;
5523    *) as_dir=$as_dir/ ;;
5524  esac
5525    for ac_exec_ext in '' $ac_executable_extensions; do
5526  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5527    ac_cv_prog_ac_ct_RANLIB="ranlib"
5528    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
5529    break 2
5530  fi
5531done
5532  done
5533IFS=$as_save_IFS
5534
5535fi
5536fi
5537ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5538if test -n "$ac_ct_RANLIB"; then
5539  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5540printf "%s\n" "$ac_ct_RANLIB" >&6; }
5541else
5542  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5543printf "%s\n" "no" >&6; }
5544fi
5545
5546  if test "x$ac_ct_RANLIB" = x; then
5547    RANLIB=""
5548  else
5549    case $cross_compiling:$ac_tool_warned in
5550yes:)
5551{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5552printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5553ac_tool_warned=yes ;;
5554esac
5555    RANLIB=$ac_ct_RANLIB
5556  fi
5557else
5558  RANLIB="$ac_cv_prog_RANLIB"
5559fi
5560
5561
5562    #--------------------------------------------------------------------
5563    # Determines the correct binary file extension (.o, .obj, .exe etc.)
5564    #--------------------------------------------------------------------
5565
5566
5567
5568
5569ac_header= ac_cache=
5570for ac_item in $ac_header_c_list
5571do
5572  if test $ac_cache; then
5573    ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default"
5574    if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then
5575      printf "%s\n" "#define $ac_item 1" >> confdefs.h
5576    fi
5577    ac_header= ac_cache=
5578  elif test $ac_header; then
5579    ac_cache=$ac_item
5580  else
5581    ac_header=$ac_item
5582  fi
5583done
5584
5585
5586
5587
5588
5589
5590
5591
5592if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes
5593then :
5594
5595printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h
5596
5597fi
5598
5599    # Any macros that use the compiler (e.g. AC_TRY_COMPILE) have to go here.
5600
5601
5602    #------------------------------------------------------------------------
5603    # If we're using GCC, see if the compiler understands -pipe. If so, use it.
5604    # It makes compiling go faster.  (This is only a performance feature.)
5605    #------------------------------------------------------------------------
5606
5607    if test -z "$no_pipe" -a -n "$GCC"; then
5608	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the compiler understands -pipe" >&5
5609printf %s "checking if the compiler understands -pipe... " >&6; }
5610if test ${tcl_cv_cc_pipe+y}
5611then :
5612  printf %s "(cached) " >&6
5613else $as_nop
5614
5615	    hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -pipe"
5616	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5617/* end confdefs.h.  */
5618
5619int
5620main (void)
5621{
5622
5623  ;
5624  return 0;
5625}
5626_ACEOF
5627if ac_fn_c_try_compile "$LINENO"
5628then :
5629  tcl_cv_cc_pipe=yes
5630else $as_nop
5631  tcl_cv_cc_pipe=no
5632fi
5633rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5634	    CFLAGS=$hold_cflags
5635fi
5636{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_pipe" >&5
5637printf "%s\n" "$tcl_cv_cc_pipe" >&6; }
5638	if test $tcl_cv_cc_pipe = yes; then
5639	    CFLAGS="$CFLAGS -pipe"
5640	fi
5641    fi
5642
5643    #--------------------------------------------------------------------
5644    # Common compiler flag setup
5645    #--------------------------------------------------------------------
5646
5647     { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
5648printf %s "checking whether byte ordering is bigendian... " >&6; }
5649if test ${ac_cv_c_bigendian+y}
5650then :
5651  printf %s "(cached) " >&6
5652else $as_nop
5653  ac_cv_c_bigendian=unknown
5654    # See if we're dealing with a universal compiler.
5655    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5656/* end confdefs.h.  */
5657#ifndef __APPLE_CC__
5658	       not a universal capable compiler
5659	     #endif
5660	     typedef int dummy;
5661
5662_ACEOF
5663if ac_fn_c_try_compile "$LINENO"
5664then :
5665
5666	# Check for potential -arch flags.  It is not universal unless
5667	# there are at least two -arch flags with different values.
5668	ac_arch=
5669	ac_prev=
5670	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
5671	 if test -n "$ac_prev"; then
5672	   case $ac_word in
5673	     i?86 | x86_64 | ppc | ppc64)
5674	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
5675		 ac_arch=$ac_word
5676	       else
5677		 ac_cv_c_bigendian=universal
5678		 break
5679	       fi
5680	       ;;
5681	   esac
5682	   ac_prev=
5683	 elif test "x$ac_word" = "x-arch"; then
5684	   ac_prev=arch
5685	 fi
5686       done
5687fi
5688rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5689    if test $ac_cv_c_bigendian = unknown; then
5690      # See if sys/param.h defines the BYTE_ORDER macro.
5691      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5692/* end confdefs.h.  */
5693#include <sys/types.h>
5694	     #include <sys/param.h>
5695
5696int
5697main (void)
5698{
5699#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
5700		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
5701		     && LITTLE_ENDIAN)
5702	      bogus endian macros
5703	     #endif
5704
5705  ;
5706  return 0;
5707}
5708_ACEOF
5709if ac_fn_c_try_compile "$LINENO"
5710then :
5711  # It does; now see whether it defined to BIG_ENDIAN or not.
5712	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5713/* end confdefs.h.  */
5714#include <sys/types.h>
5715		#include <sys/param.h>
5716
5717int
5718main (void)
5719{
5720#if BYTE_ORDER != BIG_ENDIAN
5721		 not big endian
5722		#endif
5723
5724  ;
5725  return 0;
5726}
5727_ACEOF
5728if ac_fn_c_try_compile "$LINENO"
5729then :
5730  ac_cv_c_bigendian=yes
5731else $as_nop
5732  ac_cv_c_bigendian=no
5733fi
5734rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5735fi
5736rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5737    fi
5738    if test $ac_cv_c_bigendian = unknown; then
5739      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
5740      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5741/* end confdefs.h.  */
5742#include <limits.h>
5743
5744int
5745main (void)
5746{
5747#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
5748	      bogus endian macros
5749	     #endif
5750
5751  ;
5752  return 0;
5753}
5754_ACEOF
5755if ac_fn_c_try_compile "$LINENO"
5756then :
5757  # It does; now see whether it defined to _BIG_ENDIAN or not.
5758	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5759/* end confdefs.h.  */
5760#include <limits.h>
5761
5762int
5763main (void)
5764{
5765#ifndef _BIG_ENDIAN
5766		 not big endian
5767		#endif
5768
5769  ;
5770  return 0;
5771}
5772_ACEOF
5773if ac_fn_c_try_compile "$LINENO"
5774then :
5775  ac_cv_c_bigendian=yes
5776else $as_nop
5777  ac_cv_c_bigendian=no
5778fi
5779rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5780fi
5781rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5782    fi
5783    if test $ac_cv_c_bigendian = unknown; then
5784      # Compile a test program.
5785      if test "$cross_compiling" = yes
5786then :
5787  # Try to guess by grepping values from an object file.
5788	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5789/* end confdefs.h.  */
5790unsigned short int ascii_mm[] =
5791		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
5792		unsigned short int ascii_ii[] =
5793		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
5794		int use_ascii (int i) {
5795		  return ascii_mm[i] + ascii_ii[i];
5796		}
5797		unsigned short int ebcdic_ii[] =
5798		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
5799		unsigned short int ebcdic_mm[] =
5800		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
5801		int use_ebcdic (int i) {
5802		  return ebcdic_mm[i] + ebcdic_ii[i];
5803		}
5804		extern int foo;
5805
5806int
5807main (void)
5808{
5809return use_ascii (foo) == use_ebcdic (foo);
5810  ;
5811  return 0;
5812}
5813_ACEOF
5814if ac_fn_c_try_compile "$LINENO"
5815then :
5816  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
5817	      ac_cv_c_bigendian=yes
5818	    fi
5819	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
5820	      if test "$ac_cv_c_bigendian" = unknown; then
5821		ac_cv_c_bigendian=no
5822	      else
5823		# finding both strings is unlikely to happen, but who knows?
5824		ac_cv_c_bigendian=unknown
5825	      fi
5826	    fi
5827fi
5828rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5829else $as_nop
5830  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5831/* end confdefs.h.  */
5832$ac_includes_default
5833int
5834main (void)
5835{
5836
5837	     /* Are we little or big endian?  From Harbison&Steele.  */
5838	     union
5839	     {
5840	       long int l;
5841	       char c[sizeof (long int)];
5842	     } u;
5843	     u.l = 1;
5844	     return u.c[sizeof (long int) - 1] == 1;
5845
5846  ;
5847  return 0;
5848}
5849_ACEOF
5850if ac_fn_c_try_run "$LINENO"
5851then :
5852  ac_cv_c_bigendian=no
5853else $as_nop
5854  ac_cv_c_bigendian=yes
5855fi
5856rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5857  conftest.$ac_objext conftest.beam conftest.$ac_ext
5858fi
5859
5860    fi
5861fi
5862{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
5863printf "%s\n" "$ac_cv_c_bigendian" >&6; }
5864 case $ac_cv_c_bigendian in #(
5865   yes)
5866     printf "%s\n" "#define WORDS_BIGENDIAN 1" >>confdefs.h
5867;; #(
5868   no)
5869      ;; #(
5870   universal)
5871
5872printf "%s\n" "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
5873
5874     ;; #(
5875   *)
5876     as_fn_error $? "unknown endianness
5877 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
5878 esac
5879
5880
5881
5882#-----------------------------------------------------------------------
5883# Setup inlining if available. Check sizeof long long, long.
5884#-----------------------------------------------------------------------
5885
5886{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
5887printf %s "checking for inline... " >&6; }
5888if test ${ac_cv_c_inline+y}
5889then :
5890  printf %s "(cached) " >&6
5891else $as_nop
5892  ac_cv_c_inline=no
5893for ac_kw in inline __inline__ __inline; do
5894  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5895/* end confdefs.h.  */
5896#ifndef __cplusplus
5897typedef int foo_t;
5898static $ac_kw foo_t static_foo (void) {return 0; }
5899$ac_kw foo_t foo (void) {return 0; }
5900#endif
5901
5902_ACEOF
5903if ac_fn_c_try_compile "$LINENO"
5904then :
5905  ac_cv_c_inline=$ac_kw
5906fi
5907rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5908  test "$ac_cv_c_inline" != no && break
5909done
5910
5911fi
5912{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
5913printf "%s\n" "$ac_cv_c_inline" >&6; }
5914
5915case $ac_cv_c_inline in
5916  inline | yes) ;;
5917  *)
5918    case $ac_cv_c_inline in
5919      no) ac_val=;;
5920      *) ac_val=$ac_cv_c_inline;;
5921    esac
5922    cat >>confdefs.h <<_ACEOF
5923#ifndef __cplusplus
5924#define inline $ac_val
5925#endif
5926_ACEOF
5927    ;;
5928esac
5929
5930ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
5931if test "x$ac_cv_type_long_long" = xyes
5932then :
5933
5934    printf "%s\n" "#define HAVE_LONG_LONG 1" >>confdefs.h
5935
5936    # The cast to long int works around a bug in the HP C Compiler
5937# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5938# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5939# This bug is HP SR number 8606223364.
5940{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
5941printf %s "checking size of long long... " >&6; }
5942if test ${ac_cv_sizeof_long_long+y}
5943then :
5944  printf %s "(cached) " >&6
5945else $as_nop
5946  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long"        "$ac_includes_default"
5947then :
5948
5949else $as_nop
5950  if test "$ac_cv_type_long_long" = yes; then
5951     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5952printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5953as_fn_error 77 "cannot compute sizeof (long long)
5954See \`config.log' for more details" "$LINENO" 5; }
5955   else
5956     ac_cv_sizeof_long_long=0
5957   fi
5958fi
5959
5960fi
5961{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
5962printf "%s\n" "$ac_cv_sizeof_long_long" >&6; }
5963
5964
5965
5966printf "%s\n" "#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long" >>confdefs.h
5967
5968
5969
5970fi
5971
5972# The cast to long int works around a bug in the HP C Compiler
5973# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5974# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5975# This bug is HP SR number 8606223364.
5976{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
5977printf %s "checking size of long... " >&6; }
5978if test ${ac_cv_sizeof_long+y}
5979then :
5980  printf %s "(cached) " >&6
5981else $as_nop
5982  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"
5983then :
5984
5985else $as_nop
5986  if test "$ac_cv_type_long" = yes; then
5987     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5988printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5989as_fn_error 77 "cannot compute sizeof (long)
5990See \`config.log' for more details" "$LINENO" 5; }
5991   else
5992     ac_cv_sizeof_long=0
5993   fi
5994fi
5995
5996fi
5997{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
5998printf "%s\n" "$ac_cv_sizeof_long" >&6; }
5999
6000
6001
6002printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
6003
6004
6005
6006#-----------------------------------------------------------------------
6007# __CHANGE__
6008# Specify the C source files to compile in TEA_ADD_SOURCES,
6009# public headers that need to be installed in TEA_ADD_HEADERS,
6010# stub library C source files to compile in TEA_ADD_STUB_SOURCES,
6011# and runtime Tcl library files in TEA_ADD_TCL_SOURCES.
6012# This defines PKG(_STUB)_SOURCES, PKG(_STUB)_OBJECTS, PKG_HEADERS
6013# and PKG_TCL_SOURCES.
6014#-----------------------------------------------------------------------
6015
6016
6017    vars="generic/tdbcpostgres.c generic/pqStubInit.c"
6018    for i in $vars; do
6019	case $i in
6020	    \$*)
6021		# allow $-var names
6022		PKG_SOURCES="$PKG_SOURCES $i"
6023		PKG_OBJECTS="$PKG_OBJECTS $i"
6024		;;
6025	    *)
6026		# check for existence - allows for generic/win/unix VPATH
6027		# To add more dirs here (like 'src'), you have to update VPATH
6028		# in Makefile.in as well
6029		if test ! -f "${srcdir}/$i" -a ! -f "${srcdir}/generic/$i" \
6030		    -a ! -f "${srcdir}/win/$i" -a ! -f "${srcdir}/unix/$i" \
6031		    -a ! -f "${srcdir}/macosx/$i" \
6032		    ; then
6033		    as_fn_error $? "could not find source file '$i'" "$LINENO" 5
6034		fi
6035		PKG_SOURCES="$PKG_SOURCES $i"
6036		# this assumes it is in a VPATH dir
6037		i=`basename $i`
6038		# handle user calling this before or after TEA_SETUP_COMPILER
6039		if test x"${OBJEXT}" != x ; then
6040		    j="`echo $i | sed -e 's/\.[^.]*$//'`.${OBJEXT}"
6041		else
6042		    j="`echo $i | sed -e 's/\.[^.]*$//'`.\${OBJEXT}"
6043		fi
6044		PKG_OBJECTS="$PKG_OBJECTS $j"
6045		;;
6046	esac
6047    done
6048
6049
6050
6051
6052    vars="generic/fakepq.h generic/pqStubs.h"
6053    for i in $vars; do
6054	# check for existence, be strict because it is installed
6055	if test ! -f "${srcdir}/$i" ; then
6056	    as_fn_error $? "could not find header file '${srcdir}/$i'" "$LINENO" 5
6057	fi
6058	PKG_HEADERS="$PKG_HEADERS $i"
6059    done
6060
6061
6062if test "${TCL_MAJOR_VERSION}" -eq 8 ; then
6063  if test "${TCL_MINOR_VERSION}" -eq 5 ; then
6064
6065    vars="${TCLOO_INCLUDE_SPEC}"
6066    for i in $vars; do
6067	PKG_INCLUDES="$PKG_INCLUDES $i"
6068    done
6069
6070
6071
6072    vars="${TCLOO_STUB_LIB_SPEC}"
6073    for i in $vars; do
6074	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
6075	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
6076	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.[lL][iI][bB]$/-l\1/'`
6077	fi
6078	PKG_LIBS="$PKG_LIBS $i"
6079    done
6080
6081
6082  fi
6083fi
6084
6085    PKG_CFLAGS="$PKG_CFLAGS ${TCLOO_CFLAGS}"
6086
6087
6088
6089    vars="${tdbc_INCLUDE_SPEC}"
6090    for i in $vars; do
6091	PKG_INCLUDES="$PKG_INCLUDES $i"
6092    done
6093
6094
6095if test "x${TEA_PLATFORM}" = "xwindows" -a "x${GCC}" != "xyes" ; then
6096
6097    vars="\"`${CYGPATH} ${tdbc_STUB_LIB_PATH}`\""
6098    for i in $vars; do
6099	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
6100	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
6101	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.[lL][iI][bB]$/-l\1/'`
6102	fi
6103	PKG_LIBS="$PKG_LIBS $i"
6104    done
6105
6106
6107else
6108
6109    vars="${tdbc_STUB_LIB_SPEC}"
6110    for i in $vars; do
6111	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
6112	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
6113	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.[lL][iI][bB]$/-l\1/'`
6114	fi
6115	PKG_LIBS="$PKG_LIBS $i"
6116    done
6117
6118
6119fi
6120
6121    PKG_CFLAGS="$PKG_CFLAGS ${tdbc_CFLAGS}"
6122
6123
6124
6125    vars=""
6126    for i in $vars; do
6127	# check for existence - allows for generic/win/unix VPATH
6128	if test ! -f "${srcdir}/$i" -a ! -f "${srcdir}/generic/$i" \
6129	    -a ! -f "${srcdir}/win/$i" -a ! -f "${srcdir}/unix/$i" \
6130	    -a ! -f "${srcdir}/macosx/$i" \
6131	    ; then
6132	    as_fn_error $? "could not find stub source file '$i'" "$LINENO" 5
6133	fi
6134	PKG_STUB_SOURCES="$PKG_STUB_SOURCES $i"
6135	# this assumes it is in a VPATH dir
6136	i=`basename $i`
6137	# handle user calling this before or after TEA_SETUP_COMPILER
6138	if test x"${OBJEXT}" != x ; then
6139	    j="`echo $i | sed -e 's/\.[^.]*$//'`.${OBJEXT}"
6140	else
6141	    j="`echo $i | sed -e 's/\.[^.]*$//'`.\${OBJEXT}"
6142	fi
6143	PKG_STUB_OBJECTS="$PKG_STUB_OBJECTS $j"
6144    done
6145
6146
6147
6148
6149    vars="library/tdbcpostgres.tcl"
6150    for i in $vars; do
6151	# check for existence, be strict because it is installed
6152	if test ! -f "${srcdir}/$i" ; then
6153	    as_fn_error $? "could not find tcl source file '${srcdir}/$i'" "$LINENO" 5
6154	fi
6155	PKG_TCL_SOURCES="$PKG_TCL_SOURCES $i"
6156    done
6157
6158
6159
6160#--------------------------------------------------------------------
6161# __CHANGE__
6162#
6163# You can add more files to clean if your extension creates any extra
6164# files by extending CLEANFILES.
6165# Add pkgIndex.tcl if it is generated in the Makefile instead of ./configure
6166# and change Makefile.in to move it from CONFIG_CLEAN_FILES to BINARIES var.
6167#
6168# A few miscellaneous platform-specific items:
6169# TEA_ADD_* any platform specific compiler/build info here.
6170#--------------------------------------------------------------------
6171
6172#CLEANFILES="$CLEANFILES pkgIndex.tcl"
6173if test "${TEA_PLATFORM}" = "windows" ; then
6174    # Ensure no empty if clauses
6175    :
6176    #TEA_ADD_SOURCES([win/winFile.c])
6177    #TEA_ADD_INCLUDES([-I\"$(${CYGPATH} ${srcdir}/win)\"])
6178else
6179    # Ensure no empty else clauses
6180    :
6181    #TEA_ADD_SOURCES([unix/unixFile.c])
6182    #TEA_ADD_LIBS([-lsuperfly])
6183fi
6184
6185#--------------------------------------------------------------------
6186# __CHANGE__
6187# Choose which headers you need.  Extension authors should try very
6188# hard to only rely on the Tcl public header files.  Internal headers
6189# contain private data structures and are subject to change without
6190# notice.
6191# This MUST be called after TEA_LOAD_TCLCONFIG / TEA_LOAD_TKCONFIG
6192#--------------------------------------------------------------------
6193
6194
6195    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Tcl public headers" >&5
6196printf %s "checking for Tcl public headers... " >&6; }
6197
6198
6199# Check whether --with-tclinclude was given.
6200if test ${with_tclinclude+y}
6201then :
6202  withval=$with_tclinclude; with_tclinclude=${withval}
6203fi
6204
6205
6206    if test ${ac_cv_c_tclh+y}
6207then :
6208  printf %s "(cached) " >&6
6209else $as_nop
6210
6211	# Use the value from --with-tclinclude, if it was given
6212
6213	if test x"${with_tclinclude}" != x ; then
6214	    if test -f "${with_tclinclude}/tcl.h" ; then
6215		ac_cv_c_tclh=${with_tclinclude}
6216	    else
6217		as_fn_error $? "${with_tclinclude} directory does not contain tcl.h" "$LINENO" 5
6218	    fi
6219	else
6220	    list=""
6221	    if test "`uname -s`" = "Darwin"; then
6222		# If Tcl was built as a framework, attempt to use
6223		# the framework's Headers directory
6224		case ${TCL_DEFS} in
6225		    *TCL_FRAMEWORK*)
6226			list="`ls -d ${TCL_BIN_DIR}/Headers 2>/dev/null`"
6227			;;
6228		esac
6229	    fi
6230
6231	    # Look in the source dir only if Tcl is not installed,
6232	    # and in that situation, look there before installed locations.
6233	    if test -f "${TCL_BIN_DIR}/Makefile" ; then
6234		list="$list `ls -d ${TCL_SRC_DIR}/generic 2>/dev/null`"
6235	    fi
6236
6237	    # Check order: pkg --prefix location, Tcl's --prefix location,
6238	    # relative to directory of tclConfig.sh.
6239
6240	    eval "temp_includedir=${includedir}"
6241	    list="$list \
6242		`ls -d ${temp_includedir}        2>/dev/null` \
6243		`ls -d ${TCL_PREFIX}/include     2>/dev/null` \
6244		`ls -d ${TCL_BIN_DIR}/../include 2>/dev/null`"
6245	    if test "${TEA_PLATFORM}" != "windows" -o "$GCC" = "yes"; then
6246		list="$list /usr/local/include /usr/include"
6247		if test x"${TCL_INCLUDE_SPEC}" != x ; then
6248		    d=`echo "${TCL_INCLUDE_SPEC}" | sed -e 's/^-I//'`
6249		    list="$list `ls -d ${d} 2>/dev/null`"
6250		fi
6251	    fi
6252	    for i in $list ; do
6253		if test -f "$i/tcl.h" ; then
6254		    ac_cv_c_tclh=$i
6255		    break
6256		fi
6257	    done
6258	fi
6259
6260fi
6261
6262
6263    # Print a message based on how we determined the include path
6264
6265    if test x"${ac_cv_c_tclh}" = x ; then
6266	as_fn_error $? "tcl.h not found.  Please specify its location with --with-tclinclude" "$LINENO" 5
6267    else
6268	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${ac_cv_c_tclh}" >&5
6269printf "%s\n" "${ac_cv_c_tclh}" >&6; }
6270    fi
6271
6272    # Convert to a native path and substitute into the output files.
6273
6274    INCLUDE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tclh}`
6275
6276    TCL_INCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
6277
6278
6279
6280#TEA_PRIVATE_TCL_HEADERS
6281
6282#TEA_PUBLIC_TK_HEADERS
6283#TEA_PRIVATE_TK_HEADERS
6284#TEA_PATH_X
6285
6286#--------------------------------------------------------------------
6287# Check whether --enable-threads or --disable-threads was given.
6288# This auto-enables if Tcl was compiled threaded.
6289#--------------------------------------------------------------------
6290
6291
6292    # Check whether --enable-threads was given.
6293if test ${enable_threads+y}
6294then :
6295  enableval=$enable_threads; tcl_ok=$enableval
6296else $as_nop
6297  tcl_ok=yes
6298fi
6299
6300
6301    if test "${enable_threads+set}" = set; then
6302	enableval="$enable_threads"
6303	tcl_ok=$enableval
6304    else
6305	tcl_ok=yes
6306    fi
6307
6308    if test "$tcl_ok" = "yes" -o "${TCL_THREADS}" = 1; then
6309	TCL_THREADS=1
6310
6311	if test "${TEA_PLATFORM}" != "windows" ; then
6312	    # We are always OK on Windows, so check what this platform wants:
6313
6314	    # USE_THREAD_ALLOC tells us to try the special thread-based
6315	    # allocator that significantly reduces lock contention
6316
6317printf "%s\n" "#define USE_THREAD_ALLOC 1" >>confdefs.h
6318
6319
6320printf "%s\n" "#define _REENTRANT 1" >>confdefs.h
6321
6322	    if test "`uname -s`" = "SunOS" ; then
6323
6324printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6325
6326	    fi
6327
6328printf "%s\n" "#define _THREAD_SAFE 1" >>confdefs.h
6329
6330	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_mutex_init in -lpthread" >&5
6331printf %s "checking for pthread_mutex_init in -lpthread... " >&6; }
6332if test ${ac_cv_lib_pthread_pthread_mutex_init+y}
6333then :
6334  printf %s "(cached) " >&6
6335else $as_nop
6336  ac_check_lib_save_LIBS=$LIBS
6337LIBS="-lpthread  $LIBS"
6338cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6339/* end confdefs.h.  */
6340
6341/* Override any GCC internal prototype to avoid an error.
6342   Use char because int might match the return type of a GCC
6343   builtin and then its argument prototype would still apply.  */
6344char pthread_mutex_init ();
6345int
6346main (void)
6347{
6348return pthread_mutex_init ();
6349  ;
6350  return 0;
6351}
6352_ACEOF
6353if ac_fn_c_try_link "$LINENO"
6354then :
6355  ac_cv_lib_pthread_pthread_mutex_init=yes
6356else $as_nop
6357  ac_cv_lib_pthread_pthread_mutex_init=no
6358fi
6359rm -f core conftest.err conftest.$ac_objext conftest.beam \
6360    conftest$ac_exeext conftest.$ac_ext
6361LIBS=$ac_check_lib_save_LIBS
6362fi
6363{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_mutex_init" >&5
6364printf "%s\n" "$ac_cv_lib_pthread_pthread_mutex_init" >&6; }
6365if test "x$ac_cv_lib_pthread_pthread_mutex_init" = xyes
6366then :
6367  tcl_ok=yes
6368else $as_nop
6369  tcl_ok=no
6370fi
6371
6372	    if test "$tcl_ok" = "no"; then
6373		# Check a little harder for __pthread_mutex_init in the same
6374		# library, as some systems hide it there until pthread.h is
6375		# defined.  We could alternatively do an AC_TRY_COMPILE with
6376		# pthread.h, but that will work with libpthread really doesn't
6377		# exist, like AIX 4.2.  [Bug: 4359]
6378		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __pthread_mutex_init in -lpthread" >&5
6379printf %s "checking for __pthread_mutex_init in -lpthread... " >&6; }
6380if test ${ac_cv_lib_pthread___pthread_mutex_init+y}
6381then :
6382  printf %s "(cached) " >&6
6383else $as_nop
6384  ac_check_lib_save_LIBS=$LIBS
6385LIBS="-lpthread  $LIBS"
6386cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6387/* end confdefs.h.  */
6388
6389/* Override any GCC internal prototype to avoid an error.
6390   Use char because int might match the return type of a GCC
6391   builtin and then its argument prototype would still apply.  */
6392char __pthread_mutex_init ();
6393int
6394main (void)
6395{
6396return __pthread_mutex_init ();
6397  ;
6398  return 0;
6399}
6400_ACEOF
6401if ac_fn_c_try_link "$LINENO"
6402then :
6403  ac_cv_lib_pthread___pthread_mutex_init=yes
6404else $as_nop
6405  ac_cv_lib_pthread___pthread_mutex_init=no
6406fi
6407rm -f core conftest.err conftest.$ac_objext conftest.beam \
6408    conftest$ac_exeext conftest.$ac_ext
6409LIBS=$ac_check_lib_save_LIBS
6410fi
6411{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread___pthread_mutex_init" >&5
6412printf "%s\n" "$ac_cv_lib_pthread___pthread_mutex_init" >&6; }
6413if test "x$ac_cv_lib_pthread___pthread_mutex_init" = xyes
6414then :
6415  tcl_ok=yes
6416else $as_nop
6417  tcl_ok=no
6418fi
6419
6420	    fi
6421
6422	    if test "$tcl_ok" = "yes"; then
6423		# The space is needed
6424		THREADS_LIBS=" -lpthread"
6425	    else
6426		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_mutex_init in -lpthreads" >&5
6427printf %s "checking for pthread_mutex_init in -lpthreads... " >&6; }
6428if test ${ac_cv_lib_pthreads_pthread_mutex_init+y}
6429then :
6430  printf %s "(cached) " >&6
6431else $as_nop
6432  ac_check_lib_save_LIBS=$LIBS
6433LIBS="-lpthreads  $LIBS"
6434cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6435/* end confdefs.h.  */
6436
6437/* Override any GCC internal prototype to avoid an error.
6438   Use char because int might match the return type of a GCC
6439   builtin and then its argument prototype would still apply.  */
6440char pthread_mutex_init ();
6441int
6442main (void)
6443{
6444return pthread_mutex_init ();
6445  ;
6446  return 0;
6447}
6448_ACEOF
6449if ac_fn_c_try_link "$LINENO"
6450then :
6451  ac_cv_lib_pthreads_pthread_mutex_init=yes
6452else $as_nop
6453  ac_cv_lib_pthreads_pthread_mutex_init=no
6454fi
6455rm -f core conftest.err conftest.$ac_objext conftest.beam \
6456    conftest$ac_exeext conftest.$ac_ext
6457LIBS=$ac_check_lib_save_LIBS
6458fi
6459{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_mutex_init" >&5
6460printf "%s\n" "$ac_cv_lib_pthreads_pthread_mutex_init" >&6; }
6461if test "x$ac_cv_lib_pthreads_pthread_mutex_init" = xyes
6462then :
6463  tcl_ok=yes
6464else $as_nop
6465  tcl_ok=no
6466fi
6467
6468		if test "$tcl_ok" = "yes"; then
6469		    # The space is needed
6470		    THREADS_LIBS=" -lpthreads"
6471		else
6472		    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_mutex_init in -lc" >&5
6473printf %s "checking for pthread_mutex_init in -lc... " >&6; }
6474if test ${ac_cv_lib_c_pthread_mutex_init+y}
6475then :
6476  printf %s "(cached) " >&6
6477else $as_nop
6478  ac_check_lib_save_LIBS=$LIBS
6479LIBS="-lc  $LIBS"
6480cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6481/* end confdefs.h.  */
6482
6483/* Override any GCC internal prototype to avoid an error.
6484   Use char because int might match the return type of a GCC
6485   builtin and then its argument prototype would still apply.  */
6486char pthread_mutex_init ();
6487int
6488main (void)
6489{
6490return pthread_mutex_init ();
6491  ;
6492  return 0;
6493}
6494_ACEOF
6495if ac_fn_c_try_link "$LINENO"
6496then :
6497  ac_cv_lib_c_pthread_mutex_init=yes
6498else $as_nop
6499  ac_cv_lib_c_pthread_mutex_init=no
6500fi
6501rm -f core conftest.err conftest.$ac_objext conftest.beam \
6502    conftest$ac_exeext conftest.$ac_ext
6503LIBS=$ac_check_lib_save_LIBS
6504fi
6505{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_pthread_mutex_init" >&5
6506printf "%s\n" "$ac_cv_lib_c_pthread_mutex_init" >&6; }
6507if test "x$ac_cv_lib_c_pthread_mutex_init" = xyes
6508then :
6509  tcl_ok=yes
6510else $as_nop
6511  tcl_ok=no
6512fi
6513
6514		    if test "$tcl_ok" = "no"; then
6515			{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_mutex_init in -lc_r" >&5
6516printf %s "checking for pthread_mutex_init in -lc_r... " >&6; }
6517if test ${ac_cv_lib_c_r_pthread_mutex_init+y}
6518then :
6519  printf %s "(cached) " >&6
6520else $as_nop
6521  ac_check_lib_save_LIBS=$LIBS
6522LIBS="-lc_r  $LIBS"
6523cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6524/* end confdefs.h.  */
6525
6526/* Override any GCC internal prototype to avoid an error.
6527   Use char because int might match the return type of a GCC
6528   builtin and then its argument prototype would still apply.  */
6529char pthread_mutex_init ();
6530int
6531main (void)
6532{
6533return pthread_mutex_init ();
6534  ;
6535  return 0;
6536}
6537_ACEOF
6538if ac_fn_c_try_link "$LINENO"
6539then :
6540  ac_cv_lib_c_r_pthread_mutex_init=yes
6541else $as_nop
6542  ac_cv_lib_c_r_pthread_mutex_init=no
6543fi
6544rm -f core conftest.err conftest.$ac_objext conftest.beam \
6545    conftest$ac_exeext conftest.$ac_ext
6546LIBS=$ac_check_lib_save_LIBS
6547fi
6548{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_mutex_init" >&5
6549printf "%s\n" "$ac_cv_lib_c_r_pthread_mutex_init" >&6; }
6550if test "x$ac_cv_lib_c_r_pthread_mutex_init" = xyes
6551then :
6552  tcl_ok=yes
6553else $as_nop
6554  tcl_ok=no
6555fi
6556
6557			if test "$tcl_ok" = "yes"; then
6558			    # The space is needed
6559			    THREADS_LIBS=" -pthread"
6560			else
6561			    TCL_THREADS=0
6562			    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Do not know how to find pthread lib on your system - thread support disabled" >&5
6563printf "%s\n" "$as_me: WARNING: Do not know how to find pthread lib on your system - thread support disabled" >&2;}
6564			fi
6565		    fi
6566		fi
6567	    fi
6568	fi
6569    else
6570	TCL_THREADS=0
6571    fi
6572    # Do checking message here to not mess up interleaved configure output
6573    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for building with threads" >&5
6574printf %s "checking for building with threads... " >&6; }
6575    if test "${TCL_THREADS}" = 1; then
6576
6577printf "%s\n" "#define TCL_THREADS 1" >>confdefs.h
6578
6579	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5
6580printf "%s\n" "yes (default)" >&6; }
6581    else
6582	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6583printf "%s\n" "no" >&6; }
6584    fi
6585    # TCL_THREADS sanity checking.  See if our request for building with
6586    # threads is the same as the way Tcl was built.  If not, warn the user.
6587    case ${TCL_DEFS} in
6588	*THREADS=1*)
6589	    if test "${TCL_THREADS}" = "0"; then
6590		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING:
6591    Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
6592    that IS thread-enabled.  It is recommended to use --enable-threads." >&5
6593printf "%s\n" "$as_me: WARNING:
6594    Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
6595    that IS thread-enabled.  It is recommended to use --enable-threads." >&2;}
6596	    fi
6597	    ;;
6598    esac
6599
6600
6601
6602#--------------------------------------------------------------------
6603# The statement below defines a collection of symbols related to
6604# building as a shared library instead of a static library.
6605#--------------------------------------------------------------------
6606
6607
6608    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to build libraries" >&5
6609printf %s "checking how to build libraries... " >&6; }
6610    # Check whether --enable-shared was given.
6611if test ${enable_shared+y}
6612then :
6613  enableval=$enable_shared; shared_ok=$enableval
6614else $as_nop
6615  shared_ok=yes
6616fi
6617
6618
6619    if test "${enable_shared+set}" = set; then
6620	enableval="$enable_shared"
6621	shared_ok=$enableval
6622    else
6623	shared_ok=yes
6624    fi
6625
6626    # Check whether --enable-stubs was given.
6627if test ${enable_stubs+y}
6628then :
6629  enableval=$enable_stubs; stubs_ok=$enableval
6630else $as_nop
6631  stubs_ok=yes
6632fi
6633
6634
6635    if test "${enable_stubs+set}" = set; then
6636	enableval="$enable_stubs"
6637	stubs_ok=$enableval
6638    else
6639	stubs_ok=yes
6640    fi
6641
6642    # Stubs are always enabled for shared builds
6643    if test "$shared_ok" = "yes" ; then
6644	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: shared" >&5
6645printf "%s\n" "shared" >&6; }
6646	SHARED_BUILD=1
6647        STUBS_BUILD=1
6648    else
6649	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: static" >&5
6650printf "%s\n" "static" >&6; }
6651	SHARED_BUILD=0
6652
6653printf "%s\n" "#define STATIC_BUILD 1" >>confdefs.h
6654
6655        if test "$stubs_ok" = "yes" ; then
6656          STUBS_BUILD=1
6657        else
6658          STUBS_BUILD=0
6659        fi
6660    fi
6661    if test "${STUBS_BUILD}" = "1" ; then
6662
6663printf "%s\n" "#define USE_TCL_STUBS 1" >>confdefs.h
6664
6665
6666printf "%s\n" "#define USE_TCLOO_STUBS 1" >>confdefs.h
6667
6668      if test "${TEA_WINDOWINGSYSTEM}" != ""; then
6669
6670printf "%s\n" "#define USE_TK_STUBS 1" >>confdefs.h
6671
6672      fi
6673    fi
6674
6675
6676
6677
6678
6679#--------------------------------------------------------------------
6680# This macro figures out what flags to use with the compiler/linker
6681# when building shared/static debug/optimized objects.  This information
6682# can be taken from the tclConfig.sh file, but this figures it all out.
6683#--------------------------------------------------------------------
6684
6685if test -n "$ac_tool_prefix"; then
6686  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6687set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6688{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6689printf %s "checking for $ac_word... " >&6; }
6690if test ${ac_cv_prog_RANLIB+y}
6691then :
6692  printf %s "(cached) " >&6
6693else $as_nop
6694  if test -n "$RANLIB"; then
6695  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6696else
6697as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6698for as_dir in $PATH
6699do
6700  IFS=$as_save_IFS
6701  case $as_dir in #(((
6702    '') as_dir=./ ;;
6703    */) ;;
6704    *) as_dir=$as_dir/ ;;
6705  esac
6706    for ac_exec_ext in '' $ac_executable_extensions; do
6707  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6708    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6709    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6710    break 2
6711  fi
6712done
6713  done
6714IFS=$as_save_IFS
6715
6716fi
6717fi
6718RANLIB=$ac_cv_prog_RANLIB
6719if test -n "$RANLIB"; then
6720  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6721printf "%s\n" "$RANLIB" >&6; }
6722else
6723  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6724printf "%s\n" "no" >&6; }
6725fi
6726
6727
6728fi
6729if test -z "$ac_cv_prog_RANLIB"; then
6730  ac_ct_RANLIB=$RANLIB
6731  # Extract the first word of "ranlib", so it can be a program name with args.
6732set dummy ranlib; ac_word=$2
6733{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6734printf %s "checking for $ac_word... " >&6; }
6735if test ${ac_cv_prog_ac_ct_RANLIB+y}
6736then :
6737  printf %s "(cached) " >&6
6738else $as_nop
6739  if test -n "$ac_ct_RANLIB"; then
6740  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6741else
6742as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6743for as_dir in $PATH
6744do
6745  IFS=$as_save_IFS
6746  case $as_dir in #(((
6747    '') as_dir=./ ;;
6748    */) ;;
6749    *) as_dir=$as_dir/ ;;
6750  esac
6751    for ac_exec_ext in '' $ac_executable_extensions; do
6752  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6753    ac_cv_prog_ac_ct_RANLIB="ranlib"
6754    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6755    break 2
6756  fi
6757done
6758  done
6759IFS=$as_save_IFS
6760
6761fi
6762fi
6763ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6764if test -n "$ac_ct_RANLIB"; then
6765  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6766printf "%s\n" "$ac_ct_RANLIB" >&6; }
6767else
6768  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6769printf "%s\n" "no" >&6; }
6770fi
6771
6772  if test "x$ac_ct_RANLIB" = x; then
6773    RANLIB=":"
6774  else
6775    case $cross_compiling:$ac_tool_warned in
6776yes:)
6777{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6778printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6779ac_tool_warned=yes ;;
6780esac
6781    RANLIB=$ac_ct_RANLIB
6782  fi
6783else
6784  RANLIB="$ac_cv_prog_RANLIB"
6785fi
6786
6787
6788
6789
6790    # Step 0.a: Enable 64 bit support?
6791
6792    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if 64bit support is requested" >&5
6793printf %s "checking if 64bit support is requested... " >&6; }
6794    # Check whether --enable-64bit was given.
6795if test ${enable_64bit+y}
6796then :
6797  enableval=$enable_64bit; do64bit=$enableval
6798else $as_nop
6799  do64bit=no
6800fi
6801
6802    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $do64bit" >&5
6803printf "%s\n" "$do64bit" >&6; }
6804
6805    # Step 0.b: Enable Solaris 64 bit VIS support?
6806
6807    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if 64bit Sparc VIS support is requested" >&5
6808printf %s "checking if 64bit Sparc VIS support is requested... " >&6; }
6809    # Check whether --enable-64bit-vis was given.
6810if test ${enable_64bit_vis+y}
6811then :
6812  enableval=$enable_64bit_vis; do64bitVIS=$enableval
6813else $as_nop
6814  do64bitVIS=no
6815fi
6816
6817    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $do64bitVIS" >&5
6818printf "%s\n" "$do64bitVIS" >&6; }
6819    # Force 64bit on with VIS
6820    if test "$do64bitVIS" = "yes"
6821then :
6822  do64bit=yes
6823fi
6824
6825    # Step 0.c: Check if visibility support is available. Do this here so
6826    # that platform specific alternatives can be used below if this fails.
6827
6828    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler supports visibility \"hidden\"" >&5
6829printf %s "checking if compiler supports visibility \"hidden\"... " >&6; }
6830if test ${tcl_cv_cc_visibility_hidden+y}
6831then :
6832  printf %s "(cached) " >&6
6833else $as_nop
6834
6835	hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -Werror"
6836	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6837/* end confdefs.h.  */
6838
6839	    extern __attribute__((__visibility__("hidden"))) void f(void);
6840	    void f(void) {}
6841int
6842main (void)
6843{
6844f();
6845  ;
6846  return 0;
6847}
6848_ACEOF
6849if ac_fn_c_try_link "$LINENO"
6850then :
6851  tcl_cv_cc_visibility_hidden=yes
6852else $as_nop
6853  tcl_cv_cc_visibility_hidden=no
6854fi
6855rm -f core conftest.err conftest.$ac_objext conftest.beam \
6856    conftest$ac_exeext conftest.$ac_ext
6857	CFLAGS=$hold_cflags
6858fi
6859{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_visibility_hidden" >&5
6860printf "%s\n" "$tcl_cv_cc_visibility_hidden" >&6; }
6861    if test $tcl_cv_cc_visibility_hidden = yes
6862then :
6863
6864
6865printf "%s\n" "#define MODULE_SCOPE extern __attribute__((__visibility__(\"hidden\")))" >>confdefs.h
6866
6867
6868printf "%s\n" "#define HAVE_HIDDEN 1" >>confdefs.h
6869
6870
6871fi
6872
6873    # Step 0.d: Disable -rpath support?
6874
6875    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if rpath support is requested" >&5
6876printf %s "checking if rpath support is requested... " >&6; }
6877    # Check whether --enable-rpath was given.
6878if test ${enable_rpath+y}
6879then :
6880  enableval=$enable_rpath; doRpath=$enableval
6881else $as_nop
6882  doRpath=yes
6883fi
6884
6885    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $doRpath" >&5
6886printf "%s\n" "$doRpath" >&6; }
6887
6888    # Set the variable "system" to hold the name and version number
6889    # for the system.
6890
6891
6892    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking system version" >&5
6893printf %s "checking system version... " >&6; }
6894if test ${tcl_cv_sys_version+y}
6895then :
6896  printf %s "(cached) " >&6
6897else $as_nop
6898
6899	# TEA specific:
6900	if test "${TEA_PLATFORM}" = "windows" ; then
6901	    tcl_cv_sys_version=windows
6902	else
6903	    tcl_cv_sys_version=`uname -s`-`uname -r`
6904	    if test "$?" -ne 0 ; then
6905		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: can't find uname command" >&5
6906printf "%s\n" "$as_me: WARNING: can't find uname command" >&2;}
6907		tcl_cv_sys_version=unknown
6908	    else
6909		if test "`uname -s`" = "AIX" ; then
6910		    tcl_cv_sys_version=AIX-`uname -v`.`uname -r`
6911		fi
6912		if test "`uname -s`" = "NetBSD" -a -f /etc/debian_version ; then
6913		    tcl_cv_sys_version=NetBSD-Debian
6914		fi
6915	    fi
6916	fi
6917
6918fi
6919{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_sys_version" >&5
6920printf "%s\n" "$tcl_cv_sys_version" >&6; }
6921    system=$tcl_cv_sys_version
6922
6923
6924    # Require ranlib early so we can override it in special cases below.
6925
6926
6927
6928    # Set configuration options based on system name and version.
6929    # This is similar to Tcl's unix/tcl.m4 except that we've added a
6930    # "windows" case and removed some core-only vars.
6931
6932    do64bit_ok=no
6933    # default to '{$LIBS}' and set to "" on per-platform necessary basis
6934    SHLIB_LD_LIBS='${LIBS}'
6935    # When ld needs options to work in 64-bit mode, put them in
6936    # LDFLAGS_ARCH so they eventually end up in LDFLAGS even if [load]
6937    # is disabled by the user. [Bug 1016796]
6938    LDFLAGS_ARCH=""
6939    UNSHARED_LIB_SUFFIX=""
6940    # TEA specific: use PACKAGE_VERSION instead of VERSION
6941    TCL_TRIM_DOTS='`echo ${PACKAGE_VERSION} | tr -d .`'
6942    ECHO_VERSION='`echo ${PACKAGE_VERSION}`'
6943    TCL_LIB_VERSIONS_OK=ok
6944    CFLAGS_DEBUG=-g
6945    if test "$GCC" = yes
6946then :
6947
6948	CFLAGS_OPTIMIZE=-O2
6949	CFLAGS_WARNING="-Wall"
6950
6951else $as_nop
6952
6953	CFLAGS_OPTIMIZE=-O
6954	CFLAGS_WARNING=""
6955
6956fi
6957    if test -n "$ac_tool_prefix"; then
6958  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6959set dummy ${ac_tool_prefix}ar; ac_word=$2
6960{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6961printf %s "checking for $ac_word... " >&6; }
6962if test ${ac_cv_prog_AR+y}
6963then :
6964  printf %s "(cached) " >&6
6965else $as_nop
6966  if test -n "$AR"; then
6967  ac_cv_prog_AR="$AR" # Let the user override the test.
6968else
6969as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6970for as_dir in $PATH
6971do
6972  IFS=$as_save_IFS
6973  case $as_dir in #(((
6974    '') as_dir=./ ;;
6975    */) ;;
6976    *) as_dir=$as_dir/ ;;
6977  esac
6978    for ac_exec_ext in '' $ac_executable_extensions; do
6979  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6980    ac_cv_prog_AR="${ac_tool_prefix}ar"
6981    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6982    break 2
6983  fi
6984done
6985  done
6986IFS=$as_save_IFS
6987
6988fi
6989fi
6990AR=$ac_cv_prog_AR
6991if test -n "$AR"; then
6992  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6993printf "%s\n" "$AR" >&6; }
6994else
6995  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6996printf "%s\n" "no" >&6; }
6997fi
6998
6999
7000fi
7001if test -z "$ac_cv_prog_AR"; then
7002  ac_ct_AR=$AR
7003  # Extract the first word of "ar", so it can be a program name with args.
7004set dummy ar; ac_word=$2
7005{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7006printf %s "checking for $ac_word... " >&6; }
7007if test ${ac_cv_prog_ac_ct_AR+y}
7008then :
7009  printf %s "(cached) " >&6
7010else $as_nop
7011  if test -n "$ac_ct_AR"; then
7012  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7013else
7014as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7015for as_dir in $PATH
7016do
7017  IFS=$as_save_IFS
7018  case $as_dir in #(((
7019    '') as_dir=./ ;;
7020    */) ;;
7021    *) as_dir=$as_dir/ ;;
7022  esac
7023    for ac_exec_ext in '' $ac_executable_extensions; do
7024  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
7025    ac_cv_prog_ac_ct_AR="ar"
7026    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
7027    break 2
7028  fi
7029done
7030  done
7031IFS=$as_save_IFS
7032
7033fi
7034fi
7035ac_ct_AR=$ac_cv_prog_ac_ct_AR
7036if test -n "$ac_ct_AR"; then
7037  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
7038printf "%s\n" "$ac_ct_AR" >&6; }
7039else
7040  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7041printf "%s\n" "no" >&6; }
7042fi
7043
7044  if test "x$ac_ct_AR" = x; then
7045    AR=""
7046  else
7047    case $cross_compiling:$ac_tool_warned in
7048yes:)
7049{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7050printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7051ac_tool_warned=yes ;;
7052esac
7053    AR=$ac_ct_AR
7054  fi
7055else
7056  AR="$ac_cv_prog_AR"
7057fi
7058
7059    STLIB_LD='${AR} cr'
7060    LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH"
7061    if test "x$SHLIB_VERSION" = x
7062then :
7063  SHLIB_VERSION=""
7064else $as_nop
7065  SHLIB_VERSION=".$SHLIB_VERSION"
7066fi
7067    case $system in
7068	# TEA specific:
7069	windows)
7070	    MACHINE="X86"
7071	    if test "$do64bit" != "no" ; then
7072		case "$do64bit" in
7073		    amd64|x64|yes)
7074			MACHINE="AMD64" ; # default to AMD64 64-bit build
7075			;;
7076		    ia64)
7077			MACHINE="IA64"
7078			;;
7079		esac
7080	    fi
7081
7082	    if test "$GCC" != "yes" ; then
7083	        if test "${SHARED_BUILD}" = "0" ; then
7084		    runtime=-MT
7085	        else
7086		    runtime=-MD
7087	        fi
7088	        case "x`echo \${VisualStudioVersion}`" in
7089	            x1[4-9]*)
7090		        lflags="${lflags} -nodefaultlib:libucrt.lib"
7091
7092    vars="ucrt.lib"
7093    for i in $vars; do
7094	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
7095	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
7096	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.[lL][iI][bB]$/-l\1/'`
7097	fi
7098	PKG_LIBS="$PKG_LIBS $i"
7099    done
7100
7101
7102	            ;;
7103	            *)
7104	            ;;
7105	        esac
7106
7107                if test "$do64bit" != "no" ; then
7108		    CC="cl.exe"
7109		    RC="rc.exe"
7110		    lflags="${lflags} -nologo -MACHINE:${MACHINE} "
7111		    LINKBIN="link.exe"
7112		    CFLAGS_DEBUG="-nologo -Zi -Od -W3 ${runtime}d"
7113		    CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
7114		    # Avoid 'unresolved external symbol __security_cookie'
7115		    # errors, c.f. http://support.microsoft.com/?id=894573
7116
7117    vars="bufferoverflowU.lib"
7118    for i in $vars; do
7119	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
7120	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
7121	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.[lL][iI][bB]$/-l\1/'`
7122	fi
7123	PKG_LIBS="$PKG_LIBS $i"
7124    done
7125
7126
7127		else
7128		    RC="rc"
7129		    lflags="${lflags} -nologo"
7130		    LINKBIN="link"
7131		    CFLAGS_DEBUG="-nologo -Z7 -Od -W3 -WX ${runtime}d"
7132		    CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
7133		fi
7134	    fi
7135
7136	    if test "$GCC" = "yes"; then
7137		# mingw gcc mode
7138		if test -n "$ac_tool_prefix"; then
7139  # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
7140set dummy ${ac_tool_prefix}windres; ac_word=$2
7141{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7142printf %s "checking for $ac_word... " >&6; }
7143if test ${ac_cv_prog_RC+y}
7144then :
7145  printf %s "(cached) " >&6
7146else $as_nop
7147  if test -n "$RC"; then
7148  ac_cv_prog_RC="$RC" # Let the user override the test.
7149else
7150as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7151for as_dir in $PATH
7152do
7153  IFS=$as_save_IFS
7154  case $as_dir in #(((
7155    '') as_dir=./ ;;
7156    */) ;;
7157    *) as_dir=$as_dir/ ;;
7158  esac
7159    for ac_exec_ext in '' $ac_executable_extensions; do
7160  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
7161    ac_cv_prog_RC="${ac_tool_prefix}windres"
7162    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
7163    break 2
7164  fi
7165done
7166  done
7167IFS=$as_save_IFS
7168
7169fi
7170fi
7171RC=$ac_cv_prog_RC
7172if test -n "$RC"; then
7173  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RC" >&5
7174printf "%s\n" "$RC" >&6; }
7175else
7176  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7177printf "%s\n" "no" >&6; }
7178fi
7179
7180
7181fi
7182if test -z "$ac_cv_prog_RC"; then
7183  ac_ct_RC=$RC
7184  # Extract the first word of "windres", so it can be a program name with args.
7185set dummy windres; ac_word=$2
7186{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7187printf %s "checking for $ac_word... " >&6; }
7188if test ${ac_cv_prog_ac_ct_RC+y}
7189then :
7190  printf %s "(cached) " >&6
7191else $as_nop
7192  if test -n "$ac_ct_RC"; then
7193  ac_cv_prog_ac_ct_RC="$ac_ct_RC" # Let the user override the test.
7194else
7195as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7196for as_dir in $PATH
7197do
7198  IFS=$as_save_IFS
7199  case $as_dir in #(((
7200    '') as_dir=./ ;;
7201    */) ;;
7202    *) as_dir=$as_dir/ ;;
7203  esac
7204    for ac_exec_ext in '' $ac_executable_extensions; do
7205  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
7206    ac_cv_prog_ac_ct_RC="windres"
7207    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
7208    break 2
7209  fi
7210done
7211  done
7212IFS=$as_save_IFS
7213
7214fi
7215fi
7216ac_ct_RC=$ac_cv_prog_ac_ct_RC
7217if test -n "$ac_ct_RC"; then
7218  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RC" >&5
7219printf "%s\n" "$ac_ct_RC" >&6; }
7220else
7221  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7222printf "%s\n" "no" >&6; }
7223fi
7224
7225  if test "x$ac_ct_RC" = x; then
7226    RC=""
7227  else
7228    case $cross_compiling:$ac_tool_warned in
7229yes:)
7230{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7231printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7232ac_tool_warned=yes ;;
7233esac
7234    RC=$ac_ct_RC
7235  fi
7236else
7237  RC="$ac_cv_prog_RC"
7238fi
7239
7240		CFLAGS_DEBUG="-g"
7241		CFLAGS_OPTIMIZE="-O2 -fomit-frame-pointer"
7242		SHLIB_LD='${CC} -shared'
7243		UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
7244		LDFLAGS_CONSOLE="-wl,--subsystem,console ${lflags}"
7245		LDFLAGS_WINDOW="-wl,--subsystem,windows ${lflags}"
7246
7247		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cross-compile version of gcc" >&5
7248printf %s "checking for cross-compile version of gcc... " >&6; }
7249if test ${ac_cv_cross+y}
7250then :
7251  printf %s "(cached) " >&6
7252else $as_nop
7253  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7254/* end confdefs.h.  */
7255
7256			    #ifdef _WIN32
7257				#error cross-compiler
7258			    #endif
7259
7260int
7261main (void)
7262{
7263
7264  ;
7265  return 0;
7266}
7267_ACEOF
7268if ac_fn_c_try_compile "$LINENO"
7269then :
7270  ac_cv_cross=yes
7271else $as_nop
7272  ac_cv_cross=no
7273fi
7274rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7275
7276fi
7277{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cross" >&5
7278printf "%s\n" "$ac_cv_cross" >&6; }
7279		      if test "$ac_cv_cross" = "yes"; then
7280			case "$do64bit" in
7281			    amd64|x64|yes)
7282				CC="x86_64-w64-mingw32-${CC}"
7283				LD="x86_64-w64-mingw32-ld"
7284				AR="x86_64-w64-mingw32-ar"
7285				RANLIB="x86_64-w64-mingw32-ranlib"
7286				RC="x86_64-w64-mingw32-windres"
7287			    ;;
7288			    *)
7289				CC="i686-w64-mingw32-${CC}"
7290				LD="i686-w64-mingw32-ld"
7291				AR="i686-w64-mingw32-ar"
7292				RANLIB="i686-w64-mingw32-ranlib"
7293				RC="i686-w64-mingw32-windres"
7294			    ;;
7295			esac
7296		fi
7297
7298	    else
7299		SHLIB_LD="${LINKBIN} -dll ${lflags}"
7300		# link -lib only works when -lib is the first arg
7301		STLIB_LD="${LINKBIN} -lib ${lflags}"
7302		UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.lib'
7303		PATHTYPE=-w
7304		# For information on what debugtype is most useful, see:
7305		# http://msdn.microsoft.com/library/en-us/dnvc60/html/gendepdebug.asp
7306		# and also
7307		# http://msdn2.microsoft.com/en-us/library/y0zzbyt4%28VS.80%29.aspx
7308		# This essentially turns it all on.
7309		LDFLAGS_DEBUG="-debug -debugtype:cv"
7310		LDFLAGS_OPTIMIZE="-release"
7311		LDFLAGS_CONSOLE="-link -subsystem:console ${lflags}"
7312		LDFLAGS_WINDOW="-link -subsystem:windows ${lflags}"
7313	    fi
7314
7315	    SHLIB_SUFFIX=".dll"
7316	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.dll'
7317
7318	    TCL_LIB_VERSIONS_OK=nodots
7319    	    ;;
7320	AIX-*)
7321	    if test "$GCC" != "yes"
7322then :
7323
7324		# AIX requires the _r compiler when gcc isn't being used
7325		case "${CC}" in
7326		    *_r|*_r\ *)
7327			# ok ...
7328			;;
7329		    *)
7330			# Make sure only first arg gets _r
7331		    	CC=`echo "$CC" | sed -e 's/^\([^ ]*\)/\1_r/'`
7332			;;
7333		esac
7334		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Using $CC for compiling with threads" >&5
7335printf "%s\n" "Using $CC for compiling with threads" >&6; }
7336
7337fi
7338	    LIBS="$LIBS -lc"
7339	    SHLIB_CFLAGS=""
7340	    SHLIB_SUFFIX=".so"
7341
7342	    LD_LIBRARY_PATH_VAR="LIBPATH"
7343
7344	    # Check to enable 64-bit flags for compiler/linker
7345	    if test "$do64bit" = yes
7346then :
7347
7348		if test "$GCC" = yes
7349then :
7350
7351		    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC on $system" >&5
7352printf "%s\n" "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
7353
7354else $as_nop
7355
7356		    do64bit_ok=yes
7357		    CFLAGS="$CFLAGS -q64"
7358		    LDFLAGS_ARCH="-q64"
7359		    RANLIB="${RANLIB} -X64"
7360		    AR="${AR} -X64"
7361		    SHLIB_LD_FLAGS="-b64"
7362
7363fi
7364
7365fi
7366
7367	    if test "`uname -m`" = ia64
7368then :
7369
7370		# AIX-5 uses ELF style dynamic libraries on IA-64, but not PPC
7371		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
7372		if test "$GCC" = yes
7373then :
7374
7375		    CC_SEARCH_FLAGS='"-Wl,-R,${LIB_RUNTIME_DIR}"'
7376
7377else $as_nop
7378
7379		    CC_SEARCH_FLAGS='"-R${LIB_RUNTIME_DIR}"'
7380
7381fi
7382		LD_SEARCH_FLAGS='-R "${LIB_RUNTIME_DIR}"'
7383
7384else $as_nop
7385
7386		if test "$GCC" = yes
7387then :
7388
7389		    SHLIB_LD='${CC} -shared -Wl,-bexpall'
7390
7391else $as_nop
7392
7393		    SHLIB_LD="/bin/ld -bhalt:4 -bM:SRE -bexpall -H512 -T512 -bnoentry"
7394		    LDFLAGS="$LDFLAGS -brtl"
7395
7396fi
7397		SHLIB_LD="${SHLIB_LD} ${SHLIB_LD_FLAGS}"
7398		CC_SEARCH_FLAGS='"-L${LIB_RUNTIME_DIR}"'
7399		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
7400
7401fi
7402	    ;;
7403	BeOS*)
7404	    SHLIB_CFLAGS="-fPIC"
7405	    SHLIB_LD='${CC} -nostart'
7406	    SHLIB_SUFFIX=".so"
7407
7408	    #-----------------------------------------------------------
7409	    # Check for inet_ntoa in -lbind, for BeOS (which also needs
7410	    # -lsocket, even if the network functions are in -lnet which
7411	    # is always linked to, for compatibility.
7412	    #-----------------------------------------------------------
7413	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_ntoa in -lbind" >&5
7414printf %s "checking for inet_ntoa in -lbind... " >&6; }
7415if test ${ac_cv_lib_bind_inet_ntoa+y}
7416then :
7417  printf %s "(cached) " >&6
7418else $as_nop
7419  ac_check_lib_save_LIBS=$LIBS
7420LIBS="-lbind  $LIBS"
7421cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7422/* end confdefs.h.  */
7423
7424/* Override any GCC internal prototype to avoid an error.
7425   Use char because int might match the return type of a GCC
7426   builtin and then its argument prototype would still apply.  */
7427char inet_ntoa ();
7428int
7429main (void)
7430{
7431return inet_ntoa ();
7432  ;
7433  return 0;
7434}
7435_ACEOF
7436if ac_fn_c_try_link "$LINENO"
7437then :
7438  ac_cv_lib_bind_inet_ntoa=yes
7439else $as_nop
7440  ac_cv_lib_bind_inet_ntoa=no
7441fi
7442rm -f core conftest.err conftest.$ac_objext conftest.beam \
7443    conftest$ac_exeext conftest.$ac_ext
7444LIBS=$ac_check_lib_save_LIBS
7445fi
7446{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_inet_ntoa" >&5
7447printf "%s\n" "$ac_cv_lib_bind_inet_ntoa" >&6; }
7448if test "x$ac_cv_lib_bind_inet_ntoa" = xyes
7449then :
7450  LIBS="$LIBS -lbind -lsocket"
7451fi
7452
7453	    ;;
7454	BSD/OS-2.1*|BSD/OS-3*)
7455	    SHLIB_CFLAGS=""
7456	    SHLIB_LD="shlicc -r"
7457	    SHLIB_SUFFIX=".so"
7458	    CC_SEARCH_FLAGS=""
7459	    LD_SEARCH_FLAGS=""
7460	    ;;
7461	BSD/OS-4.*)
7462	    SHLIB_CFLAGS="-export-dynamic -fPIC"
7463	    SHLIB_LD='${CC} -shared'
7464	    SHLIB_SUFFIX=".so"
7465	    LDFLAGS="$LDFLAGS -export-dynamic"
7466	    CC_SEARCH_FLAGS=""
7467	    LD_SEARCH_FLAGS=""
7468	    ;;
7469	CYGWIN_*)
7470	    SHLIB_CFLAGS=""
7471	    SHLIB_LD='${CC} -shared'
7472	    SHLIB_SUFFIX=".dll"
7473	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -Wl,--out-implib,\$@.a"
7474	    EXEEXT=".exe"
7475	    do64bit_ok=yes
7476	    CC_SEARCH_FLAGS=""
7477	    LD_SEARCH_FLAGS=""
7478	    ;;
7479	dgux*)
7480	    SHLIB_CFLAGS="-K PIC"
7481	    SHLIB_LD='${CC} -G'
7482	    SHLIB_LD_LIBS=""
7483	    SHLIB_SUFFIX=".so"
7484	    CC_SEARCH_FLAGS=""
7485	    LD_SEARCH_FLAGS=""
7486	    ;;
7487	Haiku*)
7488	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
7489	    SHLIB_CFLAGS="-fPIC"
7490	    SHLIB_SUFFIX=".so"
7491	    SHLIB_LD='${CC} ${CFLAGS} ${LDFLAGS} -shared'
7492	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_ntoa in -lnetwork" >&5
7493printf %s "checking for inet_ntoa in -lnetwork... " >&6; }
7494if test ${ac_cv_lib_network_inet_ntoa+y}
7495then :
7496  printf %s "(cached) " >&6
7497else $as_nop
7498  ac_check_lib_save_LIBS=$LIBS
7499LIBS="-lnetwork  $LIBS"
7500cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7501/* end confdefs.h.  */
7502
7503/* Override any GCC internal prototype to avoid an error.
7504   Use char because int might match the return type of a GCC
7505   builtin and then its argument prototype would still apply.  */
7506char inet_ntoa ();
7507int
7508main (void)
7509{
7510return inet_ntoa ();
7511  ;
7512  return 0;
7513}
7514_ACEOF
7515if ac_fn_c_try_link "$LINENO"
7516then :
7517  ac_cv_lib_network_inet_ntoa=yes
7518else $as_nop
7519  ac_cv_lib_network_inet_ntoa=no
7520fi
7521rm -f core conftest.err conftest.$ac_objext conftest.beam \
7522    conftest$ac_exeext conftest.$ac_ext
7523LIBS=$ac_check_lib_save_LIBS
7524fi
7525{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_inet_ntoa" >&5
7526printf "%s\n" "$ac_cv_lib_network_inet_ntoa" >&6; }
7527if test "x$ac_cv_lib_network_inet_ntoa" = xyes
7528then :
7529  LIBS="$LIBS -lnetwork"
7530fi
7531
7532	    ;;
7533	HP-UX-*.11.*)
7534	    # Use updated header definitions where possible
7535
7536printf "%s\n" "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h
7537
7538	    # TEA specific: Needed by Tcl, but not most extensions
7539	    #AC_DEFINE(_XOPEN_SOURCE, 1, [Do we want to use the XOPEN network library?])
7540	    #LIBS="$LIBS -lxnet"               # Use the XOPEN network library
7541
7542	    if test "`uname -m`" = ia64
7543then :
7544
7545		SHLIB_SUFFIX=".so"
7546
7547else $as_nop
7548
7549		SHLIB_SUFFIX=".sl"
7550
7551fi
7552	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
7553printf %s "checking for shl_load in -ldld... " >&6; }
7554if test ${ac_cv_lib_dld_shl_load+y}
7555then :
7556  printf %s "(cached) " >&6
7557else $as_nop
7558  ac_check_lib_save_LIBS=$LIBS
7559LIBS="-ldld  $LIBS"
7560cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7561/* end confdefs.h.  */
7562
7563/* Override any GCC internal prototype to avoid an error.
7564   Use char because int might match the return type of a GCC
7565   builtin and then its argument prototype would still apply.  */
7566char shl_load ();
7567int
7568main (void)
7569{
7570return shl_load ();
7571  ;
7572  return 0;
7573}
7574_ACEOF
7575if ac_fn_c_try_link "$LINENO"
7576then :
7577  ac_cv_lib_dld_shl_load=yes
7578else $as_nop
7579  ac_cv_lib_dld_shl_load=no
7580fi
7581rm -f core conftest.err conftest.$ac_objext conftest.beam \
7582    conftest$ac_exeext conftest.$ac_ext
7583LIBS=$ac_check_lib_save_LIBS
7584fi
7585{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
7586printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; }
7587if test "x$ac_cv_lib_dld_shl_load" = xyes
7588then :
7589  tcl_ok=yes
7590else $as_nop
7591  tcl_ok=no
7592fi
7593
7594	    if test "$tcl_ok" = yes
7595then :
7596
7597		SHLIB_CFLAGS="+z"
7598		SHLIB_LD="ld -b"
7599		LDFLAGS="$LDFLAGS -Wl,-E"
7600		CC_SEARCH_FLAGS='"-Wl,+s,+b,${LIB_RUNTIME_DIR}:."'
7601		LD_SEARCH_FLAGS='+s +b "${LIB_RUNTIME_DIR}:."'
7602		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
7603
7604fi
7605	    if test "$GCC" = yes
7606then :
7607
7608		SHLIB_LD='${CC} -shared'
7609		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
7610
7611else $as_nop
7612
7613		CFLAGS="$CFLAGS -z"
7614
7615fi
7616
7617	    # Check to enable 64-bit flags for compiler/linker
7618	    if test "$do64bit" = "yes"
7619then :
7620
7621		if test "$GCC" = yes
7622then :
7623
7624		    case `${CC} -dumpmachine` in
7625			hppa64*)
7626			    # 64-bit gcc in use.  Fix flags for GNU ld.
7627			    do64bit_ok=yes
7628			    SHLIB_LD='${CC} -shared'
7629			    if test $doRpath = yes
7630then :
7631
7632				CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
7633fi
7634			    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
7635			    ;;
7636			*)
7637			    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC on $system" >&5
7638printf "%s\n" "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
7639			    ;;
7640		    esac
7641
7642else $as_nop
7643
7644		    do64bit_ok=yes
7645		    CFLAGS="$CFLAGS +DD64"
7646		    LDFLAGS_ARCH="+DD64"
7647
7648fi
7649
7650fi ;;
7651	HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*)
7652	    SHLIB_SUFFIX=".sl"
7653	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
7654printf %s "checking for shl_load in -ldld... " >&6; }
7655if test ${ac_cv_lib_dld_shl_load+y}
7656then :
7657  printf %s "(cached) " >&6
7658else $as_nop
7659  ac_check_lib_save_LIBS=$LIBS
7660LIBS="-ldld  $LIBS"
7661cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7662/* end confdefs.h.  */
7663
7664/* Override any GCC internal prototype to avoid an error.
7665   Use char because int might match the return type of a GCC
7666   builtin and then its argument prototype would still apply.  */
7667char shl_load ();
7668int
7669main (void)
7670{
7671return shl_load ();
7672  ;
7673  return 0;
7674}
7675_ACEOF
7676if ac_fn_c_try_link "$LINENO"
7677then :
7678  ac_cv_lib_dld_shl_load=yes
7679else $as_nop
7680  ac_cv_lib_dld_shl_load=no
7681fi
7682rm -f core conftest.err conftest.$ac_objext conftest.beam \
7683    conftest$ac_exeext conftest.$ac_ext
7684LIBS=$ac_check_lib_save_LIBS
7685fi
7686{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
7687printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; }
7688if test "x$ac_cv_lib_dld_shl_load" = xyes
7689then :
7690  tcl_ok=yes
7691else $as_nop
7692  tcl_ok=no
7693fi
7694
7695	    if test "$tcl_ok" = yes
7696then :
7697
7698		SHLIB_CFLAGS="+z"
7699		SHLIB_LD="ld -b"
7700		SHLIB_LD_LIBS=""
7701		LDFLAGS="$LDFLAGS -Wl,-E"
7702		CC_SEARCH_FLAGS='"-Wl,+s,+b,${LIB_RUNTIME_DIR}:."'
7703		LD_SEARCH_FLAGS='+s +b "${LIB_RUNTIME_DIR}:."'
7704		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
7705
7706fi ;;
7707	IRIX-5.*)
7708	    SHLIB_CFLAGS=""
7709	    SHLIB_LD="ld -shared -rdata_shared"
7710	    SHLIB_SUFFIX=".so"
7711	    case " $LIBOBJS " in
7712  *" mkstemp.$ac_objext "* ) ;;
7713  *) LIBOBJS="$LIBOBJS mkstemp.$ac_objext"
7714 ;;
7715esac
7716
7717	    if test $doRpath = yes
7718then :
7719
7720		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
7721		LD_SEARCH_FLAGS='-rpath "${LIB_RUNTIME_DIR}"'
7722fi
7723	    ;;
7724	IRIX-6.*)
7725	    SHLIB_CFLAGS=""
7726	    SHLIB_LD="ld -n32 -shared -rdata_shared"
7727	    SHLIB_SUFFIX=".so"
7728	    if test $doRpath = yes
7729then :
7730
7731		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
7732		LD_SEARCH_FLAGS='-rpath "${LIB_RUNTIME_DIR}"'
7733fi
7734	    if test "$GCC" = yes
7735then :
7736
7737		CFLAGS="$CFLAGS -mabi=n32"
7738		LDFLAGS="$LDFLAGS -mabi=n32"
7739
7740else $as_nop
7741
7742		case $system in
7743		    IRIX-6.3)
7744			# Use to build 6.2 compatible binaries on 6.3.
7745			CFLAGS="$CFLAGS -n32 -D_OLD_TERMIOS"
7746			;;
7747		    *)
7748			CFLAGS="$CFLAGS -n32"
7749			;;
7750		esac
7751		LDFLAGS="$LDFLAGS -n32"
7752
7753fi
7754	    ;;
7755	IRIX64-6.*)
7756	    SHLIB_CFLAGS=""
7757	    SHLIB_LD="ld -n32 -shared -rdata_shared"
7758	    SHLIB_SUFFIX=".so"
7759	    if test $doRpath = yes
7760then :
7761
7762		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
7763		LD_SEARCH_FLAGS='-rpath "${LIB_RUNTIME_DIR}"'
7764fi
7765
7766	    # Check to enable 64-bit flags for compiler/linker
7767
7768	    if test "$do64bit" = yes
7769then :
7770
7771	        if test "$GCC" = yes
7772then :
7773
7774	            { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported by gcc" >&5
7775printf "%s\n" "$as_me: WARNING: 64bit mode not supported by gcc" >&2;}
7776
7777else $as_nop
7778
7779	            do64bit_ok=yes
7780	            SHLIB_LD="ld -64 -shared -rdata_shared"
7781	            CFLAGS="$CFLAGS -64"
7782	            LDFLAGS_ARCH="-64"
7783
7784fi
7785
7786fi
7787	    ;;
7788	Linux*|GNU*|NetBSD-Debian|DragonFly-*|FreeBSD-*)
7789	    SHLIB_CFLAGS="-fPIC"
7790	    SHLIB_SUFFIX=".so"
7791
7792	    # TEA specific:
7793	    CFLAGS_OPTIMIZE="-O2 -fomit-frame-pointer"
7794
7795	    # TEA specific: use LDFLAGS_DEFAULT instead of LDFLAGS
7796	    SHLIB_LD='${CC} ${CFLAGS} ${LDFLAGS_DEFAULT} -shared'
7797	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
7798
7799	    case $system in
7800	    DragonFly-*|FreeBSD-*)
7801		if test "${TCL_THREADS}" = "1"
7802then :
7803
7804		    # The -pthread needs to go in the LDFLAGS, not LIBS
7805		    LIBS=`echo $LIBS | sed s/-pthread//`
7806		    CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
7807		    LDFLAGS="$LDFLAGS $PTHREAD_LIBS"
7808fi
7809	    ;;
7810            esac
7811
7812	    if test $doRpath = yes
7813then :
7814
7815		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
7816fi
7817	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
7818	    if test "`uname -m`" = "alpha"
7819then :
7820  CFLAGS="$CFLAGS -mieee"
7821fi
7822	    if test $do64bit = yes
7823then :
7824
7825		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -m64 flag" >&5
7826printf %s "checking if compiler accepts -m64 flag... " >&6; }
7827if test ${tcl_cv_cc_m64+y}
7828then :
7829  printf %s "(cached) " >&6
7830else $as_nop
7831
7832		    hold_cflags=$CFLAGS
7833		    CFLAGS="$CFLAGS -m64"
7834		    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7835/* end confdefs.h.  */
7836
7837int
7838main (void)
7839{
7840
7841  ;
7842  return 0;
7843}
7844_ACEOF
7845if ac_fn_c_try_link "$LINENO"
7846then :
7847  tcl_cv_cc_m64=yes
7848else $as_nop
7849  tcl_cv_cc_m64=no
7850fi
7851rm -f core conftest.err conftest.$ac_objext conftest.beam \
7852    conftest$ac_exeext conftest.$ac_ext
7853		    CFLAGS=$hold_cflags
7854fi
7855{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_m64" >&5
7856printf "%s\n" "$tcl_cv_cc_m64" >&6; }
7857		if test $tcl_cv_cc_m64 = yes
7858then :
7859
7860		    CFLAGS="$CFLAGS -m64"
7861		    do64bit_ok=yes
7862
7863fi
7864
7865fi
7866
7867	    # The combo of gcc + glibc has a bug related to inlining of
7868	    # functions like strtod(). The -fno-builtin flag should address
7869	    # this problem but it does not work. The -fno-inline flag is kind
7870	    # of overkill but it works. Disable inlining only when one of the
7871	    # files in compat/*.c is being linked in.
7872
7873	    if test x"${USE_COMPAT}" != x
7874then :
7875  CFLAGS="$CFLAGS -fno-inline"
7876fi
7877	    ;;
7878	Lynx*)
7879	    SHLIB_CFLAGS="-fPIC"
7880	    SHLIB_SUFFIX=".so"
7881	    CFLAGS_OPTIMIZE=-02
7882	    SHLIB_LD='${CC} -shared'
7883	    LD_FLAGS="-Wl,--export-dynamic"
7884	    if test $doRpath = yes
7885then :
7886
7887		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
7888		LD_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
7889fi
7890	    ;;
7891	OpenBSD-*)
7892	    arch=`arch -s`
7893	    case "$arch" in
7894	    alpha|sparc64)
7895		SHLIB_CFLAGS="-fPIC"
7896		;;
7897	    *)
7898		SHLIB_CFLAGS="-fpic"
7899		;;
7900	    esac
7901	    SHLIB_LD='${CC} ${SHLIB_CFLAGS} -shared'
7902	    SHLIB_SUFFIX=".so"
7903	    if test $doRpath = yes
7904then :
7905
7906		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
7907fi
7908	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
7909	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so${SHLIB_VERSION}'
7910	    LDFLAGS="$LDFLAGS -Wl,-export-dynamic"
7911	    CFLAGS_OPTIMIZE="-O2"
7912	    # On OpenBSD:	Compile with -pthread
7913	    #		Don't link with -lpthread
7914	    LIBS=`echo $LIBS | sed s/-lpthread//`
7915	    CFLAGS="$CFLAGS -pthread"
7916	    # OpenBSD doesn't do version numbers with dots.
7917	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
7918	    TCL_LIB_VERSIONS_OK=nodots
7919	    ;;
7920	NetBSD-*)
7921	    # NetBSD has ELF and can use 'cc -shared' to build shared libs
7922	    SHLIB_CFLAGS="-fPIC"
7923	    SHLIB_LD='${CC} ${SHLIB_CFLAGS} -shared'
7924	    SHLIB_SUFFIX=".so"
7925	    LDFLAGS="$LDFLAGS -export-dynamic"
7926	    if test $doRpath = yes
7927then :
7928
7929		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
7930fi
7931	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
7932	    # The -pthread needs to go in the CFLAGS, not LIBS
7933	    LIBS=`echo $LIBS | sed s/-pthread//`
7934	    CFLAGS="$CFLAGS -pthread"
7935	    LDFLAGS="$LDFLAGS -pthread"
7936	    ;;
7937	Darwin-*)
7938	    CFLAGS_OPTIMIZE="-Os"
7939	    SHLIB_CFLAGS="-fno-common"
7940	    # To avoid discrepancies between what headers configure sees during
7941	    # preprocessing tests and compiling tests, move any -isysroot and
7942	    # -mmacosx-version-min flags from CFLAGS to CPPFLAGS:
7943	    CPPFLAGS="${CPPFLAGS} `echo " ${CFLAGS}" | \
7944		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
7945		if ($i~/^(isysroot|mmacosx-version-min)/) print "-"$i}'`"
7946	    CFLAGS="`echo " ${CFLAGS}" | \
7947		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
7948		if (!($i~/^(isysroot|mmacosx-version-min)/)) print "-"$i}'`"
7949	    if test $do64bit = yes
7950then :
7951
7952		case `arch` in
7953		    ppc)
7954			{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -arch ppc64 flag" >&5
7955printf %s "checking if compiler accepts -arch ppc64 flag... " >&6; }
7956if test ${tcl_cv_cc_arch_ppc64+y}
7957then :
7958  printf %s "(cached) " >&6
7959else $as_nop
7960
7961			    hold_cflags=$CFLAGS
7962			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
7963			    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7964/* end confdefs.h.  */
7965
7966int
7967main (void)
7968{
7969
7970  ;
7971  return 0;
7972}
7973_ACEOF
7974if ac_fn_c_try_link "$LINENO"
7975then :
7976  tcl_cv_cc_arch_ppc64=yes
7977else $as_nop
7978  tcl_cv_cc_arch_ppc64=no
7979fi
7980rm -f core conftest.err conftest.$ac_objext conftest.beam \
7981    conftest$ac_exeext conftest.$ac_ext
7982			    CFLAGS=$hold_cflags
7983fi
7984{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_arch_ppc64" >&5
7985printf "%s\n" "$tcl_cv_cc_arch_ppc64" >&6; }
7986			if test $tcl_cv_cc_arch_ppc64 = yes
7987then :
7988
7989			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
7990			    do64bit_ok=yes
7991
7992fi;;
7993		    i386)
7994			{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -arch x86_64 flag" >&5
7995printf %s "checking if compiler accepts -arch x86_64 flag... " >&6; }
7996if test ${tcl_cv_cc_arch_x86_64+y}
7997then :
7998  printf %s "(cached) " >&6
7999else $as_nop
8000
8001			    hold_cflags=$CFLAGS
8002			    CFLAGS="$CFLAGS -arch x86_64"
8003			    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8004/* end confdefs.h.  */
8005
8006int
8007main (void)
8008{
8009
8010  ;
8011  return 0;
8012}
8013_ACEOF
8014if ac_fn_c_try_link "$LINENO"
8015then :
8016  tcl_cv_cc_arch_x86_64=yes
8017else $as_nop
8018  tcl_cv_cc_arch_x86_64=no
8019fi
8020rm -f core conftest.err conftest.$ac_objext conftest.beam \
8021    conftest$ac_exeext conftest.$ac_ext
8022			    CFLAGS=$hold_cflags
8023fi
8024{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_arch_x86_64" >&5
8025printf "%s\n" "$tcl_cv_cc_arch_x86_64" >&6; }
8026			if test $tcl_cv_cc_arch_x86_64 = yes
8027then :
8028
8029			    CFLAGS="$CFLAGS -arch x86_64"
8030			    do64bit_ok=yes
8031
8032fi;;
8033		    *)
8034			{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&5
8035printf "%s\n" "$as_me: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&2;};;
8036		esac
8037
8038else $as_nop
8039
8040		# Check for combined 32-bit and 64-bit fat build
8041		if echo "$CFLAGS " |grep -E -q -- '-arch (ppc64|x86_64) ' \
8042		    && echo "$CFLAGS " |grep -E -q -- '-arch (ppc|i386) '
8043then :
8044
8045		    fat_32_64=yes
8046fi
8047
8048fi
8049	    # TEA specific: use LDFLAGS_DEFAULT instead of LDFLAGS
8050	    SHLIB_LD='${CC} -dynamiclib ${CFLAGS} ${LDFLAGS_DEFAULT}'
8051	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if ld accepts -single_module flag" >&5
8052printf %s "checking if ld accepts -single_module flag... " >&6; }
8053if test ${tcl_cv_ld_single_module+y}
8054then :
8055  printf %s "(cached) " >&6
8056else $as_nop
8057
8058		hold_ldflags=$LDFLAGS
8059		LDFLAGS="$LDFLAGS -dynamiclib -Wl,-single_module"
8060		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8061/* end confdefs.h.  */
8062
8063int
8064main (void)
8065{
8066int i;
8067  ;
8068  return 0;
8069}
8070_ACEOF
8071if ac_fn_c_try_link "$LINENO"
8072then :
8073  tcl_cv_ld_single_module=yes
8074else $as_nop
8075  tcl_cv_ld_single_module=no
8076fi
8077rm -f core conftest.err conftest.$ac_objext conftest.beam \
8078    conftest$ac_exeext conftest.$ac_ext
8079		LDFLAGS=$hold_ldflags
8080fi
8081{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_single_module" >&5
8082printf "%s\n" "$tcl_cv_ld_single_module" >&6; }
8083	    if test $tcl_cv_ld_single_module = yes
8084then :
8085
8086		SHLIB_LD="${SHLIB_LD} -Wl,-single_module"
8087
8088fi
8089	    # TEA specific: link shlib with current and compatibility version flags
8090	    vers=`echo ${PACKAGE_VERSION} | sed -e 's/^\([0-9]\{1,5\}\)\(\(\.[0-9]\{1,3\}\)\{0,2\}\).*$/\1\2/p' -e d`
8091	    SHLIB_LD="${SHLIB_LD} -current_version ${vers:-0} -compatibility_version ${vers:-0}"
8092	    SHLIB_SUFFIX=".dylib"
8093	    LDFLAGS="$LDFLAGS -headerpad_max_install_names"
8094	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if ld accepts -search_paths_first flag" >&5
8095printf %s "checking if ld accepts -search_paths_first flag... " >&6; }
8096if test ${tcl_cv_ld_search_paths_first+y}
8097then :
8098  printf %s "(cached) " >&6
8099else $as_nop
8100
8101		hold_ldflags=$LDFLAGS
8102		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
8103		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8104/* end confdefs.h.  */
8105
8106int
8107main (void)
8108{
8109int i;
8110  ;
8111  return 0;
8112}
8113_ACEOF
8114if ac_fn_c_try_link "$LINENO"
8115then :
8116  tcl_cv_ld_search_paths_first=yes
8117else $as_nop
8118  tcl_cv_ld_search_paths_first=no
8119fi
8120rm -f core conftest.err conftest.$ac_objext conftest.beam \
8121    conftest$ac_exeext conftest.$ac_ext
8122		LDFLAGS=$hold_ldflags
8123fi
8124{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_search_paths_first" >&5
8125printf "%s\n" "$tcl_cv_ld_search_paths_first" >&6; }
8126	    if test $tcl_cv_ld_search_paths_first = yes
8127then :
8128
8129		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
8130
8131fi
8132	    if test "$tcl_cv_cc_visibility_hidden" != yes
8133then :
8134
8135
8136printf "%s\n" "#define MODULE_SCOPE __private_extern__" >>confdefs.h
8137
8138		tcl_cv_cc_visibility_hidden=yes
8139
8140fi
8141	    CC_SEARCH_FLAGS=""
8142	    LD_SEARCH_FLAGS=""
8143	    LD_LIBRARY_PATH_VAR="DYLD_LIBRARY_PATH"
8144	    # TEA specific: for combined 32 & 64 bit fat builds of Tk
8145	    # extensions, verify that 64-bit build is possible.
8146	    if test "$fat_32_64" = yes && test -n "${TK_BIN_DIR}"
8147then :
8148
8149		if test "${TEA_WINDOWINGSYSTEM}" = x11
8150then :
8151
8152		    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 64-bit X11" >&5
8153printf %s "checking for 64-bit X11... " >&6; }
8154if test ${tcl_cv_lib_x11_64+y}
8155then :
8156  printf %s "(cached) " >&6
8157else $as_nop
8158
8159			for v in CFLAGS CPPFLAGS LDFLAGS; do
8160			    eval 'hold_'$v'="$'$v'";'$v'="`echo "$'$v' "|sed -e "s/-arch ppc / /g" -e "s/-arch i386 / /g"`"'
8161			done
8162			CPPFLAGS="$CPPFLAGS -I/usr/X11R6/include"
8163			LDFLAGS="$LDFLAGS -L/usr/X11R6/lib -lX11"
8164			cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8165/* end confdefs.h.  */
8166#include <X11/Xlib.h>
8167int
8168main (void)
8169{
8170XrmInitialize();
8171  ;
8172  return 0;
8173}
8174_ACEOF
8175if ac_fn_c_try_link "$LINENO"
8176then :
8177  tcl_cv_lib_x11_64=yes
8178else $as_nop
8179  tcl_cv_lib_x11_64=no
8180fi
8181rm -f core conftest.err conftest.$ac_objext conftest.beam \
8182    conftest$ac_exeext conftest.$ac_ext
8183			for v in CFLAGS CPPFLAGS LDFLAGS; do
8184			    eval $v'="$hold_'$v'"'
8185			done
8186fi
8187{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_lib_x11_64" >&5
8188printf "%s\n" "$tcl_cv_lib_x11_64" >&6; }
8189
8190fi
8191		if test "${TEA_WINDOWINGSYSTEM}" = aqua
8192then :
8193
8194		    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 64-bit Tk" >&5
8195printf %s "checking for 64-bit Tk... " >&6; }
8196if test ${tcl_cv_lib_tk_64+y}
8197then :
8198  printf %s "(cached) " >&6
8199else $as_nop
8200
8201			for v in CFLAGS CPPFLAGS LDFLAGS; do
8202			    eval 'hold_'$v'="$'$v'";'$v'="`echo "$'$v' "|sed -e "s/-arch ppc / /g" -e "s/-arch i386 / /g"`"'
8203			done
8204			CPPFLAGS="$CPPFLAGS -DUSE_TCL_STUBS=1 -DUSE_TK_STUBS=1 ${TCL_INCLUDES} ${TK_INCLUDES}"
8205			LDFLAGS="$LDFLAGS ${TCL_STUB_LIB_SPEC} ${TK_STUB_LIB_SPEC}"
8206			cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8207/* end confdefs.h.  */
8208#include <tk.h>
8209int
8210main (void)
8211{
8212Tk_InitStubs(NULL, "", 0);
8213  ;
8214  return 0;
8215}
8216_ACEOF
8217if ac_fn_c_try_link "$LINENO"
8218then :
8219  tcl_cv_lib_tk_64=yes
8220else $as_nop
8221  tcl_cv_lib_tk_64=no
8222fi
8223rm -f core conftest.err conftest.$ac_objext conftest.beam \
8224    conftest$ac_exeext conftest.$ac_ext
8225			for v in CFLAGS CPPFLAGS LDFLAGS; do
8226			    eval $v'="$hold_'$v'"'
8227			done
8228fi
8229{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_lib_tk_64" >&5
8230printf "%s\n" "$tcl_cv_lib_tk_64" >&6; }
8231
8232fi
8233		# remove 64-bit arch flags from CFLAGS et al. if configuration
8234		# does not support 64-bit.
8235		if test "$tcl_cv_lib_tk_64" = no -o "$tcl_cv_lib_x11_64" = no
8236then :
8237
8238		    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: Removing 64-bit architectures from compiler & linker flags" >&5
8239printf "%s\n" "$as_me: Removing 64-bit architectures from compiler & linker flags" >&6;}
8240		    for v in CFLAGS CPPFLAGS LDFLAGS; do
8241			eval $v'="`echo "$'$v' "|sed -e "s/-arch ppc64 / /g" -e "s/-arch x86_64 / /g"`"'
8242		    done
8243fi
8244
8245fi
8246	    ;;
8247	OS/390-*)
8248	    CFLAGS_OPTIMIZE=""		# Optimizer is buggy
8249
8250printf "%s\n" "#define _OE_SOCKETS 1" >>confdefs.h
8251
8252	    ;;
8253	OSF1-V*)
8254	    # Digital OSF/1
8255	    SHLIB_CFLAGS=""
8256	    if test "$SHARED_BUILD" = 1
8257then :
8258
8259	        SHLIB_LD='ld -shared -expect_unresolved "*"'
8260
8261else $as_nop
8262
8263	        SHLIB_LD='ld -non_shared -expect_unresolved "*"'
8264
8265fi
8266	    SHLIB_SUFFIX=".so"
8267	    if test $doRpath = yes
8268then :
8269
8270		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
8271		LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
8272fi
8273	    if test "$GCC" = yes
8274then :
8275  CFLAGS="$CFLAGS -mieee"
8276else $as_nop
8277
8278		CFLAGS="$CFLAGS -DHAVE_TZSET -std1 -ieee"
8279fi
8280	    # see pthread_intro(3) for pthread support on osf1, k.furukawa
8281	    CFLAGS="$CFLAGS -DHAVE_PTHREAD_ATTR_SETSTACKSIZE"
8282	    CFLAGS="$CFLAGS -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
8283	    LIBS=`echo $LIBS | sed s/-lpthreads//`
8284	    if test "$GCC" = yes
8285then :
8286
8287		LIBS="$LIBS -lpthread -lmach -lexc"
8288
8289else $as_nop
8290
8291		CFLAGS="$CFLAGS -pthread"
8292		LDFLAGS="$LDFLAGS -pthread"
8293
8294fi
8295	    ;;
8296	QNX-6*)
8297	    # QNX RTP
8298	    # This may work for all QNX, but it was only reported for v6.
8299	    SHLIB_CFLAGS="-fPIC"
8300	    SHLIB_LD="ld -Bshareable -x"
8301	    SHLIB_LD_LIBS=""
8302	    SHLIB_SUFFIX=".so"
8303	    CC_SEARCH_FLAGS=""
8304	    LD_SEARCH_FLAGS=""
8305	    ;;
8306	SCO_SV-3.2*)
8307	    if test "$GCC" = yes
8308then :
8309
8310		SHLIB_CFLAGS="-fPIC -melf"
8311		LDFLAGS="$LDFLAGS -melf -Wl,-Bexport"
8312
8313else $as_nop
8314
8315		SHLIB_CFLAGS="-Kpic -belf"
8316		LDFLAGS="$LDFLAGS -belf -Wl,-Bexport"
8317
8318fi
8319	    SHLIB_LD="ld -G"
8320	    SHLIB_LD_LIBS=""
8321	    SHLIB_SUFFIX=".so"
8322	    CC_SEARCH_FLAGS=""
8323	    LD_SEARCH_FLAGS=""
8324	    ;;
8325	SunOS-5.[0-6])
8326	    # Careful to not let 5.10+ fall into this case
8327
8328	    # Note: If _REENTRANT isn't defined, then Solaris
8329	    # won't define thread-safe library routines.
8330
8331
8332printf "%s\n" "#define _REENTRANT 1" >>confdefs.h
8333
8334
8335printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
8336
8337
8338	    SHLIB_CFLAGS="-KPIC"
8339	    SHLIB_SUFFIX=".so"
8340	    if test "$GCC" = yes
8341then :
8342
8343		SHLIB_LD='${CC} -shared'
8344		CC_SEARCH_FLAGS='"-Wl,-R,${LIB_RUNTIME_DIR}"'
8345		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
8346
8347else $as_nop
8348
8349		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
8350		CC_SEARCH_FLAGS='-R "${LIB_RUNTIME_DIR}"'
8351		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
8352
8353fi
8354	    ;;
8355	SunOS-5*)
8356	    # Note: If _REENTRANT isn't defined, then Solaris
8357	    # won't define thread-safe library routines.
8358
8359
8360printf "%s\n" "#define _REENTRANT 1" >>confdefs.h
8361
8362
8363printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
8364
8365
8366	    SHLIB_CFLAGS="-KPIC"
8367
8368	    # Check to enable 64-bit flags for compiler/linker
8369	    if test "$do64bit" = yes
8370then :
8371
8372		arch=`isainfo`
8373		if test "$arch" = "sparcv9 sparc"
8374then :
8375
8376		    if test "$GCC" = yes
8377then :
8378
8379			if test "`${CC} -dumpversion | awk -F. '{print $1}'`" -lt 3
8380then :
8381
8382			    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&5
8383printf "%s\n" "$as_me: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&2;}
8384
8385else $as_nop
8386
8387			    do64bit_ok=yes
8388			    CFLAGS="$CFLAGS -m64 -mcpu=v9"
8389			    LDFLAGS="$LDFLAGS -m64 -mcpu=v9"
8390			    SHLIB_CFLAGS="-fPIC"
8391
8392fi
8393
8394else $as_nop
8395
8396			do64bit_ok=yes
8397			if test "$do64bitVIS" = yes
8398then :
8399
8400			    CFLAGS="$CFLAGS -xarch=v9a"
8401			    LDFLAGS_ARCH="-xarch=v9a"
8402
8403else $as_nop
8404
8405			    CFLAGS="$CFLAGS -xarch=v9"
8406			    LDFLAGS_ARCH="-xarch=v9"
8407
8408fi
8409			# Solaris 64 uses this as well
8410			#LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH_64"
8411
8412fi
8413
8414else $as_nop
8415  if test "$arch" = "amd64 i386"
8416then :
8417
8418		    if test "$GCC" = yes
8419then :
8420
8421			case $system in
8422			    SunOS-5.1[1-9]*|SunOS-5.[2-9][0-9]*)
8423				do64bit_ok=yes
8424				CFLAGS="$CFLAGS -m64"
8425				LDFLAGS="$LDFLAGS -m64";;
8426			    *)
8427				{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC on $system" >&5
8428printf "%s\n" "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;};;
8429			esac
8430
8431else $as_nop
8432
8433			do64bit_ok=yes
8434			case $system in
8435			    SunOS-5.1[1-9]*|SunOS-5.[2-9][0-9]*)
8436				CFLAGS="$CFLAGS -m64"
8437				LDFLAGS="$LDFLAGS -m64";;
8438			    *)
8439				CFLAGS="$CFLAGS -xarch=amd64"
8440				LDFLAGS="$LDFLAGS -xarch=amd64";;
8441			esac
8442
8443fi
8444
8445else $as_nop
8446  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported for $arch" >&5
8447printf "%s\n" "$as_me: WARNING: 64bit mode not supported for $arch" >&2;}
8448fi
8449fi
8450
8451fi
8452
8453	    SHLIB_SUFFIX=".so"
8454	    if test "$GCC" = yes
8455then :
8456
8457		SHLIB_LD='${CC} -shared'
8458		CC_SEARCH_FLAGS='"-Wl,-R,${LIB_RUNTIME_DIR}"'
8459		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
8460		if test "$do64bit_ok" = yes
8461then :
8462
8463		    if test "$arch" = "sparcv9 sparc"
8464then :
8465
8466			# We need to specify -static-libgcc or we need to
8467			# add the path to the sparv9 libgcc.
8468			# JH: static-libgcc is necessary for core Tcl, but may
8469			# not be necessary for extensions.
8470			SHLIB_LD="$SHLIB_LD -m64 -mcpu=v9 -static-libgcc"
8471			# for finding sparcv9 libgcc, get the regular libgcc
8472			# path, remove so name and append 'sparcv9'
8473			#v9gcclibdir="`gcc -print-file-name=libgcc_s.so` | ..."
8474			#CC_SEARCH_FLAGS="${CC_SEARCH_FLAGS},-R,$v9gcclibdir"
8475
8476else $as_nop
8477  if test "$arch" = "amd64 i386"
8478then :
8479
8480			# JH: static-libgcc is necessary for core Tcl, but may
8481			# not be necessary for extensions.
8482			SHLIB_LD="$SHLIB_LD -m64 -static-libgcc"
8483
8484fi
8485fi
8486
8487fi
8488
8489else $as_nop
8490
8491		case $system in
8492		    SunOS-5.[1-9][0-9]*)
8493			# TEA specific: use LDFLAGS_DEFAULT instead of LDFLAGS
8494			SHLIB_LD='${CC} -G -z text ${LDFLAGS_DEFAULT}';;
8495		    *)
8496			SHLIB_LD='/usr/ccs/bin/ld -G -z text';;
8497		esac
8498		CC_SEARCH_FLAGS='"-Wl,-R,${LIB_RUNTIME_DIR}"'
8499		LD_SEARCH_FLAGS='-R "${LIB_RUNTIME_DIR}"'
8500
8501fi
8502	    ;;
8503	UNIX_SV* | UnixWare-5*)
8504	    SHLIB_CFLAGS="-KPIC"
8505	    SHLIB_LD='${CC} -G'
8506	    SHLIB_LD_LIBS=""
8507	    SHLIB_SUFFIX=".so"
8508	    # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
8509	    # that don't grok the -Bexport option.  Test that it does.
8510	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld accepts -Bexport flag" >&5
8511printf %s "checking for ld accepts -Bexport flag... " >&6; }
8512if test ${tcl_cv_ld_Bexport+y}
8513then :
8514  printf %s "(cached) " >&6
8515else $as_nop
8516
8517		hold_ldflags=$LDFLAGS
8518		LDFLAGS="$LDFLAGS -Wl,-Bexport"
8519		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8520/* end confdefs.h.  */
8521
8522int
8523main (void)
8524{
8525int i;
8526  ;
8527  return 0;
8528}
8529_ACEOF
8530if ac_fn_c_try_link "$LINENO"
8531then :
8532  tcl_cv_ld_Bexport=yes
8533else $as_nop
8534  tcl_cv_ld_Bexport=no
8535fi
8536rm -f core conftest.err conftest.$ac_objext conftest.beam \
8537    conftest$ac_exeext conftest.$ac_ext
8538	        LDFLAGS=$hold_ldflags
8539fi
8540{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_Bexport" >&5
8541printf "%s\n" "$tcl_cv_ld_Bexport" >&6; }
8542	    if test $tcl_cv_ld_Bexport = yes
8543then :
8544
8545		LDFLAGS="$LDFLAGS -Wl,-Bexport"
8546
8547fi
8548	    CC_SEARCH_FLAGS=""
8549	    LD_SEARCH_FLAGS=""
8550	    ;;
8551    esac
8552
8553    if test "$do64bit" = yes -a "$do64bit_ok" = no
8554then :
8555
8556	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit support being disabled -- don't know magic for this platform" >&5
8557printf "%s\n" "$as_me: WARNING: 64bit support being disabled -- don't know magic for this platform" >&2;}
8558
8559fi
8560
8561
8562
8563    # Add in the arch flags late to ensure it wasn't removed.
8564    # Not necessary in TEA, but this is aligned with core
8565    LDFLAGS="$LDFLAGS $LDFLAGS_ARCH"
8566
8567    # If we're running gcc, then change the C flags for compiling shared
8568    # libraries to the right flags for gcc, instead of those for the
8569    # standard manufacturer compiler.
8570
8571    if test "$GCC" = yes
8572then :
8573
8574	case $system in
8575	    AIX-*) ;;
8576	    BSD/OS*) ;;
8577	    CYGWIN_*|MINGW32_*|MINGW64_*|MSYS_*) ;;
8578	    IRIX*) ;;
8579	    NetBSD-*|DragonFly-*|FreeBSD-*|OpenBSD-*) ;;
8580	    Darwin-*) ;;
8581	    SCO_SV-3.2*) ;;
8582	    windows) ;;
8583	    *) SHLIB_CFLAGS="-fPIC" ;;
8584	esac
8585fi
8586
8587    if test "$tcl_cv_cc_visibility_hidden" != yes
8588then :
8589
8590
8591printf "%s\n" "#define MODULE_SCOPE extern" >>confdefs.h
8592
8593
8594fi
8595
8596    if test "$SHARED_LIB_SUFFIX" = ""
8597then :
8598
8599    # TEA specific: use PACKAGE_VERSION instead of VERSION
8600    SHARED_LIB_SUFFIX='${PACKAGE_VERSION}${SHLIB_SUFFIX}'
8601fi
8602    if test "$UNSHARED_LIB_SUFFIX" = ""
8603then :
8604
8605    # TEA specific: use PACKAGE_VERSION instead of VERSION
8606    UNSHARED_LIB_SUFFIX='${PACKAGE_VERSION}.a'
8607fi
8608
8609    if test "${GCC}" = "yes" -a ${SHLIB_SUFFIX} = ".dll"; then
8610	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SEH support in compiler" >&5
8611printf %s "checking for SEH support in compiler... " >&6; }
8612if test ${tcl_cv_seh+y}
8613then :
8614  printf %s "(cached) " >&6
8615else $as_nop
8616  if test "$cross_compiling" = yes
8617then :
8618  tcl_cv_seh=no
8619else $as_nop
8620  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8621/* end confdefs.h.  */
8622
8623#define WIN32_LEAN_AND_MEAN
8624#include <windows.h>
8625#undef WIN32_LEAN_AND_MEAN
8626
8627	    int main(int argc, char** argv) {
8628		int a, b = 0;
8629		__try {
8630		    a = 666 / b;
8631		}
8632		__except (EXCEPTION_EXECUTE_HANDLER) {
8633		    return 0;
8634		}
8635		return 1;
8636	    }
8637
8638_ACEOF
8639if ac_fn_c_try_run "$LINENO"
8640then :
8641  tcl_cv_seh=yes
8642else $as_nop
8643  tcl_cv_seh=no
8644fi
8645rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8646  conftest.$ac_objext conftest.beam conftest.$ac_ext
8647fi
8648
8649
8650fi
8651{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_seh" >&5
8652printf "%s\n" "$tcl_cv_seh" >&6; }
8653	if test "$tcl_cv_seh" = "no" ; then
8654
8655printf "%s\n" "#define HAVE_NO_SEH 1" >>confdefs.h
8656
8657	fi
8658
8659	#
8660	# Check to see if the excpt.h include file provided contains the
8661	# definition for EXCEPTION_DISPOSITION; if not, which is the case
8662	# with Cygwin's version as of 2002-04-10, define it to be int,
8663	# sufficient for getting the current code to work.
8664	#
8665	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for EXCEPTION_DISPOSITION support in include files" >&5
8666printf %s "checking for EXCEPTION_DISPOSITION support in include files... " >&6; }
8667if test ${tcl_cv_eh_disposition+y}
8668then :
8669  printf %s "(cached) " >&6
8670else $as_nop
8671  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8672/* end confdefs.h.  */
8673
8674#	    define WIN32_LEAN_AND_MEAN
8675#	    include <windows.h>
8676#	    undef WIN32_LEAN_AND_MEAN
8677
8678int
8679main (void)
8680{
8681
8682		EXCEPTION_DISPOSITION x;
8683
8684  ;
8685  return 0;
8686}
8687_ACEOF
8688if ac_fn_c_try_compile "$LINENO"
8689then :
8690  tcl_cv_eh_disposition=yes
8691else $as_nop
8692  tcl_cv_eh_disposition=no
8693fi
8694rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8695
8696fi
8697{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_eh_disposition" >&5
8698printf "%s\n" "$tcl_cv_eh_disposition" >&6; }
8699	if test "$tcl_cv_eh_disposition" = "no" ; then
8700
8701printf "%s\n" "#define EXCEPTION_DISPOSITION int" >>confdefs.h
8702
8703	fi
8704
8705	# Check to see if winnt.h defines CHAR, SHORT, and LONG
8706	# even if VOID has already been #defined. The win32api
8707	# used by mingw and cygwin is known to do this.
8708
8709	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for winnt.h that ignores VOID define" >&5
8710printf %s "checking for winnt.h that ignores VOID define... " >&6; }
8711if test ${tcl_cv_winnt_ignore_void+y}
8712then :
8713  printf %s "(cached) " >&6
8714else $as_nop
8715  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8716/* end confdefs.h.  */
8717
8718#define VOID void
8719#define WIN32_LEAN_AND_MEAN
8720#include <windows.h>
8721#undef WIN32_LEAN_AND_MEAN
8722
8723int
8724main (void)
8725{
8726
8727		CHAR c;
8728		SHORT s;
8729		LONG l;
8730
8731  ;
8732  return 0;
8733}
8734_ACEOF
8735if ac_fn_c_try_compile "$LINENO"
8736then :
8737  tcl_cv_winnt_ignore_void=yes
8738else $as_nop
8739  tcl_cv_winnt_ignore_void=no
8740fi
8741rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8742
8743fi
8744{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_winnt_ignore_void" >&5
8745printf "%s\n" "$tcl_cv_winnt_ignore_void" >&6; }
8746	if test "$tcl_cv_winnt_ignore_void" = "yes" ; then
8747
8748printf "%s\n" "#define HAVE_WINNT_IGNORE_VOID 1" >>confdefs.h
8749
8750	fi
8751    fi
8752
8753	# See if the compiler supports casting to a union type.
8754	# This is used to stop gcc from printing a compiler
8755	# warning when initializing a union member.
8756
8757	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cast to union support" >&5
8758printf %s "checking for cast to union support... " >&6; }
8759if test ${tcl_cv_cast_to_union+y}
8760then :
8761  printf %s "(cached) " >&6
8762else $as_nop
8763  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8764/* end confdefs.h.  */
8765
8766int
8767main (void)
8768{
8769
8770		  union foo { int i; double d; };
8771		  union foo f = (union foo) (int) 0;
8772
8773  ;
8774  return 0;
8775}
8776_ACEOF
8777if ac_fn_c_try_compile "$LINENO"
8778then :
8779  tcl_cv_cast_to_union=yes
8780else $as_nop
8781  tcl_cv_cast_to_union=no
8782fi
8783rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8784
8785fi
8786{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cast_to_union" >&5
8787printf "%s\n" "$tcl_cv_cast_to_union" >&6; }
8788	if test "$tcl_cv_cast_to_union" = "yes"; then
8789
8790printf "%s\n" "#define HAVE_CAST_TO_UNION 1" >>confdefs.h
8791
8792	fi
8793
8794	ac_fn_c_check_header_compile "$LINENO" "stdbool.h" "ac_cv_header_stdbool_h" "$ac_includes_default"
8795if test "x$ac_cv_header_stdbool_h" = xyes
8796then :
8797
8798printf "%s\n" "#define HAVE_STDBOOL_H 1" >>confdefs.h
8799
8800fi
8801
8802
8803
8804
8805
8806
8807
8808
8809
8810
8811
8812
8813
8814
8815
8816
8817    # These must be called after we do the basic CFLAGS checks and
8818    # verify any possible 64-bit or similar switches are necessary
8819
8820    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for required early compiler flags" >&5
8821printf %s "checking for required early compiler flags... " >&6; }
8822    tcl_flags=""
8823
8824    if test ${tcl_cv_flag__isoc99_source+y}
8825then :
8826  printf %s "(cached) " >&6
8827else $as_nop
8828  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8829/* end confdefs.h.  */
8830#include <stdlib.h>
8831int
8832main (void)
8833{
8834char *p = (char *)strtoll; char *q = (char *)strtoull;
8835  ;
8836  return 0;
8837}
8838_ACEOF
8839if ac_fn_c_try_compile "$LINENO"
8840then :
8841  tcl_cv_flag__isoc99_source=no
8842else $as_nop
8843  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8844/* end confdefs.h.  */
8845#define _ISOC99_SOURCE 1
8846#include <stdlib.h>
8847int
8848main (void)
8849{
8850char *p = (char *)strtoll; char *q = (char *)strtoull;
8851  ;
8852  return 0;
8853}
8854_ACEOF
8855if ac_fn_c_try_compile "$LINENO"
8856then :
8857  tcl_cv_flag__isoc99_source=yes
8858else $as_nop
8859  tcl_cv_flag__isoc99_source=no
8860fi
8861rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8862fi
8863rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8864fi
8865
8866    if test "x${tcl_cv_flag__isoc99_source}" = "xyes" ; then
8867
8868printf "%s\n" "#define _ISOC99_SOURCE 1" >>confdefs.h
8869
8870	tcl_flags="$tcl_flags _ISOC99_SOURCE"
8871    fi
8872
8873
8874    if test ${tcl_cv_flag__largefile64_source+y}
8875then :
8876  printf %s "(cached) " >&6
8877else $as_nop
8878  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8879/* end confdefs.h.  */
8880#include <sys/stat.h>
8881int
8882main (void)
8883{
8884struct stat64 buf; int i = stat64("/", &buf);
8885  ;
8886  return 0;
8887}
8888_ACEOF
8889if ac_fn_c_try_compile "$LINENO"
8890then :
8891  tcl_cv_flag__largefile64_source=no
8892else $as_nop
8893  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8894/* end confdefs.h.  */
8895#define _LARGEFILE64_SOURCE 1
8896#include <sys/stat.h>
8897int
8898main (void)
8899{
8900struct stat64 buf; int i = stat64("/", &buf);
8901  ;
8902  return 0;
8903}
8904_ACEOF
8905if ac_fn_c_try_compile "$LINENO"
8906then :
8907  tcl_cv_flag__largefile64_source=yes
8908else $as_nop
8909  tcl_cv_flag__largefile64_source=no
8910fi
8911rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8912fi
8913rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8914fi
8915
8916    if test "x${tcl_cv_flag__largefile64_source}" = "xyes" ; then
8917
8918printf "%s\n" "#define _LARGEFILE64_SOURCE 1" >>confdefs.h
8919
8920	tcl_flags="$tcl_flags _LARGEFILE64_SOURCE"
8921    fi
8922
8923
8924    if test ${tcl_cv_flag__largefile_source64+y}
8925then :
8926  printf %s "(cached) " >&6
8927else $as_nop
8928  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8929/* end confdefs.h.  */
8930#include <sys/stat.h>
8931int
8932main (void)
8933{
8934char *p = (char *)open64;
8935  ;
8936  return 0;
8937}
8938_ACEOF
8939if ac_fn_c_try_compile "$LINENO"
8940then :
8941  tcl_cv_flag__largefile_source64=no
8942else $as_nop
8943  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8944/* end confdefs.h.  */
8945#define _LARGEFILE_SOURCE64 1
8946#include <sys/stat.h>
8947int
8948main (void)
8949{
8950char *p = (char *)open64;
8951  ;
8952  return 0;
8953}
8954_ACEOF
8955if ac_fn_c_try_compile "$LINENO"
8956then :
8957  tcl_cv_flag__largefile_source64=yes
8958else $as_nop
8959  tcl_cv_flag__largefile_source64=no
8960fi
8961rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8962fi
8963rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8964fi
8965
8966    if test "x${tcl_cv_flag__largefile_source64}" = "xyes" ; then
8967
8968printf "%s\n" "#define _LARGEFILE_SOURCE64 1" >>confdefs.h
8969
8970	tcl_flags="$tcl_flags _LARGEFILE_SOURCE64"
8971    fi
8972
8973    if test "x${tcl_flags}" = "x" ; then
8974	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5
8975printf "%s\n" "none" >&6; }
8976    else
8977	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${tcl_flags}" >&5
8978printf "%s\n" "${tcl_flags}" >&6; }
8979    fi
8980
8981
8982    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 64-bit integer type" >&5
8983printf %s "checking for 64-bit integer type... " >&6; }
8984    if test ${tcl_cv_type_64bit+y}
8985then :
8986  printf %s "(cached) " >&6
8987else $as_nop
8988
8989	tcl_cv_type_64bit=none
8990	# See if the compiler knows natively about __int64
8991	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8992/* end confdefs.h.  */
8993
8994int
8995main (void)
8996{
8997__int64 value = (__int64) 0;
8998  ;
8999  return 0;
9000}
9001_ACEOF
9002if ac_fn_c_try_compile "$LINENO"
9003then :
9004  tcl_type_64bit=__int64
9005else $as_nop
9006  tcl_type_64bit="long long"
9007fi
9008rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9009	# See if we could use long anyway  Note that we substitute in the
9010	# type that is our current guess for a 64-bit type inside this check
9011	# program, so it should be modified only carefully...
9012        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9013/* end confdefs.h.  */
9014
9015int
9016main (void)
9017{
9018switch (0) {
9019            case 1: case (sizeof(${tcl_type_64bit})==sizeof(long)): ;
9020        }
9021  ;
9022  return 0;
9023}
9024_ACEOF
9025if ac_fn_c_try_compile "$LINENO"
9026then :
9027  tcl_cv_type_64bit=${tcl_type_64bit}
9028fi
9029rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9030fi
9031
9032    if test "${tcl_cv_type_64bit}" = none ; then
9033
9034printf "%s\n" "#define TCL_WIDE_INT_IS_LONG 1" >>confdefs.h
9035
9036	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9037printf "%s\n" "yes" >&6; }
9038    elif test "${tcl_cv_type_64bit}" = "__int64" \
9039		-a "${TEA_PLATFORM}" = "windows" ; then
9040	# TEA specific: We actually want to use the default tcl.h checks in
9041	# this case to handle both TCL_WIDE_INT_TYPE and TCL_LL_MODIFIER*
9042	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: using Tcl header defaults" >&5
9043printf "%s\n" "using Tcl header defaults" >&6; }
9044    else
9045
9046printf "%s\n" "#define TCL_WIDE_INT_TYPE ${tcl_cv_type_64bit}" >>confdefs.h
9047
9048	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${tcl_cv_type_64bit}" >&5
9049printf "%s\n" "${tcl_cv_type_64bit}" >&6; }
9050
9051	# Now check for auxiliary declarations
9052	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct dirent64" >&5
9053printf %s "checking for struct dirent64... " >&6; }
9054if test ${tcl_cv_struct_dirent64+y}
9055then :
9056  printf %s "(cached) " >&6
9057else $as_nop
9058
9059	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9060/* end confdefs.h.  */
9061#include <sys/types.h>
9062#include <dirent.h>
9063int
9064main (void)
9065{
9066struct dirent64 p;
9067  ;
9068  return 0;
9069}
9070_ACEOF
9071if ac_fn_c_try_compile "$LINENO"
9072then :
9073  tcl_cv_struct_dirent64=yes
9074else $as_nop
9075  tcl_cv_struct_dirent64=no
9076fi
9077rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9078fi
9079{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_struct_dirent64" >&5
9080printf "%s\n" "$tcl_cv_struct_dirent64" >&6; }
9081	if test "x${tcl_cv_struct_dirent64}" = "xyes" ; then
9082
9083printf "%s\n" "#define HAVE_STRUCT_DIRENT64 1" >>confdefs.h
9084
9085	fi
9086
9087	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DIR64" >&5
9088printf %s "checking for DIR64... " >&6; }
9089if test ${tcl_cv_DIR64+y}
9090then :
9091  printf %s "(cached) " >&6
9092else $as_nop
9093
9094	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9095/* end confdefs.h.  */
9096#include <sys/types.h>
9097#include <dirent.h>
9098int
9099main (void)
9100{
9101struct dirent64 *p; DIR64 d = opendir64(".");
9102            p = readdir64(d); rewinddir64(d); closedir64(d);
9103  ;
9104  return 0;
9105}
9106_ACEOF
9107if ac_fn_c_try_compile "$LINENO"
9108then :
9109  tcl_cv_DIR64=yes
9110else $as_nop
9111  tcl_cv_DIR64=no
9112fi
9113rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9114fi
9115{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_DIR64" >&5
9116printf "%s\n" "$tcl_cv_DIR64" >&6; }
9117	if test "x${tcl_cv_DIR64}" = "xyes" ; then
9118
9119printf "%s\n" "#define HAVE_DIR64 1" >>confdefs.h
9120
9121	fi
9122
9123	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct stat64" >&5
9124printf %s "checking for struct stat64... " >&6; }
9125if test ${tcl_cv_struct_stat64+y}
9126then :
9127  printf %s "(cached) " >&6
9128else $as_nop
9129
9130	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9131/* end confdefs.h.  */
9132#include <sys/stat.h>
9133int
9134main (void)
9135{
9136struct stat64 p;
9137
9138  ;
9139  return 0;
9140}
9141_ACEOF
9142if ac_fn_c_try_compile "$LINENO"
9143then :
9144  tcl_cv_struct_stat64=yes
9145else $as_nop
9146  tcl_cv_struct_stat64=no
9147fi
9148rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9149fi
9150{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_struct_stat64" >&5
9151printf "%s\n" "$tcl_cv_struct_stat64" >&6; }
9152	if test "x${tcl_cv_struct_stat64}" = "xyes" ; then
9153
9154printf "%s\n" "#define HAVE_STRUCT_STAT64 1" >>confdefs.h
9155
9156	fi
9157
9158	ac_fn_c_check_func "$LINENO" "open64" "ac_cv_func_open64"
9159if test "x$ac_cv_func_open64" = xyes
9160then :
9161  printf "%s\n" "#define HAVE_OPEN64 1" >>confdefs.h
9162
9163fi
9164ac_fn_c_check_func "$LINENO" "lseek64" "ac_cv_func_lseek64"
9165if test "x$ac_cv_func_lseek64" = xyes
9166then :
9167  printf "%s\n" "#define HAVE_LSEEK64 1" >>confdefs.h
9168
9169fi
9170
9171	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for off64_t" >&5
9172printf %s "checking for off64_t... " >&6; }
9173	if test ${tcl_cv_type_off64_t+y}
9174then :
9175  printf %s "(cached) " >&6
9176else $as_nop
9177
9178	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9179/* end confdefs.h.  */
9180#include <sys/types.h>
9181int
9182main (void)
9183{
9184off64_t offset;
9185
9186  ;
9187  return 0;
9188}
9189_ACEOF
9190if ac_fn_c_try_compile "$LINENO"
9191then :
9192  tcl_cv_type_off64_t=yes
9193else $as_nop
9194  tcl_cv_type_off64_t=no
9195fi
9196rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9197fi
9198
9199			if test "x${tcl_cv_type_off64_t}" = "xyes" && \
9200	        test "x${ac_cv_func_lseek64}" = "xyes" && \
9201	        test "x${ac_cv_func_open64}" = "xyes" ; then
9202
9203printf "%s\n" "#define HAVE_TYPE_OFF64_T 1" >>confdefs.h
9204
9205	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9206printf "%s\n" "yes" >&6; }
9207	else
9208	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
9209printf "%s\n" "no" >&6; }
9210	fi
9211    fi
9212
9213
9214
9215#--------------------------------------------------------------------
9216# Set the default compiler switches based on the --enable-symbols option.
9217#--------------------------------------------------------------------
9218
9219
9220
9221    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for build with symbols" >&5
9222printf %s "checking for build with symbols... " >&6; }
9223    # Check whether --enable-symbols was given.
9224if test ${enable_symbols+y}
9225then :
9226  enableval=$enable_symbols; tcl_ok=$enableval
9227else $as_nop
9228  tcl_ok=no
9229fi
9230
9231    if test "$tcl_ok" = "no"; then
9232	CFLAGS_DEFAULT="${CFLAGS_OPTIMIZE} -DNDEBUG"
9233	LDFLAGS_DEFAULT="${LDFLAGS_OPTIMIZE}"
9234	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
9235printf "%s\n" "no" >&6; }
9236
9237printf "%s\n" "#define TCL_CFG_OPTIMIZED 1" >>confdefs.h
9238
9239    else
9240	CFLAGS_DEFAULT="${CFLAGS_DEBUG}"
9241	LDFLAGS_DEFAULT="${LDFLAGS_DEBUG}"
9242	if test "$tcl_ok" = "yes"; then
9243	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes (standard debugging)" >&5
9244printf "%s\n" "yes (standard debugging)" >&6; }
9245	fi
9246    fi
9247
9248
9249
9250    if test "$tcl_ok" = "mem" -o "$tcl_ok" = "all"; then
9251
9252printf "%s\n" "#define TCL_MEM_DEBUG 1" >>confdefs.h
9253
9254    fi
9255
9256    if test "$tcl_ok" != "yes" -a "$tcl_ok" != "no"; then
9257	if test "$tcl_ok" = "all"; then
9258	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: enabled symbols mem debugging" >&5
9259printf "%s\n" "enabled symbols mem debugging" >&6; }
9260	else
9261	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: enabled $tcl_ok debugging" >&5
9262printf "%s\n" "enabled $tcl_ok debugging" >&6; }
9263	fi
9264    fi
9265
9266
9267#--------------------------------------------------------------------
9268# Integer pointer types used by the (U)INT2PTR / PTR2(U)INT macros.
9269#--------------------------------------------------------------------
9270
9271
9272  ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
9273if test "x$ac_cv_type_intptr_t" = xyes
9274then :
9275
9276printf "%s\n" "#define HAVE_INTPTR_T 1" >>confdefs.h
9277
9278else $as_nop
9279  for ac_type in 'int' 'long int' 'long long int'; do
9280       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9281/* end confdefs.h.  */
9282$ac_includes_default
9283int
9284main (void)
9285{
9286static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
9287test_array [0] = 0;
9288return test_array [0];
9289
9290  ;
9291  return 0;
9292}
9293_ACEOF
9294if ac_fn_c_try_compile "$LINENO"
9295then :
9296
9297printf "%s\n" "#define intptr_t $ac_type" >>confdefs.h
9298
9299	  ac_type=
9300fi
9301rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9302       test -z "$ac_type" && break
9303     done
9304fi
9305
9306
9307
9308  ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
9309if test "x$ac_cv_type_uintptr_t" = xyes
9310then :
9311
9312printf "%s\n" "#define HAVE_UINTPTR_T 1" >>confdefs.h
9313
9314else $as_nop
9315  for ac_type in 'unsigned int' 'unsigned long int' \
9316	'unsigned long long int'; do
9317       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9318/* end confdefs.h.  */
9319$ac_includes_default
9320int
9321main (void)
9322{
9323static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
9324test_array [0] = 0;
9325return test_array [0];
9326
9327  ;
9328  return 0;
9329}
9330_ACEOF
9331if ac_fn_c_try_compile "$LINENO"
9332then :
9333
9334printf "%s\n" "#define uintptr_t $ac_type" >>confdefs.h
9335
9336	  ac_type=
9337fi
9338rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9339       test -z "$ac_type" && break
9340     done
9341fi
9342
9343
9344
9345#--------------------------------------------------------------------
9346# Locate the ws2_32 library; we need it for ntohs and friends
9347#--------------------------------------------------------------------
9348
9349{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for main in -lws2_32" >&5
9350printf %s "checking for main in -lws2_32... " >&6; }
9351if test ${ac_cv_lib_ws2_32_main+y}
9352then :
9353  printf %s "(cached) " >&6
9354else $as_nop
9355  ac_check_lib_save_LIBS=$LIBS
9356LIBS="-lws2_32  $LIBS"
9357cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9358/* end confdefs.h.  */
9359
9360
9361int
9362main (void)
9363{
9364return main ();
9365  ;
9366  return 0;
9367}
9368_ACEOF
9369if ac_fn_c_try_link "$LINENO"
9370then :
9371  ac_cv_lib_ws2_32_main=yes
9372else $as_nop
9373  ac_cv_lib_ws2_32_main=no
9374fi
9375rm -f core conftest.err conftest.$ac_objext conftest.beam \
9376    conftest$ac_exeext conftest.$ac_ext
9377LIBS=$ac_check_lib_save_LIBS
9378fi
9379{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ws2_32_main" >&5
9380printf "%s\n" "$ac_cv_lib_ws2_32_main" >&6; }
9381if test "x$ac_cv_lib_ws2_32_main" = xyes
9382then :
9383
9384    vars="-lws2_32"
9385    for i in $vars; do
9386	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
9387	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
9388	    i=`echo "$i" | sed -e 's/^\(^-.*\)\.lLiIbB$/-l\1/'`
9389	fi
9390	PKG_LIBS="$PKG_LIBS $i"
9391    done
9392
9393
9394else $as_nop
9395
9396    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for main in -lwinsock" >&5
9397printf %s "checking for main in -lwinsock... " >&6; }
9398if test ${ac_cv_lib_winsock_main+y}
9399then :
9400  printf %s "(cached) " >&6
9401else $as_nop
9402  ac_check_lib_save_LIBS=$LIBS
9403LIBS="-lwinsock  $LIBS"
9404cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9405/* end confdefs.h.  */
9406
9407
9408int
9409main (void)
9410{
9411return main ();
9412  ;
9413  return 0;
9414}
9415_ACEOF
9416if ac_fn_c_try_link "$LINENO"
9417then :
9418  ac_cv_lib_winsock_main=yes
9419else $as_nop
9420  ac_cv_lib_winsock_main=no
9421fi
9422rm -f core conftest.err conftest.$ac_objext conftest.beam \
9423    conftest$ac_exeext conftest.$ac_ext
9424LIBS=$ac_check_lib_save_LIBS
9425fi
9426{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_winsock_main" >&5
9427printf "%s\n" "$ac_cv_lib_winsock_main" >&6; }
9428if test "x$ac_cv_lib_winsock_main" = xyes
9429then :
9430
9431    vars="-lwinsock"
9432    for i in $vars; do
9433	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
9434	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
9435	    i=`echo "$i" | sed -e 's/^\(^-.*\)\.lLiIbB$/-l\1/'`
9436	fi
9437	PKG_LIBS="$PKG_LIBS $i"
9438    done
9439
9440
9441fi
9442
9443
9444fi
9445
9446
9447#--------------------------------------------------------------------
9448# This macro generates a line to use when building a library.  It
9449# depends on values set by the TEA_ENABLE_SHARED, TEA_ENABLE_SYMBOLS,
9450# and TEA_LOAD_TCLCONFIG macros above.
9451#--------------------------------------------------------------------
9452
9453
9454{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
9455printf %s "checking for grep that handles long lines and -e... " >&6; }
9456if test ${ac_cv_path_GREP+y}
9457then :
9458  printf %s "(cached) " >&6
9459else $as_nop
9460  if test -z "$GREP"; then
9461  ac_path_GREP_found=false
9462  # Loop through the user's path and test for each of PROGNAME-LIST
9463  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9464for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
9465do
9466  IFS=$as_save_IFS
9467  case $as_dir in #(((
9468    '') as_dir=./ ;;
9469    */) ;;
9470    *) as_dir=$as_dir/ ;;
9471  esac
9472    for ac_prog in grep ggrep
9473   do
9474    for ac_exec_ext in '' $ac_executable_extensions; do
9475      ac_path_GREP="$as_dir$ac_prog$ac_exec_ext"
9476      as_fn_executable_p "$ac_path_GREP" || continue
9477# Check for GNU ac_path_GREP and select it if it is found.
9478  # Check for GNU $ac_path_GREP
9479case `"$ac_path_GREP" --version 2>&1` in
9480*GNU*)
9481  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
9482*)
9483  ac_count=0
9484  printf %s 0123456789 >"conftest.in"
9485  while :
9486  do
9487    cat "conftest.in" "conftest.in" >"conftest.tmp"
9488    mv "conftest.tmp" "conftest.in"
9489    cp "conftest.in" "conftest.nl"
9490    printf "%s\n" 'GREP' >> "conftest.nl"
9491    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
9492    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
9493    as_fn_arith $ac_count + 1 && ac_count=$as_val
9494    if test $ac_count -gt ${ac_path_GREP_max-0}; then
9495      # Best one so far, save it but keep looking for a better one
9496      ac_cv_path_GREP="$ac_path_GREP"
9497      ac_path_GREP_max=$ac_count
9498    fi
9499    # 10*(2^10) chars as input seems more than enough
9500    test $ac_count -gt 10 && break
9501  done
9502  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
9503esac
9504
9505      $ac_path_GREP_found && break 3
9506    done
9507  done
9508  done
9509IFS=$as_save_IFS
9510  if test -z "$ac_cv_path_GREP"; then
9511    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
9512  fi
9513else
9514  ac_cv_path_GREP=$GREP
9515fi
9516
9517fi
9518{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
9519printf "%s\n" "$ac_cv_path_GREP" >&6; }
9520 GREP="$ac_cv_path_GREP"
9521
9522
9523{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
9524printf %s "checking for egrep... " >&6; }
9525if test ${ac_cv_path_EGREP+y}
9526then :
9527  printf %s "(cached) " >&6
9528else $as_nop
9529  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
9530   then ac_cv_path_EGREP="$GREP -E"
9531   else
9532     if test -z "$EGREP"; then
9533  ac_path_EGREP_found=false
9534  # Loop through the user's path and test for each of PROGNAME-LIST
9535  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9536for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
9537do
9538  IFS=$as_save_IFS
9539  case $as_dir in #(((
9540    '') as_dir=./ ;;
9541    */) ;;
9542    *) as_dir=$as_dir/ ;;
9543  esac
9544    for ac_prog in egrep
9545   do
9546    for ac_exec_ext in '' $ac_executable_extensions; do
9547      ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext"
9548      as_fn_executable_p "$ac_path_EGREP" || continue
9549# Check for GNU ac_path_EGREP and select it if it is found.
9550  # Check for GNU $ac_path_EGREP
9551case `"$ac_path_EGREP" --version 2>&1` in
9552*GNU*)
9553  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
9554*)
9555  ac_count=0
9556  printf %s 0123456789 >"conftest.in"
9557  while :
9558  do
9559    cat "conftest.in" "conftest.in" >"conftest.tmp"
9560    mv "conftest.tmp" "conftest.in"
9561    cp "conftest.in" "conftest.nl"
9562    printf "%s\n" 'EGREP' >> "conftest.nl"
9563    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
9564    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
9565    as_fn_arith $ac_count + 1 && ac_count=$as_val
9566    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
9567      # Best one so far, save it but keep looking for a better one
9568      ac_cv_path_EGREP="$ac_path_EGREP"
9569      ac_path_EGREP_max=$ac_count
9570    fi
9571    # 10*(2^10) chars as input seems more than enough
9572    test $ac_count -gt 10 && break
9573  done
9574  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
9575esac
9576
9577      $ac_path_EGREP_found && break 3
9578    done
9579  done
9580  done
9581IFS=$as_save_IFS
9582  if test -z "$ac_cv_path_EGREP"; then
9583    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
9584  fi
9585else
9586  ac_cv_path_EGREP=$EGREP
9587fi
9588
9589   fi
9590fi
9591{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
9592printf "%s\n" "$ac_cv_path_EGREP" >&6; }
9593 EGREP="$ac_cv_path_EGREP"
9594
9595
9596
9597    if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes"; then
9598	MAKE_STATIC_LIB="\${STLIB_LD} -out:\$@ \$(PKG_OBJECTS)"
9599	MAKE_SHARED_LIB="\${SHLIB_LD} \${LDFLAGS} \${LDFLAGS_DEFAULT} -out:\$@ \$(PKG_OBJECTS) \${SHLIB_LD_LIBS}"
9600	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9601/* end confdefs.h.  */
9602
9603#if defined(_MSC_VER) && _MSC_VER >= 1400
9604print("manifest needed")
9605#endif
9606
9607_ACEOF
9608if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9609  $EGREP "manifest needed" >/dev/null 2>&1
9610then :
9611
9612	# Could do a CHECK_PROG for mt, but should always be with MSVC8+
9613	VC_MANIFEST_EMBED_DLL="if test -f \$@.manifest ; then mt.exe -nologo -manifest \$@.manifest -outputresource:\$@\;2 ; fi"
9614	VC_MANIFEST_EMBED_EXE="if test -f \$@.manifest ; then mt.exe -nologo -manifest \$@.manifest -outputresource:\$@\;1 ; fi"
9615	MAKE_SHARED_LIB="${MAKE_SHARED_LIB} ; ${VC_MANIFEST_EMBED_DLL}"
9616
9617    CLEANFILES="$CLEANFILES *.manifest"
9618
9619
9620fi
9621rm -rf conftest*
9622
9623	MAKE_STUB_LIB="\${STLIB_LD} -nodefaultlib -out:\$@ \$(PKG_STUB_OBJECTS)"
9624    else
9625	MAKE_STATIC_LIB="\${STLIB_LD} \$@ \$(PKG_OBJECTS)"
9626	MAKE_SHARED_LIB="\${SHLIB_LD} \${LDFLAGS} \${LDFLAGS_DEFAULT} -o \$@ \$(PKG_OBJECTS) \${SHLIB_LD_LIBS}"
9627	MAKE_STUB_LIB="\${STLIB_LD} \$@ \$(PKG_STUB_OBJECTS)"
9628    fi
9629
9630    if test "${SHARED_BUILD}" = "1" ; then
9631	MAKE_LIB="${MAKE_SHARED_LIB} "
9632    else
9633	MAKE_LIB="${MAKE_STATIC_LIB} "
9634    fi
9635
9636    #--------------------------------------------------------------------
9637    # Shared libraries and static libraries have different names.
9638    # Use the double eval to make sure any variables in the suffix is
9639    # substituted. (@@@ Might not be necessary anymore)
9640    #--------------------------------------------------------------------
9641
9642    PACKAGE_LIB_PREFIX8="${PACKAGE_LIB_PREFIX}"
9643    PACKAGE_LIB_PREFIX9="${PACKAGE_LIB_PREFIX}tcl9"
9644    if test "${TCL_MAJOR_VERSION}" -gt 8 ; then
9645	PACKAGE_LIB_PREFIX="${PACKAGE_LIB_PREFIX9}"
9646    else
9647	PACKAGE_LIB_PREFIX="${PACKAGE_LIB_PREFIX8}"
9648    fi
9649    if test "${TEA_PLATFORM}" = "windows" ; then
9650	if test "${SHARED_BUILD}" = "1" ; then
9651	    # We force the unresolved linking of symbols that are really in
9652	    # the private libraries of Tcl and Tk.
9653	    if test x"${TK_BIN_DIR}" != x ; then
9654		SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TK_BIN_DIR}/${TK_STUB_LIB_FILE}`\""
9655	    fi
9656	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}`\""
9657	    if test "$GCC" = "yes"; then
9658		SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -static-libgcc"
9659	    fi
9660	    eval eval "PKG_LIB_FILE8=${PACKAGE_LIB_PREFIX8}${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
9661	    eval eval "PKG_LIB_FILE9=${PACKAGE_LIB_PREFIX9}${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
9662	    eval eval "PKG_LIB_FILE=${PACKAGE_LIB_PREFIX}${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
9663	else
9664	    if test "$GCC" = "yes"; then
9665		PACKAGE_LIB_PREFIX=lib${PACKAGE_LIB_PREFIX}
9666	    fi
9667	    eval eval "PKG_LIB_FILE8=${PACKAGE_LIB_PREFIX8}${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
9668	    eval eval "PKG_LIB_FILE9=${PACKAGE_LIB_PREFIX9}${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
9669	    eval eval "PKG_LIB_FILE=${PACKAGE_LIB_PREFIX}${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
9670	fi
9671	# Some packages build their own stubs libraries
9672	eval eval "PKG_STUB_LIB_FILE=${PACKAGE_LIB_PREFIX}${PACKAGE_NAME}stub${UNSHARED_LIB_SUFFIX}"
9673	if test "$GCC" = "yes"; then
9674	    PKG_STUB_LIB_FILE=lib${PKG_STUB_LIB_FILE}
9675	fi
9676	# These aren't needed on Windows (either MSVC or gcc)
9677	RANLIB=:
9678	RANLIB_STUB=:
9679    else
9680	RANLIB_STUB="${RANLIB}"
9681	if test "${SHARED_BUILD}" = "1" ; then
9682	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TCL_STUB_LIB_SPEC}"
9683	    if test x"${TK_BIN_DIR}" != x ; then
9684		SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TK_STUB_LIB_SPEC}"
9685	    fi
9686	    eval eval "PKG_LIB_FILE8=lib${PACKAGE_LIB_PREFIX8}${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
9687	    eval eval "PKG_LIB_FILE9=lib${PACKAGE_LIB_PREFIX9}${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
9688	    eval eval "PKG_LIB_FILE=lib${PACKAGE_LIB_PREFIX}${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
9689	    RANLIB=:
9690	else
9691	    eval eval "PKG_LIB_FILE=lib${PACKAGE_LIB_PREFIX8}${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
9692	    eval eval "PKG_LIB_FILE=lib${PACKAGE_LIB_PREFIX9}${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
9693	    eval eval "PKG_LIB_FILE=lib${PACKAGE_LIB_PREFIX}${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
9694	fi
9695	# Some packages build their own stubs libraries
9696	eval eval "PKG_STUB_LIB_FILE=lib${PACKAGE_LIB_PREFIX8}${PACKAGE_NAME}stub${UNSHARED_LIB_SUFFIX}"
9697    fi
9698
9699    # These are escaped so that only CFLAGS is picked up at configure time.
9700    # The other values will be substituted at make time.
9701    CFLAGS="${CFLAGS} \${CFLAGS_DEFAULT} \${CFLAGS_WARNING}"
9702    if test "${SHARED_BUILD}" = "1" ; then
9703	CFLAGS="${CFLAGS} \${SHLIB_CFLAGS}"
9704    fi
9705
9706
9707
9708
9709
9710
9711
9712
9713
9714
9715#--------------------------------------------------------------------
9716# Determine the name of the tclsh and/or wish executables in the
9717# Tcl and Tk build directories or the location they were installed
9718# into. These paths are used to support running test cases only,
9719# the Makefile should not be making use of these paths to generate
9720# a pkgIndex.tcl file or anything else at extension build time.
9721#--------------------------------------------------------------------
9722
9723
9724    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tclsh" >&5
9725printf %s "checking for tclsh... " >&6; }
9726    if test -f "${TCL_BIN_DIR}/Makefile" ; then
9727        # tclConfig.sh is in Tcl build directory
9728        if test "${TEA_PLATFORM}" = "windows"; then
9729          if test -f "${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${EXEEXT}" ; then
9730            TCLSH_PROG="${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${EXEEXT}"
9731          elif test -f "${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}s${EXEEXT}" ; then
9732            TCLSH_PROG="${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}s${EXEEXT}"
9733          elif test -f "${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}t${EXEEXT}" ; then
9734            TCLSH_PROG="${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}t${EXEEXT}"
9735          elif test -f "${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}st${EXEEXT}" ; then
9736            TCLSH_PROG="${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}st${EXEEXT}"
9737          fi
9738        else
9739            TCLSH_PROG="${TCL_BIN_DIR}/tclsh"
9740        fi
9741    else
9742        # tclConfig.sh is in install location
9743        if test "${TEA_PLATFORM}" = "windows"; then
9744            TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${EXEEXT}"
9745        else
9746            TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}.${TCL_MINOR_VERSION}"
9747        fi
9748        list="`ls -d ${TCL_BIN_DIR}/../bin 2>/dev/null` \
9749              `ls -d ${TCL_BIN_DIR}/..     2>/dev/null` \
9750              `ls -d ${TCL_PREFIX}/bin     2>/dev/null`"
9751        for i in $list ; do
9752            if test -f "$i/${TCLSH_PROG}" ; then
9753                REAL_TCL_BIN_DIR="`cd "$i"; pwd`/"
9754                break
9755            fi
9756        done
9757        TCLSH_PROG="${REAL_TCL_BIN_DIR}${TCLSH_PROG}"
9758    fi
9759    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${TCLSH_PROG}" >&5
9760printf "%s\n" "${TCLSH_PROG}" >&6; }
9761
9762
9763#TEA_PROG_WISH
9764
9765#--------------------------------------------------------------------
9766# Finally, substitute all of the various values into the Makefile.
9767# You may alternatively have a special pkgIndex.tcl.in or other files
9768# which require substituting the AC variables in. Include these here.
9769#--------------------------------------------------------------------
9770
9771ac_config_files="$ac_config_files Makefile pkgIndex.tcl"
9772
9773cat >confcache <<\_ACEOF
9774# This file is a shell script that caches the results of configure
9775# tests run on this system so they can be shared between configure
9776# scripts and configure runs, see configure's option --config-cache.
9777# It is not useful on other systems.  If it contains results you don't
9778# want to keep, you may remove or edit it.
9779#
9780# config.status only pays attention to the cache file if you give it
9781# the --recheck option to rerun configure.
9782#
9783# `ac_cv_env_foo' variables (set or unset) will be overridden when
9784# loading this file, other *unset* `ac_cv_foo' will be assigned the
9785# following values.
9786
9787_ACEOF
9788
9789# The following way of writing the cache mishandles newlines in values,
9790# but we know of no workaround that is simple, portable, and efficient.
9791# So, we kill variables containing newlines.
9792# Ultrix sh set writes to stderr and can't be redirected directly,
9793# and sets the high bit in the cache file unless we assign to the vars.
9794(
9795  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
9796    eval ac_val=\$$ac_var
9797    case $ac_val in #(
9798    *${as_nl}*)
9799      case $ac_var in #(
9800      *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
9801printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
9802      esac
9803      case $ac_var in #(
9804      _ | IFS | as_nl) ;; #(
9805      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
9806      *) { eval $ac_var=; unset $ac_var;} ;;
9807      esac ;;
9808    esac
9809  done
9810
9811  (set) 2>&1 |
9812    case $as_nl`(ac_space=' '; set) 2>&1` in #(
9813    *${as_nl}ac_space=\ *)
9814      # `set' does not quote correctly, so add quotes: double-quote
9815      # substitution turns \\\\ into \\, and sed turns \\ into \.
9816      sed -n \
9817	"s/'/'\\\\''/g;
9818	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
9819      ;; #(
9820    *)
9821      # `set' quotes correctly as required by POSIX, so do not add quotes.
9822      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
9823      ;;
9824    esac |
9825    sort
9826) |
9827  sed '
9828     /^ac_cv_env_/b end
9829     t clear
9830     :clear
9831     s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/
9832     t end
9833     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
9834     :end' >>confcache
9835if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
9836  if test -w "$cache_file"; then
9837    if test "x$cache_file" != "x/dev/null"; then
9838      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
9839printf "%s\n" "$as_me: updating cache $cache_file" >&6;}
9840      if test ! -f "$cache_file" || test -h "$cache_file"; then
9841	cat confcache >"$cache_file"
9842      else
9843        case $cache_file in #(
9844        */* | ?:*)
9845	  mv -f confcache "$cache_file"$$ &&
9846	  mv -f "$cache_file"$$ "$cache_file" ;; #(
9847        *)
9848	  mv -f confcache "$cache_file" ;;
9849	esac
9850      fi
9851    fi
9852  else
9853    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
9854printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;}
9855  fi
9856fi
9857rm -f confcache
9858
9859test "x$prefix" = xNONE && prefix=$ac_default_prefix
9860# Let make expand exec_prefix.
9861test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
9862
9863# Transform confdefs.h into DEFS.
9864# Protect against shell expansion while executing Makefile rules.
9865# Protect against Makefile macro expansion.
9866#
9867# If the first sed substitution is executed (which looks for macros that
9868# take arguments), then branch to the quote section.  Otherwise,
9869# look for a macro that doesn't take arguments.
9870ac_script='
9871:mline
9872/\\$/{
9873 N
9874 s,\\\n,,
9875 b mline
9876}
9877t clear
9878:clear
9879s/^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 (][^	 (]*([^)]*)\)[	 ]*\(.*\)/-D\1=\2/g
9880t quote
9881s/^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 ][^	 ]*\)[	 ]*\(.*\)/-D\1=\2/g
9882t quote
9883b any
9884:quote
9885s/[	 `~#$^&*(){}\\|;'\''"<>?]/\\&/g
9886s/\[/\\&/g
9887s/\]/\\&/g
9888s/\$/$$/g
9889H
9890:any
9891${
9892	g
9893	s/^\n//
9894	s/\n/ /g
9895	p
9896}
9897'
9898DEFS=`sed -n "$ac_script" confdefs.h`
9899
9900
9901ac_libobjs=
9902ac_ltlibobjs=
9903U=
9904for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
9905  # 1. Remove the extension, and $U if already installed.
9906  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
9907  ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"`
9908  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
9909  #    will be set to the directory where LIBOBJS objects are built.
9910  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
9911  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
9912done
9913LIBOBJS=$ac_libobjs
9914
9915LTLIBOBJS=$ac_ltlibobjs
9916
9917
9918
9919CFLAGS="${CFLAGS} ${CPPFLAGS}"; CPPFLAGS=""
9920
9921: "${CONFIG_STATUS=./config.status}"
9922ac_write_fail=0
9923ac_clean_files_save=$ac_clean_files
9924ac_clean_files="$ac_clean_files $CONFIG_STATUS"
9925{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
9926printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;}
9927as_write_fail=0
9928cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
9929#! $SHELL
9930# Generated by $as_me.
9931# Run this file to recreate the current configuration.
9932# Compiler output produced by configure, useful for debugging
9933# configure, is in config.log if it exists.
9934
9935debug=false
9936ac_cs_recheck=false
9937ac_cs_silent=false
9938
9939SHELL=\${CONFIG_SHELL-$SHELL}
9940export SHELL
9941_ASEOF
9942cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
9943## -------------------- ##
9944## M4sh Initialization. ##
9945## -------------------- ##
9946
9947# Be more Bourne compatible
9948DUALCASE=1; export DUALCASE # for MKS sh
9949as_nop=:
9950if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
9951then :
9952  emulate sh
9953  NULLCMD=:
9954  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
9955  # is contrary to our usage.  Disable this feature.
9956  alias -g '${1+"$@"}'='"$@"'
9957  setopt NO_GLOB_SUBST
9958else $as_nop
9959  case `(set -o) 2>/dev/null` in #(
9960  *posix*) :
9961    set -o posix ;; #(
9962  *) :
9963     ;;
9964esac
9965fi
9966
9967
9968
9969# Reset variables that may have inherited troublesome values from
9970# the environment.
9971
9972# IFS needs to be set, to space, tab, and newline, in precisely that order.
9973# (If _AS_PATH_WALK were called with IFS unset, it would have the
9974# side effect of setting IFS to empty, thus disabling word splitting.)
9975# Quoting is to prevent editors from complaining about space-tab.
9976as_nl='
9977'
9978export as_nl
9979IFS=" ""	$as_nl"
9980
9981PS1='$ '
9982PS2='> '
9983PS4='+ '
9984
9985# Ensure predictable behavior from utilities with locale-dependent output.
9986LC_ALL=C
9987export LC_ALL
9988LANGUAGE=C
9989export LANGUAGE
9990
9991# We cannot yet rely on "unset" to work, but we need these variables
9992# to be unset--not just set to an empty or harmless value--now, to
9993# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh).  This construct
9994# also avoids known problems related to "unset" and subshell syntax
9995# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
9996for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
9997do eval test \${$as_var+y} \
9998  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
9999done
10000
10001# Ensure that fds 0, 1, and 2 are open.
10002if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
10003if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
10004if (exec 3>&2)            ; then :; else exec 2>/dev/null; fi
10005
10006# The user is always right.
10007if ${PATH_SEPARATOR+false} :; then
10008  PATH_SEPARATOR=:
10009  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
10010    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
10011      PATH_SEPARATOR=';'
10012  }
10013fi
10014
10015
10016# Find who we are.  Look in the path if we contain no directory separator.
10017as_myself=
10018case $0 in #((
10019  *[\\/]* ) as_myself=$0 ;;
10020  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10021for as_dir in $PATH
10022do
10023  IFS=$as_save_IFS
10024  case $as_dir in #(((
10025    '') as_dir=./ ;;
10026    */) ;;
10027    *) as_dir=$as_dir/ ;;
10028  esac
10029    test -r "$as_dir$0" && as_myself=$as_dir$0 && break
10030  done
10031IFS=$as_save_IFS
10032
10033     ;;
10034esac
10035# We did not find ourselves, most probably we were run as `sh COMMAND'
10036# in which case we are not to be found in the path.
10037if test "x$as_myself" = x; then
10038  as_myself=$0
10039fi
10040if test ! -f "$as_myself"; then
10041  printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
10042  exit 1
10043fi
10044
10045
10046
10047# as_fn_error STATUS ERROR [LINENO LOG_FD]
10048# ----------------------------------------
10049# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
10050# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
10051# script with STATUS, using 1 if that was 0.
10052as_fn_error ()
10053{
10054  as_status=$1; test $as_status -eq 0 && as_status=1
10055  if test "$4"; then
10056    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
10057    printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
10058  fi
10059  printf "%s\n" "$as_me: error: $2" >&2
10060  as_fn_exit $as_status
10061} # as_fn_error
10062
10063
10064
10065# as_fn_set_status STATUS
10066# -----------------------
10067# Set $? to STATUS, without forking.
10068as_fn_set_status ()
10069{
10070  return $1
10071} # as_fn_set_status
10072
10073# as_fn_exit STATUS
10074# -----------------
10075# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
10076as_fn_exit ()
10077{
10078  set +e
10079  as_fn_set_status $1
10080  exit $1
10081} # as_fn_exit
10082
10083# as_fn_unset VAR
10084# ---------------
10085# Portably unset VAR.
10086as_fn_unset ()
10087{
10088  { eval $1=; unset $1;}
10089}
10090as_unset=as_fn_unset
10091
10092# as_fn_append VAR VALUE
10093# ----------------------
10094# Append the text in VALUE to the end of the definition contained in VAR. Take
10095# advantage of any shell optimizations that allow amortized linear growth over
10096# repeated appends, instead of the typical quadratic growth present in naive
10097# implementations.
10098if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
10099then :
10100  eval 'as_fn_append ()
10101  {
10102    eval $1+=\$2
10103  }'
10104else $as_nop
10105  as_fn_append ()
10106  {
10107    eval $1=\$$1\$2
10108  }
10109fi # as_fn_append
10110
10111# as_fn_arith ARG...
10112# ------------------
10113# Perform arithmetic evaluation on the ARGs, and store the result in the
10114# global $as_val. Take advantage of shells that can avoid forks. The arguments
10115# must be portable across $(()) and expr.
10116if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
10117then :
10118  eval 'as_fn_arith ()
10119  {
10120    as_val=$(( $* ))
10121  }'
10122else $as_nop
10123  as_fn_arith ()
10124  {
10125    as_val=`expr "$@" || test $? -eq 1`
10126  }
10127fi # as_fn_arith
10128
10129
10130if expr a : '\(a\)' >/dev/null 2>&1 &&
10131   test "X`expr 00001 : '.*\(...\)'`" = X001; then
10132  as_expr=expr
10133else
10134  as_expr=false
10135fi
10136
10137if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
10138  as_basename=basename
10139else
10140  as_basename=false
10141fi
10142
10143if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
10144  as_dirname=dirname
10145else
10146  as_dirname=false
10147fi
10148
10149as_me=`$as_basename -- "$0" ||
10150$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
10151	 X"$0" : 'X\(//\)$' \| \
10152	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
10153printf "%s\n" X/"$0" |
10154    sed '/^.*\/\([^/][^/]*\)\/*$/{
10155	    s//\1/
10156	    q
10157	  }
10158	  /^X\/\(\/\/\)$/{
10159	    s//\1/
10160	    q
10161	  }
10162	  /^X\/\(\/\).*/{
10163	    s//\1/
10164	    q
10165	  }
10166	  s/.*/./; q'`
10167
10168# Avoid depending upon Character Ranges.
10169as_cr_letters='abcdefghijklmnopqrstuvwxyz'
10170as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
10171as_cr_Letters=$as_cr_letters$as_cr_LETTERS
10172as_cr_digits='0123456789'
10173as_cr_alnum=$as_cr_Letters$as_cr_digits
10174
10175
10176# Determine whether it's possible to make 'echo' print without a newline.
10177# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
10178# for compatibility with existing Makefiles.
10179ECHO_C= ECHO_N= ECHO_T=
10180case `echo -n x` in #(((((
10181-n*)
10182  case `echo 'xy\c'` in
10183  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
10184  xy)  ECHO_C='\c';;
10185  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
10186       ECHO_T='	';;
10187  esac;;
10188*)
10189  ECHO_N='-n';;
10190esac
10191
10192# For backward compatibility with old third-party macros, we provide
10193# the shell variables $as_echo and $as_echo_n.  New code should use
10194# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
10195as_echo='printf %s\n'
10196as_echo_n='printf %s'
10197
10198rm -f conf$$ conf$$.exe conf$$.file
10199if test -d conf$$.dir; then
10200  rm -f conf$$.dir/conf$$.file
10201else
10202  rm -f conf$$.dir
10203  mkdir conf$$.dir 2>/dev/null
10204fi
10205if (echo >conf$$.file) 2>/dev/null; then
10206  if ln -s conf$$.file conf$$ 2>/dev/null; then
10207    as_ln_s='ln -s'
10208    # ... but there are two gotchas:
10209    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
10210    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
10211    # In both cases, we have to default to `cp -pR'.
10212    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
10213      as_ln_s='cp -pR'
10214  elif ln conf$$.file conf$$ 2>/dev/null; then
10215    as_ln_s=ln
10216  else
10217    as_ln_s='cp -pR'
10218  fi
10219else
10220  as_ln_s='cp -pR'
10221fi
10222rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
10223rmdir conf$$.dir 2>/dev/null
10224
10225
10226# as_fn_mkdir_p
10227# -------------
10228# Create "$as_dir" as a directory, including parents if necessary.
10229as_fn_mkdir_p ()
10230{
10231
10232  case $as_dir in #(
10233  -*) as_dir=./$as_dir;;
10234  esac
10235  test -d "$as_dir" || eval $as_mkdir_p || {
10236    as_dirs=
10237    while :; do
10238      case $as_dir in #(
10239      *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
10240      *) as_qdir=$as_dir;;
10241      esac
10242      as_dirs="'$as_qdir' $as_dirs"
10243      as_dir=`$as_dirname -- "$as_dir" ||
10244$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
10245	 X"$as_dir" : 'X\(//\)[^/]' \| \
10246	 X"$as_dir" : 'X\(//\)$' \| \
10247	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
10248printf "%s\n" X"$as_dir" |
10249    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
10250	    s//\1/
10251	    q
10252	  }
10253	  /^X\(\/\/\)[^/].*/{
10254	    s//\1/
10255	    q
10256	  }
10257	  /^X\(\/\/\)$/{
10258	    s//\1/
10259	    q
10260	  }
10261	  /^X\(\/\).*/{
10262	    s//\1/
10263	    q
10264	  }
10265	  s/.*/./; q'`
10266      test -d "$as_dir" && break
10267    done
10268    test -z "$as_dirs" || eval "mkdir $as_dirs"
10269  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
10270
10271
10272} # as_fn_mkdir_p
10273if mkdir -p . 2>/dev/null; then
10274  as_mkdir_p='mkdir -p "$as_dir"'
10275else
10276  test -d ./-p && rmdir ./-p
10277  as_mkdir_p=false
10278fi
10279
10280
10281# as_fn_executable_p FILE
10282# -----------------------
10283# Test if FILE is an executable regular file.
10284as_fn_executable_p ()
10285{
10286  test -f "$1" && test -x "$1"
10287} # as_fn_executable_p
10288as_test_x='test -x'
10289as_executable_p=as_fn_executable_p
10290
10291# Sed expression to map a string onto a valid CPP name.
10292as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
10293
10294# Sed expression to map a string onto a valid variable name.
10295as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
10296
10297
10298exec 6>&1
10299## ----------------------------------- ##
10300## Main body of $CONFIG_STATUS script. ##
10301## ----------------------------------- ##
10302_ASEOF
10303test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
10304
10305cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10306# Save the log message, to keep $0 and so on meaningful, and to
10307# report actual input values of CONFIG_FILES etc. instead of their
10308# values after options handling.
10309ac_log="
10310This file was extended by tdbcpostgres $as_me 1.1.3, which was
10311generated by GNU Autoconf 2.70.  Invocation command line was
10312
10313  CONFIG_FILES    = $CONFIG_FILES
10314  CONFIG_HEADERS  = $CONFIG_HEADERS
10315  CONFIG_LINKS    = $CONFIG_LINKS
10316  CONFIG_COMMANDS = $CONFIG_COMMANDS
10317  $ $0 $@
10318
10319on `(hostname || uname -n) 2>/dev/null | sed 1q`
10320"
10321
10322_ACEOF
10323
10324case $ac_config_files in *"
10325"*) set x $ac_config_files; shift; ac_config_files=$*;;
10326esac
10327
10328
10329
10330cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10331# Files that config.status was made for.
10332config_files="$ac_config_files"
10333
10334_ACEOF
10335
10336cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10337ac_cs_usage="\
10338\`$as_me' instantiates files and other configuration actions
10339from templates according to the current configuration.  Unless the files
10340and actions are specified as TAGs, all are instantiated by default.
10341
10342Usage: $0 [OPTION]... [TAG]...
10343
10344  -h, --help       print this help, then exit
10345  -V, --version    print version number and configuration settings, then exit
10346      --config     print configuration, then exit
10347  -q, --quiet, --silent
10348                   do not print progress messages
10349  -d, --debug      don't remove temporary files
10350      --recheck    update $as_me by reconfiguring in the same conditions
10351      --file=FILE[:TEMPLATE]
10352                   instantiate the configuration file FILE
10353
10354Configuration files:
10355$config_files
10356
10357Report bugs to the package provider."
10358
10359_ACEOF
10360ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"`
10361ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"`
10362cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10363ac_cs_config='$ac_cs_config_escaped'
10364ac_cs_version="\\
10365tdbcpostgres config.status 1.1.3
10366configured by $0, generated by GNU Autoconf 2.70,
10367  with options \\"\$ac_cs_config\\"
10368
10369Copyright (C) 2020 Free Software Foundation, Inc.
10370This config.status script is free software; the Free Software Foundation
10371gives unlimited permission to copy, distribute and modify it."
10372
10373ac_pwd='$ac_pwd'
10374srcdir='$srcdir'
10375test -n "\$AWK" || AWK=awk
10376_ACEOF
10377
10378cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10379# The default lists apply if the user does not specify any file.
10380ac_need_defaults=:
10381while test $# != 0
10382do
10383  case $1 in
10384  --*=?*)
10385    ac_option=`expr "X$1" : 'X\([^=]*\)='`
10386    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
10387    ac_shift=:
10388    ;;
10389  --*=)
10390    ac_option=`expr "X$1" : 'X\([^=]*\)='`
10391    ac_optarg=
10392    ac_shift=:
10393    ;;
10394  *)
10395    ac_option=$1
10396    ac_optarg=$2
10397    ac_shift=shift
10398    ;;
10399  esac
10400
10401  case $ac_option in
10402  # Handling of the options.
10403  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
10404    ac_cs_recheck=: ;;
10405  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
10406    printf "%s\n" "$ac_cs_version"; exit ;;
10407  --config | --confi | --conf | --con | --co | --c )
10408    printf "%s\n" "$ac_cs_config"; exit ;;
10409  --debug | --debu | --deb | --de | --d | -d )
10410    debug=: ;;
10411  --file | --fil | --fi | --f )
10412    $ac_shift
10413    case $ac_optarg in
10414    *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
10415    '') as_fn_error $? "missing file argument" ;;
10416    esac
10417    as_fn_append CONFIG_FILES " '$ac_optarg'"
10418    ac_need_defaults=false;;
10419  --he | --h |  --help | --hel | -h )
10420    printf "%s\n" "$ac_cs_usage"; exit ;;
10421  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
10422  | -silent | --silent | --silen | --sile | --sil | --si | --s)
10423    ac_cs_silent=: ;;
10424
10425  # This is an error.
10426  -*) as_fn_error $? "unrecognized option: \`$1'
10427Try \`$0 --help' for more information." ;;
10428
10429  *) as_fn_append ac_config_targets " $1"
10430     ac_need_defaults=false ;;
10431
10432  esac
10433  shift
10434done
10435
10436ac_configure_extra_args=
10437
10438if $ac_cs_silent; then
10439  exec 6>/dev/null
10440  ac_configure_extra_args="$ac_configure_extra_args --silent"
10441fi
10442
10443_ACEOF
10444cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10445if \$ac_cs_recheck; then
10446  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
10447  shift
10448  \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6
10449  CONFIG_SHELL='$SHELL'
10450  export CONFIG_SHELL
10451  exec "\$@"
10452fi
10453
10454_ACEOF
10455cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10456exec 5>>config.log
10457{
10458  echo
10459  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
10460## Running $as_me. ##
10461_ASBOX
10462  printf "%s\n" "$ac_log"
10463} >&5
10464
10465_ACEOF
10466cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10467_ACEOF
10468
10469cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10470
10471# Handling of arguments.
10472for ac_config_target in $ac_config_targets
10473do
10474  case $ac_config_target in
10475    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
10476    "pkgIndex.tcl") CONFIG_FILES="$CONFIG_FILES pkgIndex.tcl" ;;
10477
10478  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
10479  esac
10480done
10481
10482
10483# If the user did not use the arguments to specify the items to instantiate,
10484# then the envvar interface is used.  Set only those that are not.
10485# We use the long form for the default assignment because of an extremely
10486# bizarre bug on SunOS 4.1.3.
10487if $ac_need_defaults; then
10488  test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files
10489fi
10490
10491# Have a temporary directory for convenience.  Make it in the build tree
10492# simply because there is no reason against having it here, and in addition,
10493# creating and moving files from /tmp can sometimes cause problems.
10494# Hook for its removal unless debugging.
10495# Note that there is a small window in which the directory will not be cleaned:
10496# after its creation but before its name has been assigned to `$tmp'.
10497$debug ||
10498{
10499  tmp= ac_tmp=
10500  trap 'exit_status=$?
10501  : "${ac_tmp:=$tmp}"
10502  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
10503' 0
10504  trap 'as_fn_exit 1' 1 2 13 15
10505}
10506# Create a (secure) tmp directory for tmp files.
10507
10508{
10509  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
10510  test -d "$tmp"
10511}  ||
10512{
10513  tmp=./conf$$-$RANDOM
10514  (umask 077 && mkdir "$tmp")
10515} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
10516ac_tmp=$tmp
10517
10518# Set up the scripts for CONFIG_FILES section.
10519# No need to generate them if there are no CONFIG_FILES.
10520# This happens for instance with `./config.status config.h'.
10521if test -n "$CONFIG_FILES"; then
10522
10523
10524ac_cr=`echo X | tr X '\015'`
10525# On cygwin, bash can eat \r inside `` if the user requested igncr.
10526# But we know of no other shell where ac_cr would be empty at this
10527# point, so we can use a bashism as a fallback.
10528if test "x$ac_cr" = x; then
10529  eval ac_cr=\$\'\\r\'
10530fi
10531ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
10532if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
10533  ac_cs_awk_cr='\\r'
10534else
10535  ac_cs_awk_cr=$ac_cr
10536fi
10537
10538echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
10539_ACEOF
10540
10541
10542{
10543  echo "cat >conf$$subs.awk <<_ACEOF" &&
10544  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
10545  echo "_ACEOF"
10546} >conf$$subs.sh ||
10547  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
10548ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
10549ac_delim='%!_!# '
10550for ac_last_try in false false false false false :; do
10551  . ./conf$$subs.sh ||
10552    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
10553
10554  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
10555  if test $ac_delim_n = $ac_delim_num; then
10556    break
10557  elif $ac_last_try; then
10558    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
10559  else
10560    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
10561  fi
10562done
10563rm -f conf$$subs.sh
10564
10565cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10566cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
10567_ACEOF
10568sed -n '
10569h
10570s/^/S["/; s/!.*/"]=/
10571p
10572g
10573s/^[^!]*!//
10574:repl
10575t repl
10576s/'"$ac_delim"'$//
10577t delim
10578:nl
10579h
10580s/\(.\{148\}\)..*/\1/
10581t more1
10582s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
10583p
10584n
10585b repl
10586:more1
10587s/["\\]/\\&/g; s/^/"/; s/$/"\\/
10588p
10589g
10590s/.\{148\}//
10591t nl
10592:delim
10593h
10594s/\(.\{148\}\)..*/\1/
10595t more2
10596s/["\\]/\\&/g; s/^/"/; s/$/"/
10597p
10598b
10599:more2
10600s/["\\]/\\&/g; s/^/"/; s/$/"\\/
10601p
10602g
10603s/.\{148\}//
10604t delim
10605' <conf$$subs.awk | sed '
10606/^[^""]/{
10607  N
10608  s/\n//
10609}
10610' >>$CONFIG_STATUS || ac_write_fail=1
10611rm -f conf$$subs.awk
10612cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10613_ACAWK
10614cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
10615  for (key in S) S_is_set[key] = 1
10616  FS = ""
10617
10618}
10619{
10620  line = $ 0
10621  nfields = split(line, field, "@")
10622  substed = 0
10623  len = length(field[1])
10624  for (i = 2; i < nfields; i++) {
10625    key = field[i]
10626    keylen = length(key)
10627    if (S_is_set[key]) {
10628      value = S[key]
10629      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
10630      len += length(value) + length(field[++i])
10631      substed = 1
10632    } else
10633      len += 1 + keylen
10634  }
10635
10636  print line
10637}
10638
10639_ACAWK
10640_ACEOF
10641cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10642if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
10643  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
10644else
10645  cat
10646fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
10647  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
10648_ACEOF
10649
10650# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
10651# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
10652# trailing colons and then remove the whole line if VPATH becomes empty
10653# (actually we leave an empty line to preserve line numbers).
10654if test "x$srcdir" = x.; then
10655  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
10656h
10657s///
10658s/^/:/
10659s/[	 ]*$/:/
10660s/:\$(srcdir):/:/g
10661s/:\${srcdir}:/:/g
10662s/:@srcdir@:/:/g
10663s/^:*//
10664s/:*$//
10665x
10666s/\(=[	 ]*\).*/\1/
10667G
10668s/\n//
10669s/^[^=]*=[	 ]*$//
10670}'
10671fi
10672
10673cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10674fi # test -n "$CONFIG_FILES"
10675
10676
10677eval set X "  :F $CONFIG_FILES      "
10678shift
10679for ac_tag
10680do
10681  case $ac_tag in
10682  :[FHLC]) ac_mode=$ac_tag; continue;;
10683  esac
10684  case $ac_mode$ac_tag in
10685  :[FHL]*:*);;
10686  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
10687  :[FH]-) ac_tag=-:-;;
10688  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
10689  esac
10690  ac_save_IFS=$IFS
10691  IFS=:
10692  set x $ac_tag
10693  IFS=$ac_save_IFS
10694  shift
10695  ac_file=$1
10696  shift
10697
10698  case $ac_mode in
10699  :L) ac_source=$1;;
10700  :[FH])
10701    ac_file_inputs=
10702    for ac_f
10703    do
10704      case $ac_f in
10705      -) ac_f="$ac_tmp/stdin";;
10706      *) # Look for the file first in the build tree, then in the source tree
10707	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
10708	 # because $ac_f cannot contain `:'.
10709	 test -f "$ac_f" ||
10710	   case $ac_f in
10711	   [\\/$]*) false;;
10712	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
10713	   esac ||
10714	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
10715      esac
10716      case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
10717      as_fn_append ac_file_inputs " '$ac_f'"
10718    done
10719
10720    # Let's still pretend it is `configure' which instantiates (i.e., don't
10721    # use $as_me), people would be surprised to read:
10722    #    /* config.h.  Generated by config.status.  */
10723    configure_input='Generated from '`
10724	  printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
10725	`' by configure.'
10726    if test x"$ac_file" != x-; then
10727      configure_input="$ac_file.  $configure_input"
10728      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
10729printf "%s\n" "$as_me: creating $ac_file" >&6;}
10730    fi
10731    # Neutralize special characters interpreted by sed in replacement strings.
10732    case $configure_input in #(
10733    *\&* | *\|* | *\\* )
10734       ac_sed_conf_input=`printf "%s\n" "$configure_input" |
10735       sed 's/[\\\\&|]/\\\\&/g'`;; #(
10736    *) ac_sed_conf_input=$configure_input;;
10737    esac
10738
10739    case $ac_tag in
10740    *:-:* | *:-) cat >"$ac_tmp/stdin" \
10741      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
10742    esac
10743    ;;
10744  esac
10745
10746  ac_dir=`$as_dirname -- "$ac_file" ||
10747$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
10748	 X"$ac_file" : 'X\(//\)[^/]' \| \
10749	 X"$ac_file" : 'X\(//\)$' \| \
10750	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
10751printf "%s\n" X"$ac_file" |
10752    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
10753	    s//\1/
10754	    q
10755	  }
10756	  /^X\(\/\/\)[^/].*/{
10757	    s//\1/
10758	    q
10759	  }
10760	  /^X\(\/\/\)$/{
10761	    s//\1/
10762	    q
10763	  }
10764	  /^X\(\/\).*/{
10765	    s//\1/
10766	    q
10767	  }
10768	  s/.*/./; q'`
10769  as_dir="$ac_dir"; as_fn_mkdir_p
10770  ac_builddir=.
10771
10772case "$ac_dir" in
10773.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
10774*)
10775  ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
10776  # A ".." for each directory in $ac_dir_suffix.
10777  ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
10778  case $ac_top_builddir_sub in
10779  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
10780  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
10781  esac ;;
10782esac
10783ac_abs_top_builddir=$ac_pwd
10784ac_abs_builddir=$ac_pwd$ac_dir_suffix
10785# for backward compatibility:
10786ac_top_builddir=$ac_top_build_prefix
10787
10788case $srcdir in
10789  .)  # We are building in place.
10790    ac_srcdir=.
10791    ac_top_srcdir=$ac_top_builddir_sub
10792    ac_abs_top_srcdir=$ac_pwd ;;
10793  [\\/]* | ?:[\\/]* )  # Absolute name.
10794    ac_srcdir=$srcdir$ac_dir_suffix;
10795    ac_top_srcdir=$srcdir
10796    ac_abs_top_srcdir=$srcdir ;;
10797  *) # Relative name.
10798    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
10799    ac_top_srcdir=$ac_top_build_prefix$srcdir
10800    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
10801esac
10802ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
10803
10804
10805  case $ac_mode in
10806  :F)
10807  #
10808  # CONFIG_FILE
10809  #
10810
10811_ACEOF
10812
10813cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10814# If the template does not know about datarootdir, expand it.
10815# FIXME: This hack should be removed a few years after 2.60.
10816ac_datarootdir_hack=; ac_datarootdir_seen=
10817ac_sed_dataroot='
10818/datarootdir/ {
10819  p
10820  q
10821}
10822/@datadir@/p
10823/@docdir@/p
10824/@infodir@/p
10825/@localedir@/p
10826/@mandir@/p'
10827case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
10828*datarootdir*) ac_datarootdir_seen=yes;;
10829*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
10830  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
10831printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
10832_ACEOF
10833cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10834  ac_datarootdir_hack='
10835  s&@datadir@&$datadir&g
10836  s&@docdir@&$docdir&g
10837  s&@infodir@&$infodir&g
10838  s&@localedir@&$localedir&g
10839  s&@mandir@&$mandir&g
10840  s&\\\${datarootdir}&$datarootdir&g' ;;
10841esac
10842_ACEOF
10843
10844# Neutralize VPATH when `$srcdir' = `.'.
10845# Shell code in configure.ac might set extrasub.
10846# FIXME: do we really want to maintain this feature?
10847cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10848ac_sed_extra="$ac_vpsub
10849$extrasub
10850_ACEOF
10851cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10852:t
10853/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
10854s|@configure_input@|$ac_sed_conf_input|;t t
10855s&@top_builddir@&$ac_top_builddir_sub&;t t
10856s&@top_build_prefix@&$ac_top_build_prefix&;t t
10857s&@srcdir@&$ac_srcdir&;t t
10858s&@abs_srcdir@&$ac_abs_srcdir&;t t
10859s&@top_srcdir@&$ac_top_srcdir&;t t
10860s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
10861s&@builddir@&$ac_builddir&;t t
10862s&@abs_builddir@&$ac_abs_builddir&;t t
10863s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
10864$ac_datarootdir_hack
10865"
10866eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
10867  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
10868
10869test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
10870  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
10871  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
10872      "$ac_tmp/out"`; test -z "$ac_out"; } &&
10873  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
10874which seems to be undefined.  Please make sure it is defined" >&5
10875printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
10876which seems to be undefined.  Please make sure it is defined" >&2;}
10877
10878  rm -f "$ac_tmp/stdin"
10879  case $ac_file in
10880  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
10881  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
10882  esac \
10883  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
10884 ;;
10885
10886
10887
10888  esac
10889
10890done # for ac_tag
10891
10892
10893as_fn_exit 0
10894_ACEOF
10895ac_clean_files=$ac_clean_files_save
10896
10897test $ac_write_fail = 0 ||
10898  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
10899
10900
10901# configure is writing to config.log, and then calls config.status.
10902# config.status does its own redirection, appending to config.log.
10903# Unfortunately, on DOS this fails, as config.log is still kept open
10904# by configure, so config.status won't be able to write to it; its
10905# output is simply discarded.  So we exec the FD to /dev/null,
10906# effectively closing config.log, so it can be properly (re)opened and
10907# appended to by config.status.  When coming back to configure, we
10908# need to make the FD available again.
10909if test "$no_create" != yes; then
10910  ac_cs_success=:
10911  ac_config_status_args=
10912  test "$silent" = yes &&
10913    ac_config_status_args="$ac_config_status_args --quiet"
10914  exec 5>/dev/null
10915  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
10916  exec 5>>config.log
10917  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
10918  # would make configure fail if this is the last instruction.
10919  $ac_cs_success || as_fn_exit 1
10920fi
10921if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
10922  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
10923printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
10924fi
10925
10926
10927