1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.70 for tk 8.7.
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='tk'
609PACKAGE_TARNAME='tk'
610PACKAGE_VERSION='8.7'
611PACKAGE_STRING='tk 8.7'
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
648REZ_FLAGS
649REZ
650APP_RSRC_FILE
651LIB_RSRC_FILE
652WISH_RSRC_FILE
653TK_RSRC_FILE
654CFBUNDLELOCALIZATIONS
655EXTRA_WISH_LIBS
656EXTRA_BUILD_HTML
657EXTRA_INSTALL_BINARIES
658EXTRA_INSTALL
659EXTRA_APP_CC_SWITCHES
660EXTRA_CC_SWITCHES
661HTML_DIR
662PRIVATE_INCLUDE_DIR
663LIB_RUNTIME_DIR
664TK_LIBRARY
665TK_PKG_DIR
666TK_WINDOWINGSYSTEM
667LOCALES
668XLIBSW
669XINCLUDES
670TCL_STUB_FLAGS
671TK_BUILD_LIB_SPEC
672LD_LIBRARY_PATH_VAR
673TK_SHARED_BUILD
674TK_SRC_DIR
675TK_BUILD_STUB_LIB_PATH
676TK_BUILD_STUB_LIB_SPEC
677TK_INCLUDE_SPEC
678TK_STUB_LIB_PATH
679TK_STUB_LIB_SPEC
680TK_STUB_LIB_FLAG
681TK_STUB_LIB_FILE
682TK_LIB_SPEC
683TK_LIB_FLAG
684TK_LIB_FILE_TCL9
685TK_LIB_FILE_TCL8
686TK_LIB_FILE
687TK_YEAR
688TK_PATCH_LEVEL
689TK_MINOR_VERSION
690TK_MAJOR_VERSION
691TK_VERSION
692TK_DEMO_DIR
693DEMO_DIR
694INSTALL_MSGS
695INSTALL_LIBRARIES
696TK_ZIP_FILE
697ZIPFS_BUILD
698ZIP_INSTALL_OBJS
699ZIP_PROG_VFSSEARCH
700ZIP_PROG_OPTIONS
701ZIP_PROG
702MACHER_PROG
703EXEEXT_FOR_BUILD
704CC_FOR_BUILD
705UNIX_FONT_OBJS
706XFT_LIBS
707XFT_CFLAGS
708XMKMF
709EGREP
710GREP
711CPP
712LDFLAGS_DEFAULT
713CFLAGS_DEFAULT
714INSTALL_STUB_LIB
715DLL_INSTALL_DIR
716INSTALL_LIB
717MAKE_STUB_LIB
718MAKE_LIB
719SHLIB_SUFFIX
720SHLIB_CFLAGS
721SHLIB_LD_LIBS
722TK_SHLIB_LD_EXTRAS
723TCL_SHLIB_LD_EXTRAS
724SHLIB_LD
725STLIB_LD
726LD_SEARCH_FLAGS
727CC_SEARCH_FLAGS
728LDFLAGS_OPTIMIZE
729LDFLAGS_DEBUG
730CFLAGS_NOLTO
731CFLAGS_WARNING
732CFLAGS_OPTIMIZE
733CFLAGS_DEBUG
734LDAIX_SRC
735PLAT_SRCS
736PLAT_OBJS
737DL_OBJS
738DL_LIBS
739TCL_LIBS
740LIBOBJS
741AR
742RANLIB
743SHARED_BUILD
744OBJEXT
745EXEEXT
746ac_ct_CC
747CPPFLAGS
748LDFLAGS
749CFLAGS
750CC
751MAN_FLAGS
752BUILD_TCLSH
753TCLSH_PROG
754TCL_STUB_LIB_SPEC
755TCL_STUB_LIB_FLAG
756TCL_STUB_LIB_FILE
757TCL_LIB_SPEC
758TCL_LIB_FLAG
759TCL_LIB_FILE
760TCL_SRC_DIR
761TCL_BIN_DIR
762TCL_PATCH_LEVEL
763TCL_VERSION
764target_alias
765host_alias
766build_alias
767LIBS
768ECHO_T
769ECHO_N
770ECHO_C
771DEFS
772mandir
773localedir
774libdir
775psdir
776pdfdir
777dvidir
778htmldir
779infodir
780docdir
781oldincludedir
782includedir
783runstatedir
784localstatedir
785sharedstatedir
786sysconfdir
787datadir
788datarootdir
789libexecdir
790sbindir
791bindir
792program_transform_name
793prefix
794exec_prefix
795PACKAGE_URL
796PACKAGE_BUGREPORT
797PACKAGE_STRING
798PACKAGE_VERSION
799PACKAGE_TARNAME
800PACKAGE_NAME
801PATH_SEPARATOR
802SHELL
803OBJEXT_FOR_BUILD'
804ac_subst_files=''
805ac_user_opts='
806enable_option_checking
807with_tcl
808enable_man_symlinks
809enable_man_compression
810enable_man_suffix
811with_encoding
812enable_shared
813enable_64bit
814enable_64bit_vis
815enable_rpath
816enable_corefoundation
817enable_load
818enable_symbols
819enable_aqua
820with_x
821enable_xft
822enable_xss
823enable_framework
824enable_zipfs
825'
826      ac_precious_vars='build_alias
827host_alias
828target_alias
829CC
830CFLAGS
831LDFLAGS
832LIBS
833CPPFLAGS
834CPP
835XMKMF'
836
837
838# Initialize some variables set by options.
839ac_init_help=
840ac_init_version=false
841ac_unrecognized_opts=
842ac_unrecognized_sep=
843# The variables have the same names as the options, with
844# dashes changed to underlines.
845cache_file=/dev/null
846exec_prefix=NONE
847no_create=
848no_recursion=
849prefix=NONE
850program_prefix=NONE
851program_suffix=NONE
852program_transform_name=s,x,x,
853silent=
854site=
855srcdir=
856verbose=
857x_includes=NONE
858x_libraries=NONE
859
860# Installation directory options.
861# These are left unexpanded so users can "make install exec_prefix=/foo"
862# and all the variables that are supposed to be based on exec_prefix
863# by default will actually change.
864# Use braces instead of parens because sh, perl, etc. also accept them.
865# (The list follows the same order as the GNU Coding Standards.)
866bindir='${exec_prefix}/bin'
867sbindir='${exec_prefix}/sbin'
868libexecdir='${exec_prefix}/libexec'
869datarootdir='${prefix}/share'
870datadir='${datarootdir}'
871sysconfdir='${prefix}/etc'
872sharedstatedir='${prefix}/com'
873localstatedir='${prefix}/var'
874runstatedir='${localstatedir}/run'
875includedir='${prefix}/include'
876oldincludedir='/usr/include'
877docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
878infodir='${datarootdir}/info'
879htmldir='${docdir}'
880dvidir='${docdir}'
881pdfdir='${docdir}'
882psdir='${docdir}'
883libdir='${exec_prefix}/lib'
884localedir='${datarootdir}/locale'
885mandir='${datarootdir}/man'
886
887ac_prev=
888ac_dashdash=
889for ac_option
890do
891  # If the previous option needs an argument, assign it.
892  if test -n "$ac_prev"; then
893    eval $ac_prev=\$ac_option
894    ac_prev=
895    continue
896  fi
897
898  case $ac_option in
899  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
900  *=)   ac_optarg= ;;
901  *)    ac_optarg=yes ;;
902  esac
903
904  case $ac_dashdash$ac_option in
905  --)
906    ac_dashdash=yes ;;
907
908  -bindir | --bindir | --bindi | --bind | --bin | --bi)
909    ac_prev=bindir ;;
910  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
911    bindir=$ac_optarg ;;
912
913  -build | --build | --buil | --bui | --bu)
914    ac_prev=build_alias ;;
915  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
916    build_alias=$ac_optarg ;;
917
918  -cache-file | --cache-file | --cache-fil | --cache-fi \
919  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
920    ac_prev=cache_file ;;
921  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
922  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
923    cache_file=$ac_optarg ;;
924
925  --config-cache | -C)
926    cache_file=config.cache ;;
927
928  -datadir | --datadir | --datadi | --datad)
929    ac_prev=datadir ;;
930  -datadir=* | --datadir=* | --datadi=* | --datad=*)
931    datadir=$ac_optarg ;;
932
933  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
934  | --dataroo | --dataro | --datar)
935    ac_prev=datarootdir ;;
936  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
937  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
938    datarootdir=$ac_optarg ;;
939
940  -disable-* | --disable-*)
941    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
942    # Reject names that are not valid shell variable names.
943    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
944      as_fn_error $? "invalid feature name: \`$ac_useropt'"
945    ac_useropt_orig=$ac_useropt
946    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
947    case $ac_user_opts in
948      *"
949"enable_$ac_useropt"
950"*) ;;
951      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
952	 ac_unrecognized_sep=', ';;
953    esac
954    eval enable_$ac_useropt=no ;;
955
956  -docdir | --docdir | --docdi | --doc | --do)
957    ac_prev=docdir ;;
958  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
959    docdir=$ac_optarg ;;
960
961  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
962    ac_prev=dvidir ;;
963  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
964    dvidir=$ac_optarg ;;
965
966  -enable-* | --enable-*)
967    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
968    # Reject names that are not valid shell variable names.
969    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
970      as_fn_error $? "invalid feature name: \`$ac_useropt'"
971    ac_useropt_orig=$ac_useropt
972    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
973    case $ac_user_opts in
974      *"
975"enable_$ac_useropt"
976"*) ;;
977      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
978	 ac_unrecognized_sep=', ';;
979    esac
980    eval enable_$ac_useropt=\$ac_optarg ;;
981
982  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
983  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
984  | --exec | --exe | --ex)
985    ac_prev=exec_prefix ;;
986  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
987  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
988  | --exec=* | --exe=* | --ex=*)
989    exec_prefix=$ac_optarg ;;
990
991  -gas | --gas | --ga | --g)
992    # Obsolete; use --with-gas.
993    with_gas=yes ;;
994
995  -help | --help | --hel | --he | -h)
996    ac_init_help=long ;;
997  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
998    ac_init_help=recursive ;;
999  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1000    ac_init_help=short ;;
1001
1002  -host | --host | --hos | --ho)
1003    ac_prev=host_alias ;;
1004  -host=* | --host=* | --hos=* | --ho=*)
1005    host_alias=$ac_optarg ;;
1006
1007  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1008    ac_prev=htmldir ;;
1009  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1010  | --ht=*)
1011    htmldir=$ac_optarg ;;
1012
1013  -includedir | --includedir | --includedi | --included | --include \
1014  | --includ | --inclu | --incl | --inc)
1015    ac_prev=includedir ;;
1016  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1017  | --includ=* | --inclu=* | --incl=* | --inc=*)
1018    includedir=$ac_optarg ;;
1019
1020  -infodir | --infodir | --infodi | --infod | --info | --inf)
1021    ac_prev=infodir ;;
1022  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1023    infodir=$ac_optarg ;;
1024
1025  -libdir | --libdir | --libdi | --libd)
1026    ac_prev=libdir ;;
1027  -libdir=* | --libdir=* | --libdi=* | --libd=*)
1028    libdir=$ac_optarg ;;
1029
1030  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1031  | --libexe | --libex | --libe)
1032    ac_prev=libexecdir ;;
1033  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1034  | --libexe=* | --libex=* | --libe=*)
1035    libexecdir=$ac_optarg ;;
1036
1037  -localedir | --localedir | --localedi | --localed | --locale)
1038    ac_prev=localedir ;;
1039  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1040    localedir=$ac_optarg ;;
1041
1042  -localstatedir | --localstatedir | --localstatedi | --localstated \
1043  | --localstate | --localstat | --localsta | --localst | --locals)
1044    ac_prev=localstatedir ;;
1045  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1046  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1047    localstatedir=$ac_optarg ;;
1048
1049  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1050    ac_prev=mandir ;;
1051  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1052    mandir=$ac_optarg ;;
1053
1054  -nfp | --nfp | --nf)
1055    # Obsolete; use --without-fp.
1056    with_fp=no ;;
1057
1058  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1059  | --no-cr | --no-c | -n)
1060    no_create=yes ;;
1061
1062  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1063  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1064    no_recursion=yes ;;
1065
1066  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1067  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1068  | --oldin | --oldi | --old | --ol | --o)
1069    ac_prev=oldincludedir ;;
1070  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1071  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1072  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1073    oldincludedir=$ac_optarg ;;
1074
1075  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1076    ac_prev=prefix ;;
1077  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1078    prefix=$ac_optarg ;;
1079
1080  -program-prefix | --program-prefix | --program-prefi | --program-pref \
1081  | --program-pre | --program-pr | --program-p)
1082    ac_prev=program_prefix ;;
1083  -program-prefix=* | --program-prefix=* | --program-prefi=* \
1084  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1085    program_prefix=$ac_optarg ;;
1086
1087  -program-suffix | --program-suffix | --program-suffi | --program-suff \
1088  | --program-suf | --program-su | --program-s)
1089    ac_prev=program_suffix ;;
1090  -program-suffix=* | --program-suffix=* | --program-suffi=* \
1091  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1092    program_suffix=$ac_optarg ;;
1093
1094  -program-transform-name | --program-transform-name \
1095  | --program-transform-nam | --program-transform-na \
1096  | --program-transform-n | --program-transform- \
1097  | --program-transform | --program-transfor \
1098  | --program-transfo | --program-transf \
1099  | --program-trans | --program-tran \
1100  | --progr-tra | --program-tr | --program-t)
1101    ac_prev=program_transform_name ;;
1102  -program-transform-name=* | --program-transform-name=* \
1103  | --program-transform-nam=* | --program-transform-na=* \
1104  | --program-transform-n=* | --program-transform-=* \
1105  | --program-transform=* | --program-transfor=* \
1106  | --program-transfo=* | --program-transf=* \
1107  | --program-trans=* | --program-tran=* \
1108  | --progr-tra=* | --program-tr=* | --program-t=*)
1109    program_transform_name=$ac_optarg ;;
1110
1111  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1112    ac_prev=pdfdir ;;
1113  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1114    pdfdir=$ac_optarg ;;
1115
1116  -psdir | --psdir | --psdi | --psd | --ps)
1117    ac_prev=psdir ;;
1118  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1119    psdir=$ac_optarg ;;
1120
1121  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1122  | -silent | --silent | --silen | --sile | --sil)
1123    silent=yes ;;
1124
1125  -runstatedir | --runstatedir | --runstatedi | --runstated \
1126  | --runstate | --runstat | --runsta | --runst | --runs \
1127  | --run | --ru | --r)
1128    ac_prev=runstatedir ;;
1129  -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1130  | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1131  | --run=* | --ru=* | --r=*)
1132    runstatedir=$ac_optarg ;;
1133
1134  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1135    ac_prev=sbindir ;;
1136  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1137  | --sbi=* | --sb=*)
1138    sbindir=$ac_optarg ;;
1139
1140  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1141  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1142  | --sharedst | --shareds | --shared | --share | --shar \
1143  | --sha | --sh)
1144    ac_prev=sharedstatedir ;;
1145  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1146  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1147  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1148  | --sha=* | --sh=*)
1149    sharedstatedir=$ac_optarg ;;
1150
1151  -site | --site | --sit)
1152    ac_prev=site ;;
1153  -site=* | --site=* | --sit=*)
1154    site=$ac_optarg ;;
1155
1156  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1157    ac_prev=srcdir ;;
1158  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1159    srcdir=$ac_optarg ;;
1160
1161  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1162  | --syscon | --sysco | --sysc | --sys | --sy)
1163    ac_prev=sysconfdir ;;
1164  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1165  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1166    sysconfdir=$ac_optarg ;;
1167
1168  -target | --target | --targe | --targ | --tar | --ta | --t)
1169    ac_prev=target_alias ;;
1170  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1171    target_alias=$ac_optarg ;;
1172
1173  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1174    verbose=yes ;;
1175
1176  -version | --version | --versio | --versi | --vers | -V)
1177    ac_init_version=: ;;
1178
1179  -with-* | --with-*)
1180    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1181    # Reject names that are not valid shell variable names.
1182    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1183      as_fn_error $? "invalid package name: \`$ac_useropt'"
1184    ac_useropt_orig=$ac_useropt
1185    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1186    case $ac_user_opts in
1187      *"
1188"with_$ac_useropt"
1189"*) ;;
1190      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1191	 ac_unrecognized_sep=', ';;
1192    esac
1193    eval with_$ac_useropt=\$ac_optarg ;;
1194
1195  -without-* | --without-*)
1196    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1197    # Reject names that are not valid shell variable names.
1198    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1199      as_fn_error $? "invalid package name: \`$ac_useropt'"
1200    ac_useropt_orig=$ac_useropt
1201    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1202    case $ac_user_opts in
1203      *"
1204"with_$ac_useropt"
1205"*) ;;
1206      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1207	 ac_unrecognized_sep=', ';;
1208    esac
1209    eval with_$ac_useropt=no ;;
1210
1211  --x)
1212    # Obsolete; use --with-x.
1213    with_x=yes ;;
1214
1215  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1216  | --x-incl | --x-inc | --x-in | --x-i)
1217    ac_prev=x_includes ;;
1218  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1219  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1220    x_includes=$ac_optarg ;;
1221
1222  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1223  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1224    ac_prev=x_libraries ;;
1225  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1226  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1227    x_libraries=$ac_optarg ;;
1228
1229  -*) as_fn_error $? "unrecognized option: \`$ac_option'
1230Try \`$0 --help' for more information"
1231    ;;
1232
1233  *=*)
1234    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1235    # Reject names that are not valid shell variable names.
1236    case $ac_envvar in #(
1237      '' | [0-9]* | *[!_$as_cr_alnum]* )
1238      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1239    esac
1240    eval $ac_envvar=\$ac_optarg
1241    export $ac_envvar ;;
1242
1243  *)
1244    # FIXME: should be removed in autoconf 3.0.
1245    printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2
1246    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1247      printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2
1248    : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1249    ;;
1250
1251  esac
1252done
1253
1254if test -n "$ac_prev"; then
1255  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1256  as_fn_error $? "missing argument to $ac_option"
1257fi
1258
1259if test -n "$ac_unrecognized_opts"; then
1260  case $enable_option_checking in
1261    no) ;;
1262    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1263    *)     printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1264  esac
1265fi
1266
1267# Check all directory arguments for consistency.
1268for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1269		datadir sysconfdir sharedstatedir localstatedir includedir \
1270		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1271		libdir localedir mandir runstatedir
1272do
1273  eval ac_val=\$$ac_var
1274  # Remove trailing slashes.
1275  case $ac_val in
1276    */ )
1277      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1278      eval $ac_var=\$ac_val;;
1279  esac
1280  # Be sure to have absolute directory names.
1281  case $ac_val in
1282    [\\/$]* | ?:[\\/]* )  continue;;
1283    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1284  esac
1285  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1286done
1287
1288# There might be people who depend on the old broken behavior: `$host'
1289# used to hold the argument of --host etc.
1290# FIXME: To remove some day.
1291build=$build_alias
1292host=$host_alias
1293target=$target_alias
1294
1295# FIXME: To remove some day.
1296if test "x$host_alias" != x; then
1297  if test "x$build_alias" = x; then
1298    cross_compiling=maybe
1299  elif test "x$build_alias" != "x$host_alias"; then
1300    cross_compiling=yes
1301  fi
1302fi
1303
1304ac_tool_prefix=
1305test -n "$host_alias" && ac_tool_prefix=$host_alias-
1306
1307test "$silent" = yes && exec 6>/dev/null
1308
1309
1310ac_pwd=`pwd` && test -n "$ac_pwd" &&
1311ac_ls_di=`ls -di .` &&
1312ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1313  as_fn_error $? "working directory cannot be determined"
1314test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1315  as_fn_error $? "pwd does not report name of working directory"
1316
1317
1318# Find the source files, if location was not specified.
1319if test -z "$srcdir"; then
1320  ac_srcdir_defaulted=yes
1321  # Try the directory containing this script, then the parent directory.
1322  ac_confdir=`$as_dirname -- "$as_myself" ||
1323$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1324	 X"$as_myself" : 'X\(//\)[^/]' \| \
1325	 X"$as_myself" : 'X\(//\)$' \| \
1326	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1327printf "%s\n" X"$as_myself" |
1328    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1329	    s//\1/
1330	    q
1331	  }
1332	  /^X\(\/\/\)[^/].*/{
1333	    s//\1/
1334	    q
1335	  }
1336	  /^X\(\/\/\)$/{
1337	    s//\1/
1338	    q
1339	  }
1340	  /^X\(\/\).*/{
1341	    s//\1/
1342	    q
1343	  }
1344	  s/.*/./; q'`
1345  srcdir=$ac_confdir
1346  if test ! -r "$srcdir/$ac_unique_file"; then
1347    srcdir=..
1348  fi
1349else
1350  ac_srcdir_defaulted=no
1351fi
1352if test ! -r "$srcdir/$ac_unique_file"; then
1353  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1354  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1355fi
1356ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1357ac_abs_confdir=`(
1358	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1359	pwd)`
1360# When building in place, set srcdir=.
1361if test "$ac_abs_confdir" = "$ac_pwd"; then
1362  srcdir=.
1363fi
1364# Remove unnecessary trailing slashes from srcdir.
1365# Double slashes in file names in object file debugging info
1366# mess up M-x gdb in Emacs.
1367case $srcdir in
1368*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1369esac
1370for ac_var in $ac_precious_vars; do
1371  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1372  eval ac_env_${ac_var}_value=\$${ac_var}
1373  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1374  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1375done
1376
1377#
1378# Report the --help message.
1379#
1380if test "$ac_init_help" = "long"; then
1381  # Omit some internal or obsolete options to make the list less imposing.
1382  # This message is too long to be a string in the A/UX 3.1 sh.
1383  cat <<_ACEOF
1384\`configure' configures tk 8.7 to adapt to many kinds of systems.
1385
1386Usage: $0 [OPTION]... [VAR=VALUE]...
1387
1388To assign environment variables (e.g., CC, CFLAGS...), specify them as
1389VAR=VALUE.  See below for descriptions of some of the useful variables.
1390
1391Defaults for the options are specified in brackets.
1392
1393Configuration:
1394  -h, --help              display this help and exit
1395      --help=short        display options specific to this package
1396      --help=recursive    display the short help of all the included packages
1397  -V, --version           display version information and exit
1398  -q, --quiet, --silent   do not print \`checking ...' messages
1399      --cache-file=FILE   cache test results in FILE [disabled]
1400  -C, --config-cache      alias for \`--cache-file=config.cache'
1401  -n, --no-create         do not create output files
1402      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1403
1404Installation directories:
1405  --prefix=PREFIX         install architecture-independent files in PREFIX
1406                          [$ac_default_prefix]
1407  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1408                          [PREFIX]
1409
1410By default, \`make install' will install all the files in
1411\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1412an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1413for instance \`--prefix=\$HOME'.
1414
1415For better control, use the options below.
1416
1417Fine tuning of the installation directories:
1418  --bindir=DIR            user executables [EPREFIX/bin]
1419  --sbindir=DIR           system admin executables [EPREFIX/sbin]
1420  --libexecdir=DIR        program executables [EPREFIX/libexec]
1421  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1422  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1423  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1424  --runstatedir=DIR       modifiable per-process data [LOCALSTATEDIR/run]
1425  --libdir=DIR            object code libraries [EPREFIX/lib]
1426  --includedir=DIR        C header files [PREFIX/include]
1427  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1428  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1429  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1430  --infodir=DIR           info documentation [DATAROOTDIR/info]
1431  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1432  --mandir=DIR            man documentation [DATAROOTDIR/man]
1433  --docdir=DIR            documentation root [DATAROOTDIR/doc/tk]
1434  --htmldir=DIR           html documentation [DOCDIR]
1435  --dvidir=DIR            dvi documentation [DOCDIR]
1436  --pdfdir=DIR            pdf documentation [DOCDIR]
1437  --psdir=DIR             ps documentation [DOCDIR]
1438_ACEOF
1439
1440  cat <<\_ACEOF
1441
1442X features:
1443  --x-includes=DIR    X include files are in DIR
1444  --x-libraries=DIR   X library files are in DIR
1445_ACEOF
1446fi
1447
1448if test -n "$ac_init_help"; then
1449  case $ac_init_help in
1450     short | recursive ) echo "Configuration of tk 8.7:";;
1451   esac
1452  cat <<\_ACEOF
1453
1454Optional Features:
1455  --disable-option-checking  ignore unrecognized --enable/--with options
1456  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1457  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1458  --enable-man-symlinks   use symlinks for the manpages (default: off)
1459  --enable-man-compression=PROG
1460                          compress the manpages with PROG (default: off)
1461  --enable-man-suffix=STRING
1462                          use STRING as a suffix to manpage file names
1463                          (default: no, tk if enabled without
1464                          specifying STRING)
1465  --enable-shared         build and link with shared libraries (default: on)
1466  --enable-64bit          enable 64bit support (default: off)
1467  --enable-64bit-vis      enable 64bit Sparc VIS support (default: off)
1468  --disable-rpath         disable rpath support (default: on)
1469  --enable-corefoundation use CoreFoundation API on MacOSX (default: on)
1470  --enable-load           allow dynamic loading and "load" command (default:
1471                          on)
1472  --enable-symbols        build with debugging symbols (default: off)
1473  --enable-aqua=yes|no    use Aqua windowingsystem on Mac OS X (default: no)
1474  --enable-xft            use freetype/fontconfig/xft (default: on)
1475  --enable-xss            use XScreenSaver for activity timer (default: on)
1476  --enable-framework      package shared libraries in MacOSX frameworks
1477                          (default: off)
1478  --enable-zipfs          build with Zipfs support (default: on)
1479
1480Optional Packages:
1481  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1482  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1483  --with-tcl              directory containing tcl configuration
1484                          (tclConfig.sh)
1485  --with-encoding         encoding for configuration values (default: utf-8)
1486  --with-x                use the X Window System
1487
1488Some influential environment variables:
1489  CC          C compiler command
1490  CFLAGS      C compiler flags
1491  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1492              nonstandard directory <lib dir>
1493  LIBS        libraries to pass to the linker, e.g. -l<library>
1494  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1495              you have headers in a nonstandard directory <include dir>
1496  CPP         C preprocessor
1497  XMKMF       Path to xmkmf, Makefile generator for X Window System
1498
1499Use these variables to override the choices made by `configure' or to help
1500it to find libraries and programs with nonstandard names/locations.
1501
1502Report bugs to the package provider.
1503_ACEOF
1504ac_status=$?
1505fi
1506
1507if test "$ac_init_help" = "recursive"; then
1508  # If there are subdirs, report their specific --help.
1509  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1510    test -d "$ac_dir" ||
1511      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1512      continue
1513    ac_builddir=.
1514
1515case "$ac_dir" in
1516.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1517*)
1518  ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
1519  # A ".." for each directory in $ac_dir_suffix.
1520  ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1521  case $ac_top_builddir_sub in
1522  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1523  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1524  esac ;;
1525esac
1526ac_abs_top_builddir=$ac_pwd
1527ac_abs_builddir=$ac_pwd$ac_dir_suffix
1528# for backward compatibility:
1529ac_top_builddir=$ac_top_build_prefix
1530
1531case $srcdir in
1532  .)  # We are building in place.
1533    ac_srcdir=.
1534    ac_top_srcdir=$ac_top_builddir_sub
1535    ac_abs_top_srcdir=$ac_pwd ;;
1536  [\\/]* | ?:[\\/]* )  # Absolute name.
1537    ac_srcdir=$srcdir$ac_dir_suffix;
1538    ac_top_srcdir=$srcdir
1539    ac_abs_top_srcdir=$srcdir ;;
1540  *) # Relative name.
1541    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1542    ac_top_srcdir=$ac_top_build_prefix$srcdir
1543    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1544esac
1545ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1546
1547    cd "$ac_dir" || { ac_status=$?; continue; }
1548    # Check for configure.gnu first; this name is used for a wrapper for
1549    # Metaconfig's "Configure" on case-insensitive file systems.
1550    if test -f "$ac_srcdir/configure.gnu"; then
1551      echo &&
1552      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1553    elif test -f "$ac_srcdir/configure"; then
1554      echo &&
1555      $SHELL "$ac_srcdir/configure" --help=recursive
1556    else
1557      printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1558    fi || ac_status=$?
1559    cd "$ac_pwd" || { ac_status=$?; break; }
1560  done
1561fi
1562
1563test -n "$ac_init_help" && exit $ac_status
1564if $ac_init_version; then
1565  cat <<\_ACEOF
1566tk configure 8.7
1567generated by GNU Autoconf 2.70
1568
1569Copyright (C) 2020 Free Software Foundation, Inc.
1570This configure script is free software; the Free Software Foundation
1571gives unlimited permission to copy, distribute and modify it.
1572_ACEOF
1573  exit
1574fi
1575
1576## ------------------------ ##
1577## Autoconf initialization. ##
1578## ------------------------ ##
1579
1580# ac_fn_c_try_compile LINENO
1581# --------------------------
1582# Try to compile conftest.$ac_ext, and return whether this succeeded.
1583ac_fn_c_try_compile ()
1584{
1585  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1586  rm -f conftest.$ac_objext conftest.beam
1587  if { { ac_try="$ac_compile"
1588case "(($ac_try" in
1589  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1590  *) ac_try_echo=$ac_try;;
1591esac
1592eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1593printf "%s\n" "$ac_try_echo"; } >&5
1594  (eval "$ac_compile") 2>conftest.err
1595  ac_status=$?
1596  if test -s conftest.err; then
1597    grep -v '^ *+' conftest.err >conftest.er1
1598    cat conftest.er1 >&5
1599    mv -f conftest.er1 conftest.err
1600  fi
1601  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1602  test $ac_status = 0; } && {
1603	 test -z "$ac_c_werror_flag" ||
1604	 test ! -s conftest.err
1605       } && test -s conftest.$ac_objext
1606then :
1607  ac_retval=0
1608else $as_nop
1609  printf "%s\n" "$as_me: failed program was:" >&5
1610sed 's/^/| /' conftest.$ac_ext >&5
1611
1612	ac_retval=1
1613fi
1614  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1615  as_fn_set_status $ac_retval
1616
1617} # ac_fn_c_try_compile
1618
1619# ac_fn_c_try_link LINENO
1620# -----------------------
1621# Try to link conftest.$ac_ext, and return whether this succeeded.
1622ac_fn_c_try_link ()
1623{
1624  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1625  rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext
1626  if { { ac_try="$ac_link"
1627case "(($ac_try" in
1628  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1629  *) ac_try_echo=$ac_try;;
1630esac
1631eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1632printf "%s\n" "$ac_try_echo"; } >&5
1633  (eval "$ac_link") 2>conftest.err
1634  ac_status=$?
1635  if test -s conftest.err; then
1636    grep -v '^ *+' conftest.err >conftest.er1
1637    cat conftest.er1 >&5
1638    mv -f conftest.er1 conftest.err
1639  fi
1640  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1641  test $ac_status = 0; } && {
1642	 test -z "$ac_c_werror_flag" ||
1643	 test ! -s conftest.err
1644       } && test -s conftest$ac_exeext && {
1645	 test "$cross_compiling" = yes ||
1646	 test -x conftest$ac_exeext
1647       }
1648then :
1649  ac_retval=0
1650else $as_nop
1651  printf "%s\n" "$as_me: failed program was:" >&5
1652sed 's/^/| /' conftest.$ac_ext >&5
1653
1654	ac_retval=1
1655fi
1656  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1657  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1658  # interfere with the next link command; also delete a directory that is
1659  # left behind by Apple's compiler.  We do this before executing the actions.
1660  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1661  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1662  as_fn_set_status $ac_retval
1663
1664} # ac_fn_c_try_link
1665
1666# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1667# -------------------------------------------------------
1668# Tests whether HEADER exists and can be compiled using the include files in
1669# INCLUDES, setting the cache variable VAR accordingly.
1670ac_fn_c_check_header_compile ()
1671{
1672  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1673  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1674printf %s "checking for $2... " >&6; }
1675if eval test \${$3+y}
1676then :
1677  printf %s "(cached) " >&6
1678else $as_nop
1679  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1680/* end confdefs.h.  */
1681$4
1682#include <$2>
1683_ACEOF
1684if ac_fn_c_try_compile "$LINENO"
1685then :
1686  eval "$3=yes"
1687else $as_nop
1688  eval "$3=no"
1689fi
1690rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1691fi
1692eval ac_res=\$$3
1693	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1694printf "%s\n" "$ac_res" >&6; }
1695  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1696
1697} # ac_fn_c_check_header_compile
1698
1699# ac_fn_c_check_func LINENO FUNC VAR
1700# ----------------------------------
1701# Tests whether FUNC exists, setting the cache variable VAR accordingly
1702ac_fn_c_check_func ()
1703{
1704  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1705  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1706printf %s "checking for $2... " >&6; }
1707if eval test \${$3+y}
1708then :
1709  printf %s "(cached) " >&6
1710else $as_nop
1711  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1712/* end confdefs.h.  */
1713/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1714   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
1715#define $2 innocuous_$2
1716
1717/* System header to define __stub macros and hopefully few prototypes,
1718   which can conflict with char $2 (); below.  */
1719
1720#include <limits.h>
1721#undef $2
1722
1723/* Override any GCC internal prototype to avoid an error.
1724   Use char because int might match the return type of a GCC
1725   builtin and then its argument prototype would still apply.  */
1726#ifdef __cplusplus
1727extern "C"
1728#endif
1729char $2 ();
1730/* The GNU C library defines this for functions which it implements
1731    to always fail with ENOSYS.  Some functions are actually named
1732    something starting with __ and the normal name is an alias.  */
1733#if defined __stub_$2 || defined __stub___$2
1734choke me
1735#endif
1736
1737int
1738main (void)
1739{
1740return $2 ();
1741  ;
1742  return 0;
1743}
1744_ACEOF
1745if ac_fn_c_try_link "$LINENO"
1746then :
1747  eval "$3=yes"
1748else $as_nop
1749  eval "$3=no"
1750fi
1751rm -f core conftest.err conftest.$ac_objext conftest.beam \
1752    conftest$ac_exeext conftest.$ac_ext
1753fi
1754eval ac_res=\$$3
1755	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1756printf "%s\n" "$ac_res" >&6; }
1757  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1758
1759} # ac_fn_c_check_func
1760
1761# ac_fn_c_try_run LINENO
1762# ----------------------
1763# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that
1764# executables *can* be run.
1765ac_fn_c_try_run ()
1766{
1767  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1768  if { { ac_try="$ac_link"
1769case "(($ac_try" in
1770  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1771  *) ac_try_echo=$ac_try;;
1772esac
1773eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1774printf "%s\n" "$ac_try_echo"; } >&5
1775  (eval "$ac_link") 2>&5
1776  ac_status=$?
1777  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1778  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1779  { { case "(($ac_try" in
1780  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1781  *) ac_try_echo=$ac_try;;
1782esac
1783eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1784printf "%s\n" "$ac_try_echo"; } >&5
1785  (eval "$ac_try") 2>&5
1786  ac_status=$?
1787  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1788  test $ac_status = 0; }; }
1789then :
1790  ac_retval=0
1791else $as_nop
1792  printf "%s\n" "$as_me: program exited with status $ac_status" >&5
1793       printf "%s\n" "$as_me: failed program was:" >&5
1794sed 's/^/| /' conftest.$ac_ext >&5
1795
1796       ac_retval=$ac_status
1797fi
1798  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1799  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1800  as_fn_set_status $ac_retval
1801
1802} # ac_fn_c_try_run
1803
1804# ac_fn_c_try_cpp LINENO
1805# ----------------------
1806# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1807ac_fn_c_try_cpp ()
1808{
1809  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1810  if { { ac_try="$ac_cpp conftest.$ac_ext"
1811case "(($ac_try" in
1812  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1813  *) ac_try_echo=$ac_try;;
1814esac
1815eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1816printf "%s\n" "$ac_try_echo"; } >&5
1817  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1818  ac_status=$?
1819  if test -s conftest.err; then
1820    grep -v '^ *+' conftest.err >conftest.er1
1821    cat conftest.er1 >&5
1822    mv -f conftest.er1 conftest.err
1823  fi
1824  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1825  test $ac_status = 0; } > conftest.i && {
1826	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1827	 test ! -s conftest.err
1828       }
1829then :
1830  ac_retval=0
1831else $as_nop
1832  printf "%s\n" "$as_me: failed program was:" >&5
1833sed 's/^/| /' conftest.$ac_ext >&5
1834
1835    ac_retval=1
1836fi
1837  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1838  as_fn_set_status $ac_retval
1839
1840} # ac_fn_c_try_cpp
1841
1842# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1843# -------------------------------------------
1844# Tests whether TYPE exists after having included INCLUDES, setting cache
1845# variable VAR accordingly.
1846ac_fn_c_check_type ()
1847{
1848  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1849  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1850printf %s "checking for $2... " >&6; }
1851if eval test \${$3+y}
1852then :
1853  printf %s "(cached) " >&6
1854else $as_nop
1855  eval "$3=no"
1856  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1857/* end confdefs.h.  */
1858$4
1859int
1860main (void)
1861{
1862if (sizeof ($2))
1863	 return 0;
1864  ;
1865  return 0;
1866}
1867_ACEOF
1868if ac_fn_c_try_compile "$LINENO"
1869then :
1870  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1871/* end confdefs.h.  */
1872$4
1873int
1874main (void)
1875{
1876if (sizeof (($2)))
1877	    return 0;
1878  ;
1879  return 0;
1880}
1881_ACEOF
1882if ac_fn_c_try_compile "$LINENO"
1883then :
1884
1885else $as_nop
1886  eval "$3=yes"
1887fi
1888rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1889fi
1890rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1891fi
1892eval ac_res=\$$3
1893	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1894printf "%s\n" "$ac_res" >&6; }
1895  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1896
1897} # ac_fn_c_check_type
1898ac_configure_args_raw=
1899for ac_arg
1900do
1901  case $ac_arg in
1902  *\'*)
1903    ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1904  esac
1905  as_fn_append ac_configure_args_raw " '$ac_arg'"
1906done
1907
1908case $ac_configure_args_raw in
1909  *$as_nl*)
1910    ac_safe_unquote= ;;
1911  *)
1912    ac_unsafe_z='|&;<>()$`\\"*?[ ''	' # This string ends in space, tab.
1913    ac_unsafe_a="$ac_unsafe_z#~"
1914    ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g"
1915    ac_configure_args_raw=`      printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;;
1916esac
1917
1918cat >config.log <<_ACEOF
1919This file contains any messages produced by compilers while
1920running configure, to aid debugging if configure makes a mistake.
1921
1922It was created by tk $as_me 8.7, which was
1923generated by GNU Autoconf 2.70.  Invocation command line was
1924
1925  $ $0$ac_configure_args_raw
1926
1927_ACEOF
1928exec 5>>config.log
1929{
1930cat <<_ASUNAME
1931## --------- ##
1932## Platform. ##
1933## --------- ##
1934
1935hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1936uname -m = `(uname -m) 2>/dev/null || echo unknown`
1937uname -r = `(uname -r) 2>/dev/null || echo unknown`
1938uname -s = `(uname -s) 2>/dev/null || echo unknown`
1939uname -v = `(uname -v) 2>/dev/null || echo unknown`
1940
1941/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1942/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1943
1944/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1945/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1946/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1947/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1948/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1949/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1950/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1951
1952_ASUNAME
1953
1954as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1955for as_dir in $PATH
1956do
1957  IFS=$as_save_IFS
1958  case $as_dir in #(((
1959    '') as_dir=./ ;;
1960    */) ;;
1961    *) as_dir=$as_dir/ ;;
1962  esac
1963    printf "%s\n" "PATH: $as_dir"
1964  done
1965IFS=$as_save_IFS
1966
1967} >&5
1968
1969cat >&5 <<_ACEOF
1970
1971
1972## ----------- ##
1973## Core tests. ##
1974## ----------- ##
1975
1976_ACEOF
1977
1978
1979# Keep a trace of the command line.
1980# Strip out --no-create and --no-recursion so they do not pile up.
1981# Strip out --silent because we don't want to record it for future runs.
1982# Also quote any args containing shell meta-characters.
1983# Make two passes to allow for proper duplicate-argument suppression.
1984ac_configure_args=
1985ac_configure_args0=
1986ac_configure_args1=
1987ac_must_keep_next=false
1988for ac_pass in 1 2
1989do
1990  for ac_arg
1991  do
1992    case $ac_arg in
1993    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1994    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1995    | -silent | --silent | --silen | --sile | --sil)
1996      continue ;;
1997    *\'*)
1998      ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1999    esac
2000    case $ac_pass in
2001    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2002    2)
2003      as_fn_append ac_configure_args1 " '$ac_arg'"
2004      if test $ac_must_keep_next = true; then
2005	ac_must_keep_next=false # Got value, back to normal.
2006      else
2007	case $ac_arg in
2008	  *=* | --config-cache | -C | -disable-* | --disable-* \
2009	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2010	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2011	  | -with-* | --with-* | -without-* | --without-* | --x)
2012	    case "$ac_configure_args0 " in
2013	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2014	    esac
2015	    ;;
2016	  -* ) ac_must_keep_next=true ;;
2017	esac
2018      fi
2019      as_fn_append ac_configure_args " '$ac_arg'"
2020      ;;
2021    esac
2022  done
2023done
2024{ ac_configure_args0=; unset ac_configure_args0;}
2025{ ac_configure_args1=; unset ac_configure_args1;}
2026
2027# When interrupted or exit'd, cleanup temporary files, and complete
2028# config.log.  We remove comments because anyway the quotes in there
2029# would cause problems or look ugly.
2030# WARNING: Use '\'' to represent an apostrophe within the trap.
2031# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2032trap 'exit_status=$?
2033  # Sanitize IFS.
2034  IFS=" ""	$as_nl"
2035  # Save into config.log some information that might help in debugging.
2036  {
2037    echo
2038
2039    printf "%s\n" "## ---------------- ##
2040## Cache variables. ##
2041## ---------------- ##"
2042    echo
2043    # The following way of writing the cache mishandles newlines in values,
2044(
2045  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2046    eval ac_val=\$$ac_var
2047    case $ac_val in #(
2048    *${as_nl}*)
2049      case $ac_var in #(
2050      *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2051printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2052      esac
2053      case $ac_var in #(
2054      _ | IFS | as_nl) ;; #(
2055      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2056      *) { eval $ac_var=; unset $ac_var;} ;;
2057      esac ;;
2058    esac
2059  done
2060  (set) 2>&1 |
2061    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2062    *${as_nl}ac_space=\ *)
2063      sed -n \
2064	"s/'\''/'\''\\\\'\'''\''/g;
2065	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2066      ;; #(
2067    *)
2068      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2069      ;;
2070    esac |
2071    sort
2072)
2073    echo
2074
2075    printf "%s\n" "## ----------------- ##
2076## Output variables. ##
2077## ----------------- ##"
2078    echo
2079    for ac_var in $ac_subst_vars
2080    do
2081      eval ac_val=\$$ac_var
2082      case $ac_val in
2083      *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2084      esac
2085      printf "%s\n" "$ac_var='\''$ac_val'\''"
2086    done | sort
2087    echo
2088
2089    if test -n "$ac_subst_files"; then
2090      printf "%s\n" "## ------------------- ##
2091## File substitutions. ##
2092## ------------------- ##"
2093      echo
2094      for ac_var in $ac_subst_files
2095      do
2096	eval ac_val=\$$ac_var
2097	case $ac_val in
2098	*\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2099	esac
2100	printf "%s\n" "$ac_var='\''$ac_val'\''"
2101      done | sort
2102      echo
2103    fi
2104
2105    if test -s confdefs.h; then
2106      printf "%s\n" "## ----------- ##
2107## confdefs.h. ##
2108## ----------- ##"
2109      echo
2110      cat confdefs.h
2111      echo
2112    fi
2113    test "$ac_signal" != 0 &&
2114      printf "%s\n" "$as_me: caught signal $ac_signal"
2115    printf "%s\n" "$as_me: exit $exit_status"
2116  } >&5
2117  rm -f core *.core core.conftest.* &&
2118    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2119    exit $exit_status
2120' 0
2121for ac_signal in 1 2 13 15; do
2122  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2123done
2124ac_signal=0
2125
2126# confdefs.h avoids OS command line length limits that DEFS can exceed.
2127rm -f -r conftest* confdefs.h
2128
2129printf "%s\n" "/* confdefs.h */" > confdefs.h
2130
2131# Predefined preprocessor variables.
2132
2133printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h
2134
2135printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h
2136
2137printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h
2138
2139printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h
2140
2141printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h
2142
2143printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h
2144
2145
2146# Let the site file select an alternate cache file if it wants to.
2147# Prefer an explicitly selected file to automatically selected ones.
2148if test -n "$CONFIG_SITE"; then
2149  ac_site_files="$CONFIG_SITE"
2150elif test "x$prefix" != xNONE; then
2151  ac_site_files="$prefix/share/config.site $prefix/etc/config.site"
2152else
2153  ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
2154fi
2155
2156for ac_site_file in $ac_site_files
2157do
2158  case $ac_site_file in #(
2159  */*) :
2160     ;; #(
2161  *) :
2162    ac_site_file=./$ac_site_file ;;
2163esac
2164  if test -f "$ac_site_file" && test -r "$ac_site_file"; then
2165    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2166printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;}
2167    sed 's/^/| /' "$ac_site_file" >&5
2168    . "$ac_site_file" \
2169      || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2170printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
2171as_fn_error $? "failed to load site script $ac_site_file
2172See \`config.log' for more details" "$LINENO" 5; }
2173  fi
2174done
2175
2176if test -r "$cache_file"; then
2177  # Some versions of bash will fail to source /dev/null (special files
2178  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2179  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2180    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2181printf "%s\n" "$as_me: loading cache $cache_file" >&6;}
2182    case $cache_file in
2183      [\\/]* | ?:[\\/]* ) . "$cache_file";;
2184      *)                      . "./$cache_file";;
2185    esac
2186  fi
2187else
2188  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2189printf "%s\n" "$as_me: creating cache $cache_file" >&6;}
2190  >$cache_file
2191fi
2192
2193# Test code for whether the C compiler supports C89 (global declarations)
2194ac_c_conftest_c89_globals='
2195/* Does the compiler advertise C89 conformance?
2196   Do not test the value of __STDC__, because some compilers set it to 0
2197   while being otherwise adequately conformant. */
2198#if !defined __STDC__
2199# error "Compiler does not advertise C89 conformance"
2200#endif
2201
2202#include <stddef.h>
2203#include <stdarg.h>
2204struct stat;
2205/* Most of the following tests are stolen from RCS 5.7 src/conf.sh.  */
2206struct buf { int x; };
2207struct buf * (*rcsopen) (struct buf *, struct stat *, int);
2208static char *e (p, i)
2209     char **p;
2210     int i;
2211{
2212  return p[i];
2213}
2214static char *f (char * (*g) (char **, int), char **p, ...)
2215{
2216  char *s;
2217  va_list v;
2218  va_start (v,p);
2219  s = g (p, va_arg (v,int));
2220  va_end (v);
2221  return s;
2222}
2223
2224/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
2225   function prototypes and stuff, but not \xHH hex character constants.
2226   These do not provoke an error unfortunately, instead are silently treated
2227   as an "x".  The following induces an error, until -std is added to get
2228   proper ANSI mode.  Curiously \x00 != x always comes out true, for an
2229   array size at least.  It is necessary to write \x00 == 0 to get something
2230   that is true only with -std.  */
2231int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1];
2232
2233/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
2234   inside strings and character constants.  */
2235#define FOO(x) '\''x'\''
2236int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1];
2237
2238int test (int i, double x);
2239struct s1 {int (*f) (int a);};
2240struct s2 {int (*f) (double a);};
2241int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int),
2242               int, int);'
2243
2244# Test code for whether the C compiler supports C89 (body of main).
2245ac_c_conftest_c89_main='
2246ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]);
2247'
2248
2249# Test code for whether the C compiler supports C99 (global declarations)
2250ac_c_conftest_c99_globals='
2251// Does the compiler advertise C99 conformance?
2252#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L
2253# error "Compiler does not advertise C99 conformance"
2254#endif
2255
2256#include <stdbool.h>
2257extern int puts (const char *);
2258extern int printf (const char *, ...);
2259extern int dprintf (int, const char *, ...);
2260extern void *malloc (size_t);
2261
2262// Check varargs macros.  These examples are taken from C99 6.10.3.5.
2263// dprintf is used instead of fprintf to avoid needing to declare
2264// FILE and stderr.
2265#define debug(...) dprintf (2, __VA_ARGS__)
2266#define showlist(...) puts (#__VA_ARGS__)
2267#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
2268static void
2269test_varargs_macros (void)
2270{
2271  int x = 1234;
2272  int y = 5678;
2273  debug ("Flag");
2274  debug ("X = %d\n", x);
2275  showlist (The first, second, and third items.);
2276  report (x>y, "x is %d but y is %d", x, y);
2277}
2278
2279// Check long long types.
2280#define BIG64 18446744073709551615ull
2281#define BIG32 4294967295ul
2282#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
2283#if !BIG_OK
2284  #error "your preprocessor is broken"
2285#endif
2286#if BIG_OK
2287#else
2288  #error "your preprocessor is broken"
2289#endif
2290static long long int bignum = -9223372036854775807LL;
2291static unsigned long long int ubignum = BIG64;
2292
2293struct incomplete_array
2294{
2295  int datasize;
2296  double data[];
2297};
2298
2299struct named_init {
2300  int number;
2301  const wchar_t *name;
2302  double average;
2303};
2304
2305typedef const char *ccp;
2306
2307static inline int
2308test_restrict (ccp restrict text)
2309{
2310  // See if C++-style comments work.
2311  // Iterate through items via the restricted pointer.
2312  // Also check for declarations in for loops.
2313  for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i)
2314    continue;
2315  return 0;
2316}
2317
2318// Check varargs and va_copy.
2319static bool
2320test_varargs (const char *format, ...)
2321{
2322  va_list args;
2323  va_start (args, format);
2324  va_list args_copy;
2325  va_copy (args_copy, args);
2326
2327  const char *str = "";
2328  int number = 0;
2329  float fnumber = 0;
2330
2331  while (*format)
2332    {
2333      switch (*format++)
2334	{
2335	case '\''s'\'': // string
2336	  str = va_arg (args_copy, const char *);
2337	  break;
2338	case '\''d'\'': // int
2339	  number = va_arg (args_copy, int);
2340	  break;
2341	case '\''f'\'': // float
2342	  fnumber = va_arg (args_copy, double);
2343	  break;
2344	default:
2345	  break;
2346	}
2347    }
2348  va_end (args_copy);
2349  va_end (args);
2350
2351  return *str && number && fnumber;
2352}
2353'
2354
2355# Test code for whether the C compiler supports C99 (body of main).
2356ac_c_conftest_c99_main='
2357  // Check bool.
2358  _Bool success = false;
2359  success |= (argc != 0);
2360
2361  // Check restrict.
2362  if (test_restrict ("String literal") == 0)
2363    success = true;
2364  char *restrict newvar = "Another string";
2365
2366  // Check varargs.
2367  success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234);
2368  test_varargs_macros ();
2369
2370  // Check flexible array members.
2371  struct incomplete_array *ia =
2372    malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
2373  ia->datasize = 10;
2374  for (int i = 0; i < ia->datasize; ++i)
2375    ia->data[i] = i * 1.234;
2376
2377  // Check named initializers.
2378  struct named_init ni = {
2379    .number = 34,
2380    .name = L"Test wide string",
2381    .average = 543.34343,
2382  };
2383
2384  ni.number = 58;
2385
2386  int dynamic_array[ni.number];
2387  dynamic_array[0] = argv[0][0];
2388  dynamic_array[ni.number - 1] = 543;
2389
2390  // work around unused variable warnings
2391  ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\''
2392	 || dynamic_array[ni.number - 1] != 543);
2393'
2394
2395# Test code for whether the C compiler supports C11 (global declarations)
2396ac_c_conftest_c11_globals='
2397// Does the compiler advertise C11 conformance?
2398#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L
2399# error "Compiler does not advertise C11 conformance"
2400#endif
2401
2402// Check _Alignas.
2403char _Alignas (double) aligned_as_double;
2404char _Alignas (0) no_special_alignment;
2405extern char aligned_as_int;
2406char _Alignas (0) _Alignas (int) aligned_as_int;
2407
2408// Check _Alignof.
2409enum
2410{
2411  int_alignment = _Alignof (int),
2412  int_array_alignment = _Alignof (int[100]),
2413  char_alignment = _Alignof (char)
2414};
2415_Static_assert (0 < -_Alignof (int), "_Alignof is signed");
2416
2417// Check _Noreturn.
2418int _Noreturn does_not_return (void) { for (;;) continue; }
2419
2420// Check _Static_assert.
2421struct test_static_assert
2422{
2423  int x;
2424  _Static_assert (sizeof (int) <= sizeof (long int),
2425                  "_Static_assert does not work in struct");
2426  long int y;
2427};
2428
2429// Check UTF-8 literals.
2430#define u8 syntax error!
2431char const utf8_literal[] = u8"happens to be ASCII" "another string";
2432
2433// Check duplicate typedefs.
2434typedef long *long_ptr;
2435typedef long int *long_ptr;
2436typedef long_ptr long_ptr;
2437
2438// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
2439struct anonymous
2440{
2441  union {
2442    struct { int i; int j; };
2443    struct { int k; long int l; } w;
2444  };
2445  int m;
2446} v1;
2447'
2448
2449# Test code for whether the C compiler supports C11 (body of main).
2450ac_c_conftest_c11_main='
2451  _Static_assert ((offsetof (struct anonymous, i)
2452		   == offsetof (struct anonymous, w.k)),
2453		  "Anonymous union alignment botch");
2454  v1.i = 2;
2455  v1.w.k = 5;
2456  ok |= v1.i != 5;
2457'
2458
2459# Test code for whether the C compiler supports C11 (complete).
2460ac_c_conftest_c11_program="${ac_c_conftest_c89_globals}
2461${ac_c_conftest_c99_globals}
2462${ac_c_conftest_c11_globals}
2463
2464int
2465main (int argc, char **argv)
2466{
2467  int ok = 0;
2468  ${ac_c_conftest_c89_main}
2469  ${ac_c_conftest_c99_main}
2470  ${ac_c_conftest_c11_main}
2471  return ok;
2472}
2473"
2474
2475# Test code for whether the C compiler supports C99 (complete).
2476ac_c_conftest_c99_program="${ac_c_conftest_c89_globals}
2477${ac_c_conftest_c99_globals}
2478
2479int
2480main (int argc, char **argv)
2481{
2482  int ok = 0;
2483  ${ac_c_conftest_c89_main}
2484  ${ac_c_conftest_c99_main}
2485  return ok;
2486}
2487"
2488
2489# Test code for whether the C compiler supports C89 (complete).
2490ac_c_conftest_c89_program="${ac_c_conftest_c89_globals}
2491
2492int
2493main (int argc, char **argv)
2494{
2495  int ok = 0;
2496  ${ac_c_conftest_c89_main}
2497  return ok;
2498}
2499"
2500
2501as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H"
2502as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H"
2503as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H"
2504as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H"
2505as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H"
2506as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H"
2507as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H"
2508as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H"
2509as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H"
2510as_fn_append ac_header_c_list " sys/time.h sys_time_h HAVE_SYS_TIME_H"
2511# Check that the precious variables saved in the cache have kept the same
2512# value.
2513ac_cache_corrupted=false
2514for ac_var in $ac_precious_vars; do
2515  eval ac_old_set=\$ac_cv_env_${ac_var}_set
2516  eval ac_new_set=\$ac_env_${ac_var}_set
2517  eval ac_old_val=\$ac_cv_env_${ac_var}_value
2518  eval ac_new_val=\$ac_env_${ac_var}_value
2519  case $ac_old_set,$ac_new_set in
2520    set,)
2521      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2522printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2523      ac_cache_corrupted=: ;;
2524    ,set)
2525      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2526printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2527      ac_cache_corrupted=: ;;
2528    ,);;
2529    *)
2530      if test "x$ac_old_val" != "x$ac_new_val"; then
2531	# differences in whitespace do not lead to failure.
2532	ac_old_val_w=`echo x $ac_old_val`
2533	ac_new_val_w=`echo x $ac_new_val`
2534	if test "$ac_old_val_w" != "$ac_new_val_w"; then
2535	  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2536printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2537	  ac_cache_corrupted=:
2538	else
2539	  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2540printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2541	  eval $ac_var=\$ac_old_val
2542	fi
2543	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2544printf "%s\n" "$as_me:   former value:  \`$ac_old_val'" >&2;}
2545	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2546printf "%s\n" "$as_me:   current value: \`$ac_new_val'" >&2;}
2547      fi;;
2548  esac
2549  # Pass precious variables to config.status.
2550  if test "$ac_new_set" = set; then
2551    case $ac_new_val in
2552    *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2553    *) ac_arg=$ac_var=$ac_new_val ;;
2554    esac
2555    case " $ac_configure_args " in
2556      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2557      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2558    esac
2559  fi
2560done
2561if $ac_cache_corrupted; then
2562  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2563printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
2564  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2565printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;}
2566  as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file'
2567	    and start over" "$LINENO" 5
2568fi
2569## -------------------- ##
2570## Main body of script. ##
2571## -------------------- ##
2572
2573ac_ext=c
2574ac_cpp='$CPP $CPPFLAGS'
2575ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2576ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2577ac_compiler_gnu=$ac_cv_c_compiler_gnu
2578
2579
2580
2581
2582
2583
2584TK_VERSION=8.7
2585TK_MAJOR_VERSION=8
2586TK_MINOR_VERSION=7
2587TK_PATCH_LEVEL="a5"
2588VERSION=${TK_VERSION}
2589LOCALES="cs da de el en en_gb eo es fr hu it nl pl pt ru sv"
2590
2591#--------------------------------------------------------------------
2592# Find and load the tclConfig.sh file
2593#--------------------------------------------------------------------
2594
2595
2596    #
2597    # Ok, lets find the tcl configuration
2598    # First, look for one uninstalled.
2599    # the alternative search directory is invoked by --with-tcl
2600    #
2601
2602    if test x"${no_tcl}" = x ; then
2603	# we reset no_tcl in case something fails here
2604	no_tcl=true
2605
2606# Check whether --with-tcl was given.
2607if test ${with_tcl+y}
2608then :
2609  withval=$with_tcl; with_tclconfig="${withval}"
2610fi
2611
2612	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5
2613printf %s "checking for Tcl configuration... " >&6; }
2614	if test ${ac_cv_c_tclconfig+y}
2615then :
2616  printf %s "(cached) " >&6
2617else $as_nop
2618
2619
2620	    # First check to see if --with-tcl was specified.
2621	    if test x"${with_tclconfig}" != x ; then
2622		case "${with_tclconfig}" in
2623		    */tclConfig.sh )
2624			if test -f "${with_tclconfig}"; then
2625			    { 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
2626printf "%s\n" "$as_me: WARNING: --with-tcl argument should refer to directory containing tclConfig.sh, not to tclConfig.sh itself" >&2;}
2627			    with_tclconfig="`echo "${with_tclconfig}" | sed 's!/tclConfig\.sh$!!'`"
2628			fi ;;
2629		esac
2630		if test -f "${with_tclconfig}/tclConfig.sh" ; then
2631		    ac_cv_c_tclconfig="`(cd "${with_tclconfig}"; pwd)`"
2632		else
2633		    as_fn_error $? "${with_tclconfig} directory doesn't contain tclConfig.sh" "$LINENO" 5
2634		fi
2635	    fi
2636
2637	    # then check for a private Tcl installation
2638	    if test x"${ac_cv_c_tclconfig}" = x ; then
2639		for i in \
2640			../tcl \
2641			`ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
2642			`ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
2643			`ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
2644			../../tcl \
2645			`ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
2646			`ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
2647			`ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
2648			../../../tcl \
2649			`ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
2650			`ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
2651			`ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
2652		    if test -f "$i/unix/tclConfig.sh" ; then
2653			ac_cv_c_tclconfig="`(cd $i/unix; pwd)`"
2654			break
2655		    fi
2656		done
2657	    fi
2658
2659	    # on Darwin, check in Framework installation locations
2660	    if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
2661		for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
2662			`ls -d /Library/Frameworks 2>/dev/null` \
2663			`ls -d /Network/Library/Frameworks 2>/dev/null` \
2664			; do
2665		    if test -f "$i/Tcl.framework/tclConfig.sh" ; then
2666			ac_cv_c_tclconfig="`(cd $i/Tcl.framework; pwd)`"
2667			break
2668		    fi
2669		done
2670	    fi
2671
2672	    # check in a few common install locations
2673	    if test x"${ac_cv_c_tclconfig}" = x ; then
2674		for i in `ls -d ${libdir} 2>/dev/null` \
2675			`ls -d ${exec_prefix}/lib 2>/dev/null` \
2676			`ls -d ${prefix}/lib 2>/dev/null` \
2677			`ls -d /usr/local/lib 2>/dev/null` \
2678			`ls -d /usr/contrib/lib 2>/dev/null` \
2679			`ls -d /usr/pkg/lib 2>/dev/null` \
2680			`ls -d /usr/lib/tcl8.7 2>/dev/null` \
2681			`ls -d /usr/lib 2>/dev/null` \
2682			`ls -d /usr/lib64 2>/dev/null` \
2683			`ls -d /usr/local/lib/tcl8.7 2>/dev/null` \
2684			`ls -d /usr/local/lib/tcl/tcl8.7 2>/dev/null` \
2685			; do
2686		    if test -f "$i/tclConfig.sh" ; then
2687			ac_cv_c_tclconfig="`(cd $i; pwd)`"
2688			break
2689		    fi
2690		done
2691	    fi
2692
2693	    # check in a few other private locations
2694	    if test x"${ac_cv_c_tclconfig}" = x ; then
2695		for i in \
2696			${srcdir}/../tcl \
2697			`ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
2698			`ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
2699			`ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
2700		    if test -f "$i/unix/tclConfig.sh" ; then
2701			ac_cv_c_tclconfig="`(cd $i/unix; pwd)`"
2702			break
2703		    fi
2704		done
2705	    fi
2706
2707fi
2708
2709
2710	if test x"${ac_cv_c_tclconfig}" = x ; then
2711	    TCL_BIN_DIR="# no Tcl configs found"
2712	    as_fn_error $? "Can't find Tcl configuration definitions. Use --with-tcl to specify a directory containing tclConfig.sh" "$LINENO" 5
2713	else
2714	    no_tcl=
2715	    TCL_BIN_DIR="${ac_cv_c_tclconfig}"
2716	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
2717printf "%s\n" "found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
2718	fi
2719    fi
2720
2721
2722    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
2723printf %s "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... " >&6; }
2724
2725    if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
2726        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: loading" >&5
2727printf "%s\n" "loading" >&6; }
2728	. "${TCL_BIN_DIR}/tclConfig.sh"
2729    else
2730        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
2731printf "%s\n" "could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
2732    fi
2733
2734    # If the TCL_BIN_DIR is the build directory (not the install directory),
2735    # then set the common variable name to the value of the build variables.
2736    # For example, the variable TCL_LIB_SPEC will be set to the value
2737    # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
2738    # instead of TCL_BUILD_LIB_SPEC since it will work with both an
2739    # installed and uninstalled version of Tcl.
2740    if test -f "${TCL_BIN_DIR}/Makefile" ; then
2741        TCL_LIB_SPEC="${TCL_BUILD_LIB_SPEC}"
2742        TCL_STUB_LIB_SPEC="${TCL_BUILD_STUB_LIB_SPEC}"
2743        TCL_STUB_LIB_PATH="${TCL_BUILD_STUB_LIB_PATH}"
2744    elif test "`uname -s`" = "Darwin"; then
2745	# If Tcl was built as a framework, attempt to use the libraries
2746	# from the framework at the given location so that linking works
2747	# against Tcl.framework installed in an arbitrary location.
2748	case ${TCL_DEFS} in
2749	    *TCL_FRAMEWORK*)
2750		if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
2751		    for i in "`cd "${TCL_BIN_DIR}"; pwd`" \
2752			     "`cd "${TCL_BIN_DIR}"/../..; pwd`"; do
2753			if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
2754			    TCL_LIB_SPEC="-F`dirname "$i" | sed -e 's/ /\\\\ /g'` -framework ${TCL_LIB_FILE}"
2755			    break
2756			fi
2757		    done
2758		fi
2759		if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
2760		    TCL_STUB_LIB_SPEC="-L`echo "${TCL_BIN_DIR}"  | sed -e 's/ /\\\\ /g'` ${TCL_STUB_LIB_FLAG}"
2761		    TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
2762		fi
2763		;;
2764	esac
2765    fi
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781if test "${TCL_MAJOR_VERSION}" -lt 9 ; then
2782if test "${TCL_MAJOR_VERSION}" -ne 8 ; then
2783    as_fn_error $? "${PACKAGE_NAME} ${PACKAGE_VERSION} requires Tcl 8.6+
2784Found config for Tcl ${TCL_VERSION}" "$LINENO" 5
2785fi
2786if test "${TCL_MINOR_VERSION}" -lt 6 ; then
2787    as_fn_error $? "${PACKAGE_NAME} ${PACKAGE_VERSION} requires Tcl 8.6+
2788Found config for Tcl ${TCL_VERSION}" "$LINENO" 5
2789fi
2790fi
2791
2792
2793    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tclsh" >&5
2794printf %s "checking for tclsh... " >&6; }
2795    if test ${ac_cv_path_tclsh+y}
2796then :
2797  printf %s "(cached) " >&6
2798else $as_nop
2799
2800	search_path=`echo ${PATH} | sed -e 's/:/ /g'`
2801	for dir in $search_path ; do
2802	    for j in `ls -r $dir/tclsh[8-9]* 2> /dev/null` \
2803		    `ls -r $dir/tclsh* 2> /dev/null` ; do
2804		if test x"$ac_cv_path_tclsh" = x ; then
2805		    if test -f "$j" ; then
2806			ac_cv_path_tclsh=$j
2807			break
2808		    fi
2809		fi
2810	    done
2811	done
2812
2813fi
2814
2815
2816    if test -f "$ac_cv_path_tclsh" ; then
2817	TCLSH_PROG="$ac_cv_path_tclsh"
2818	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $TCLSH_PROG" >&5
2819printf "%s\n" "$TCLSH_PROG" >&6; }
2820    else
2821	# It is not an error if an installed version of Tcl can't be located.
2822	TCLSH_PROG=""
2823	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: No tclsh found on PATH" >&5
2824printf "%s\n" "No tclsh found on PATH" >&6; }
2825    fi
2826
2827
2828
2829    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tclsh in Tcl build directory" >&5
2830printf %s "checking for tclsh in Tcl build directory... " >&6; }
2831    BUILD_TCLSH="${TCL_BIN_DIR}"/tclsh
2832    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $BUILD_TCLSH" >&5
2833printf "%s\n" "$BUILD_TCLSH" >&6; }
2834
2835
2836
2837#------------------------------------------------------------------------
2838# Handle the --prefix=... option
2839#------------------------------------------------------------------------
2840
2841if test "${prefix}" = "NONE"; then
2842    prefix="$TCL_PREFIX"
2843fi
2844if test "${exec_prefix}" = "NONE"; then
2845    exec_prefix=$prefix
2846fi
2847# Make sure srcdir is fully qualified!
2848srcdir="`cd "$srcdir" ; pwd`"
2849TK_SRC_DIR="`cd "$srcdir"/..; pwd`"
2850
2851#------------------------------------------------------------------------
2852# Compress and/or soft link the manpages?
2853#------------------------------------------------------------------------
2854
2855
2856    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to use symlinks for manpages" >&5
2857printf %s "checking whether to use symlinks for manpages... " >&6; }
2858    # Check whether --enable-man-symlinks was given.
2859if test ${enable_man_symlinks+y}
2860then :
2861  enableval=$enable_man_symlinks; test "$enableval" != "no" && MAN_FLAGS="$MAN_FLAGS --symlinks"
2862else $as_nop
2863  enableval="no"
2864fi
2865
2866    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enableval" >&5
2867printf "%s\n" "$enableval" >&6; }
2868
2869    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to compress the manpages" >&5
2870printf %s "checking whether to compress the manpages... " >&6; }
2871    # Check whether --enable-man-compression was given.
2872if test ${enable_man_compression+y}
2873then :
2874  enableval=$enable_man_compression; case $enableval in
2875	    yes) as_fn_error $? "missing argument to --enable-man-compression" "$LINENO" 5;;
2876	    no)  ;;
2877	    *)   MAN_FLAGS="$MAN_FLAGS --compress $enableval";;
2878	esac
2879else $as_nop
2880  enableval="no"
2881fi
2882
2883    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enableval" >&5
2884printf "%s\n" "$enableval" >&6; }
2885    if test "$enableval" != "no"; then
2886	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for compressed file suffix" >&5
2887printf %s "checking for compressed file suffix... " >&6; }
2888	touch TeST
2889	$enableval TeST
2890	Z=`ls TeST* | sed 's/^....//'`
2891	rm -f TeST*
2892	MAN_FLAGS="$MAN_FLAGS --extension $Z"
2893	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $Z" >&5
2894printf "%s\n" "$Z" >&6; }
2895    fi
2896
2897    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to add a package name suffix for the manpages" >&5
2898printf %s "checking whether to add a package name suffix for the manpages... " >&6; }
2899    # Check whether --enable-man-suffix was given.
2900if test ${enable_man_suffix+y}
2901then :
2902  enableval=$enable_man_suffix; case $enableval in
2903	    yes) enableval="tk" MAN_FLAGS="$MAN_FLAGS --suffix $enableval";;
2904	    no)  ;;
2905	    *)   MAN_FLAGS="$MAN_FLAGS --suffix $enableval";;
2906	esac
2907else $as_nop
2908  enableval="no"
2909fi
2910
2911    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enableval" >&5
2912printf "%s\n" "$enableval" >&6; }
2913
2914
2915
2916
2917#------------------------------------------------------------------------
2918# Standard compiler checks
2919#------------------------------------------------------------------------
2920
2921# If the user did not set CFLAGS, set it now to keep
2922# the AC_PROG_CC macro from adding "-g -O2".
2923if test "${CFLAGS+set}" != "set" ; then
2924    CFLAGS=""
2925fi
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936ac_ext=c
2937ac_cpp='$CPP $CPPFLAGS'
2938ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2939ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2940ac_compiler_gnu=$ac_cv_c_compiler_gnu
2941if test -n "$ac_tool_prefix"; then
2942  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2943set dummy ${ac_tool_prefix}gcc; ac_word=$2
2944{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2945printf %s "checking for $ac_word... " >&6; }
2946if test ${ac_cv_prog_CC+y}
2947then :
2948  printf %s "(cached) " >&6
2949else $as_nop
2950  if test -n "$CC"; then
2951  ac_cv_prog_CC="$CC" # Let the user override the test.
2952else
2953as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2954for as_dir in $PATH
2955do
2956  IFS=$as_save_IFS
2957  case $as_dir in #(((
2958    '') as_dir=./ ;;
2959    */) ;;
2960    *) as_dir=$as_dir/ ;;
2961  esac
2962    for ac_exec_ext in '' $ac_executable_extensions; do
2963  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
2964    ac_cv_prog_CC="${ac_tool_prefix}gcc"
2965    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
2966    break 2
2967  fi
2968done
2969  done
2970IFS=$as_save_IFS
2971
2972fi
2973fi
2974CC=$ac_cv_prog_CC
2975if test -n "$CC"; then
2976  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2977printf "%s\n" "$CC" >&6; }
2978else
2979  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
2980printf "%s\n" "no" >&6; }
2981fi
2982
2983
2984fi
2985if test -z "$ac_cv_prog_CC"; then
2986  ac_ct_CC=$CC
2987  # Extract the first word of "gcc", so it can be a program name with args.
2988set dummy gcc; ac_word=$2
2989{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2990printf %s "checking for $ac_word... " >&6; }
2991if test ${ac_cv_prog_ac_ct_CC+y}
2992then :
2993  printf %s "(cached) " >&6
2994else $as_nop
2995  if test -n "$ac_ct_CC"; then
2996  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2997else
2998as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2999for as_dir in $PATH
3000do
3001  IFS=$as_save_IFS
3002  case $as_dir in #(((
3003    '') as_dir=./ ;;
3004    */) ;;
3005    *) as_dir=$as_dir/ ;;
3006  esac
3007    for ac_exec_ext in '' $ac_executable_extensions; do
3008  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3009    ac_cv_prog_ac_ct_CC="gcc"
3010    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3011    break 2
3012  fi
3013done
3014  done
3015IFS=$as_save_IFS
3016
3017fi
3018fi
3019ac_ct_CC=$ac_cv_prog_ac_ct_CC
3020if test -n "$ac_ct_CC"; then
3021  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3022printf "%s\n" "$ac_ct_CC" >&6; }
3023else
3024  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3025printf "%s\n" "no" >&6; }
3026fi
3027
3028  if test "x$ac_ct_CC" = x; then
3029    CC=""
3030  else
3031    case $cross_compiling:$ac_tool_warned in
3032yes:)
3033{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3034printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3035ac_tool_warned=yes ;;
3036esac
3037    CC=$ac_ct_CC
3038  fi
3039else
3040  CC="$ac_cv_prog_CC"
3041fi
3042
3043if test -z "$CC"; then
3044          if test -n "$ac_tool_prefix"; then
3045    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3046set dummy ${ac_tool_prefix}cc; ac_word=$2
3047{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3048printf %s "checking for $ac_word... " >&6; }
3049if test ${ac_cv_prog_CC+y}
3050then :
3051  printf %s "(cached) " >&6
3052else $as_nop
3053  if test -n "$CC"; then
3054  ac_cv_prog_CC="$CC" # Let the user override the test.
3055else
3056as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3057for as_dir in $PATH
3058do
3059  IFS=$as_save_IFS
3060  case $as_dir in #(((
3061    '') as_dir=./ ;;
3062    */) ;;
3063    *) as_dir=$as_dir/ ;;
3064  esac
3065    for ac_exec_ext in '' $ac_executable_extensions; do
3066  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3067    ac_cv_prog_CC="${ac_tool_prefix}cc"
3068    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3069    break 2
3070  fi
3071done
3072  done
3073IFS=$as_save_IFS
3074
3075fi
3076fi
3077CC=$ac_cv_prog_CC
3078if test -n "$CC"; then
3079  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3080printf "%s\n" "$CC" >&6; }
3081else
3082  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3083printf "%s\n" "no" >&6; }
3084fi
3085
3086
3087  fi
3088fi
3089if test -z "$CC"; then
3090  # Extract the first word of "cc", so it can be a program name with args.
3091set dummy cc; ac_word=$2
3092{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3093printf %s "checking for $ac_word... " >&6; }
3094if test ${ac_cv_prog_CC+y}
3095then :
3096  printf %s "(cached) " >&6
3097else $as_nop
3098  if test -n "$CC"; then
3099  ac_cv_prog_CC="$CC" # Let the user override the test.
3100else
3101  ac_prog_rejected=no
3102as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3103for as_dir in $PATH
3104do
3105  IFS=$as_save_IFS
3106  case $as_dir in #(((
3107    '') as_dir=./ ;;
3108    */) ;;
3109    *) as_dir=$as_dir/ ;;
3110  esac
3111    for ac_exec_ext in '' $ac_executable_extensions; do
3112  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3113    if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3114       ac_prog_rejected=yes
3115       continue
3116     fi
3117    ac_cv_prog_CC="cc"
3118    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3119    break 2
3120  fi
3121done
3122  done
3123IFS=$as_save_IFS
3124
3125if test $ac_prog_rejected = yes; then
3126  # We found a bogon in the path, so make sure we never use it.
3127  set dummy $ac_cv_prog_CC
3128  shift
3129  if test $# != 0; then
3130    # We chose a different compiler from the bogus one.
3131    # However, it has the same basename, so the bogon will be chosen
3132    # first if we set CC to just the basename; use the full file name.
3133    shift
3134    ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
3135  fi
3136fi
3137fi
3138fi
3139CC=$ac_cv_prog_CC
3140if test -n "$CC"; then
3141  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3142printf "%s\n" "$CC" >&6; }
3143else
3144  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3145printf "%s\n" "no" >&6; }
3146fi
3147
3148
3149fi
3150if test -z "$CC"; then
3151  if test -n "$ac_tool_prefix"; then
3152  for ac_prog in cl.exe
3153  do
3154    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3155set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3156{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3157printf %s "checking for $ac_word... " >&6; }
3158if test ${ac_cv_prog_CC+y}
3159then :
3160  printf %s "(cached) " >&6
3161else $as_nop
3162  if test -n "$CC"; then
3163  ac_cv_prog_CC="$CC" # Let the user override the test.
3164else
3165as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3166for as_dir in $PATH
3167do
3168  IFS=$as_save_IFS
3169  case $as_dir in #(((
3170    '') as_dir=./ ;;
3171    */) ;;
3172    *) as_dir=$as_dir/ ;;
3173  esac
3174    for ac_exec_ext in '' $ac_executable_extensions; do
3175  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3176    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3177    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3178    break 2
3179  fi
3180done
3181  done
3182IFS=$as_save_IFS
3183
3184fi
3185fi
3186CC=$ac_cv_prog_CC
3187if test -n "$CC"; then
3188  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3189printf "%s\n" "$CC" >&6; }
3190else
3191  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3192printf "%s\n" "no" >&6; }
3193fi
3194
3195
3196    test -n "$CC" && break
3197  done
3198fi
3199if test -z "$CC"; then
3200  ac_ct_CC=$CC
3201  for ac_prog in cl.exe
3202do
3203  # Extract the first word of "$ac_prog", so it can be a program name with args.
3204set dummy $ac_prog; ac_word=$2
3205{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3206printf %s "checking for $ac_word... " >&6; }
3207if test ${ac_cv_prog_ac_ct_CC+y}
3208then :
3209  printf %s "(cached) " >&6
3210else $as_nop
3211  if test -n "$ac_ct_CC"; then
3212  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3213else
3214as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3215for as_dir in $PATH
3216do
3217  IFS=$as_save_IFS
3218  case $as_dir in #(((
3219    '') as_dir=./ ;;
3220    */) ;;
3221    *) as_dir=$as_dir/ ;;
3222  esac
3223    for ac_exec_ext in '' $ac_executable_extensions; do
3224  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3225    ac_cv_prog_ac_ct_CC="$ac_prog"
3226    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3227    break 2
3228  fi
3229done
3230  done
3231IFS=$as_save_IFS
3232
3233fi
3234fi
3235ac_ct_CC=$ac_cv_prog_ac_ct_CC
3236if test -n "$ac_ct_CC"; then
3237  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3238printf "%s\n" "$ac_ct_CC" >&6; }
3239else
3240  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3241printf "%s\n" "no" >&6; }
3242fi
3243
3244
3245  test -n "$ac_ct_CC" && break
3246done
3247
3248  if test "x$ac_ct_CC" = x; then
3249    CC=""
3250  else
3251    case $cross_compiling:$ac_tool_warned in
3252yes:)
3253{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3254printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3255ac_tool_warned=yes ;;
3256esac
3257    CC=$ac_ct_CC
3258  fi
3259fi
3260
3261fi
3262if test -z "$CC"; then
3263  if test -n "$ac_tool_prefix"; then
3264  # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
3265set dummy ${ac_tool_prefix}clang; ac_word=$2
3266{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3267printf %s "checking for $ac_word... " >&6; }
3268if test ${ac_cv_prog_CC+y}
3269then :
3270  printf %s "(cached) " >&6
3271else $as_nop
3272  if test -n "$CC"; then
3273  ac_cv_prog_CC="$CC" # Let the user override the test.
3274else
3275as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3276for as_dir in $PATH
3277do
3278  IFS=$as_save_IFS
3279  case $as_dir in #(((
3280    '') as_dir=./ ;;
3281    */) ;;
3282    *) as_dir=$as_dir/ ;;
3283  esac
3284    for ac_exec_ext in '' $ac_executable_extensions; do
3285  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3286    ac_cv_prog_CC="${ac_tool_prefix}clang"
3287    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3288    break 2
3289  fi
3290done
3291  done
3292IFS=$as_save_IFS
3293
3294fi
3295fi
3296CC=$ac_cv_prog_CC
3297if test -n "$CC"; then
3298  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3299printf "%s\n" "$CC" >&6; }
3300else
3301  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3302printf "%s\n" "no" >&6; }
3303fi
3304
3305
3306fi
3307if test -z "$ac_cv_prog_CC"; then
3308  ac_ct_CC=$CC
3309  # Extract the first word of "clang", so it can be a program name with args.
3310set dummy clang; ac_word=$2
3311{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3312printf %s "checking for $ac_word... " >&6; }
3313if test ${ac_cv_prog_ac_ct_CC+y}
3314then :
3315  printf %s "(cached) " >&6
3316else $as_nop
3317  if test -n "$ac_ct_CC"; then
3318  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3319else
3320as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3321for as_dir in $PATH
3322do
3323  IFS=$as_save_IFS
3324  case $as_dir in #(((
3325    '') as_dir=./ ;;
3326    */) ;;
3327    *) as_dir=$as_dir/ ;;
3328  esac
3329    for ac_exec_ext in '' $ac_executable_extensions; do
3330  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3331    ac_cv_prog_ac_ct_CC="clang"
3332    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3333    break 2
3334  fi
3335done
3336  done
3337IFS=$as_save_IFS
3338
3339fi
3340fi
3341ac_ct_CC=$ac_cv_prog_ac_ct_CC
3342if test -n "$ac_ct_CC"; then
3343  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3344printf "%s\n" "$ac_ct_CC" >&6; }
3345else
3346  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3347printf "%s\n" "no" >&6; }
3348fi
3349
3350  if test "x$ac_ct_CC" = x; then
3351    CC=""
3352  else
3353    case $cross_compiling:$ac_tool_warned in
3354yes:)
3355{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3356printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3357ac_tool_warned=yes ;;
3358esac
3359    CC=$ac_ct_CC
3360  fi
3361else
3362  CC="$ac_cv_prog_CC"
3363fi
3364
3365fi
3366
3367
3368test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3369printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3370as_fn_error $? "no acceptable C compiler found in \$PATH
3371See \`config.log' for more details" "$LINENO" 5; }
3372
3373# Provide some information about the compiler.
3374printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3375set X $ac_compile
3376ac_compiler=$2
3377for ac_option in --version -v -V -qversion -version; do
3378  { { ac_try="$ac_compiler $ac_option >&5"
3379case "(($ac_try" in
3380  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3381  *) ac_try_echo=$ac_try;;
3382esac
3383eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3384printf "%s\n" "$ac_try_echo"; } >&5
3385  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3386  ac_status=$?
3387  if test -s conftest.err; then
3388    sed '10a\
3389... rest of stderr output deleted ...
3390         10q' conftest.err >conftest.er1
3391    cat conftest.er1 >&5
3392  fi
3393  rm -f conftest.er1 conftest.err
3394  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3395  test $ac_status = 0; }
3396done
3397
3398cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3399/* end confdefs.h.  */
3400
3401int
3402main (void)
3403{
3404
3405  ;
3406  return 0;
3407}
3408_ACEOF
3409ac_clean_files_save=$ac_clean_files
3410ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3411# Try to create an executable without -o first, disregard a.out.
3412# It will help us diagnose broken compilers, and finding out an intuition
3413# of exeext.
3414{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3415printf %s "checking whether the C compiler works... " >&6; }
3416ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3417
3418# The possible output files:
3419ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3420
3421ac_rmfiles=
3422for ac_file in $ac_files
3423do
3424  case $ac_file in
3425    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3426    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3427  esac
3428done
3429rm -f $ac_rmfiles
3430
3431if { { ac_try="$ac_link_default"
3432case "(($ac_try" in
3433  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3434  *) ac_try_echo=$ac_try;;
3435esac
3436eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3437printf "%s\n" "$ac_try_echo"; } >&5
3438  (eval "$ac_link_default") 2>&5
3439  ac_status=$?
3440  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3441  test $ac_status = 0; }
3442then :
3443  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3444# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3445# in a Makefile.  We should not override ac_cv_exeext if it was cached,
3446# so that the user can short-circuit this test for compilers unknown to
3447# Autoconf.
3448for ac_file in $ac_files ''
3449do
3450  test -f "$ac_file" || continue
3451  case $ac_file in
3452    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3453	;;
3454    [ab].out )
3455	# We found the default executable, but exeext='' is most
3456	# certainly right.
3457	break;;
3458    *.* )
3459	if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no;
3460	then :; else
3461	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3462	fi
3463	# We set ac_cv_exeext here because the later test for it is not
3464	# safe: cross compilers may not add the suffix if given an `-o'
3465	# argument, so we may need to know it at that point already.
3466	# Even if this section looks crufty: it has the advantage of
3467	# actually working.
3468	break;;
3469    * )
3470	break;;
3471  esac
3472done
3473test "$ac_cv_exeext" = no && ac_cv_exeext=
3474
3475else $as_nop
3476  ac_file=''
3477fi
3478if test -z "$ac_file"
3479then :
3480  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3481printf "%s\n" "no" >&6; }
3482printf "%s\n" "$as_me: failed program was:" >&5
3483sed 's/^/| /' conftest.$ac_ext >&5
3484
3485{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3486printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3487as_fn_error 77 "C compiler cannot create executables
3488See \`config.log' for more details" "$LINENO" 5; }
3489else $as_nop
3490  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3491printf "%s\n" "yes" >&6; }
3492fi
3493{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3494printf %s "checking for C compiler default output file name... " >&6; }
3495{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3496printf "%s\n" "$ac_file" >&6; }
3497ac_exeext=$ac_cv_exeext
3498
3499rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3500ac_clean_files=$ac_clean_files_save
3501{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3502printf %s "checking for suffix of executables... " >&6; }
3503if { { ac_try="$ac_link"
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_link") 2>&5
3511  ac_status=$?
3512  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3513  test $ac_status = 0; }
3514then :
3515  # If both `conftest.exe' and `conftest' are `present' (well, observable)
3516# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3517# work properly (i.e., refer to `conftest.exe'), while it won't with
3518# `rm'.
3519for ac_file in conftest.exe conftest conftest.*; do
3520  test -f "$ac_file" || continue
3521  case $ac_file in
3522    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3523    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3524	  break;;
3525    * ) break;;
3526  esac
3527done
3528else $as_nop
3529  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3530printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3531as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3532See \`config.log' for more details" "$LINENO" 5; }
3533fi
3534rm -f conftest conftest$ac_cv_exeext
3535{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3536printf "%s\n" "$ac_cv_exeext" >&6; }
3537
3538rm -f conftest.$ac_ext
3539EXEEXT=$ac_cv_exeext
3540ac_exeext=$EXEEXT
3541cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3542/* end confdefs.h.  */
3543#include <stdio.h>
3544int
3545main (void)
3546{
3547FILE *f = fopen ("conftest.out", "w");
3548 return ferror (f) || fclose (f) != 0;
3549
3550  ;
3551  return 0;
3552}
3553_ACEOF
3554ac_clean_files="$ac_clean_files conftest.out"
3555# Check that the compiler produces executables we can run.  If not, either
3556# the compiler is broken, or we cross compile.
3557{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3558printf %s "checking whether we are cross compiling... " >&6; }
3559if test "$cross_compiling" != yes; then
3560  { { ac_try="$ac_link"
3561case "(($ac_try" in
3562  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3563  *) ac_try_echo=$ac_try;;
3564esac
3565eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3566printf "%s\n" "$ac_try_echo"; } >&5
3567  (eval "$ac_link") 2>&5
3568  ac_status=$?
3569  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3570  test $ac_status = 0; }
3571  if { ac_try='./conftest$ac_cv_exeext'
3572  { { case "(($ac_try" in
3573  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3574  *) ac_try_echo=$ac_try;;
3575esac
3576eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3577printf "%s\n" "$ac_try_echo"; } >&5
3578  (eval "$ac_try") 2>&5
3579  ac_status=$?
3580  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3581  test $ac_status = 0; }; }; then
3582    cross_compiling=no
3583  else
3584    if test "$cross_compiling" = maybe; then
3585	cross_compiling=yes
3586    else
3587	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3588printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3589as_fn_error 77 "cannot run C compiled programs.
3590If you meant to cross compile, use \`--host'.
3591See \`config.log' for more details" "$LINENO" 5; }
3592    fi
3593  fi
3594fi
3595{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3596printf "%s\n" "$cross_compiling" >&6; }
3597
3598rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3599ac_clean_files=$ac_clean_files_save
3600{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3601printf %s "checking for suffix of object files... " >&6; }
3602if test ${ac_cv_objext+y}
3603then :
3604  printf %s "(cached) " >&6
3605else $as_nop
3606  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3607/* end confdefs.h.  */
3608
3609int
3610main (void)
3611{
3612
3613  ;
3614  return 0;
3615}
3616_ACEOF
3617rm -f conftest.o conftest.obj
3618if { { ac_try="$ac_compile"
3619case "(($ac_try" in
3620  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3621  *) ac_try_echo=$ac_try;;
3622esac
3623eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3624printf "%s\n" "$ac_try_echo"; } >&5
3625  (eval "$ac_compile") 2>&5
3626  ac_status=$?
3627  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3628  test $ac_status = 0; }
3629then :
3630  for ac_file in conftest.o conftest.obj conftest.*; do
3631  test -f "$ac_file" || continue;
3632  case $ac_file in
3633    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3634    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3635       break;;
3636  esac
3637done
3638else $as_nop
3639  printf "%s\n" "$as_me: failed program was:" >&5
3640sed 's/^/| /' conftest.$ac_ext >&5
3641
3642{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3643printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3644as_fn_error $? "cannot compute suffix of object files: cannot compile
3645See \`config.log' for more details" "$LINENO" 5; }
3646fi
3647rm -f conftest.$ac_cv_objext conftest.$ac_ext
3648fi
3649{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3650printf "%s\n" "$ac_cv_objext" >&6; }
3651OBJEXT=$ac_cv_objext
3652ac_objext=$OBJEXT
3653{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
3654printf %s "checking whether the compiler supports GNU C... " >&6; }
3655if test ${ac_cv_c_compiler_gnu+y}
3656then :
3657  printf %s "(cached) " >&6
3658else $as_nop
3659  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3660/* end confdefs.h.  */
3661
3662int
3663main (void)
3664{
3665#ifndef __GNUC__
3666       choke me
3667#endif
3668
3669  ;
3670  return 0;
3671}
3672_ACEOF
3673if ac_fn_c_try_compile "$LINENO"
3674then :
3675  ac_compiler_gnu=yes
3676else $as_nop
3677  ac_compiler_gnu=no
3678fi
3679rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
3680ac_cv_c_compiler_gnu=$ac_compiler_gnu
3681
3682fi
3683{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3684printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
3685ac_compiler_gnu=$ac_cv_c_compiler_gnu
3686
3687if test $ac_compiler_gnu = yes; then
3688  GCC=yes
3689else
3690  GCC=
3691fi
3692ac_test_CFLAGS=${CFLAGS+y}
3693ac_save_CFLAGS=$CFLAGS
3694{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3695printf %s "checking whether $CC accepts -g... " >&6; }
3696if test ${ac_cv_prog_cc_g+y}
3697then :
3698  printf %s "(cached) " >&6
3699else $as_nop
3700  ac_save_c_werror_flag=$ac_c_werror_flag
3701   ac_c_werror_flag=yes
3702   ac_cv_prog_cc_g=no
3703   CFLAGS="-g"
3704   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3705/* end confdefs.h.  */
3706
3707int
3708main (void)
3709{
3710
3711  ;
3712  return 0;
3713}
3714_ACEOF
3715if ac_fn_c_try_compile "$LINENO"
3716then :
3717  ac_cv_prog_cc_g=yes
3718else $as_nop
3719  CFLAGS=""
3720      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3721/* end confdefs.h.  */
3722
3723int
3724main (void)
3725{
3726
3727  ;
3728  return 0;
3729}
3730_ACEOF
3731if ac_fn_c_try_compile "$LINENO"
3732then :
3733
3734else $as_nop
3735  ac_c_werror_flag=$ac_save_c_werror_flag
3736	 CFLAGS="-g"
3737	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3738/* end confdefs.h.  */
3739
3740int
3741main (void)
3742{
3743
3744  ;
3745  return 0;
3746}
3747_ACEOF
3748if ac_fn_c_try_compile "$LINENO"
3749then :
3750  ac_cv_prog_cc_g=yes
3751fi
3752rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
3753fi
3754rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
3755fi
3756rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
3757   ac_c_werror_flag=$ac_save_c_werror_flag
3758fi
3759{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3760printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
3761if test $ac_test_CFLAGS; then
3762  CFLAGS=$ac_save_CFLAGS
3763elif test $ac_cv_prog_cc_g = yes; then
3764  if test "$GCC" = yes; then
3765    CFLAGS="-g -O2"
3766  else
3767    CFLAGS="-g"
3768  fi
3769else
3770  if test "$GCC" = yes; then
3771    CFLAGS="-O2"
3772  else
3773    CFLAGS=
3774  fi
3775fi
3776{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
3777printf %s "checking for $CC option to enable C11 features... " >&6; }
3778if test ${ac_cv_prog_cc_c11+y}
3779then :
3780  printf %s "(cached) " >&6
3781else $as_nop
3782  ac_cv_prog_cc_c11=no
3783ac_save_CC=$CC
3784cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3785/* end confdefs.h.  */
3786$ac_c_conftest_c11_program
3787_ACEOF
3788for ac_arg in '' -std=gnu11
3789do
3790  CC="$ac_save_CC $ac_arg"
3791  if ac_fn_c_try_compile "$LINENO"
3792then :
3793  ac_cv_prog_cc_c11=$ac_arg
3794fi
3795rm -f core conftest.err conftest.$ac_objext conftest.beam
3796  test "x$ac_cv_prog_cc_c11" != "xno" && break
3797done
3798rm -f conftest.$ac_ext
3799CC=$ac_save_CC
3800
3801fi
3802# AC_CACHE_VAL
3803ac_prog_cc_stdc_options=
3804case "x$ac_cv_prog_cc_c11" in #(
3805  x) :
3806    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3807printf "%s\n" "none needed" >&6; } ;; #(
3808  xno) :
3809    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3810printf "%s\n" "unsupported" >&6; } ;; #(
3811  *) :
3812    ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c11"
3813    CC="$CC$ac_prog_cc_stdc_options"
3814    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
3815printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } ;;
3816esac
3817if test "x$ac_cv_prog_cc_c11" != xno
3818then :
3819  ac_prog_cc_stdc=c11
3820		 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
3821else $as_nop
3822  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
3823printf %s "checking for $CC option to enable C99 features... " >&6; }
3824if test ${ac_cv_prog_cc_c99+y}
3825then :
3826  printf %s "(cached) " >&6
3827else $as_nop
3828  ac_cv_prog_cc_c99=no
3829ac_save_CC=$CC
3830cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3831/* end confdefs.h.  */
3832$ac_c_conftest_c89_program
3833_ACEOF
3834for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc1x -qlanglvl=extc99
3835do
3836  CC="$ac_save_CC $ac_arg"
3837  if ac_fn_c_try_compile "$LINENO"
3838then :
3839  ac_cv_prog_cc_c99=$ac_arg
3840fi
3841rm -f core conftest.err conftest.$ac_objext conftest.beam
3842  test "x$ac_cv_prog_cc_c99" != "xno" && break
3843done
3844rm -f conftest.$ac_ext
3845CC=$ac_save_CC
3846
3847fi
3848# AC_CACHE_VAL
3849ac_prog_cc_stdc_options=
3850case "x$ac_cv_prog_cc_c99" in #(
3851  x) :
3852    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3853printf "%s\n" "none needed" >&6; } ;; #(
3854  xno) :
3855    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3856printf "%s\n" "unsupported" >&6; } ;; #(
3857  *) :
3858    ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c99"
3859    CC="$CC$ac_prog_cc_stdc_options"
3860    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
3861printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } ;;
3862esac
3863if test "x$ac_cv_prog_cc_c99" != xno
3864then :
3865  ac_prog_cc_stdc=c99
3866		    ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
3867else $as_nop
3868  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
3869printf %s "checking for $CC option to enable C89 features... " >&6; }
3870if test ${ac_cv_prog_cc_c89+y}
3871then :
3872  printf %s "(cached) " >&6
3873else $as_nop
3874  ac_cv_prog_cc_c89=no
3875ac_save_CC=$CC
3876cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3877/* end confdefs.h.  */
3878$ac_c_conftest_c89_program
3879_ACEOF
3880for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3881	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3882do
3883  CC="$ac_save_CC $ac_arg"
3884  if ac_fn_c_try_compile "$LINENO"
3885then :
3886  ac_cv_prog_cc_c89=$ac_arg
3887fi
3888rm -f core conftest.err conftest.$ac_objext conftest.beam
3889  test "x$ac_cv_prog_cc_c89" != "xno" && break
3890done
3891rm -f conftest.$ac_ext
3892CC=$ac_save_CC
3893
3894fi
3895# AC_CACHE_VAL
3896ac_prog_cc_stdc_options=
3897case "x$ac_cv_prog_cc_c89" in #(
3898  x) :
3899    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3900printf "%s\n" "none needed" >&6; } ;; #(
3901  xno) :
3902    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3903printf "%s\n" "unsupported" >&6; } ;; #(
3904  *) :
3905    ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c89"
3906    CC="$CC$ac_prog_cc_stdc_options"
3907    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3908printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } ;;
3909esac
3910if test "x$ac_cv_prog_cc_c89" != xno
3911then :
3912  ac_prog_cc_stdc=c89
3913		       ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
3914else $as_nop
3915  ac_prog_cc_stdc=no
3916		       ac_cv_prog_cc_stdc=no
3917fi
3918
3919fi
3920
3921fi
3922
3923ac_ext=c
3924ac_cpp='$CPP $CPPFLAGS'
3925ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3926ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3927ac_compiler_gnu=$ac_cv_c_compiler_gnu
3928
3929
3930{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
3931printf %s "checking for inline... " >&6; }
3932if test ${ac_cv_c_inline+y}
3933then :
3934  printf %s "(cached) " >&6
3935else $as_nop
3936  ac_cv_c_inline=no
3937for ac_kw in inline __inline__ __inline; do
3938  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3939/* end confdefs.h.  */
3940#ifndef __cplusplus
3941typedef int foo_t;
3942static $ac_kw foo_t static_foo (void) {return 0; }
3943$ac_kw foo_t foo (void) {return 0; }
3944#endif
3945
3946_ACEOF
3947if ac_fn_c_try_compile "$LINENO"
3948then :
3949  ac_cv_c_inline=$ac_kw
3950fi
3951rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
3952  test "$ac_cv_c_inline" != no && break
3953done
3954
3955fi
3956{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
3957printf "%s\n" "$ac_cv_c_inline" >&6; }
3958
3959case $ac_cv_c_inline in
3960  inline | yes) ;;
3961  *)
3962    case $ac_cv_c_inline in
3963      no) ac_val=;;
3964      *) ac_val=$ac_cv_c_inline;;
3965    esac
3966    cat >>confdefs.h <<_ACEOF
3967#ifndef __cplusplus
3968#define inline $ac_val
3969#endif
3970_ACEOF
3971    ;;
3972esac
3973
3974
3975#------------------------------------------------------------------------
3976# If we're using GCC, see if the compiler understands -pipe.  If so, use it.
3977# It makes compiling go faster.  (This is only a performance feature.)
3978#------------------------------------------------------------------------
3979
3980if test -z "$no_pipe" && test -n "$GCC"; then
3981    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the compiler understands -pipe" >&5
3982printf %s "checking if the compiler understands -pipe... " >&6; }
3983if test ${tcl_cv_cc_pipe+y}
3984then :
3985  printf %s "(cached) " >&6
3986else $as_nop
3987
3988	hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -pipe"
3989	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3990/* end confdefs.h.  */
3991
3992int
3993main (void)
3994{
3995
3996  ;
3997  return 0;
3998}
3999_ACEOF
4000if ac_fn_c_try_compile "$LINENO"
4001then :
4002  tcl_cv_cc_pipe=yes
4003else $as_nop
4004  tcl_cv_cc_pipe=no
4005fi
4006rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
4007	CFLAGS=$hold_cflags
4008fi
4009{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_pipe" >&5
4010printf "%s\n" "$tcl_cv_cc_pipe" >&6; }
4011    if test $tcl_cv_cc_pipe = yes; then
4012	CFLAGS="$CFLAGS -pipe"
4013    fi
4014fi
4015
4016#------------------------------------------------------------------------
4017# Embedded configuration information, encoding to use for the values, TIP #59
4018#------------------------------------------------------------------------
4019
4020
4021
4022# Check whether --with-encoding was given.
4023if test ${with_encoding+y}
4024then :
4025  withval=$with_encoding; with_tcencoding=${withval}
4026fi
4027
4028
4029    if test x"${with_tcencoding}" != x ; then
4030
4031printf "%s\n" "#define TCL_CFGVAL_ENCODING \"${with_tcencoding}\"" >>confdefs.h
4032
4033    else
4034
4035printf "%s\n" "#define TCL_CFGVAL_ENCODING \"utf-8\"" >>confdefs.h
4036
4037    fi
4038
4039
4040
4041    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to build libraries" >&5
4042printf %s "checking how to build libraries... " >&6; }
4043    # Check whether --enable-shared was given.
4044if test ${enable_shared+y}
4045then :
4046  enableval=$enable_shared; tcl_ok=$enableval
4047else $as_nop
4048  tcl_ok=yes
4049fi
4050
4051    if test "$tcl_ok" = "yes" ; then
4052	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: shared" >&5
4053printf "%s\n" "shared" >&6; }
4054	SHARED_BUILD=1
4055    else
4056	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: static" >&5
4057printf "%s\n" "static" >&6; }
4058	SHARED_BUILD=0
4059
4060printf "%s\n" "#define STATIC_BUILD 1" >>confdefs.h
4061
4062    fi
4063
4064
4065
4066#--------------------------------------------------------------------
4067# The statements below define a collection of compile flags.  This
4068# macro depends on the value of SHARED_BUILD, and should be called
4069# after SC_ENABLE_SHARED checks the configure switches.
4070#--------------------------------------------------------------------
4071
4072if test -n "$ac_tool_prefix"; then
4073  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4074set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4075{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4076printf %s "checking for $ac_word... " >&6; }
4077if test ${ac_cv_prog_RANLIB+y}
4078then :
4079  printf %s "(cached) " >&6
4080else $as_nop
4081  if test -n "$RANLIB"; then
4082  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4083else
4084as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4085for as_dir in $PATH
4086do
4087  IFS=$as_save_IFS
4088  case $as_dir in #(((
4089    '') as_dir=./ ;;
4090    */) ;;
4091    *) as_dir=$as_dir/ ;;
4092  esac
4093    for ac_exec_ext in '' $ac_executable_extensions; do
4094  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4095    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4096    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4097    break 2
4098  fi
4099done
4100  done
4101IFS=$as_save_IFS
4102
4103fi
4104fi
4105RANLIB=$ac_cv_prog_RANLIB
4106if test -n "$RANLIB"; then
4107  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4108printf "%s\n" "$RANLIB" >&6; }
4109else
4110  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4111printf "%s\n" "no" >&6; }
4112fi
4113
4114
4115fi
4116if test -z "$ac_cv_prog_RANLIB"; then
4117  ac_ct_RANLIB=$RANLIB
4118  # Extract the first word of "ranlib", so it can be a program name with args.
4119set dummy ranlib; ac_word=$2
4120{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4121printf %s "checking for $ac_word... " >&6; }
4122if test ${ac_cv_prog_ac_ct_RANLIB+y}
4123then :
4124  printf %s "(cached) " >&6
4125else $as_nop
4126  if test -n "$ac_ct_RANLIB"; then
4127  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4128else
4129as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4130for as_dir in $PATH
4131do
4132  IFS=$as_save_IFS
4133  case $as_dir in #(((
4134    '') as_dir=./ ;;
4135    */) ;;
4136    *) as_dir=$as_dir/ ;;
4137  esac
4138    for ac_exec_ext in '' $ac_executable_extensions; do
4139  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4140    ac_cv_prog_ac_ct_RANLIB="ranlib"
4141    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4142    break 2
4143  fi
4144done
4145  done
4146IFS=$as_save_IFS
4147
4148fi
4149fi
4150ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4151if test -n "$ac_ct_RANLIB"; then
4152  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
4153printf "%s\n" "$ac_ct_RANLIB" >&6; }
4154else
4155  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4156printf "%s\n" "no" >&6; }
4157fi
4158
4159  if test "x$ac_ct_RANLIB" = x; then
4160    RANLIB=":"
4161  else
4162    case $cross_compiling:$ac_tool_warned in
4163yes:)
4164{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4165printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4166ac_tool_warned=yes ;;
4167esac
4168    RANLIB=$ac_ct_RANLIB
4169  fi
4170else
4171  RANLIB="$ac_cv_prog_RANLIB"
4172fi
4173
4174ac_header= ac_cache=
4175for ac_item in $ac_header_c_list
4176do
4177  if test $ac_cache; then
4178    ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default"
4179    if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then
4180      printf "%s\n" "#define $ac_item 1" >> confdefs.h
4181    fi
4182    ac_header= ac_cache=
4183  elif test $ac_header; then
4184    ac_cache=$ac_item
4185  else
4186    ac_header=$ac_item
4187  fi
4188done
4189
4190
4191
4192
4193
4194
4195
4196
4197if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes
4198then :
4199
4200printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h
4201
4202fi
4203
4204
4205    # Step 0.a: Enable 64 bit support?
4206
4207    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if 64bit support is requested" >&5
4208printf %s "checking if 64bit support is requested... " >&6; }
4209    # Check whether --enable-64bit was given.
4210if test ${enable_64bit+y}
4211then :
4212  enableval=$enable_64bit; do64bit=$enableval
4213else $as_nop
4214  do64bit=no
4215fi
4216
4217    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $do64bit" >&5
4218printf "%s\n" "$do64bit" >&6; }
4219
4220    # Step 0.b: Enable Solaris 64 bit VIS support?
4221
4222    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if 64bit Sparc VIS support is requested" >&5
4223printf %s "checking if 64bit Sparc VIS support is requested... " >&6; }
4224    # Check whether --enable-64bit-vis was given.
4225if test ${enable_64bit_vis+y}
4226then :
4227  enableval=$enable_64bit_vis; do64bitVIS=$enableval
4228else $as_nop
4229  do64bitVIS=no
4230fi
4231
4232    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $do64bitVIS" >&5
4233printf "%s\n" "$do64bitVIS" >&6; }
4234    # Force 64bit on with VIS
4235    if test "$do64bitVIS" = "yes"
4236then :
4237  do64bit=yes
4238fi
4239
4240    # Step 0.c: Check if visibility support is available. Do this here so
4241    # that platform specific alternatives can be used below if this fails.
4242
4243    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler supports visibility \"hidden\"" >&5
4244printf %s "checking if compiler supports visibility \"hidden\"... " >&6; }
4245if test ${tcl_cv_cc_visibility_hidden+y}
4246then :
4247  printf %s "(cached) " >&6
4248else $as_nop
4249
4250	hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -Werror"
4251	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4252/* end confdefs.h.  */
4253
4254	    extern __attribute__((__visibility__("hidden"))) void f(void);
4255	    void f(void) {}
4256int
4257main (void)
4258{
4259f();
4260  ;
4261  return 0;
4262}
4263_ACEOF
4264if ac_fn_c_try_link "$LINENO"
4265then :
4266  tcl_cv_cc_visibility_hidden=yes
4267else $as_nop
4268  tcl_cv_cc_visibility_hidden=no
4269fi
4270rm -f core conftest.err conftest.$ac_objext conftest.beam \
4271    conftest$ac_exeext conftest.$ac_ext
4272	CFLAGS=$hold_cflags
4273fi
4274{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_visibility_hidden" >&5
4275printf "%s\n" "$tcl_cv_cc_visibility_hidden" >&6; }
4276    if test $tcl_cv_cc_visibility_hidden = yes
4277then :
4278
4279
4280printf "%s\n" "#define MODULE_SCOPE extern __attribute__((__visibility__(\"hidden\")))" >>confdefs.h
4281
4282
4283printf "%s\n" "#define HAVE_HIDDEN 1" >>confdefs.h
4284
4285
4286fi
4287
4288    # Step 0.d: Disable -rpath support?
4289
4290    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if rpath support is requested" >&5
4291printf %s "checking if rpath support is requested... " >&6; }
4292    # Check whether --enable-rpath was given.
4293if test ${enable_rpath+y}
4294then :
4295  enableval=$enable_rpath; doRpath=$enableval
4296else $as_nop
4297  doRpath=yes
4298fi
4299
4300    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $doRpath" >&5
4301printf "%s\n" "$doRpath" >&6; }
4302
4303    # Step 1: set the variable "system" to hold the name and version number
4304    # for the system.
4305
4306
4307    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking system version" >&5
4308printf %s "checking system version... " >&6; }
4309if test ${tcl_cv_sys_version+y}
4310then :
4311  printf %s "(cached) " >&6
4312else $as_nop
4313
4314	if test "${TEA_PLATFORM}" = "windows" ; then
4315	    tcl_cv_sys_version=windows
4316	else
4317	    tcl_cv_sys_version=`uname -s`-`uname -r`
4318	    if test "$?" -ne 0 ; then
4319		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: can't find uname command" >&5
4320printf "%s\n" "$as_me: WARNING: can't find uname command" >&2;}
4321		tcl_cv_sys_version=unknown
4322	    else
4323		if test "`uname -s`" = "AIX" ; then
4324		    tcl_cv_sys_version=AIX-`uname -v`.`uname -r`
4325		fi
4326		if test "`uname -s`" = "NetBSD" -a -f /etc/debian_version ; then
4327		    tcl_cv_sys_version=NetBSD-Debian
4328		fi
4329	    fi
4330	fi
4331
4332fi
4333{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_sys_version" >&5
4334printf "%s\n" "$tcl_cv_sys_version" >&6; }
4335    system=$tcl_cv_sys_version
4336
4337
4338    # Step 2: check for existence of -ldl library.  This is needed because
4339    # Linux can use either -ldl or -ldld for dynamic loading.
4340
4341    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
4342printf %s "checking for dlopen in -ldl... " >&6; }
4343if test ${ac_cv_lib_dl_dlopen+y}
4344then :
4345  printf %s "(cached) " >&6
4346else $as_nop
4347  ac_check_lib_save_LIBS=$LIBS
4348LIBS="-ldl  $LIBS"
4349cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4350/* end confdefs.h.  */
4351
4352/* Override any GCC internal prototype to avoid an error.
4353   Use char because int might match the return type of a GCC
4354   builtin and then its argument prototype would still apply.  */
4355char dlopen ();
4356int
4357main (void)
4358{
4359return dlopen ();
4360  ;
4361  return 0;
4362}
4363_ACEOF
4364if ac_fn_c_try_link "$LINENO"
4365then :
4366  ac_cv_lib_dl_dlopen=yes
4367else $as_nop
4368  ac_cv_lib_dl_dlopen=no
4369fi
4370rm -f core conftest.err conftest.$ac_objext conftest.beam \
4371    conftest$ac_exeext conftest.$ac_ext
4372LIBS=$ac_check_lib_save_LIBS
4373fi
4374{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
4375printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; }
4376if test "x$ac_cv_lib_dl_dlopen" = xyes
4377then :
4378  have_dl=yes
4379else $as_nop
4380  have_dl=no
4381fi
4382
4383
4384    # Require ranlib early so we can override it in special cases below.
4385
4386
4387
4388    # Step 3: set configuration options based on system name and version.
4389
4390    do64bit_ok=no
4391    # default to '{$LIBS}' and set to "" on per-platform necessary basis
4392    SHLIB_LD_LIBS='${LIBS}'
4393    LDFLAGS_ORIG="$LDFLAGS"
4394    # When ld needs options to work in 64-bit mode, put them in
4395    # LDFLAGS_ARCH so they eventually end up in LDFLAGS even if [load]
4396    # is disabled by the user. [Bug 1016796]
4397    LDFLAGS_ARCH=""
4398    UNSHARED_LIB_SUFFIX=""
4399    TCL_TRIM_DOTS='`echo ${VERSION} | tr -d .`'
4400    ECHO_VERSION='`echo ${VERSION}`'
4401    TCL_LIB_VERSIONS_OK=ok
4402    CFLAGS_DEBUG=-g
4403    if test "$GCC" = yes
4404then :
4405
4406	CFLAGS_OPTIMIZE=-O2
4407	CFLAGS_WARNING="-Wall -Wextra -Wshadow -Wundef -Wwrite-strings -Wpointer-arith"
4408	case "${CC}" in
4409	    *++|*++-*)
4410		;;
4411	    *)
4412		CFLAGS_WARNING="${CFLAGS_WARNING} -Wc++-compat -fextended-identifiers"
4413		;;
4414	esac
4415
4416
4417else $as_nop
4418
4419	CFLAGS_OPTIMIZE=-O
4420	CFLAGS_WARNING=""
4421
4422fi
4423    if test -n "$ac_tool_prefix"; then
4424  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
4425set dummy ${ac_tool_prefix}ar; ac_word=$2
4426{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4427printf %s "checking for $ac_word... " >&6; }
4428if test ${ac_cv_prog_AR+y}
4429then :
4430  printf %s "(cached) " >&6
4431else $as_nop
4432  if test -n "$AR"; then
4433  ac_cv_prog_AR="$AR" # Let the user override the test.
4434else
4435as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4436for as_dir in $PATH
4437do
4438  IFS=$as_save_IFS
4439  case $as_dir in #(((
4440    '') as_dir=./ ;;
4441    */) ;;
4442    *) as_dir=$as_dir/ ;;
4443  esac
4444    for ac_exec_ext in '' $ac_executable_extensions; do
4445  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4446    ac_cv_prog_AR="${ac_tool_prefix}ar"
4447    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4448    break 2
4449  fi
4450done
4451  done
4452IFS=$as_save_IFS
4453
4454fi
4455fi
4456AR=$ac_cv_prog_AR
4457if test -n "$AR"; then
4458  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
4459printf "%s\n" "$AR" >&6; }
4460else
4461  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4462printf "%s\n" "no" >&6; }
4463fi
4464
4465
4466fi
4467if test -z "$ac_cv_prog_AR"; then
4468  ac_ct_AR=$AR
4469  # Extract the first word of "ar", so it can be a program name with args.
4470set dummy ar; ac_word=$2
4471{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4472printf %s "checking for $ac_word... " >&6; }
4473if test ${ac_cv_prog_ac_ct_AR+y}
4474then :
4475  printf %s "(cached) " >&6
4476else $as_nop
4477  if test -n "$ac_ct_AR"; then
4478  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
4479else
4480as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4481for as_dir in $PATH
4482do
4483  IFS=$as_save_IFS
4484  case $as_dir in #(((
4485    '') as_dir=./ ;;
4486    */) ;;
4487    *) as_dir=$as_dir/ ;;
4488  esac
4489    for ac_exec_ext in '' $ac_executable_extensions; do
4490  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4491    ac_cv_prog_ac_ct_AR="ar"
4492    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4493    break 2
4494  fi
4495done
4496  done
4497IFS=$as_save_IFS
4498
4499fi
4500fi
4501ac_ct_AR=$ac_cv_prog_ac_ct_AR
4502if test -n "$ac_ct_AR"; then
4503  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
4504printf "%s\n" "$ac_ct_AR" >&6; }
4505else
4506  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4507printf "%s\n" "no" >&6; }
4508fi
4509
4510  if test "x$ac_ct_AR" = x; then
4511    AR=""
4512  else
4513    case $cross_compiling:$ac_tool_warned in
4514yes:)
4515{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4516printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4517ac_tool_warned=yes ;;
4518esac
4519    AR=$ac_ct_AR
4520  fi
4521else
4522  AR="$ac_cv_prog_AR"
4523fi
4524
4525    STLIB_LD='${AR} cr'
4526    LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH"
4527    PLAT_OBJS=""
4528    PLAT_SRCS=""
4529    LDAIX_SRC=""
4530    if test "x${SHLIB_VERSION}" = x
4531then :
4532  SHLIB_VERSION="1.0"
4533fi
4534    case $system in
4535	AIX-*)
4536	    if test "$GCC" != "yes"
4537then :
4538
4539		# AIX requires the _r compiler when gcc isn't being used
4540		case "${CC}" in
4541		    *_r|*_r\ *)
4542			# ok ...
4543			;;
4544		    *)
4545			# Make sure only first arg gets _r
4546		    	CC=`echo "$CC" | sed -e 's/^\([^ ]*\)/\1_r/'`
4547			;;
4548		esac
4549		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Using $CC for compiling with threads" >&5
4550printf "%s\n" "Using $CC for compiling with threads" >&6; }
4551
4552fi
4553	    LIBS="$LIBS -lc"
4554	    SHLIB_CFLAGS=""
4555	    SHLIB_SUFFIX=".so"
4556
4557	    DL_OBJS="tclLoadDl.o"
4558	    LD_LIBRARY_PATH_VAR="LIBPATH"
4559
4560	    # ldAix No longer needed with use of -bexpall/-brtl
4561	    # but some extensions may still reference it
4562	    LDAIX_SRC='$(UNIX_DIR)/ldAix'
4563
4564	    # Check to enable 64-bit flags for compiler/linker
4565	    if test "$do64bit" = yes
4566then :
4567
4568		if test "$GCC" = yes
4569then :
4570
4571		    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC on $system" >&5
4572printf "%s\n" "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
4573
4574else $as_nop
4575
4576		    do64bit_ok=yes
4577		    CFLAGS="$CFLAGS -q64"
4578		    LDFLAGS_ARCH="-q64"
4579		    RANLIB="${RANLIB} -X64"
4580		    AR="${AR} -X64"
4581		    SHLIB_LD_FLAGS="-b64"
4582
4583fi
4584
4585fi
4586
4587	    if test "`uname -m`" = ia64
4588then :
4589
4590		# AIX-5 uses ELF style dynamic libraries on IA-64, but not PPC
4591		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
4592		# AIX-5 has dl* in libc.so
4593		DL_LIBS=""
4594		if test "$GCC" = yes
4595then :
4596
4597		    CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
4598
4599else $as_nop
4600
4601		    CC_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
4602
4603fi
4604		LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
4605
4606else $as_nop
4607
4608		if test "$GCC" = yes
4609then :
4610
4611		    SHLIB_LD='${CC} -shared -Wl,-bexpall'
4612
4613else $as_nop
4614
4615		    SHLIB_LD="/bin/ld -bhalt:4 -bM:SRE -bexpall -H512 -T512 -bnoentry"
4616		    LDFLAGS="$LDFLAGS -brtl"
4617
4618fi
4619		SHLIB_LD="${SHLIB_LD} ${SHLIB_LD_FLAGS}"
4620		DL_LIBS="-ldl"
4621		CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
4622		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
4623
4624fi
4625	    ;;
4626	BeOS*)
4627	    SHLIB_CFLAGS="-fPIC"
4628	    SHLIB_LD='${CC} -nostart'
4629	    SHLIB_SUFFIX=".so"
4630	    DL_OBJS="tclLoadDl.o"
4631	    DL_LIBS="-ldl"
4632
4633	    #-----------------------------------------------------------
4634	    # Check for inet_ntoa in -lbind, for BeOS (which also needs
4635	    # -lsocket, even if the network functions are in -lnet which
4636	    # is always linked to, for compatibility.
4637	    #-----------------------------------------------------------
4638	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_ntoa in -lbind" >&5
4639printf %s "checking for inet_ntoa in -lbind... " >&6; }
4640if test ${ac_cv_lib_bind_inet_ntoa+y}
4641then :
4642  printf %s "(cached) " >&6
4643else $as_nop
4644  ac_check_lib_save_LIBS=$LIBS
4645LIBS="-lbind  $LIBS"
4646cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4647/* end confdefs.h.  */
4648
4649/* Override any GCC internal prototype to avoid an error.
4650   Use char because int might match the return type of a GCC
4651   builtin and then its argument prototype would still apply.  */
4652char inet_ntoa ();
4653int
4654main (void)
4655{
4656return inet_ntoa ();
4657  ;
4658  return 0;
4659}
4660_ACEOF
4661if ac_fn_c_try_link "$LINENO"
4662then :
4663  ac_cv_lib_bind_inet_ntoa=yes
4664else $as_nop
4665  ac_cv_lib_bind_inet_ntoa=no
4666fi
4667rm -f core conftest.err conftest.$ac_objext conftest.beam \
4668    conftest$ac_exeext conftest.$ac_ext
4669LIBS=$ac_check_lib_save_LIBS
4670fi
4671{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_inet_ntoa" >&5
4672printf "%s\n" "$ac_cv_lib_bind_inet_ntoa" >&6; }
4673if test "x$ac_cv_lib_bind_inet_ntoa" = xyes
4674then :
4675  LIBS="$LIBS -lbind -lsocket"
4676fi
4677
4678	    ;;
4679	BSD/OS-2.1*|BSD/OS-3*)
4680	    SHLIB_CFLAGS=""
4681	    SHLIB_LD="shlicc -r"
4682	    SHLIB_SUFFIX=".so"
4683	    DL_OBJS="tclLoadDl.o"
4684	    DL_LIBS="-ldl"
4685	    CC_SEARCH_FLAGS=""
4686	    LD_SEARCH_FLAGS=""
4687	    ;;
4688	BSD/OS-4.*)
4689	    SHLIB_CFLAGS="-export-dynamic -fPIC"
4690	    SHLIB_LD='${CC} -shared'
4691	    SHLIB_SUFFIX=".so"
4692	    DL_OBJS="tclLoadDl.o"
4693	    DL_LIBS="-ldl"
4694	    LDFLAGS="$LDFLAGS -export-dynamic"
4695	    CC_SEARCH_FLAGS=""
4696	    LD_SEARCH_FLAGS=""
4697	    ;;
4698	CYGWIN_*|MINGW32_*|MSYS_*)
4699	    SHLIB_CFLAGS="-fno-common"
4700	    SHLIB_LD='${CC} -shared'
4701	    SHLIB_SUFFIX=".dll"
4702	    DL_OBJS="tclLoadDl.o"
4703	    PLAT_OBJS='${CYGWIN_OBJS}'
4704	    PLAT_SRCS='${CYGWIN_SRCS}'
4705	    DL_LIBS="-ldl"
4706	    CC_SEARCH_FLAGS=""
4707	    LD_SEARCH_FLAGS=""
4708	    TCL_NEEDS_EXP_FILE=1
4709	    TCL_EXPORT_FILE_SUFFIX='${VERSION}.dll.a'
4710	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -Wl,--out-implib,\$@.a"
4711	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Cygwin version of gcc" >&5
4712printf %s "checking for Cygwin version of gcc... " >&6; }
4713if test ${ac_cv_cygwin+y}
4714then :
4715  printf %s "(cached) " >&6
4716else $as_nop
4717  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4718/* end confdefs.h.  */
4719
4720		#ifdef __CYGWIN__
4721		    #error cygwin
4722		#endif
4723
4724int
4725main (void)
4726{
4727
4728  ;
4729  return 0;
4730}
4731_ACEOF
4732if ac_fn_c_try_compile "$LINENO"
4733then :
4734  ac_cv_cygwin=no
4735else $as_nop
4736  ac_cv_cygwin=yes
4737fi
4738rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
4739
4740fi
4741{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cygwin" >&5
4742printf "%s\n" "$ac_cv_cygwin" >&6; }
4743	    if test "$ac_cv_cygwin" = "no"; then
4744		as_fn_error $? "${CC} is not a cygwin compiler." "$LINENO" 5
4745	    fi
4746	    do64bit_ok=yes
4747	    if test "x${SHARED_BUILD}" = "x1"; then
4748		echo "running cd ../win; ${CONFIG_SHELL-/bin/sh} ./configure $ac_configure_args"
4749		# The eval makes quoting arguments work.
4750		if cd ../win; eval ${CONFIG_SHELL-/bin/sh} ./configure $ac_configure_args; cd ../unix
4751		then :
4752		else
4753		    { echo "configure: error: configure failed for ../win" 1>&2; exit 1; }
4754		fi
4755	    fi
4756	    ;;
4757	dgux*)
4758	    SHLIB_CFLAGS="-K PIC"
4759	    SHLIB_LD='${CC} -G'
4760	    SHLIB_LD_LIBS=""
4761	    SHLIB_SUFFIX=".so"
4762	    DL_OBJS="tclLoadDl.o"
4763	    DL_LIBS="-ldl"
4764	    CC_SEARCH_FLAGS=""
4765	    LD_SEARCH_FLAGS=""
4766	    ;;
4767	Haiku*)
4768	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
4769	    SHLIB_CFLAGS="-fPIC"
4770	    SHLIB_SUFFIX=".so"
4771	    SHLIB_LD='${CC} ${CFLAGS} ${LDFLAGS} -shared'
4772	    DL_OBJS="tclLoadDl.o"
4773	    DL_LIBS="-lroot"
4774	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_ntoa in -lnetwork" >&5
4775printf %s "checking for inet_ntoa in -lnetwork... " >&6; }
4776if test ${ac_cv_lib_network_inet_ntoa+y}
4777then :
4778  printf %s "(cached) " >&6
4779else $as_nop
4780  ac_check_lib_save_LIBS=$LIBS
4781LIBS="-lnetwork  $LIBS"
4782cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4783/* end confdefs.h.  */
4784
4785/* Override any GCC internal prototype to avoid an error.
4786   Use char because int might match the return type of a GCC
4787   builtin and then its argument prototype would still apply.  */
4788char inet_ntoa ();
4789int
4790main (void)
4791{
4792return inet_ntoa ();
4793  ;
4794  return 0;
4795}
4796_ACEOF
4797if ac_fn_c_try_link "$LINENO"
4798then :
4799  ac_cv_lib_network_inet_ntoa=yes
4800else $as_nop
4801  ac_cv_lib_network_inet_ntoa=no
4802fi
4803rm -f core conftest.err conftest.$ac_objext conftest.beam \
4804    conftest$ac_exeext conftest.$ac_ext
4805LIBS=$ac_check_lib_save_LIBS
4806fi
4807{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_inet_ntoa" >&5
4808printf "%s\n" "$ac_cv_lib_network_inet_ntoa" >&6; }
4809if test "x$ac_cv_lib_network_inet_ntoa" = xyes
4810then :
4811  LIBS="$LIBS -lnetwork"
4812fi
4813
4814	    ;;
4815	HP-UX-*.11.*)
4816	    # Use updated header definitions where possible
4817
4818printf "%s\n" "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h
4819
4820
4821printf "%s\n" "#define _XOPEN_SOURCE 1" >>confdefs.h
4822
4823	    LIBS="$LIBS -lxnet"               # Use the XOPEN network library
4824
4825	    if test "`uname -m`" = ia64
4826then :
4827
4828		SHLIB_SUFFIX=".so"
4829
4830else $as_nop
4831
4832		SHLIB_SUFFIX=".sl"
4833
4834fi
4835	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
4836printf %s "checking for shl_load in -ldld... " >&6; }
4837if test ${ac_cv_lib_dld_shl_load+y}
4838then :
4839  printf %s "(cached) " >&6
4840else $as_nop
4841  ac_check_lib_save_LIBS=$LIBS
4842LIBS="-ldld  $LIBS"
4843cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4844/* end confdefs.h.  */
4845
4846/* Override any GCC internal prototype to avoid an error.
4847   Use char because int might match the return type of a GCC
4848   builtin and then its argument prototype would still apply.  */
4849char shl_load ();
4850int
4851main (void)
4852{
4853return shl_load ();
4854  ;
4855  return 0;
4856}
4857_ACEOF
4858if ac_fn_c_try_link "$LINENO"
4859then :
4860  ac_cv_lib_dld_shl_load=yes
4861else $as_nop
4862  ac_cv_lib_dld_shl_load=no
4863fi
4864rm -f core conftest.err conftest.$ac_objext conftest.beam \
4865    conftest$ac_exeext conftest.$ac_ext
4866LIBS=$ac_check_lib_save_LIBS
4867fi
4868{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
4869printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; }
4870if test "x$ac_cv_lib_dld_shl_load" = xyes
4871then :
4872  tcl_ok=yes
4873else $as_nop
4874  tcl_ok=no
4875fi
4876
4877	    if test "$tcl_ok" = yes
4878then :
4879
4880		SHLIB_CFLAGS="+z"
4881		SHLIB_LD="ld -b"
4882		DL_OBJS="tclLoadShl.o"
4883		DL_LIBS="-ldld"
4884		LDFLAGS="$LDFLAGS -Wl,-E"
4885		CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
4886		LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
4887		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
4888
4889fi
4890	    if test "$GCC" = yes
4891then :
4892
4893		SHLIB_LD='${CC} -shared'
4894		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
4895
4896else $as_nop
4897
4898		CFLAGS="$CFLAGS -z"
4899
4900fi
4901
4902	    # Users may want PA-RISC 1.1/2.0 portable code - needs HP cc
4903	    #CFLAGS="$CFLAGS +DAportable"
4904
4905	    # Check to enable 64-bit flags for compiler/linker
4906	    if test "$do64bit" = "yes"
4907then :
4908
4909		if test "$GCC" = yes
4910then :
4911
4912		    case `${CC} -dumpmachine` in
4913			hppa64*)
4914			    # 64-bit gcc in use.  Fix flags for GNU ld.
4915			    do64bit_ok=yes
4916			    SHLIB_LD='${CC} -shared'
4917			    if test $doRpath = yes
4918then :
4919
4920				CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
4921fi
4922			    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
4923			    ;;
4924			*)
4925			    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC on $system" >&5
4926printf "%s\n" "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
4927			    ;;
4928		    esac
4929
4930else $as_nop
4931
4932		    do64bit_ok=yes
4933		    CFLAGS="$CFLAGS +DD64"
4934		    LDFLAGS_ARCH="+DD64"
4935
4936fi
4937
4938fi ;;
4939	HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*)
4940	    SHLIB_SUFFIX=".sl"
4941	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
4942printf %s "checking for shl_load in -ldld... " >&6; }
4943if test ${ac_cv_lib_dld_shl_load+y}
4944then :
4945  printf %s "(cached) " >&6
4946else $as_nop
4947  ac_check_lib_save_LIBS=$LIBS
4948LIBS="-ldld  $LIBS"
4949cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4950/* end confdefs.h.  */
4951
4952/* Override any GCC internal prototype to avoid an error.
4953   Use char because int might match the return type of a GCC
4954   builtin and then its argument prototype would still apply.  */
4955char shl_load ();
4956int
4957main (void)
4958{
4959return shl_load ();
4960  ;
4961  return 0;
4962}
4963_ACEOF
4964if ac_fn_c_try_link "$LINENO"
4965then :
4966  ac_cv_lib_dld_shl_load=yes
4967else $as_nop
4968  ac_cv_lib_dld_shl_load=no
4969fi
4970rm -f core conftest.err conftest.$ac_objext conftest.beam \
4971    conftest$ac_exeext conftest.$ac_ext
4972LIBS=$ac_check_lib_save_LIBS
4973fi
4974{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
4975printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; }
4976if test "x$ac_cv_lib_dld_shl_load" = xyes
4977then :
4978  tcl_ok=yes
4979else $as_nop
4980  tcl_ok=no
4981fi
4982
4983	    if test "$tcl_ok" = yes
4984then :
4985
4986		SHLIB_CFLAGS="+z"
4987		SHLIB_LD="ld -b"
4988		SHLIB_LD_LIBS=""
4989		DL_OBJS="tclLoadShl.o"
4990		DL_LIBS="-ldld"
4991		LDFLAGS="$LDFLAGS -Wl,-E"
4992		CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
4993		LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
4994		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
4995
4996fi ;;
4997	IRIX-5.*)
4998	    SHLIB_CFLAGS=""
4999	    SHLIB_LD="ld -shared -rdata_shared"
5000	    SHLIB_SUFFIX=".so"
5001	    DL_OBJS="tclLoadDl.o"
5002	    DL_LIBS=""
5003	    case " $LIBOBJS " in
5004  *" mkstemp.$ac_objext "* ) ;;
5005  *) LIBOBJS="$LIBOBJS mkstemp.$ac_objext"
5006 ;;
5007esac
5008
5009	    if test $doRpath = yes
5010then :
5011
5012		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5013		LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
5014fi
5015	    ;;
5016	IRIX-6.*)
5017	    SHLIB_CFLAGS=""
5018	    SHLIB_LD="ld -n32 -shared -rdata_shared"
5019	    SHLIB_SUFFIX=".so"
5020	    DL_OBJS="tclLoadDl.o"
5021	    DL_LIBS=""
5022	    case " $LIBOBJS " in
5023  *" mkstemp.$ac_objext "* ) ;;
5024  *) LIBOBJS="$LIBOBJS mkstemp.$ac_objext"
5025 ;;
5026esac
5027
5028	    if test $doRpath = yes
5029then :
5030
5031		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5032		LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
5033fi
5034	    if test "$GCC" = yes
5035then :
5036
5037		CFLAGS="$CFLAGS -mabi=n32"
5038		LDFLAGS="$LDFLAGS -mabi=n32"
5039
5040else $as_nop
5041
5042		case $system in
5043		    IRIX-6.3)
5044			# Use to build 6.2 compatible binaries on 6.3.
5045			CFLAGS="$CFLAGS -n32 -D_OLD_TERMIOS"
5046			;;
5047		    *)
5048			CFLAGS="$CFLAGS -n32"
5049			;;
5050		esac
5051		LDFLAGS="$LDFLAGS -n32"
5052
5053fi
5054	    ;;
5055	IRIX64-6.*)
5056	    SHLIB_CFLAGS=""
5057	    SHLIB_LD="ld -n32 -shared -rdata_shared"
5058	    SHLIB_SUFFIX=".so"
5059	    DL_OBJS="tclLoadDl.o"
5060	    DL_LIBS=""
5061	    case " $LIBOBJS " in
5062  *" mkstemp.$ac_objext "* ) ;;
5063  *) LIBOBJS="$LIBOBJS mkstemp.$ac_objext"
5064 ;;
5065esac
5066
5067	    if test $doRpath = yes
5068then :
5069
5070		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5071		LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
5072fi
5073
5074	    # Check to enable 64-bit flags for compiler/linker
5075
5076	    if test "$do64bit" = yes
5077then :
5078
5079	        if test "$GCC" = yes
5080then :
5081
5082	            { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported by gcc" >&5
5083printf "%s\n" "$as_me: WARNING: 64bit mode not supported by gcc" >&2;}
5084
5085else $as_nop
5086
5087	            do64bit_ok=yes
5088	            SHLIB_LD="ld -64 -shared -rdata_shared"
5089	            CFLAGS="$CFLAGS -64"
5090	            LDFLAGS_ARCH="-64"
5091
5092fi
5093
5094fi
5095	    ;;
5096	Linux*|GNU*|NetBSD-Debian)
5097	    SHLIB_CFLAGS="-fPIC -fno-common"
5098	    SHLIB_SUFFIX=".so"
5099
5100	    CFLAGS_OPTIMIZE="-O2"
5101	    # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings
5102	    # when you inline the string and math operations.  Turn this off to
5103	    # get rid of the warnings.
5104	    #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
5105
5106	    SHLIB_LD='${CC} ${CFLAGS} ${LDFLAGS} -shared'
5107	    DL_OBJS="tclLoadDl.o"
5108	    DL_LIBS="-ldl"
5109	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
5110	    if test $doRpath = yes
5111then :
5112
5113		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5114fi
5115	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
5116	    if test "`uname -m`" = "alpha"
5117then :
5118  CFLAGS="$CFLAGS -mieee"
5119fi
5120	    if test $do64bit = yes
5121then :
5122
5123		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -m64 flag" >&5
5124printf %s "checking if compiler accepts -m64 flag... " >&6; }
5125if test ${tcl_cv_cc_m64+y}
5126then :
5127  printf %s "(cached) " >&6
5128else $as_nop
5129
5130		    hold_cflags=$CFLAGS
5131		    CFLAGS="$CFLAGS -m64"
5132		    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5133/* end confdefs.h.  */
5134
5135int
5136main (void)
5137{
5138
5139  ;
5140  return 0;
5141}
5142_ACEOF
5143if ac_fn_c_try_link "$LINENO"
5144then :
5145  tcl_cv_cc_m64=yes
5146else $as_nop
5147  tcl_cv_cc_m64=no
5148fi
5149rm -f core conftest.err conftest.$ac_objext conftest.beam \
5150    conftest$ac_exeext conftest.$ac_ext
5151		    CFLAGS=$hold_cflags
5152fi
5153{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_m64" >&5
5154printf "%s\n" "$tcl_cv_cc_m64" >&6; }
5155		if test $tcl_cv_cc_m64 = yes
5156then :
5157
5158		    CFLAGS="$CFLAGS -m64"
5159		    do64bit_ok=yes
5160
5161fi
5162
5163fi
5164
5165	    # The combo of gcc + glibc has a bug related to inlining of
5166	    # functions like strtol()/strtoul(). The -fno-builtin flag should address
5167	    # this problem but it does not work. The -fno-inline flag is kind
5168	    # of overkill but it works. Disable inlining only when one of the
5169	    # files in compat/*.c is being linked in.
5170
5171	    if test x"${USE_COMPAT}" != x
5172then :
5173  CFLAGS="$CFLAGS -fno-inline"
5174fi
5175	    ;;
5176	Lynx*)
5177	    SHLIB_CFLAGS="-fPIC"
5178	    SHLIB_SUFFIX=".so"
5179	    CFLAGS_OPTIMIZE=-02
5180	    SHLIB_LD='${CC} -shared'
5181	    DL_OBJS="tclLoadDl.o"
5182	    DL_LIBS="-mshared -ldl"
5183	    LD_FLAGS="-Wl,--export-dynamic"
5184	    if test $doRpath = yes
5185then :
5186
5187		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5188		LD_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5189fi
5190	    ;;
5191	OpenBSD-*)
5192	    arch=`arch -s`
5193	    case "$arch" in
5194	    alpha|sparc64)
5195		SHLIB_CFLAGS="-fPIC"
5196		;;
5197	    *)
5198		SHLIB_CFLAGS="-fpic"
5199		;;
5200	    esac
5201	    SHLIB_LD='${CC} ${SHLIB_CFLAGS} -shared'
5202	    SHLIB_SUFFIX=".so"
5203	    DL_OBJS="tclLoadDl.o"
5204	    DL_LIBS=""
5205	    if test $doRpath = yes
5206then :
5207
5208		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5209fi
5210	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
5211	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.${SHLIB_VERSION}'
5212	    LDFLAGS="-Wl,-export-dynamic"
5213	    CFLAGS_OPTIMIZE="-O2"
5214	    # On OpenBSD:	Compile with -pthread
5215	    #		Don't link with -lpthread
5216	    LIBS=`echo $LIBS | sed s/-lpthread//`
5217	    CFLAGS="$CFLAGS -pthread"
5218	    # OpenBSD doesn't do version numbers with dots.
5219	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
5220	    TCL_LIB_VERSIONS_OK=nodots
5221	    ;;
5222	NetBSD-*)
5223	    # NetBSD has ELF and can use 'cc -shared' to build shared libs
5224	    SHLIB_CFLAGS="-fPIC"
5225	    SHLIB_LD='${CC} ${SHLIB_CFLAGS} -shared'
5226	    SHLIB_SUFFIX=".so"
5227	    DL_OBJS="tclLoadDl.o"
5228	    DL_LIBS=""
5229	    LDFLAGS="$LDFLAGS -export-dynamic"
5230	    if test $doRpath = yes
5231then :
5232
5233		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5234fi
5235	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
5236	    # The -pthread needs to go in the CFLAGS, not LIBS
5237	    LIBS=`echo $LIBS | sed s/-pthread//`
5238	    CFLAGS="$CFLAGS -pthread"
5239	    LDFLAGS="$LDFLAGS -pthread"
5240	    ;;
5241	DragonFly-*|FreeBSD-*)
5242	    # This configuration from FreeBSD Ports.
5243	    SHLIB_LD="${CC} -shared"
5244	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -Wl,-soname,\$@"
5245	    SHLIB_SUFFIX=".so"
5246	    DL_OBJS="tclLoadDl.o"
5247	    DL_LIBS=""
5248	    if test $doRpath = yes
5249then :
5250
5251		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5252		LD_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5253fi
5254	    # The -pthread needs to go in the LDFLAGS, not LIBS
5255	    LIBS=`echo $LIBS | sed s/-pthread//`
5256	    CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
5257	    LDFLAGS="$LDFLAGS $PTHREAD_LIBS"
5258	    case $system in
5259	    FreeBSD-3.*)
5260		# Version numbers are dot-stripped by system policy.
5261		TCL_TRIM_DOTS=`echo ${VERSION} | tr -d .`
5262		UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
5263		SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so'
5264		TCL_LIB_VERSIONS_OK=nodots
5265		;;
5266	    esac
5267	    ;;
5268	Darwin-*)
5269	    CFLAGS_OPTIMIZE="-Os"
5270	    SHLIB_CFLAGS="-fno-common"
5271	    # To avoid discrepancies between what headers configure sees during
5272	    # preprocessing tests and compiling tests, move any -isysroot and
5273	    # -mmacosx-version-min flags from CFLAGS to CPPFLAGS:
5274	    CPPFLAGS="${CPPFLAGS} `echo " ${CFLAGS}" | \
5275		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
5276		if ($i~/^(isysroot|mmacosx-version-min)/) print "-"$i}'`"
5277	    CFLAGS="`echo " ${CFLAGS}" | \
5278		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
5279		if (!($i~/^(isysroot|mmacosx-version-min)/)) print "-"$i}'`"
5280	    if test $do64bit = yes
5281then :
5282
5283		case `arch` in
5284		    ppc)
5285			{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -arch ppc64 flag" >&5
5286printf %s "checking if compiler accepts -arch ppc64 flag... " >&6; }
5287if test ${tcl_cv_cc_arch_ppc64+y}
5288then :
5289  printf %s "(cached) " >&6
5290else $as_nop
5291
5292			    hold_cflags=$CFLAGS
5293			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
5294			    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5295/* end confdefs.h.  */
5296
5297int
5298main (void)
5299{
5300
5301  ;
5302  return 0;
5303}
5304_ACEOF
5305if ac_fn_c_try_link "$LINENO"
5306then :
5307  tcl_cv_cc_arch_ppc64=yes
5308else $as_nop
5309  tcl_cv_cc_arch_ppc64=no
5310fi
5311rm -f core conftest.err conftest.$ac_objext conftest.beam \
5312    conftest$ac_exeext conftest.$ac_ext
5313			    CFLAGS=$hold_cflags
5314fi
5315{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_arch_ppc64" >&5
5316printf "%s\n" "$tcl_cv_cc_arch_ppc64" >&6; }
5317			if test $tcl_cv_cc_arch_ppc64 = yes
5318then :
5319
5320			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
5321			    do64bit_ok=yes
5322
5323fi;;
5324		    i386)
5325			{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -arch x86_64 flag" >&5
5326printf %s "checking if compiler accepts -arch x86_64 flag... " >&6; }
5327if test ${tcl_cv_cc_arch_x86_64+y}
5328then :
5329  printf %s "(cached) " >&6
5330else $as_nop
5331
5332			    hold_cflags=$CFLAGS
5333			    CFLAGS="$CFLAGS -arch x86_64"
5334			    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5335/* end confdefs.h.  */
5336
5337int
5338main (void)
5339{
5340
5341  ;
5342  return 0;
5343}
5344_ACEOF
5345if ac_fn_c_try_link "$LINENO"
5346then :
5347  tcl_cv_cc_arch_x86_64=yes
5348else $as_nop
5349  tcl_cv_cc_arch_x86_64=no
5350fi
5351rm -f core conftest.err conftest.$ac_objext conftest.beam \
5352    conftest$ac_exeext conftest.$ac_ext
5353			    CFLAGS=$hold_cflags
5354fi
5355{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_arch_x86_64" >&5
5356printf "%s\n" "$tcl_cv_cc_arch_x86_64" >&6; }
5357			if test $tcl_cv_cc_arch_x86_64 = yes
5358then :
5359
5360			    CFLAGS="$CFLAGS -arch x86_64"
5361			    do64bit_ok=yes
5362
5363fi;;
5364		    *)
5365			{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&5
5366printf "%s\n" "$as_me: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&2;};;
5367		esac
5368
5369else $as_nop
5370
5371		# Check for combined 32-bit and 64-bit fat build
5372		if echo "$CFLAGS " |grep -E -q -- '-arch (ppc64|x86_64) ' \
5373		    && echo "$CFLAGS " |grep -E -q -- '-arch (ppc|i386) '
5374then :
5375
5376		    fat_32_64=yes
5377fi
5378
5379fi
5380	    SHLIB_LD='${CC} -dynamiclib ${CFLAGS} ${LDFLAGS}'
5381	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if ld accepts -single_module flag" >&5
5382printf %s "checking if ld accepts -single_module flag... " >&6; }
5383if test ${tcl_cv_ld_single_module+y}
5384then :
5385  printf %s "(cached) " >&6
5386else $as_nop
5387
5388		hold_ldflags=$LDFLAGS
5389		LDFLAGS="$LDFLAGS -dynamiclib -Wl,-single_module"
5390		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5391/* end confdefs.h.  */
5392
5393int
5394main (void)
5395{
5396int i;
5397  ;
5398  return 0;
5399}
5400_ACEOF
5401if ac_fn_c_try_link "$LINENO"
5402then :
5403  tcl_cv_ld_single_module=yes
5404else $as_nop
5405  tcl_cv_ld_single_module=no
5406fi
5407rm -f core conftest.err conftest.$ac_objext conftest.beam \
5408    conftest$ac_exeext conftest.$ac_ext
5409		LDFLAGS=$hold_ldflags
5410fi
5411{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_single_module" >&5
5412printf "%s\n" "$tcl_cv_ld_single_module" >&6; }
5413	    if test $tcl_cv_ld_single_module = yes
5414then :
5415
5416		SHLIB_LD="${SHLIB_LD} -Wl,-single_module"
5417
5418fi
5419	    SHLIB_SUFFIX=".dylib"
5420	    DL_OBJS="tclLoadDyld.o"
5421	    DL_LIBS=""
5422	    LDFLAGS="$LDFLAGS -headerpad_max_install_names"
5423	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if ld accepts -search_paths_first flag" >&5
5424printf %s "checking if ld accepts -search_paths_first flag... " >&6; }
5425if test ${tcl_cv_ld_search_paths_first+y}
5426then :
5427  printf %s "(cached) " >&6
5428else $as_nop
5429
5430		hold_ldflags=$LDFLAGS
5431		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
5432		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5433/* end confdefs.h.  */
5434
5435int
5436main (void)
5437{
5438int i;
5439  ;
5440  return 0;
5441}
5442_ACEOF
5443if ac_fn_c_try_link "$LINENO"
5444then :
5445  tcl_cv_ld_search_paths_first=yes
5446else $as_nop
5447  tcl_cv_ld_search_paths_first=no
5448fi
5449rm -f core conftest.err conftest.$ac_objext conftest.beam \
5450    conftest$ac_exeext conftest.$ac_ext
5451		LDFLAGS=$hold_ldflags
5452fi
5453{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_search_paths_first" >&5
5454printf "%s\n" "$tcl_cv_ld_search_paths_first" >&6; }
5455	    if test $tcl_cv_ld_search_paths_first = yes
5456then :
5457
5458		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
5459
5460fi
5461	    if test "$tcl_cv_cc_visibility_hidden" != yes
5462then :
5463
5464
5465printf "%s\n" "#define MODULE_SCOPE __private_extern__" >>confdefs.h
5466
5467		tcl_cv_cc_visibility_hidden=yes
5468
5469fi
5470	    CC_SEARCH_FLAGS=""
5471	    LD_SEARCH_FLAGS=""
5472	    LD_LIBRARY_PATH_VAR="DYLD_LIBRARY_PATH"
5473
5474printf "%s\n" "#define MAC_OSX_TCL 1" >>confdefs.h
5475
5476	    PLAT_OBJS='${MAC_OSX_OBJS}'
5477	    PLAT_SRCS='${MAC_OSX_SRCS}'
5478	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to use CoreFoundation" >&5
5479printf %s "checking whether to use CoreFoundation... " >&6; }
5480	    # Check whether --enable-corefoundation was given.
5481if test ${enable_corefoundation+y}
5482then :
5483  enableval=$enable_corefoundation; tcl_corefoundation=$enableval
5484else $as_nop
5485  tcl_corefoundation=yes
5486fi
5487
5488	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_corefoundation" >&5
5489printf "%s\n" "$tcl_corefoundation" >&6; }
5490	    if test $tcl_corefoundation = yes
5491then :
5492
5493		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CoreFoundation.framework" >&5
5494printf %s "checking for CoreFoundation.framework... " >&6; }
5495if test ${tcl_cv_lib_corefoundation+y}
5496then :
5497  printf %s "(cached) " >&6
5498else $as_nop
5499
5500		    hold_libs=$LIBS
5501		    if test "$fat_32_64" = yes
5502then :
5503
5504			for v in CFLAGS CPPFLAGS LDFLAGS; do
5505			    # On Tiger there is no 64-bit CF, so remove 64-bit
5506			    # archs from CFLAGS et al. while testing for
5507			    # presence of CF. 64-bit CF is disabled in
5508			    # tclUnixPort.h if necessary.
5509			    eval 'hold_'$v'="$'$v'";'$v'="`echo "$'$v' "|sed -e "s/-arch ppc64 / /g" -e "s/-arch x86_64 / /g"`"'
5510			done
5511fi
5512		    LIBS="$LIBS -framework CoreFoundation"
5513		    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5514/* end confdefs.h.  */
5515#include <CoreFoundation/CoreFoundation.h>
5516int
5517main (void)
5518{
5519CFBundleRef b = CFBundleGetMainBundle();
5520  ;
5521  return 0;
5522}
5523_ACEOF
5524if ac_fn_c_try_link "$LINENO"
5525then :
5526  tcl_cv_lib_corefoundation=yes
5527else $as_nop
5528  tcl_cv_lib_corefoundation=no
5529fi
5530rm -f core conftest.err conftest.$ac_objext conftest.beam \
5531    conftest$ac_exeext conftest.$ac_ext
5532		    if test "$fat_32_64" = yes
5533then :
5534
5535			for v in CFLAGS CPPFLAGS LDFLAGS; do
5536			    eval $v'="$hold_'$v'"'
5537		        done
5538fi
5539		    LIBS=$hold_libs
5540fi
5541{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_lib_corefoundation" >&5
5542printf "%s\n" "$tcl_cv_lib_corefoundation" >&6; }
5543		if test $tcl_cv_lib_corefoundation = yes
5544then :
5545
5546		    LIBS="$LIBS -framework CoreFoundation"
5547
5548printf "%s\n" "#define HAVE_COREFOUNDATION 1" >>confdefs.h
5549
5550
5551else $as_nop
5552  tcl_corefoundation=no
5553fi
5554		if test "$fat_32_64" = yes -a $tcl_corefoundation = yes
5555then :
5556
5557		    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 64-bit CoreFoundation" >&5
5558printf %s "checking for 64-bit CoreFoundation... " >&6; }
5559if test ${tcl_cv_lib_corefoundation_64+y}
5560then :
5561  printf %s "(cached) " >&6
5562else $as_nop
5563
5564			for v in CFLAGS CPPFLAGS LDFLAGS; do
5565			    eval 'hold_'$v'="$'$v'";'$v'="`echo "$'$v' "|sed -e "s/-arch ppc / /g" -e "s/-arch i386 / /g"`"'
5566			done
5567			cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5568/* end confdefs.h.  */
5569#include <CoreFoundation/CoreFoundation.h>
5570int
5571main (void)
5572{
5573CFBundleRef b = CFBundleGetMainBundle();
5574  ;
5575  return 0;
5576}
5577_ACEOF
5578if ac_fn_c_try_link "$LINENO"
5579then :
5580  tcl_cv_lib_corefoundation_64=yes
5581else $as_nop
5582  tcl_cv_lib_corefoundation_64=no
5583fi
5584rm -f core conftest.err conftest.$ac_objext conftest.beam \
5585    conftest$ac_exeext conftest.$ac_ext
5586			for v in CFLAGS CPPFLAGS LDFLAGS; do
5587			    eval $v'="$hold_'$v'"'
5588			done
5589fi
5590{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_lib_corefoundation_64" >&5
5591printf "%s\n" "$tcl_cv_lib_corefoundation_64" >&6; }
5592		    if test $tcl_cv_lib_corefoundation_64 = no
5593then :
5594
5595
5596printf "%s\n" "#define NO_COREFOUNDATION_64 1" >>confdefs.h
5597
5598                        LDFLAGS="$LDFLAGS -Wl,-no_arch_warnings"
5599
5600fi
5601
5602fi
5603
5604fi
5605	    ;;
5606	OS/390-*)
5607	    SHLIB_LD_LIBS=""
5608	    CFLAGS_OPTIMIZE=""		# Optimizer is buggy
5609
5610printf "%s\n" "#define _OE_SOCKETS 1" >>confdefs.h
5611
5612	    ;;
5613	OSF1-V*)
5614	    # Digital OSF/1
5615	    SHLIB_CFLAGS=""
5616	    if test "$SHARED_BUILD" = 1
5617then :
5618
5619	        SHLIB_LD='ld -shared -expect_unresolved "*"'
5620
5621else $as_nop
5622
5623	        SHLIB_LD='ld -non_shared -expect_unresolved "*"'
5624
5625fi
5626	    SHLIB_SUFFIX=".so"
5627	    DL_OBJS="tclLoadDl.o"
5628	    DL_LIBS=""
5629	    if test $doRpath = yes
5630then :
5631
5632		CC_SEARCH_FLAGS='"-Wl,-rpath,${LIB_RUNTIME_DIR}"'
5633		LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
5634fi
5635	    if test "$GCC" = yes
5636then :
5637  CFLAGS="$CFLAGS -mieee"
5638else $as_nop
5639
5640		CFLAGS="$CFLAGS -DHAVE_TZSET -std1 -ieee"
5641fi
5642	    # see pthread_intro(3) for pthread support on osf1, k.furukawa
5643	    CFLAGS="$CFLAGS -DHAVE_PTHREAD_ATTR_SETSTACKSIZE"
5644	    CFLAGS="$CFLAGS -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
5645	    LIBS=`echo $LIBS | sed s/-lpthreads//`
5646	    if test "$GCC" = yes
5647then :
5648
5649		LIBS="$LIBS -lpthread -lmach -lexc"
5650
5651else $as_nop
5652
5653		CFLAGS="$CFLAGS -pthread"
5654		LDFLAGS="$LDFLAGS -pthread"
5655
5656fi
5657	    ;;
5658	QNX-6*)
5659	    # QNX RTP
5660	    # This may work for all QNX, but it was only reported for v6.
5661	    SHLIB_LD="ld -Bshareable -x"
5662	    SHLIB_LD_LIBS=""
5663	    SHLIB_SUFFIX=".so"
5664	    DL_OBJS="tclLoadDl.o"
5665	    # dlopen is in -lc on QNX
5666	    DL_LIBS=""
5667	    CC_SEARCH_FLAGS=""
5668	    LD_SEARCH_FLAGS=""
5669	    ;;
5670	SCO_SV-3.2*)
5671	    # Note, dlopen is available only on SCO 3.2.5 and greater. However,
5672	    # this test works, since "uname -s" was non-standard in 3.2.4 and
5673	    # below.
5674	    if test "$GCC" = yes
5675then :
5676
5677		SHLIB_CFLAGS="-fPIC -melf"
5678		LDFLAGS="$LDFLAGS -melf -Wl,-Bexport"
5679
5680else $as_nop
5681
5682		SHLIB_CFLAGS="-Kpic -belf"
5683		LDFLAGS="$LDFLAGS -belf -Wl,-Bexport"
5684
5685fi
5686	    SHLIB_LD="ld -G"
5687	    SHLIB_LD_LIBS=""
5688	    SHLIB_SUFFIX=".so"
5689	    DL_OBJS="tclLoadDl.o"
5690	    DL_LIBS=""
5691	    CC_SEARCH_FLAGS=""
5692	    LD_SEARCH_FLAGS=""
5693	    ;;
5694	SunOS-5.[0-6])
5695	    # Careful to not let 5.10+ fall into this case
5696
5697	    # Note: If _REENTRANT isn't defined, then Solaris
5698	    # won't define thread-safe library routines.
5699
5700
5701printf "%s\n" "#define _REENTRANT 1" >>confdefs.h
5702
5703
5704printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5705
5706
5707	    SHLIB_CFLAGS="-KPIC"
5708	    SHLIB_SUFFIX=".so"
5709	    DL_OBJS="tclLoadDl.o"
5710	    DL_LIBS="-ldl"
5711	    if test "$GCC" = yes
5712then :
5713
5714		SHLIB_LD='${CC} -shared'
5715		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
5716		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
5717
5718else $as_nop
5719
5720		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
5721		CC_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
5722		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
5723
5724fi
5725	    ;;
5726	SunOS-5*)
5727	    # Note: If _REENTRANT isn't defined, then Solaris
5728	    # won't define thread-safe library routines.
5729
5730
5731printf "%s\n" "#define _REENTRANT 1" >>confdefs.h
5732
5733
5734printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5735
5736
5737	    SHLIB_CFLAGS="-KPIC"
5738
5739	    # Check to enable 64-bit flags for compiler/linker
5740	    if test "$do64bit" = yes
5741then :
5742
5743		arch=`isainfo`
5744		if test "$arch" = "sparcv9 sparc"
5745then :
5746
5747		    if test "$GCC" = yes
5748then :
5749
5750			if test "`${CC} -dumpversion | awk -F. '{print $1}'`" -lt 3
5751then :
5752
5753			    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&5
5754printf "%s\n" "$as_me: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&2;}
5755
5756else $as_nop
5757
5758			    do64bit_ok=yes
5759			    CFLAGS="$CFLAGS -m64 -mcpu=v9"
5760			    LDFLAGS="$LDFLAGS -m64 -mcpu=v9"
5761			    SHLIB_CFLAGS="-fPIC"
5762
5763fi
5764
5765else $as_nop
5766
5767			do64bit_ok=yes
5768			if test "$do64bitVIS" = yes
5769then :
5770
5771			    CFLAGS="$CFLAGS -xarch=v9a"
5772			    LDFLAGS_ARCH="-xarch=v9a"
5773
5774else $as_nop
5775
5776			    CFLAGS="$CFLAGS -xarch=v9"
5777			    LDFLAGS_ARCH="-xarch=v9"
5778
5779fi
5780			# Solaris 64 uses this as well
5781			#LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH_64"
5782
5783fi
5784
5785else $as_nop
5786  if test "$arch" = "amd64 i386"
5787then :
5788
5789		    if test "$GCC" = yes
5790then :
5791
5792			case $system in
5793			    SunOS-5.1[1-9]*|SunOS-5.[2-9][0-9]*)
5794				do64bit_ok=yes
5795				CFLAGS="$CFLAGS -m64"
5796				LDFLAGS="$LDFLAGS -m64";;
5797			    *)
5798				{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC on $system" >&5
5799printf "%s\n" "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;};;
5800			esac
5801
5802else $as_nop
5803
5804			do64bit_ok=yes
5805			case $system in
5806			    SunOS-5.1[1-9]*|SunOS-5.[2-9][0-9]*)
5807				CFLAGS="$CFLAGS -m64"
5808				LDFLAGS="$LDFLAGS -m64";;
5809			    *)
5810				CFLAGS="$CFLAGS -xarch=amd64"
5811				LDFLAGS="$LDFLAGS -xarch=amd64";;
5812			esac
5813
5814fi
5815
5816else $as_nop
5817  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported for $arch" >&5
5818printf "%s\n" "$as_me: WARNING: 64bit mode not supported for $arch" >&2;}
5819fi
5820fi
5821
5822fi
5823
5824	    #--------------------------------------------------------------------
5825	    # On Solaris 5.x i386 with the sunpro compiler we need to link
5826	    # with sunmath to get floating point rounding control
5827	    #--------------------------------------------------------------------
5828	    if test "$GCC" = yes
5829then :
5830  use_sunmath=no
5831else $as_nop
5832
5833		arch=`isainfo`
5834		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to use -lsunmath for fp rounding control" >&5
5835printf %s "checking whether to use -lsunmath for fp rounding control... " >&6; }
5836		if test "$arch" = "amd64 i386" -o "$arch" = "i386"
5837then :
5838
5839			{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5840printf "%s\n" "yes" >&6; }
5841			MATH_LIBS="-lsunmath $MATH_LIBS"
5842			ac_fn_c_check_header_compile "$LINENO" "sunmath.h" "ac_cv_header_sunmath_h" "$ac_includes_default"
5843if test "x$ac_cv_header_sunmath_h" = xyes
5844then :
5845
5846fi
5847
5848			use_sunmath=yes
5849
5850else $as_nop
5851
5852			{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5853printf "%s\n" "no" >&6; }
5854			use_sunmath=no
5855
5856fi
5857
5858fi
5859	    SHLIB_SUFFIX=".so"
5860	    DL_OBJS="tclLoadDl.o"
5861	    DL_LIBS="-ldl"
5862	    if test "$GCC" = yes
5863then :
5864
5865		SHLIB_LD='${CC} -shared'
5866		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
5867		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
5868		if test "$do64bit_ok" = yes
5869then :
5870
5871		    if test "$arch" = "sparcv9 sparc"
5872then :
5873
5874			# We need to specify -static-libgcc or we need to
5875			# add the path to the sparv9 libgcc.
5876			SHLIB_LD="$SHLIB_LD -m64 -mcpu=v9 -static-libgcc"
5877			# for finding sparcv9 libgcc, get the regular libgcc
5878			# path, remove so name and append 'sparcv9'
5879			#v9gcclibdir="`gcc -print-file-name=libgcc_s.so` | ..."
5880			#CC_SEARCH_FLAGS="${CC_SEARCH_FLAGS},-R,$v9gcclibdir"
5881
5882else $as_nop
5883  if test "$arch" = "amd64 i386"
5884then :
5885
5886			SHLIB_LD="$SHLIB_LD -m64 -static-libgcc"
5887
5888fi
5889fi
5890
5891fi
5892
5893else $as_nop
5894
5895		if test "$use_sunmath" = yes
5896then :
5897  textmode=textoff
5898else $as_nop
5899  textmode=text
5900fi
5901		case $system in
5902		    SunOS-5.[1-9][0-9]*|SunOS-5.[7-9])
5903			SHLIB_LD="\${CC} -G -z $textmode \${LDFLAGS}";;
5904		    *)
5905			SHLIB_LD="/usr/ccs/bin/ld -G -z $textmode";;
5906		esac
5907		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
5908		LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
5909
5910fi
5911	    ;;
5912	UNIX_SV* | UnixWare-5*)
5913	    SHLIB_CFLAGS="-KPIC"
5914	    SHLIB_LD='${CC} -G'
5915	    SHLIB_LD_LIBS=""
5916	    SHLIB_SUFFIX=".so"
5917	    DL_OBJS="tclLoadDl.o"
5918	    DL_LIBS="-ldl"
5919	    # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
5920	    # that don't grok the -Bexport option.  Test that it does.
5921	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld accepts -Bexport flag" >&5
5922printf %s "checking for ld accepts -Bexport flag... " >&6; }
5923if test ${tcl_cv_ld_Bexport+y}
5924then :
5925  printf %s "(cached) " >&6
5926else $as_nop
5927
5928		hold_ldflags=$LDFLAGS
5929		LDFLAGS="$LDFLAGS -Wl,-Bexport"
5930		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5931/* end confdefs.h.  */
5932
5933int
5934main (void)
5935{
5936int i;
5937  ;
5938  return 0;
5939}
5940_ACEOF
5941if ac_fn_c_try_link "$LINENO"
5942then :
5943  tcl_cv_ld_Bexport=yes
5944else $as_nop
5945  tcl_cv_ld_Bexport=no
5946fi
5947rm -f core conftest.err conftest.$ac_objext conftest.beam \
5948    conftest$ac_exeext conftest.$ac_ext
5949	        LDFLAGS=$hold_ldflags
5950fi
5951{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_Bexport" >&5
5952printf "%s\n" "$tcl_cv_ld_Bexport" >&6; }
5953	    if test $tcl_cv_ld_Bexport = yes
5954then :
5955
5956		LDFLAGS="$LDFLAGS -Wl,-Bexport"
5957
5958fi
5959	    CC_SEARCH_FLAGS=""
5960	    LD_SEARCH_FLAGS=""
5961	    ;;
5962    esac
5963
5964    if test "$do64bit" = yes -a "$do64bit_ok" = no
5965then :
5966
5967	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 64bit support being disabled -- don't know magic for this platform" >&5
5968printf "%s\n" "$as_me: WARNING: 64bit support being disabled -- don't know magic for this platform" >&2;}
5969
5970fi
5971
5972    if test "$do64bit" = yes -a "$do64bit_ok" = yes
5973then :
5974
5975
5976printf "%s\n" "#define TCL_CFG_DO64BIT 1" >>confdefs.h
5977
5978
5979fi
5980
5981
5982
5983    # Step 4: disable dynamic loading if requested via a command-line switch.
5984
5985    # Check whether --enable-load was given.
5986if test ${enable_load+y}
5987then :
5988  enableval=$enable_load; tcl_ok=$enableval
5989else $as_nop
5990  tcl_ok=yes
5991fi
5992
5993    if test "$tcl_ok" = no
5994then :
5995  DL_OBJS=""
5996fi
5997
5998    if test "x$DL_OBJS" != x
5999then :
6000  BUILD_DLTEST="\$(DLTEST_TARGETS)"
6001else $as_nop
6002
6003	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Can't figure out how to do dynamic loading or shared libraries on this system." >&5
6004printf "%s\n" "$as_me: WARNING: Can't figure out how to do dynamic loading or shared libraries on this system." >&2;}
6005	SHLIB_CFLAGS=""
6006	SHLIB_LD=""
6007	SHLIB_SUFFIX=""
6008	DL_OBJS="tclLoadNone.o"
6009	DL_LIBS=""
6010	LDFLAGS="$LDFLAGS_ORIG"
6011	CC_SEARCH_FLAGS=""
6012	LD_SEARCH_FLAGS=""
6013	BUILD_DLTEST=""
6014
6015fi
6016    LDFLAGS="$LDFLAGS $LDFLAGS_ARCH"
6017
6018    # If we're running gcc, then change the C flags for compiling shared
6019    # libraries to the right flags for gcc, instead of those for the
6020    # standard manufacturer compiler.
6021
6022    if test "$DL_OBJS" != "tclLoadNone.o" -a "$GCC" = yes
6023then :
6024
6025	case $system in
6026	    AIX-*) ;;
6027	    BSD/OS*) ;;
6028	    CYGWIN_*|MINGW32_*|MSYS_*) ;;
6029	    HP-UX*) ;;
6030	    Darwin-*) ;;
6031	    IRIX*) ;;
6032	    Linux*|GNU*) ;;
6033	    NetBSD-*|OpenBSD-*) ;;
6034	    OSF1-*) ;;
6035	    SCO_SV-3.2*) ;;
6036	    *) SHLIB_CFLAGS="-fPIC" ;;
6037	esac
6038fi
6039
6040    if test "$tcl_cv_cc_visibility_hidden" != yes
6041then :
6042
6043
6044printf "%s\n" "#define MODULE_SCOPE extern" >>confdefs.h
6045
6046
6047fi
6048
6049    if test "$SHARED_LIB_SUFFIX" = ""
6050then :
6051
6052	SHARED_LIB_SUFFIX='${VERSION}${SHLIB_SUFFIX}'
6053fi
6054    if test "$UNSHARED_LIB_SUFFIX" = ""
6055then :
6056
6057	UNSHARED_LIB_SUFFIX='${VERSION}.a'
6058fi
6059    DLL_INSTALL_DIR="\$(LIB_INSTALL_DIR)"
6060
6061    if test "${SHARED_BUILD}" = 1 -a "${SHLIB_SUFFIX}" != ""
6062then :
6063
6064        LIB_SUFFIX=${SHARED_LIB_SUFFIX}
6065        MAKE_LIB='${SHLIB_LD} -o $@ ${OBJS} ${LDFLAGS} ${SHLIB_LD_LIBS} ${TCL_SHLIB_LD_EXTRAS} ${TK_SHLIB_LD_EXTRAS} ${LD_SEARCH_FLAGS}'
6066        if test "${SHLIB_SUFFIX}" = ".dll"
6067then :
6068
6069            INSTALL_LIB='$(INSTALL_LIBRARY) $(LIB_FILE) "$(BIN_INSTALL_DIR)/$(LIB_FILE)";if test -f $(LIB_FILE).a; then $(INSTALL_DATA) $(LIB_FILE).a "$(LIB_INSTALL_DIR)"; fi;'
6070            DLL_INSTALL_DIR="\$(BIN_INSTALL_DIR)"
6071
6072else $as_nop
6073
6074            INSTALL_LIB='$(INSTALL_LIBRARY) $(LIB_FILE) "$(LIB_INSTALL_DIR)/$(LIB_FILE)"'
6075
6076fi
6077
6078else $as_nop
6079
6080        LIB_SUFFIX=${UNSHARED_LIB_SUFFIX}
6081
6082        if test "$RANLIB" = ""
6083then :
6084
6085            MAKE_LIB='$(STLIB_LD) $@ ${OBJS}'
6086
6087else $as_nop
6088
6089            MAKE_LIB='${STLIB_LD} $@ ${OBJS} ; ${RANLIB} $@'
6090
6091fi
6092        INSTALL_LIB='$(INSTALL_LIBRARY) $(LIB_FILE) "$(LIB_INSTALL_DIR)/$(LIB_FILE)"'
6093
6094fi
6095
6096    # Stub lib does not depend on shared/static configuration
6097    if test "$RANLIB" = ""
6098then :
6099
6100        MAKE_STUB_LIB='${STLIB_LD} $@ ${STUB_LIB_OBJS}'
6101
6102else $as_nop
6103
6104        MAKE_STUB_LIB='${STLIB_LD} $@ ${STUB_LIB_OBJS} ; ${RANLIB} $@'
6105
6106fi
6107    INSTALL_STUB_LIB='$(INSTALL_LIBRARY) $(STUB_LIB_FILE) "$(LIB_INSTALL_DIR)/$(STUB_LIB_FILE)"'
6108
6109    # Define TCL_LIBS now that we know what DL_LIBS is.
6110    # The trick here is that we don't want to change the value of TCL_LIBS if
6111    # it is already set when tclConfig.sh had been loaded by Tk.
6112    if test "x${TCL_LIBS}" = x
6113then :
6114
6115        TCL_LIBS="${DL_LIBS} ${LIBS} ${MATH_LIBS}"
6116fi
6117
6118
6119    # See if the compiler supports casting to a union type.
6120    # This is used to stop gcc from printing a compiler
6121    # warning when initializing a union member.
6122
6123    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cast to union support" >&5
6124printf %s "checking for cast to union support... " >&6; }
6125if test ${tcl_cv_cast_to_union+y}
6126then :
6127  printf %s "(cached) " >&6
6128else $as_nop
6129  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6130/* end confdefs.h.  */
6131
6132int
6133main (void)
6134{
6135
6136		union foo { int i; double d; };
6137		union foo f = (union foo) (int) 0;
6138
6139  ;
6140  return 0;
6141}
6142_ACEOF
6143if ac_fn_c_try_compile "$LINENO"
6144then :
6145  tcl_cv_cast_to_union=yes
6146else $as_nop
6147  tcl_cv_cast_to_union=no
6148fi
6149rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6150
6151fi
6152{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cast_to_union" >&5
6153printf "%s\n" "$tcl_cv_cast_to_union" >&6; }
6154    if test "$tcl_cv_cast_to_union" = "yes"; then
6155
6156printf "%s\n" "#define HAVE_CAST_TO_UNION 1" >>confdefs.h
6157
6158    fi
6159    hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -fno-lto"
6160    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working -fno-lto" >&5
6161printf %s "checking for working -fno-lto... " >&6; }
6162if test ${ac_cv_nolto+y}
6163then :
6164  printf %s "(cached) " >&6
6165else $as_nop
6166  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6167/* end confdefs.h.  */
6168
6169int
6170main (void)
6171{
6172
6173  ;
6174  return 0;
6175}
6176_ACEOF
6177if ac_fn_c_try_compile "$LINENO"
6178then :
6179  ac_cv_nolto=yes
6180else $as_nop
6181  ac_cv_nolto=no
6182fi
6183rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6184
6185fi
6186{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_nolto" >&5
6187printf "%s\n" "$ac_cv_nolto" >&6; }
6188    CFLAGS=$hold_cflags
6189    if test "$ac_cv_nolto" = "yes" ; then
6190	CFLAGS_NOLTO="-fno-lto"
6191    else
6192	CFLAGS_NOLTO=""
6193    fi
6194    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the compiler understands -finput-charset" >&5
6195printf %s "checking if the compiler understands -finput-charset... " >&6; }
6196if test ${tcl_cv_cc_input_charset+y}
6197then :
6198  printf %s "(cached) " >&6
6199else $as_nop
6200
6201	hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -finput-charset=UTF-8"
6202	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6203/* end confdefs.h.  */
6204
6205int
6206main (void)
6207{
6208
6209  ;
6210  return 0;
6211}
6212_ACEOF
6213if ac_fn_c_try_compile "$LINENO"
6214then :
6215  tcl_cv_cc_input_charset=yes
6216else $as_nop
6217  tcl_cv_cc_input_charset=no
6218fi
6219rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6220	CFLAGS=$hold_cflags
6221fi
6222{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_input_charset" >&5
6223printf "%s\n" "$tcl_cv_cc_input_charset" >&6; }
6224    if test $tcl_cv_cc_input_charset = yes; then
6225	CFLAGS="$CFLAGS -finput-charset=UTF-8"
6226    fi
6227
6228    ac_fn_c_check_header_compile "$LINENO" "stdbool.h" "ac_cv_header_stdbool_h" "$ac_includes_default"
6229if test "x$ac_cv_header_stdbool_h" = xyes
6230then :
6231
6232printf "%s\n" "#define HAVE_STDBOOL_H 1" >>confdefs.h
6233
6234fi
6235
6236
6237    # FIXME: This subst was left in only because the TCL_DL_LIBS
6238    # entry in tclConfig.sh uses it. It is not clear why someone
6239    # would use TCL_DL_LIBS instead of TCL_LIBS.
6240
6241
6242
6243
6244
6245
6246
6247
6248
6249
6250
6251
6252
6253
6254
6255
6256
6257
6258
6259
6260
6261
6262
6263
6264
6265
6266printf "%s\n" "#define TCL_SHLIB_EXT \"${SHLIB_SUFFIX}\"" >>confdefs.h
6267
6268
6269
6270
6271
6272
6273
6274
6275
6276
6277
6278    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for build with symbols" >&5
6279printf %s "checking for build with symbols... " >&6; }
6280    # Check whether --enable-symbols was given.
6281if test ${enable_symbols+y}
6282then :
6283  enableval=$enable_symbols; tcl_ok=$enableval
6284else $as_nop
6285  tcl_ok=no
6286fi
6287
6288# FIXME: Currently, LDFLAGS_DEFAULT is not used, it should work like CFLAGS_DEFAULT.
6289    if test "$tcl_ok" = "no"; then
6290	CFLAGS_DEFAULT='$(CFLAGS_OPTIMIZE)'
6291	LDFLAGS_DEFAULT='$(LDFLAGS_OPTIMIZE)'
6292
6293printf "%s\n" "#define NDEBUG 1" >>confdefs.h
6294
6295	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6296printf "%s\n" "no" >&6; }
6297
6298printf "%s\n" "#define TCL_CFG_OPTIMIZED 1" >>confdefs.h
6299
6300    else
6301	CFLAGS_DEFAULT='$(CFLAGS_DEBUG)'
6302	LDFLAGS_DEFAULT='$(LDFLAGS_DEBUG)'
6303	if test "$tcl_ok" = "yes"; then
6304	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes (standard debugging)" >&5
6305printf "%s\n" "yes (standard debugging)" >&6; }
6306	fi
6307    fi
6308
6309
6310
6311    if test "$tcl_ok" = "mem" -o "$tcl_ok" = "all"; then
6312
6313printf "%s\n" "#define TCL_MEM_DEBUG 1" >>confdefs.h
6314
6315    fi
6316
6317
6318
6319    if test "$tcl_ok" != "yes" -a "$tcl_ok" != "no"; then
6320	if test "$tcl_ok" = "all"; then
6321	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: enabled symbols mem debugging" >&5
6322printf "%s\n" "enabled symbols mem debugging" >&6; }
6323	else
6324	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: enabled $tcl_ok debugging" >&5
6325printf "%s\n" "enabled $tcl_ok debugging" >&6; }
6326	fi
6327    fi
6328
6329
6330#--------------------------------------------------------------------
6331#	Detect what compiler flags to set for 64-bit support.
6332#--------------------------------------------------------------------
6333
6334
6335    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for required early compiler flags" >&5
6336printf %s "checking for required early compiler flags... " >&6; }
6337    tcl_flags=""
6338
6339    if test ${tcl_cv_flag__isoc99_source+y}
6340then :
6341  printf %s "(cached) " >&6
6342else $as_nop
6343  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6344/* end confdefs.h.  */
6345#include <stdlib.h>
6346int
6347main (void)
6348{
6349char *p = (char *)strtoll; char *q = (char *)strtoull;
6350  ;
6351  return 0;
6352}
6353_ACEOF
6354if ac_fn_c_try_compile "$LINENO"
6355then :
6356  tcl_cv_flag__isoc99_source=no
6357else $as_nop
6358  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6359/* end confdefs.h.  */
6360#define _ISOC99_SOURCE 1
6361#include <stdlib.h>
6362int
6363main (void)
6364{
6365char *p = (char *)strtoll; char *q = (char *)strtoull;
6366  ;
6367  return 0;
6368}
6369_ACEOF
6370if ac_fn_c_try_compile "$LINENO"
6371then :
6372  tcl_cv_flag__isoc99_source=yes
6373else $as_nop
6374  tcl_cv_flag__isoc99_source=no
6375fi
6376rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6377fi
6378rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6379fi
6380
6381    if test "x${tcl_cv_flag__isoc99_source}" = "xyes" ; then
6382
6383printf "%s\n" "#define _ISOC99_SOURCE 1" >>confdefs.h
6384
6385	tcl_flags="$tcl_flags _ISOC99_SOURCE"
6386    fi
6387
6388
6389    if test ${tcl_cv_flag__largefile64_source+y}
6390then :
6391  printf %s "(cached) " >&6
6392else $as_nop
6393  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6394/* end confdefs.h.  */
6395#include <sys/stat.h>
6396int
6397main (void)
6398{
6399struct stat64 buf; int i = stat64("/", &buf);
6400  ;
6401  return 0;
6402}
6403_ACEOF
6404if ac_fn_c_try_compile "$LINENO"
6405then :
6406  tcl_cv_flag__largefile64_source=no
6407else $as_nop
6408  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6409/* end confdefs.h.  */
6410#define _LARGEFILE64_SOURCE 1
6411#include <sys/stat.h>
6412int
6413main (void)
6414{
6415struct stat64 buf; int i = stat64("/", &buf);
6416  ;
6417  return 0;
6418}
6419_ACEOF
6420if ac_fn_c_try_compile "$LINENO"
6421then :
6422  tcl_cv_flag__largefile64_source=yes
6423else $as_nop
6424  tcl_cv_flag__largefile64_source=no
6425fi
6426rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6427fi
6428rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6429fi
6430
6431    if test "x${tcl_cv_flag__largefile64_source}" = "xyes" ; then
6432
6433printf "%s\n" "#define _LARGEFILE64_SOURCE 1" >>confdefs.h
6434
6435	tcl_flags="$tcl_flags _LARGEFILE64_SOURCE"
6436    fi
6437
6438
6439    if test ${tcl_cv_flag__largefile_source64+y}
6440then :
6441  printf %s "(cached) " >&6
6442else $as_nop
6443  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6444/* end confdefs.h.  */
6445#include <sys/stat.h>
6446int
6447main (void)
6448{
6449char *p = (char *)open64;
6450  ;
6451  return 0;
6452}
6453_ACEOF
6454if ac_fn_c_try_compile "$LINENO"
6455then :
6456  tcl_cv_flag__largefile_source64=no
6457else $as_nop
6458  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6459/* end confdefs.h.  */
6460#define _LARGEFILE_SOURCE64 1
6461#include <sys/stat.h>
6462int
6463main (void)
6464{
6465char *p = (char *)open64;
6466  ;
6467  return 0;
6468}
6469_ACEOF
6470if ac_fn_c_try_compile "$LINENO"
6471then :
6472  tcl_cv_flag__largefile_source64=yes
6473else $as_nop
6474  tcl_cv_flag__largefile_source64=no
6475fi
6476rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6477fi
6478rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6479fi
6480
6481    if test "x${tcl_cv_flag__largefile_source64}" = "xyes" ; then
6482
6483printf "%s\n" "#define _LARGEFILE_SOURCE64 1" >>confdefs.h
6484
6485	tcl_flags="$tcl_flags _LARGEFILE_SOURCE64"
6486    fi
6487
6488    if test "x${tcl_flags}" = "x" ; then
6489	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5
6490printf "%s\n" "none" >&6; }
6491    else
6492	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${tcl_flags}" >&5
6493printf "%s\n" "${tcl_flags}" >&6; }
6494    fi
6495
6496
6497
6498    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 64-bit integer type" >&5
6499printf %s "checking for 64-bit integer type... " >&6; }
6500    if test ${tcl_cv_type_64bit+y}
6501then :
6502  printf %s "(cached) " >&6
6503else $as_nop
6504
6505	tcl_cv_type_64bit=none
6506	# See if we could use long anyway  Note that we substitute in the
6507	# type that is our current guess for a 64-bit type inside this check
6508	# program, so it should be modified only carefully...
6509        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6510/* end confdefs.h.  */
6511
6512int
6513main (void)
6514{
6515switch (0) {
6516            case 1: case (sizeof(long long)==sizeof(long)): ;
6517        }
6518  ;
6519  return 0;
6520}
6521_ACEOF
6522if ac_fn_c_try_compile "$LINENO"
6523then :
6524  tcl_cv_type_64bit="long long"
6525fi
6526rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6527fi
6528
6529    if test "${tcl_cv_type_64bit}" = none ; then
6530
6531printf "%s\n" "#define TCL_WIDE_INT_IS_LONG 1" >>confdefs.h
6532
6533	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6534printf "%s\n" "yes" >&6; }
6535    else
6536	# Now check for auxiliary declarations
6537	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct dirent64" >&5
6538printf %s "checking for struct dirent64... " >&6; }
6539if test ${tcl_cv_struct_dirent64+y}
6540then :
6541  printf %s "(cached) " >&6
6542else $as_nop
6543
6544	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6545/* end confdefs.h.  */
6546#include <sys/types.h>
6547#include <dirent.h>
6548int
6549main (void)
6550{
6551struct dirent64 p;
6552  ;
6553  return 0;
6554}
6555_ACEOF
6556if ac_fn_c_try_compile "$LINENO"
6557then :
6558  tcl_cv_struct_dirent64=yes
6559else $as_nop
6560  tcl_cv_struct_dirent64=no
6561fi
6562rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6563fi
6564{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_struct_dirent64" >&5
6565printf "%s\n" "$tcl_cv_struct_dirent64" >&6; }
6566	if test "x${tcl_cv_struct_dirent64}" = "xyes" ; then
6567
6568printf "%s\n" "#define HAVE_STRUCT_DIRENT64 1" >>confdefs.h
6569
6570	fi
6571
6572	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DIR64" >&5
6573printf %s "checking for DIR64... " >&6; }
6574if test ${tcl_cv_DIR64+y}
6575then :
6576  printf %s "(cached) " >&6
6577else $as_nop
6578
6579	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6580/* end confdefs.h.  */
6581#include <sys/types.h>
6582#include <dirent.h>
6583int
6584main (void)
6585{
6586struct dirent64 *p; DIR64 d = opendir64(".");
6587            p = readdir64(d); rewinddir64(d); closedir64(d);
6588  ;
6589  return 0;
6590}
6591_ACEOF
6592if ac_fn_c_try_compile "$LINENO"
6593then :
6594  tcl_cv_DIR64=yes
6595else $as_nop
6596  tcl_cv_DIR64=no
6597fi
6598rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6599fi
6600{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_DIR64" >&5
6601printf "%s\n" "$tcl_cv_DIR64" >&6; }
6602	if test "x${tcl_cv_DIR64}" = "xyes" ; then
6603
6604printf "%s\n" "#define HAVE_DIR64 1" >>confdefs.h
6605
6606	fi
6607
6608	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct stat64" >&5
6609printf %s "checking for struct stat64... " >&6; }
6610if test ${tcl_cv_struct_stat64+y}
6611then :
6612  printf %s "(cached) " >&6
6613else $as_nop
6614
6615	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6616/* end confdefs.h.  */
6617#include <sys/stat.h>
6618int
6619main (void)
6620{
6621struct stat64 p;
6622
6623  ;
6624  return 0;
6625}
6626_ACEOF
6627if ac_fn_c_try_compile "$LINENO"
6628then :
6629  tcl_cv_struct_stat64=yes
6630else $as_nop
6631  tcl_cv_struct_stat64=no
6632fi
6633rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6634fi
6635{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_struct_stat64" >&5
6636printf "%s\n" "$tcl_cv_struct_stat64" >&6; }
6637	if test "x${tcl_cv_struct_stat64}" = "xyes" ; then
6638
6639printf "%s\n" "#define HAVE_STRUCT_STAT64 1" >>confdefs.h
6640
6641	fi
6642
6643	ac_fn_c_check_func "$LINENO" "open64" "ac_cv_func_open64"
6644if test "x$ac_cv_func_open64" = xyes
6645then :
6646  printf "%s\n" "#define HAVE_OPEN64 1" >>confdefs.h
6647
6648fi
6649ac_fn_c_check_func "$LINENO" "lseek64" "ac_cv_func_lseek64"
6650if test "x$ac_cv_func_lseek64" = xyes
6651then :
6652  printf "%s\n" "#define HAVE_LSEEK64 1" >>confdefs.h
6653
6654fi
6655
6656	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for off64_t" >&5
6657printf %s "checking for off64_t... " >&6; }
6658	if test ${tcl_cv_type_off64_t+y}
6659then :
6660  printf %s "(cached) " >&6
6661else $as_nop
6662
6663	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6664/* end confdefs.h.  */
6665#include <sys/types.h>
6666int
6667main (void)
6668{
6669off64_t offset;
6670
6671  ;
6672  return 0;
6673}
6674_ACEOF
6675if ac_fn_c_try_compile "$LINENO"
6676then :
6677  tcl_cv_type_off64_t=yes
6678else $as_nop
6679  tcl_cv_type_off64_t=no
6680fi
6681rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6682fi
6683
6684			if test "x${tcl_cv_type_off64_t}" = "xyes" && \
6685	        test "x${ac_cv_func_lseek64}" = "xyes" && \
6686	        test "x${ac_cv_func_open64}" = "xyes" ; then
6687
6688printf "%s\n" "#define HAVE_TYPE_OFF64_T 1" >>confdefs.h
6689
6690	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6691printf "%s\n" "yes" >&6; }
6692	else
6693	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6694printf "%s\n" "no" >&6; }
6695	fi
6696    fi
6697
6698
6699#--------------------------------------------------------------------
6700#	Check endianness because we can optimize some operations
6701#--------------------------------------------------------------------
6702
6703 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
6704printf %s "checking whether byte ordering is bigendian... " >&6; }
6705if test ${ac_cv_c_bigendian+y}
6706then :
6707  printf %s "(cached) " >&6
6708else $as_nop
6709  ac_cv_c_bigendian=unknown
6710    # See if we're dealing with a universal compiler.
6711    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6712/* end confdefs.h.  */
6713#ifndef __APPLE_CC__
6714	       not a universal capable compiler
6715	     #endif
6716	     typedef int dummy;
6717
6718_ACEOF
6719if ac_fn_c_try_compile "$LINENO"
6720then :
6721
6722	# Check for potential -arch flags.  It is not universal unless
6723	# there are at least two -arch flags with different values.
6724	ac_arch=
6725	ac_prev=
6726	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
6727	 if test -n "$ac_prev"; then
6728	   case $ac_word in
6729	     i?86 | x86_64 | ppc | ppc64)
6730	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
6731		 ac_arch=$ac_word
6732	       else
6733		 ac_cv_c_bigendian=universal
6734		 break
6735	       fi
6736	       ;;
6737	   esac
6738	   ac_prev=
6739	 elif test "x$ac_word" = "x-arch"; then
6740	   ac_prev=arch
6741	 fi
6742       done
6743fi
6744rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6745    if test $ac_cv_c_bigendian = unknown; then
6746      # See if sys/param.h defines the BYTE_ORDER macro.
6747      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6748/* end confdefs.h.  */
6749#include <sys/types.h>
6750	     #include <sys/param.h>
6751
6752int
6753main (void)
6754{
6755#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
6756		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
6757		     && LITTLE_ENDIAN)
6758	      bogus endian macros
6759	     #endif
6760
6761  ;
6762  return 0;
6763}
6764_ACEOF
6765if ac_fn_c_try_compile "$LINENO"
6766then :
6767  # It does; now see whether it defined to BIG_ENDIAN or not.
6768	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6769/* end confdefs.h.  */
6770#include <sys/types.h>
6771		#include <sys/param.h>
6772
6773int
6774main (void)
6775{
6776#if BYTE_ORDER != BIG_ENDIAN
6777		 not big endian
6778		#endif
6779
6780  ;
6781  return 0;
6782}
6783_ACEOF
6784if ac_fn_c_try_compile "$LINENO"
6785then :
6786  ac_cv_c_bigendian=yes
6787else $as_nop
6788  ac_cv_c_bigendian=no
6789fi
6790rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6791fi
6792rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6793    fi
6794    if test $ac_cv_c_bigendian = unknown; then
6795      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
6796      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6797/* end confdefs.h.  */
6798#include <limits.h>
6799
6800int
6801main (void)
6802{
6803#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
6804	      bogus endian macros
6805	     #endif
6806
6807  ;
6808  return 0;
6809}
6810_ACEOF
6811if ac_fn_c_try_compile "$LINENO"
6812then :
6813  # It does; now see whether it defined to _BIG_ENDIAN or not.
6814	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6815/* end confdefs.h.  */
6816#include <limits.h>
6817
6818int
6819main (void)
6820{
6821#ifndef _BIG_ENDIAN
6822		 not big endian
6823		#endif
6824
6825  ;
6826  return 0;
6827}
6828_ACEOF
6829if ac_fn_c_try_compile "$LINENO"
6830then :
6831  ac_cv_c_bigendian=yes
6832else $as_nop
6833  ac_cv_c_bigendian=no
6834fi
6835rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6836fi
6837rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6838    fi
6839    if test $ac_cv_c_bigendian = unknown; then
6840      # Compile a test program.
6841      if test "$cross_compiling" = yes
6842then :
6843  # Try to guess by grepping values from an object file.
6844	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6845/* end confdefs.h.  */
6846unsigned short int ascii_mm[] =
6847		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
6848		unsigned short int ascii_ii[] =
6849		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
6850		int use_ascii (int i) {
6851		  return ascii_mm[i] + ascii_ii[i];
6852		}
6853		unsigned short int ebcdic_ii[] =
6854		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
6855		unsigned short int ebcdic_mm[] =
6856		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
6857		int use_ebcdic (int i) {
6858		  return ebcdic_mm[i] + ebcdic_ii[i];
6859		}
6860		extern int foo;
6861
6862int
6863main (void)
6864{
6865return use_ascii (foo) == use_ebcdic (foo);
6866  ;
6867  return 0;
6868}
6869_ACEOF
6870if ac_fn_c_try_compile "$LINENO"
6871then :
6872  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
6873	      ac_cv_c_bigendian=yes
6874	    fi
6875	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
6876	      if test "$ac_cv_c_bigendian" = unknown; then
6877		ac_cv_c_bigendian=no
6878	      else
6879		# finding both strings is unlikely to happen, but who knows?
6880		ac_cv_c_bigendian=unknown
6881	      fi
6882	    fi
6883fi
6884rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6885else $as_nop
6886  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6887/* end confdefs.h.  */
6888$ac_includes_default
6889int
6890main (void)
6891{
6892
6893	     /* Are we little or big endian?  From Harbison&Steele.  */
6894	     union
6895	     {
6896	       long int l;
6897	       char c[sizeof (long int)];
6898	     } u;
6899	     u.l = 1;
6900	     return u.c[sizeof (long int) - 1] == 1;
6901
6902  ;
6903  return 0;
6904}
6905_ACEOF
6906if ac_fn_c_try_run "$LINENO"
6907then :
6908  ac_cv_c_bigendian=no
6909else $as_nop
6910  ac_cv_c_bigendian=yes
6911fi
6912rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6913  conftest.$ac_objext conftest.beam conftest.$ac_ext
6914fi
6915
6916    fi
6917fi
6918{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
6919printf "%s\n" "$ac_cv_c_bigendian" >&6; }
6920 case $ac_cv_c_bigendian in #(
6921   yes)
6922     printf "%s\n" "#define WORDS_BIGENDIAN 1" >>confdefs.h
6923;; #(
6924   no)
6925      ;; #(
6926   universal)
6927
6928printf "%s\n" "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
6929
6930     ;; #(
6931   *)
6932     as_fn_error $? "unknown endianness
6933 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
6934 esac
6935
6936
6937#------------------------------------------------------------------------
6938# If Tcl and Tk are installed in different places, adjust the library
6939# search path to reflect this.
6940#------------------------------------------------------------------------
6941
6942LIB_RUNTIME_DIR='$(libdir)'
6943
6944if test "$TCL_EXEC_PREFIX" != "$exec_prefix"; then
6945    LIB_RUNTIME_DIR="${LIB_RUNTIME_DIR}:${TCL_EXEC_PREFIX}/lib"
6946fi
6947
6948if test "$TCL_PREFIX" != "$prefix"; then
6949    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING:
6950        Different --prefix selected for Tk and Tcl!
6951        [package require tk] may not work correctly in tclsh." >&5
6952printf "%s\n" "$as_me: WARNING:
6953        Different --prefix selected for Tk and Tcl!
6954        [package require tk] may not work correctly in tclsh." >&2;}
6955fi
6956
6957#--------------------------------------------------------------------
6958#	Include sys/select.h if it exists and if it supplies things
6959#	that appear to be useful and aren't already in sys/types.h.
6960#	This appears to be true only on the RS/6000 under AIX.  Some
6961#	systems like OSF/1 have a sys/select.h that's of no use, and
6962#	other systems like SCO UNIX have a sys/select.h that's
6963#	pernicious.  If "fd_set" isn't defined anywhere then set a
6964#	special flag.
6965#--------------------------------------------------------------------
6966
6967{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fd_set in sys/types" >&5
6968printf %s "checking for fd_set in sys/types... " >&6; }
6969if test ${tcl_cv_type_fd_set+y}
6970then :
6971  printf %s "(cached) " >&6
6972else $as_nop
6973
6974    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6975/* end confdefs.h.  */
6976#include <sys/types.h>
6977int
6978main (void)
6979{
6980fd_set readMask, writeMask;
6981  ;
6982  return 0;
6983}
6984_ACEOF
6985if ac_fn_c_try_compile "$LINENO"
6986then :
6987  tcl_cv_type_fd_set=yes
6988else $as_nop
6989  tcl_cv_type_fd_set=no
6990fi
6991rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6992fi
6993{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_type_fd_set" >&5
6994printf "%s\n" "$tcl_cv_type_fd_set" >&6; }
6995tk_ok=$tcl_cv_type_fd_set
6996if test $tk_ok = no; then
6997    ac_ext=c
6998ac_cpp='$CPP $CPPFLAGS'
6999ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7000ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7001ac_compiler_gnu=$ac_cv_c_compiler_gnu
7002{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
7003printf %s "checking how to run the C preprocessor... " >&6; }
7004# On Suns, sometimes $CPP names a directory.
7005if test -n "$CPP" && test -d "$CPP"; then
7006  CPP=
7007fi
7008if test -z "$CPP"; then
7009  if test ${ac_cv_prog_CPP+y}
7010then :
7011  printf %s "(cached) " >&6
7012else $as_nop
7013      # Double quotes because $CC needs to be expanded
7014    for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp
7015    do
7016      ac_preproc_ok=false
7017for ac_c_preproc_warn_flag in '' yes
7018do
7019  # Use a header file that comes with gcc, so configuring glibc
7020  # with a fresh cross-compiler works.
7021  # On the NeXT, cc -E runs the code through the compiler's parser,
7022  # not just through cpp. "Syntax error" is here to catch this case.
7023  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7024/* end confdefs.h.  */
7025#include <limits.h>
7026		     Syntax error
7027_ACEOF
7028if ac_fn_c_try_cpp "$LINENO"
7029then :
7030
7031else $as_nop
7032  # Broken: fails on valid input.
7033continue
7034fi
7035rm -f conftest.err conftest.i conftest.$ac_ext
7036
7037  # OK, works on sane cases.  Now check whether nonexistent headers
7038  # can be detected and how.
7039  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7040/* end confdefs.h.  */
7041#include <ac_nonexistent.h>
7042_ACEOF
7043if ac_fn_c_try_cpp "$LINENO"
7044then :
7045  # Broken: success on invalid input.
7046continue
7047else $as_nop
7048  # Passes both tests.
7049ac_preproc_ok=:
7050break
7051fi
7052rm -f conftest.err conftest.i conftest.$ac_ext
7053
7054done
7055# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7056rm -f conftest.i conftest.err conftest.$ac_ext
7057if $ac_preproc_ok
7058then :
7059  break
7060fi
7061
7062    done
7063    ac_cv_prog_CPP=$CPP
7064
7065fi
7066  CPP=$ac_cv_prog_CPP
7067else
7068  ac_cv_prog_CPP=$CPP
7069fi
7070{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
7071printf "%s\n" "$CPP" >&6; }
7072ac_preproc_ok=false
7073for ac_c_preproc_warn_flag in '' yes
7074do
7075  # Use a header file that comes with gcc, so configuring glibc
7076  # with a fresh cross-compiler works.
7077  # On the NeXT, cc -E runs the code through the compiler's parser,
7078  # not just through cpp. "Syntax error" is here to catch this case.
7079  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7080/* end confdefs.h.  */
7081#include <limits.h>
7082		     Syntax error
7083_ACEOF
7084if ac_fn_c_try_cpp "$LINENO"
7085then :
7086
7087else $as_nop
7088  # Broken: fails on valid input.
7089continue
7090fi
7091rm -f conftest.err conftest.i conftest.$ac_ext
7092
7093  # OK, works on sane cases.  Now check whether nonexistent headers
7094  # can be detected and how.
7095  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7096/* end confdefs.h.  */
7097#include <ac_nonexistent.h>
7098_ACEOF
7099if ac_fn_c_try_cpp "$LINENO"
7100then :
7101  # Broken: success on invalid input.
7102continue
7103else $as_nop
7104  # Passes both tests.
7105ac_preproc_ok=:
7106break
7107fi
7108rm -f conftest.err conftest.i conftest.$ac_ext
7109
7110done
7111# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7112rm -f conftest.i conftest.err conftest.$ac_ext
7113if $ac_preproc_ok
7114then :
7115
7116else $as_nop
7117  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7118printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
7119as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
7120See \`config.log' for more details" "$LINENO" 5; }
7121fi
7122
7123ac_ext=c
7124ac_cpp='$CPP $CPPFLAGS'
7125ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7126ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7127ac_compiler_gnu=$ac_cv_c_compiler_gnu
7128
7129
7130{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
7131printf %s "checking for grep that handles long lines and -e... " >&6; }
7132if test ${ac_cv_path_GREP+y}
7133then :
7134  printf %s "(cached) " >&6
7135else $as_nop
7136  if test -z "$GREP"; then
7137  ac_path_GREP_found=false
7138  # Loop through the user's path and test for each of PROGNAME-LIST
7139  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7140for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7141do
7142  IFS=$as_save_IFS
7143  case $as_dir in #(((
7144    '') as_dir=./ ;;
7145    */) ;;
7146    *) as_dir=$as_dir/ ;;
7147  esac
7148    for ac_prog in grep ggrep
7149   do
7150    for ac_exec_ext in '' $ac_executable_extensions; do
7151      ac_path_GREP="$as_dir$ac_prog$ac_exec_ext"
7152      as_fn_executable_p "$ac_path_GREP" || continue
7153# Check for GNU ac_path_GREP and select it if it is found.
7154  # Check for GNU $ac_path_GREP
7155case `"$ac_path_GREP" --version 2>&1` in
7156*GNU*)
7157  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
7158*)
7159  ac_count=0
7160  printf %s 0123456789 >"conftest.in"
7161  while :
7162  do
7163    cat "conftest.in" "conftest.in" >"conftest.tmp"
7164    mv "conftest.tmp" "conftest.in"
7165    cp "conftest.in" "conftest.nl"
7166    printf "%s\n" 'GREP' >> "conftest.nl"
7167    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
7168    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7169    as_fn_arith $ac_count + 1 && ac_count=$as_val
7170    if test $ac_count -gt ${ac_path_GREP_max-0}; then
7171      # Best one so far, save it but keep looking for a better one
7172      ac_cv_path_GREP="$ac_path_GREP"
7173      ac_path_GREP_max=$ac_count
7174    fi
7175    # 10*(2^10) chars as input seems more than enough
7176    test $ac_count -gt 10 && break
7177  done
7178  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7179esac
7180
7181      $ac_path_GREP_found && break 3
7182    done
7183  done
7184  done
7185IFS=$as_save_IFS
7186  if test -z "$ac_cv_path_GREP"; then
7187    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7188  fi
7189else
7190  ac_cv_path_GREP=$GREP
7191fi
7192
7193fi
7194{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
7195printf "%s\n" "$ac_cv_path_GREP" >&6; }
7196 GREP="$ac_cv_path_GREP"
7197
7198
7199{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
7200printf %s "checking for egrep... " >&6; }
7201if test ${ac_cv_path_EGREP+y}
7202then :
7203  printf %s "(cached) " >&6
7204else $as_nop
7205  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
7206   then ac_cv_path_EGREP="$GREP -E"
7207   else
7208     if test -z "$EGREP"; then
7209  ac_path_EGREP_found=false
7210  # Loop through the user's path and test for each of PROGNAME-LIST
7211  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7212for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7213do
7214  IFS=$as_save_IFS
7215  case $as_dir in #(((
7216    '') as_dir=./ ;;
7217    */) ;;
7218    *) as_dir=$as_dir/ ;;
7219  esac
7220    for ac_prog in egrep
7221   do
7222    for ac_exec_ext in '' $ac_executable_extensions; do
7223      ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext"
7224      as_fn_executable_p "$ac_path_EGREP" || continue
7225# Check for GNU ac_path_EGREP and select it if it is found.
7226  # Check for GNU $ac_path_EGREP
7227case `"$ac_path_EGREP" --version 2>&1` in
7228*GNU*)
7229  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
7230*)
7231  ac_count=0
7232  printf %s 0123456789 >"conftest.in"
7233  while :
7234  do
7235    cat "conftest.in" "conftest.in" >"conftest.tmp"
7236    mv "conftest.tmp" "conftest.in"
7237    cp "conftest.in" "conftest.nl"
7238    printf "%s\n" 'EGREP' >> "conftest.nl"
7239    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
7240    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7241    as_fn_arith $ac_count + 1 && ac_count=$as_val
7242    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
7243      # Best one so far, save it but keep looking for a better one
7244      ac_cv_path_EGREP="$ac_path_EGREP"
7245      ac_path_EGREP_max=$ac_count
7246    fi
7247    # 10*(2^10) chars as input seems more than enough
7248    test $ac_count -gt 10 && break
7249  done
7250  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7251esac
7252
7253      $ac_path_EGREP_found && break 3
7254    done
7255  done
7256  done
7257IFS=$as_save_IFS
7258  if test -z "$ac_cv_path_EGREP"; then
7259    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7260  fi
7261else
7262  ac_cv_path_EGREP=$EGREP
7263fi
7264
7265   fi
7266fi
7267{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
7268printf "%s\n" "$ac_cv_path_EGREP" >&6; }
7269 EGREP="$ac_cv_path_EGREP"
7270
7271
7272{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fd_mask in sys/select" >&5
7273printf %s "checking for fd_mask in sys/select... " >&6; }
7274if test ${tcl_cv_grep_fd_mask+y}
7275then :
7276  printf %s "(cached) " >&6
7277else $as_nop
7278
7279	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7280/* end confdefs.h.  */
7281#include <sys/select.h>
7282
7283_ACEOF
7284if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7285  $EGREP "fd_mask" >/dev/null 2>&1
7286then :
7287  tcl_cv_grep_fd_mask=present
7288else $as_nop
7289  tcl_cv_grep_fd_mask=missing
7290fi
7291rm -rf conftest*
7292
7293fi
7294{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_grep_fd_mask" >&5
7295printf "%s\n" "$tcl_cv_grep_fd_mask" >&6; }
7296    if test $tcl_cv_grep_fd_mask = present; then
7297
7298printf "%s\n" "#define HAVE_SYS_SELECT_H 1" >>confdefs.h
7299
7300	tk_ok=yes
7301    fi
7302fi
7303if test $tk_ok = no; then
7304
7305printf "%s\n" "#define NO_FD_SET 1" >>confdefs.h
7306
7307fi
7308
7309#------------------------------------------------------------------------------
7310#       Find out all about time handling differences.
7311#------------------------------------------------------------------------------
7312
7313
7314
7315
7316#--------------------------------------------------------------------
7317#	Check for various typedefs and provide substitutes if
7318#	they don't exist.
7319#--------------------------------------------------------------------
7320
7321ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
7322if test "x$ac_cv_type_mode_t" = xyes
7323then :
7324
7325else $as_nop
7326
7327printf "%s\n" "#define mode_t int" >>confdefs.h
7328
7329fi
7330
7331
7332  ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default
7333"
7334if test "x$ac_cv_type_pid_t" = xyes
7335then :
7336
7337else $as_nop
7338                                          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7339/* end confdefs.h.  */
7340
7341          #if defined _WIN64 && !defined __CYGWIN__
7342          LLP64
7343          #endif
7344
7345int
7346main (void)
7347{
7348
7349  ;
7350  return 0;
7351}
7352
7353_ACEOF
7354if ac_fn_c_try_compile "$LINENO"
7355then :
7356  ac_pid_type='int'
7357else $as_nop
7358  ac_pid_type='__int64'
7359fi
7360rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7361
7362printf "%s\n" "#define pid_t $ac_pid_type" >>confdefs.h
7363
7364
7365fi
7366
7367
7368ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
7369if test "x$ac_cv_type_size_t" = xyes
7370then :
7371
7372else $as_nop
7373
7374printf "%s\n" "#define size_t unsigned int" >>confdefs.h
7375
7376fi
7377
7378
7379ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "
7380#include <stdint.h>
7381
7382"
7383if test "x$ac_cv_type_intptr_t" = xyes
7384then :
7385
7386printf "%s\n" "#define HAVE_INTPTR_T 1" >>confdefs.h
7387
7388
7389fi
7390ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "
7391#include <stdint.h>
7392
7393"
7394if test "x$ac_cv_type_uintptr_t" = xyes
7395then :
7396
7397printf "%s\n" "#define HAVE_UINTPTR_T 1" >>confdefs.h
7398
7399
7400fi
7401
7402
7403#-------------------------------------------
7404#     In OS/390 struct pwd has no pw_gecos field
7405#-------------------------------------------
7406
7407{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking pw_gecos in struct pwd" >&5
7408printf %s "checking pw_gecos in struct pwd... " >&6; }
7409if test ${tcl_cv_pwd_pw_gecos+y}
7410then :
7411  printf %s "(cached) " >&6
7412else $as_nop
7413
7414    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7415/* end confdefs.h.  */
7416#include <pwd.h>
7417int
7418main (void)
7419{
7420struct passwd pwd; (void)pwd.pw_gecos;
7421  ;
7422  return 0;
7423}
7424_ACEOF
7425if ac_fn_c_try_compile "$LINENO"
7426then :
7427  tcl_cv_pwd_pw_gecos=yes
7428else $as_nop
7429  tcl_cv_pwd_pw_gecos=no
7430fi
7431rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7432fi
7433{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_pwd_pw_gecos" >&5
7434printf "%s\n" "$tcl_cv_pwd_pw_gecos" >&6; }
7435if test $tcl_cv_pwd_pw_gecos = yes; then
7436
7437printf "%s\n" "#define HAVE_PW_GECOS 1" >>confdefs.h
7438
7439fi
7440
7441#--------------------------------------------------------------------
7442#	On Mac OS X, we can build either with X11 or with Aqua
7443#--------------------------------------------------------------------
7444
7445if test "`uname -s`" = "Darwin" ; then
7446    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to use Aqua" >&5
7447printf %s "checking whether to use Aqua... " >&6; }
7448    # Check whether --enable-aqua was given.
7449if test ${enable_aqua+y}
7450then :
7451  enableval=$enable_aqua; tk_aqua=$enableval
7452else $as_nop
7453  tk_aqua=no
7454fi
7455
7456    if test $tk_aqua = yes -o $tk_aqua = cocoa; then
7457	tk_aqua=yes
7458	if test $tcl_corefoundation = no; then
7459	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Aqua can only be used when CoreFoundation is available" >&5
7460printf "%s\n" "$as_me: WARNING: Aqua can only be used when CoreFoundation is available" >&2;}
7461	    tk_aqua=no
7462	fi
7463	if test ! -d /System/Library/Frameworks/Cocoa.framework; then
7464	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Aqua can only be used when Cocoa is available" >&5
7465printf "%s\n" "$as_me: WARNING: Aqua can only be used when Cocoa is available" >&2;}
7466	    tk_aqua=no
7467	fi
7468	if test "`uname -r | awk -F. '{print $1}'`" -lt 9; then
7469	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Aqua requires Mac OS X 10.5 or later" >&5
7470printf "%s\n" "$as_me: WARNING: Aqua requires Mac OS X 10.5 or later" >&2;}
7471	    tk_aqua=no
7472	fi
7473    fi
7474    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tk_aqua" >&5
7475printf "%s\n" "$tk_aqua" >&6; }
7476    if test "$fat_32_64" = yes; then
7477	if test $tk_aqua = no; then
7478	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 64-bit X11" >&5
7479printf %s "checking for 64-bit X11... " >&6; }
7480if test ${tcl_cv_lib_x11_64+y}
7481then :
7482  printf %s "(cached) " >&6
7483else $as_nop
7484
7485		for v in CFLAGS CPPFLAGS LDFLAGS; do
7486		    eval 'hold_'$v'="$'$v'";'$v'="`echo "$'$v' "|sed -e "s/-arch ppc / /g" -e "s/-arch i386 / /g"`"'
7487		done
7488		CPPFLAGS="$CPPFLAGS -I/usr/X11R6/include"
7489		LDFLAGS="$LDFLAGS -L/usr/X11R6/lib -lX11"
7490		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7491/* end confdefs.h.  */
7492#include <X11/Xlib.h>
7493int
7494main (void)
7495{
7496XrmInitialize();
7497  ;
7498  return 0;
7499}
7500_ACEOF
7501if ac_fn_c_try_link "$LINENO"
7502then :
7503  tcl_cv_lib_x11_64=yes
7504else $as_nop
7505  tcl_cv_lib_x11_64=no
7506fi
7507rm -f core conftest.err conftest.$ac_objext conftest.beam \
7508    conftest$ac_exeext conftest.$ac_ext
7509		for v in CFLAGS CPPFLAGS LDFLAGS; do
7510		    eval $v'="$hold_'$v'"'
7511		done
7512fi
7513{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_lib_x11_64" >&5
7514printf "%s\n" "$tcl_cv_lib_x11_64" >&6; }
7515	fi
7516	# remove 64-bit arch flags from CFLAGS et al. for combined 32 & 64 bit
7517	# fat builds if configuration does not support 64-bit.
7518	if test "$tcl_cv_lib_x11_64" = no; then
7519	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: Removing 64-bit architectures from compiler & linker flags" >&5
7520printf "%s\n" "$as_me: Removing 64-bit architectures from compiler & linker flags" >&6;}
7521	    for v in CFLAGS CPPFLAGS LDFLAGS; do
7522		eval $v'="`echo "$'$v' "|sed -e "s/-arch ppc64 / /g" -e "s/-arch x86_64 / /g"`"'
7523	    done
7524	fi
7525    fi
7526    if test $tk_aqua = no; then
7527	# check if weak linking whole libraries is possible.
7528	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if ld accepts -weak-l flag" >&5
7529printf %s "checking if ld accepts -weak-l flag... " >&6; }
7530if test ${tcl_cv_ld_weak_l+y}
7531then :
7532  printf %s "(cached) " >&6
7533else $as_nop
7534
7535	    hold_ldflags=$LDFLAGS
7536	    LDFLAGS="$LDFLAGS -Wl,-weak-lm"
7537	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7538/* end confdefs.h.  */
7539#include <math.h>
7540int
7541main (void)
7542{
7543double f = sin(1.0);
7544  ;
7545  return 0;
7546}
7547_ACEOF
7548if ac_fn_c_try_link "$LINENO"
7549then :
7550  tcl_cv_ld_weak_l=yes
7551else $as_nop
7552  tcl_cv_ld_weak_l=no
7553fi
7554rm -f core conftest.err conftest.$ac_objext conftest.beam \
7555    conftest$ac_exeext conftest.$ac_ext
7556	    LDFLAGS=$hold_ldflags
7557fi
7558{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_weak_l" >&5
7559printf "%s\n" "$tcl_cv_ld_weak_l" >&6; }
7560    fi
7561    ac_fn_c_check_header_compile "$LINENO" "AvailabilityMacros.h" "ac_cv_header_AvailabilityMacros_h" "$ac_includes_default"
7562if test "x$ac_cv_header_AvailabilityMacros_h" = xyes
7563then :
7564  printf "%s\n" "#define HAVE_AVAILABILITYMACROS_H 1" >>confdefs.h
7565
7566fi
7567
7568    if test "$ac_cv_header_AvailabilityMacros_h" = yes; then
7569	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if weak import is available" >&5
7570printf %s "checking if weak import is available... " >&6; }
7571if test ${tcl_cv_cc_weak_import+y}
7572then :
7573  printf %s "(cached) " >&6
7574else $as_nop
7575
7576	    hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -Werror"
7577	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7578/* end confdefs.h.  */
7579
7580		    #ifdef __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__
7581		    #if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1020
7582		    #error __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1020
7583		    #endif
7584		    #elif MAC_OS_X_VERSION_MIN_REQUIRED < 1020
7585		    #error MAC_OS_X_VERSION_MIN_REQUIRED < 1020
7586		    #endif
7587		    int rand(void) __attribute__((weak_import));
7588
7589int
7590main (void)
7591{
7592rand();
7593  ;
7594  return 0;
7595}
7596_ACEOF
7597if ac_fn_c_try_link "$LINENO"
7598then :
7599  tcl_cv_cc_weak_import=yes
7600else $as_nop
7601  tcl_cv_cc_weak_import=no
7602fi
7603rm -f core conftest.err conftest.$ac_objext conftest.beam \
7604    conftest$ac_exeext conftest.$ac_ext
7605	    CFLAGS=$hold_cflags
7606fi
7607{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_weak_import" >&5
7608printf "%s\n" "$tcl_cv_cc_weak_import" >&6; }
7609	if test $tcl_cv_cc_weak_import = yes; then
7610
7611printf "%s\n" "#define HAVE_WEAK_IMPORT 1" >>confdefs.h
7612
7613	fi
7614	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if Darwin SUSv3 extensions are available" >&5
7615printf %s "checking if Darwin SUSv3 extensions are available... " >&6; }
7616if test ${tcl_cv_cc_darwin_c_source+y}
7617then :
7618  printf %s "(cached) " >&6
7619else $as_nop
7620
7621	    hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -Werror"
7622	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7623/* end confdefs.h.  */
7624
7625		    #ifdef __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__
7626		    #if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1050
7627		    #error __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1050
7628		    #endif
7629		    #elif MAC_OS_X_VERSION_MIN_REQUIRED < 1050
7630		    #error MAC_OS_X_VERSION_MIN_REQUIRED < 1050
7631		    #endif
7632		    #define _DARWIN_C_SOURCE 1
7633		    #include <sys/cdefs.h>
7634
7635int
7636main (void)
7637{
7638
7639  ;
7640  return 0;
7641}
7642_ACEOF
7643if ac_fn_c_try_compile "$LINENO"
7644then :
7645  tcl_cv_cc_darwin_c_source=yes
7646else $as_nop
7647  tcl_cv_cc_darwin_c_source=no
7648fi
7649rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7650	    CFLAGS=$hold_cflags
7651fi
7652{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_darwin_c_source" >&5
7653printf "%s\n" "$tcl_cv_cc_darwin_c_source" >&6; }
7654	if test $tcl_cv_cc_darwin_c_source = yes; then
7655
7656printf "%s\n" "#define _DARWIN_C_SOURCE 1" >>confdefs.h
7657
7658	fi
7659    fi
7660else
7661    tk_aqua=no
7662fi
7663
7664if test $tk_aqua = yes; then
7665
7666printf "%s\n" "#define MAC_OSX_TK 1" >>confdefs.h
7667
7668    LIBS="$LIBS -framework Cocoa -framework Carbon -framework IOKit -framework QuartzCore -framework Security"
7669    if test -d /System/Library/Frameworks/UserNotifications.framework; then
7670        LIBS="$LIBS -framework UserNotifications"
7671    fi
7672    EXTRA_CC_SWITCHES='-std=gnu99 -x objective-c'
7673    TK_WINDOWINGSYSTEM=AQUA
7674    if test -n "${enable_symbols}" -a "${enable_symbols}" != no; then
7675
7676printf "%s\n" "#define TK_MAC_DEBUG 1" >>confdefs.h
7677
7678    fi
7679else
7680    #--------------------------------------------------------------------
7681    #	Locate the X11 header files and the X11 library archive.  Try
7682    #	the ac_path_x macro first, but if it doesn't find the X stuff
7683    #	(e.g. because there's no xmkmf program) then check through
7684    #	a list of possible directories.  Under some conditions the
7685    #	autoconf macro will return an include directory that contains
7686    #	no include files, so double-check its result just to be safe.
7687    #--------------------------------------------------------------------
7688
7689
7690    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for X" >&5
7691printf %s "checking for X... " >&6; }
7692
7693
7694# Check whether --with-x was given.
7695if test ${with_x+y}
7696then :
7697  withval=$with_x;
7698fi
7699
7700# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
7701if test "x$with_x" = xno; then
7702  # The user explicitly disabled X.
7703  have_x=disabled
7704else
7705  case $x_includes,$x_libraries in #(
7706    *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
7707    *,NONE | NONE,*) if test ${ac_cv_have_x+y}
7708then :
7709  printf %s "(cached) " >&6
7710else $as_nop
7711  # One or both of the vars are not set, and there is no cached value.
7712ac_x_includes=no
7713ac_x_libraries=no
7714# Do we need to do anything special at all?
7715ac_save_LIBS=$LIBS
7716LIBS="-lX11 $LIBS"
7717cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7718/* end confdefs.h.  */
7719#include <X11/Xlib.h>
7720int
7721main (void)
7722{
7723XrmInitialize ()
7724  ;
7725  return 0;
7726}
7727_ACEOF
7728if ac_fn_c_try_link "$LINENO"
7729then :
7730  # We can compile and link X programs with no special options.
7731  ac_x_includes=
7732  ac_x_libraries=
7733fi
7734rm -f core conftest.err conftest.$ac_objext conftest.beam \
7735    conftest$ac_exeext conftest.$ac_ext
7736LIBS="$ac_save_LIBS"
7737# If that didn't work, only try xmkmf and file system searches
7738# for native compilation.
7739if test x"$ac_x_includes" = xno && test "$cross_compiling" = no
7740then :
7741  rm -f -r conftest.dir
7742if mkdir conftest.dir; then
7743  cd conftest.dir
7744  cat >Imakefile <<'_ACEOF'
7745incroot:
7746	@echo incroot='${INCROOT}'
7747usrlibdir:
7748	@echo usrlibdir='${USRLIBDIR}'
7749libdir:
7750	@echo libdir='${LIBDIR}'
7751_ACEOF
7752  if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
7753    # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
7754    for ac_var in incroot usrlibdir libdir; do
7755      eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
7756    done
7757    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
7758    for ac_extension in a so sl dylib la dll; do
7759      if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
7760	 test -f "$ac_im_libdir/libX11.$ac_extension"; then
7761	ac_im_usrlibdir=$ac_im_libdir; break
7762      fi
7763    done
7764    # Screen out bogus values from the imake configuration.  They are
7765    # bogus both because they are the default anyway, and because
7766    # using them would break gcc on systems where it needs fixed includes.
7767    case $ac_im_incroot in
7768	/usr/include) ac_x_includes= ;;
7769	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
7770    esac
7771    case $ac_im_usrlibdir in
7772	/usr/lib | /usr/lib64 | /lib | /lib64) ;;
7773	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
7774    esac
7775  fi
7776  cd ..
7777  rm -f -r conftest.dir
7778fi
7779
7780  # Standard set of common directories for X headers.
7781# Check X11 before X11Rn because it is often a symlink to the current release.
7782ac_x_header_dirs='
7783/usr/X11/include
7784/usr/X11R7/include
7785/usr/X11R6/include
7786/usr/X11R5/include
7787/usr/X11R4/include
7788
7789/usr/include/X11
7790/usr/include/X11R7
7791/usr/include/X11R6
7792/usr/include/X11R5
7793/usr/include/X11R4
7794
7795/usr/local/X11/include
7796/usr/local/X11R7/include
7797/usr/local/X11R6/include
7798/usr/local/X11R5/include
7799/usr/local/X11R4/include
7800
7801/usr/local/include/X11
7802/usr/local/include/X11R7
7803/usr/local/include/X11R6
7804/usr/local/include/X11R5
7805/usr/local/include/X11R4
7806
7807/opt/X11/include
7808
7809/usr/X386/include
7810/usr/x386/include
7811/usr/XFree86/include/X11
7812
7813/usr/include
7814/usr/local/include
7815/usr/unsupported/include
7816/usr/athena/include
7817/usr/local/x11r5/include
7818/usr/lpp/Xamples/include
7819
7820/usr/openwin/include
7821/usr/openwin/share/include'
7822
7823if test "$ac_x_includes" = no; then
7824  # Guess where to find include files, by looking for Xlib.h.
7825  # First, try using that file with no special directory specified.
7826  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7827/* end confdefs.h.  */
7828#include <X11/Xlib.h>
7829_ACEOF
7830if ac_fn_c_try_cpp "$LINENO"
7831then :
7832  # We can compile using X headers with no special include directory.
7833ac_x_includes=
7834else $as_nop
7835  for ac_dir in $ac_x_header_dirs; do
7836  if test -r "$ac_dir/X11/Xlib.h"; then
7837    ac_x_includes=$ac_dir
7838    break
7839  fi
7840done
7841fi
7842rm -f conftest.err conftest.i conftest.$ac_ext
7843fi # $ac_x_includes = no
7844
7845if test "$ac_x_libraries" = no; then
7846  # Check for the libraries.
7847  # See if we find them without any special options.
7848  # Don't add to $LIBS permanently.
7849  ac_save_LIBS=$LIBS
7850  LIBS="-lX11 $LIBS"
7851  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7852/* end confdefs.h.  */
7853#include <X11/Xlib.h>
7854int
7855main (void)
7856{
7857XrmInitialize ()
7858  ;
7859  return 0;
7860}
7861_ACEOF
7862if ac_fn_c_try_link "$LINENO"
7863then :
7864  LIBS=$ac_save_LIBS
7865# We can link X programs with no special library path.
7866ac_x_libraries=
7867else $as_nop
7868  LIBS=$ac_save_LIBS
7869for ac_dir in `printf "%s\n" "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
7870do
7871  # Don't even attempt the hair of trying to link an X program!
7872  for ac_extension in a so sl dylib la dll; do
7873    if test -r "$ac_dir/libX11.$ac_extension"; then
7874      ac_x_libraries=$ac_dir
7875      break 2
7876    fi
7877  done
7878done
7879fi
7880rm -f core conftest.err conftest.$ac_objext conftest.beam \
7881    conftest$ac_exeext conftest.$ac_ext
7882fi # $ac_x_libraries = no
7883
7884fi
7885# Record the results.
7886case $ac_x_includes,$ac_x_libraries in #(
7887  no,* | *,no | *\'*) :
7888    # Didn't find X, or a directory has "'" in its name.
7889    ac_cv_have_x="have_x=no" ;; #(
7890  *) :
7891    # Record where we found X for the cache.
7892    ac_cv_have_x="have_x=yes\
7893	ac_x_includes='$ac_x_includes'\
7894	ac_x_libraries='$ac_x_libraries'" ;;
7895esac
7896fi
7897;; #(
7898    *) have_x=yes;;
7899  esac
7900  eval "$ac_cv_have_x"
7901fi # $with_x != no
7902
7903if test "$have_x" != yes; then
7904  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
7905printf "%s\n" "$have_x" >&6; }
7906  no_x=yes
7907else
7908  # If each of the values was on the command line, it overrides each guess.
7909  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
7910  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
7911  # Update the cache value to reflect the command line values.
7912  ac_cv_have_x="have_x=yes\
7913	ac_x_includes='$x_includes'\
7914	ac_x_libraries='$x_libraries'"
7915  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
7916printf "%s\n" "libraries $x_libraries, headers $x_includes" >&6; }
7917fi
7918
7919    not_really_there=""
7920    if test "$no_x" = ""; then
7921	if test "$x_includes" = ""; then
7922	    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7923/* end confdefs.h.  */
7924#include <X11/Xlib.h>
7925_ACEOF
7926if ac_fn_c_try_cpp "$LINENO"
7927then :
7928
7929else $as_nop
7930  not_really_there="yes"
7931fi
7932rm -f conftest.err conftest.i conftest.$ac_ext
7933	else
7934	    if test ! -r $x_includes/X11/Xlib.h; then
7935		not_really_there="yes"
7936	    fi
7937	fi
7938    fi
7939    if test "$no_x" = "yes" -o "$not_really_there" = "yes"; then
7940	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for X11 header files" >&5
7941printf %s "checking for X11 header files... " >&6; }
7942	found_xincludes="no"
7943	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7944/* end confdefs.h.  */
7945#include <X11/Xlib.h>
7946_ACEOF
7947if ac_fn_c_try_cpp "$LINENO"
7948then :
7949  found_xincludes="yes"
7950else $as_nop
7951  found_xincludes="no"
7952fi
7953rm -f conftest.err conftest.i conftest.$ac_ext
7954	if test "$found_xincludes" = "no"; then
7955	    dirs="/usr/unsupported/include /usr/local/include /usr/X386/include /usr/X11R6/include /usr/X11R5/include /usr/include/X11R5 /usr/include/X11R4 /usr/openwin/include /usr/X11/include /usr/sww/include"
7956	    for i in $dirs ; do
7957		if test -r $i/X11/Xlib.h; then
7958		    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $i" >&5
7959printf "%s\n" "$i" >&6; }
7960		    XINCLUDES=" -I$i"
7961		    found_xincludes="yes"
7962		    break
7963		fi
7964	    done
7965	fi
7966    else
7967	if test "$x_includes" != ""; then
7968	    XINCLUDES="-I$x_includes"
7969	    found_xincludes="yes"
7970	fi
7971    fi
7972    if test "$found_xincludes" = "no"; then
7973	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: couldn't find any!" >&5
7974printf "%s\n" "couldn't find any!" >&6; }
7975    fi
7976
7977    if test "$no_x" = yes; then
7978	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for X11 libraries" >&5
7979printf %s "checking for X11 libraries... " >&6; }
7980	XLIBSW=nope
7981	dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib"
7982	for i in $dirs ; do
7983	    if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl -o -r $i/libX11.dylib; then
7984		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $i" >&5
7985printf "%s\n" "$i" >&6; }
7986		XLIBSW="-L$i -lX11"
7987		x_libraries="$i"
7988		break
7989	    fi
7990	done
7991    else
7992	if test "$x_libraries" = ""; then
7993	    XLIBSW=-lX11
7994	else
7995	    XLIBSW="-L$x_libraries -lX11"
7996	fi
7997    fi
7998    if test "$XLIBSW" = nope ; then
7999	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for XCreateWindow in -lXwindow" >&5
8000printf %s "checking for XCreateWindow in -lXwindow... " >&6; }
8001if test ${ac_cv_lib_Xwindow_XCreateWindow+y}
8002then :
8003  printf %s "(cached) " >&6
8004else $as_nop
8005  ac_check_lib_save_LIBS=$LIBS
8006LIBS="-lXwindow  $LIBS"
8007cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8008/* end confdefs.h.  */
8009
8010/* Override any GCC internal prototype to avoid an error.
8011   Use char because int might match the return type of a GCC
8012   builtin and then its argument prototype would still apply.  */
8013char XCreateWindow ();
8014int
8015main (void)
8016{
8017return XCreateWindow ();
8018  ;
8019  return 0;
8020}
8021_ACEOF
8022if ac_fn_c_try_link "$LINENO"
8023then :
8024  ac_cv_lib_Xwindow_XCreateWindow=yes
8025else $as_nop
8026  ac_cv_lib_Xwindow_XCreateWindow=no
8027fi
8028rm -f core conftest.err conftest.$ac_objext conftest.beam \
8029    conftest$ac_exeext conftest.$ac_ext
8030LIBS=$ac_check_lib_save_LIBS
8031fi
8032{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xwindow_XCreateWindow" >&5
8033printf "%s\n" "$ac_cv_lib_Xwindow_XCreateWindow" >&6; }
8034if test "x$ac_cv_lib_Xwindow_XCreateWindow" = xyes
8035then :
8036  XLIBSW=-lXwindow
8037fi
8038
8039    fi
8040    if test "$XLIBSW" = nope ; then
8041	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: could not find any!  Using -lX11." >&5
8042printf "%s\n" "could not find any!  Using -lX11." >&6; }
8043	XLIBSW=-lX11
8044    fi
8045
8046    TK_WINDOWINGSYSTEM=X11
8047fi
8048
8049#--------------------------------------------------------------------
8050#	Various manipulations on the search path used at runtime to
8051#	find shared libraries:
8052#	1. If the X library binaries are in a non-standard directory,
8053#	   add the X library location into that search path.
8054#	2. On systems such as AIX and Ultrix that use "-L" as the
8055#	   search path option, colons cannot be used to separate
8056#	   directories from each other. Change colons to " -L".
8057#	3. Create two sets of search flags, one for use in cc lines
8058#	   and the other for when the linker is invoked directly.  In
8059#	   the second case, '-Wl,' must be stripped off and commas must
8060#	   be replaced by spaces.
8061#--------------------------------------------------------------------
8062
8063if test "x${x_libraries}" != "x"; then
8064  if test "x${x_libraries}" != "xNONE"; then
8065    LIB_RUNTIME_DIR="${LIB_RUNTIME_DIR}:${x_libraries}"
8066  fi
8067fi
8068if test "${TCL_LD_SEARCH_FLAGS}" = '-L${LIB_RUNTIME_DIR}'; then
8069    LIB_RUNTIME_DIR=`echo ${LIB_RUNTIME_DIR} |sed -e 's/:/ -L/g'`
8070fi
8071
8072#--------------------------------------------------------------------
8073#	Check for the existence of various libraries.  The order here
8074#	is important, so that then end up in the right order in the
8075#	command line generated by make.  The -lsocket and -lnsl libraries
8076#	require a couple of special tricks:
8077#	1. Use "connect" and "accept" to check for -lsocket, and
8078#	   "gethostbyname" to check for -lnsl.
8079#	2. Use each function name only once:  can't redo a check because
8080#	   autoconf caches the results of the last check and won't redo it.
8081#	3. Use -lnsl and -lsocket only if they supply procedures that
8082#	   aren't already present in the normal libraries.  This is because
8083#	   IRIX 5.2 has libraries, but they aren't needed and they're
8084#	   bogus:  they goof up name resolution if used.
8085#	4. On some SVR4 systems, can't use -lsocket without -lnsl too.
8086#	   To get around this problem, check for both libraries together
8087#	   if -lsocket doesn't work by itself.
8088#--------------------------------------------------------------------
8089
8090if test $tk_aqua = no; then
8091    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
8092printf %s "checking for main in -lXbsd... " >&6; }
8093if test ${ac_cv_lib_Xbsd_main+y}
8094then :
8095  printf %s "(cached) " >&6
8096else $as_nop
8097  ac_check_lib_save_LIBS=$LIBS
8098LIBS="-lXbsd  $LIBS"
8099cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8100/* end confdefs.h.  */
8101
8102
8103int
8104main (void)
8105{
8106return main ();
8107  ;
8108  return 0;
8109}
8110_ACEOF
8111if ac_fn_c_try_link "$LINENO"
8112then :
8113  ac_cv_lib_Xbsd_main=yes
8114else $as_nop
8115  ac_cv_lib_Xbsd_main=no
8116fi
8117rm -f core conftest.err conftest.$ac_objext conftest.beam \
8118    conftest$ac_exeext conftest.$ac_ext
8119LIBS=$ac_check_lib_save_LIBS
8120fi
8121{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
8122printf "%s\n" "$ac_cv_lib_Xbsd_main" >&6; }
8123if test "x$ac_cv_lib_Xbsd_main" = xyes
8124then :
8125  LIBS="$LIBS -lXbsd"
8126fi
8127
8128fi
8129
8130#--------------------------------------------------------------------
8131# One more check related to the X libraries.  The standard releases
8132# of Ultrix don't support the "xauth" mechanism, so send won't work
8133# unless TK_NO_SECURITY is defined.  However, there are usually copies
8134# of the MIT X server available as well, which do support xauth.
8135# Check for the MIT stuff and use it if it exists.
8136#
8137# Note: can't use ac_check_lib macro (at least, not in Autoconf 2.1)
8138# because it can't deal with the "-" in the library name.
8139#--------------------------------------------------------------------
8140
8141if test -d /usr/include/mit -a $tk_aqua = no; then
8142    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking MIT X libraries" >&5
8143printf %s "checking MIT X libraries... " >&6; }
8144    tk_oldCFlags=$CFLAGS
8145    CFLAGS="$CFLAGS -I/usr/include/mit"
8146    tk_oldLibs=$LIBS
8147    LIBS="$LIBS -lX11-mit"
8148    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8149/* end confdefs.h.  */
8150
8151	#include <X11/Xlib.h>
8152
8153int
8154main (void)
8155{
8156
8157	XOpenDisplay(0);
8158
8159  ;
8160  return 0;
8161}
8162_ACEOF
8163if ac_fn_c_try_link "$LINENO"
8164then :
8165
8166	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8167printf "%s\n" "yes" >&6; }
8168	XLIBSW="-lX11-mit"
8169	XINCLUDES="-I/usr/include/mit"
8170
8171else $as_nop
8172  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8173printf "%s\n" "no" >&6; }
8174fi
8175rm -f core conftest.err conftest.$ac_objext conftest.beam \
8176    conftest$ac_exeext conftest.$ac_ext
8177    CFLAGS=$tk_oldCFlags
8178    LIBS=$tk_oldLibs
8179fi
8180
8181#--------------------------------------------------------------------
8182#	Check for freetype / fontconfig / Xft support.
8183#--------------------------------------------------------------------
8184
8185if test $tk_aqua = no; then
8186    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to use xft" >&5
8187printf %s "checking whether to use xft... " >&6; }
8188    # Check whether --enable-xft was given.
8189if test ${enable_xft+y}
8190then :
8191  enableval=$enable_xft; enable_xft=$enableval
8192else $as_nop
8193  enable_xft="default"
8194fi
8195
8196    XFT_CFLAGS=""
8197    XFT_LIBS=""
8198    if test "$enable_xft" = "no" ; then
8199	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_xft" >&5
8200printf "%s\n" "$enable_xft" >&6; }
8201    else
8202	found_xft="yes"
8203			XFT_CFLAGS=`xft-config --cflags 2>/dev/null` || found_xft="no"
8204	XFT_LIBS=`xft-config --libs 2>/dev/null` || found_xft="no"
8205	if test "$found_xft" = "no" ; then
8206	    found_xft=yes
8207	    XFT_CFLAGS=`pkg-config --cflags xft fontconfig 2>/dev/null` || found_xft="no"
8208	    XFT_LIBS=`pkg-config --libs xft fontconfig 2>/dev/null` || found_xft="no"
8209	fi
8210	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $found_xft" >&5
8211printf "%s\n" "$found_xft" >&6; }
8212		if test "$found_xft" = "yes" ; then
8213	    tk_oldCFlags=$CFLAGS
8214	    CFLAGS="$CFLAGS $XINCLUDES $XFT_CFLAGS"
8215	    tk_oldLibs=$LIBS
8216	    LIBS="$tk_oldLIBS $XFT_LIBS $XLIBSW"
8217	    ac_fn_c_check_header_compile "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "#include <X11/Xlib.h>
8218"
8219if test "x$ac_cv_header_X11_Xft_Xft_h" = xyes
8220then :
8221
8222else $as_nop
8223
8224		found_xft=no
8225
8226fi
8227
8228	    CFLAGS=$tk_oldCFlags
8229	    LIBS=$tk_oldLibs
8230	fi
8231		if test "$found_xft" = "yes" ; then
8232	    tk_oldCFlags=$CFLAGS
8233	    CFLAGS="$CFLAGS $XINCLUDES $XFT_CFLAGS"
8234	    tk_oldLibs=$LIBS
8235	    LIBS="$tk_oldLIBS $XFT_LIBS $XLIBSW"
8236	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
8237printf %s "checking for XftFontOpen in -lXft... " >&6; }
8238if test ${ac_cv_lib_Xft_XftFontOpen+y}
8239then :
8240  printf %s "(cached) " >&6
8241else $as_nop
8242  ac_check_lib_save_LIBS=$LIBS
8243LIBS="-lXft  $LIBS"
8244cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8245/* end confdefs.h.  */
8246
8247/* Override any GCC internal prototype to avoid an error.
8248   Use char because int might match the return type of a GCC
8249   builtin and then its argument prototype would still apply.  */
8250char XftFontOpen ();
8251int
8252main (void)
8253{
8254return XftFontOpen ();
8255  ;
8256  return 0;
8257}
8258_ACEOF
8259if ac_fn_c_try_link "$LINENO"
8260then :
8261  ac_cv_lib_Xft_XftFontOpen=yes
8262else $as_nop
8263  ac_cv_lib_Xft_XftFontOpen=no
8264fi
8265rm -f core conftest.err conftest.$ac_objext conftest.beam \
8266    conftest$ac_exeext conftest.$ac_ext
8267LIBS=$ac_check_lib_save_LIBS
8268fi
8269{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
8270printf "%s\n" "$ac_cv_lib_Xft_XftFontOpen" >&6; }
8271if test "x$ac_cv_lib_Xft_XftFontOpen" = xyes
8272then :
8273  printf "%s\n" "#define HAVE_LIBXFT 1" >>confdefs.h
8274
8275  LIBS="-lXft $LIBS"
8276
8277else $as_nop
8278
8279		found_xft=no
8280
8281fi
8282
8283	    CFLAGS=$tk_oldCFlags
8284	    LIBS=$tk_oldLibs
8285	fi
8286		if test "$found_xft" = "yes" ; then
8287	    tk_oldCFlags=$CFLAGS
8288	    CFLAGS="$CFLAGS $XINCLUDES $XFT_CFLAGS"
8289	    tk_oldLibs=$LIBS
8290	    LIBS="$tk_oldLIBS $XFT_LIBS $XLIBSW -lfontconfig"
8291	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for FcFontSort in -lfontconfig" >&5
8292printf %s "checking for FcFontSort in -lfontconfig... " >&6; }
8293if test ${ac_cv_lib_fontconfig_FcFontSort+y}
8294then :
8295  printf %s "(cached) " >&6
8296else $as_nop
8297  ac_check_lib_save_LIBS=$LIBS
8298LIBS="-lfontconfig  $LIBS"
8299cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8300/* end confdefs.h.  */
8301
8302/* Override any GCC internal prototype to avoid an error.
8303   Use char because int might match the return type of a GCC
8304   builtin and then its argument prototype would still apply.  */
8305char FcFontSort ();
8306int
8307main (void)
8308{
8309return FcFontSort ();
8310  ;
8311  return 0;
8312}
8313_ACEOF
8314if ac_fn_c_try_link "$LINENO"
8315then :
8316  ac_cv_lib_fontconfig_FcFontSort=yes
8317else $as_nop
8318  ac_cv_lib_fontconfig_FcFontSort=no
8319fi
8320rm -f core conftest.err conftest.$ac_objext conftest.beam \
8321    conftest$ac_exeext conftest.$ac_ext
8322LIBS=$ac_check_lib_save_LIBS
8323fi
8324{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fontconfig_FcFontSort" >&5
8325printf "%s\n" "$ac_cv_lib_fontconfig_FcFontSort" >&6; }
8326if test "x$ac_cv_lib_fontconfig_FcFontSort" = xyes
8327then :
8328
8329		XFT_LIBS="$XFT_LIBS -lfontconfig"
8330
8331fi
8332
8333	    CFLAGS=$tk_oldCFlags
8334	    LIBS=$tk_oldLibs
8335	fi
8336		if test "$found_xft" = "no" ; then
8337	    if test "$enable_xft" = "yes" ; then
8338		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Can't find xft configuration, or xft is unusable" >&5
8339printf "%s\n" "$as_me: WARNING: Can't find xft configuration, or xft is unusable" >&2;}
8340	    fi
8341	    enable_xft=no
8342	    XFT_CFLAGS=""
8343	    XFT_LIBS=""
8344	else
8345            enable_xft=yes
8346	fi
8347    fi
8348    if test $enable_xft = "yes" ; then
8349	UNIX_FONT_OBJS=tkUnixRFont.o
8350
8351printf "%s\n" "#define HAVE_XFT 1" >>confdefs.h
8352
8353    else
8354	UNIX_FONT_OBJS=tkUnixFont.o
8355    fi
8356
8357
8358
8359fi
8360
8361#--------------------------------------------------------------------
8362# XXX Do this last.
8363# It might modify XLIBSW which could affect other tests.
8364#
8365# Check whether the header and library for the XScreenSaver
8366# extension are available, and set HAVE_XSS if so.
8367# XScreenSaver is needed for Tk_GetUserInactiveTime().
8368#--------------------------------------------------------------------
8369
8370if test $tk_aqua = no; then
8371    tk_oldCFlags=$CFLAGS
8372    CFLAGS="$CFLAGS $XINCLUDES"
8373    tk_oldLibs=$LIBS
8374    LIBS="$tk_oldLibs $XLIBSW"
8375    xss_header_found=no
8376    xss_lib_found=no
8377    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to try to use XScreenSaver" >&5
8378printf %s "checking whether to try to use XScreenSaver... " >&6; }
8379    # Check whether --enable-xss was given.
8380if test ${enable_xss+y}
8381then :
8382  enableval=$enable_xss; enable_xss=$enableval
8383else $as_nop
8384  enable_xss=yes
8385fi
8386
8387    if test "$enable_xss" = "no" ; then
8388	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_xss" >&5
8389printf "%s\n" "$enable_xss" >&6; }
8390    else
8391	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_xss" >&5
8392printf "%s\n" "$enable_xss" >&6; }
8393	ac_fn_c_check_header_compile "$LINENO" "X11/extensions/scrnsaver.h" "ac_cv_header_X11_extensions_scrnsaver_h" "#include <X11/Xlib.h>
8394"
8395if test "x$ac_cv_header_X11_extensions_scrnsaver_h" = xyes
8396then :
8397
8398	    xss_header_found=yes
8399
8400fi
8401
8402	ac_fn_c_check_func "$LINENO" "XScreenSaverQueryInfo" "ac_cv_func_XScreenSaverQueryInfo"
8403if test "x$ac_cv_func_XScreenSaverQueryInfo" = xyes
8404then :
8405
8406else $as_nop
8407
8408	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for XScreenSaverQueryInfo in -lXext" >&5
8409printf %s "checking for XScreenSaverQueryInfo in -lXext... " >&6; }
8410if test ${ac_cv_lib_Xext_XScreenSaverQueryInfo+y}
8411then :
8412  printf %s "(cached) " >&6
8413else $as_nop
8414  ac_check_lib_save_LIBS=$LIBS
8415LIBS="-lXext  $LIBS"
8416cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8417/* end confdefs.h.  */
8418
8419/* Override any GCC internal prototype to avoid an error.
8420   Use char because int might match the return type of a GCC
8421   builtin and then its argument prototype would still apply.  */
8422char XScreenSaverQueryInfo ();
8423int
8424main (void)
8425{
8426return XScreenSaverQueryInfo ();
8427  ;
8428  return 0;
8429}
8430_ACEOF
8431if ac_fn_c_try_link "$LINENO"
8432then :
8433  ac_cv_lib_Xext_XScreenSaverQueryInfo=yes
8434else $as_nop
8435  ac_cv_lib_Xext_XScreenSaverQueryInfo=no
8436fi
8437rm -f core conftest.err conftest.$ac_objext conftest.beam \
8438    conftest$ac_exeext conftest.$ac_ext
8439LIBS=$ac_check_lib_save_LIBS
8440fi
8441{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XScreenSaverQueryInfo" >&5
8442printf "%s\n" "$ac_cv_lib_Xext_XScreenSaverQueryInfo" >&6; }
8443if test "x$ac_cv_lib_Xext_XScreenSaverQueryInfo" = xyes
8444then :
8445
8446		XLIBSW="$XLIBSW -lXext"
8447		xss_lib_found=yes
8448
8449else $as_nop
8450
8451		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for XScreenSaverQueryInfo in -lXss" >&5
8452printf %s "checking for XScreenSaverQueryInfo in -lXss... " >&6; }
8453if test ${ac_cv_lib_Xss_XScreenSaverQueryInfo+y}
8454then :
8455  printf %s "(cached) " >&6
8456else $as_nop
8457  ac_check_lib_save_LIBS=$LIBS
8458LIBS="-lXss -lXext $LIBS"
8459cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8460/* end confdefs.h.  */
8461
8462/* Override any GCC internal prototype to avoid an error.
8463   Use char because int might match the return type of a GCC
8464   builtin and then its argument prototype would still apply.  */
8465char XScreenSaverQueryInfo ();
8466int
8467main (void)
8468{
8469return XScreenSaverQueryInfo ();
8470  ;
8471  return 0;
8472}
8473_ACEOF
8474if ac_fn_c_try_link "$LINENO"
8475then :
8476  ac_cv_lib_Xss_XScreenSaverQueryInfo=yes
8477else $as_nop
8478  ac_cv_lib_Xss_XScreenSaverQueryInfo=no
8479fi
8480rm -f core conftest.err conftest.$ac_objext conftest.beam \
8481    conftest$ac_exeext conftest.$ac_ext
8482LIBS=$ac_check_lib_save_LIBS
8483fi
8484{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xss_XScreenSaverQueryInfo" >&5
8485printf "%s\n" "$ac_cv_lib_Xss_XScreenSaverQueryInfo" >&6; }
8486if test "x$ac_cv_lib_Xss_XScreenSaverQueryInfo" = xyes
8487then :
8488
8489		    if test "$tcl_cv_ld_weak_l" = yes; then
8490			# On Darwin, weak link libXss if possible,
8491			# as it is only available on Tiger or later.
8492			XLIBSW="$XLIBSW -Wl,-weak-lXss -lXext"
8493		    else
8494			XLIBSW="$XLIBSW -lXss -lXext"
8495		    fi
8496		    xss_lib_found=yes
8497
8498fi
8499
8500
8501fi
8502
8503
8504fi
8505
8506    fi
8507    if test $enable_xss = yes -a $xss_lib_found = yes -a $xss_header_found = yes; then
8508
8509printf "%s\n" "#define HAVE_XSS 1" >>confdefs.h
8510
8511    fi
8512    CFLAGS=$tk_oldCFlags
8513    LIBS=$tk_oldLibs
8514fi
8515
8516#--------------------------------------------------------------------
8517#	Figure out whether "char" is unsigned.  If so, set a
8518#	#define for __CHAR_UNSIGNED__.
8519#--------------------------------------------------------------------
8520
8521{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
8522printf %s "checking whether char is unsigned... " >&6; }
8523if test ${ac_cv_c_char_unsigned+y}
8524then :
8525  printf %s "(cached) " >&6
8526else $as_nop
8527  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8528/* end confdefs.h.  */
8529$ac_includes_default
8530int
8531main (void)
8532{
8533static int test_array [1 - 2 * !(((char) -1) < 0)];
8534test_array [0] = 0;
8535return test_array [0];
8536
8537  ;
8538  return 0;
8539}
8540_ACEOF
8541if ac_fn_c_try_compile "$LINENO"
8542then :
8543  ac_cv_c_char_unsigned=no
8544else $as_nop
8545  ac_cv_c_char_unsigned=yes
8546fi
8547rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8548fi
8549{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5
8550printf "%s\n" "$ac_cv_c_char_unsigned" >&6; }
8551if test $ac_cv_c_char_unsigned = yes; then
8552  printf "%s\n" "#define __CHAR_UNSIGNED__ 1" >>confdefs.h
8553
8554fi
8555
8556
8557#--------------------------------------------------------------------
8558#	The statements below define a collection of symbols related to
8559#	building libtk as a shared library instead of a static library.
8560#--------------------------------------------------------------------
8561
8562eval eval "TK_UNSHARED_LIB_SUFFIX=${UNSHARED_LIB_SUFFIX}"
8563eval eval "TK_SHARED_LIB_SUFFIX=${SHARED_LIB_SUFFIX}"
8564eval "TK_LIB_FILE_TCL8=libtk${LIB_SUFFIX}"
8565if test ${TCL_MAJOR_VERSION} = 8 ; then
8566eval "TK_LIB_FILE=libtk${LIB_SUFFIX}"
8567else
8568eval "TK_LIB_FILE=libtcl9tk${LIB_SUFFIX}"
8569fi
8570eval "TK_LIB_FILE_TCL9=libtcl9tk${LIB_SUFFIX}"
8571
8572# tkConfig.sh needs a version of the _LIB_SUFFIX that has been eval'ed
8573# since on some platforms TK_LIB_FILE contains shell escapes.
8574
8575eval "TK_LIB_FILE=${TK_LIB_FILE}"
8576
8577if test "${SHARED_BUILD}" = "1" -a "${SHLIB_SUFFIX}" != ""; then
8578    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \${TCL_STUB_LIB_SPEC}"
8579    TCL_STUB_FLAGS="-DUSE_TCL_STUBS"
8580fi
8581
8582test -z "$TK_LIBRARY" && TK_LIBRARY='$(prefix)/lib/tk$(VERSION)'
8583PRIVATE_INCLUDE_DIR='$(includedir)'
8584HTML_DIR='$(DISTDIR)/html'
8585TK_PKG_DIR='tk$(VERSION)'
8586TK_RSRC_FILE='tk$(VERSION).rsrc'
8587WISH_RSRC_FILE='wish$(VERSION).rsrc'
8588
8589# Note:  in the following variable, it's important to use the absolute
8590# path name of the Tcl directory rather than "..":  this is because
8591# AIX remembers this path and will attempt to use it at run-time to look
8592# up the Tcl library.
8593
8594if test "`uname -s`" = "Darwin" ; then
8595
8596    if test "`uname -s`" = "Darwin" ; then
8597	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to package libraries" >&5
8598printf %s "checking how to package libraries... " >&6; }
8599	# Check whether --enable-framework was given.
8600if test ${enable_framework+y}
8601then :
8602  enableval=$enable_framework; enable_framework=$enableval
8603else $as_nop
8604  enable_framework=no
8605fi
8606
8607	if test $enable_framework = yes; then
8608	    if test $SHARED_BUILD = 0; then
8609		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Frameworks can only be built if --enable-shared is yes" >&5
8610printf "%s\n" "$as_me: WARNING: Frameworks can only be built if --enable-shared is yes" >&2;}
8611		enable_framework=no
8612	    fi
8613	    if test $tcl_corefoundation = no; then
8614		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Frameworks can only be used when CoreFoundation is available" >&5
8615printf "%s\n" "$as_me: WARNING: Frameworks can only be used when CoreFoundation is available" >&2;}
8616		enable_framework=no
8617	    fi
8618	fi
8619	if test $enable_framework = yes; then
8620	    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: framework" >&5
8621printf "%s\n" "framework" >&6; }
8622	    FRAMEWORK_BUILD=1
8623	else
8624	    if test $SHARED_BUILD = 1; then
8625		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: shared library" >&5
8626printf "%s\n" "shared library" >&6; }
8627	    else
8628		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: static library" >&5
8629printf "%s\n" "static library" >&6; }
8630	    fi
8631	    FRAMEWORK_BUILD=0
8632	fi
8633    fi
8634
8635    TK_SHLIB_LD_EXTRAS="-compatibility_version ${TK_VERSION} -current_version ${TK_VERSION}`echo ${TK_PATCH_LEVEL} | awk '{match($0, "\\\.[0-9]+"); print substr($0,RSTART,RLENGTH)}'`"
8636    TK_SHLIB_LD_EXTRAS="${TK_SHLIB_LD_EXTRAS}"' -install_name "${DYLIB_INSTALL_DIR}/${TK_LIB_FILE}" -unexported_symbols_list $$(f=$(TK_LIB_FILE).E && nm -gp tkMacOSX*.o 2>/dev/null | awk "/^[0-9a-f]+ . \.objc/ {print \$$3}" > $$f && nm -gjp "$(TCL_BIN_DIR)"/$(TCL_STUB_LIB_FILE) | grep ^_[^_] >> $$f && echo $$f)'
8637    echo "$LDFLAGS " | grep -q -- '-prebind ' && TK_SHLIB_LD_EXTRAS="${TK_SHLIB_LD_EXTRAS}"' -seg1addr 0xb000000'
8638    TK_SHLIB_LD_EXTRAS="${TK_SHLIB_LD_EXTRAS}"' -sectcreate __TEXT __info_plist Tk-Info.plist'
8639    EXTRA_WISH_LIBS='-sectcreate __TEXT __info_plist Wish-Info.plist'
8640    EXTRA_WISH_LIBS=${EXTRA_WISH_LIBS}' -sectcreate __TEXT __credits_html Credits.html'
8641    if test "${SHARED_BUILD}" = "0"; then
8642	EXTRA_WISH_LIBS=${EXTRA_WISH_LIBS}' -ObjC'
8643    fi
8644    EXTRA_APP_CC_SWITCHES="${EXTRA_APP_CC_SWITCHES}"' -mdynamic-no-pic'
8645    ac_config_files="$ac_config_files Tk-Info.plist:../macosx/Tk-Info.plist.in Wish-Info.plist:../macosx/Wish-Info.plist.in Credits.html:../macosx/Credits.html.in"
8646
8647    for l in ${LOCALES}; do CFBUNDLELOCALIZATIONS="${CFBUNDLELOCALIZATIONS}<string>$l</string>"; done
8648    TK_YEAR="`date +%Y`"
8649fi
8650
8651if test "$FRAMEWORK_BUILD" = "1" ; then
8652
8653printf "%s\n" "#define TK_FRAMEWORK 1" >>confdefs.h
8654
8655    # Construct a fake local framework structure to make linking with
8656    # '-framework Tk' and running of tktest work
8657    ac_config_commands="$ac_config_commands Tk.framework"
8658
8659    LD_LIBRARY_PATH_VAR="DYLD_FRAMEWORK_PATH"
8660    if test "${libdir}" = '${exec_prefix}/lib'; then
8661        # override libdir default
8662        libdir="/Library/Frameworks"
8663    fi
8664    if test ${TCL_MAJOR_VERSION} = 8 ; then
8665	TK_LIB_FILE="Tk"
8666    else
8667	TK_LIB_FILE="Tk"
8668    fi
8669    TK_LIB_FILE_TCL8="Tk"
8670    TK_LIB_FILE_TCL9="Tk"
8671    TK_LIB_FLAG="-framework Tk"
8672    TK_BUILD_LIB_SPEC="-F`pwd | sed -e 's/ /\\\\ /g'` -framework Tk"
8673    TK_LIB_SPEC="-F${libdir} -framework Tk"
8674    libdir="${libdir}/Tk.framework/Versions/\${VERSION}"
8675    TK_LIBRARY="${libdir}/Resources/Scripts"
8676    TK_PKG_DIR="Resources/Scripts"
8677    TK_RSRC_FILE="Tk.rsrc"
8678    WISH_RSRC_FILE="Wish.rsrc"
8679    includedir="${libdir}/Headers"
8680    PRIVATE_INCLUDE_DIR="${libdir}/PrivateHeaders"
8681    HTML_DIR="${libdir}/Resources/Documentation/Reference/Tk"
8682    EXTRA_INSTALL="install-private-headers html-tk"
8683    EXTRA_BUILD_HTML='@ln -fs contents.htm "$(HTML_INSTALL_DIR)"/TkTOC.html'
8684    EXTRA_INSTALL_BINARIES='@echo "Installing Info.plist to $(LIB_INSTALL_DIR)/Resources/" && $(INSTALL_DATA_DIR) "$(LIB_INSTALL_DIR)/Resources" && $(INSTALL_DATA) Tk-Info.plist "$(LIB_INSTALL_DIR)/Resources/Info.plist"'
8685    EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && echo "Installing Credits.html to $(LIB_INSTALL_DIR)/Resources/" && $(INSTALL_DATA_DIR) "$(LIB_INSTALL_DIR)/Resources" && $(INSTALL_DATA) Credits.html "$(LIB_INSTALL_DIR)/Resources"'
8686    EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && echo "Installing license.terms to $(LIB_INSTALL_DIR)/Resources/" && $(INSTALL_DATA) "$(TOP_DIR)/license.terms" "$(LIB_INSTALL_DIR)/Resources"'
8687    if test $tk_aqua = yes; then
8688	EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && echo "Installing Images to $(LIB_INSTALL_DIR)/Resources/" && $(INSTALL_DATA_DIR) "$(LIB_INSTALL_DIR)/Resources" && for i in Tk.tiff Tk.icns; do $(INSTALL_DATA) "$(MAC_OSX_DIR)/$$i" "$(LIB_INSTALL_DIR)/Resources"; done'
8689	EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && echo "Installing wish$(VERSION) script to $(INSTALL_ROOT)/'"${bindir}"'/" && $(INSTALL_DATA_DIR) "$(INSTALL_ROOT)/'"${bindir}"'" && printf > "$(INSTALL_ROOT)/'"${bindir}"'/wish$(VERSION)" "#!/bin/sh\n\"\$$(dirname \$$0)'"`eval d="${bindir}"; echo "$d" | sed -e 's#/[^/][^/]*#/..#g'`"'$(bindir)/Wish\" \"\$$@\"" && chmod +x "$(INSTALL_ROOT)/'"${bindir}"'/wish$(VERSION)"'
8690	bindir="${libdir}/Resources/Wish.app/Contents/MacOS"
8691	EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && echo "Installing Info.plist to $(BIN_INSTALL_DIR)/.." && $(INSTALL_DATA) Wish-Info.plist "$(BIN_INSTALL_DIR)/../Info.plist" && mv -f "$(BIN_INSTALL_DIR)/wish$(VERSION)" "$(BIN_INSTALL_DIR)/Wish"'
8692	EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && echo "Installing Wish.icns to $(BIN_INSTALL_DIR)/../Resources" && $(INSTALL_DATA_DIR) "$(BIN_INSTALL_DIR)/../Resources"'
8693	EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && $(INSTALL_DATA) "$(MAC_OSX_DIR)/Tk.icns" "$(BIN_INSTALL_DIR)/../Resources/Wish.icns"'
8694	EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && echo "Installing Wish.sdef to $(BIN_INSTALL_DIR)/../Resources" && $(INSTALL_DATA) "$(MAC_OSX_DIR)/Wish.sdef" "$(BIN_INSTALL_DIR)/../Resources"'
8695	EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && echo "Installing Credits.html to $(BIN_INSTALL_DIR)/../Resources" && $(INSTALL_DATA) Credits.html "$(BIN_INSTALL_DIR)/../Resources"'
8696    fi
8697    EXTRA_INSTALL_BINARIES="$EXTRA_INSTALL_BINARIES"' && echo "Finalizing Tk.framework" && rm -f "$(LIB_INSTALL_DIR)/../Current" && ln -s "$(VERSION)" "$(LIB_INSTALL_DIR)/../Current" && for f in "$(LIB_FILE)" tkConfig.sh Resources Headers PrivateHeaders; do rm -f "$(LIB_INSTALL_DIR)/../../$$f" && ln -s "Versions/Current/$$f" "$(LIB_INSTALL_DIR)/../.."; done && f="$(STUB_LIB_FILE)" && rm -f "$(LIB_INSTALL_DIR)/../../$$f" && ln -s "Versions/$(VERSION)/$$f" "$(LIB_INSTALL_DIR)/../.."'
8698    # Don't use AC_DEFINE for the following as the framework version define
8699    # needs to go into the Makefile even when using autoheader, so that we
8700    # can pick up a potential make override of VERSION. Also, don't put this
8701    # into CFLAGS as it should not go into tkConfig.sh
8702    EXTRA_CC_SWITCHES="$EXTRA_CC_SWITCHES"' -DTK_FRAMEWORK_VERSION=\"$(VERSION)\"'
8703else
8704    if test $tk_aqua = yes; then
8705        EXTRA_INSTALL_BINARIES='@echo "Installing Images to $(LIB_INSTALL_DIR)/" && $(INSTALL_DATA_DIR) "$(LIB_INSTALL_DIR)" && for i in Tk.tiff Tk.icns; do $(INSTALL_DATA) "$(MAC_OSX_DIR)/$$i" "$(LIB_INSTALL_DIR)"; done'
8706    fi
8707    # libdir must be a fully qualified path and not ${exec_prefix}/lib
8708    eval libdir="$libdir"
8709    TK_LIB_FLAG="-l"
8710    if test "${TCL_MAJOR_VERSION}" -gt 8 ; then
8711	TK_LIB_FLAG="${TK_LIB_FLAG}tcl9"
8712    fi
8713    if test "${ac_cv_cygwin}" = "yes" -a "$SHARED_BUILD" = "1"; then
8714	TK_LIB_FLAG="${TK_LIB_FLAG}tk`echo ${TK_VERSION} | tr -d .`"
8715	TK_BUILD_LIB_SPEC="-L\$(TOP_DIR)/win ${TK_LIB_FLAG}"
8716    else
8717	if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
8718	    TK_LIB_FLAG="${TK_LIB_FLAG}tk${TK_VERSION}"
8719	else
8720	    TK_LIB_FLAG="${TK_LIB_FLAG}tk`echo ${TK_VERSION} | tr -d .`"
8721	fi
8722	TK_BUILD_LIB_SPEC="-L`pwd | sed -e 's/ /\\\\ /g'` ${TK_LIB_FLAG}"
8723    fi
8724    TK_LIB_SPEC="-L${libdir} ${TK_LIB_FLAG}"
8725fi
8726
8727#--------------------------------------------------------------------
8728#	Zipfs support - Tip 430
8729#--------------------------------------------------------------------
8730# Check whether --enable-zipfs was given.
8731if test ${enable_zipfs+y}
8732then :
8733  enableval=$enable_zipfs; tcl_ok=$enableval
8734else $as_nop
8735  tcl_ok=yes
8736fi
8737
8738if test "$tcl_ok" = "yes" -a "x$enable_framework" != "xyes"; then
8739    #
8740    # Find a native compiler
8741    #
8742    # Put a plausible default for CC_FOR_BUILD in Makefile.
8743    if test -z "$CC_FOR_BUILD"; then
8744      if test "x$cross_compiling" = "xno"; then
8745        CC_FOR_BUILD='$(CC)'
8746      else
8747        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gcc" >&5
8748printf %s "checking for gcc... " >&6; }
8749        if test ${ac_cv_path_cc+y}
8750then :
8751  printf %s "(cached) " >&6
8752else $as_nop
8753
8754            search_path=`echo ${PATH} | sed -e 's/:/ /g'`
8755            for dir in $search_path ; do
8756                for j in `ls -r $dir/gcc 2> /dev/null` \
8757                        `ls -r $dir/gcc 2> /dev/null` ; do
8758                    if test x"$ac_cv_path_cc" = x ; then
8759                        if test -f "$j" ; then
8760                            ac_cv_path_cc=$j
8761                            break
8762                        fi
8763                    fi
8764                done
8765            done
8766
8767fi
8768
8769      fi
8770    fi
8771
8772    # Also set EXEEXT_FOR_BUILD.
8773    if test "x$cross_compiling" = "xno"; then
8774      EXEEXT_FOR_BUILD='$(EXEEXT)'
8775      OBJEXT_FOR_BUILD='$(OBJEXT)'
8776    else
8777      OBJEXT_FOR_BUILD='.no'
8778      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for build system executable suffix" >&5
8779printf %s "checking for build system executable suffix... " >&6; }
8780if test ${bfd_cv_build_exeext+y}
8781then :
8782  printf %s "(cached) " >&6
8783else $as_nop
8784  rm -f conftest*
8785         echo 'int main () { return 0; }' > conftest.c
8786         bfd_cv_build_exeext=
8787         ${CC_FOR_BUILD} -o conftest conftest.c 1>&5 2>&5
8788         for file in conftest.*; do
8789           case $file in
8790           *.c | *.o | *.obj | *.ilk | *.pdb) ;;
8791           *) bfd_cv_build_exeext=`echo $file | sed -e s/conftest//` ;;
8792           esac
8793         done
8794         rm -f conftest*
8795         test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no
8796fi
8797{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_build_exeext" >&5
8798printf "%s\n" "$bfd_cv_build_exeext" >&6; }
8799      EXEEXT_FOR_BUILD=""
8800      test x"${bfd_cv_build_exeext}" != xno && EXEEXT_FOR_BUILD=${bfd_cv_build_exeext}
8801    fi
8802
8803    #
8804    # Find a native zip implementation
8805    #
8806
8807    MACHER_PROG=""
8808    ZIP_PROG=""
8809    ZIP_PROG_OPTIONS=""
8810    ZIP_PROG_VFSSEARCH=""
8811    ZIP_INSTALL_OBJS=""
8812
8813    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for macher" >&5
8814printf %s "checking for macher... " >&6; }
8815    if test ${ac_cv_path_macher+y}
8816then :
8817  printf %s "(cached) " >&6
8818else $as_nop
8819
8820    search_path=`echo ${PATH} | sed -e 's/:/ /g'`
8821    for dir in $search_path ; do
8822        for j in `ls -r $dir/macher 2> /dev/null` \
8823            `ls -r $dir/macher 2> /dev/null` ; do
8824        if test x"$ac_cv_path_macher" = x ; then
8825            if test -f "$j" ; then
8826            ac_cv_path_macher=$j
8827            break
8828            fi
8829        fi
8830        done
8831    done
8832
8833fi
8834
8835    if test -f "$ac_cv_path_macher" ; then
8836        MACHER_PROG="$ac_cv_path_macher"
8837        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MACHER_PROG" >&5
8838printf "%s\n" "$MACHER_PROG" >&6; }
8839        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Found macher in environment" >&5
8840printf "%s\n" "Found macher in environment" >&6; }
8841    fi
8842    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zip" >&5
8843printf %s "checking for zip... " >&6; }
8844    if test ${ac_cv_path_zip+y}
8845then :
8846  printf %s "(cached) " >&6
8847else $as_nop
8848
8849    search_path=`echo ${PATH} | sed -e 's/:/ /g'`
8850    for dir in $search_path ; do
8851        for j in `ls -r $dir/zip 2> /dev/null` \
8852            `ls -r $dir/zip 2> /dev/null` ; do
8853        if test x"$ac_cv_path_zip" = x ; then
8854            if test -f "$j" ; then
8855            ac_cv_path_zip=$j
8856            break
8857            fi
8858        fi
8859        done
8860    done
8861
8862fi
8863
8864    if test -f "$ac_cv_path_zip" ; then
8865        ZIP_PROG="$ac_cv_path_zip"
8866        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ZIP_PROG" >&5
8867printf "%s\n" "$ZIP_PROG" >&6; }
8868        ZIP_PROG_OPTIONS="-rq"
8869        ZIP_PROG_VFSSEARCH="*"
8870        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Found INFO Zip in environment" >&5
8871printf "%s\n" "Found INFO Zip in environment" >&6; }
8872        # Use standard arguments for zip
8873    else
8874        # It is not an error if an installed version of Zip can't be located.
8875        # We can use the locally distributed minizip instead
8876        ZIP_PROG="./minizip${EXEEXT_FOR_BUILD}"
8877        ZIP_PROG_OPTIONS="-o -r"
8878        ZIP_PROG_VFSSEARCH="*"
8879        ZIP_INSTALL_OBJS="minizip${EXEEXT_FOR_BUILD}"
8880        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: No zip found on PATH. Building minizip" >&5
8881printf "%s\n" "No zip found on PATH. Building minizip" >&6; }
8882    fi
8883
8884
8885
8886
8887
8888
8889	ZIPFS_BUILD=1
8890	TK_ZIP_FILE=libtk${TK_MAJOR_VERSION}.${TK_MINOR_VERSION}${TK_PATCH_LEVEL}.zip
8891else
8892	ZIPFS_BUILD=0
8893	TK_ZIP_FILE=
8894fi
8895# Do checking message here to not mess up interleaved configure output
8896{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for building with zipfs" >&5
8897printf %s "checking for building with zipfs... " >&6; }
8898if test "${ZIPFS_BUILD}" = 1; then
8899    if test "${SHARED_BUILD}" = 0; then
8900       ZIPFS_BUILD=2;
8901
8902printf "%s\n" "#define ZIPFS_BUILD 2" >>confdefs.h
8903
8904       INSTALL_LIBRARIES=install-demos
8905       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8906printf "%s\n" "yes" >&6; }
8907     else
8908
8909printf "%s\n" "#define ZIPFS_BUILD 1" >>confdefs.h
8910\
8911       INSTALL_LIBRARIES=install-demos
8912       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8913printf "%s\n" "yes" >&6; }
8914    fi
8915else
8916{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8917printf "%s\n" "no" >&6; }
8918INSTALL_LIBRARIES=install-libraries
8919INSTALL_MSGS=install-msgs
8920fi
8921
8922
8923
8924
8925
8926
8927#--------------------------------------------------------------------
8928#       The statements below define various symbols relating to Tk
8929#       stub support.
8930#--------------------------------------------------------------------
8931
8932# Replace ${VERSION} with contents of ${TK_VERSION}
8933eval "TK_STUB_LIB_FILE=libtkstub${TK_UNSHARED_LIB_SUFFIX}"
8934eval "TK_STUB_LIB_DIR=${libdir}"
8935
8936if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
8937    TK_STUB_LIB_FLAG="-ltkstub${TK_VERSION}"
8938else
8939    TK_STUB_LIB_FLAG="-ltkstub`echo ${TK_VERSION} | tr -d .`"
8940fi
8941
8942TK_BUILD_STUB_LIB_SPEC="-L`pwd | sed -e 's/ /\\\\ /g'` ${TK_STUB_LIB_FLAG}"
8943TK_STUB_LIB_SPEC="-L${TK_STUB_LIB_DIR} ${TK_STUB_LIB_FLAG}"
8944TK_BUILD_STUB_LIB_PATH="`pwd`/${TK_STUB_LIB_FILE}"
8945TK_STUB_LIB_PATH="${TK_STUB_LIB_DIR}/${TK_STUB_LIB_FILE}"
8946
8947# Install time header dir can be set via --includedir
8948eval "TK_INCLUDE_SPEC=\"-I${includedir}\""
8949
8950#------------------------------------------------------------------------
8951# Demo dir
8952#------------------------------------------------------------------------
8953
8954if test x"${DEMO_DIR}" = x
8955then :
8956  DEMO_DIR='$(TK_LIBRARY)/demos'
8957fi
8958eval "TK_DEMO_DIR=\"`echo ${DEMO_DIR} | tr '()' '{}'`\""
8959eval "TK_DEMO_DIR=\"`echo ${TK_DEMO_DIR} | tr '()' '{}'`\""
8960
8961
8962
8963#------------------------------------------------------------------------
8964# tkConfig.sh refers to this by a different name
8965#------------------------------------------------------------------------
8966
8967TK_SHARED_BUILD=${SHARED_BUILD}
8968
8969
8970
8971
8972
8973
8974
8975
8976
8977
8978
8979
8980
8981
8982
8983
8984
8985
8986
8987
8988
8989
8990
8991
8992
8993
8994
8995
8996
8997
8998
8999
9000
9001
9002
9003
9004
9005
9006
9007
9008
9009
9010
9011
9012
9013
9014
9015
9016
9017
9018
9019
9020
9021
9022ac_config_files="$ac_config_files Makefile:../unix/Makefile.in tkConfig.sh:../unix/tkConfig.sh.in tk.pc:../unix/tk.pc.in"
9023
9024cat >confcache <<\_ACEOF
9025# This file is a shell script that caches the results of configure
9026# tests run on this system so they can be shared between configure
9027# scripts and configure runs, see configure's option --config-cache.
9028# It is not useful on other systems.  If it contains results you don't
9029# want to keep, you may remove or edit it.
9030#
9031# config.status only pays attention to the cache file if you give it
9032# the --recheck option to rerun configure.
9033#
9034# `ac_cv_env_foo' variables (set or unset) will be overridden when
9035# loading this file, other *unset* `ac_cv_foo' will be assigned the
9036# following values.
9037
9038_ACEOF
9039
9040# The following way of writing the cache mishandles newlines in values,
9041# but we know of no workaround that is simple, portable, and efficient.
9042# So, we kill variables containing newlines.
9043# Ultrix sh set writes to stderr and can't be redirected directly,
9044# and sets the high bit in the cache file unless we assign to the vars.
9045(
9046  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
9047    eval ac_val=\$$ac_var
9048    case $ac_val in #(
9049    *${as_nl}*)
9050      case $ac_var in #(
9051      *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
9052printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
9053      esac
9054      case $ac_var in #(
9055      _ | IFS | as_nl) ;; #(
9056      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
9057      *) { eval $ac_var=; unset $ac_var;} ;;
9058      esac ;;
9059    esac
9060  done
9061
9062  (set) 2>&1 |
9063    case $as_nl`(ac_space=' '; set) 2>&1` in #(
9064    *${as_nl}ac_space=\ *)
9065      # `set' does not quote correctly, so add quotes: double-quote
9066      # substitution turns \\\\ into \\, and sed turns \\ into \.
9067      sed -n \
9068	"s/'/'\\\\''/g;
9069	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
9070      ;; #(
9071    *)
9072      # `set' quotes correctly as required by POSIX, so do not add quotes.
9073      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
9074      ;;
9075    esac |
9076    sort
9077) |
9078  sed '
9079     /^ac_cv_env_/b end
9080     t clear
9081     :clear
9082     s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/
9083     t end
9084     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
9085     :end' >>confcache
9086if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
9087  if test -w "$cache_file"; then
9088    if test "x$cache_file" != "x/dev/null"; then
9089      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
9090printf "%s\n" "$as_me: updating cache $cache_file" >&6;}
9091      if test ! -f "$cache_file" || test -h "$cache_file"; then
9092	cat confcache >"$cache_file"
9093      else
9094        case $cache_file in #(
9095        */* | ?:*)
9096	  mv -f confcache "$cache_file"$$ &&
9097	  mv -f "$cache_file"$$ "$cache_file" ;; #(
9098        *)
9099	  mv -f confcache "$cache_file" ;;
9100	esac
9101      fi
9102    fi
9103  else
9104    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
9105printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;}
9106  fi
9107fi
9108rm -f confcache
9109
9110test "x$prefix" = xNONE && prefix=$ac_default_prefix
9111# Let make expand exec_prefix.
9112test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
9113
9114# Transform confdefs.h into DEFS.
9115# Protect against shell expansion while executing Makefile rules.
9116# Protect against Makefile macro expansion.
9117#
9118# If the first sed substitution is executed (which looks for macros that
9119# take arguments), then branch to the quote section.  Otherwise,
9120# look for a macro that doesn't take arguments.
9121ac_script='
9122:mline
9123/\\$/{
9124 N
9125 s,\\\n,,
9126 b mline
9127}
9128t clear
9129:clear
9130s/^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 (][^	 (]*([^)]*)\)[	 ]*\(.*\)/-D\1=\2/g
9131t quote
9132s/^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 ][^	 ]*\)[	 ]*\(.*\)/-D\1=\2/g
9133t quote
9134b any
9135:quote
9136s/[	 `~#$^&*(){}\\|;'\''"<>?]/\\&/g
9137s/\[/\\&/g
9138s/\]/\\&/g
9139s/\$/$$/g
9140H
9141:any
9142${
9143	g
9144	s/^\n//
9145	s/\n/ /g
9146	p
9147}
9148'
9149DEFS=`sed -n "$ac_script" confdefs.h`
9150
9151
9152ac_libobjs=
9153ac_ltlibobjs=
9154U=
9155for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
9156  # 1. Remove the extension, and $U if already installed.
9157  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
9158  ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"`
9159  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
9160  #    will be set to the directory where LIBOBJS objects are built.
9161  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
9162  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
9163done
9164LIBOBJS=$ac_libobjs
9165
9166LTLIBOBJS=$ac_ltlibobjs
9167
9168
9169CFLAGS="${CFLAGS} ${CPPFLAGS}"; CPPFLAGS=""
9170
9171
9172: "${CONFIG_STATUS=./config.status}"
9173ac_write_fail=0
9174ac_clean_files_save=$ac_clean_files
9175ac_clean_files="$ac_clean_files $CONFIG_STATUS"
9176{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
9177printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;}
9178as_write_fail=0
9179cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
9180#! $SHELL
9181# Generated by $as_me.
9182# Run this file to recreate the current configuration.
9183# Compiler output produced by configure, useful for debugging
9184# configure, is in config.log if it exists.
9185
9186debug=false
9187ac_cs_recheck=false
9188ac_cs_silent=false
9189
9190SHELL=\${CONFIG_SHELL-$SHELL}
9191export SHELL
9192_ASEOF
9193cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
9194## -------------------- ##
9195## M4sh Initialization. ##
9196## -------------------- ##
9197
9198# Be more Bourne compatible
9199DUALCASE=1; export DUALCASE # for MKS sh
9200as_nop=:
9201if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
9202then :
9203  emulate sh
9204  NULLCMD=:
9205  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
9206  # is contrary to our usage.  Disable this feature.
9207  alias -g '${1+"$@"}'='"$@"'
9208  setopt NO_GLOB_SUBST
9209else $as_nop
9210  case `(set -o) 2>/dev/null` in #(
9211  *posix*) :
9212    set -o posix ;; #(
9213  *) :
9214     ;;
9215esac
9216fi
9217
9218
9219
9220# Reset variables that may have inherited troublesome values from
9221# the environment.
9222
9223# IFS needs to be set, to space, tab, and newline, in precisely that order.
9224# (If _AS_PATH_WALK were called with IFS unset, it would have the
9225# side effect of setting IFS to empty, thus disabling word splitting.)
9226# Quoting is to prevent editors from complaining about space-tab.
9227as_nl='
9228'
9229export as_nl
9230IFS=" ""	$as_nl"
9231
9232PS1='$ '
9233PS2='> '
9234PS4='+ '
9235
9236# Ensure predictable behavior from utilities with locale-dependent output.
9237LC_ALL=C
9238export LC_ALL
9239LANGUAGE=C
9240export LANGUAGE
9241
9242# We cannot yet rely on "unset" to work, but we need these variables
9243# to be unset--not just set to an empty or harmless value--now, to
9244# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh).  This construct
9245# also avoids known problems related to "unset" and subshell syntax
9246# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
9247for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
9248do eval test \${$as_var+y} \
9249  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
9250done
9251
9252# Ensure that fds 0, 1, and 2 are open.
9253if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
9254if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
9255if (exec 3>&2)            ; then :; else exec 2>/dev/null; fi
9256
9257# The user is always right.
9258if ${PATH_SEPARATOR+false} :; then
9259  PATH_SEPARATOR=:
9260  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
9261    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
9262      PATH_SEPARATOR=';'
9263  }
9264fi
9265
9266
9267# Find who we are.  Look in the path if we contain no directory separator.
9268as_myself=
9269case $0 in #((
9270  *[\\/]* ) as_myself=$0 ;;
9271  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9272for as_dir in $PATH
9273do
9274  IFS=$as_save_IFS
9275  case $as_dir in #(((
9276    '') as_dir=./ ;;
9277    */) ;;
9278    *) as_dir=$as_dir/ ;;
9279  esac
9280    test -r "$as_dir$0" && as_myself=$as_dir$0 && break
9281  done
9282IFS=$as_save_IFS
9283
9284     ;;
9285esac
9286# We did not find ourselves, most probably we were run as `sh COMMAND'
9287# in which case we are not to be found in the path.
9288if test "x$as_myself" = x; then
9289  as_myself=$0
9290fi
9291if test ! -f "$as_myself"; then
9292  printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
9293  exit 1
9294fi
9295
9296
9297
9298# as_fn_error STATUS ERROR [LINENO LOG_FD]
9299# ----------------------------------------
9300# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
9301# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
9302# script with STATUS, using 1 if that was 0.
9303as_fn_error ()
9304{
9305  as_status=$1; test $as_status -eq 0 && as_status=1
9306  if test "$4"; then
9307    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
9308    printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
9309  fi
9310  printf "%s\n" "$as_me: error: $2" >&2
9311  as_fn_exit $as_status
9312} # as_fn_error
9313
9314
9315
9316# as_fn_set_status STATUS
9317# -----------------------
9318# Set $? to STATUS, without forking.
9319as_fn_set_status ()
9320{
9321  return $1
9322} # as_fn_set_status
9323
9324# as_fn_exit STATUS
9325# -----------------
9326# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
9327as_fn_exit ()
9328{
9329  set +e
9330  as_fn_set_status $1
9331  exit $1
9332} # as_fn_exit
9333
9334# as_fn_unset VAR
9335# ---------------
9336# Portably unset VAR.
9337as_fn_unset ()
9338{
9339  { eval $1=; unset $1;}
9340}
9341as_unset=as_fn_unset
9342
9343# as_fn_append VAR VALUE
9344# ----------------------
9345# Append the text in VALUE to the end of the definition contained in VAR. Take
9346# advantage of any shell optimizations that allow amortized linear growth over
9347# repeated appends, instead of the typical quadratic growth present in naive
9348# implementations.
9349if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
9350then :
9351  eval 'as_fn_append ()
9352  {
9353    eval $1+=\$2
9354  }'
9355else $as_nop
9356  as_fn_append ()
9357  {
9358    eval $1=\$$1\$2
9359  }
9360fi # as_fn_append
9361
9362# as_fn_arith ARG...
9363# ------------------
9364# Perform arithmetic evaluation on the ARGs, and store the result in the
9365# global $as_val. Take advantage of shells that can avoid forks. The arguments
9366# must be portable across $(()) and expr.
9367if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
9368then :
9369  eval 'as_fn_arith ()
9370  {
9371    as_val=$(( $* ))
9372  }'
9373else $as_nop
9374  as_fn_arith ()
9375  {
9376    as_val=`expr "$@" || test $? -eq 1`
9377  }
9378fi # as_fn_arith
9379
9380
9381if expr a : '\(a\)' >/dev/null 2>&1 &&
9382   test "X`expr 00001 : '.*\(...\)'`" = X001; then
9383  as_expr=expr
9384else
9385  as_expr=false
9386fi
9387
9388if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
9389  as_basename=basename
9390else
9391  as_basename=false
9392fi
9393
9394if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
9395  as_dirname=dirname
9396else
9397  as_dirname=false
9398fi
9399
9400as_me=`$as_basename -- "$0" ||
9401$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
9402	 X"$0" : 'X\(//\)$' \| \
9403	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
9404printf "%s\n" X/"$0" |
9405    sed '/^.*\/\([^/][^/]*\)\/*$/{
9406	    s//\1/
9407	    q
9408	  }
9409	  /^X\/\(\/\/\)$/{
9410	    s//\1/
9411	    q
9412	  }
9413	  /^X\/\(\/\).*/{
9414	    s//\1/
9415	    q
9416	  }
9417	  s/.*/./; q'`
9418
9419# Avoid depending upon Character Ranges.
9420as_cr_letters='abcdefghijklmnopqrstuvwxyz'
9421as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
9422as_cr_Letters=$as_cr_letters$as_cr_LETTERS
9423as_cr_digits='0123456789'
9424as_cr_alnum=$as_cr_Letters$as_cr_digits
9425
9426
9427# Determine whether it's possible to make 'echo' print without a newline.
9428# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
9429# for compatibility with existing Makefiles.
9430ECHO_C= ECHO_N= ECHO_T=
9431case `echo -n x` in #(((((
9432-n*)
9433  case `echo 'xy\c'` in
9434  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
9435  xy)  ECHO_C='\c';;
9436  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
9437       ECHO_T='	';;
9438  esac;;
9439*)
9440  ECHO_N='-n';;
9441esac
9442
9443# For backward compatibility with old third-party macros, we provide
9444# the shell variables $as_echo and $as_echo_n.  New code should use
9445# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
9446as_echo='printf %s\n'
9447as_echo_n='printf %s'
9448
9449rm -f conf$$ conf$$.exe conf$$.file
9450if test -d conf$$.dir; then
9451  rm -f conf$$.dir/conf$$.file
9452else
9453  rm -f conf$$.dir
9454  mkdir conf$$.dir 2>/dev/null
9455fi
9456if (echo >conf$$.file) 2>/dev/null; then
9457  if ln -s conf$$.file conf$$ 2>/dev/null; then
9458    as_ln_s='ln -s'
9459    # ... but there are two gotchas:
9460    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
9461    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
9462    # In both cases, we have to default to `cp -pR'.
9463    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
9464      as_ln_s='cp -pR'
9465  elif ln conf$$.file conf$$ 2>/dev/null; then
9466    as_ln_s=ln
9467  else
9468    as_ln_s='cp -pR'
9469  fi
9470else
9471  as_ln_s='cp -pR'
9472fi
9473rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
9474rmdir conf$$.dir 2>/dev/null
9475
9476
9477# as_fn_mkdir_p
9478# -------------
9479# Create "$as_dir" as a directory, including parents if necessary.
9480as_fn_mkdir_p ()
9481{
9482
9483  case $as_dir in #(
9484  -*) as_dir=./$as_dir;;
9485  esac
9486  test -d "$as_dir" || eval $as_mkdir_p || {
9487    as_dirs=
9488    while :; do
9489      case $as_dir in #(
9490      *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
9491      *) as_qdir=$as_dir;;
9492      esac
9493      as_dirs="'$as_qdir' $as_dirs"
9494      as_dir=`$as_dirname -- "$as_dir" ||
9495$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
9496	 X"$as_dir" : 'X\(//\)[^/]' \| \
9497	 X"$as_dir" : 'X\(//\)$' \| \
9498	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
9499printf "%s\n" X"$as_dir" |
9500    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
9501	    s//\1/
9502	    q
9503	  }
9504	  /^X\(\/\/\)[^/].*/{
9505	    s//\1/
9506	    q
9507	  }
9508	  /^X\(\/\/\)$/{
9509	    s//\1/
9510	    q
9511	  }
9512	  /^X\(\/\).*/{
9513	    s//\1/
9514	    q
9515	  }
9516	  s/.*/./; q'`
9517      test -d "$as_dir" && break
9518    done
9519    test -z "$as_dirs" || eval "mkdir $as_dirs"
9520  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
9521
9522
9523} # as_fn_mkdir_p
9524if mkdir -p . 2>/dev/null; then
9525  as_mkdir_p='mkdir -p "$as_dir"'
9526else
9527  test -d ./-p && rmdir ./-p
9528  as_mkdir_p=false
9529fi
9530
9531
9532# as_fn_executable_p FILE
9533# -----------------------
9534# Test if FILE is an executable regular file.
9535as_fn_executable_p ()
9536{
9537  test -f "$1" && test -x "$1"
9538} # as_fn_executable_p
9539as_test_x='test -x'
9540as_executable_p=as_fn_executable_p
9541
9542# Sed expression to map a string onto a valid CPP name.
9543as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
9544
9545# Sed expression to map a string onto a valid variable name.
9546as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
9547
9548
9549exec 6>&1
9550## ----------------------------------- ##
9551## Main body of $CONFIG_STATUS script. ##
9552## ----------------------------------- ##
9553_ASEOF
9554test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
9555
9556cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9557# Save the log message, to keep $0 and so on meaningful, and to
9558# report actual input values of CONFIG_FILES etc. instead of their
9559# values after options handling.
9560ac_log="
9561This file was extended by tk $as_me 8.7, which was
9562generated by GNU Autoconf 2.70.  Invocation command line was
9563
9564  CONFIG_FILES    = $CONFIG_FILES
9565  CONFIG_HEADERS  = $CONFIG_HEADERS
9566  CONFIG_LINKS    = $CONFIG_LINKS
9567  CONFIG_COMMANDS = $CONFIG_COMMANDS
9568  $ $0 $@
9569
9570on `(hostname || uname -n) 2>/dev/null | sed 1q`
9571"
9572
9573_ACEOF
9574
9575case $ac_config_files in *"
9576"*) set x $ac_config_files; shift; ac_config_files=$*;;
9577esac
9578
9579
9580
9581cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9582# Files that config.status was made for.
9583config_files="$ac_config_files"
9584config_commands="$ac_config_commands"
9585
9586_ACEOF
9587
9588cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9589ac_cs_usage="\
9590\`$as_me' instantiates files and other configuration actions
9591from templates according to the current configuration.  Unless the files
9592and actions are specified as TAGs, all are instantiated by default.
9593
9594Usage: $0 [OPTION]... [TAG]...
9595
9596  -h, --help       print this help, then exit
9597  -V, --version    print version number and configuration settings, then exit
9598      --config     print configuration, then exit
9599  -q, --quiet, --silent
9600                   do not print progress messages
9601  -d, --debug      don't remove temporary files
9602      --recheck    update $as_me by reconfiguring in the same conditions
9603      --file=FILE[:TEMPLATE]
9604                   instantiate the configuration file FILE
9605
9606Configuration files:
9607$config_files
9608
9609Configuration commands:
9610$config_commands
9611
9612Report bugs to the package provider."
9613
9614_ACEOF
9615ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"`
9616ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"`
9617cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9618ac_cs_config='$ac_cs_config_escaped'
9619ac_cs_version="\\
9620tk config.status 8.7
9621configured by $0, generated by GNU Autoconf 2.70,
9622  with options \\"\$ac_cs_config\\"
9623
9624Copyright (C) 2020 Free Software Foundation, Inc.
9625This config.status script is free software; the Free Software Foundation
9626gives unlimited permission to copy, distribute and modify it."
9627
9628ac_pwd='$ac_pwd'
9629srcdir='$srcdir'
9630test -n "\$AWK" || AWK=awk
9631_ACEOF
9632
9633cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9634# The default lists apply if the user does not specify any file.
9635ac_need_defaults=:
9636while test $# != 0
9637do
9638  case $1 in
9639  --*=?*)
9640    ac_option=`expr "X$1" : 'X\([^=]*\)='`
9641    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
9642    ac_shift=:
9643    ;;
9644  --*=)
9645    ac_option=`expr "X$1" : 'X\([^=]*\)='`
9646    ac_optarg=
9647    ac_shift=:
9648    ;;
9649  *)
9650    ac_option=$1
9651    ac_optarg=$2
9652    ac_shift=shift
9653    ;;
9654  esac
9655
9656  case $ac_option in
9657  # Handling of the options.
9658  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
9659    ac_cs_recheck=: ;;
9660  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
9661    printf "%s\n" "$ac_cs_version"; exit ;;
9662  --config | --confi | --conf | --con | --co | --c )
9663    printf "%s\n" "$ac_cs_config"; exit ;;
9664  --debug | --debu | --deb | --de | --d | -d )
9665    debug=: ;;
9666  --file | --fil | --fi | --f )
9667    $ac_shift
9668    case $ac_optarg in
9669    *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
9670    '') as_fn_error $? "missing file argument" ;;
9671    esac
9672    as_fn_append CONFIG_FILES " '$ac_optarg'"
9673    ac_need_defaults=false;;
9674  --he | --h |  --help | --hel | -h )
9675    printf "%s\n" "$ac_cs_usage"; exit ;;
9676  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
9677  | -silent | --silent | --silen | --sile | --sil | --si | --s)
9678    ac_cs_silent=: ;;
9679
9680  # This is an error.
9681  -*) as_fn_error $? "unrecognized option: \`$1'
9682Try \`$0 --help' for more information." ;;
9683
9684  *) as_fn_append ac_config_targets " $1"
9685     ac_need_defaults=false ;;
9686
9687  esac
9688  shift
9689done
9690
9691ac_configure_extra_args=
9692
9693if $ac_cs_silent; then
9694  exec 6>/dev/null
9695  ac_configure_extra_args="$ac_configure_extra_args --silent"
9696fi
9697
9698_ACEOF
9699cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9700if \$ac_cs_recheck; then
9701  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
9702  shift
9703  \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6
9704  CONFIG_SHELL='$SHELL'
9705  export CONFIG_SHELL
9706  exec "\$@"
9707fi
9708
9709_ACEOF
9710cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9711exec 5>>config.log
9712{
9713  echo
9714  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
9715## Running $as_me. ##
9716_ASBOX
9717  printf "%s\n" "$ac_log"
9718} >&5
9719
9720_ACEOF
9721cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9722#
9723# INIT-COMMANDS
9724#
9725VERSION=${TK_VERSION} && tk_aqua=${tk_aqua}
9726
9727_ACEOF
9728
9729cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9730
9731# Handling of arguments.
9732for ac_config_target in $ac_config_targets
9733do
9734  case $ac_config_target in
9735    "Tk-Info.plist") CONFIG_FILES="$CONFIG_FILES Tk-Info.plist:../macosx/Tk-Info.plist.in" ;;
9736    "Wish-Info.plist") CONFIG_FILES="$CONFIG_FILES Wish-Info.plist:../macosx/Wish-Info.plist.in" ;;
9737    "Credits.html") CONFIG_FILES="$CONFIG_FILES Credits.html:../macosx/Credits.html.in" ;;
9738    "Tk.framework") CONFIG_COMMANDS="$CONFIG_COMMANDS Tk.framework" ;;
9739    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile:../unix/Makefile.in" ;;
9740    "tkConfig.sh") CONFIG_FILES="$CONFIG_FILES tkConfig.sh:../unix/tkConfig.sh.in" ;;
9741    "tk.pc") CONFIG_FILES="$CONFIG_FILES tk.pc:../unix/tk.pc.in" ;;
9742
9743  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
9744  esac
9745done
9746
9747
9748# If the user did not use the arguments to specify the items to instantiate,
9749# then the envvar interface is used.  Set only those that are not.
9750# We use the long form for the default assignment because of an extremely
9751# bizarre bug on SunOS 4.1.3.
9752if $ac_need_defaults; then
9753  test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files
9754  test ${CONFIG_COMMANDS+y} || CONFIG_COMMANDS=$config_commands
9755fi
9756
9757# Have a temporary directory for convenience.  Make it in the build tree
9758# simply because there is no reason against having it here, and in addition,
9759# creating and moving files from /tmp can sometimes cause problems.
9760# Hook for its removal unless debugging.
9761# Note that there is a small window in which the directory will not be cleaned:
9762# after its creation but before its name has been assigned to `$tmp'.
9763$debug ||
9764{
9765  tmp= ac_tmp=
9766  trap 'exit_status=$?
9767  : "${ac_tmp:=$tmp}"
9768  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
9769' 0
9770  trap 'as_fn_exit 1' 1 2 13 15
9771}
9772# Create a (secure) tmp directory for tmp files.
9773
9774{
9775  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
9776  test -d "$tmp"
9777}  ||
9778{
9779  tmp=./conf$$-$RANDOM
9780  (umask 077 && mkdir "$tmp")
9781} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
9782ac_tmp=$tmp
9783
9784# Set up the scripts for CONFIG_FILES section.
9785# No need to generate them if there are no CONFIG_FILES.
9786# This happens for instance with `./config.status config.h'.
9787if test -n "$CONFIG_FILES"; then
9788
9789
9790ac_cr=`echo X | tr X '\015'`
9791# On cygwin, bash can eat \r inside `` if the user requested igncr.
9792# But we know of no other shell where ac_cr would be empty at this
9793# point, so we can use a bashism as a fallback.
9794if test "x$ac_cr" = x; then
9795  eval ac_cr=\$\'\\r\'
9796fi
9797ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
9798if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
9799  ac_cs_awk_cr='\\r'
9800else
9801  ac_cs_awk_cr=$ac_cr
9802fi
9803
9804echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
9805_ACEOF
9806
9807
9808{
9809  echo "cat >conf$$subs.awk <<_ACEOF" &&
9810  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
9811  echo "_ACEOF"
9812} >conf$$subs.sh ||
9813  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
9814ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
9815ac_delim='%!_!# '
9816for ac_last_try in false false false false false :; do
9817  . ./conf$$subs.sh ||
9818    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
9819
9820  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
9821  if test $ac_delim_n = $ac_delim_num; then
9822    break
9823  elif $ac_last_try; then
9824    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
9825  else
9826    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
9827  fi
9828done
9829rm -f conf$$subs.sh
9830
9831cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9832cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
9833_ACEOF
9834sed -n '
9835h
9836s/^/S["/; s/!.*/"]=/
9837p
9838g
9839s/^[^!]*!//
9840:repl
9841t repl
9842s/'"$ac_delim"'$//
9843t delim
9844:nl
9845h
9846s/\(.\{148\}\)..*/\1/
9847t more1
9848s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
9849p
9850n
9851b repl
9852:more1
9853s/["\\]/\\&/g; s/^/"/; s/$/"\\/
9854p
9855g
9856s/.\{148\}//
9857t nl
9858:delim
9859h
9860s/\(.\{148\}\)..*/\1/
9861t more2
9862s/["\\]/\\&/g; s/^/"/; s/$/"/
9863p
9864b
9865:more2
9866s/["\\]/\\&/g; s/^/"/; s/$/"\\/
9867p
9868g
9869s/.\{148\}//
9870t delim
9871' <conf$$subs.awk | sed '
9872/^[^""]/{
9873  N
9874  s/\n//
9875}
9876' >>$CONFIG_STATUS || ac_write_fail=1
9877rm -f conf$$subs.awk
9878cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9879_ACAWK
9880cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
9881  for (key in S) S_is_set[key] = 1
9882  FS = ""
9883
9884}
9885{
9886  line = $ 0
9887  nfields = split(line, field, "@")
9888  substed = 0
9889  len = length(field[1])
9890  for (i = 2; i < nfields; i++) {
9891    key = field[i]
9892    keylen = length(key)
9893    if (S_is_set[key]) {
9894      value = S[key]
9895      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
9896      len += length(value) + length(field[++i])
9897      substed = 1
9898    } else
9899      len += 1 + keylen
9900  }
9901
9902  print line
9903}
9904
9905_ACAWK
9906_ACEOF
9907cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9908if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
9909  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
9910else
9911  cat
9912fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
9913  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
9914_ACEOF
9915
9916# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
9917# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
9918# trailing colons and then remove the whole line if VPATH becomes empty
9919# (actually we leave an empty line to preserve line numbers).
9920if test "x$srcdir" = x.; then
9921  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
9922h
9923s///
9924s/^/:/
9925s/[	 ]*$/:/
9926s/:\$(srcdir):/:/g
9927s/:\${srcdir}:/:/g
9928s/:@srcdir@:/:/g
9929s/^:*//
9930s/:*$//
9931x
9932s/\(=[	 ]*\).*/\1/
9933G
9934s/\n//
9935s/^[^=]*=[	 ]*$//
9936}'
9937fi
9938
9939cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9940fi # test -n "$CONFIG_FILES"
9941
9942
9943eval set X "  :F $CONFIG_FILES      :C $CONFIG_COMMANDS"
9944shift
9945for ac_tag
9946do
9947  case $ac_tag in
9948  :[FHLC]) ac_mode=$ac_tag; continue;;
9949  esac
9950  case $ac_mode$ac_tag in
9951  :[FHL]*:*);;
9952  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
9953  :[FH]-) ac_tag=-:-;;
9954  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
9955  esac
9956  ac_save_IFS=$IFS
9957  IFS=:
9958  set x $ac_tag
9959  IFS=$ac_save_IFS
9960  shift
9961  ac_file=$1
9962  shift
9963
9964  case $ac_mode in
9965  :L) ac_source=$1;;
9966  :[FH])
9967    ac_file_inputs=
9968    for ac_f
9969    do
9970      case $ac_f in
9971      -) ac_f="$ac_tmp/stdin";;
9972      *) # Look for the file first in the build tree, then in the source tree
9973	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
9974	 # because $ac_f cannot contain `:'.
9975	 test -f "$ac_f" ||
9976	   case $ac_f in
9977	   [\\/$]*) false;;
9978	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
9979	   esac ||
9980	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
9981      esac
9982      case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
9983      as_fn_append ac_file_inputs " '$ac_f'"
9984    done
9985
9986    # Let's still pretend it is `configure' which instantiates (i.e., don't
9987    # use $as_me), people would be surprised to read:
9988    #    /* config.h.  Generated by config.status.  */
9989    configure_input='Generated from '`
9990	  printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
9991	`' by configure.'
9992    if test x"$ac_file" != x-; then
9993      configure_input="$ac_file.  $configure_input"
9994      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
9995printf "%s\n" "$as_me: creating $ac_file" >&6;}
9996    fi
9997    # Neutralize special characters interpreted by sed in replacement strings.
9998    case $configure_input in #(
9999    *\&* | *\|* | *\\* )
10000       ac_sed_conf_input=`printf "%s\n" "$configure_input" |
10001       sed 's/[\\\\&|]/\\\\&/g'`;; #(
10002    *) ac_sed_conf_input=$configure_input;;
10003    esac
10004
10005    case $ac_tag in
10006    *:-:* | *:-) cat >"$ac_tmp/stdin" \
10007      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
10008    esac
10009    ;;
10010  esac
10011
10012  ac_dir=`$as_dirname -- "$ac_file" ||
10013$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
10014	 X"$ac_file" : 'X\(//\)[^/]' \| \
10015	 X"$ac_file" : 'X\(//\)$' \| \
10016	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
10017printf "%s\n" X"$ac_file" |
10018    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
10019	    s//\1/
10020	    q
10021	  }
10022	  /^X\(\/\/\)[^/].*/{
10023	    s//\1/
10024	    q
10025	  }
10026	  /^X\(\/\/\)$/{
10027	    s//\1/
10028	    q
10029	  }
10030	  /^X\(\/\).*/{
10031	    s//\1/
10032	    q
10033	  }
10034	  s/.*/./; q'`
10035  as_dir="$ac_dir"; as_fn_mkdir_p
10036  ac_builddir=.
10037
10038case "$ac_dir" in
10039.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
10040*)
10041  ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
10042  # A ".." for each directory in $ac_dir_suffix.
10043  ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
10044  case $ac_top_builddir_sub in
10045  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
10046  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
10047  esac ;;
10048esac
10049ac_abs_top_builddir=$ac_pwd
10050ac_abs_builddir=$ac_pwd$ac_dir_suffix
10051# for backward compatibility:
10052ac_top_builddir=$ac_top_build_prefix
10053
10054case $srcdir in
10055  .)  # We are building in place.
10056    ac_srcdir=.
10057    ac_top_srcdir=$ac_top_builddir_sub
10058    ac_abs_top_srcdir=$ac_pwd ;;
10059  [\\/]* | ?:[\\/]* )  # Absolute name.
10060    ac_srcdir=$srcdir$ac_dir_suffix;
10061    ac_top_srcdir=$srcdir
10062    ac_abs_top_srcdir=$srcdir ;;
10063  *) # Relative name.
10064    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
10065    ac_top_srcdir=$ac_top_build_prefix$srcdir
10066    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
10067esac
10068ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
10069
10070
10071  case $ac_mode in
10072  :F)
10073  #
10074  # CONFIG_FILE
10075  #
10076
10077_ACEOF
10078
10079cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10080# If the template does not know about datarootdir, expand it.
10081# FIXME: This hack should be removed a few years after 2.60.
10082ac_datarootdir_hack=; ac_datarootdir_seen=
10083ac_sed_dataroot='
10084/datarootdir/ {
10085  p
10086  q
10087}
10088/@datadir@/p
10089/@docdir@/p
10090/@infodir@/p
10091/@localedir@/p
10092/@mandir@/p'
10093case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
10094*datarootdir*) ac_datarootdir_seen=yes;;
10095*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
10096  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
10097printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
10098_ACEOF
10099cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10100  ac_datarootdir_hack='
10101  s&@datadir@&$datadir&g
10102  s&@docdir@&$docdir&g
10103  s&@infodir@&$infodir&g
10104  s&@localedir@&$localedir&g
10105  s&@mandir@&$mandir&g
10106  s&\\\${datarootdir}&$datarootdir&g' ;;
10107esac
10108_ACEOF
10109
10110# Neutralize VPATH when `$srcdir' = `.'.
10111# Shell code in configure.ac might set extrasub.
10112# FIXME: do we really want to maintain this feature?
10113cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
10114ac_sed_extra="$ac_vpsub
10115$extrasub
10116_ACEOF
10117cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
10118:t
10119/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
10120s|@configure_input@|$ac_sed_conf_input|;t t
10121s&@top_builddir@&$ac_top_builddir_sub&;t t
10122s&@top_build_prefix@&$ac_top_build_prefix&;t t
10123s&@srcdir@&$ac_srcdir&;t t
10124s&@abs_srcdir@&$ac_abs_srcdir&;t t
10125s&@top_srcdir@&$ac_top_srcdir&;t t
10126s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
10127s&@builddir@&$ac_builddir&;t t
10128s&@abs_builddir@&$ac_abs_builddir&;t t
10129s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
10130$ac_datarootdir_hack
10131"
10132eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
10133  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
10134
10135test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
10136  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
10137  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
10138      "$ac_tmp/out"`; test -z "$ac_out"; } &&
10139  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
10140which seems to be undefined.  Please make sure it is defined" >&5
10141printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
10142which seems to be undefined.  Please make sure it is defined" >&2;}
10143
10144  rm -f "$ac_tmp/stdin"
10145  case $ac_file in
10146  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
10147  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
10148  esac \
10149  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
10150 ;;
10151
10152
10153  :C)  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
10154printf "%s\n" "$as_me: executing $ac_file commands" >&6;}
10155 ;;
10156  esac
10157
10158
10159  case $ac_file$ac_mode in
10160    "Tk.framework":C) n=Tk &&
10161        f=$n.framework && v=Versions/$VERSION &&
10162        rm -rf $f && mkdir -p $f/$v/Resources &&
10163        ln -s $v/$n $v/Resources $f && ln -s ../../../$n $f/$v &&
10164        ln -s ../../../../$n-Info.plist $f/$v/Resources/Info.plist &&
10165        if test $tk_aqua = yes; then ln -s ../../../../$n.rsrc $f/$v/Resources; fi &&
10166        unset n f v
10167     ;;
10168
10169  esac
10170done # for ac_tag
10171
10172
10173as_fn_exit 0
10174_ACEOF
10175ac_clean_files=$ac_clean_files_save
10176
10177test $ac_write_fail = 0 ||
10178  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
10179
10180
10181# configure is writing to config.log, and then calls config.status.
10182# config.status does its own redirection, appending to config.log.
10183# Unfortunately, on DOS this fails, as config.log is still kept open
10184# by configure, so config.status won't be able to write to it; its
10185# output is simply discarded.  So we exec the FD to /dev/null,
10186# effectively closing config.log, so it can be properly (re)opened and
10187# appended to by config.status.  When coming back to configure, we
10188# need to make the FD available again.
10189if test "$no_create" != yes; then
10190  ac_cs_success=:
10191  ac_config_status_args=
10192  test "$silent" = yes &&
10193    ac_config_status_args="$ac_config_status_args --quiet"
10194  exec 5>/dev/null
10195  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
10196  exec 5>>config.log
10197  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
10198  # would make configure fail if this is the last instruction.
10199  $ac_cs_success || as_fn_exit 1
10200fi
10201if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
10202  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
10203printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
10204fi
10205
10206
10207
10208