xref: /vim-8.2.3635/src/auto/configure (revision 9f3685a5)
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.65.
4#
5#
6# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
7# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
8# Inc.
9#
10#
11# This configure script is free software; the Free Software Foundation
12# gives unlimited permission to copy, distribute and modify it.
13## -------------------- ##
14## M4sh Initialization. ##
15## -------------------- ##
16
17# Be more Bourne compatible
18DUALCASE=1; export DUALCASE # for MKS sh
19if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
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
27  case `(set -o) 2>/dev/null` in #(
28  *posix*) :
29    set -o posix ;; #(
30  *) :
31     ;;
32esac
33fi
34
35
36as_nl='
37'
38export as_nl
39# Printing a long string crashes Solaris 7 /usr/bin/printf.
40as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43# Prefer a ksh shell builtin over an external printf program on Solaris,
44# but without wasting forks for bash or zsh.
45if test -z "$BASH_VERSION$ZSH_VERSION" \
46    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47  as_echo='print -r --'
48  as_echo_n='print -rn --'
49elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50  as_echo='printf %s\n'
51  as_echo_n='printf %s'
52else
53  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55    as_echo_n='/usr/ucb/echo -n'
56  else
57    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58    as_echo_n_body='eval
59      arg=$1;
60      case $arg in #(
61      *"$as_nl"*)
62	expr "X$arg" : "X\\(.*\\)$as_nl";
63	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64      esac;
65      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66    '
67    export as_echo_n_body
68    as_echo_n='sh -c $as_echo_n_body as_echo'
69  fi
70  export as_echo_body
71  as_echo='sh -c $as_echo_body as_echo'
72fi
73
74# The user is always right.
75if test "${PATH_SEPARATOR+set}" != set; 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# IFS
85# We need space, tab and new line, in precisely that order.  Quoting is
86# there to prevent editors from complaining about space-tab.
87# (If _AS_PATH_WALK were called with IFS unset, it would disable word
88# splitting by setting IFS to empty value.)
89IFS=" ""	$as_nl"
90
91# Find who we are.  Look in the path if we contain no directory separator.
92case $0 in #((
93  *[\\/]* ) as_myself=$0 ;;
94  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95for as_dir in $PATH
96do
97  IFS=$as_save_IFS
98  test -z "$as_dir" && as_dir=.
99    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
100  done
101IFS=$as_save_IFS
102
103     ;;
104esac
105# We did not find ourselves, most probably we were run as `sh COMMAND'
106# in which case we are not to be found in the path.
107if test "x$as_myself" = x; then
108  as_myself=$0
109fi
110if test ! -f "$as_myself"; then
111  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112  exit 1
113fi
114
115# Unset variables that we do not need and which cause bugs (e.g. in
116# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
117# suppresses any "Segmentation fault" message there.  '((' could
118# trigger a bug in pdksh 5.2.14.
119for as_var in BASH_ENV ENV MAIL MAILPATH
120do eval test x\${$as_var+set} = xset \
121  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122done
123PS1='$ '
124PS2='> '
125PS4='+ '
126
127# NLS nuisances.
128LC_ALL=C
129export LC_ALL
130LANGUAGE=C
131export LANGUAGE
132
133# CDPATH.
134(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
135
136if test "x$CONFIG_SHELL" = x; then
137  as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
138  emulate sh
139  NULLCMD=:
140  # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
141  # is contrary to our usage.  Disable this feature.
142  alias -g '\${1+\"\$@\"}'='\"\$@\"'
143  setopt NO_GLOB_SUBST
144else
145  case \`(set -o) 2>/dev/null\` in #(
146  *posix*) :
147    set -o posix ;; #(
148  *) :
149     ;;
150esac
151fi
152"
153  as_required="as_fn_return () { (exit \$1); }
154as_fn_success () { as_fn_return 0; }
155as_fn_failure () { as_fn_return 1; }
156as_fn_ret_success () { return 0; }
157as_fn_ret_failure () { return 1; }
158
159exitcode=0
160as_fn_success || { exitcode=1; echo as_fn_success failed.; }
161as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
162as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
163as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
164if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
165
166else
167  exitcode=1; echo positional parameters were not saved.
168fi
169test x\$exitcode = x0 || exit 1"
170  as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
171  as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
172  eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
173  test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
174test \$(( 1 + 1 )) = 2 || exit 1"
175  if (eval "$as_required") 2>/dev/null; then :
176  as_have_required=yes
177else
178  as_have_required=no
179fi
180  if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
181
182else
183  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
184as_found=false
185for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
186do
187  IFS=$as_save_IFS
188  test -z "$as_dir" && as_dir=.
189  as_found=:
190  case $as_dir in #(
191	 /*)
192	   for as_base in sh bash ksh sh5; do
193	     # Try only shells that exist, to save several forks.
194	     as_shell=$as_dir/$as_base
195	     if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
196		    { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
197  CONFIG_SHELL=$as_shell as_have_required=yes
198		   if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
199  break 2
200fi
201fi
202	   done;;
203       esac
204  as_found=false
205done
206$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
207	      { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
208  CONFIG_SHELL=$SHELL as_have_required=yes
209fi; }
210IFS=$as_save_IFS
211
212
213      if test "x$CONFIG_SHELL" != x; then :
214  # We cannot yet assume a decent shell, so we have to provide a
215	# neutralization value for shells without unset; and this also
216	# works around shells that cannot unset nonexistent variables.
217	BASH_ENV=/dev/null
218	ENV=/dev/null
219	(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
220	export CONFIG_SHELL
221	exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
222fi
223
224    if test x$as_have_required = xno; then :
225  $as_echo "$0: This script requires a shell more modern than all"
226  $as_echo "$0: the shells that I found on your system."
227  if test x${ZSH_VERSION+set} = xset ; then
228    $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
229    $as_echo "$0: be upgraded to zsh 4.3.4 or later."
230  else
231    $as_echo "$0: Please tell [email protected] about your system,
232$0: including any error possibly output before this
233$0: message. Then install a modern shell, or manually run
234$0: the script under such a shell if you do have one."
235  fi
236  exit 1
237fi
238fi
239fi
240SHELL=${CONFIG_SHELL-/bin/sh}
241export SHELL
242# Unset more variables known to interfere with behavior of common tools.
243CLICOLOR_FORCE= GREP_OPTIONS=
244unset CLICOLOR_FORCE GREP_OPTIONS
245
246## --------------------- ##
247## M4sh Shell Functions. ##
248## --------------------- ##
249# as_fn_unset VAR
250# ---------------
251# Portably unset VAR.
252as_fn_unset ()
253{
254  { eval $1=; unset $1;}
255}
256as_unset=as_fn_unset
257
258# as_fn_set_status STATUS
259# -----------------------
260# Set $? to STATUS, without forking.
261as_fn_set_status ()
262{
263  return $1
264} # as_fn_set_status
265
266# as_fn_exit STATUS
267# -----------------
268# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
269as_fn_exit ()
270{
271  set +e
272  as_fn_set_status $1
273  exit $1
274} # as_fn_exit
275
276# as_fn_mkdir_p
277# -------------
278# Create "$as_dir" as a directory, including parents if necessary.
279as_fn_mkdir_p ()
280{
281
282  case $as_dir in #(
283  -*) as_dir=./$as_dir;;
284  esac
285  test -d "$as_dir" || eval $as_mkdir_p || {
286    as_dirs=
287    while :; do
288      case $as_dir in #(
289      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
290      *) as_qdir=$as_dir;;
291      esac
292      as_dirs="'$as_qdir' $as_dirs"
293      as_dir=`$as_dirname -- "$as_dir" ||
294$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
295	 X"$as_dir" : 'X\(//\)[^/]' \| \
296	 X"$as_dir" : 'X\(//\)$' \| \
297	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
298$as_echo X"$as_dir" |
299    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
300	    s//\1/
301	    q
302	  }
303	  /^X\(\/\/\)[^/].*/{
304	    s//\1/
305	    q
306	  }
307	  /^X\(\/\/\)$/{
308	    s//\1/
309	    q
310	  }
311	  /^X\(\/\).*/{
312	    s//\1/
313	    q
314	  }
315	  s/.*/./; q'`
316      test -d "$as_dir" && break
317    done
318    test -z "$as_dirs" || eval "mkdir $as_dirs"
319  } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
320
321
322} # as_fn_mkdir_p
323# as_fn_append VAR VALUE
324# ----------------------
325# Append the text in VALUE to the end of the definition contained in VAR. Take
326# advantage of any shell optimizations that allow amortized linear growth over
327# repeated appends, instead of the typical quadratic growth present in naive
328# implementations.
329if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
330  eval 'as_fn_append ()
331  {
332    eval $1+=\$2
333  }'
334else
335  as_fn_append ()
336  {
337    eval $1=\$$1\$2
338  }
339fi # as_fn_append
340
341# as_fn_arith ARG...
342# ------------------
343# Perform arithmetic evaluation on the ARGs, and store the result in the
344# global $as_val. Take advantage of shells that can avoid forks. The arguments
345# must be portable across $(()) and expr.
346if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
347  eval 'as_fn_arith ()
348  {
349    as_val=$(( $* ))
350  }'
351else
352  as_fn_arith ()
353  {
354    as_val=`expr "$@" || test $? -eq 1`
355  }
356fi # as_fn_arith
357
358
359# as_fn_error ERROR [LINENO LOG_FD]
360# ---------------------------------
361# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
362# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
363# script with status $?, using 1 if that was 0.
364as_fn_error ()
365{
366  as_status=$?; test $as_status -eq 0 && as_status=1
367  if test "$3"; then
368    as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
369    $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
370  fi
371  $as_echo "$as_me: error: $1" >&2
372  as_fn_exit $as_status
373} # as_fn_error
374
375if expr a : '\(a\)' >/dev/null 2>&1 &&
376   test "X`expr 00001 : '.*\(...\)'`" = X001; then
377  as_expr=expr
378else
379  as_expr=false
380fi
381
382if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383  as_basename=basename
384else
385  as_basename=false
386fi
387
388if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
389  as_dirname=dirname
390else
391  as_dirname=false
392fi
393
394as_me=`$as_basename -- "$0" ||
395$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
396	 X"$0" : 'X\(//\)$' \| \
397	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
398$as_echo X/"$0" |
399    sed '/^.*\/\([^/][^/]*\)\/*$/{
400	    s//\1/
401	    q
402	  }
403	  /^X\/\(\/\/\)$/{
404	    s//\1/
405	    q
406	  }
407	  /^X\/\(\/\).*/{
408	    s//\1/
409	    q
410	  }
411	  s/.*/./; q'`
412
413# Avoid depending upon Character Ranges.
414as_cr_letters='abcdefghijklmnopqrstuvwxyz'
415as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
416as_cr_Letters=$as_cr_letters$as_cr_LETTERS
417as_cr_digits='0123456789'
418as_cr_alnum=$as_cr_Letters$as_cr_digits
419
420
421  as_lineno_1=$LINENO as_lineno_1a=$LINENO
422  as_lineno_2=$LINENO as_lineno_2a=$LINENO
423  eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
424  test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
425  # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
426  sed -n '
427    p
428    /[$]LINENO/=
429  ' <$as_myself |
430    sed '
431      s/[$]LINENO.*/&-/
432      t lineno
433      b
434      :lineno
435      N
436      :loop
437      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
438      t loop
439      s/-\n.*//
440    ' >$as_me.lineno &&
441  chmod +x "$as_me.lineno" ||
442    { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
443
444  # Don't try to exec as it changes $[0], causing all sort of problems
445  # (the dirname of $[0] is not the place where we might find the
446  # original and so on.  Autoconf is especially sensitive to this).
447  . "./$as_me.lineno"
448  # Exit status is that of the last command.
449  exit
450}
451
452ECHO_C= ECHO_N= ECHO_T=
453case `echo -n x` in #(((((
454-n*)
455  case `echo 'xy\c'` in
456  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
457  xy)  ECHO_C='\c';;
458  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
459       ECHO_T='	';;
460  esac;;
461*)
462  ECHO_N='-n';;
463esac
464
465rm -f conf$$ conf$$.exe conf$$.file
466if test -d conf$$.dir; then
467  rm -f conf$$.dir/conf$$.file
468else
469  rm -f conf$$.dir
470  mkdir conf$$.dir 2>/dev/null
471fi
472if (echo >conf$$.file) 2>/dev/null; then
473  if ln -s conf$$.file conf$$ 2>/dev/null; then
474    as_ln_s='ln -s'
475    # ... but there are two gotchas:
476    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
477    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
478    # In both cases, we have to default to `cp -p'.
479    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
480      as_ln_s='cp -p'
481  elif ln conf$$.file conf$$ 2>/dev/null; then
482    as_ln_s=ln
483  else
484    as_ln_s='cp -p'
485  fi
486else
487  as_ln_s='cp -p'
488fi
489rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490rmdir conf$$.dir 2>/dev/null
491
492if mkdir -p . 2>/dev/null; then
493  as_mkdir_p='mkdir -p "$as_dir"'
494else
495  test -d ./-p && rmdir ./-p
496  as_mkdir_p=false
497fi
498
499if test -x / >/dev/null 2>&1; then
500  as_test_x='test -x'
501else
502  if ls -dL / >/dev/null 2>&1; then
503    as_ls_L_option=L
504  else
505    as_ls_L_option=
506  fi
507  as_test_x='
508    eval sh -c '\''
509      if test -d "$1"; then
510	test -d "$1/.";
511      else
512	case $1 in #(
513	-*)set "./$1";;
514	esac;
515	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
516	???[sx]*):;;*)false;;esac;fi
517    '\'' sh
518  '
519fi
520as_executable_p=$as_test_x
521
522# Sed expression to map a string onto a valid CPP name.
523as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
524
525# Sed expression to map a string onto a valid variable name.
526as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
527
528
529test -n "$DJDIR" || exec 7<&0 </dev/null
530exec 6>&1
531
532# Name of the host.
533# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
534# so uname gets run too.
535ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
536
537#
538# Initializations.
539#
540ac_default_prefix=/usr/local
541ac_clean_files=
542ac_config_libobj_dir=.
543LIBOBJS=
544cross_compiling=no
545subdirs=
546MFLAGS=
547MAKEFLAGS=
548
549# Identity of this package.
550PACKAGE_NAME=
551PACKAGE_TARNAME=
552PACKAGE_VERSION=
553PACKAGE_STRING=
554PACKAGE_BUGREPORT=
555PACKAGE_URL=
556
557ac_unique_file="vim.h"
558# Factoring default headers for most tests.
559ac_includes_default="\
560#include <stdio.h>
561#ifdef HAVE_SYS_TYPES_H
562# include <sys/types.h>
563#endif
564#ifdef HAVE_SYS_STAT_H
565# include <sys/stat.h>
566#endif
567#ifdef STDC_HEADERS
568# include <stdlib.h>
569# include <stddef.h>
570#else
571# ifdef HAVE_STDLIB_H
572#  include <stdlib.h>
573# endif
574#endif
575#ifdef HAVE_STRING_H
576# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
577#  include <memory.h>
578# endif
579# include <string.h>
580#endif
581#ifdef HAVE_STRINGS_H
582# include <strings.h>
583#endif
584#ifdef HAVE_INTTYPES_H
585# include <inttypes.h>
586#endif
587#ifdef HAVE_STDINT_H
588# include <stdint.h>
589#endif
590#ifdef HAVE_UNISTD_H
591# include <unistd.h>
592#endif"
593
594ac_subst_vars='LTLIBOBJS
595LIBOBJS
596LINK_AS_NEEDED
597DEPEND_CFLAGS_FILTER
598MAKEMO
599MSGFMT
600INSTALL_TOOL_LANGS
601INSTALL_LANGS
602TAGPRG
603HANGULIN_OBJ
604HANGULIN_SRC
605GUI_X_LIBS
606GUITYPE
607GUI_LIB_LOC
608GUI_INC_LOC
609NARROW_PROTO
610MOTIF_LIBNAME
611GNOME_INCLUDEDIR
612GNOME_LIBDIR
613GNOME_LIBS
614GTK_LIBNAME
615GTK_LIBS
616GTK_CFLAGS
617PKG_CONFIG
618X_LIB
619X_EXTRA_LIBS
620X_LIBS
621X_PRE_LIBS
622X_CFLAGS
623XMKMF
624xmkmfpath
625SNIFF_OBJ
626SNIFF_SRC
627NETBEANS_OBJ
628NETBEANS_SRC
629WORKSHOP_OBJ
630WORKSHOP_SRC
631RUBY_LIBS
632RUBY_CFLAGS
633RUBY_PRO
634RUBY_OBJ
635RUBY_SRC
636vi_cv_path_ruby
637TCL_LIBS
638TCL_CFLAGS
639TCL_PRO
640TCL_OBJ
641TCL_SRC
642vi_cv_path_tcl
643PYTHON3_OBJ
644PYTHON3_SRC
645PYTHON3_CFLAGS
646PYTHON3_LIBS
647PYTHON3_CONFDIR
648vi_cv_path_python3
649PYTHON_OBJ
650PYTHON_SRC
651PYTHON_CFLAGS
652PYTHON_GETPATH_CFLAGS
653PYTHON_LIBS
654PYTHON_CONFDIR
655vi_cv_path_python
656PERL_LIBS
657PERL_CFLAGS
658PERL_PRO
659PERL_OBJ
660PERL_SRC
661shrpenv
662vi_cv_perllib
663vi_cv_path_perl
664MZSCHEME_MZC
665MZSCHEME_EXTRA
666MZSCHEME_CFLAGS
667MZSCHEME_LIBS
668MZSCHEME_PRO
669MZSCHEME_OBJ
670MZSCHEME_SRC
671vi_cv_path_mzscheme
672LUA_CFLAGS
673LUA_LIBS
674LUA_PRO
675LUA_OBJ
676LUA_SRC
677vi_cv_path_lua
678compiledby
679dogvimdiff
680dovimdiff
681QUOTESED
682line_break
683VIEWNAME
684EXNAME
685VIMNAME
686OS_EXTRA_OBJ
687OS_EXTRA_SRC
688XCODE_SELECT
689CPP_MM
690STRIP
691AWK
692EGREP
693GREP
694CPP
695OBJEXT
696EXEEXT
697ac_ct_CC
698CPPFLAGS
699LDFLAGS
700CFLAGS
701CC
702SET_MAKE
703target_alias
704host_alias
705build_alias
706LIBS
707ECHO_T
708ECHO_N
709ECHO_C
710DEFS
711mandir
712localedir
713libdir
714psdir
715pdfdir
716dvidir
717htmldir
718infodir
719docdir
720oldincludedir
721includedir
722localstatedir
723sharedstatedir
724sysconfdir
725datadir
726datarootdir
727libexecdir
728sbindir
729bindir
730program_transform_name
731prefix
732exec_prefix
733PACKAGE_URL
734PACKAGE_BUGREPORT
735PACKAGE_STRING
736PACKAGE_VERSION
737PACKAGE_TARNAME
738PACKAGE_NAME
739PATH_SEPARATOR
740SHELL'
741ac_subst_files=''
742ac_user_opts='
743enable_option_checking
744enable_fail_if_missing
745enable_darwin
746with_mac_arch
747with_developer_dir
748with_local_dir
749with_vim_name
750with_ex_name
751with_view_name
752with_global_runtime
753with_modified_by
754enable_selinux
755with_features
756with_compiledby
757enable_xsmp
758enable_xsmp_interact
759enable_luainterp
760with_lua_prefix
761enable_mzschemeinterp
762with_plthome
763enable_perlinterp
764enable_pythoninterp
765with_python_config_dir
766enable_python3interp
767with_python3_config_dir
768enable_tclinterp
769with_tclsh
770enable_rubyinterp
771with_ruby_command
772enable_cscope
773enable_workshop
774enable_netbeans
775enable_sniff
776enable_multibyte
777enable_hangulinput
778enable_xim
779enable_fontset
780with_x
781enable_gui
782enable_gtk2_check
783enable_gnome_check
784enable_motif_check
785enable_athena_check
786enable_nextaw_check
787enable_carbon_check
788enable_gtktest
789with_gnome_includes
790with_gnome_libs
791with_gnome
792with_motif_lib
793with_tlib
794enable_largefile
795enable_acl
796enable_gpm
797enable_sysmouse
798enable_nls
799'
800      ac_precious_vars='build_alias
801host_alias
802target_alias
803CC
804CFLAGS
805LDFLAGS
806LIBS
807CPPFLAGS
808CPP
809XMKMF'
810
811
812# Initialize some variables set by options.
813ac_init_help=
814ac_init_version=false
815ac_unrecognized_opts=
816ac_unrecognized_sep=
817# The variables have the same names as the options, with
818# dashes changed to underlines.
819cache_file=/dev/null
820exec_prefix=NONE
821no_create=
822no_recursion=
823prefix=NONE
824program_prefix=NONE
825program_suffix=NONE
826program_transform_name=s,x,x,
827silent=
828site=
829srcdir=
830verbose=
831x_includes=NONE
832x_libraries=NONE
833
834# Installation directory options.
835# These are left unexpanded so users can "make install exec_prefix=/foo"
836# and all the variables that are supposed to be based on exec_prefix
837# by default will actually change.
838# Use braces instead of parens because sh, perl, etc. also accept them.
839# (The list follows the same order as the GNU Coding Standards.)
840bindir='${exec_prefix}/bin'
841sbindir='${exec_prefix}/sbin'
842libexecdir='${exec_prefix}/libexec'
843datarootdir='${prefix}/share'
844datadir='${datarootdir}'
845sysconfdir='${prefix}/etc'
846sharedstatedir='${prefix}/com'
847localstatedir='${prefix}/var'
848includedir='${prefix}/include'
849oldincludedir='/usr/include'
850docdir='${datarootdir}/doc/${PACKAGE}'
851infodir='${datarootdir}/info'
852htmldir='${docdir}'
853dvidir='${docdir}'
854pdfdir='${docdir}'
855psdir='${docdir}'
856libdir='${exec_prefix}/lib'
857localedir='${datarootdir}/locale'
858mandir='${datarootdir}/man'
859
860ac_prev=
861ac_dashdash=
862for ac_option
863do
864  # If the previous option needs an argument, assign it.
865  if test -n "$ac_prev"; then
866    eval $ac_prev=\$ac_option
867    ac_prev=
868    continue
869  fi
870
871  case $ac_option in
872  *=*)	ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
873  *)	ac_optarg=yes ;;
874  esac
875
876  # Accept the important Cygnus configure options, so we can diagnose typos.
877
878  case $ac_dashdash$ac_option in
879  --)
880    ac_dashdash=yes ;;
881
882  -bindir | --bindir | --bindi | --bind | --bin | --bi)
883    ac_prev=bindir ;;
884  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
885    bindir=$ac_optarg ;;
886
887  -build | --build | --buil | --bui | --bu)
888    ac_prev=build_alias ;;
889  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
890    build_alias=$ac_optarg ;;
891
892  -cache-file | --cache-file | --cache-fil | --cache-fi \
893  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
894    ac_prev=cache_file ;;
895  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
896  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
897    cache_file=$ac_optarg ;;
898
899  --config-cache | -C)
900    cache_file=config.cache ;;
901
902  -datadir | --datadir | --datadi | --datad)
903    ac_prev=datadir ;;
904  -datadir=* | --datadir=* | --datadi=* | --datad=*)
905    datadir=$ac_optarg ;;
906
907  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
908  | --dataroo | --dataro | --datar)
909    ac_prev=datarootdir ;;
910  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
911  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
912    datarootdir=$ac_optarg ;;
913
914  -disable-* | --disable-*)
915    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
916    # Reject names that are not valid shell variable names.
917    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
918      as_fn_error "invalid feature name: $ac_useropt"
919    ac_useropt_orig=$ac_useropt
920    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
921    case $ac_user_opts in
922      *"
923"enable_$ac_useropt"
924"*) ;;
925      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
926	 ac_unrecognized_sep=', ';;
927    esac
928    eval enable_$ac_useropt=no ;;
929
930  -docdir | --docdir | --docdi | --doc | --do)
931    ac_prev=docdir ;;
932  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
933    docdir=$ac_optarg ;;
934
935  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
936    ac_prev=dvidir ;;
937  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
938    dvidir=$ac_optarg ;;
939
940  -enable-* | --enable-*)
941    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
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=`$as_echo "$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--enable-$ac_useropt_orig"
952	 ac_unrecognized_sep=', ';;
953    esac
954    eval enable_$ac_useropt=\$ac_optarg ;;
955
956  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
957  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
958  | --exec | --exe | --ex)
959    ac_prev=exec_prefix ;;
960  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
961  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
962  | --exec=* | --exe=* | --ex=*)
963    exec_prefix=$ac_optarg ;;
964
965  -gas | --gas | --ga | --g)
966    # Obsolete; use --with-gas.
967    with_gas=yes ;;
968
969  -help | --help | --hel | --he | -h)
970    ac_init_help=long ;;
971  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
972    ac_init_help=recursive ;;
973  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
974    ac_init_help=short ;;
975
976  -host | --host | --hos | --ho)
977    ac_prev=host_alias ;;
978  -host=* | --host=* | --hos=* | --ho=*)
979    host_alias=$ac_optarg ;;
980
981  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
982    ac_prev=htmldir ;;
983  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
984  | --ht=*)
985    htmldir=$ac_optarg ;;
986
987  -includedir | --includedir | --includedi | --included | --include \
988  | --includ | --inclu | --incl | --inc)
989    ac_prev=includedir ;;
990  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
991  | --includ=* | --inclu=* | --incl=* | --inc=*)
992    includedir=$ac_optarg ;;
993
994  -infodir | --infodir | --infodi | --infod | --info | --inf)
995    ac_prev=infodir ;;
996  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
997    infodir=$ac_optarg ;;
998
999  -libdir | --libdir | --libdi | --libd)
1000    ac_prev=libdir ;;
1001  -libdir=* | --libdir=* | --libdi=* | --libd=*)
1002    libdir=$ac_optarg ;;
1003
1004  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1005  | --libexe | --libex | --libe)
1006    ac_prev=libexecdir ;;
1007  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1008  | --libexe=* | --libex=* | --libe=*)
1009    libexecdir=$ac_optarg ;;
1010
1011  -localedir | --localedir | --localedi | --localed | --locale)
1012    ac_prev=localedir ;;
1013  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1014    localedir=$ac_optarg ;;
1015
1016  -localstatedir | --localstatedir | --localstatedi | --localstated \
1017  | --localstate | --localstat | --localsta | --localst | --locals)
1018    ac_prev=localstatedir ;;
1019  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1020  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1021    localstatedir=$ac_optarg ;;
1022
1023  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1024    ac_prev=mandir ;;
1025  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1026    mandir=$ac_optarg ;;
1027
1028  -nfp | --nfp | --nf)
1029    # Obsolete; use --without-fp.
1030    with_fp=no ;;
1031
1032  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1033  | --no-cr | --no-c | -n)
1034    no_create=yes ;;
1035
1036  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1037  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1038    no_recursion=yes ;;
1039
1040  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1041  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1042  | --oldin | --oldi | --old | --ol | --o)
1043    ac_prev=oldincludedir ;;
1044  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1045  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1046  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1047    oldincludedir=$ac_optarg ;;
1048
1049  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1050    ac_prev=prefix ;;
1051  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1052    prefix=$ac_optarg ;;
1053
1054  -program-prefix | --program-prefix | --program-prefi | --program-pref \
1055  | --program-pre | --program-pr | --program-p)
1056    ac_prev=program_prefix ;;
1057  -program-prefix=* | --program-prefix=* | --program-prefi=* \
1058  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1059    program_prefix=$ac_optarg ;;
1060
1061  -program-suffix | --program-suffix | --program-suffi | --program-suff \
1062  | --program-suf | --program-su | --program-s)
1063    ac_prev=program_suffix ;;
1064  -program-suffix=* | --program-suffix=* | --program-suffi=* \
1065  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1066    program_suffix=$ac_optarg ;;
1067
1068  -program-transform-name | --program-transform-name \
1069  | --program-transform-nam | --program-transform-na \
1070  | --program-transform-n | --program-transform- \
1071  | --program-transform | --program-transfor \
1072  | --program-transfo | --program-transf \
1073  | --program-trans | --program-tran \
1074  | --progr-tra | --program-tr | --program-t)
1075    ac_prev=program_transform_name ;;
1076  -program-transform-name=* | --program-transform-name=* \
1077  | --program-transform-nam=* | --program-transform-na=* \
1078  | --program-transform-n=* | --program-transform-=* \
1079  | --program-transform=* | --program-transfor=* \
1080  | --program-transfo=* | --program-transf=* \
1081  | --program-trans=* | --program-tran=* \
1082  | --progr-tra=* | --program-tr=* | --program-t=*)
1083    program_transform_name=$ac_optarg ;;
1084
1085  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1086    ac_prev=pdfdir ;;
1087  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1088    pdfdir=$ac_optarg ;;
1089
1090  -psdir | --psdir | --psdi | --psd | --ps)
1091    ac_prev=psdir ;;
1092  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1093    psdir=$ac_optarg ;;
1094
1095  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1096  | -silent | --silent | --silen | --sile | --sil)
1097    silent=yes ;;
1098
1099  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1100    ac_prev=sbindir ;;
1101  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1102  | --sbi=* | --sb=*)
1103    sbindir=$ac_optarg ;;
1104
1105  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1106  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1107  | --sharedst | --shareds | --shared | --share | --shar \
1108  | --sha | --sh)
1109    ac_prev=sharedstatedir ;;
1110  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1111  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1112  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1113  | --sha=* | --sh=*)
1114    sharedstatedir=$ac_optarg ;;
1115
1116  -site | --site | --sit)
1117    ac_prev=site ;;
1118  -site=* | --site=* | --sit=*)
1119    site=$ac_optarg ;;
1120
1121  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1122    ac_prev=srcdir ;;
1123  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1124    srcdir=$ac_optarg ;;
1125
1126  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1127  | --syscon | --sysco | --sysc | --sys | --sy)
1128    ac_prev=sysconfdir ;;
1129  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1130  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1131    sysconfdir=$ac_optarg ;;
1132
1133  -target | --target | --targe | --targ | --tar | --ta | --t)
1134    ac_prev=target_alias ;;
1135  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1136    target_alias=$ac_optarg ;;
1137
1138  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1139    verbose=yes ;;
1140
1141  -version | --version | --versio | --versi | --vers | -V)
1142    ac_init_version=: ;;
1143
1144  -with-* | --with-*)
1145    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1146    # Reject names that are not valid shell variable names.
1147    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1148      as_fn_error "invalid package name: $ac_useropt"
1149    ac_useropt_orig=$ac_useropt
1150    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1151    case $ac_user_opts in
1152      *"
1153"with_$ac_useropt"
1154"*) ;;
1155      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1156	 ac_unrecognized_sep=', ';;
1157    esac
1158    eval with_$ac_useropt=\$ac_optarg ;;
1159
1160  -without-* | --without-*)
1161    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1162    # Reject names that are not valid shell variable names.
1163    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1164      as_fn_error "invalid package name: $ac_useropt"
1165    ac_useropt_orig=$ac_useropt
1166    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1167    case $ac_user_opts in
1168      *"
1169"with_$ac_useropt"
1170"*) ;;
1171      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1172	 ac_unrecognized_sep=', ';;
1173    esac
1174    eval with_$ac_useropt=no ;;
1175
1176  --x)
1177    # Obsolete; use --with-x.
1178    with_x=yes ;;
1179
1180  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1181  | --x-incl | --x-inc | --x-in | --x-i)
1182    ac_prev=x_includes ;;
1183  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1184  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1185    x_includes=$ac_optarg ;;
1186
1187  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1188  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1189    ac_prev=x_libraries ;;
1190  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1191  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1192    x_libraries=$ac_optarg ;;
1193
1194  -*) as_fn_error "unrecognized option: \`$ac_option'
1195Try \`$0 --help' for more information."
1196    ;;
1197
1198  *=*)
1199    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1200    # Reject names that are not valid shell variable names.
1201    case $ac_envvar in #(
1202      '' | [0-9]* | *[!_$as_cr_alnum]* )
1203      as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1204    esac
1205    eval $ac_envvar=\$ac_optarg
1206    export $ac_envvar ;;
1207
1208  *)
1209    # FIXME: should be removed in autoconf 3.0.
1210    $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1211    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1212      $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1213    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1214    ;;
1215
1216  esac
1217done
1218
1219if test -n "$ac_prev"; then
1220  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1221  as_fn_error "missing argument to $ac_option"
1222fi
1223
1224if test -n "$ac_unrecognized_opts"; then
1225  case $enable_option_checking in
1226    no) ;;
1227    fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1228    *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1229  esac
1230fi
1231
1232# Check all directory arguments for consistency.
1233for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1234		datadir sysconfdir sharedstatedir localstatedir includedir \
1235		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1236		libdir localedir mandir
1237do
1238  eval ac_val=\$$ac_var
1239  # Remove trailing slashes.
1240  case $ac_val in
1241    */ )
1242      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1243      eval $ac_var=\$ac_val;;
1244  esac
1245  # Be sure to have absolute directory names.
1246  case $ac_val in
1247    [\\/$]* | ?:[\\/]* )  continue;;
1248    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1249  esac
1250  as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1251done
1252
1253# There might be people who depend on the old broken behavior: `$host'
1254# used to hold the argument of --host etc.
1255# FIXME: To remove some day.
1256build=$build_alias
1257host=$host_alias
1258target=$target_alias
1259
1260# FIXME: To remove some day.
1261if test "x$host_alias" != x; then
1262  if test "x$build_alias" = x; then
1263    cross_compiling=maybe
1264    $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1265    If a cross compiler is detected then cross compile mode will be used." >&2
1266  elif test "x$build_alias" != "x$host_alias"; then
1267    cross_compiling=yes
1268  fi
1269fi
1270
1271ac_tool_prefix=
1272test -n "$host_alias" && ac_tool_prefix=$host_alias-
1273
1274test "$silent" = yes && exec 6>/dev/null
1275
1276
1277ac_pwd=`pwd` && test -n "$ac_pwd" &&
1278ac_ls_di=`ls -di .` &&
1279ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1280  as_fn_error "working directory cannot be determined"
1281test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1282  as_fn_error "pwd does not report name of working directory"
1283
1284
1285# Find the source files, if location was not specified.
1286if test -z "$srcdir"; then
1287  ac_srcdir_defaulted=yes
1288  # Try the directory containing this script, then the parent directory.
1289  ac_confdir=`$as_dirname -- "$as_myself" ||
1290$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1291	 X"$as_myself" : 'X\(//\)[^/]' \| \
1292	 X"$as_myself" : 'X\(//\)$' \| \
1293	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1294$as_echo X"$as_myself" |
1295    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1296	    s//\1/
1297	    q
1298	  }
1299	  /^X\(\/\/\)[^/].*/{
1300	    s//\1/
1301	    q
1302	  }
1303	  /^X\(\/\/\)$/{
1304	    s//\1/
1305	    q
1306	  }
1307	  /^X\(\/\).*/{
1308	    s//\1/
1309	    q
1310	  }
1311	  s/.*/./; q'`
1312  srcdir=$ac_confdir
1313  if test ! -r "$srcdir/$ac_unique_file"; then
1314    srcdir=..
1315  fi
1316else
1317  ac_srcdir_defaulted=no
1318fi
1319if test ! -r "$srcdir/$ac_unique_file"; then
1320  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1321  as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1322fi
1323ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1324ac_abs_confdir=`(
1325	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1326	pwd)`
1327# When building in place, set srcdir=.
1328if test "$ac_abs_confdir" = "$ac_pwd"; then
1329  srcdir=.
1330fi
1331# Remove unnecessary trailing slashes from srcdir.
1332# Double slashes in file names in object file debugging info
1333# mess up M-x gdb in Emacs.
1334case $srcdir in
1335*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1336esac
1337for ac_var in $ac_precious_vars; do
1338  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1339  eval ac_env_${ac_var}_value=\$${ac_var}
1340  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1341  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1342done
1343
1344#
1345# Report the --help message.
1346#
1347if test "$ac_init_help" = "long"; then
1348  # Omit some internal or obsolete options to make the list less imposing.
1349  # This message is too long to be a string in the A/UX 3.1 sh.
1350  cat <<_ACEOF
1351\`configure' configures this package to adapt to many kinds of systems.
1352
1353Usage: $0 [OPTION]... [VAR=VALUE]...
1354
1355To assign environment variables (e.g., CC, CFLAGS...), specify them as
1356VAR=VALUE.  See below for descriptions of some of the useful variables.
1357
1358Defaults for the options are specified in brackets.
1359
1360Configuration:
1361  -h, --help              display this help and exit
1362      --help=short        display options specific to this package
1363      --help=recursive    display the short help of all the included packages
1364  -V, --version           display version information and exit
1365  -q, --quiet, --silent   do not print \`checking...' messages
1366      --cache-file=FILE   cache test results in FILE [disabled]
1367  -C, --config-cache      alias for \`--cache-file=config.cache'
1368  -n, --no-create         do not create output files
1369      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1370
1371Installation directories:
1372  --prefix=PREFIX         install architecture-independent files in PREFIX
1373                          [$ac_default_prefix]
1374  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1375                          [PREFIX]
1376
1377By default, \`make install' will install all the files in
1378\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1379an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1380for instance \`--prefix=\$HOME'.
1381
1382For better control, use the options below.
1383
1384Fine tuning of the installation directories:
1385  --bindir=DIR            user executables [EPREFIX/bin]
1386  --sbindir=DIR           system admin executables [EPREFIX/sbin]
1387  --libexecdir=DIR        program executables [EPREFIX/libexec]
1388  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1389  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1390  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1391  --libdir=DIR            object code libraries [EPREFIX/lib]
1392  --includedir=DIR        C header files [PREFIX/include]
1393  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1394  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1395  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1396  --infodir=DIR           info documentation [DATAROOTDIR/info]
1397  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1398  --mandir=DIR            man documentation [DATAROOTDIR/man]
1399  --docdir=DIR            documentation root [DATAROOTDIR/doc/PACKAGE]
1400  --htmldir=DIR           html documentation [DOCDIR]
1401  --dvidir=DIR            dvi documentation [DOCDIR]
1402  --pdfdir=DIR            pdf documentation [DOCDIR]
1403  --psdir=DIR             ps documentation [DOCDIR]
1404_ACEOF
1405
1406  cat <<\_ACEOF
1407
1408X features:
1409  --x-includes=DIR    X include files are in DIR
1410  --x-libraries=DIR   X library files are in DIR
1411_ACEOF
1412fi
1413
1414if test -n "$ac_init_help"; then
1415
1416  cat <<\_ACEOF
1417
1418Optional Features:
1419  --disable-option-checking  ignore unrecognized --enable/--with options
1420  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1421  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1422  --enable-fail-if-missing    Fail if dependencies on additional features
1423     specified on the command line are missing.
1424  --disable-darwin        Disable Darwin (Mac OS X) support.
1425  --disable-selinux	  Don't check for SELinux support.
1426  --disable-xsmp          Disable XSMP session management
1427  --disable-xsmp-interact Disable XSMP interaction
1428  --enable-luainterp=OPTS     Include Lua interpreter.  default=no OPTS=no/yes/dynamic
1429  --enable-mzschemeinterp   Include MzScheme interpreter.
1430  --enable-perlinterp=OPTS     Include Perl interpreter.  default=no OPTS=no/yes/dynamic
1431  --enable-pythoninterp=OPTS   Include Python interpreter. default=no OPTS=no/yes/dynamic
1432  --enable-python3interp=OPTS   Include Python3 interpreter. default=no OPTS=no/yes/dynamic
1433  --enable-tclinterp      Include Tcl interpreter.
1434  --enable-rubyinterp=OPTS     Include Ruby interpreter.  default=no OPTS=no/yes/dynamic
1435  --enable-cscope         Include cscope interface.
1436  --enable-workshop       Include Sun Visual Workshop support.
1437  --disable-netbeans      Disable NetBeans integration support.
1438  --enable-sniff          Include Sniff interface.
1439  --enable-multibyte      Include multibyte editing support.
1440  --enable-hangulinput    Include Hangul input support.
1441  --enable-xim            Include XIM input support.
1442  --enable-fontset        Include X fontset output support.
1443  --enable-gui=OPTS     X11 GUI default=auto OPTS=auto/no/gtk2/gnome2/motif/athena/neXtaw/photon/carbon
1444  --enable-gtk2-check     If auto-select GUI, check for GTK+ 2 default=yes
1445  --enable-gnome-check    If GTK GUI, check for GNOME default=no
1446  --enable-motif-check    If auto-select GUI, check for Motif default=yes
1447  --enable-athena-check   If auto-select GUI, check for Athena default=yes
1448  --enable-nextaw-check   If auto-select GUI, check for neXtaw default=yes
1449  --enable-carbon-check   If auto-select GUI, check for Carbon default=yes
1450  --disable-gtktest       Do not try to compile and run a test GTK program
1451  --disable-largefile     omit support for large files
1452  --disable-acl           Don't check for ACL support.
1453  --disable-gpm           Don't use gpm (Linux mouse daemon).
1454  --disable-sysmouse    Don't use sysmouse (mouse in *BSD console).
1455  --disable-nls           Don't support NLS (gettext()).
1456
1457Optional Packages:
1458  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1459  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1460  --with-mac-arch=ARCH    current, intel, ppc or both
1461  --with-developer-dir=PATH    use PATH as location for Xcode developer tools
1462  --with-local-dir=PATH   search PATH instead of /usr/local for local libraries.
1463  --without-local-dir     do not search /usr/local for local libraries.
1464  --with-vim-name=NAME    what to call the Vim executable
1465  --with-ex-name=NAME     what to call the Ex executable
1466  --with-view-name=NAME   what to call the View executable
1467  --with-global-runtime=DIR    global runtime directory in 'runtimepath'
1468  --with-modified-by=NAME       name of who modified a release version
1469  --with-features=TYPE    tiny, small, normal, big or huge (default: normal)
1470  --with-compiledby=NAME  name to show in :version message
1471  --with-lua-prefix=PFX   Prefix where Lua is installed.
1472  --with-plthome=PLTHOME   Use PLTHOME.
1473  --with-python-config-dir=PATH  Python's config directory
1474  --with-python3-config-dir=PATH  Python's config directory
1475  --with-tclsh=PATH       which tclsh to use (default: tclsh8.0)
1476  --with-ruby-command=RUBY  name of the Ruby command (default: ruby)
1477  --with-x                use the X Window System
1478  --with-gnome-includes=DIR Specify location of GNOME headers
1479  --with-gnome-libs=DIR   Specify location of GNOME libs
1480  --with-gnome            Specify prefix for GNOME files
1481  --with-motif-lib=STRING   Library for Motif
1482  --with-tlib=library     terminal library to be used
1483
1484Some influential environment variables:
1485  CC          C compiler command
1486  CFLAGS      C compiler flags
1487  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1488              nonstandard directory <lib dir>
1489  LIBS        libraries to pass to the linker, e.g. -l<library>
1490  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1491              you have headers in a nonstandard directory <include dir>
1492  CPP         C preprocessor
1493  XMKMF       Path to xmkmf, Makefile generator for X Window System
1494
1495Use these variables to override the choices made by `configure' or to help
1496it to find libraries and programs with nonstandard names/locations.
1497
1498Report bugs to the package provider.
1499_ACEOF
1500ac_status=$?
1501fi
1502
1503if test "$ac_init_help" = "recursive"; then
1504  # If there are subdirs, report their specific --help.
1505  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1506    test -d "$ac_dir" ||
1507      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1508      continue
1509    ac_builddir=.
1510
1511case "$ac_dir" in
1512.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1513*)
1514  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1515  # A ".." for each directory in $ac_dir_suffix.
1516  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1517  case $ac_top_builddir_sub in
1518  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1519  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1520  esac ;;
1521esac
1522ac_abs_top_builddir=$ac_pwd
1523ac_abs_builddir=$ac_pwd$ac_dir_suffix
1524# for backward compatibility:
1525ac_top_builddir=$ac_top_build_prefix
1526
1527case $srcdir in
1528  .)  # We are building in place.
1529    ac_srcdir=.
1530    ac_top_srcdir=$ac_top_builddir_sub
1531    ac_abs_top_srcdir=$ac_pwd ;;
1532  [\\/]* | ?:[\\/]* )  # Absolute name.
1533    ac_srcdir=$srcdir$ac_dir_suffix;
1534    ac_top_srcdir=$srcdir
1535    ac_abs_top_srcdir=$srcdir ;;
1536  *) # Relative name.
1537    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1538    ac_top_srcdir=$ac_top_build_prefix$srcdir
1539    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1540esac
1541ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1542
1543    cd "$ac_dir" || { ac_status=$?; continue; }
1544    # Check for guested configure.
1545    if test -f "$ac_srcdir/configure.gnu"; then
1546      echo &&
1547      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1548    elif test -f "$ac_srcdir/configure"; then
1549      echo &&
1550      $SHELL "$ac_srcdir/configure" --help=recursive
1551    else
1552      $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1553    fi || ac_status=$?
1554    cd "$ac_pwd" || { ac_status=$?; break; }
1555  done
1556fi
1557
1558test -n "$ac_init_help" && exit $ac_status
1559if $ac_init_version; then
1560  cat <<\_ACEOF
1561configure
1562generated by GNU Autoconf 2.65
1563
1564Copyright (C) 2009 Free Software Foundation, Inc.
1565This configure script is free software; the Free Software Foundation
1566gives unlimited permission to copy, distribute and modify it.
1567_ACEOF
1568  exit
1569fi
1570
1571## ------------------------ ##
1572## Autoconf initialization. ##
1573## ------------------------ ##
1574
1575# ac_fn_c_try_compile LINENO
1576# --------------------------
1577# Try to compile conftest.$ac_ext, and return whether this succeeded.
1578ac_fn_c_try_compile ()
1579{
1580  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1581  rm -f conftest.$ac_objext
1582  if { { ac_try="$ac_compile"
1583case "(($ac_try" in
1584  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1585  *) ac_try_echo=$ac_try;;
1586esac
1587eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1588$as_echo "$ac_try_echo"; } >&5
1589  (eval "$ac_compile") 2>conftest.err
1590  ac_status=$?
1591  if test -s conftest.err; then
1592    grep -v '^ *+' conftest.err >conftest.er1
1593    cat conftest.er1 >&5
1594    mv -f conftest.er1 conftest.err
1595  fi
1596  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1597  test $ac_status = 0; } && {
1598	 test -z "$ac_c_werror_flag" ||
1599	 test ! -s conftest.err
1600       } && test -s conftest.$ac_objext; then :
1601  ac_retval=0
1602else
1603  $as_echo "$as_me: failed program was:" >&5
1604sed 's/^/| /' conftest.$ac_ext >&5
1605
1606	ac_retval=1
1607fi
1608  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1609  as_fn_set_status $ac_retval
1610
1611} # ac_fn_c_try_compile
1612
1613# ac_fn_c_try_cpp LINENO
1614# ----------------------
1615# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1616ac_fn_c_try_cpp ()
1617{
1618  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1619  if { { ac_try="$ac_cpp conftest.$ac_ext"
1620case "(($ac_try" in
1621  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1622  *) ac_try_echo=$ac_try;;
1623esac
1624eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1625$as_echo "$ac_try_echo"; } >&5
1626  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1627  ac_status=$?
1628  if test -s conftest.err; then
1629    grep -v '^ *+' conftest.err >conftest.er1
1630    cat conftest.er1 >&5
1631    mv -f conftest.er1 conftest.err
1632  fi
1633  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1634  test $ac_status = 0; } >/dev/null && {
1635	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1636	 test ! -s conftest.err
1637       }; then :
1638  ac_retval=0
1639else
1640  $as_echo "$as_me: failed program was:" >&5
1641sed 's/^/| /' conftest.$ac_ext >&5
1642
1643    ac_retval=1
1644fi
1645  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1646  as_fn_set_status $ac_retval
1647
1648} # ac_fn_c_try_cpp
1649
1650# ac_fn_c_try_link LINENO
1651# -----------------------
1652# Try to link conftest.$ac_ext, and return whether this succeeded.
1653ac_fn_c_try_link ()
1654{
1655  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1656  rm -f conftest.$ac_objext conftest$ac_exeext
1657  if { { ac_try="$ac_link"
1658case "(($ac_try" in
1659  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1660  *) ac_try_echo=$ac_try;;
1661esac
1662eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1663$as_echo "$ac_try_echo"; } >&5
1664  (eval "$ac_link") 2>conftest.err
1665  ac_status=$?
1666  if test -s conftest.err; then
1667    grep -v '^ *+' conftest.err >conftest.er1
1668    cat conftest.er1 >&5
1669    mv -f conftest.er1 conftest.err
1670  fi
1671  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1672  test $ac_status = 0; } && {
1673	 test -z "$ac_c_werror_flag" ||
1674	 test ! -s conftest.err
1675       } && test -s conftest$ac_exeext && {
1676	 test "$cross_compiling" = yes ||
1677	 $as_test_x conftest$ac_exeext
1678       }; then :
1679  ac_retval=0
1680else
1681  $as_echo "$as_me: failed program was:" >&5
1682sed 's/^/| /' conftest.$ac_ext >&5
1683
1684	ac_retval=1
1685fi
1686  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1687  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1688  # interfere with the next link command; also delete a directory that is
1689  # left behind by Apple's compiler.  We do this before executing the actions.
1690  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1691  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1692  as_fn_set_status $ac_retval
1693
1694} # ac_fn_c_try_link
1695
1696# ac_fn_c_try_run LINENO
1697# ----------------------
1698# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1699# that executables *can* be run.
1700ac_fn_c_try_run ()
1701{
1702  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1703  if { { ac_try="$ac_link"
1704case "(($ac_try" in
1705  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1706  *) ac_try_echo=$ac_try;;
1707esac
1708eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1709$as_echo "$ac_try_echo"; } >&5
1710  (eval "$ac_link") 2>&5
1711  ac_status=$?
1712  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1713  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1714  { { case "(($ac_try" in
1715  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1716  *) ac_try_echo=$ac_try;;
1717esac
1718eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1719$as_echo "$ac_try_echo"; } >&5
1720  (eval "$ac_try") 2>&5
1721  ac_status=$?
1722  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1723  test $ac_status = 0; }; }; then :
1724  ac_retval=0
1725else
1726  $as_echo "$as_me: program exited with status $ac_status" >&5
1727       $as_echo "$as_me: failed program was:" >&5
1728sed 's/^/| /' conftest.$ac_ext >&5
1729
1730       ac_retval=$ac_status
1731fi
1732  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1733  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1734  as_fn_set_status $ac_retval
1735
1736} # ac_fn_c_try_run
1737
1738# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1739# -------------------------------------------------------
1740# Tests whether HEADER exists, giving a warning if it cannot be compiled using
1741# the include files in INCLUDES and setting the cache variable VAR
1742# accordingly.
1743ac_fn_c_check_header_mongrel ()
1744{
1745  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1746  if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1747  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1748$as_echo_n "checking for $2... " >&6; }
1749if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1750  $as_echo_n "(cached) " >&6
1751fi
1752eval ac_res=\$$3
1753	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1754$as_echo "$ac_res" >&6; }
1755else
1756  # Is the header compilable?
1757{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1758$as_echo_n "checking $2 usability... " >&6; }
1759cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1760/* end confdefs.h.  */
1761$4
1762#include <$2>
1763_ACEOF
1764if ac_fn_c_try_compile "$LINENO"; then :
1765  ac_header_compiler=yes
1766else
1767  ac_header_compiler=no
1768fi
1769rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1770{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1771$as_echo "$ac_header_compiler" >&6; }
1772
1773# Is the header present?
1774{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1775$as_echo_n "checking $2 presence... " >&6; }
1776cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1777/* end confdefs.h.  */
1778#include <$2>
1779_ACEOF
1780if ac_fn_c_try_cpp "$LINENO"; then :
1781  ac_header_preproc=yes
1782else
1783  ac_header_preproc=no
1784fi
1785rm -f conftest.err conftest.$ac_ext
1786{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1787$as_echo "$ac_header_preproc" >&6; }
1788
1789# So?  What about this header?
1790case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1791  yes:no: )
1792    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1793$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1794    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1795$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1796    ;;
1797  no:yes:* )
1798    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1799$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1800    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1801$as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1802    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1803$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1804    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1805$as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1806    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1807$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1808    ;;
1809esac
1810  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1811$as_echo_n "checking for $2... " >&6; }
1812if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1813  $as_echo_n "(cached) " >&6
1814else
1815  eval "$3=\$ac_header_compiler"
1816fi
1817eval ac_res=\$$3
1818	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1819$as_echo "$ac_res" >&6; }
1820fi
1821  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1822
1823} # ac_fn_c_check_header_mongrel
1824
1825# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1826# -------------------------------------------------------
1827# Tests whether HEADER exists and can be compiled using the include files in
1828# INCLUDES, setting the cache variable VAR accordingly.
1829ac_fn_c_check_header_compile ()
1830{
1831  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1832  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1833$as_echo_n "checking for $2... " >&6; }
1834if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1835  $as_echo_n "(cached) " >&6
1836else
1837  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1838/* end confdefs.h.  */
1839$4
1840#include <$2>
1841_ACEOF
1842if ac_fn_c_try_compile "$LINENO"; then :
1843  eval "$3=yes"
1844else
1845  eval "$3=no"
1846fi
1847rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1848fi
1849eval ac_res=\$$3
1850	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1851$as_echo "$ac_res" >&6; }
1852  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1853
1854} # ac_fn_c_check_header_compile
1855
1856# ac_fn_c_check_func LINENO FUNC VAR
1857# ----------------------------------
1858# Tests whether FUNC exists, setting the cache variable VAR accordingly
1859ac_fn_c_check_func ()
1860{
1861  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1862  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1863$as_echo_n "checking for $2... " >&6; }
1864if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1865  $as_echo_n "(cached) " >&6
1866else
1867  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1868/* end confdefs.h.  */
1869/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1870   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
1871#define $2 innocuous_$2
1872
1873/* System header to define __stub macros and hopefully few prototypes,
1874    which can conflict with char $2 (); below.
1875    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
1876    <limits.h> exists even on freestanding compilers.  */
1877
1878#ifdef __STDC__
1879# include <limits.h>
1880#else
1881# include <assert.h>
1882#endif
1883
1884#undef $2
1885
1886/* Override any GCC internal prototype to avoid an error.
1887   Use char because int might match the return type of a GCC
1888   builtin and then its argument prototype would still apply.  */
1889#ifdef __cplusplus
1890extern "C"
1891#endif
1892char $2 ();
1893/* The GNU C library defines this for functions which it implements
1894    to always fail with ENOSYS.  Some functions are actually named
1895    something starting with __ and the normal name is an alias.  */
1896#if defined __stub_$2 || defined __stub___$2
1897choke me
1898#endif
1899
1900int
1901main ()
1902{
1903return $2 ();
1904  ;
1905  return 0;
1906}
1907_ACEOF
1908if ac_fn_c_try_link "$LINENO"; then :
1909  eval "$3=yes"
1910else
1911  eval "$3=no"
1912fi
1913rm -f core conftest.err conftest.$ac_objext \
1914    conftest$ac_exeext conftest.$ac_ext
1915fi
1916eval ac_res=\$$3
1917	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1918$as_echo "$ac_res" >&6; }
1919  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1920
1921} # ac_fn_c_check_func
1922
1923# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1924# -------------------------------------------
1925# Tests whether TYPE exists after having included INCLUDES, setting cache
1926# variable VAR accordingly.
1927ac_fn_c_check_type ()
1928{
1929  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1930  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1931$as_echo_n "checking for $2... " >&6; }
1932if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1933  $as_echo_n "(cached) " >&6
1934else
1935  eval "$3=no"
1936  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1937/* end confdefs.h.  */
1938$4
1939int
1940main ()
1941{
1942if (sizeof ($2))
1943	 return 0;
1944  ;
1945  return 0;
1946}
1947_ACEOF
1948if ac_fn_c_try_compile "$LINENO"; then :
1949  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1950/* end confdefs.h.  */
1951$4
1952int
1953main ()
1954{
1955if (sizeof (($2)))
1956	    return 0;
1957  ;
1958  return 0;
1959}
1960_ACEOF
1961if ac_fn_c_try_compile "$LINENO"; then :
1962
1963else
1964  eval "$3=yes"
1965fi
1966rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1967fi
1968rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1969fi
1970eval ac_res=\$$3
1971	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1972$as_echo "$ac_res" >&6; }
1973  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1974
1975} # ac_fn_c_check_type
1976
1977# ac_fn_c_find_uintX_t LINENO BITS VAR
1978# ------------------------------------
1979# Finds an unsigned integer type with width BITS, setting cache variable VAR
1980# accordingly.
1981ac_fn_c_find_uintX_t ()
1982{
1983  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1984  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5
1985$as_echo_n "checking for uint$2_t... " >&6; }
1986if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1987  $as_echo_n "(cached) " >&6
1988else
1989  eval "$3=no"
1990     # Order is important - never check a type that is potentially smaller
1991     # than half of the expected target width.
1992     for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \
1993	 'unsigned long long int' 'unsigned short int' 'unsigned char'; do
1994       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1995/* end confdefs.h.  */
1996$ac_includes_default
1997int
1998main ()
1999{
2000static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)];
2001test_array [0] = 0
2002
2003  ;
2004  return 0;
2005}
2006_ACEOF
2007if ac_fn_c_try_compile "$LINENO"; then :
2008  case $ac_type in #(
2009  uint$2_t) :
2010    eval "$3=yes" ;; #(
2011  *) :
2012    eval "$3=\$ac_type" ;;
2013esac
2014fi
2015rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2016       eval as_val=\$$3
2017   if test "x$as_val" = x""no; then :
2018
2019else
2020  break
2021fi
2022     done
2023fi
2024eval ac_res=\$$3
2025	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2026$as_echo "$ac_res" >&6; }
2027  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2028
2029} # ac_fn_c_find_uintX_t
2030
2031# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2032# --------------------------------------------
2033# Tries to find the compile-time value of EXPR in a program that includes
2034# INCLUDES, setting VAR accordingly. Returns whether the value could be
2035# computed
2036ac_fn_c_compute_int ()
2037{
2038  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2039  if test "$cross_compiling" = yes; then
2040    # Depending upon the size, compute the lo and hi bounds.
2041cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2042/* end confdefs.h.  */
2043$4
2044int
2045main ()
2046{
2047static int test_array [1 - 2 * !(($2) >= 0)];
2048test_array [0] = 0
2049
2050  ;
2051  return 0;
2052}
2053_ACEOF
2054if ac_fn_c_try_compile "$LINENO"; then :
2055  ac_lo=0 ac_mid=0
2056  while :; do
2057    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2058/* end confdefs.h.  */
2059$4
2060int
2061main ()
2062{
2063static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2064test_array [0] = 0
2065
2066  ;
2067  return 0;
2068}
2069_ACEOF
2070if ac_fn_c_try_compile "$LINENO"; then :
2071  ac_hi=$ac_mid; break
2072else
2073  as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2074			if test $ac_lo -le $ac_mid; then
2075			  ac_lo= ac_hi=
2076			  break
2077			fi
2078			as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2079fi
2080rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2081  done
2082else
2083  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2084/* end confdefs.h.  */
2085$4
2086int
2087main ()
2088{
2089static int test_array [1 - 2 * !(($2) < 0)];
2090test_array [0] = 0
2091
2092  ;
2093  return 0;
2094}
2095_ACEOF
2096if ac_fn_c_try_compile "$LINENO"; then :
2097  ac_hi=-1 ac_mid=-1
2098  while :; do
2099    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2100/* end confdefs.h.  */
2101$4
2102int
2103main ()
2104{
2105static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2106test_array [0] = 0
2107
2108  ;
2109  return 0;
2110}
2111_ACEOF
2112if ac_fn_c_try_compile "$LINENO"; then :
2113  ac_lo=$ac_mid; break
2114else
2115  as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2116			if test $ac_mid -le $ac_hi; then
2117			  ac_lo= ac_hi=
2118			  break
2119			fi
2120			as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2121fi
2122rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2123  done
2124else
2125  ac_lo= ac_hi=
2126fi
2127rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2128fi
2129rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2130# Binary search between lo and hi bounds.
2131while test "x$ac_lo" != "x$ac_hi"; do
2132  as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2133  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2134/* end confdefs.h.  */
2135$4
2136int
2137main ()
2138{
2139static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2140test_array [0] = 0
2141
2142  ;
2143  return 0;
2144}
2145_ACEOF
2146if ac_fn_c_try_compile "$LINENO"; then :
2147  ac_hi=$ac_mid
2148else
2149  as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2150fi
2151rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2152done
2153case $ac_lo in #((
2154?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2155'') ac_retval=1 ;;
2156esac
2157  else
2158    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2159/* end confdefs.h.  */
2160$4
2161static long int longval () { return $2; }
2162static unsigned long int ulongval () { return $2; }
2163#include <stdio.h>
2164#include <stdlib.h>
2165int
2166main ()
2167{
2168
2169  FILE *f = fopen ("conftest.val", "w");
2170  if (! f)
2171    return 1;
2172  if (($2) < 0)
2173    {
2174      long int i = longval ();
2175      if (i != ($2))
2176	return 1;
2177      fprintf (f, "%ld", i);
2178    }
2179  else
2180    {
2181      unsigned long int i = ulongval ();
2182      if (i != ($2))
2183	return 1;
2184      fprintf (f, "%lu", i);
2185    }
2186  /* Do not output a trailing newline, as this causes \r\n confusion
2187     on some platforms.  */
2188  return ferror (f) || fclose (f) != 0;
2189
2190  ;
2191  return 0;
2192}
2193_ACEOF
2194if ac_fn_c_try_run "$LINENO"; then :
2195  echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2196else
2197  ac_retval=1
2198fi
2199rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2200  conftest.$ac_objext conftest.beam conftest.$ac_ext
2201rm -f conftest.val
2202
2203  fi
2204  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2205  as_fn_set_status $ac_retval
2206
2207} # ac_fn_c_compute_int
2208cat >auto/config.log <<_ACEOF
2209This file contains any messages produced by compilers while
2210running configure, to aid debugging if configure makes a mistake.
2211
2212It was created by $as_me, which was
2213generated by GNU Autoconf 2.65.  Invocation command line was
2214
2215  $ $0 $@
2216
2217_ACEOF
2218exec 5>>auto/config.log
2219{
2220cat <<_ASUNAME
2221## --------- ##
2222## Platform. ##
2223## --------- ##
2224
2225hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2226uname -m = `(uname -m) 2>/dev/null || echo unknown`
2227uname -r = `(uname -r) 2>/dev/null || echo unknown`
2228uname -s = `(uname -s) 2>/dev/null || echo unknown`
2229uname -v = `(uname -v) 2>/dev/null || echo unknown`
2230
2231/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2232/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2233
2234/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2235/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2236/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2237/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2238/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2239/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2240/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2241
2242_ASUNAME
2243
2244as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2245for as_dir in $PATH
2246do
2247  IFS=$as_save_IFS
2248  test -z "$as_dir" && as_dir=.
2249    $as_echo "PATH: $as_dir"
2250  done
2251IFS=$as_save_IFS
2252
2253} >&5
2254
2255cat >&5 <<_ACEOF
2256
2257
2258## ----------- ##
2259## Core tests. ##
2260## ----------- ##
2261
2262_ACEOF
2263
2264
2265# Keep a trace of the command line.
2266# Strip out --no-create and --no-recursion so they do not pile up.
2267# Strip out --silent because we don't want to record it for future runs.
2268# Also quote any args containing shell meta-characters.
2269# Make two passes to allow for proper duplicate-argument suppression.
2270ac_configure_args=
2271ac_configure_args0=
2272ac_configure_args1=
2273ac_must_keep_next=false
2274for ac_pass in 1 2
2275do
2276  for ac_arg
2277  do
2278    case $ac_arg in
2279    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2280    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2281    | -silent | --silent | --silen | --sile | --sil)
2282      continue ;;
2283    *\'*)
2284      ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2285    esac
2286    case $ac_pass in
2287    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2288    2)
2289      as_fn_append ac_configure_args1 " '$ac_arg'"
2290      if test $ac_must_keep_next = true; then
2291	ac_must_keep_next=false # Got value, back to normal.
2292      else
2293	case $ac_arg in
2294	  *=* | --config-cache | -C | -disable-* | --disable-* \
2295	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2296	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2297	  | -with-* | --with-* | -without-* | --without-* | --x)
2298	    case "$ac_configure_args0 " in
2299	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2300	    esac
2301	    ;;
2302	  -* ) ac_must_keep_next=true ;;
2303	esac
2304      fi
2305      as_fn_append ac_configure_args " '$ac_arg'"
2306      ;;
2307    esac
2308  done
2309done
2310{ ac_configure_args0=; unset ac_configure_args0;}
2311{ ac_configure_args1=; unset ac_configure_args1;}
2312
2313# When interrupted or exit'd, cleanup temporary files, and complete
2314# config.log.  We remove comments because anyway the quotes in there
2315# would cause problems or look ugly.
2316# WARNING: Use '\'' to represent an apostrophe within the trap.
2317# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2318trap 'exit_status=$?
2319  # Save into config.log some information that might help in debugging.
2320  {
2321    echo
2322
2323    cat <<\_ASBOX
2324## ---------------- ##
2325## Cache variables. ##
2326## ---------------- ##
2327_ASBOX
2328    echo
2329    # The following way of writing the cache mishandles newlines in values,
2330(
2331  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2332    eval ac_val=\$$ac_var
2333    case $ac_val in #(
2334    *${as_nl}*)
2335      case $ac_var in #(
2336      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2337$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2338      esac
2339      case $ac_var in #(
2340      _ | IFS | as_nl) ;; #(
2341      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2342      *) { eval $ac_var=; unset $ac_var;} ;;
2343      esac ;;
2344    esac
2345  done
2346  (set) 2>&1 |
2347    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2348    *${as_nl}ac_space=\ *)
2349      sed -n \
2350	"s/'\''/'\''\\\\'\'''\''/g;
2351	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2352      ;; #(
2353    *)
2354      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2355      ;;
2356    esac |
2357    sort
2358)
2359    echo
2360
2361    cat <<\_ASBOX
2362## ----------------- ##
2363## Output variables. ##
2364## ----------------- ##
2365_ASBOX
2366    echo
2367    for ac_var in $ac_subst_vars
2368    do
2369      eval ac_val=\$$ac_var
2370      case $ac_val in
2371      *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2372      esac
2373      $as_echo "$ac_var='\''$ac_val'\''"
2374    done | sort
2375    echo
2376
2377    if test -n "$ac_subst_files"; then
2378      cat <<\_ASBOX
2379## ------------------- ##
2380## File substitutions. ##
2381## ------------------- ##
2382_ASBOX
2383      echo
2384      for ac_var in $ac_subst_files
2385      do
2386	eval ac_val=\$$ac_var
2387	case $ac_val in
2388	*\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2389	esac
2390	$as_echo "$ac_var='\''$ac_val'\''"
2391      done | sort
2392      echo
2393    fi
2394
2395    if test -s confdefs.h; then
2396      cat <<\_ASBOX
2397## ----------- ##
2398## confdefs.h. ##
2399## ----------- ##
2400_ASBOX
2401      echo
2402      cat confdefs.h
2403      echo
2404    fi
2405    test "$ac_signal" != 0 &&
2406      $as_echo "$as_me: caught signal $ac_signal"
2407    $as_echo "$as_me: exit $exit_status"
2408  } >&5
2409  rm -f core *.core core.conftest.* &&
2410    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2411    exit $exit_status
2412' 0
2413for ac_signal in 1 2 13 15; do
2414  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2415done
2416ac_signal=0
2417
2418# confdefs.h avoids OS command line length limits that DEFS can exceed.
2419rm -f -r conftest* confdefs.h
2420
2421$as_echo "/* confdefs.h */" > confdefs.h
2422
2423# Predefined preprocessor variables.
2424
2425cat >>confdefs.h <<_ACEOF
2426#define PACKAGE_NAME "$PACKAGE_NAME"
2427_ACEOF
2428
2429cat >>confdefs.h <<_ACEOF
2430#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2431_ACEOF
2432
2433cat >>confdefs.h <<_ACEOF
2434#define PACKAGE_VERSION "$PACKAGE_VERSION"
2435_ACEOF
2436
2437cat >>confdefs.h <<_ACEOF
2438#define PACKAGE_STRING "$PACKAGE_STRING"
2439_ACEOF
2440
2441cat >>confdefs.h <<_ACEOF
2442#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2443_ACEOF
2444
2445cat >>confdefs.h <<_ACEOF
2446#define PACKAGE_URL "$PACKAGE_URL"
2447_ACEOF
2448
2449
2450# Let the site file select an alternate cache file if it wants to.
2451# Prefer an explicitly selected file to automatically selected ones.
2452ac_site_file1=NONE
2453ac_site_file2=NONE
2454if test -n "$CONFIG_SITE"; then
2455  ac_site_file1=$CONFIG_SITE
2456elif test "x$prefix" != xNONE; then
2457  ac_site_file1=$prefix/share/config.site
2458  ac_site_file2=$prefix/etc/config.site
2459else
2460  ac_site_file1=$ac_default_prefix/share/config.site
2461  ac_site_file2=$ac_default_prefix/etc/config.site
2462fi
2463for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2464do
2465  test "x$ac_site_file" = xNONE && continue
2466  if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2467    { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2468$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2469    sed 's/^/| /' "$ac_site_file" >&5
2470    . "$ac_site_file"
2471  fi
2472done
2473
2474if test -r "$cache_file"; then
2475  # Some versions of bash will fail to source /dev/null (special files
2476  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2477  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2478    { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2479$as_echo "$as_me: loading cache $cache_file" >&6;}
2480    case $cache_file in
2481      [\\/]* | ?:[\\/]* ) . "$cache_file";;
2482      *)                      . "./$cache_file";;
2483    esac
2484  fi
2485else
2486  { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2487$as_echo "$as_me: creating cache $cache_file" >&6;}
2488  >$cache_file
2489fi
2490
2491# Check that the precious variables saved in the cache have kept the same
2492# value.
2493ac_cache_corrupted=false
2494for ac_var in $ac_precious_vars; do
2495  eval ac_old_set=\$ac_cv_env_${ac_var}_set
2496  eval ac_new_set=\$ac_env_${ac_var}_set
2497  eval ac_old_val=\$ac_cv_env_${ac_var}_value
2498  eval ac_new_val=\$ac_env_${ac_var}_value
2499  case $ac_old_set,$ac_new_set in
2500    set,)
2501      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2502$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2503      ac_cache_corrupted=: ;;
2504    ,set)
2505      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2506$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2507      ac_cache_corrupted=: ;;
2508    ,);;
2509    *)
2510      if test "x$ac_old_val" != "x$ac_new_val"; then
2511	# differences in whitespace do not lead to failure.
2512	ac_old_val_w=`echo x $ac_old_val`
2513	ac_new_val_w=`echo x $ac_new_val`
2514	if test "$ac_old_val_w" != "$ac_new_val_w"; then
2515	  { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2516$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2517	  ac_cache_corrupted=:
2518	else
2519	  { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2520$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2521	  eval $ac_var=\$ac_old_val
2522	fi
2523	{ $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2524$as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2525	{ $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2526$as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2527      fi;;
2528  esac
2529  # Pass precious variables to config.status.
2530  if test "$ac_new_set" = set; then
2531    case $ac_new_val in
2532    *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2533    *) ac_arg=$ac_var=$ac_new_val ;;
2534    esac
2535    case " $ac_configure_args " in
2536      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2537      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2538    esac
2539  fi
2540done
2541if $ac_cache_corrupted; then
2542  { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2543$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2544  { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2545$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2546  as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2547fi
2548## -------------------- ##
2549## Main body of script. ##
2550## -------------------- ##
2551
2552ac_ext=c
2553ac_cpp='$CPP $CPPFLAGS'
2554ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2555ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2556ac_compiler_gnu=$ac_cv_c_compiler_gnu
2557
2558
2559ac_config_headers="$ac_config_headers auto/config.h:config.h.in"
2560
2561
2562$as_echo "#define UNIX 1" >>confdefs.h
2563
2564{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
2565$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
2566set x ${MAKE-make}
2567ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
2568if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
2569  $as_echo_n "(cached) " >&6
2570else
2571  cat >conftest.make <<\_ACEOF
2572SHELL = /bin/sh
2573all:
2574	@echo '@@@%%%=$(MAKE)=@@@%%%'
2575_ACEOF
2576# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
2577case `${MAKE-make} -f conftest.make 2>/dev/null` in
2578  *@@@%%%=?*=@@@%%%*)
2579    eval ac_cv_prog_make_${ac_make}_set=yes;;
2580  *)
2581    eval ac_cv_prog_make_${ac_make}_set=no;;
2582esac
2583rm -f conftest.make
2584fi
2585if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
2586  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2587$as_echo "yes" >&6; }
2588  SET_MAKE=
2589else
2590  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2591$as_echo "no" >&6; }
2592  SET_MAKE="MAKE=${MAKE-make}"
2593fi
2594
2595
2596ac_ext=c
2597ac_cpp='$CPP $CPPFLAGS'
2598ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2599ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2600ac_compiler_gnu=$ac_cv_c_compiler_gnu
2601if test -n "$ac_tool_prefix"; then
2602  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2603set dummy ${ac_tool_prefix}gcc; ac_word=$2
2604{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2605$as_echo_n "checking for $ac_word... " >&6; }
2606if test "${ac_cv_prog_CC+set}" = set; then :
2607  $as_echo_n "(cached) " >&6
2608else
2609  if test -n "$CC"; then
2610  ac_cv_prog_CC="$CC" # Let the user override the test.
2611else
2612as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2613for as_dir in $PATH
2614do
2615  IFS=$as_save_IFS
2616  test -z "$as_dir" && as_dir=.
2617    for ac_exec_ext in '' $ac_executable_extensions; do
2618  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2619    ac_cv_prog_CC="${ac_tool_prefix}gcc"
2620    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2621    break 2
2622  fi
2623done
2624  done
2625IFS=$as_save_IFS
2626
2627fi
2628fi
2629CC=$ac_cv_prog_CC
2630if test -n "$CC"; then
2631  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2632$as_echo "$CC" >&6; }
2633else
2634  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2635$as_echo "no" >&6; }
2636fi
2637
2638
2639fi
2640if test -z "$ac_cv_prog_CC"; then
2641  ac_ct_CC=$CC
2642  # Extract the first word of "gcc", so it can be a program name with args.
2643set dummy gcc; ac_word=$2
2644{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2645$as_echo_n "checking for $ac_word... " >&6; }
2646if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
2647  $as_echo_n "(cached) " >&6
2648else
2649  if test -n "$ac_ct_CC"; then
2650  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2651else
2652as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2653for as_dir in $PATH
2654do
2655  IFS=$as_save_IFS
2656  test -z "$as_dir" && as_dir=.
2657    for ac_exec_ext in '' $ac_executable_extensions; do
2658  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2659    ac_cv_prog_ac_ct_CC="gcc"
2660    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2661    break 2
2662  fi
2663done
2664  done
2665IFS=$as_save_IFS
2666
2667fi
2668fi
2669ac_ct_CC=$ac_cv_prog_ac_ct_CC
2670if test -n "$ac_ct_CC"; then
2671  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2672$as_echo "$ac_ct_CC" >&6; }
2673else
2674  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2675$as_echo "no" >&6; }
2676fi
2677
2678  if test "x$ac_ct_CC" = x; then
2679    CC=""
2680  else
2681    case $cross_compiling:$ac_tool_warned in
2682yes:)
2683{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2684$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2685ac_tool_warned=yes ;;
2686esac
2687    CC=$ac_ct_CC
2688  fi
2689else
2690  CC="$ac_cv_prog_CC"
2691fi
2692
2693if test -z "$CC"; then
2694          if test -n "$ac_tool_prefix"; then
2695    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2696set dummy ${ac_tool_prefix}cc; ac_word=$2
2697{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2698$as_echo_n "checking for $ac_word... " >&6; }
2699if test "${ac_cv_prog_CC+set}" = set; then :
2700  $as_echo_n "(cached) " >&6
2701else
2702  if test -n "$CC"; then
2703  ac_cv_prog_CC="$CC" # Let the user override the test.
2704else
2705as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2706for as_dir in $PATH
2707do
2708  IFS=$as_save_IFS
2709  test -z "$as_dir" && as_dir=.
2710    for ac_exec_ext in '' $ac_executable_extensions; do
2711  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2712    ac_cv_prog_CC="${ac_tool_prefix}cc"
2713    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2714    break 2
2715  fi
2716done
2717  done
2718IFS=$as_save_IFS
2719
2720fi
2721fi
2722CC=$ac_cv_prog_CC
2723if test -n "$CC"; then
2724  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2725$as_echo "$CC" >&6; }
2726else
2727  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2728$as_echo "no" >&6; }
2729fi
2730
2731
2732  fi
2733fi
2734if test -z "$CC"; then
2735  # Extract the first word of "cc", so it can be a program name with args.
2736set dummy cc; ac_word=$2
2737{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2738$as_echo_n "checking for $ac_word... " >&6; }
2739if test "${ac_cv_prog_CC+set}" = set; then :
2740  $as_echo_n "(cached) " >&6
2741else
2742  if test -n "$CC"; then
2743  ac_cv_prog_CC="$CC" # Let the user override the test.
2744else
2745  ac_prog_rejected=no
2746as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2747for as_dir in $PATH
2748do
2749  IFS=$as_save_IFS
2750  test -z "$as_dir" && as_dir=.
2751    for ac_exec_ext in '' $ac_executable_extensions; do
2752  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2753    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2754       ac_prog_rejected=yes
2755       continue
2756     fi
2757    ac_cv_prog_CC="cc"
2758    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2759    break 2
2760  fi
2761done
2762  done
2763IFS=$as_save_IFS
2764
2765if test $ac_prog_rejected = yes; then
2766  # We found a bogon in the path, so make sure we never use it.
2767  set dummy $ac_cv_prog_CC
2768  shift
2769  if test $# != 0; then
2770    # We chose a different compiler from the bogus one.
2771    # However, it has the same basename, so the bogon will be chosen
2772    # first if we set CC to just the basename; use the full file name.
2773    shift
2774    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2775  fi
2776fi
2777fi
2778fi
2779CC=$ac_cv_prog_CC
2780if test -n "$CC"; then
2781  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2782$as_echo "$CC" >&6; }
2783else
2784  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2785$as_echo "no" >&6; }
2786fi
2787
2788
2789fi
2790if test -z "$CC"; then
2791  if test -n "$ac_tool_prefix"; then
2792  for ac_prog in cl.exe
2793  do
2794    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2795set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2796{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2797$as_echo_n "checking for $ac_word... " >&6; }
2798if test "${ac_cv_prog_CC+set}" = set; then :
2799  $as_echo_n "(cached) " >&6
2800else
2801  if test -n "$CC"; then
2802  ac_cv_prog_CC="$CC" # Let the user override the test.
2803else
2804as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2805for as_dir in $PATH
2806do
2807  IFS=$as_save_IFS
2808  test -z "$as_dir" && as_dir=.
2809    for ac_exec_ext in '' $ac_executable_extensions; do
2810  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2811    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2812    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2813    break 2
2814  fi
2815done
2816  done
2817IFS=$as_save_IFS
2818
2819fi
2820fi
2821CC=$ac_cv_prog_CC
2822if test -n "$CC"; then
2823  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2824$as_echo "$CC" >&6; }
2825else
2826  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2827$as_echo "no" >&6; }
2828fi
2829
2830
2831    test -n "$CC" && break
2832  done
2833fi
2834if test -z "$CC"; then
2835  ac_ct_CC=$CC
2836  for ac_prog in cl.exe
2837do
2838  # Extract the first word of "$ac_prog", so it can be a program name with args.
2839set dummy $ac_prog; ac_word=$2
2840{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2841$as_echo_n "checking for $ac_word... " >&6; }
2842if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
2843  $as_echo_n "(cached) " >&6
2844else
2845  if test -n "$ac_ct_CC"; then
2846  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2847else
2848as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2849for as_dir in $PATH
2850do
2851  IFS=$as_save_IFS
2852  test -z "$as_dir" && as_dir=.
2853    for ac_exec_ext in '' $ac_executable_extensions; do
2854  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2855    ac_cv_prog_ac_ct_CC="$ac_prog"
2856    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2857    break 2
2858  fi
2859done
2860  done
2861IFS=$as_save_IFS
2862
2863fi
2864fi
2865ac_ct_CC=$ac_cv_prog_ac_ct_CC
2866if test -n "$ac_ct_CC"; then
2867  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2868$as_echo "$ac_ct_CC" >&6; }
2869else
2870  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2871$as_echo "no" >&6; }
2872fi
2873
2874
2875  test -n "$ac_ct_CC" && break
2876done
2877
2878  if test "x$ac_ct_CC" = x; then
2879    CC=""
2880  else
2881    case $cross_compiling:$ac_tool_warned in
2882yes:)
2883{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2884$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2885ac_tool_warned=yes ;;
2886esac
2887    CC=$ac_ct_CC
2888  fi
2889fi
2890
2891fi
2892
2893
2894test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2895$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2896as_fn_error "no acceptable C compiler found in \$PATH
2897See \`config.log' for more details." "$LINENO" 5; }
2898
2899# Provide some information about the compiler.
2900$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
2901set X $ac_compile
2902ac_compiler=$2
2903for ac_option in --version -v -V -qversion; do
2904  { { ac_try="$ac_compiler $ac_option >&5"
2905case "(($ac_try" in
2906  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2907  *) ac_try_echo=$ac_try;;
2908esac
2909eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2910$as_echo "$ac_try_echo"; } >&5
2911  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
2912  ac_status=$?
2913  if test -s conftest.err; then
2914    sed '10a\
2915... rest of stderr output deleted ...
2916         10q' conftest.err >conftest.er1
2917    cat conftest.er1 >&5
2918  fi
2919  rm -f conftest.er1 conftest.err
2920  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2921  test $ac_status = 0; }
2922done
2923
2924cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2925/* end confdefs.h.  */
2926
2927int
2928main ()
2929{
2930
2931  ;
2932  return 0;
2933}
2934_ACEOF
2935ac_clean_files_save=$ac_clean_files
2936ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
2937# Try to create an executable without -o first, disregard a.out.
2938# It will help us diagnose broken compilers, and finding out an intuition
2939# of exeext.
2940{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
2941$as_echo_n "checking whether the C compiler works... " >&6; }
2942ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2943
2944# The possible output files:
2945ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
2946
2947ac_rmfiles=
2948for ac_file in $ac_files
2949do
2950  case $ac_file in
2951    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
2952    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2953  esac
2954done
2955rm -f $ac_rmfiles
2956
2957if { { ac_try="$ac_link_default"
2958case "(($ac_try" in
2959  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2960  *) ac_try_echo=$ac_try;;
2961esac
2962eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2963$as_echo "$ac_try_echo"; } >&5
2964  (eval "$ac_link_default") 2>&5
2965  ac_status=$?
2966  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2967  test $ac_status = 0; }; then :
2968  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
2969# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
2970# in a Makefile.  We should not override ac_cv_exeext if it was cached,
2971# so that the user can short-circuit this test for compilers unknown to
2972# Autoconf.
2973for ac_file in $ac_files ''
2974do
2975  test -f "$ac_file" || continue
2976  case $ac_file in
2977    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
2978	;;
2979    [ab].out )
2980	# We found the default executable, but exeext='' is most
2981	# certainly right.
2982	break;;
2983    *.* )
2984	if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
2985	then :; else
2986	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2987	fi
2988	# We set ac_cv_exeext here because the later test for it is not
2989	# safe: cross compilers may not add the suffix if given an `-o'
2990	# argument, so we may need to know it at that point already.
2991	# Even if this section looks crufty: it has the advantage of
2992	# actually working.
2993	break;;
2994    * )
2995	break;;
2996  esac
2997done
2998test "$ac_cv_exeext" = no && ac_cv_exeext=
2999
3000else
3001  ac_file=''
3002fi
3003if test -z "$ac_file"; then :
3004  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3005$as_echo "no" >&6; }
3006$as_echo "$as_me: failed program was:" >&5
3007sed 's/^/| /' conftest.$ac_ext >&5
3008
3009{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3010$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3011{ as_fn_set_status 77
3012as_fn_error "C compiler cannot create executables
3013See \`config.log' for more details." "$LINENO" 5; }; }
3014else
3015  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3016$as_echo "yes" >&6; }
3017fi
3018{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3019$as_echo_n "checking for C compiler default output file name... " >&6; }
3020{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3021$as_echo "$ac_file" >&6; }
3022ac_exeext=$ac_cv_exeext
3023
3024rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3025ac_clean_files=$ac_clean_files_save
3026{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3027$as_echo_n "checking for suffix of executables... " >&6; }
3028if { { ac_try="$ac_link"
3029case "(($ac_try" in
3030  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3031  *) ac_try_echo=$ac_try;;
3032esac
3033eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3034$as_echo "$ac_try_echo"; } >&5
3035  (eval "$ac_link") 2>&5
3036  ac_status=$?
3037  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3038  test $ac_status = 0; }; then :
3039  # If both `conftest.exe' and `conftest' are `present' (well, observable)
3040# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3041# work properly (i.e., refer to `conftest.exe'), while it won't with
3042# `rm'.
3043for ac_file in conftest.exe conftest conftest.*; do
3044  test -f "$ac_file" || continue
3045  case $ac_file in
3046    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3047    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3048	  break;;
3049    * ) break;;
3050  esac
3051done
3052else
3053  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3054$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3055as_fn_error "cannot compute suffix of executables: cannot compile and link
3056See \`config.log' for more details." "$LINENO" 5; }
3057fi
3058rm -f conftest conftest$ac_cv_exeext
3059{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3060$as_echo "$ac_cv_exeext" >&6; }
3061
3062rm -f conftest.$ac_ext
3063EXEEXT=$ac_cv_exeext
3064ac_exeext=$EXEEXT
3065cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3066/* end confdefs.h.  */
3067#include <stdio.h>
3068int
3069main ()
3070{
3071FILE *f = fopen ("conftest.out", "w");
3072 return ferror (f) || fclose (f) != 0;
3073
3074  ;
3075  return 0;
3076}
3077_ACEOF
3078ac_clean_files="$ac_clean_files conftest.out"
3079# Check that the compiler produces executables we can run.  If not, either
3080# the compiler is broken, or we cross compile.
3081{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3082$as_echo_n "checking whether we are cross compiling... " >&6; }
3083if test "$cross_compiling" != yes; then
3084  { { ac_try="$ac_link"
3085case "(($ac_try" in
3086  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3087  *) ac_try_echo=$ac_try;;
3088esac
3089eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3090$as_echo "$ac_try_echo"; } >&5
3091  (eval "$ac_link") 2>&5
3092  ac_status=$?
3093  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3094  test $ac_status = 0; }
3095  if { ac_try='./conftest$ac_cv_exeext'
3096  { { case "(($ac_try" in
3097  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3098  *) ac_try_echo=$ac_try;;
3099esac
3100eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3101$as_echo "$ac_try_echo"; } >&5
3102  (eval "$ac_try") 2>&5
3103  ac_status=$?
3104  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3105  test $ac_status = 0; }; }; then
3106    cross_compiling=no
3107  else
3108    if test "$cross_compiling" = maybe; then
3109	cross_compiling=yes
3110    else
3111	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3112$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3113as_fn_error "cannot run C compiled programs.
3114If you meant to cross compile, use \`--host'.
3115See \`config.log' for more details." "$LINENO" 5; }
3116    fi
3117  fi
3118fi
3119{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3120$as_echo "$cross_compiling" >&6; }
3121
3122rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3123ac_clean_files=$ac_clean_files_save
3124{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3125$as_echo_n "checking for suffix of object files... " >&6; }
3126if test "${ac_cv_objext+set}" = set; then :
3127  $as_echo_n "(cached) " >&6
3128else
3129  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3130/* end confdefs.h.  */
3131
3132int
3133main ()
3134{
3135
3136  ;
3137  return 0;
3138}
3139_ACEOF
3140rm -f conftest.o conftest.obj
3141if { { ac_try="$ac_compile"
3142case "(($ac_try" in
3143  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3144  *) ac_try_echo=$ac_try;;
3145esac
3146eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3147$as_echo "$ac_try_echo"; } >&5
3148  (eval "$ac_compile") 2>&5
3149  ac_status=$?
3150  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3151  test $ac_status = 0; }; then :
3152  for ac_file in conftest.o conftest.obj conftest.*; do
3153  test -f "$ac_file" || continue;
3154  case $ac_file in
3155    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3156    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3157       break;;
3158  esac
3159done
3160else
3161  $as_echo "$as_me: failed program was:" >&5
3162sed 's/^/| /' conftest.$ac_ext >&5
3163
3164{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3165$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3166as_fn_error "cannot compute suffix of object files: cannot compile
3167See \`config.log' for more details." "$LINENO" 5; }
3168fi
3169rm -f conftest.$ac_cv_objext conftest.$ac_ext
3170fi
3171{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3172$as_echo "$ac_cv_objext" >&6; }
3173OBJEXT=$ac_cv_objext
3174ac_objext=$OBJEXT
3175{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3176$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3177if test "${ac_cv_c_compiler_gnu+set}" = set; then :
3178  $as_echo_n "(cached) " >&6
3179else
3180  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3181/* end confdefs.h.  */
3182
3183int
3184main ()
3185{
3186#ifndef __GNUC__
3187       choke me
3188#endif
3189
3190  ;
3191  return 0;
3192}
3193_ACEOF
3194if ac_fn_c_try_compile "$LINENO"; then :
3195  ac_compiler_gnu=yes
3196else
3197  ac_compiler_gnu=no
3198fi
3199rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3200ac_cv_c_compiler_gnu=$ac_compiler_gnu
3201
3202fi
3203{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3204$as_echo "$ac_cv_c_compiler_gnu" >&6; }
3205if test $ac_compiler_gnu = yes; then
3206  GCC=yes
3207else
3208  GCC=
3209fi
3210ac_test_CFLAGS=${CFLAGS+set}
3211ac_save_CFLAGS=$CFLAGS
3212{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3213$as_echo_n "checking whether $CC accepts -g... " >&6; }
3214if test "${ac_cv_prog_cc_g+set}" = set; then :
3215  $as_echo_n "(cached) " >&6
3216else
3217  ac_save_c_werror_flag=$ac_c_werror_flag
3218   ac_c_werror_flag=yes
3219   ac_cv_prog_cc_g=no
3220   CFLAGS="-g"
3221   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3222/* end confdefs.h.  */
3223
3224int
3225main ()
3226{
3227
3228  ;
3229  return 0;
3230}
3231_ACEOF
3232if ac_fn_c_try_compile "$LINENO"; then :
3233  ac_cv_prog_cc_g=yes
3234else
3235  CFLAGS=""
3236      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3237/* end confdefs.h.  */
3238
3239int
3240main ()
3241{
3242
3243  ;
3244  return 0;
3245}
3246_ACEOF
3247if ac_fn_c_try_compile "$LINENO"; then :
3248
3249else
3250  ac_c_werror_flag=$ac_save_c_werror_flag
3251	 CFLAGS="-g"
3252	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3253/* end confdefs.h.  */
3254
3255int
3256main ()
3257{
3258
3259  ;
3260  return 0;
3261}
3262_ACEOF
3263if ac_fn_c_try_compile "$LINENO"; then :
3264  ac_cv_prog_cc_g=yes
3265fi
3266rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3267fi
3268rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3269fi
3270rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3271   ac_c_werror_flag=$ac_save_c_werror_flag
3272fi
3273{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3274$as_echo "$ac_cv_prog_cc_g" >&6; }
3275if test "$ac_test_CFLAGS" = set; then
3276  CFLAGS=$ac_save_CFLAGS
3277elif test $ac_cv_prog_cc_g = yes; then
3278  if test "$GCC" = yes; then
3279    CFLAGS="-g -O2"
3280  else
3281    CFLAGS="-g"
3282  fi
3283else
3284  if test "$GCC" = yes; then
3285    CFLAGS="-O2"
3286  else
3287    CFLAGS=
3288  fi
3289fi
3290{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3291$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3292if test "${ac_cv_prog_cc_c89+set}" = set; then :
3293  $as_echo_n "(cached) " >&6
3294else
3295  ac_cv_prog_cc_c89=no
3296ac_save_CC=$CC
3297cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3298/* end confdefs.h.  */
3299#include <stdarg.h>
3300#include <stdio.h>
3301#include <sys/types.h>
3302#include <sys/stat.h>
3303/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3304struct buf { int x; };
3305FILE * (*rcsopen) (struct buf *, struct stat *, int);
3306static char *e (p, i)
3307     char **p;
3308     int i;
3309{
3310  return p[i];
3311}
3312static char *f (char * (*g) (char **, int), char **p, ...)
3313{
3314  char *s;
3315  va_list v;
3316  va_start (v,p);
3317  s = g (p, va_arg (v,int));
3318  va_end (v);
3319  return s;
3320}
3321
3322/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3323   function prototypes and stuff, but not '\xHH' hex character constants.
3324   These don't provoke an error unfortunately, instead are silently treated
3325   as 'x'.  The following induces an error, until -std is added to get
3326   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3327   array size at least.  It's necessary to write '\x00'==0 to get something
3328   that's true only with -std.  */
3329int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3330
3331/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3332   inside strings and character constants.  */
3333#define FOO(x) 'x'
3334int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3335
3336int test (int i, double x);
3337struct s1 {int (*f) (int a);};
3338struct s2 {int (*f) (double a);};
3339int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3340int argc;
3341char **argv;
3342int
3343main ()
3344{
3345return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3346  ;
3347  return 0;
3348}
3349_ACEOF
3350for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3351	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3352do
3353  CC="$ac_save_CC $ac_arg"
3354  if ac_fn_c_try_compile "$LINENO"; then :
3355  ac_cv_prog_cc_c89=$ac_arg
3356fi
3357rm -f core conftest.err conftest.$ac_objext
3358  test "x$ac_cv_prog_cc_c89" != "xno" && break
3359done
3360rm -f conftest.$ac_ext
3361CC=$ac_save_CC
3362
3363fi
3364# AC_CACHE_VAL
3365case "x$ac_cv_prog_cc_c89" in
3366  x)
3367    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3368$as_echo "none needed" >&6; } ;;
3369  xno)
3370    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3371$as_echo "unsupported" >&6; } ;;
3372  *)
3373    CC="$CC $ac_cv_prog_cc_c89"
3374    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3375$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3376esac
3377if test "x$ac_cv_prog_cc_c89" != xno; then :
3378
3379fi
3380
3381ac_ext=c
3382ac_cpp='$CPP $CPPFLAGS'
3383ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3384ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3385ac_compiler_gnu=$ac_cv_c_compiler_gnu
3386	ac_ext=c
3387ac_cpp='$CPP $CPPFLAGS'
3388ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3389ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3390ac_compiler_gnu=$ac_cv_c_compiler_gnu
3391{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3392$as_echo_n "checking how to run the C preprocessor... " >&6; }
3393# On Suns, sometimes $CPP names a directory.
3394if test -n "$CPP" && test -d "$CPP"; then
3395  CPP=
3396fi
3397if test -z "$CPP"; then
3398  if test "${ac_cv_prog_CPP+set}" = set; then :
3399  $as_echo_n "(cached) " >&6
3400else
3401      # Double quotes because CPP needs to be expanded
3402    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3403    do
3404      ac_preproc_ok=false
3405for ac_c_preproc_warn_flag in '' yes
3406do
3407  # Use a header file that comes with gcc, so configuring glibc
3408  # with a fresh cross-compiler works.
3409  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3410  # <limits.h> exists even on freestanding compilers.
3411  # On the NeXT, cc -E runs the code through the compiler's parser,
3412  # not just through cpp. "Syntax error" is here to catch this case.
3413  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3414/* end confdefs.h.  */
3415#ifdef __STDC__
3416# include <limits.h>
3417#else
3418# include <assert.h>
3419#endif
3420		     Syntax error
3421_ACEOF
3422if ac_fn_c_try_cpp "$LINENO"; then :
3423
3424else
3425  # Broken: fails on valid input.
3426continue
3427fi
3428rm -f conftest.err conftest.$ac_ext
3429
3430  # OK, works on sane cases.  Now check whether nonexistent headers
3431  # can be detected and how.
3432  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3433/* end confdefs.h.  */
3434#include <ac_nonexistent.h>
3435_ACEOF
3436if ac_fn_c_try_cpp "$LINENO"; then :
3437  # Broken: success on invalid input.
3438continue
3439else
3440  # Passes both tests.
3441ac_preproc_ok=:
3442break
3443fi
3444rm -f conftest.err conftest.$ac_ext
3445
3446done
3447# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3448rm -f conftest.err conftest.$ac_ext
3449if $ac_preproc_ok; then :
3450  break
3451fi
3452
3453    done
3454    ac_cv_prog_CPP=$CPP
3455
3456fi
3457  CPP=$ac_cv_prog_CPP
3458else
3459  ac_cv_prog_CPP=$CPP
3460fi
3461{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3462$as_echo "$CPP" >&6; }
3463ac_preproc_ok=false
3464for ac_c_preproc_warn_flag in '' yes
3465do
3466  # Use a header file that comes with gcc, so configuring glibc
3467  # with a fresh cross-compiler works.
3468  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3469  # <limits.h> exists even on freestanding compilers.
3470  # On the NeXT, cc -E runs the code through the compiler's parser,
3471  # not just through cpp. "Syntax error" is here to catch this case.
3472  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3473/* end confdefs.h.  */
3474#ifdef __STDC__
3475# include <limits.h>
3476#else
3477# include <assert.h>
3478#endif
3479		     Syntax error
3480_ACEOF
3481if ac_fn_c_try_cpp "$LINENO"; then :
3482
3483else
3484  # Broken: fails on valid input.
3485continue
3486fi
3487rm -f conftest.err conftest.$ac_ext
3488
3489  # OK, works on sane cases.  Now check whether nonexistent headers
3490  # can be detected and how.
3491  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3492/* end confdefs.h.  */
3493#include <ac_nonexistent.h>
3494_ACEOF
3495if ac_fn_c_try_cpp "$LINENO"; then :
3496  # Broken: success on invalid input.
3497continue
3498else
3499  # Passes both tests.
3500ac_preproc_ok=:
3501break
3502fi
3503rm -f conftest.err conftest.$ac_ext
3504
3505done
3506# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3507rm -f conftest.err conftest.$ac_ext
3508if $ac_preproc_ok; then :
3509
3510else
3511  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3512$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3513as_fn_error "C preprocessor \"$CPP\" fails sanity check
3514See \`config.log' for more details." "$LINENO" 5; }
3515fi
3516
3517ac_ext=c
3518ac_cpp='$CPP $CPPFLAGS'
3519ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3520ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3521ac_compiler_gnu=$ac_cv_c_compiler_gnu
3522
3523
3524{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3525$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3526if test "${ac_cv_path_GREP+set}" = set; then :
3527  $as_echo_n "(cached) " >&6
3528else
3529  if test -z "$GREP"; then
3530  ac_path_GREP_found=false
3531  # Loop through the user's path and test for each of PROGNAME-LIST
3532  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3533for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3534do
3535  IFS=$as_save_IFS
3536  test -z "$as_dir" && as_dir=.
3537    for ac_prog in grep ggrep; do
3538    for ac_exec_ext in '' $ac_executable_extensions; do
3539      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3540      { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
3541# Check for GNU ac_path_GREP and select it if it is found.
3542  # Check for GNU $ac_path_GREP
3543case `"$ac_path_GREP" --version 2>&1` in
3544*GNU*)
3545  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3546*)
3547  ac_count=0
3548  $as_echo_n 0123456789 >"conftest.in"
3549  while :
3550  do
3551    cat "conftest.in" "conftest.in" >"conftest.tmp"
3552    mv "conftest.tmp" "conftest.in"
3553    cp "conftest.in" "conftest.nl"
3554    $as_echo 'GREP' >> "conftest.nl"
3555    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3556    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3557    as_fn_arith $ac_count + 1 && ac_count=$as_val
3558    if test $ac_count -gt ${ac_path_GREP_max-0}; then
3559      # Best one so far, save it but keep looking for a better one
3560      ac_cv_path_GREP="$ac_path_GREP"
3561      ac_path_GREP_max=$ac_count
3562    fi
3563    # 10*(2^10) chars as input seems more than enough
3564    test $ac_count -gt 10 && break
3565  done
3566  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3567esac
3568
3569      $ac_path_GREP_found && break 3
3570    done
3571  done
3572  done
3573IFS=$as_save_IFS
3574  if test -z "$ac_cv_path_GREP"; then
3575    as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3576  fi
3577else
3578  ac_cv_path_GREP=$GREP
3579fi
3580
3581fi
3582{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3583$as_echo "$ac_cv_path_GREP" >&6; }
3584 GREP="$ac_cv_path_GREP"
3585
3586
3587{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3588$as_echo_n "checking for egrep... " >&6; }
3589if test "${ac_cv_path_EGREP+set}" = set; then :
3590  $as_echo_n "(cached) " >&6
3591else
3592  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3593   then ac_cv_path_EGREP="$GREP -E"
3594   else
3595     if test -z "$EGREP"; then
3596  ac_path_EGREP_found=false
3597  # Loop through the user's path and test for each of PROGNAME-LIST
3598  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3599for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3600do
3601  IFS=$as_save_IFS
3602  test -z "$as_dir" && as_dir=.
3603    for ac_prog in egrep; do
3604    for ac_exec_ext in '' $ac_executable_extensions; do
3605      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3606      { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
3607# Check for GNU ac_path_EGREP and select it if it is found.
3608  # Check for GNU $ac_path_EGREP
3609case `"$ac_path_EGREP" --version 2>&1` in
3610*GNU*)
3611  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3612*)
3613  ac_count=0
3614  $as_echo_n 0123456789 >"conftest.in"
3615  while :
3616  do
3617    cat "conftest.in" "conftest.in" >"conftest.tmp"
3618    mv "conftest.tmp" "conftest.in"
3619    cp "conftest.in" "conftest.nl"
3620    $as_echo 'EGREP' >> "conftest.nl"
3621    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3622    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3623    as_fn_arith $ac_count + 1 && ac_count=$as_val
3624    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3625      # Best one so far, save it but keep looking for a better one
3626      ac_cv_path_EGREP="$ac_path_EGREP"
3627      ac_path_EGREP_max=$ac_count
3628    fi
3629    # 10*(2^10) chars as input seems more than enough
3630    test $ac_count -gt 10 && break
3631  done
3632  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3633esac
3634
3635      $ac_path_EGREP_found && break 3
3636    done
3637  done
3638  done
3639IFS=$as_save_IFS
3640  if test -z "$ac_cv_path_EGREP"; then
3641    as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3642  fi
3643else
3644  ac_cv_path_EGREP=$EGREP
3645fi
3646
3647   fi
3648fi
3649{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
3650$as_echo "$ac_cv_path_EGREP" >&6; }
3651 EGREP="$ac_cv_path_EGREP"
3652
3653
3654cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3655/* end confdefs.h.  */
3656
3657_ACEOF
3658if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3659  $EGREP "" >/dev/null 2>&1; then :
3660
3661fi
3662rm -f conftest*
3663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5
3664$as_echo_n "checking for library containing strerror... " >&6; }
3665if test "${ac_cv_search_strerror+set}" = set; then :
3666  $as_echo_n "(cached) " >&6
3667else
3668  ac_func_search_save_LIBS=$LIBS
3669cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3670/* end confdefs.h.  */
3671
3672/* Override any GCC internal prototype to avoid an error.
3673   Use char because int might match the return type of a GCC
3674   builtin and then its argument prototype would still apply.  */
3675#ifdef __cplusplus
3676extern "C"
3677#endif
3678char strerror ();
3679int
3680main ()
3681{
3682return strerror ();
3683  ;
3684  return 0;
3685}
3686_ACEOF
3687for ac_lib in '' cposix; do
3688  if test -z "$ac_lib"; then
3689    ac_res="none required"
3690  else
3691    ac_res=-l$ac_lib
3692    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
3693  fi
3694  if ac_fn_c_try_link "$LINENO"; then :
3695  ac_cv_search_strerror=$ac_res
3696fi
3697rm -f core conftest.err conftest.$ac_objext \
3698    conftest$ac_exeext
3699  if test "${ac_cv_search_strerror+set}" = set; then :
3700  break
3701fi
3702done
3703if test "${ac_cv_search_strerror+set}" = set; then :
3704
3705else
3706  ac_cv_search_strerror=no
3707fi
3708rm conftest.$ac_ext
3709LIBS=$ac_func_search_save_LIBS
3710fi
3711{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_strerror" >&5
3712$as_echo "$ac_cv_search_strerror" >&6; }
3713ac_res=$ac_cv_search_strerror
3714if test "$ac_res" != no; then :
3715  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
3716
3717fi
3718	for ac_prog in gawk mawk nawk awk
3719do
3720  # Extract the first word of "$ac_prog", so it can be a program name with args.
3721set dummy $ac_prog; ac_word=$2
3722{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3723$as_echo_n "checking for $ac_word... " >&6; }
3724if test "${ac_cv_prog_AWK+set}" = set; then :
3725  $as_echo_n "(cached) " >&6
3726else
3727  if test -n "$AWK"; then
3728  ac_cv_prog_AWK="$AWK" # Let the user override the test.
3729else
3730as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3731for as_dir in $PATH
3732do
3733  IFS=$as_save_IFS
3734  test -z "$as_dir" && as_dir=.
3735    for ac_exec_ext in '' $ac_executable_extensions; do
3736  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3737    ac_cv_prog_AWK="$ac_prog"
3738    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3739    break 2
3740  fi
3741done
3742  done
3743IFS=$as_save_IFS
3744
3745fi
3746fi
3747AWK=$ac_cv_prog_AWK
3748if test -n "$AWK"; then
3749  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3750$as_echo "$AWK" >&6; }
3751else
3752  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3753$as_echo "no" >&6; }
3754fi
3755
3756
3757  test -n "$AWK" && break
3758done
3759
3760# Extract the first word of "strip", so it can be a program name with args.
3761set dummy strip; ac_word=$2
3762{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3763$as_echo_n "checking for $ac_word... " >&6; }
3764if test "${ac_cv_prog_STRIP+set}" = set; then :
3765  $as_echo_n "(cached) " >&6
3766else
3767  if test -n "$STRIP"; then
3768  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3769else
3770as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3771for as_dir in $PATH
3772do
3773  IFS=$as_save_IFS
3774  test -z "$as_dir" && as_dir=.
3775    for ac_exec_ext in '' $ac_executable_extensions; do
3776  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3777    ac_cv_prog_STRIP="strip"
3778    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3779    break 2
3780  fi
3781done
3782  done
3783IFS=$as_save_IFS
3784
3785  test -z "$ac_cv_prog_STRIP" && ac_cv_prog_STRIP=":"
3786fi
3787fi
3788STRIP=$ac_cv_prog_STRIP
3789if test -n "$STRIP"; then
3790  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3791$as_echo "$STRIP" >&6; }
3792else
3793  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3794$as_echo "no" >&6; }
3795fi
3796
3797
3798
3799
3800
3801{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
3802$as_echo_n "checking for ANSI C header files... " >&6; }
3803if test "${ac_cv_header_stdc+set}" = set; then :
3804  $as_echo_n "(cached) " >&6
3805else
3806  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3807/* end confdefs.h.  */
3808#include <stdlib.h>
3809#include <stdarg.h>
3810#include <string.h>
3811#include <float.h>
3812
3813int
3814main ()
3815{
3816
3817  ;
3818  return 0;
3819}
3820_ACEOF
3821if ac_fn_c_try_compile "$LINENO"; then :
3822  ac_cv_header_stdc=yes
3823else
3824  ac_cv_header_stdc=no
3825fi
3826rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3827
3828if test $ac_cv_header_stdc = yes; then
3829  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3830  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3831/* end confdefs.h.  */
3832#include <string.h>
3833
3834_ACEOF
3835if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3836  $EGREP "memchr" >/dev/null 2>&1; then :
3837
3838else
3839  ac_cv_header_stdc=no
3840fi
3841rm -f conftest*
3842
3843fi
3844
3845if test $ac_cv_header_stdc = yes; then
3846  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3847  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3848/* end confdefs.h.  */
3849#include <stdlib.h>
3850
3851_ACEOF
3852if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3853  $EGREP "free" >/dev/null 2>&1; then :
3854
3855else
3856  ac_cv_header_stdc=no
3857fi
3858rm -f conftest*
3859
3860fi
3861
3862if test $ac_cv_header_stdc = yes; then
3863  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3864  if test "$cross_compiling" = yes; then :
3865  :
3866else
3867  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3868/* end confdefs.h.  */
3869#include <ctype.h>
3870#include <stdlib.h>
3871#if ((' ' & 0x0FF) == 0x020)
3872# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3873# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3874#else
3875# define ISLOWER(c) \
3876		   (('a' <= (c) && (c) <= 'i') \
3877		     || ('j' <= (c) && (c) <= 'r') \
3878		     || ('s' <= (c) && (c) <= 'z'))
3879# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3880#endif
3881
3882#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3883int
3884main ()
3885{
3886  int i;
3887  for (i = 0; i < 256; i++)
3888    if (XOR (islower (i), ISLOWER (i))
3889	|| toupper (i) != TOUPPER (i))
3890      return 2;
3891  return 0;
3892}
3893_ACEOF
3894if ac_fn_c_try_run "$LINENO"; then :
3895
3896else
3897  ac_cv_header_stdc=no
3898fi
3899rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3900  conftest.$ac_objext conftest.beam conftest.$ac_ext
3901fi
3902
3903fi
3904fi
3905{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
3906$as_echo "$ac_cv_header_stdc" >&6; }
3907if test $ac_cv_header_stdc = yes; then
3908
3909$as_echo "#define STDC_HEADERS 1" >>confdefs.h
3910
3911fi
3912
3913{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
3914$as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
3915if test "${ac_cv_header_sys_wait_h+set}" = set; then :
3916  $as_echo_n "(cached) " >&6
3917else
3918  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3919/* end confdefs.h.  */
3920#include <sys/types.h>
3921#include <sys/wait.h>
3922#ifndef WEXITSTATUS
3923# define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
3924#endif
3925#ifndef WIFEXITED
3926# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
3927#endif
3928
3929int
3930main ()
3931{
3932  int s;
3933  wait (&s);
3934  s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
3935  ;
3936  return 0;
3937}
3938_ACEOF
3939if ac_fn_c_try_compile "$LINENO"; then :
3940  ac_cv_header_sys_wait_h=yes
3941else
3942  ac_cv_header_sys_wait_h=no
3943fi
3944rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3945fi
3946{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
3947$as_echo "$ac_cv_header_sys_wait_h" >&6; }
3948if test $ac_cv_header_sys_wait_h = yes; then
3949
3950$as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
3951
3952fi
3953
3954
3955
3956{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-fail-if-missing argument" >&5
3957$as_echo_n "checking --enable-fail-if-missing argument... " >&6; }
3958# Check whether --enable-fail_if_missing was given.
3959if test "${enable_fail_if_missing+set}" = set; then :
3960  enableval=$enable_fail_if_missing; fail_if_missing="yes"
3961else
3962  fail_if_missing="no"
3963fi
3964
3965{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $fail_if_missing" >&5
3966$as_echo "$fail_if_missing" >&6; }
3967
3968if test -z "$CFLAGS"; then
3969  CFLAGS="-O"
3970  test "$GCC" = yes && CFLAGS="-O2 -fno-strength-reduce -Wall"
3971fi
3972if test "$GCC" = yes; then
3973    gccversion=`"$CC" -dumpversion`
3974  if test "x$gccversion" = "x"; then
3975        gccversion=`"$CC" --version | sed -e '2,$d' -e 's/darwin.//' -e 's/^[^0-9]*\([0-9]\.[0-9.]*\).*$/\1/g'`
3976  fi
3977    if test "$gccversion" = "3.0.1" -o "$gccversion" = "3.0.2" -o "$gccversion" = "4.0.1"; then
3978    echo 'GCC [34].0.[12] has a bug in the optimizer, disabling "-O#"'
3979    CFLAGS=`echo "$CFLAGS" | sed 's/-O[23456789]/-O/'`
3980  else
3981    if test "$gccversion" = "3.1" -o "$gccversion" = "3.2" -o "$gccversion" = "3.2.1" && `echo "$CFLAGS" | grep -v fno-strength-reduce >/dev/null`; then
3982      echo 'GCC 3.1 and 3.2 have a bug in the optimizer, adding "-fno-strength-reduce"'
3983      CFLAGS="$CFLAGS -fno-strength-reduce"
3984    fi
3985  fi
3986fi
3987
3988if test "$cross_compiling" = yes; then
3989  { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot compile a simple program; if not cross compiling check CC and CFLAGS" >&5
3990$as_echo "cannot compile a simple program; if not cross compiling check CC and CFLAGS" >&6; }
3991fi
3992
3993test "$GCC" = yes && CPP_MM=M;
3994
3995if test -f ./toolcheck; then
3996  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for buggy tools..." >&5
3997$as_echo "$as_me: checking for buggy tools..." >&6;}
3998  sh ./toolcheck 1>&6
3999fi
4000
4001OS_EXTRA_SRC=""; OS_EXTRA_OBJ=""
4002
4003{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BeOS" >&5
4004$as_echo_n "checking for BeOS... " >&6; }
4005case `uname` in
4006    BeOS)	OS_EXTRA_SRC=os_beos.c; OS_EXTRA_OBJ=objects/os_beos.o
4007		BEOS=yes; { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4008$as_echo "yes" >&6; };;
4009    *)		BEOS=no; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4010$as_echo "no" >&6; };;
4011esac
4012
4013{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for QNX" >&5
4014$as_echo_n "checking for QNX... " >&6; }
4015case `uname` in
4016    QNX)	OS_EXTRA_SRC=os_qnx.c; OS_EXTRA_OBJ=objects/os_qnx.o
4017		test -z "$with_x" && with_x=no
4018		QNX=yes; { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4019$as_echo "yes" >&6; };;
4020    *)		QNX=no; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4021$as_echo "no" >&6; };;
4022esac
4023
4024{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Darwin (Mac OS X)" >&5
4025$as_echo_n "checking for Darwin (Mac OS X)... " >&6; }
4026if test "`(uname) 2>/dev/null`" = Darwin; then
4027  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4028$as_echo "yes" >&6; }
4029
4030  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-darwin argument" >&5
4031$as_echo_n "checking --disable-darwin argument... " >&6; }
4032  # Check whether --enable-darwin was given.
4033if test "${enable_darwin+set}" = set; then :
4034  enableval=$enable_darwin;
4035else
4036  enable_darwin="yes"
4037fi
4038
4039  if test "$enable_darwin" = "yes"; then
4040    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4041$as_echo "no" >&6; }
4042    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Darwin files are there" >&5
4043$as_echo_n "checking if Darwin files are there... " >&6; }
4044    if test -f os_macosx.m; then
4045      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4046$as_echo "yes" >&6; }
4047    else
4048      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, Darwin support disabled" >&5
4049$as_echo "no, Darwin support disabled" >&6; }
4050      enable_darwin=no
4051    fi
4052  else
4053    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, Darwin support excluded" >&5
4054$as_echo "yes, Darwin support excluded" >&6; }
4055  fi
4056
4057  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-mac-arch argument" >&5
4058$as_echo_n "checking --with-mac-arch argument... " >&6; }
4059
4060# Check whether --with-mac-arch was given.
4061if test "${with_mac_arch+set}" = set; then :
4062  withval=$with_mac_arch; MACARCH="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACARCH" >&5
4063$as_echo "$MACARCH" >&6; }
4064else
4065  MACARCH="current"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: defaulting to $MACARCH" >&5
4066$as_echo "defaulting to $MACARCH" >&6; }
4067fi
4068
4069
4070  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-developer-dir argument" >&5
4071$as_echo_n "checking --with-developer-dir argument... " >&6; }
4072
4073# Check whether --with-developer-dir was given.
4074if test "${with_developer_dir+set}" = set; then :
4075  withval=$with_developer_dir; DEVELOPER_DIR="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVELOPER_DIR" >&5
4076$as_echo "$DEVELOPER_DIR" >&6; }
4077else
4078  DEVELOPER_DIR=""; { $as_echo "$as_me:${as_lineno-$LINENO}: result: not present" >&5
4079$as_echo "not present" >&6; }
4080fi
4081
4082
4083  if test "x$DEVELOPER_DIR" = "x"; then
4084    # Extract the first word of "xcode-select", so it can be a program name with args.
4085set dummy xcode-select; ac_word=$2
4086{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4087$as_echo_n "checking for $ac_word... " >&6; }
4088if test "${ac_cv_path_XCODE_SELECT+set}" = set; then :
4089  $as_echo_n "(cached) " >&6
4090else
4091  case $XCODE_SELECT in
4092  [\\/]* | ?:[\\/]*)
4093  ac_cv_path_XCODE_SELECT="$XCODE_SELECT" # Let the user override the test with a path.
4094  ;;
4095  *)
4096  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4097for as_dir in $PATH
4098do
4099  IFS=$as_save_IFS
4100  test -z "$as_dir" && as_dir=.
4101    for ac_exec_ext in '' $ac_executable_extensions; do
4102  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4103    ac_cv_path_XCODE_SELECT="$as_dir/$ac_word$ac_exec_ext"
4104    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4105    break 2
4106  fi
4107done
4108  done
4109IFS=$as_save_IFS
4110
4111  ;;
4112esac
4113fi
4114XCODE_SELECT=$ac_cv_path_XCODE_SELECT
4115if test -n "$XCODE_SELECT"; then
4116  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODE_SELECT" >&5
4117$as_echo "$XCODE_SELECT" >&6; }
4118else
4119  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4120$as_echo "no" >&6; }
4121fi
4122
4123
4124    if test "x$XCODE_SELECT" != "x"; then
4125      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for developer dir using xcode-select" >&5
4126$as_echo_n "checking for developer dir using xcode-select... " >&6; }
4127      DEVELOPER_DIR=`$XCODE_SELECT -print-path`
4128      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVELOPER_DIR" >&5
4129$as_echo "$DEVELOPER_DIR" >&6; }
4130    else
4131      DEVELOPER_DIR=/Developer
4132    fi
4133  fi
4134
4135  if test "x$MACARCH" = "xboth"; then
4136    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 10.4 universal SDK" >&5
4137$as_echo_n "checking for 10.4 universal SDK... " >&6; }
4138                            save_cppflags="$CPPFLAGS"
4139    save_cflags="$CFLAGS"
4140    save_ldflags="$LDFLAGS"
4141    CFLAGS="$CFLAGS -isysroot $DEVELOPER_DIR/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
4142    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4143/* end confdefs.h.  */
4144
4145int
4146main ()
4147{
4148
4149  ;
4150  return 0;
4151}
4152_ACEOF
4153if ac_fn_c_try_link "$LINENO"; then :
4154  { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
4155$as_echo "found" >&6; }
4156else
4157  { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4158$as_echo "not found" >&6; }
4159	CFLAGS="$save_cflags"
4160	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if Intel architecture is supported" >&5
4161$as_echo_n "checking if Intel architecture is supported... " >&6; }
4162	CPPFLAGS="$CPPFLAGS -arch i386"
4163	LDFLAGS="$save_ldflags -arch i386"
4164	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4165/* end confdefs.h.  */
4166
4167int
4168main ()
4169{
4170
4171  ;
4172  return 0;
4173}
4174_ACEOF
4175if ac_fn_c_try_link "$LINENO"; then :
4176  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4177$as_echo "yes" >&6; }; MACARCH="intel"
4178else
4179  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4180$as_echo "no" >&6; }
4181		MACARCH="ppc"
4182		CPPFLAGS="$save_cppflags -arch ppc"
4183		LDFLAGS="$save_ldflags -arch ppc"
4184fi
4185rm -f core conftest.err conftest.$ac_objext \
4186    conftest$ac_exeext conftest.$ac_ext
4187fi
4188rm -f core conftest.err conftest.$ac_objext \
4189    conftest$ac_exeext conftest.$ac_ext
4190  elif test "x$MACARCH" = "xintel"; then
4191    CPPFLAGS="$CPPFLAGS -arch intel"
4192    LDFLAGS="$LDFLAGS -arch intel"
4193  elif test "x$MACARCH" = "xppc"; then
4194    CPPFLAGS="$CPPFLAGS -arch ppc"
4195    LDFLAGS="$LDFLAGS -arch ppc"
4196  fi
4197
4198  if test "$enable_darwin" = "yes"; then
4199    MACOSX=yes
4200    OS_EXTRA_SRC="os_macosx.m os_mac_conv.c";
4201    OS_EXTRA_OBJ="objects/os_macosx.o objects/os_mac_conv.o"
4202        CPPFLAGS="$CPPFLAGS -DMACOS_X_UNIX -no-cpp-precomp"
4203
4204                # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4205for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4206		  inttypes.h stdint.h unistd.h
4207do :
4208  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4209ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4210"
4211eval as_val=\$$as_ac_Header
4212   if test "x$as_val" = x""yes; then :
4213  cat >>confdefs.h <<_ACEOF
4214#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4215_ACEOF
4216
4217fi
4218
4219done
4220
4221
4222ac_fn_c_check_header_mongrel "$LINENO" "Carbon/Carbon.h" "ac_cv_header_Carbon_Carbon_h" "$ac_includes_default"
4223if test "x$ac_cv_header_Carbon_Carbon_h" = x""yes; then :
4224  CARBON=yes
4225fi
4226
4227
4228    if test "x$CARBON" = "xyes"; then
4229      if test -z "$with_x" -a "X$enable_gui" != Xmotif -a "X$enable_gui" != Xathena -a "X$enable_gui" != Xgtk2; then
4230	with_x=no
4231      fi
4232    fi
4233  fi
4234
4235        if test "$MACARCH" = "intel" -o "$MACARCH" = "both"; then
4236    CFLAGS=`echo "$CFLAGS" | sed 's/-O[23456789]/-Oz/'`
4237  fi
4238
4239else
4240  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4241$as_echo "no" >&6; }
4242fi
4243
4244
4245
4246
4247if test "$cross_compiling" = no; then
4248  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-local-dir argument" >&5
4249$as_echo_n "checking --with-local-dir argument... " >&6; }
4250  have_local_include=''
4251  have_local_lib=''
4252
4253# Check whether --with-local-dir was given.
4254if test "${with_local_dir+set}" = set; then :
4255  withval=$with_local_dir;
4256    local_dir="$withval"
4257    case "$withval" in
4258    */*) ;;
4259    no)
4260      # avoid adding local dir to LDFLAGS and CPPFLAGS
4261      have_local_include=yes
4262      have_local_lib=yes
4263      ;;
4264    *) as_fn_error "must pass path argument to --with-local-dir" "$LINENO" 5 ;;
4265    esac
4266	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $local_dir" >&5
4267$as_echo "$local_dir" >&6; }
4268
4269else
4270
4271    local_dir=/usr/local
4272    { $as_echo "$as_me:${as_lineno-$LINENO}: result: Defaulting to $local_dir" >&5
4273$as_echo "Defaulting to $local_dir" >&6; }
4274
4275fi
4276
4277  if test "$GCC" = yes -a "$local_dir" != no; then
4278    echo 'void f(){}' > conftest.c
4279        have_local_include=`${CC-cc} -no-cpp-precomp -c -v conftest.c 2>&1 | grep "${local_dir}/include"`
4280    have_local_lib=`${CC-cc} -c -v conftest.c 2>&1 | grep "${local_dir}/lib"`
4281    rm -f conftest.c conftest.o
4282  fi
4283  if test -z "$have_local_lib" -a -d "${local_dir}/lib"; then
4284    tt=`echo "$LDFLAGS" | sed -e "s+-L${local_dir}/lib ++g" -e "s+-L${local_dir}/lib$++g"`
4285    if test "$tt" = "$LDFLAGS"; then
4286      LDFLAGS="$LDFLAGS -L${local_dir}/lib"
4287    fi
4288  fi
4289  if test -z "$have_local_include" -a -d "${local_dir}/include"; then
4290    tt=`echo "$CPPFLAGS" | sed -e "s+-I${local_dir}/include ++g" -e "s+-I${local_dir}/include$++g"`
4291    if test "$tt" = "$CPPFLAGS"; then
4292      CPPFLAGS="$CPPFLAGS -I${local_dir}/include"
4293    fi
4294  fi
4295fi
4296
4297{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-vim-name argument" >&5
4298$as_echo_n "checking --with-vim-name argument... " >&6; }
4299
4300# Check whether --with-vim-name was given.
4301if test "${with_vim_name+set}" = set; then :
4302  withval=$with_vim_name; VIMNAME="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VIMNAME" >&5
4303$as_echo "$VIMNAME" >&6; }
4304else
4305  VIMNAME="vim"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: Defaulting to $VIMNAME" >&5
4306$as_echo "Defaulting to $VIMNAME" >&6; }
4307fi
4308
4309
4310{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-ex-name argument" >&5
4311$as_echo_n "checking --with-ex-name argument... " >&6; }
4312
4313# Check whether --with-ex-name was given.
4314if test "${with_ex_name+set}" = set; then :
4315  withval=$with_ex_name; EXNAME="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXNAME" >&5
4316$as_echo "$EXNAME" >&6; }
4317else
4318  EXNAME="ex"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: Defaulting to ex" >&5
4319$as_echo "Defaulting to ex" >&6; }
4320fi
4321
4322
4323{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-view-name argument" >&5
4324$as_echo_n "checking --with-view-name argument... " >&6; }
4325
4326# Check whether --with-view-name was given.
4327if test "${with_view_name+set}" = set; then :
4328  withval=$with_view_name; VIEWNAME="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VIEWNAME" >&5
4329$as_echo "$VIEWNAME" >&6; }
4330else
4331  VIEWNAME="view"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: Defaulting to view" >&5
4332$as_echo "Defaulting to view" >&6; }
4333fi
4334
4335
4336
4337{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-global-runtime argument" >&5
4338$as_echo_n "checking --with-global-runtime argument... " >&6; }
4339
4340# Check whether --with-global-runtime was given.
4341if test "${with_global_runtime+set}" = set; then :
4342  withval=$with_global_runtime; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
4343$as_echo "$withval" >&6; }; cat >>confdefs.h <<_ACEOF
4344#define RUNTIME_GLOBAL "$withval"
4345_ACEOF
4346
4347else
4348  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4349$as_echo "no" >&6; }
4350fi
4351
4352
4353{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-modified-by argument" >&5
4354$as_echo_n "checking --with-modified-by argument... " >&6; }
4355
4356# Check whether --with-modified-by was given.
4357if test "${with_modified_by+set}" = set; then :
4358  withval=$with_modified_by; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
4359$as_echo "$withval" >&6; }; cat >>confdefs.h <<_ACEOF
4360#define MODIFIED_BY "$withval"
4361_ACEOF
4362
4363else
4364  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4365$as_echo "no" >&6; }
4366fi
4367
4368
4369{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if character set is EBCDIC" >&5
4370$as_echo_n "checking if character set is EBCDIC... " >&6; }
4371cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4372/* end confdefs.h.  */
4373
4374int
4375main ()
4376{
4377 /* TryCompile function for CharSet.
4378   Treat any failure as ASCII for compatibility with existing art.
4379   Use compile-time rather than run-time tests for cross-compiler
4380   tolerance.  */
4381#if '0'!=240
4382make an error "Character set is not EBCDIC"
4383#endif
4384  ;
4385  return 0;
4386}
4387_ACEOF
4388if ac_fn_c_try_compile "$LINENO"; then :
4389   # TryCompile action if true
4390cf_cv_ebcdic=yes
4391else
4392   # TryCompile action if false
4393cf_cv_ebcdic=no
4394fi
4395rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4396# end of TryCompile ])
4397# end of CacheVal CvEbcdic
4398{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cf_cv_ebcdic" >&5
4399$as_echo "$cf_cv_ebcdic" >&6; }
4400case "$cf_cv_ebcdic" in  #(vi
4401    yes)	$as_echo "#define EBCDIC 1" >>confdefs.h
4402
4403		line_break='"\\n"'
4404		;;
4405    *)		line_break='"\\012"';;
4406esac
4407
4408
4409if test "$cf_cv_ebcdic" = "yes"; then
4410{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for z/OS Unix" >&5
4411$as_echo_n "checking for z/OS Unix... " >&6; }
4412case `uname` in
4413    OS/390)	zOSUnix="yes";
4414										if test "$CC" = "cc"; then
4415		  ccm="$_CC_CCMODE"
4416		  ccn="CC"
4417		else
4418		  if test "$CC" = "c89"; then
4419		    ccm="$_CC_C89MODE"
4420		    ccn="C89"
4421		  else
4422		    ccm=1
4423		  fi
4424		fi
4425		if test "$ccm" != "1"; then
4426		  echo ""
4427		  echo "------------------------------------------"
4428		  echo " On z/OS Unix, the environment variable"
4429		  echo " _CC_${ccn}MODE must be set to \"1\"!"
4430		  echo " Do:"
4431		  echo "    export _CC_${ccn}MODE=1"
4432		  echo " and then call configure again."
4433		  echo "------------------------------------------"
4434		  exit 1
4435		fi
4436		# Set CFLAGS for configure process.
4437		# This will be reset later for config.mk.
4438		# Use haltonmsg to force error for missing H files.
4439		CFLAGS="$CFLAGS -D_ALL_SOURCE -Wc,float(ieee),haltonmsg(3296)";
4440		LDFLAGS="$LDFLAGS -Wl,EDIT=NO"
4441		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4442$as_echo "yes" >&6; }
4443		;;
4444    *)		zOSUnix="no";
4445		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4446$as_echo "no" >&6; }
4447		;;
4448esac
4449fi
4450
4451if test "$zOSUnix" = "yes"; then
4452    QUOTESED="sed -e 's/[\\\\\"]/\\\\\\\\&/g' -e 's/\\\\\\\\\"/\"/' -e 's/\\\\\\\\\";\$\$/\";/'"
4453else
4454    QUOTESED="sed -e 's/[\\\\\"]/\\\\&/g' -e 's/\\\\\"/\"/' -e 's/\\\\\";\$\$/\";/'"
4455fi
4456
4457
4458
4459{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-selinux argument" >&5
4460$as_echo_n "checking --disable-selinux argument... " >&6; }
4461# Check whether --enable-selinux was given.
4462if test "${enable_selinux+set}" = set; then :
4463  enableval=$enable_selinux;
4464else
4465  enable_selinux="yes"
4466fi
4467
4468if test "$enable_selinux" = "yes"; then
4469  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4470$as_echo "no" >&6; }
4471  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for is_selinux_enabled in -lselinux" >&5
4472$as_echo_n "checking for is_selinux_enabled in -lselinux... " >&6; }
4473if test "${ac_cv_lib_selinux_is_selinux_enabled+set}" = set; then :
4474  $as_echo_n "(cached) " >&6
4475else
4476  ac_check_lib_save_LIBS=$LIBS
4477LIBS="-lselinux  $LIBS"
4478cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4479/* end confdefs.h.  */
4480
4481/* Override any GCC internal prototype to avoid an error.
4482   Use char because int might match the return type of a GCC
4483   builtin and then its argument prototype would still apply.  */
4484#ifdef __cplusplus
4485extern "C"
4486#endif
4487char is_selinux_enabled ();
4488int
4489main ()
4490{
4491return is_selinux_enabled ();
4492  ;
4493  return 0;
4494}
4495_ACEOF
4496if ac_fn_c_try_link "$LINENO"; then :
4497  ac_cv_lib_selinux_is_selinux_enabled=yes
4498else
4499  ac_cv_lib_selinux_is_selinux_enabled=no
4500fi
4501rm -f core conftest.err conftest.$ac_objext \
4502    conftest$ac_exeext conftest.$ac_ext
4503LIBS=$ac_check_lib_save_LIBS
4504fi
4505{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_is_selinux_enabled" >&5
4506$as_echo "$ac_cv_lib_selinux_is_selinux_enabled" >&6; }
4507if test "x$ac_cv_lib_selinux_is_selinux_enabled" = x""yes; then :
4508  LIBS="$LIBS -lselinux"
4509	   $as_echo "#define HAVE_SELINUX 1" >>confdefs.h
4510
4511fi
4512
4513else
4514   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4515$as_echo "yes" >&6; }
4516fi
4517
4518
4519{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-features argument" >&5
4520$as_echo_n "checking --with-features argument... " >&6; }
4521
4522# Check whether --with-features was given.
4523if test "${with_features+set}" = set; then :
4524  withval=$with_features; features="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $features" >&5
4525$as_echo "$features" >&6; }
4526else
4527  features="normal"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: Defaulting to normal" >&5
4528$as_echo "Defaulting to normal" >&6; }
4529fi
4530
4531
4532dovimdiff=""
4533dogvimdiff=""
4534case "$features" in
4535  tiny)		$as_echo "#define FEAT_TINY 1" >>confdefs.h
4536 ;;
4537  small)	$as_echo "#define FEAT_SMALL 1" >>confdefs.h
4538 ;;
4539  normal)	$as_echo "#define FEAT_NORMAL 1" >>confdefs.h
4540 dovimdiff="installvimdiff";
4541			dogvimdiff="installgvimdiff" ;;
4542  big)		$as_echo "#define FEAT_BIG 1" >>confdefs.h
4543 dovimdiff="installvimdiff";
4544			dogvimdiff="installgvimdiff" ;;
4545  huge)		$as_echo "#define FEAT_HUGE 1" >>confdefs.h
4546 dovimdiff="installvimdiff";
4547			dogvimdiff="installgvimdiff" ;;
4548  *)		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Sorry, $features is not supported" >&5
4549$as_echo "Sorry, $features is not supported" >&6; } ;;
4550esac
4551
4552
4553
4554
4555{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-compiledby argument" >&5
4556$as_echo_n "checking --with-compiledby argument... " >&6; }
4557
4558# Check whether --with-compiledby was given.
4559if test "${with_compiledby+set}" = set; then :
4560  withval=$with_compiledby; compiledby="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
4561$as_echo "$withval" >&6; }
4562else
4563  compiledby=""; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4564$as_echo "no" >&6; }
4565fi
4566
4567
4568
4569{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-xsmp argument" >&5
4570$as_echo_n "checking --disable-xsmp argument... " >&6; }
4571# Check whether --enable-xsmp was given.
4572if test "${enable_xsmp+set}" = set; then :
4573  enableval=$enable_xsmp;
4574else
4575  enable_xsmp="yes"
4576fi
4577
4578
4579if test "$enable_xsmp" = "yes"; then
4580  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4581$as_echo "no" >&6; }
4582  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-xsmp-interact argument" >&5
4583$as_echo_n "checking --disable-xsmp-interact argument... " >&6; }
4584  # Check whether --enable-xsmp-interact was given.
4585if test "${enable_xsmp_interact+set}" = set; then :
4586  enableval=$enable_xsmp_interact;
4587else
4588  enable_xsmp_interact="yes"
4589fi
4590
4591  if test "$enable_xsmp_interact" = "yes"; then
4592    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4593$as_echo "no" >&6; }
4594    $as_echo "#define USE_XSMP_INTERACT 1" >>confdefs.h
4595
4596  else
4597    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4598$as_echo "yes" >&6; }
4599  fi
4600else
4601  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4602$as_echo "yes" >&6; }
4603fi
4604
4605{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-luainterp argument" >&5
4606$as_echo_n "checking --enable-luainterp argument... " >&6; }
4607# Check whether --enable-luainterp was given.
4608if test "${enable_luainterp+set}" = set; then :
4609  enableval=$enable_luainterp;
4610else
4611  enable_luainterp="no"
4612fi
4613
4614{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_luainterp" >&5
4615$as_echo "$enable_luainterp" >&6; }
4616
4617if test "$enable_luainterp" = "yes" -o "$enable_luainterp" = "dynamic"; then
4618
4619
4620  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-lua-prefix argument" >&5
4621$as_echo_n "checking --with-lua-prefix argument... " >&6; }
4622
4623# Check whether --with-lua_prefix was given.
4624if test "${with_lua_prefix+set}" = set; then :
4625  withval=$with_lua_prefix; with_lua_prefix="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_lua_prefix" >&5
4626$as_echo "$with_lua_prefix" >&6; }
4627else
4628  with_lua_prefix="";{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4629$as_echo "no" >&6; }
4630fi
4631
4632
4633  if test "X$with_lua_prefix" != "X"; then
4634       vi_cv_path_lua_pfx="$with_lua_prefix"
4635  else
4636    { $as_echo "$as_me:${as_lineno-$LINENO}: checking LUA_PREFIX environment var" >&5
4637$as_echo_n "checking LUA_PREFIX environment var... " >&6; }
4638    if test "X$LUA_PREFIX" != "X"; then
4639	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: \"$LUA_PREFIX\"" >&5
4640$as_echo "\"$LUA_PREFIX\"" >&6; }
4641	vi_cv_path_lua_pfx="$LUA_PREFIX"
4642    else
4643	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: not set, default to /usr" >&5
4644$as_echo "not set, default to /usr" >&6; }
4645	vi_cv_path_lua_pfx="/usr"
4646    fi
4647  fi
4648
4649  LUA_INC=
4650  if test "X$vi_cv_path_lua_pfx" != "X"; then
4651        # Extract the first word of "lua", so it can be a program name with args.
4652set dummy lua; ac_word=$2
4653{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4654$as_echo_n "checking for $ac_word... " >&6; }
4655if test "${ac_cv_path_vi_cv_path_lua+set}" = set; then :
4656  $as_echo_n "(cached) " >&6
4657else
4658  case $vi_cv_path_lua in
4659  [\\/]* | ?:[\\/]*)
4660  ac_cv_path_vi_cv_path_lua="$vi_cv_path_lua" # Let the user override the test with a path.
4661  ;;
4662  *)
4663  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4664for as_dir in $PATH
4665do
4666  IFS=$as_save_IFS
4667  test -z "$as_dir" && as_dir=.
4668    for ac_exec_ext in '' $ac_executable_extensions; do
4669  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4670    ac_cv_path_vi_cv_path_lua="$as_dir/$ac_word$ac_exec_ext"
4671    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4672    break 2
4673  fi
4674done
4675  done
4676IFS=$as_save_IFS
4677
4678  ;;
4679esac
4680fi
4681vi_cv_path_lua=$ac_cv_path_vi_cv_path_lua
4682if test -n "$vi_cv_path_lua"; then
4683  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_lua" >&5
4684$as_echo "$vi_cv_path_lua" >&6; }
4685else
4686  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4687$as_echo "no" >&6; }
4688fi
4689
4690
4691    if test "X$vi_cv_path_lua" != "X"; then
4692            { $as_echo "$as_me:${as_lineno-$LINENO}: checking Lua version" >&5
4693$as_echo_n "checking Lua version... " >&6; }
4694if test "${vi_cv_version_lua+set}" = set; then :
4695  $as_echo_n "(cached) " >&6
4696else
4697   vi_cv_version_lua=`${vi_cv_path_lua} -e "print(_VERSION)" | sed 's/.* //'`
4698fi
4699{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_version_lua" >&5
4700$as_echo "$vi_cv_version_lua" >&6; }
4701    fi
4702    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if lua.h can be found in $vi_cv_path_lua_pfx/include" >&5
4703$as_echo_n "checking if lua.h can be found in $vi_cv_path_lua_pfx/include... " >&6; }
4704    if test -f $vi_cv_path_lua_pfx/include/lua.h; then
4705      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4706$as_echo "yes" >&6; }
4707    else
4708      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4709$as_echo "no" >&6; }
4710      { $as_echo "$as_me:${as_lineno-$LINENO}: checking if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua" >&5
4711$as_echo_n "checking if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua... " >&6; }
4712      if test -f $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua/lua.h; then
4713        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4714$as_echo "yes" >&6; }
4715        LUA_INC=/lua$vi_cv_version_lua
4716      else
4717        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4718$as_echo "no" >&6; }
4719        vi_cv_path_lua_pfx=
4720      fi
4721    fi
4722  fi
4723
4724  if test "X$vi_cv_path_lua_pfx" != "X"; then
4725    if test "X$LUA_INC" != "X"; then
4726            LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua$vi_cv_version_lua"
4727    else
4728      LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua"
4729    fi
4730    LUA_CFLAGS="-I${vi_cv_path_lua_pfx}/include${LUA_INC}"
4731    LUA_SRC="if_lua.c"
4732    LUA_OBJ="objects/if_lua.o"
4733    LUA_PRO="if_lua.pro"
4734    $as_echo "#define FEAT_LUA 1" >>confdefs.h
4735
4736    if test "$enable_luainterp" = "dynamic"; then
4737      if test -f "${vi_cv_path_lua_pfx}/bin/cyglua-${vi_cv_version_lua}.dll"; then
4738	vi_cv_dll_name_lua="cyglua-${vi_cv_version_lua}.dll"
4739      else
4740	multiarch=`dpkg-architecture -qDEB_HOST_MULTIARCH 2> /dev/null`
4741	if test "X$multiarch" != "X"; then
4742	  lib_multiarch="lib/${multiarch}"
4743	fi
4744			for subdir in "${lib_multiarch}" lib64 lib; do
4745	  if test -z "$subdir"; then
4746	    continue
4747	  fi
4748	  for sover in "${vi_cv_version_lua}.so" "-${vi_cv_version_lua}.so" ".so.${vi_cv_version_lua}"; do
4749	    for i in .0 .1 .2 .3 .4 .5 .6 .7 .8 .9 ""; do
4750	      if test -f "${vi_cv_path_lua_pfx}/${subdir}/liblua${sover}$i"; then
4751		sover2="$i"
4752		break 3
4753	      fi
4754	    done
4755	  done
4756	done
4757	vi_cv_dll_name_lua="liblua${sover}$sover2"
4758      fi
4759      $as_echo "#define DYNAMIC_LUA 1" >>confdefs.h
4760
4761      LUA_LIBS=""
4762      LUA_CFLAGS="-DDYNAMIC_LUA_DLL=\\\"${vi_cv_dll_name_lua}\\\" $LUA_CFLAGS"
4763    fi
4764  fi
4765  if test "$fail_if_missing" = "yes" -a -z "$LUA_SRC"; then
4766    as_fn_error "could not configure lua" "$LINENO" 5
4767  fi
4768
4769
4770
4771
4772
4773fi
4774
4775
4776{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-mzschemeinterp argument" >&5
4777$as_echo_n "checking --enable-mzschemeinterp argument... " >&6; }
4778# Check whether --enable-mzschemeinterp was given.
4779if test "${enable_mzschemeinterp+set}" = set; then :
4780  enableval=$enable_mzschemeinterp;
4781else
4782  enable_mzschemeinterp="no"
4783fi
4784
4785{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_mzschemeinterp" >&5
4786$as_echo "$enable_mzschemeinterp" >&6; }
4787
4788if test "$enable_mzschemeinterp" = "yes"; then
4789
4790
4791  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-plthome argument" >&5
4792$as_echo_n "checking --with-plthome argument... " >&6; }
4793
4794# Check whether --with-plthome was given.
4795if test "${with_plthome+set}" = set; then :
4796  withval=$with_plthome; with_plthome="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_plthome" >&5
4797$as_echo "$with_plthome" >&6; }
4798else
4799  with_plthome="";{ $as_echo "$as_me:${as_lineno-$LINENO}: result: \"no\"" >&5
4800$as_echo "\"no\"" >&6; }
4801fi
4802
4803
4804  if test "X$with_plthome" != "X"; then
4805       vi_cv_path_mzscheme_pfx="$with_plthome"
4806  else
4807    { $as_echo "$as_me:${as_lineno-$LINENO}: checking PLTHOME environment var" >&5
4808$as_echo_n "checking PLTHOME environment var... " >&6; }
4809    if test "X$PLTHOME" != "X"; then
4810	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: \"$PLTHOME\"" >&5
4811$as_echo "\"$PLTHOME\"" >&6; }
4812	vi_cv_path_mzscheme_pfx="$PLTHOME"
4813    else
4814	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: not set" >&5
4815$as_echo "not set" >&6; }
4816		# Extract the first word of "mzscheme", so it can be a program name with args.
4817set dummy mzscheme; ac_word=$2
4818{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4819$as_echo_n "checking for $ac_word... " >&6; }
4820if test "${ac_cv_path_vi_cv_path_mzscheme+set}" = set; then :
4821  $as_echo_n "(cached) " >&6
4822else
4823  case $vi_cv_path_mzscheme in
4824  [\\/]* | ?:[\\/]*)
4825  ac_cv_path_vi_cv_path_mzscheme="$vi_cv_path_mzscheme" # Let the user override the test with a path.
4826  ;;
4827  *)
4828  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4829for as_dir in $PATH
4830do
4831  IFS=$as_save_IFS
4832  test -z "$as_dir" && as_dir=.
4833    for ac_exec_ext in '' $ac_executable_extensions; do
4834  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4835    ac_cv_path_vi_cv_path_mzscheme="$as_dir/$ac_word$ac_exec_ext"
4836    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4837    break 2
4838  fi
4839done
4840  done
4841IFS=$as_save_IFS
4842
4843  ;;
4844esac
4845fi
4846vi_cv_path_mzscheme=$ac_cv_path_vi_cv_path_mzscheme
4847if test -n "$vi_cv_path_mzscheme"; then
4848  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_mzscheme" >&5
4849$as_echo "$vi_cv_path_mzscheme" >&6; }
4850else
4851  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4852$as_echo "no" >&6; }
4853fi
4854
4855
4856
4857			if test "X$vi_cv_path_mzscheme" != "X"; then
4858	  lsout=`ls -l $vi_cv_path_mzscheme`
4859	  if echo "$lsout" | grep -e '->' >/dev/null 2>/dev/null; then
4860	    vi_cv_path_mzscheme=`echo "$lsout" | sed 's/.*-> \(.*\)/\1/'`
4861	  fi
4862	fi
4863
4864	if test "X$vi_cv_path_mzscheme" != "X"; then
4865	    	    { $as_echo "$as_me:${as_lineno-$LINENO}: checking MzScheme install prefix" >&5
4866$as_echo_n "checking MzScheme install prefix... " >&6; }
4867if test "${vi_cv_path_mzscheme_pfx+set}" = set; then :
4868  $as_echo_n "(cached) " >&6
4869else
4870  	    	    echo "(display (simplify-path		\
4871	       (build-path (call-with-values	\
4872		(lambda () (split-path (find-system-path (quote exec-file)))) \
4873		(lambda (base name must-be-dir?) base)) (quote up))))" > mzdirs.scm
4874	    	     vi_cv_path_mzscheme_pfx=`${vi_cv_path_mzscheme} -r mzdirs.scm | \
4875		sed -e 's+/$++'`
4876fi
4877{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_mzscheme_pfx" >&5
4878$as_echo "$vi_cv_path_mzscheme_pfx" >&6; }
4879	    rm -f mzdirs.scm
4880	fi
4881    fi
4882  fi
4883
4884  SCHEME_INC=
4885  if test "X$vi_cv_path_mzscheme_pfx" != "X"; then
4886    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if scheme.h can be found in $vi_cv_path_mzscheme_pfx/include" >&5
4887$as_echo_n "checking if scheme.h can be found in $vi_cv_path_mzscheme_pfx/include... " >&6; }
4888    if test -f $vi_cv_path_mzscheme_pfx/include/scheme.h; then
4889      SCHEME_INC=${vi_cv_path_mzscheme_pfx}/include
4890      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4891$as_echo "yes" >&6; }
4892    else
4893      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4894$as_echo "no" >&6; }
4895      { $as_echo "$as_me:${as_lineno-$LINENO}: checking if scheme.h can be found in $vi_cv_path_mzscheme_pfx/include/plt" >&5
4896$as_echo_n "checking if scheme.h can be found in $vi_cv_path_mzscheme_pfx/include/plt... " >&6; }
4897      if test -f $vi_cv_path_mzscheme_pfx/include/plt/scheme.h; then
4898	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4899$as_echo "yes" >&6; }
4900	SCHEME_INC=${vi_cv_path_mzscheme_pfx}/include/plt
4901      else
4902	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4903$as_echo "no" >&6; }
4904	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if scheme.h can be found in $vi_cv_path_mzscheme_pfx/include/racket" >&5
4905$as_echo_n "checking if scheme.h can be found in $vi_cv_path_mzscheme_pfx/include/racket... " >&6; }
4906	if test -f $vi_cv_path_mzscheme_pfx/include/racket/scheme.h; then
4907	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4908$as_echo "yes" >&6; }
4909	  SCHEME_INC=${vi_cv_path_mzscheme_pfx}/include/racket
4910	else
4911	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4912$as_echo "no" >&6; }
4913	  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if scheme.h can be found in /usr/include/plt/" >&5
4914$as_echo_n "checking if scheme.h can be found in /usr/include/plt/... " >&6; }
4915	  if test -f /usr/include/plt/scheme.h; then
4916	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4917$as_echo "yes" >&6; }
4918	    SCHEME_INC=/usr/include/plt
4919	  else
4920	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4921$as_echo "no" >&6; }
4922	    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if scheme.h can be found in /usr/include/racket/" >&5
4923$as_echo_n "checking if scheme.h can be found in /usr/include/racket/... " >&6; }
4924	    if test -f /usr/include/racket/scheme.h; then
4925	      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4926$as_echo "yes" >&6; }
4927	      SCHEME_INC=/usr/include/racket
4928	    else
4929	      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4930$as_echo "no" >&6; }
4931	      vi_cv_path_mzscheme_pfx=
4932	    fi
4933	  fi
4934	fi
4935      fi
4936    fi
4937  fi
4938
4939  if test "X$vi_cv_path_mzscheme_pfx" != "X"; then
4940    if test "x$MACOSX" = "xyes"; then
4941      MZSCHEME_LIBS="-framework Racket"
4942      MZSCHEME_CFLAGS="-DMZ_PRECISE_GC"
4943    elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a"; then
4944      MZSCHEME_LIBS="${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.a"
4945      MZSCHEME_CFLAGS="-DMZ_PRECISE_GC"
4946    elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libracket3m.a"; then
4947      MZSCHEME_LIBS="${vi_cv_path_mzscheme_pfx}/lib/libracket3m.a"
4948      MZSCHEME_CFLAGS="-DMZ_PRECISE_GC"
4949    elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libracket.a"; then
4950      MZSCHEME_LIBS="${vi_cv_path_mzscheme_pfx}/lib/libracket.a ${vi_cv_path_mzscheme_pfx}/lib/libmzgc.a"
4951    elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libmzscheme.a"; then
4952      MZSCHEME_LIBS="${vi_cv_path_mzscheme_pfx}/lib/libmzscheme.a ${vi_cv_path_mzscheme_pfx}/lib/libmzgc.a"
4953    else
4954            if test -f "${vi_cv_path_mzscheme_pfx}/lib/libmzscheme3m.so"; then
4955        MZSCHEME_LIBS="-L${vi_cv_path_mzscheme_pfx}/lib -lmzscheme3m"
4956	MZSCHEME_CFLAGS="-DMZ_PRECISE_GC"
4957      elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libracket3m.so"; then
4958        MZSCHEME_LIBS="-L${vi_cv_path_mzscheme_pfx}/lib -lracket3m"
4959	MZSCHEME_CFLAGS="-DMZ_PRECISE_GC"
4960      elif test -f "${vi_cv_path_mzscheme_pfx}/lib/libracket.so"; then
4961        MZSCHEME_LIBS="-L${vi_cv_path_mzscheme_pfx}/lib -lracket -lmzgc"
4962      else
4963        MZSCHEME_LIBS="-L${vi_cv_path_mzscheme_pfx}/lib -lmzscheme -lmzgc"
4964      fi
4965      if test "$GCC" = yes; then
4966			MZSCHEME_LIBS="${MZSCHEME_LIBS} -Wl,-rpath -Wl,${vi_cv_path_mzscheme_pfx}/lib"
4967      elif test "`(uname) 2>/dev/null`" = SunOS &&
4968			       uname -r | grep '^5' >/dev/null; then
4969	MZSCHEME_LIBS="${MZSCHEME_LIBS} -R ${vi_cv_path_mzscheme_pfx}/lib"
4970      fi
4971    fi
4972
4973    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for racket collects directory" >&5
4974$as_echo_n "checking for racket collects directory... " >&6; }
4975    if test -d $vi_cv_path_mzscheme_pfx/lib/plt/collects; then
4976      SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/lib/plt/
4977    else
4978      if test -d $vi_cv_path_mzscheme_pfx/lib/racket/collects; then
4979	SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/lib/racket/
4980      else
4981	if test -d $vi_cv_path_mzscheme_pfx/share/racket/collects; then
4982	  SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/share/racket/
4983	else
4984	  if test -d $vi_cv_path_mzscheme_pfx/collects; then
4985	    SCHEME_COLLECTS=$vi_cv_path_mzscheme_pfx/
4986	  fi
4987	fi
4988      fi
4989    fi
4990    if test "X$SCHEME_COLLECTS" != "X" ; then
4991      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${SCHEME_COLLECTS}" >&5
4992$as_echo "${SCHEME_COLLECTS}" >&6; }
4993    else
4994      { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4995$as_echo "not found" >&6; }
4996    fi
4997
4998    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mzscheme_base.c" >&5
4999$as_echo_n "checking for mzscheme_base.c... " >&6; }
5000    if test -f "${SCHEME_COLLECTS}collects/scheme/base.ss" ; then
5001      MZSCHEME_EXTRA="mzscheme_base.c"
5002    else
5003      if test -f "${SCHEME_COLLECTS}collects/scheme/base.rkt" ; then
5004	MZSCHEME_EXTRA="mzscheme_base.c"
5005      fi
5006    fi
5007    if test "X$MZSCHEME_EXTRA" != "X" ; then
5008            MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -DINCLUDE_MZSCHEME_BASE"
5009      MZSCHEME_MZC="${vi_cv_path_mzscheme_pfx}/bin/mzc"
5010      { $as_echo "$as_me:${as_lineno-$LINENO}: result: needed" >&5
5011$as_echo "needed" >&6; }
5012    else
5013      { $as_echo "$as_me:${as_lineno-$LINENO}: result: not needed" >&5
5014$as_echo "not needed" >&6; }
5015    fi
5016
5017    MZSCHEME_CFLAGS="${MZSCHEME_CFLAGS} -I${SCHEME_INC} \
5018      -DMZSCHEME_COLLECTS='\"${SCHEME_COLLECTS}collects\"'"
5019    MZSCHEME_SRC="if_mzsch.c"
5020    MZSCHEME_OBJ="objects/if_mzsch.o"
5021    MZSCHEME_PRO="if_mzsch.pro"
5022    $as_echo "#define FEAT_MZSCHEME 1" >>confdefs.h
5023
5024  fi
5025
5026
5027
5028
5029
5030
5031
5032fi
5033
5034
5035{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-perlinterp argument" >&5
5036$as_echo_n "checking --enable-perlinterp argument... " >&6; }
5037# Check whether --enable-perlinterp was given.
5038if test "${enable_perlinterp+set}" = set; then :
5039  enableval=$enable_perlinterp;
5040else
5041  enable_perlinterp="no"
5042fi
5043
5044{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_perlinterp" >&5
5045$as_echo "$enable_perlinterp" >&6; }
5046if test "$enable_perlinterp" = "yes" -o "$enable_perlinterp" = "dynamic"; then
5047
5048  # Extract the first word of "perl", so it can be a program name with args.
5049set dummy perl; ac_word=$2
5050{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5051$as_echo_n "checking for $ac_word... " >&6; }
5052if test "${ac_cv_path_vi_cv_path_perl+set}" = set; then :
5053  $as_echo_n "(cached) " >&6
5054else
5055  case $vi_cv_path_perl in
5056  [\\/]* | ?:[\\/]*)
5057  ac_cv_path_vi_cv_path_perl="$vi_cv_path_perl" # Let the user override the test with a path.
5058  ;;
5059  *)
5060  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5061for as_dir in $PATH
5062do
5063  IFS=$as_save_IFS
5064  test -z "$as_dir" && as_dir=.
5065    for ac_exec_ext in '' $ac_executable_extensions; do
5066  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5067    ac_cv_path_vi_cv_path_perl="$as_dir/$ac_word$ac_exec_ext"
5068    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5069    break 2
5070  fi
5071done
5072  done
5073IFS=$as_save_IFS
5074
5075  ;;
5076esac
5077fi
5078vi_cv_path_perl=$ac_cv_path_vi_cv_path_perl
5079if test -n "$vi_cv_path_perl"; then
5080  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_perl" >&5
5081$as_echo "$vi_cv_path_perl" >&6; }
5082else
5083  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5084$as_echo "no" >&6; }
5085fi
5086
5087
5088  if test "X$vi_cv_path_perl" != "X"; then
5089    { $as_echo "$as_me:${as_lineno-$LINENO}: checking Perl version" >&5
5090$as_echo_n "checking Perl version... " >&6; }
5091    if $vi_cv_path_perl -e 'require 5.003_01' >/dev/null 2>/dev/null; then
5092     eval `$vi_cv_path_perl -V:usethreads`
5093     eval `$vi_cv_path_perl -V:libperl`
5094     if test "X$usethreads" = "XUNKNOWN" -o "X$usethreads" = "Xundef"; then
5095       badthreads=no
5096     else
5097       if $vi_cv_path_perl -e 'require 5.6.0' >/dev/null 2>/dev/null; then
5098	 eval `$vi_cv_path_perl -V:use5005threads`
5099	 if test "X$use5005threads" = "XUNKNOWN" -o "X$use5005threads" = "Xundef"; then
5100	   badthreads=no
5101	 else
5102	   badthreads=yes
5103	   { $as_echo "$as_me:${as_lineno-$LINENO}: result: >>> Perl > 5.6 with 5.5 threads cannot be used <<<" >&5
5104$as_echo ">>> Perl > 5.6 with 5.5 threads cannot be used <<<" >&6; }
5105	 fi
5106       else
5107	 badthreads=yes
5108	 { $as_echo "$as_me:${as_lineno-$LINENO}: result: >>> Perl 5.5 with threads cannot be used <<<" >&5
5109$as_echo ">>> Perl 5.5 with threads cannot be used <<<" >&6; }
5110       fi
5111     fi
5112     if test $badthreads = no; then
5113      { $as_echo "$as_me:${as_lineno-$LINENO}: result: OK" >&5
5114$as_echo "OK" >&6; }
5115      eval `$vi_cv_path_perl -V:shrpenv`
5116      if test "X$shrpenv" = "XUNKNOWN"; then # pre 5.003_04
5117	shrpenv=""
5118      fi
5119      vi_cv_perllib=`$vi_cv_path_perl -MConfig -e 'print $Config{privlibexp}'`
5120
5121            perlcppflags=`$vi_cv_path_perl -Mlib=$srcdir -MExtUtils::Embed \
5122	      -e 'ccflags;perl_inc;print"\n"' | sed -e 's/-fno[^ ]*//'`
5123            perllibs=`cd $srcdir; $vi_cv_path_perl -MExtUtils::Embed -e 'ldopts' | \
5124		sed -e '/Warning/d' -e '/Note (probably harmless)/d' \
5125			-e 's/-bE:perl.exp//' -e 's/-lc //'`
5126                  perlldflags=`cd $srcdir; $vi_cv_path_perl -MExtUtils::Embed \
5127		-e 'ccdlflags' | sed -e 's/-bE:perl.exp//'`
5128
5129                  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compile and link flags for Perl are sane" >&5
5130$as_echo_n "checking if compile and link flags for Perl are sane... " >&6; }
5131      cflags_save=$CFLAGS
5132      libs_save=$LIBS
5133      ldflags_save=$LDFLAGS
5134      CFLAGS="$CFLAGS $perlcppflags"
5135      LIBS="$LIBS $perllibs"
5136      LDFLAGS="$perlldflags $LDFLAGS"
5137      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5138/* end confdefs.h.  */
5139
5140int
5141main ()
5142{
5143
5144  ;
5145  return 0;
5146}
5147_ACEOF
5148if ac_fn_c_try_link "$LINENO"; then :
5149  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5150$as_echo "yes" >&6; }; perl_ok=yes
5151else
5152  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no: PERL DISABLED" >&5
5153$as_echo "no: PERL DISABLED" >&6; }; perl_ok=no
5154fi
5155rm -f core conftest.err conftest.$ac_objext \
5156    conftest$ac_exeext conftest.$ac_ext
5157      CFLAGS=$cflags_save
5158      LIBS=$libs_save
5159      LDFLAGS=$ldflags_save
5160      if test $perl_ok = yes; then
5161	if test "X$perlcppflags" != "X"; then
5162	  	  PERL_CFLAGS=`echo "$perlcppflags" | sed -e 's/-pipe //' -e 's/-W[^ ]*//'`
5163	fi
5164	if test "X$perlldflags" != "X"; then
5165	  LDFLAGS="$perlldflags $LDFLAGS"
5166	fi
5167	PERL_LIBS=$perllibs
5168	PERL_SRC="auto/if_perl.c if_perlsfio.c"
5169	PERL_OBJ="objects/if_perl.o objects/if_perlsfio.o"
5170	PERL_PRO="if_perl.pro if_perlsfio.pro"
5171	$as_echo "#define FEAT_PERL 1" >>confdefs.h
5172
5173      fi
5174     fi
5175    else
5176      { $as_echo "$as_me:${as_lineno-$LINENO}: result: >>> too old; need Perl version 5.003_01 or later <<<" >&5
5177$as_echo ">>> too old; need Perl version 5.003_01 or later <<<" >&6; }
5178    fi
5179  fi
5180
5181  if test "x$MACOSX" = "xyes"; then
5182        dir=/System/Library/Perl
5183    darwindir=$dir/darwin
5184    if test -d $darwindir; then
5185      PERL=/usr/bin/perl
5186    else
5187            dir=/System/Library/Perl/5.8.1
5188      darwindir=$dir/darwin-thread-multi-2level
5189      if test -d $darwindir; then
5190	PERL=/usr/bin/perl
5191      fi
5192    fi
5193    if test -n "$PERL"; then
5194      PERL_DIR="$dir"
5195      PERL_CFLAGS="-DFEAT_PERL -I$darwindir/CORE"
5196      PERL_OBJ="objects/if_perl.o objects/if_perlsfio.o $darwindir/auto/DynaLoader/DynaLoader.a"
5197      PERL_LIBS="-L$darwindir/CORE -lperl"
5198    fi
5199                PERL_LIBS=`echo "$PERL_LIBS" | sed -e 's/-arch\ ppc//' -e 's/-arch\ i386//' -e 's/-arch\ x86_64//'`
5200    PERL_CFLAGS=`echo "$PERL_CFLAGS" | sed -e 's/-arch\ ppc//' -e 's/-arch\ i386//' -e 's/-arch\ x86_64//'`
5201  fi
5202  if test "$enable_perlinterp" = "dynamic"; then
5203    if test "$perl_ok" = "yes" -a "X$libperl" != "X"; then
5204      $as_echo "#define DYNAMIC_PERL 1" >>confdefs.h
5205
5206      PERL_CFLAGS="-DDYNAMIC_PERL_DLL=\\\"$libperl\\\" $PERL_CFLAGS"
5207    fi
5208  fi
5209
5210  if test "$fail_if_missing" = "yes" -a "$perl_ok" != "yes"; then
5211    as_fn_error "could not configure perl" "$LINENO" 5
5212  fi
5213fi
5214
5215
5216
5217
5218
5219
5220
5221{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-pythoninterp argument" >&5
5222$as_echo_n "checking --enable-pythoninterp argument... " >&6; }
5223# Check whether --enable-pythoninterp was given.
5224if test "${enable_pythoninterp+set}" = set; then :
5225  enableval=$enable_pythoninterp;
5226else
5227  enable_pythoninterp="no"
5228fi
5229
5230{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_pythoninterp" >&5
5231$as_echo "$enable_pythoninterp" >&6; }
5232if test "$enable_pythoninterp" = "yes" -o "$enable_pythoninterp" = "dynamic"; then
5233    for ac_prog in python2 python
5234do
5235  # Extract the first word of "$ac_prog", so it can be a program name with args.
5236set dummy $ac_prog; ac_word=$2
5237{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5238$as_echo_n "checking for $ac_word... " >&6; }
5239if test "${ac_cv_path_vi_cv_path_python+set}" = set; then :
5240  $as_echo_n "(cached) " >&6
5241else
5242  case $vi_cv_path_python in
5243  [\\/]* | ?:[\\/]*)
5244  ac_cv_path_vi_cv_path_python="$vi_cv_path_python" # Let the user override the test with a path.
5245  ;;
5246  *)
5247  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5248for as_dir in $PATH
5249do
5250  IFS=$as_save_IFS
5251  test -z "$as_dir" && as_dir=.
5252    for ac_exec_ext in '' $ac_executable_extensions; do
5253  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5254    ac_cv_path_vi_cv_path_python="$as_dir/$ac_word$ac_exec_ext"
5255    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5256    break 2
5257  fi
5258done
5259  done
5260IFS=$as_save_IFS
5261
5262  ;;
5263esac
5264fi
5265vi_cv_path_python=$ac_cv_path_vi_cv_path_python
5266if test -n "$vi_cv_path_python"; then
5267  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python" >&5
5268$as_echo "$vi_cv_path_python" >&6; }
5269else
5270  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5271$as_echo "no" >&6; }
5272fi
5273
5274
5275  test -n "$vi_cv_path_python" && break
5276done
5277
5278  if test "X$vi_cv_path_python" != "X"; then
5279
5280        { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python version" >&5
5281$as_echo_n "checking Python version... " >&6; }
5282if test "${vi_cv_var_python_version+set}" = set; then :
5283  $as_echo_n "(cached) " >&6
5284else
5285  vi_cv_var_python_version=`
5286	    ${vi_cv_path_python} -c 'import sys; print sys.version[:3]'`
5287
5288fi
5289{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python_version" >&5
5290$as_echo "$vi_cv_var_python_version" >&6; }
5291
5292        { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python is 2.3 or better" >&5
5293$as_echo_n "checking Python is 2.3 or better... " >&6; }
5294    if ${vi_cv_path_python} -c \
5295	"import sys; sys.exit(${vi_cv_var_python_version} < 2.3)"
5296    then
5297      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yep" >&5
5298$as_echo "yep" >&6; }
5299
5300            { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's install prefix" >&5
5301$as_echo_n "checking Python's install prefix... " >&6; }
5302if test "${vi_cv_path_python_pfx+set}" = set; then :
5303  $as_echo_n "(cached) " >&6
5304else
5305   vi_cv_path_python_pfx=`
5306	    ${vi_cv_path_python} -c \
5307		"import sys; print sys.prefix"`
5308fi
5309{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python_pfx" >&5
5310$as_echo "$vi_cv_path_python_pfx" >&6; }
5311
5312            { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's execution prefix" >&5
5313$as_echo_n "checking Python's execution prefix... " >&6; }
5314if test "${vi_cv_path_python_epfx+set}" = set; then :
5315  $as_echo_n "(cached) " >&6
5316else
5317   vi_cv_path_python_epfx=`
5318	    ${vi_cv_path_python} -c \
5319		"import sys; print sys.exec_prefix"`
5320fi
5321{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python_epfx" >&5
5322$as_echo "$vi_cv_path_python_epfx" >&6; }
5323
5324
5325      if test "${vi_cv_path_pythonpath+set}" = set; then :
5326  $as_echo_n "(cached) " >&6
5327else
5328   vi_cv_path_pythonpath=`
5329	    unset PYTHONPATH;
5330	    ${vi_cv_path_python} -c \
5331		"import sys, string; print string.join(sys.path,':')"`
5332fi
5333
5334
5335
5336
5337# Check whether --with-python-config-dir was given.
5338if test "${with_python_config_dir+set}" = set; then :
5339  withval=$with_python_config_dir;  vi_cv_path_python_conf="${withval}"
5340fi
5341
5342
5343      { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's configuration directory" >&5
5344$as_echo_n "checking Python's configuration directory... " >&6; }
5345if test "${vi_cv_path_python_conf+set}" = set; then :
5346  $as_echo_n "(cached) " >&6
5347else
5348
5349	vi_cv_path_python_conf=
5350	d=`${vi_cv_path_python} -c "import distutils.sysconfig; print distutils.sysconfig.get_config_var('LIBPL')"`
5351	if test -d "$d" && test -f "$d/config.c"; then
5352	  vi_cv_path_python_conf="$d"
5353	else
5354	  for path in "${vi_cv_path_python_pfx}" "${vi_cv_path_python_epfx}"; do
5355	    for subdir in lib64 lib share; do
5356	      d="${path}/${subdir}/python${vi_cv_var_python_version}/config"
5357	      if test -d "$d" && test -f "$d/config.c"; then
5358		vi_cv_path_python_conf="$d"
5359	      fi
5360	    done
5361	  done
5362	fi
5363
5364fi
5365{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python_conf" >&5
5366$as_echo "$vi_cv_path_python_conf" >&6; }
5367
5368      PYTHON_CONFDIR="${vi_cv_path_python_conf}"
5369
5370      if test "X$PYTHON_CONFDIR" = "X"; then
5371	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: can't find it!" >&5
5372$as_echo "can't find it!" >&6; }
5373      else
5374
5375			if test "${vi_cv_path_python_plibs+set}" = set; then :
5376  $as_echo_n "(cached) " >&6
5377else
5378
5379	    pwd=`pwd`
5380	    tmp_mkf="$pwd/config-PyMake$$"
5381	    cat -- "${PYTHON_CONFDIR}/Makefile" - <<'eof' >"${tmp_mkf}"
5382__:
5383	@echo "python_BASEMODLIBS='$(BASEMODLIBS)'"
5384	@echo "python_LIBS='$(LIBS)'"
5385	@echo "python_SYSLIBS='$(SYSLIBS)'"
5386	@echo "python_LINKFORSHARED='$(LINKFORSHARED)'"
5387	@echo "python_DLLLIBRARY='$(DLLLIBRARY)'"
5388	@echo "python_INSTSONAME='$(INSTSONAME)'"
5389eof
5390	    	    eval "`cd ${PYTHON_CONFDIR} && make -f "${tmp_mkf}" __ | sed '/ directory /d'`"
5391	    rm -f -- "${tmp_mkf}"
5392	    if test "x$MACOSX" = "xyes" && ${vi_cv_path_python} -c \
5393		"import sys; sys.exit(${vi_cv_var_python_version} < 2.3)"; then
5394	      vi_cv_path_python_plibs="-framework Python"
5395	    else
5396	      if test "${vi_cv_var_python_version}" = "1.4"; then
5397		  vi_cv_path_python_plibs="${PYTHON_CONFDIR}/libModules.a ${PYTHON_CONFDIR}/libPython.a ${PYTHON_CONFDIR}/libObjects.a ${PYTHON_CONFDIR}/libParser.a"
5398	      else
5399		  vi_cv_path_python_plibs="-L${PYTHON_CONFDIR} -lpython${vi_cv_var_python_version}"
5400	      fi
5401	      vi_cv_path_python_plibs="${vi_cv_path_python_plibs} ${python_BASEMODLIBS} ${python_LIBS} ${python_SYSLIBS} ${python_LINKFORSHARED}"
5402	      	      vi_cv_path_python_plibs=`echo $vi_cv_path_python_plibs | sed s/-ltermcap//`
5403	    fi
5404
5405fi
5406
5407
5408	if test "X$python_DLLLIBRARY" != "X"; then
5409	  python_INSTSONAME="$python_DLLLIBRARY"
5410	fi
5411	PYTHON_LIBS="${vi_cv_path_python_plibs}"
5412	if test "${vi_cv_path_python_pfx}" = "${vi_cv_path_python_epfx}"; then
5413	  PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME='\"${vi_cv_path_python_pfx}\"'"
5414	else
5415	  PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME='\"${vi_cv_path_python_pfx}\"'"
5416	fi
5417	PYTHON_SRC="if_python.c"
5418	PYTHON_OBJ="objects/if_python.o"
5419	if test "${vi_cv_var_python_version}" = "1.4"; then
5420	   PYTHON_OBJ="$PYTHON_OBJ objects/py_getpath.o"
5421	fi
5422    PYTHON_GETPATH_CFLAGS="-DPYTHONPATH='\"${vi_cv_path_pythonpath}\"' -DPREFIX='\"${vi_cv_path_python_pfx}\"' -DEXEC_PREFIX='\"${vi_cv_path_python_epfx}\"'"
5423
5424								{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread should be used" >&5
5425$as_echo_n "checking if -pthread should be used... " >&6; }
5426	threadsafe_flag=
5427	thread_lib=
5428	        if test "`(uname) 2>/dev/null`" != Darwin; then
5429	  test "$GCC" = yes && threadsafe_flag="-pthread"
5430	  if test "`(uname) 2>/dev/null`" = FreeBSD; then
5431	    threadsafe_flag="-D_THREAD_SAFE"
5432	    thread_lib="-pthread"
5433	  fi
5434	  if test "`(uname) 2>/dev/null`" = SunOS; then
5435	    threadsafe_flag="-pthreads"
5436	  fi
5437	fi
5438	libs_save_old=$LIBS
5439	if test -n "$threadsafe_flag"; then
5440	  cflags_save=$CFLAGS
5441	  CFLAGS="$CFLAGS $threadsafe_flag"
5442	  LIBS="$LIBS $thread_lib"
5443	  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5444/* end confdefs.h.  */
5445
5446int
5447main ()
5448{
5449
5450  ;
5451  return 0;
5452}
5453_ACEOF
5454if ac_fn_c_try_link "$LINENO"; then :
5455  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5456$as_echo "yes" >&6; }; PYTHON_CFLAGS="$PYTHON_CFLAGS $threadsafe_flag"
5457else
5458  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5459$as_echo "no" >&6; }; LIBS=$libs_save_old
5460
5461fi
5462rm -f core conftest.err conftest.$ac_objext \
5463    conftest$ac_exeext conftest.$ac_ext
5464	  CFLAGS=$cflags_save
5465	else
5466	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5467$as_echo "no" >&6; }
5468	fi
5469
5470			{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if compile and link flags for Python are sane" >&5
5471$as_echo_n "checking if compile and link flags for Python are sane... " >&6; }
5472	cflags_save=$CFLAGS
5473	libs_save=$LIBS
5474	CFLAGS="$CFLAGS $PYTHON_CFLAGS"
5475	LIBS="$LIBS $PYTHON_LIBS"
5476	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5477/* end confdefs.h.  */
5478
5479int
5480main ()
5481{
5482
5483  ;
5484  return 0;
5485}
5486_ACEOF
5487if ac_fn_c_try_link "$LINENO"; then :
5488  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5489$as_echo "yes" >&6; }; python_ok=yes
5490else
5491  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no: PYTHON DISABLED" >&5
5492$as_echo "no: PYTHON DISABLED" >&6; }; python_ok=no
5493fi
5494rm -f core conftest.err conftest.$ac_objext \
5495    conftest$ac_exeext conftest.$ac_ext
5496	CFLAGS=$cflags_save
5497	LIBS=$libs_save
5498	if test $python_ok = yes; then
5499	  $as_echo "#define FEAT_PYTHON 1" >>confdefs.h
5500
5501	else
5502	  LIBS=$libs_save_old
5503	  PYTHON_SRC=
5504	  PYTHON_OBJ=
5505	  PYTHON_LIBS=
5506	  PYTHON_CFLAGS=
5507	fi
5508      fi
5509    else
5510      { $as_echo "$as_me:${as_lineno-$LINENO}: result: too old" >&5
5511$as_echo "too old" >&6; }
5512    fi
5513  fi
5514
5515  if test "$fail_if_missing" = "yes" -a "$python_ok" != "yes"; then
5516    as_fn_error "could not configure python" "$LINENO" 5
5517  fi
5518fi
5519
5520
5521
5522
5523
5524
5525
5526
5527
5528{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-python3interp argument" >&5
5529$as_echo_n "checking --enable-python3interp argument... " >&6; }
5530# Check whether --enable-python3interp was given.
5531if test "${enable_python3interp+set}" = set; then :
5532  enableval=$enable_python3interp;
5533else
5534  enable_python3interp="no"
5535fi
5536
5537{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_python3interp" >&5
5538$as_echo "$enable_python3interp" >&6; }
5539if test "$enable_python3interp" = "yes" -o "$enable_python3interp" = "dynamic"; then
5540    for ac_prog in python3 python
5541do
5542  # Extract the first word of "$ac_prog", so it can be a program name with args.
5543set dummy $ac_prog; ac_word=$2
5544{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5545$as_echo_n "checking for $ac_word... " >&6; }
5546if test "${ac_cv_path_vi_cv_path_python3+set}" = set; then :
5547  $as_echo_n "(cached) " >&6
5548else
5549  case $vi_cv_path_python3 in
5550  [\\/]* | ?:[\\/]*)
5551  ac_cv_path_vi_cv_path_python3="$vi_cv_path_python3" # Let the user override the test with a path.
5552  ;;
5553  *)
5554  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5555for as_dir in $PATH
5556do
5557  IFS=$as_save_IFS
5558  test -z "$as_dir" && as_dir=.
5559    for ac_exec_ext in '' $ac_executable_extensions; do
5560  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5561    ac_cv_path_vi_cv_path_python3="$as_dir/$ac_word$ac_exec_ext"
5562    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5563    break 2
5564  fi
5565done
5566  done
5567IFS=$as_save_IFS
5568
5569  ;;
5570esac
5571fi
5572vi_cv_path_python3=$ac_cv_path_vi_cv_path_python3
5573if test -n "$vi_cv_path_python3"; then
5574  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3" >&5
5575$as_echo "$vi_cv_path_python3" >&6; }
5576else
5577  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5578$as_echo "no" >&6; }
5579fi
5580
5581
5582  test -n "$vi_cv_path_python3" && break
5583done
5584
5585  if test "X$vi_cv_path_python3" != "X"; then
5586
5587        { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python version" >&5
5588$as_echo_n "checking Python version... " >&6; }
5589if test "${vi_cv_var_python3_version+set}" = set; then :
5590  $as_echo_n "(cached) " >&6
5591else
5592  vi_cv_var_python3_version=`
5593          ${vi_cv_path_python3} -c 'import sys; print(sys.version[:3])'`
5594
5595fi
5596{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python3_version" >&5
5597$as_echo "$vi_cv_var_python3_version" >&6; }
5598
5599        { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python is 3.0 or better" >&5
5600$as_echo_n "checking Python is 3.0 or better... " >&6; }
5601    if ${vi_cv_path_python3} -c \
5602      "import sys; sys.exit(${vi_cv_var_python3_version} < 3.0)"
5603    then
5604      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yep" >&5
5605$as_echo "yep" >&6; }
5606
5607            { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's abiflags" >&5
5608$as_echo_n "checking Python's abiflags... " >&6; }
5609if test "${vi_cv_var_python3_abiflags+set}" = set; then :
5610  $as_echo_n "(cached) " >&6
5611else
5612
5613       vi_cv_var_python3_abiflags=
5614       if ${vi_cv_path_python3} -c \
5615           "import sys; sys.exit(${vi_cv_var_python3_version} < 3.2)"
5616       then
5617         vi_cv_var_python3_abiflags=`${vi_cv_path_python3} -c \
5618           "import sys; print(sys.abiflags)"`
5619       fi
5620fi
5621{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_var_python3_abiflags" >&5
5622$as_echo "$vi_cv_var_python3_abiflags" >&6; }
5623
5624            { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's install prefix" >&5
5625$as_echo_n "checking Python's install prefix... " >&6; }
5626if test "${vi_cv_path_python3_pfx+set}" = set; then :
5627  $as_echo_n "(cached) " >&6
5628else
5629   vi_cv_path_python3_pfx=`
5630       ${vi_cv_path_python3} -c \
5631       "import sys; print(sys.prefix)"`
5632fi
5633{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_pfx" >&5
5634$as_echo "$vi_cv_path_python3_pfx" >&6; }
5635
5636            { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's execution prefix" >&5
5637$as_echo_n "checking Python's execution prefix... " >&6; }
5638if test "${vi_cv_path_python3_epfx+set}" = set; then :
5639  $as_echo_n "(cached) " >&6
5640else
5641   vi_cv_path_python3_epfx=`
5642       ${vi_cv_path_python3} -c \
5643       "import sys; print(sys.exec_prefix)"`
5644fi
5645{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_epfx" >&5
5646$as_echo "$vi_cv_path_python3_epfx" >&6; }
5647
5648
5649      if test "${vi_cv_path_python3path+set}" = set; then :
5650  $as_echo_n "(cached) " >&6
5651else
5652   vi_cv_path_python3path=`
5653       unset PYTHONPATH;
5654       ${vi_cv_path_python3} -c \
5655       "import sys, string; print(':'.join(sys.path))"`
5656fi
5657
5658
5659
5660
5661# Check whether --with-python3-config-dir was given.
5662if test "${with_python3_config_dir+set}" = set; then :
5663  withval=$with_python3_config_dir;  vi_cv_path_python3_conf="${withval}"
5664fi
5665
5666
5667      { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python's configuration directory" >&5
5668$as_echo_n "checking Python's configuration directory... " >&6; }
5669if test "${vi_cv_path_python3_conf+set}" = set; then :
5670  $as_echo_n "(cached) " >&6
5671else
5672
5673       vi_cv_path_python3_conf=
5674       config_dir="config"
5675       if test "${vi_cv_var_python3_abiflags}" != ""; then
5676         config_dir="${config_dir}-${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}"
5677       fi
5678       d=`${vi_cv_path_python3} -c "import distutils.sysconfig; print(distutils.sysconfig.get_config_var('LIBPL'))"`
5679       if test -d "$d" && test -f "$d/config.c"; then
5680         vi_cv_path_python3_conf="$d"
5681       else
5682         for path in "${vi_cv_path_python3_pfx}" "${vi_cv_path_python3_epfx}"; do
5683	   for subdir in lib64 lib share; do
5684	     d="${path}/${subdir}/python${vi_cv_var_python3_version}/${config_dir}"
5685	     if test -d "$d" && test -f "$d/config.c"; then
5686	       vi_cv_path_python3_conf="$d"
5687	     fi
5688	   done
5689         done
5690       fi
5691
5692fi
5693{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_python3_conf" >&5
5694$as_echo "$vi_cv_path_python3_conf" >&6; }
5695
5696      PYTHON3_CONFDIR="${vi_cv_path_python3_conf}"
5697
5698      if test "X$PYTHON3_CONFDIR" = "X"; then
5699        { $as_echo "$as_me:${as_lineno-$LINENO}: result: can't find it!" >&5
5700$as_echo "can't find it!" >&6; }
5701      else
5702
5703                        if test "${vi_cv_path_python3_plibs+set}" = set; then :
5704  $as_echo_n "(cached) " >&6
5705else
5706
5707            pwd=`pwd`
5708            tmp_mkf="$pwd/config-PyMake$$"
5709            cat -- "${PYTHON3_CONFDIR}/Makefile" - <<'eof' >"${tmp_mkf}"
5710__:
5711	@echo "python3_BASEMODLIBS='$(BASEMODLIBS)'"
5712	@echo "python3_LIBS='$(LIBS)'"
5713	@echo "python3_SYSLIBS='$(SYSLIBS)'"
5714	@echo "python3_DLLLIBRARY='$(DLLLIBRARY)'"
5715	@echo "python3_INSTSONAME='$(INSTSONAME)'"
5716eof
5717                        eval "`cd ${PYTHON3_CONFDIR} && make -f "${tmp_mkf}" __ | sed '/ directory /d'`"
5718            rm -f -- "${tmp_mkf}"
5719	    vi_cv_path_python3_plibs="-L${PYTHON3_CONFDIR} -lpython${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}"
5720            vi_cv_path_python3_plibs="${vi_cv_path_python3_plibs} ${python3_BASEMODLIBS} ${python3_LIBS} ${python3_SYSLIBS}"
5721                        vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-ltermcap//`
5722            vi_cv_path_python3_plibs=`echo $vi_cv_path_python3_plibs | sed s/-lffi//`
5723
5724fi
5725
5726
5727        if test "X$python3_DLLLIBRARY" != "X"; then
5728	  python3_INSTSONAME="$python3_DLLLIBRARY"
5729        fi
5730        PYTHON3_LIBS="${vi_cv_path_python3_plibs}"
5731        if test "${vi_cv_path_python3_pfx}" = "${vi_cv_path_python3_epfx}"; then
5732          PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME='L\"${vi_cv_path_python3_pfx}\"'"
5733        else
5734          PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags} -DPYTHON3_HOME='L\"${vi_cv_path_python3_pfx}\"'"
5735        fi
5736        PYTHON3_SRC="if_python3.c"
5737        PYTHON3_OBJ="objects/if_python3.o"
5738
5739                                                                { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread should be used" >&5
5740$as_echo_n "checking if -pthread should be used... " >&6; }
5741        threadsafe_flag=
5742        thread_lib=
5743                if test "`(uname) 2>/dev/null`" != Darwin; then
5744          test "$GCC" = yes && threadsafe_flag="-pthread"
5745          if test "`(uname) 2>/dev/null`" = FreeBSD; then
5746            threadsafe_flag="-D_THREAD_SAFE"
5747            thread_lib="-pthread"
5748          fi
5749          if test "`(uname) 2>/dev/null`" = SunOS; then
5750            threadsafe_flag="-pthreads"
5751          fi
5752        fi
5753        libs_save_old=$LIBS
5754        if test -n "$threadsafe_flag"; then
5755          cflags_save=$CFLAGS
5756          CFLAGS="$CFLAGS $threadsafe_flag"
5757          LIBS="$LIBS $thread_lib"
5758          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5759/* end confdefs.h.  */
5760
5761int
5762main ()
5763{
5764
5765  ;
5766  return 0;
5767}
5768_ACEOF
5769if ac_fn_c_try_link "$LINENO"; then :
5770  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5771$as_echo "yes" >&6; }; PYTHON3_CFLAGS="$PYTHON3_CFLAGS $threadsafe_flag"
5772else
5773  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5774$as_echo "no" >&6; }; LIBS=$libs_save_old
5775
5776fi
5777rm -f core conftest.err conftest.$ac_objext \
5778    conftest$ac_exeext conftest.$ac_ext
5779          CFLAGS=$cflags_save
5780        else
5781          { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5782$as_echo "no" >&6; }
5783        fi
5784
5785                        { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compile and link flags for Python 3 are sane" >&5
5786$as_echo_n "checking if compile and link flags for Python 3 are sane... " >&6; }
5787        cflags_save=$CFLAGS
5788        libs_save=$LIBS
5789        CFLAGS="$CFLAGS $PYTHON3_CFLAGS"
5790        LIBS="$LIBS $PYTHON3_LIBS"
5791        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5792/* end confdefs.h.  */
5793
5794int
5795main ()
5796{
5797
5798  ;
5799  return 0;
5800}
5801_ACEOF
5802if ac_fn_c_try_link "$LINENO"; then :
5803  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5804$as_echo "yes" >&6; }; python3_ok=yes
5805else
5806  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no: PYTHON3 DISABLED" >&5
5807$as_echo "no: PYTHON3 DISABLED" >&6; }; python3_ok=no
5808fi
5809rm -f core conftest.err conftest.$ac_objext \
5810    conftest$ac_exeext conftest.$ac_ext
5811        CFLAGS=$cflags_save
5812        LIBS=$libs_save
5813        if test "$python3_ok" = yes; then
5814          $as_echo "#define FEAT_PYTHON3 1" >>confdefs.h
5815
5816        else
5817          LIBS=$libs_save_old
5818          PYTHON3_SRC=
5819          PYTHON3_OBJ=
5820          PYTHON3_LIBS=
5821          PYTHON3_CFLAGS=
5822        fi
5823      fi
5824    else
5825      { $as_echo "$as_me:${as_lineno-$LINENO}: result: too old" >&5
5826$as_echo "too old" >&6; }
5827    fi
5828  fi
5829fi
5830
5831
5832
5833
5834
5835
5836
5837if test "$python_ok" = yes && test "$python3_ok" = yes; then
5838  $as_echo "#define DYNAMIC_PYTHON 1" >>confdefs.h
5839
5840  $as_echo "#define DYNAMIC_PYTHON3 1" >>confdefs.h
5841
5842  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can do without RTLD_GLOBAL for Python" >&5
5843$as_echo_n "checking whether we can do without RTLD_GLOBAL for Python... " >&6; }
5844  cflags_save=$CFLAGS
5845  CFLAGS="$CFLAGS $PYTHON_CFLAGS"
5846  ldflags_save=$LDFLAGS
5847    LDFLAGS="-ldl $LDFLAGS"
5848  if test "$cross_compiling" = yes; then :
5849  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5850$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5851as_fn_error "cannot run test program while cross compiling
5852See \`config.log' for more details." "$LINENO" 5; }
5853else
5854  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5855/* end confdefs.h.  */
5856
5857    #include <dlfcn.h>
5858    /* If this program fails, then RTLD_GLOBAL is needed.
5859     * RTLD_GLOBAL will be used and then it is not possible to
5860     * have both python versions enabled in the same vim instance.
5861     * Only the first python version used will be switched on.
5862     */
5863
5864    int no_rtl_global_needed_for(char *python_instsoname, char *prefix)
5865    {
5866      int needed = 0;
5867      void* pylib = dlopen(python_instsoname, RTLD_LAZY);
5868      if (pylib != 0)
5869      {
5870          void (*pfx)(char *home) = dlsym(pylib, "Py_SetPythonHome");
5871          void (*init)(void) = dlsym(pylib, "Py_Initialize");
5872          int (*simple)(char*) = dlsym(pylib, "PyRun_SimpleString");
5873          void (*final)(void) = dlsym(pylib, "Py_Finalize");
5874          (*pfx)(prefix);
5875          (*init)();
5876          needed = (*simple)("import termios") == -1;
5877          (*final)();
5878          dlclose(pylib);
5879      }
5880      return !needed;
5881    }
5882
5883    int main(int argc, char** argv)
5884    {
5885      int not_needed = 0;
5886      if (no_rtl_global_needed_for("${python_INSTSONAME}", "${vi_cv_path_python_pfx}"))
5887            not_needed = 1;
5888      return !not_needed;
5889    }
5890_ACEOF
5891if ac_fn_c_try_run "$LINENO"; then :
5892  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5893$as_echo "yes" >&6; };$as_echo "#define PY_NO_RTLD_GLOBAL 1" >>confdefs.h
5894
5895else
5896  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5897$as_echo "no" >&6; }
5898fi
5899rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5900  conftest.$ac_objext conftest.beam conftest.$ac_ext
5901fi
5902
5903
5904  CFLAGS=$cflags_save
5905  LDFLAGS=$ldflags_save
5906
5907  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can do without RTLD_GLOBAL for Python3" >&5
5908$as_echo_n "checking whether we can do without RTLD_GLOBAL for Python3... " >&6; }
5909  cflags_save=$CFLAGS
5910  CFLAGS="$CFLAGS $PYTHON3_CFLAGS"
5911  ldflags_save=$LDFLAGS
5912    LDFLAGS="-ldl $LDFLAGS"
5913  if test "$cross_compiling" = yes; then :
5914  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5915$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5916as_fn_error "cannot run test program while cross compiling
5917See \`config.log' for more details." "$LINENO" 5; }
5918else
5919  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5920/* end confdefs.h.  */
5921
5922    #include <dlfcn.h>
5923    #include <wchar.h>
5924    /* If this program fails, then RTLD_GLOBAL is needed.
5925     * RTLD_GLOBAL will be used and then it is not possible to
5926     * have both python versions enabled in the same vim instance.
5927     * Only the first python version used will be switched on.
5928     */
5929
5930    int no_rtl_global_needed_for(char *python_instsoname, wchar_t *prefix)
5931    {
5932      int needed = 0;
5933      void* pylib = dlopen(python_instsoname, RTLD_LAZY);
5934      if (pylib != 0)
5935      {
5936          void (*pfx)(wchar_t *home) = dlsym(pylib, "Py_SetPythonHome");
5937          void (*init)(void) = dlsym(pylib, "Py_Initialize");
5938          int (*simple)(char*) = dlsym(pylib, "PyRun_SimpleString");
5939          void (*final)(void) = dlsym(pylib, "Py_Finalize");
5940          (*pfx)(prefix);
5941          (*init)();
5942          needed = (*simple)("import termios") == -1;
5943          (*final)();
5944          dlclose(pylib);
5945      }
5946      return !needed;
5947    }
5948
5949    int main(int argc, char** argv)
5950    {
5951      int not_needed = 0;
5952      if (no_rtl_global_needed_for("${python3_INSTSONAME}", L"${vi_cv_path_python3_pfx}"))
5953            not_needed = 1;
5954      return !not_needed;
5955    }
5956_ACEOF
5957if ac_fn_c_try_run "$LINENO"; then :
5958  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5959$as_echo "yes" >&6; };$as_echo "#define PY3_NO_RTLD_GLOBAL 1" >>confdefs.h
5960
5961else
5962  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5963$as_echo "no" >&6; }
5964fi
5965rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5966  conftest.$ac_objext conftest.beam conftest.$ac_ext
5967fi
5968
5969
5970  CFLAGS=$cflags_save
5971  LDFLAGS=$ldflags_save
5972
5973  PYTHON_SRC="if_python.c"
5974  PYTHON_OBJ="objects/if_python.o"
5975  PYTHON_CFLAGS="$PYTHON_CFLAGS -DDYNAMIC_PYTHON_DLL=\\\"${python_INSTSONAME}\\\""
5976  PYTHON_LIBS=
5977  PYTHON3_SRC="if_python3.c"
5978  PYTHON3_OBJ="objects/if_python3.o"
5979  PYTHON3_CFLAGS="$PYTHON3_CFLAGS -DDYNAMIC_PYTHON3_DLL=\\\"${python3_INSTSONAME}\\\""
5980  PYTHON3_LIBS=
5981elif test "$python_ok" = yes && test "$enable_pythoninterp" = "dynamic"; then
5982  $as_echo "#define DYNAMIC_PYTHON 1" >>confdefs.h
5983
5984  PYTHON_SRC="if_python.c"
5985  PYTHON_OBJ="objects/if_python.o"
5986  PYTHON_CFLAGS="$PYTHON_CFLAGS -DDYNAMIC_PYTHON_DLL=\\\"${python_INSTSONAME}\\\""
5987  PYTHON_LIBS=
5988elif test "$python3_ok" = yes && test "$enable_python3interp" = "dynamic"; then
5989  $as_echo "#define DYNAMIC_PYTHON3 1" >>confdefs.h
5990
5991  PYTHON3_SRC="if_python3.c"
5992  PYTHON3_OBJ="objects/if_python3.o"
5993  PYTHON3_CFLAGS="$PYTHON3_CFLAGS -DDYNAMIC_PYTHON3_DLL=\\\"${python3_INSTSONAME}\\\""
5994  PYTHON3_LIBS=
5995fi
5996
5997{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-tclinterp argument" >&5
5998$as_echo_n "checking --enable-tclinterp argument... " >&6; }
5999# Check whether --enable-tclinterp was given.
6000if test "${enable_tclinterp+set}" = set; then :
6001  enableval=$enable_tclinterp;
6002else
6003  enable_tclinterp="no"
6004fi
6005
6006{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_tclinterp" >&5
6007$as_echo "$enable_tclinterp" >&6; }
6008
6009if test "$enable_tclinterp" = "yes"; then
6010
6011    { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-tclsh argument" >&5
6012$as_echo_n "checking --with-tclsh argument... " >&6; }
6013
6014# Check whether --with-tclsh was given.
6015if test "${with_tclsh+set}" = set; then :
6016  withval=$with_tclsh; tclsh_name="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tclsh_name" >&5
6017$as_echo "$tclsh_name" >&6; }
6018else
6019  tclsh_name="tclsh8.5"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6020$as_echo "no" >&6; }
6021fi
6022
6023  # Extract the first word of "$tclsh_name", so it can be a program name with args.
6024set dummy $tclsh_name; ac_word=$2
6025{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6026$as_echo_n "checking for $ac_word... " >&6; }
6027if test "${ac_cv_path_vi_cv_path_tcl+set}" = set; then :
6028  $as_echo_n "(cached) " >&6
6029else
6030  case $vi_cv_path_tcl in
6031  [\\/]* | ?:[\\/]*)
6032  ac_cv_path_vi_cv_path_tcl="$vi_cv_path_tcl" # Let the user override the test with a path.
6033  ;;
6034  *)
6035  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6036for as_dir in $PATH
6037do
6038  IFS=$as_save_IFS
6039  test -z "$as_dir" && as_dir=.
6040    for ac_exec_ext in '' $ac_executable_extensions; do
6041  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6042    ac_cv_path_vi_cv_path_tcl="$as_dir/$ac_word$ac_exec_ext"
6043    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6044    break 2
6045  fi
6046done
6047  done
6048IFS=$as_save_IFS
6049
6050  ;;
6051esac
6052fi
6053vi_cv_path_tcl=$ac_cv_path_vi_cv_path_tcl
6054if test -n "$vi_cv_path_tcl"; then
6055  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_tcl" >&5
6056$as_echo "$vi_cv_path_tcl" >&6; }
6057else
6058  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6059$as_echo "no" >&6; }
6060fi
6061
6062
6063
6064
6065    if test "X$vi_cv_path_tcl" = "X" -a $tclsh_name = "tclsh8.5"; then
6066    tclsh_name="tclsh8.4"
6067    # Extract the first word of "$tclsh_name", so it can be a program name with args.
6068set dummy $tclsh_name; ac_word=$2
6069{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6070$as_echo_n "checking for $ac_word... " >&6; }
6071if test "${ac_cv_path_vi_cv_path_tcl+set}" = set; then :
6072  $as_echo_n "(cached) " >&6
6073else
6074  case $vi_cv_path_tcl in
6075  [\\/]* | ?:[\\/]*)
6076  ac_cv_path_vi_cv_path_tcl="$vi_cv_path_tcl" # Let the user override the test with a path.
6077  ;;
6078  *)
6079  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6080for as_dir in $PATH
6081do
6082  IFS=$as_save_IFS
6083  test -z "$as_dir" && as_dir=.
6084    for ac_exec_ext in '' $ac_executable_extensions; do
6085  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6086    ac_cv_path_vi_cv_path_tcl="$as_dir/$ac_word$ac_exec_ext"
6087    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6088    break 2
6089  fi
6090done
6091  done
6092IFS=$as_save_IFS
6093
6094  ;;
6095esac
6096fi
6097vi_cv_path_tcl=$ac_cv_path_vi_cv_path_tcl
6098if test -n "$vi_cv_path_tcl"; then
6099  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_tcl" >&5
6100$as_echo "$vi_cv_path_tcl" >&6; }
6101else
6102  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6103$as_echo "no" >&6; }
6104fi
6105
6106
6107  fi
6108  if test "X$vi_cv_path_tcl" = "X" -a $tclsh_name = "tclsh8.4"; then
6109    tclsh_name="tclsh8.2"
6110    # Extract the first word of "$tclsh_name", so it can be a program name with args.
6111set dummy $tclsh_name; ac_word=$2
6112{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6113$as_echo_n "checking for $ac_word... " >&6; }
6114if test "${ac_cv_path_vi_cv_path_tcl+set}" = set; then :
6115  $as_echo_n "(cached) " >&6
6116else
6117  case $vi_cv_path_tcl in
6118  [\\/]* | ?:[\\/]*)
6119  ac_cv_path_vi_cv_path_tcl="$vi_cv_path_tcl" # Let the user override the test with a path.
6120  ;;
6121  *)
6122  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6123for as_dir in $PATH
6124do
6125  IFS=$as_save_IFS
6126  test -z "$as_dir" && as_dir=.
6127    for ac_exec_ext in '' $ac_executable_extensions; do
6128  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6129    ac_cv_path_vi_cv_path_tcl="$as_dir/$ac_word$ac_exec_ext"
6130    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6131    break 2
6132  fi
6133done
6134  done
6135IFS=$as_save_IFS
6136
6137  ;;
6138esac
6139fi
6140vi_cv_path_tcl=$ac_cv_path_vi_cv_path_tcl
6141if test -n "$vi_cv_path_tcl"; then
6142  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_tcl" >&5
6143$as_echo "$vi_cv_path_tcl" >&6; }
6144else
6145  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6146$as_echo "no" >&6; }
6147fi
6148
6149
6150  fi
6151  if test "X$vi_cv_path_tcl" = "X" -a $tclsh_name = "tclsh8.2"; then
6152    tclsh_name="tclsh8.0"
6153    # Extract the first word of "$tclsh_name", so it can be a program name with args.
6154set dummy $tclsh_name; ac_word=$2
6155{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6156$as_echo_n "checking for $ac_word... " >&6; }
6157if test "${ac_cv_path_vi_cv_path_tcl+set}" = set; then :
6158  $as_echo_n "(cached) " >&6
6159else
6160  case $vi_cv_path_tcl in
6161  [\\/]* | ?:[\\/]*)
6162  ac_cv_path_vi_cv_path_tcl="$vi_cv_path_tcl" # Let the user override the test with a path.
6163  ;;
6164  *)
6165  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6166for as_dir in $PATH
6167do
6168  IFS=$as_save_IFS
6169  test -z "$as_dir" && as_dir=.
6170    for ac_exec_ext in '' $ac_executable_extensions; do
6171  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6172    ac_cv_path_vi_cv_path_tcl="$as_dir/$ac_word$ac_exec_ext"
6173    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6174    break 2
6175  fi
6176done
6177  done
6178IFS=$as_save_IFS
6179
6180  ;;
6181esac
6182fi
6183vi_cv_path_tcl=$ac_cv_path_vi_cv_path_tcl
6184if test -n "$vi_cv_path_tcl"; then
6185  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_tcl" >&5
6186$as_echo "$vi_cv_path_tcl" >&6; }
6187else
6188  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6189$as_echo "no" >&6; }
6190fi
6191
6192
6193  fi
6194    if test "X$vi_cv_path_tcl" = "X"; then
6195    tclsh_name="tclsh"
6196    # Extract the first word of "$tclsh_name", so it can be a program name with args.
6197set dummy $tclsh_name; ac_word=$2
6198{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6199$as_echo_n "checking for $ac_word... " >&6; }
6200if test "${ac_cv_path_vi_cv_path_tcl+set}" = set; then :
6201  $as_echo_n "(cached) " >&6
6202else
6203  case $vi_cv_path_tcl in
6204  [\\/]* | ?:[\\/]*)
6205  ac_cv_path_vi_cv_path_tcl="$vi_cv_path_tcl" # Let the user override the test with a path.
6206  ;;
6207  *)
6208  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6209for as_dir in $PATH
6210do
6211  IFS=$as_save_IFS
6212  test -z "$as_dir" && as_dir=.
6213    for ac_exec_ext in '' $ac_executable_extensions; do
6214  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6215    ac_cv_path_vi_cv_path_tcl="$as_dir/$ac_word$ac_exec_ext"
6216    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6217    break 2
6218  fi
6219done
6220  done
6221IFS=$as_save_IFS
6222
6223  ;;
6224esac
6225fi
6226vi_cv_path_tcl=$ac_cv_path_vi_cv_path_tcl
6227if test -n "$vi_cv_path_tcl"; then
6228  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_tcl" >&5
6229$as_echo "$vi_cv_path_tcl" >&6; }
6230else
6231  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6232$as_echo "no" >&6; }
6233fi
6234
6235
6236  fi
6237  if test "X$vi_cv_path_tcl" != "X"; then
6238    { $as_echo "$as_me:${as_lineno-$LINENO}: checking Tcl version" >&5
6239$as_echo_n "checking Tcl version... " >&6; }
6240    if echo 'exit [expr [info tclversion] < 8.0]' | $vi_cv_path_tcl - ; then
6241      tclver=`echo 'puts [info tclversion]' | $vi_cv_path_tcl -`
6242      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tclver - OK" >&5
6243$as_echo "$tclver - OK" >&6; };
6244      tclloc=`echo 'set l [info library];set i [string last lib $l];incr i -2;puts [string range $l 0 $i]' | $vi_cv_path_tcl -`
6245
6246      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for location of Tcl include" >&5
6247$as_echo_n "checking for location of Tcl include... " >&6; }
6248      if test "x$MACOSX" != "xyes"; then
6249	tclinc="$tclloc/include $tclloc/include/tcl $tclloc/include/tcl$tclver /usr/local/include /usr/local/include/tcl$tclver /usr/include /usr/include/tcl$tclver"
6250      else
6251		tclinc="/System/Library/Frameworks/Tcl.framework/Headers"
6252      fi
6253      TCL_INC=
6254      for try in $tclinc; do
6255	if test -f "$try/tcl.h"; then
6256	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $try/tcl.h" >&5
6257$as_echo "$try/tcl.h" >&6; }
6258	  TCL_INC=$try
6259	  break
6260	fi
6261      done
6262      if test -z "$TCL_INC"; then
6263	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: <not found>" >&5
6264$as_echo "<not found>" >&6; }
6265	SKIP_TCL=YES
6266      fi
6267      if test -z "$SKIP_TCL"; then
6268	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for location of tclConfig.sh script" >&5
6269$as_echo_n "checking for location of tclConfig.sh script... " >&6; }
6270	if test "x$MACOSX" != "xyes"; then
6271	  tclcnf=`echo $tclinc | sed s/include/lib/g`
6272	  tclcnf="$tclcnf `echo $tclinc | sed s/include/lib64/g`"
6273	else
6274	  	  tclcnf="/System/Library/Frameworks/Tcl.framework"
6275	fi
6276	for try in $tclcnf; do
6277	  if test -f $try/tclConfig.sh; then
6278	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $try/tclConfig.sh" >&5
6279$as_echo "$try/tclConfig.sh" >&6; }
6280	    . $try/tclConfig.sh
6281	    	    TCL_LIBS=`eval echo "$TCL_LIB_SPEC $TCL_LIBS"`
6282	    	    	    TCL_DEFS=`echo $TCL_DEFS | sed -e 's/\\\\ /\\\\X/g' | tr ' ' '\012' | sed -e '/^[^-]/d' -e '/^-[^D]/d' -e '/-D[^_]/d' -e 's/-D_/ -D_/' | tr '\012' ' ' | sed -e 's/\\\\X/\\\\ /g'`
6283	    break
6284	  fi
6285	done
6286	if test -z "$TCL_LIBS"; then
6287	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: <not found>" >&5
6288$as_echo "<not found>" >&6; }
6289	  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl library by myself" >&5
6290$as_echo_n "checking for Tcl library by myself... " >&6; }
6291	  tcllib=`echo $tclinc | sed s/include/lib/g`
6292	  tcllib="$tcllib `echo $tclinc | sed s/include/lib64/g`"
6293	  for ext in .so .a ; do
6294	    for ver in "" $tclver ; do
6295	      for try in $tcllib ; do
6296		trylib=tcl$ver$ext
6297		if test -f $try/lib$trylib ; then
6298		  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $try/lib$trylib" >&5
6299$as_echo "$try/lib$trylib" >&6; }
6300		  TCL_LIBS="-L$try -ltcl$ver -ldl -lm"
6301		  if test "`(uname) 2>/dev/null`" = SunOS &&
6302					 uname -r | grep '^5' >/dev/null; then
6303		    TCL_LIBS="$TCL_LIBS -R $try"
6304		  fi
6305		  break 3
6306		fi
6307	      done
6308	    done
6309	  done
6310	  if test -z "$TCL_LIBS"; then
6311	    { $as_echo "$as_me:${as_lineno-$LINENO}: result: <not found>" >&5
6312$as_echo "<not found>" >&6; }
6313	    SKIP_TCL=YES
6314	  fi
6315	fi
6316	if test -z "$SKIP_TCL"; then
6317	  $as_echo "#define FEAT_TCL 1" >>confdefs.h
6318
6319	  TCL_SRC=if_tcl.c
6320	  TCL_OBJ=objects/if_tcl.o
6321	  TCL_PRO=if_tcl.pro
6322	  TCL_CFLAGS="-I$TCL_INC $TCL_DEFS"
6323	fi
6324      fi
6325    else
6326      { $as_echo "$as_me:${as_lineno-$LINENO}: result: too old; need Tcl version 8.0 or later" >&5
6327$as_echo "too old; need Tcl version 8.0 or later" >&6; }
6328    fi
6329  fi
6330  if test "$fail_if_missing" = "yes" -a -z "$TCL_SRC"; then
6331    as_fn_error "could not configure Tcl" "$LINENO" 5
6332  fi
6333fi
6334
6335
6336
6337
6338
6339
6340{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-rubyinterp argument" >&5
6341$as_echo_n "checking --enable-rubyinterp argument... " >&6; }
6342# Check whether --enable-rubyinterp was given.
6343if test "${enable_rubyinterp+set}" = set; then :
6344  enableval=$enable_rubyinterp;
6345else
6346  enable_rubyinterp="no"
6347fi
6348
6349{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_rubyinterp" >&5
6350$as_echo "$enable_rubyinterp" >&6; }
6351if test "$enable_rubyinterp" = "yes" -o "$enable_rubyinterp" = "dynamic"; then
6352  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-ruby-command argument" >&5
6353$as_echo_n "checking --with-ruby-command argument... " >&6; }
6354
6355
6356# Check whether --with-ruby-command was given.
6357if test "${with_ruby_command+set}" = set; then :
6358  withval=$with_ruby_command; RUBY_CMD="$withval"; vi_cv_path_ruby="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RUBY_CMD" >&5
6359$as_echo "$RUBY_CMD" >&6; }
6360else
6361  RUBY_CMD="ruby"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: defaulting to $RUBY_CMD" >&5
6362$as_echo "defaulting to $RUBY_CMD" >&6; }
6363fi
6364
6365  # Extract the first word of "$RUBY_CMD", so it can be a program name with args.
6366set dummy $RUBY_CMD; ac_word=$2
6367{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6368$as_echo_n "checking for $ac_word... " >&6; }
6369if test "${ac_cv_path_vi_cv_path_ruby+set}" = set; then :
6370  $as_echo_n "(cached) " >&6
6371else
6372  case $vi_cv_path_ruby in
6373  [\\/]* | ?:[\\/]*)
6374  ac_cv_path_vi_cv_path_ruby="$vi_cv_path_ruby" # Let the user override the test with a path.
6375  ;;
6376  *)
6377  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6378for as_dir in $PATH
6379do
6380  IFS=$as_save_IFS
6381  test -z "$as_dir" && as_dir=.
6382    for ac_exec_ext in '' $ac_executable_extensions; do
6383  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6384    ac_cv_path_vi_cv_path_ruby="$as_dir/$ac_word$ac_exec_ext"
6385    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6386    break 2
6387  fi
6388done
6389  done
6390IFS=$as_save_IFS
6391
6392  ;;
6393esac
6394fi
6395vi_cv_path_ruby=$ac_cv_path_vi_cv_path_ruby
6396if test -n "$vi_cv_path_ruby"; then
6397  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_ruby" >&5
6398$as_echo "$vi_cv_path_ruby" >&6; }
6399else
6400  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6401$as_echo "no" >&6; }
6402fi
6403
6404
6405  if test "X$vi_cv_path_ruby" != "X"; then
6406    { $as_echo "$as_me:${as_lineno-$LINENO}: checking Ruby version" >&5
6407$as_echo_n "checking Ruby version... " >&6; }
6408    if $vi_cv_path_ruby -e '(VERSION rescue RUBY_VERSION) >= "1.6.0" or exit 1' >/dev/null 2>/dev/null; then
6409      { $as_echo "$as_me:${as_lineno-$LINENO}: result: OK" >&5
6410$as_echo "OK" >&6; }
6411      { $as_echo "$as_me:${as_lineno-$LINENO}: checking Ruby rbconfig" >&5
6412$as_echo_n "checking Ruby rbconfig... " >&6; }
6413      ruby_rbconfig="RbConfig"
6414      if ! $vi_cv_path_ruby -r rbconfig -e 'RbConfig' >/dev/null 2>/dev/null; then
6415	ruby_rbconfig="Config"
6416      fi
6417      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ruby_rbconfig" >&5
6418$as_echo "$ruby_rbconfig" >&6; }
6419      { $as_echo "$as_me:${as_lineno-$LINENO}: checking Ruby header files" >&5
6420$as_echo_n "checking Ruby header files... " >&6; }
6421      rubyhdrdir=`$vi_cv_path_ruby -r mkmf -e "print $ruby_rbconfig::CONFIG['rubyhdrdir'] || $ruby_rbconfig::CONFIG['archdir'] || \\$hdrdir" 2>/dev/null`
6422      if test "X$rubyhdrdir" != "X"; then
6423	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $rubyhdrdir" >&5
6424$as_echo "$rubyhdrdir" >&6; }
6425	RUBY_CFLAGS="-I$rubyhdrdir"
6426        rubyarch=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG['arch']"`
6427        if test -d "$rubyhdrdir/$rubyarch"; then
6428          RUBY_CFLAGS="$RUBY_CFLAGS -I$rubyhdrdir/$rubyarch"
6429        fi
6430        rubyversion=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG['ruby_version'].gsub(/\./, '')[0,2]"`
6431        RUBY_CFLAGS="$RUBY_CFLAGS -DRUBY_VERSION=$rubyversion"
6432	rubylibs=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG['LIBS']"`
6433	if test "X$rubylibs" != "X"; then
6434	  RUBY_LIBS="$rubylibs"
6435	fi
6436	librubyarg=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['LIBRUBYARG'])"`
6437	librubya=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['LIBRUBY_A'])"`
6438	rubylibdir=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig.expand($ruby_rbconfig::CONFIG['libdir'])"`
6439	if test -f "$rubylibdir/$librubya"; then
6440	  librubyarg="$librubyarg"
6441	  RUBY_LIBS="$RUBY_LIBS -L$rubylibdir"
6442	elif test "$librubyarg" = "libruby.a"; then
6443	  	  librubyarg="-lruby"
6444	  RUBY_LIBS="$RUBY_LIBS -L$rubylibdir"
6445	fi
6446
6447	if test "X$librubyarg" != "X"; then
6448	  RUBY_LIBS="$librubyarg $RUBY_LIBS"
6449	fi
6450	rubyldflags=`$vi_cv_path_ruby -r rbconfig -e "print $ruby_rbconfig::CONFIG['LDFLAGS']"`
6451	if test "X$rubyldflags" != "X"; then
6452	  	  	  	  rubyldflags=`echo "$rubyldflags" | sed -e 's/-arch\ ppc//' -e 's/-arch\ i386//' -e 's/-arch\ x86_64//'`
6453	  if test "X$rubyldflags" != "X"; then
6454	    LDFLAGS="$rubyldflags $LDFLAGS"
6455	  fi
6456	fi
6457	RUBY_SRC="if_ruby.c"
6458	RUBY_OBJ="objects/if_ruby.o"
6459	RUBY_PRO="if_ruby.pro"
6460	$as_echo "#define FEAT_RUBY 1" >>confdefs.h
6461
6462	if test "$enable_rubyinterp" = "dynamic"; then
6463	  libruby=`$vi_cv_path_ruby -r rbconfig -e "puts $ruby_rbconfig::CONFIG['LIBRUBY_SO']"`
6464	  $as_echo "#define DYNAMIC_RUBY 1" >>confdefs.h
6465
6466	  RUBY_CFLAGS="-DDYNAMIC_RUBY_DLL=\\\"$libruby\\\" -DDYNAMIC_RUBY_VER=$rubyversion $RUBY_CFLAGS"
6467	  RUBY_LIBS=
6468	fi
6469      else
6470	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: not found; disabling Ruby" >&5
6471$as_echo "not found; disabling Ruby" >&6; }
6472      fi
6473    else
6474      { $as_echo "$as_me:${as_lineno-$LINENO}: result: too old; need Ruby version 1.6.0 or later" >&5
6475$as_echo "too old; need Ruby version 1.6.0 or later" >&6; }
6476    fi
6477  fi
6478
6479  if test "$fail_if_missing" = "yes" -a -z "$RUBY_OBJ"; then
6480    as_fn_error "could not configure Ruby" "$LINENO" 5
6481  fi
6482fi
6483
6484
6485
6486
6487
6488
6489{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-cscope argument" >&5
6490$as_echo_n "checking --enable-cscope argument... " >&6; }
6491# Check whether --enable-cscope was given.
6492if test "${enable_cscope+set}" = set; then :
6493  enableval=$enable_cscope;
6494else
6495  enable_cscope="no"
6496fi
6497
6498{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_cscope" >&5
6499$as_echo "$enable_cscope" >&6; }
6500if test "$enable_cscope" = "yes"; then
6501  $as_echo "#define FEAT_CSCOPE 1" >>confdefs.h
6502
6503fi
6504
6505{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-workshop argument" >&5
6506$as_echo_n "checking --enable-workshop argument... " >&6; }
6507# Check whether --enable-workshop was given.
6508if test "${enable_workshop+set}" = set; then :
6509  enableval=$enable_workshop;
6510else
6511  enable_workshop="no"
6512fi
6513
6514{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_workshop" >&5
6515$as_echo "$enable_workshop" >&6; }
6516if test "$enable_workshop" = "yes"; then
6517  $as_echo "#define FEAT_SUN_WORKSHOP 1" >>confdefs.h
6518
6519  WORKSHOP_SRC="workshop.c integration.c"
6520
6521  WORKSHOP_OBJ="objects/workshop.o objects/integration.o"
6522
6523  if test "${enable_gui-xxx}" = xxx; then
6524    enable_gui=motif
6525  fi
6526fi
6527
6528{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-netbeans argument" >&5
6529$as_echo_n "checking --disable-netbeans argument... " >&6; }
6530# Check whether --enable-netbeans was given.
6531if test "${enable_netbeans+set}" = set; then :
6532  enableval=$enable_netbeans;
6533else
6534  enable_netbeans="yes"
6535fi
6536
6537if test "$enable_netbeans" = "yes"; then
6538  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6539$as_echo "no" >&6; }
6540    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5
6541$as_echo_n "checking for socket in -lsocket... " >&6; }
6542if test "${ac_cv_lib_socket_socket+set}" = set; then :
6543  $as_echo_n "(cached) " >&6
6544else
6545  ac_check_lib_save_LIBS=$LIBS
6546LIBS="-lsocket  $LIBS"
6547cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6548/* end confdefs.h.  */
6549
6550/* Override any GCC internal prototype to avoid an error.
6551   Use char because int might match the return type of a GCC
6552   builtin and then its argument prototype would still apply.  */
6553#ifdef __cplusplus
6554extern "C"
6555#endif
6556char socket ();
6557int
6558main ()
6559{
6560return socket ();
6561  ;
6562  return 0;
6563}
6564_ACEOF
6565if ac_fn_c_try_link "$LINENO"; then :
6566  ac_cv_lib_socket_socket=yes
6567else
6568  ac_cv_lib_socket_socket=no
6569fi
6570rm -f core conftest.err conftest.$ac_objext \
6571    conftest$ac_exeext conftest.$ac_ext
6572LIBS=$ac_check_lib_save_LIBS
6573fi
6574{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5
6575$as_echo "$ac_cv_lib_socket_socket" >&6; }
6576if test "x$ac_cv_lib_socket_socket" = x""yes; then :
6577  cat >>confdefs.h <<_ACEOF
6578#define HAVE_LIBSOCKET 1
6579_ACEOF
6580
6581  LIBS="-lsocket $LIBS"
6582
6583fi
6584
6585  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
6586$as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
6587if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then :
6588  $as_echo_n "(cached) " >&6
6589else
6590  ac_check_lib_save_LIBS=$LIBS
6591LIBS="-lnsl  $LIBS"
6592cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6593/* end confdefs.h.  */
6594
6595/* Override any GCC internal prototype to avoid an error.
6596   Use char because int might match the return type of a GCC
6597   builtin and then its argument prototype would still apply.  */
6598#ifdef __cplusplus
6599extern "C"
6600#endif
6601char gethostbyname ();
6602int
6603main ()
6604{
6605return gethostbyname ();
6606  ;
6607  return 0;
6608}
6609_ACEOF
6610if ac_fn_c_try_link "$LINENO"; then :
6611  ac_cv_lib_nsl_gethostbyname=yes
6612else
6613  ac_cv_lib_nsl_gethostbyname=no
6614fi
6615rm -f core conftest.err conftest.$ac_objext \
6616    conftest$ac_exeext conftest.$ac_ext
6617LIBS=$ac_check_lib_save_LIBS
6618fi
6619{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
6620$as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
6621if test "x$ac_cv_lib_nsl_gethostbyname" = x""yes; then :
6622  cat >>confdefs.h <<_ACEOF
6623#define HAVE_LIBNSL 1
6624_ACEOF
6625
6626  LIBS="-lnsl $LIBS"
6627
6628fi
6629
6630  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiling netbeans integration is possible" >&5
6631$as_echo_n "checking whether compiling netbeans integration is possible... " >&6; }
6632  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6633/* end confdefs.h.  */
6634
6635#include <stdio.h>
6636#include <stdlib.h>
6637#include <stdarg.h>
6638#include <fcntl.h>
6639#include <netdb.h>
6640#include <netinet/in.h>
6641#include <errno.h>
6642#include <sys/types.h>
6643#include <sys/socket.h>
6644	/* Check bitfields */
6645	struct nbbuf {
6646	unsigned int  initDone:1;
6647	ushort signmaplen;
6648	};
6649
6650int
6651main ()
6652{
6653
6654		/* Check creating a socket. */
6655		struct sockaddr_in server;
6656		(void)socket(AF_INET, SOCK_STREAM, 0);
6657		(void)htons(100);
6658		(void)gethostbyname("microsoft.com");
6659		if (errno == ECONNREFUSED)
6660		  (void)connect(1, (struct sockaddr *)&server, sizeof(server));
6661
6662  ;
6663  return 0;
6664}
6665_ACEOF
6666if ac_fn_c_try_link "$LINENO"; then :
6667  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6668$as_echo "yes" >&6; }
6669else
6670  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6671$as_echo "no" >&6; }; enable_netbeans="no"
6672fi
6673rm -f core conftest.err conftest.$ac_objext \
6674    conftest$ac_exeext conftest.$ac_ext
6675else
6676  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6677$as_echo "yes" >&6; }
6678fi
6679if test "$enable_netbeans" = "yes"; then
6680  $as_echo "#define FEAT_NETBEANS_INTG 1" >>confdefs.h
6681
6682  NETBEANS_SRC="netbeans.c"
6683
6684  NETBEANS_OBJ="objects/netbeans.o"
6685
6686fi
6687
6688{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-sniff argument" >&5
6689$as_echo_n "checking --enable-sniff argument... " >&6; }
6690# Check whether --enable-sniff was given.
6691if test "${enable_sniff+set}" = set; then :
6692  enableval=$enable_sniff;
6693else
6694  enable_sniff="no"
6695fi
6696
6697{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_sniff" >&5
6698$as_echo "$enable_sniff" >&6; }
6699if test "$enable_sniff" = "yes"; then
6700  $as_echo "#define FEAT_SNIFF 1" >>confdefs.h
6701
6702  SNIFF_SRC="if_sniff.c"
6703
6704  SNIFF_OBJ="objects/if_sniff.o"
6705
6706fi
6707
6708{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-multibyte argument" >&5
6709$as_echo_n "checking --enable-multibyte argument... " >&6; }
6710# Check whether --enable-multibyte was given.
6711if test "${enable_multibyte+set}" = set; then :
6712  enableval=$enable_multibyte;
6713else
6714  enable_multibyte="no"
6715fi
6716
6717{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_multibyte" >&5
6718$as_echo "$enable_multibyte" >&6; }
6719if test "$enable_multibyte" = "yes"; then
6720  $as_echo "#define FEAT_MBYTE 1" >>confdefs.h
6721
6722fi
6723
6724{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-hangulinput argument" >&5
6725$as_echo_n "checking --enable-hangulinput argument... " >&6; }
6726# Check whether --enable-hangulinput was given.
6727if test "${enable_hangulinput+set}" = set; then :
6728  enableval=$enable_hangulinput;
6729else
6730  enable_hangulinput="no"
6731fi
6732
6733{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_hangulinput" >&5
6734$as_echo "$enable_hangulinput" >&6; }
6735
6736{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-xim argument" >&5
6737$as_echo_n "checking --enable-xim argument... " >&6; }
6738# Check whether --enable-xim was given.
6739if test "${enable_xim+set}" = set; then :
6740  enableval=$enable_xim; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_xim" >&5
6741$as_echo "$enable_xim" >&6; }
6742else
6743  enable_xim="auto"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: defaulting to auto" >&5
6744$as_echo "defaulting to auto" >&6; }
6745fi
6746
6747
6748{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-fontset argument" >&5
6749$as_echo_n "checking --enable-fontset argument... " >&6; }
6750# Check whether --enable-fontset was given.
6751if test "${enable_fontset+set}" = set; then :
6752  enableval=$enable_fontset;
6753else
6754  enable_fontset="no"
6755fi
6756
6757{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_fontset" >&5
6758$as_echo "$enable_fontset" >&6; }
6759
6760test -z "$with_x" && with_x=yes
6761test "${enable_gui-yes}" != no -a "x$MACOSX" != "xyes" -a "x$QNX" != "xyes" && with_x=yes
6762if test "$with_x" = no; then
6763  { $as_echo "$as_me:${as_lineno-$LINENO}: result: defaulting to: don't HAVE_X11" >&5
6764$as_echo "defaulting to: don't HAVE_X11" >&6; }
6765else
6766
6767  # Extract the first word of "xmkmf", so it can be a program name with args.
6768set dummy xmkmf; ac_word=$2
6769{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6770$as_echo_n "checking for $ac_word... " >&6; }
6771if test "${ac_cv_path_xmkmfpath+set}" = set; then :
6772  $as_echo_n "(cached) " >&6
6773else
6774  case $xmkmfpath in
6775  [\\/]* | ?:[\\/]*)
6776  ac_cv_path_xmkmfpath="$xmkmfpath" # Let the user override the test with a path.
6777  ;;
6778  *)
6779  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6780for as_dir in $PATH
6781do
6782  IFS=$as_save_IFS
6783  test -z "$as_dir" && as_dir=.
6784    for ac_exec_ext in '' $ac_executable_extensions; do
6785  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6786    ac_cv_path_xmkmfpath="$as_dir/$ac_word$ac_exec_ext"
6787    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6788    break 2
6789  fi
6790done
6791  done
6792IFS=$as_save_IFS
6793
6794  ;;
6795esac
6796fi
6797xmkmfpath=$ac_cv_path_xmkmfpath
6798if test -n "$xmkmfpath"; then
6799  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xmkmfpath" >&5
6800$as_echo "$xmkmfpath" >&6; }
6801else
6802  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6803$as_echo "no" >&6; }
6804fi
6805
6806
6807
6808  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
6809$as_echo_n "checking for X... " >&6; }
6810
6811
6812# Check whether --with-x was given.
6813if test "${with_x+set}" = set; then :
6814  withval=$with_x;
6815fi
6816
6817# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
6818if test "x$with_x" = xno; then
6819  # The user explicitly disabled X.
6820  have_x=disabled
6821else
6822  case $x_includes,$x_libraries in #(
6823    *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
6824    *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
6825  $as_echo_n "(cached) " >&6
6826else
6827  # One or both of the vars are not set, and there is no cached value.
6828ac_x_includes=no ac_x_libraries=no
6829rm -f -r conftest.dir
6830if mkdir conftest.dir; then
6831  cd conftest.dir
6832  cat >Imakefile <<'_ACEOF'
6833incroot:
6834	@echo incroot='${INCROOT}'
6835usrlibdir:
6836	@echo usrlibdir='${USRLIBDIR}'
6837libdir:
6838	@echo libdir='${LIBDIR}'
6839_ACEOF
6840  if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
6841    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
6842    for ac_var in incroot usrlibdir libdir; do
6843      eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
6844    done
6845    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
6846    for ac_extension in a so sl dylib la dll; do
6847      if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
6848	 test -f "$ac_im_libdir/libX11.$ac_extension"; then
6849	ac_im_usrlibdir=$ac_im_libdir; break
6850      fi
6851    done
6852    # Screen out bogus values from the imake configuration.  They are
6853    # bogus both because they are the default anyway, and because
6854    # using them would break gcc on systems where it needs fixed includes.
6855    case $ac_im_incroot in
6856	/usr/include) ac_x_includes= ;;
6857	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
6858    esac
6859    case $ac_im_usrlibdir in
6860	/usr/lib | /usr/lib64 | /lib | /lib64) ;;
6861	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
6862    esac
6863  fi
6864  cd ..
6865  rm -f -r conftest.dir
6866fi
6867
6868# Standard set of common directories for X headers.
6869# Check X11 before X11Rn because it is often a symlink to the current release.
6870ac_x_header_dirs='
6871/usr/X11/include
6872/usr/X11R7/include
6873/usr/X11R6/include
6874/usr/X11R5/include
6875/usr/X11R4/include
6876
6877/usr/include/X11
6878/usr/include/X11R7
6879/usr/include/X11R6
6880/usr/include/X11R5
6881/usr/include/X11R4
6882
6883/usr/local/X11/include
6884/usr/local/X11R7/include
6885/usr/local/X11R6/include
6886/usr/local/X11R5/include
6887/usr/local/X11R4/include
6888
6889/usr/local/include/X11
6890/usr/local/include/X11R7
6891/usr/local/include/X11R6
6892/usr/local/include/X11R5
6893/usr/local/include/X11R4
6894
6895/usr/X386/include
6896/usr/x386/include
6897/usr/XFree86/include/X11
6898
6899/usr/include
6900/usr/local/include
6901/usr/unsupported/include
6902/usr/athena/include
6903/usr/local/x11r5/include
6904/usr/lpp/Xamples/include
6905
6906/usr/openwin/include
6907/usr/openwin/share/include'
6908
6909if test "$ac_x_includes" = no; then
6910  # Guess where to find include files, by looking for Xlib.h.
6911  # First, try using that file with no special directory specified.
6912  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6913/* end confdefs.h.  */
6914#include <X11/Xlib.h>
6915_ACEOF
6916if ac_fn_c_try_cpp "$LINENO"; then :
6917  # We can compile using X headers with no special include directory.
6918ac_x_includes=
6919else
6920  for ac_dir in $ac_x_header_dirs; do
6921  if test -r "$ac_dir/X11/Xlib.h"; then
6922    ac_x_includes=$ac_dir
6923    break
6924  fi
6925done
6926fi
6927rm -f conftest.err conftest.$ac_ext
6928fi # $ac_x_includes = no
6929
6930if test "$ac_x_libraries" = no; then
6931  # Check for the libraries.
6932  # See if we find them without any special options.
6933  # Don't add to $LIBS permanently.
6934  ac_save_LIBS=$LIBS
6935  LIBS="-lX11 $LIBS"
6936  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6937/* end confdefs.h.  */
6938#include <X11/Xlib.h>
6939int
6940main ()
6941{
6942XrmInitialize ()
6943  ;
6944  return 0;
6945}
6946_ACEOF
6947if ac_fn_c_try_link "$LINENO"; then :
6948  LIBS=$ac_save_LIBS
6949# We can link X programs with no special library path.
6950ac_x_libraries=
6951else
6952  LIBS=$ac_save_LIBS
6953for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
6954do
6955  # Don't even attempt the hair of trying to link an X program!
6956  for ac_extension in a so sl dylib la dll; do
6957    if test -r "$ac_dir/libX11.$ac_extension"; then
6958      ac_x_libraries=$ac_dir
6959      break 2
6960    fi
6961  done
6962done
6963fi
6964rm -f core conftest.err conftest.$ac_objext \
6965    conftest$ac_exeext conftest.$ac_ext
6966fi # $ac_x_libraries = no
6967
6968case $ac_x_includes,$ac_x_libraries in #(
6969  no,* | *,no | *\'*)
6970    # Didn't find X, or a directory has "'" in its name.
6971    ac_cv_have_x="have_x=no";; #(
6972  *)
6973    # Record where we found X for the cache.
6974    ac_cv_have_x="have_x=yes\
6975	ac_x_includes='$ac_x_includes'\
6976	ac_x_libraries='$ac_x_libraries'"
6977esac
6978fi
6979;; #(
6980    *) have_x=yes;;
6981  esac
6982  eval "$ac_cv_have_x"
6983fi # $with_x != no
6984
6985if test "$have_x" != yes; then
6986  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
6987$as_echo "$have_x" >&6; }
6988  no_x=yes
6989else
6990  # If each of the values was on the command line, it overrides each guess.
6991  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
6992  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
6993  # Update the cache value to reflect the command line values.
6994  ac_cv_have_x="have_x=yes\
6995	ac_x_includes='$x_includes'\
6996	ac_x_libraries='$x_libraries'"
6997  { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
6998$as_echo "libraries $x_libraries, headers $x_includes" >&6; }
6999fi
7000
7001if test "$no_x" = yes; then
7002  # Not all programs may use this symbol, but it does not hurt to define it.
7003
7004$as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h
7005
7006  X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
7007else
7008  if test -n "$x_includes"; then
7009    X_CFLAGS="$X_CFLAGS -I$x_includes"
7010  fi
7011
7012  # It would also be nice to do this for all -L options, not just this one.
7013  if test -n "$x_libraries"; then
7014    X_LIBS="$X_LIBS -L$x_libraries"
7015    # For Solaris; some versions of Sun CC require a space after -R and
7016    # others require no space.  Words are not sufficient . . . .
7017    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5
7018$as_echo_n "checking whether -R must be followed by a space... " >&6; }
7019    ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
7020    ac_xsave_c_werror_flag=$ac_c_werror_flag
7021    ac_c_werror_flag=yes
7022    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7023/* end confdefs.h.  */
7024
7025int
7026main ()
7027{
7028
7029  ;
7030  return 0;
7031}
7032_ACEOF
7033if ac_fn_c_try_link "$LINENO"; then :
7034  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7035$as_echo "no" >&6; }
7036       X_LIBS="$X_LIBS -R$x_libraries"
7037else
7038  LIBS="$ac_xsave_LIBS -R $x_libraries"
7039       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7040/* end confdefs.h.  */
7041
7042int
7043main ()
7044{
7045
7046  ;
7047  return 0;
7048}
7049_ACEOF
7050if ac_fn_c_try_link "$LINENO"; then :
7051  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7052$as_echo "yes" >&6; }
7053	  X_LIBS="$X_LIBS -R $x_libraries"
7054else
7055  { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5
7056$as_echo "neither works" >&6; }
7057fi
7058rm -f core conftest.err conftest.$ac_objext \
7059    conftest$ac_exeext conftest.$ac_ext
7060fi
7061rm -f core conftest.err conftest.$ac_objext \
7062    conftest$ac_exeext conftest.$ac_ext
7063    ac_c_werror_flag=$ac_xsave_c_werror_flag
7064    LIBS=$ac_xsave_LIBS
7065  fi
7066
7067  # Check for system-dependent libraries X programs must link with.
7068  # Do this before checking for the system-independent R6 libraries
7069  # (-lICE), since we may need -lsocket or whatever for X linking.
7070
7071  if test "$ISC" = yes; then
7072    X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
7073  else
7074    # Martyn Johnson says this is needed for Ultrix, if the X
7075    # libraries were built with DECnet support.  And Karl Berry says
7076    # the Alpha needs dnet_stub (dnet does not exist).
7077    ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
7078    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7079/* end confdefs.h.  */
7080
7081/* Override any GCC internal prototype to avoid an error.
7082   Use char because int might match the return type of a GCC
7083   builtin and then its argument prototype would still apply.  */
7084#ifdef __cplusplus
7085extern "C"
7086#endif
7087char XOpenDisplay ();
7088int
7089main ()
7090{
7091return XOpenDisplay ();
7092  ;
7093  return 0;
7094}
7095_ACEOF
7096if ac_fn_c_try_link "$LINENO"; then :
7097
7098else
7099  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
7100$as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
7101if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
7102  $as_echo_n "(cached) " >&6
7103else
7104  ac_check_lib_save_LIBS=$LIBS
7105LIBS="-ldnet  $LIBS"
7106cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7107/* end confdefs.h.  */
7108
7109/* Override any GCC internal prototype to avoid an error.
7110   Use char because int might match the return type of a GCC
7111   builtin and then its argument prototype would still apply.  */
7112#ifdef __cplusplus
7113extern "C"
7114#endif
7115char dnet_ntoa ();
7116int
7117main ()
7118{
7119return dnet_ntoa ();
7120  ;
7121  return 0;
7122}
7123_ACEOF
7124if ac_fn_c_try_link "$LINENO"; then :
7125  ac_cv_lib_dnet_dnet_ntoa=yes
7126else
7127  ac_cv_lib_dnet_dnet_ntoa=no
7128fi
7129rm -f core conftest.err conftest.$ac_objext \
7130    conftest$ac_exeext conftest.$ac_ext
7131LIBS=$ac_check_lib_save_LIBS
7132fi
7133{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
7134$as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
7135if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
7136  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
7137fi
7138
7139    if test $ac_cv_lib_dnet_dnet_ntoa = no; then
7140      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5
7141$as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; }
7142if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then :
7143  $as_echo_n "(cached) " >&6
7144else
7145  ac_check_lib_save_LIBS=$LIBS
7146LIBS="-ldnet_stub  $LIBS"
7147cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7148/* end confdefs.h.  */
7149
7150/* Override any GCC internal prototype to avoid an error.
7151   Use char because int might match the return type of a GCC
7152   builtin and then its argument prototype would still apply.  */
7153#ifdef __cplusplus
7154extern "C"
7155#endif
7156char dnet_ntoa ();
7157int
7158main ()
7159{
7160return dnet_ntoa ();
7161  ;
7162  return 0;
7163}
7164_ACEOF
7165if ac_fn_c_try_link "$LINENO"; then :
7166  ac_cv_lib_dnet_stub_dnet_ntoa=yes
7167else
7168  ac_cv_lib_dnet_stub_dnet_ntoa=no
7169fi
7170rm -f core conftest.err conftest.$ac_objext \
7171    conftest$ac_exeext conftest.$ac_ext
7172LIBS=$ac_check_lib_save_LIBS
7173fi
7174{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
7175$as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; }
7176if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = x""yes; then :
7177  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
7178fi
7179
7180    fi
7181fi
7182rm -f core conftest.err conftest.$ac_objext \
7183    conftest$ac_exeext conftest.$ac_ext
7184    LIBS="$ac_xsave_LIBS"
7185
7186    # [email protected] says -lnsl (and -lsocket) are needed for his 386/AT,
7187    # to get the SysV transport functions.
7188    # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
7189    # needs -lnsl.
7190    # The nsl library prevents programs from opening the X display
7191    # on Irix 5.2, according to T.E. Dickey.
7192    # The functions gethostbyname, getservbyname, and inet_addr are
7193    # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
7194    ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
7195if test "x$ac_cv_func_gethostbyname" = x""yes; then :
7196
7197fi
7198
7199    if test $ac_cv_func_gethostbyname = no; then
7200      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
7201$as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
7202if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then :
7203  $as_echo_n "(cached) " >&6
7204else
7205  ac_check_lib_save_LIBS=$LIBS
7206LIBS="-lnsl  $LIBS"
7207cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7208/* end confdefs.h.  */
7209
7210/* Override any GCC internal prototype to avoid an error.
7211   Use char because int might match the return type of a GCC
7212   builtin and then its argument prototype would still apply.  */
7213#ifdef __cplusplus
7214extern "C"
7215#endif
7216char gethostbyname ();
7217int
7218main ()
7219{
7220return gethostbyname ();
7221  ;
7222  return 0;
7223}
7224_ACEOF
7225if ac_fn_c_try_link "$LINENO"; then :
7226  ac_cv_lib_nsl_gethostbyname=yes
7227else
7228  ac_cv_lib_nsl_gethostbyname=no
7229fi
7230rm -f core conftest.err conftest.$ac_objext \
7231    conftest$ac_exeext conftest.$ac_ext
7232LIBS=$ac_check_lib_save_LIBS
7233fi
7234{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
7235$as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
7236if test "x$ac_cv_lib_nsl_gethostbyname" = x""yes; then :
7237  X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
7238fi
7239
7240      if test $ac_cv_lib_nsl_gethostbyname = no; then
7241	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5
7242$as_echo_n "checking for gethostbyname in -lbsd... " >&6; }
7243if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then :
7244  $as_echo_n "(cached) " >&6
7245else
7246  ac_check_lib_save_LIBS=$LIBS
7247LIBS="-lbsd  $LIBS"
7248cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7249/* end confdefs.h.  */
7250
7251/* Override any GCC internal prototype to avoid an error.
7252   Use char because int might match the return type of a GCC
7253   builtin and then its argument prototype would still apply.  */
7254#ifdef __cplusplus
7255extern "C"
7256#endif
7257char gethostbyname ();
7258int
7259main ()
7260{
7261return gethostbyname ();
7262  ;
7263  return 0;
7264}
7265_ACEOF
7266if ac_fn_c_try_link "$LINENO"; then :
7267  ac_cv_lib_bsd_gethostbyname=yes
7268else
7269  ac_cv_lib_bsd_gethostbyname=no
7270fi
7271rm -f core conftest.err conftest.$ac_objext \
7272    conftest$ac_exeext conftest.$ac_ext
7273LIBS=$ac_check_lib_save_LIBS
7274fi
7275{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5
7276$as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; }
7277if test "x$ac_cv_lib_bsd_gethostbyname" = x""yes; then :
7278  X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
7279fi
7280
7281      fi
7282    fi
7283
7284    # [email protected] says without -lsocket,
7285    # socket/setsockopt and other routines are undefined under SCO ODT
7286    # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
7287    # on later versions), says Simon Leinen: it contains gethostby*
7288    # variants that don't use the name server (or something).  -lsocket
7289    # must be given before -lnsl if both are needed.  We assume that
7290    # if connect needs -lnsl, so does gethostbyname.
7291    ac_fn_c_check_func "$LINENO" "connect" "ac_cv_func_connect"
7292if test "x$ac_cv_func_connect" = x""yes; then :
7293
7294fi
7295
7296    if test $ac_cv_func_connect = no; then
7297      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5
7298$as_echo_n "checking for connect in -lsocket... " >&6; }
7299if test "${ac_cv_lib_socket_connect+set}" = set; then :
7300  $as_echo_n "(cached) " >&6
7301else
7302  ac_check_lib_save_LIBS=$LIBS
7303LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
7304cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7305/* end confdefs.h.  */
7306
7307/* Override any GCC internal prototype to avoid an error.
7308   Use char because int might match the return type of a GCC
7309   builtin and then its argument prototype would still apply.  */
7310#ifdef __cplusplus
7311extern "C"
7312#endif
7313char connect ();
7314int
7315main ()
7316{
7317return connect ();
7318  ;
7319  return 0;
7320}
7321_ACEOF
7322if ac_fn_c_try_link "$LINENO"; then :
7323  ac_cv_lib_socket_connect=yes
7324else
7325  ac_cv_lib_socket_connect=no
7326fi
7327rm -f core conftest.err conftest.$ac_objext \
7328    conftest$ac_exeext conftest.$ac_ext
7329LIBS=$ac_check_lib_save_LIBS
7330fi
7331{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5
7332$as_echo "$ac_cv_lib_socket_connect" >&6; }
7333if test "x$ac_cv_lib_socket_connect" = x""yes; then :
7334  X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
7335fi
7336
7337    fi
7338
7339    # Guillermo Gomez says -lposix is necessary on A/UX.
7340    ac_fn_c_check_func "$LINENO" "remove" "ac_cv_func_remove"
7341if test "x$ac_cv_func_remove" = x""yes; then :
7342
7343fi
7344
7345    if test $ac_cv_func_remove = no; then
7346      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5
7347$as_echo_n "checking for remove in -lposix... " >&6; }
7348if test "${ac_cv_lib_posix_remove+set}" = set; then :
7349  $as_echo_n "(cached) " >&6
7350else
7351  ac_check_lib_save_LIBS=$LIBS
7352LIBS="-lposix  $LIBS"
7353cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7354/* end confdefs.h.  */
7355
7356/* Override any GCC internal prototype to avoid an error.
7357   Use char because int might match the return type of a GCC
7358   builtin and then its argument prototype would still apply.  */
7359#ifdef __cplusplus
7360extern "C"
7361#endif
7362char remove ();
7363int
7364main ()
7365{
7366return remove ();
7367  ;
7368  return 0;
7369}
7370_ACEOF
7371if ac_fn_c_try_link "$LINENO"; then :
7372  ac_cv_lib_posix_remove=yes
7373else
7374  ac_cv_lib_posix_remove=no
7375fi
7376rm -f core conftest.err conftest.$ac_objext \
7377    conftest$ac_exeext conftest.$ac_ext
7378LIBS=$ac_check_lib_save_LIBS
7379fi
7380{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5
7381$as_echo "$ac_cv_lib_posix_remove" >&6; }
7382if test "x$ac_cv_lib_posix_remove" = x""yes; then :
7383  X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
7384fi
7385
7386    fi
7387
7388    # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
7389    ac_fn_c_check_func "$LINENO" "shmat" "ac_cv_func_shmat"
7390if test "x$ac_cv_func_shmat" = x""yes; then :
7391
7392fi
7393
7394    if test $ac_cv_func_shmat = no; then
7395      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5
7396$as_echo_n "checking for shmat in -lipc... " >&6; }
7397if test "${ac_cv_lib_ipc_shmat+set}" = set; then :
7398  $as_echo_n "(cached) " >&6
7399else
7400  ac_check_lib_save_LIBS=$LIBS
7401LIBS="-lipc  $LIBS"
7402cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7403/* end confdefs.h.  */
7404
7405/* Override any GCC internal prototype to avoid an error.
7406   Use char because int might match the return type of a GCC
7407   builtin and then its argument prototype would still apply.  */
7408#ifdef __cplusplus
7409extern "C"
7410#endif
7411char shmat ();
7412int
7413main ()
7414{
7415return shmat ();
7416  ;
7417  return 0;
7418}
7419_ACEOF
7420if ac_fn_c_try_link "$LINENO"; then :
7421  ac_cv_lib_ipc_shmat=yes
7422else
7423  ac_cv_lib_ipc_shmat=no
7424fi
7425rm -f core conftest.err conftest.$ac_objext \
7426    conftest$ac_exeext conftest.$ac_ext
7427LIBS=$ac_check_lib_save_LIBS
7428fi
7429{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5
7430$as_echo "$ac_cv_lib_ipc_shmat" >&6; }
7431if test "x$ac_cv_lib_ipc_shmat" = x""yes; then :
7432  X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
7433fi
7434
7435    fi
7436  fi
7437
7438  # Check for libraries that X11R6 Xt/Xaw programs need.
7439  ac_save_LDFLAGS=$LDFLAGS
7440  test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
7441  # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
7442  # check for ICE first), but we must link in the order -lSM -lICE or
7443  # we get undefined symbols.  So assume we have SM if we have ICE.
7444  # These have to be linked with before -lX11, unlike the other
7445  # libraries we check for below, so use a different variable.
7446  # John Interrante, Karl Berry
7447  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5
7448$as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; }
7449if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then :
7450  $as_echo_n "(cached) " >&6
7451else
7452  ac_check_lib_save_LIBS=$LIBS
7453LIBS="-lICE $X_EXTRA_LIBS $LIBS"
7454cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7455/* end confdefs.h.  */
7456
7457/* Override any GCC internal prototype to avoid an error.
7458   Use char because int might match the return type of a GCC
7459   builtin and then its argument prototype would still apply.  */
7460#ifdef __cplusplus
7461extern "C"
7462#endif
7463char IceConnectionNumber ();
7464int
7465main ()
7466{
7467return IceConnectionNumber ();
7468  ;
7469  return 0;
7470}
7471_ACEOF
7472if ac_fn_c_try_link "$LINENO"; then :
7473  ac_cv_lib_ICE_IceConnectionNumber=yes
7474else
7475  ac_cv_lib_ICE_IceConnectionNumber=no
7476fi
7477rm -f core conftest.err conftest.$ac_objext \
7478    conftest$ac_exeext conftest.$ac_ext
7479LIBS=$ac_check_lib_save_LIBS
7480fi
7481{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
7482$as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; }
7483if test "x$ac_cv_lib_ICE_IceConnectionNumber" = x""yes; then :
7484  X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
7485fi
7486
7487  LDFLAGS=$ac_save_LDFLAGS
7488
7489fi
7490
7491
7492        if test "$zOSUnix" = "yes"; then
7493    CFLAGS="$CFLAGS -W c,dll"
7494    LDFLAGS="$LDFLAGS -W l,dll"
7495    X_EXTRA_LIBS="$X_EXTRA_LIBS -lSM -lICE -lXmu"
7496  fi
7497
7498
7499  if test -d "$x_includes" && test ! -d "$x_libraries"; then
7500    x_libraries=`echo "$x_includes" | sed s/include/lib/`
7501    { $as_echo "$as_me:${as_lineno-$LINENO}: result: Corrected X libraries to $x_libraries" >&5
7502$as_echo "Corrected X libraries to $x_libraries" >&6; }
7503    X_LIBS="$X_LIBS -L$x_libraries"
7504    if test "`(uname) 2>/dev/null`" = SunOS &&
7505					 uname -r | grep '^5' >/dev/null; then
7506      X_LIBS="$X_LIBS -R $x_libraries"
7507    fi
7508  fi
7509
7510  if test -d "$x_libraries" && test ! -d "$x_includes"; then
7511    x_includes=`echo "$x_libraries" | sed s/lib/include/`
7512    { $as_echo "$as_me:${as_lineno-$LINENO}: result: Corrected X includes to $x_includes" >&5
7513$as_echo "Corrected X includes to $x_includes" >&6; }
7514    X_CFLAGS="$X_CFLAGS -I$x_includes"
7515  fi
7516
7517    X_CFLAGS="`echo $X_CFLAGS\  | sed 's%-I/usr/include %%'`"
7518    X_LIBS="`echo $X_LIBS\  | sed 's%-L/usr/lib %%'`"
7519    X_LIBS="`echo $X_LIBS\  | sed -e 's%-R/usr/lib %%' -e 's%-R /usr/lib %%'`"
7520
7521
7522        { $as_echo "$as_me:${as_lineno-$LINENO}: checking if X11 header files can be found" >&5
7523$as_echo_n "checking if X11 header files can be found... " >&6; }
7524  cflags_save=$CFLAGS
7525  CFLAGS="$CFLAGS $X_CFLAGS"
7526  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7527/* end confdefs.h.  */
7528#include <X11/Xlib.h>
7529#include <X11/Intrinsic.h>
7530int
7531main ()
7532{
7533
7534  ;
7535  return 0;
7536}
7537_ACEOF
7538if ac_fn_c_try_compile "$LINENO"; then :
7539  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7540$as_echo "yes" >&6; }
7541else
7542  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7543$as_echo "no" >&6; }; no_x=yes
7544fi
7545rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7546  CFLAGS=$cflags_save
7547
7548  if test "${no_x-no}" = yes; then
7549    with_x=no
7550  else
7551    $as_echo "#define HAVE_X11 1" >>confdefs.h
7552
7553    X_LIB="-lXt -lX11";
7554
7555
7556    ac_save_LDFLAGS="$LDFLAGS"
7557    LDFLAGS="-L$x_libraries $LDFLAGS"
7558
7559            { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _XdmcpAuthDoIt in -lXdmcp" >&5
7560$as_echo_n "checking for _XdmcpAuthDoIt in -lXdmcp... " >&6; }
7561if test "${ac_cv_lib_Xdmcp__XdmcpAuthDoIt+set}" = set; then :
7562  $as_echo_n "(cached) " >&6
7563else
7564  ac_check_lib_save_LIBS=$LIBS
7565LIBS="-lXdmcp -lXt $X_PRE_LIBS -lX11 $X_EXTRA_LIBS -lXdmcp $LIBS"
7566cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7567/* end confdefs.h.  */
7568
7569/* Override any GCC internal prototype to avoid an error.
7570   Use char because int might match the return type of a GCC
7571   builtin and then its argument prototype would still apply.  */
7572#ifdef __cplusplus
7573extern "C"
7574#endif
7575char _XdmcpAuthDoIt ();
7576int
7577main ()
7578{
7579return _XdmcpAuthDoIt ();
7580  ;
7581  return 0;
7582}
7583_ACEOF
7584if ac_fn_c_try_link "$LINENO"; then :
7585  ac_cv_lib_Xdmcp__XdmcpAuthDoIt=yes
7586else
7587  ac_cv_lib_Xdmcp__XdmcpAuthDoIt=no
7588fi
7589rm -f core conftest.err conftest.$ac_objext \
7590    conftest$ac_exeext conftest.$ac_ext
7591LIBS=$ac_check_lib_save_LIBS
7592fi
7593{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xdmcp__XdmcpAuthDoIt" >&5
7594$as_echo "$ac_cv_lib_Xdmcp__XdmcpAuthDoIt" >&6; }
7595if test "x$ac_cv_lib_Xdmcp__XdmcpAuthDoIt" = x""yes; then :
7596  X_EXTRA_LIBS="$X_EXTRA_LIBS -lXdmcp"
7597fi
7598
7599
7600                    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceOpenConnection in -lICE" >&5
7601$as_echo_n "checking for IceOpenConnection in -lICE... " >&6; }
7602if test "${ac_cv_lib_ICE_IceOpenConnection+set}" = set; then :
7603  $as_echo_n "(cached) " >&6
7604else
7605  ac_check_lib_save_LIBS=$LIBS
7606LIBS="-lICE $X_EXTRA_LIBS $LIBS"
7607cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7608/* end confdefs.h.  */
7609
7610/* Override any GCC internal prototype to avoid an error.
7611   Use char because int might match the return type of a GCC
7612   builtin and then its argument prototype would still apply.  */
7613#ifdef __cplusplus
7614extern "C"
7615#endif
7616char IceOpenConnection ();
7617int
7618main ()
7619{
7620return IceOpenConnection ();
7621  ;
7622  return 0;
7623}
7624_ACEOF
7625if ac_fn_c_try_link "$LINENO"; then :
7626  ac_cv_lib_ICE_IceOpenConnection=yes
7627else
7628  ac_cv_lib_ICE_IceOpenConnection=no
7629fi
7630rm -f core conftest.err conftest.$ac_objext \
7631    conftest$ac_exeext conftest.$ac_ext
7632LIBS=$ac_check_lib_save_LIBS
7633fi
7634{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceOpenConnection" >&5
7635$as_echo "$ac_cv_lib_ICE_IceOpenConnection" >&6; }
7636if test "x$ac_cv_lib_ICE_IceOpenConnection" = x""yes; then :
7637  X_EXTRA_LIBS="$X_EXTRA_LIBS -lSM -lICE"
7638fi
7639
7640
7641        LDFLAGS="$X_LIBS $ac_save_LDFLAGS"
7642    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmCreatePixmapFromData in -lXpm" >&5
7643$as_echo_n "checking for XpmCreatePixmapFromData in -lXpm... " >&6; }
7644if test "${ac_cv_lib_Xpm_XpmCreatePixmapFromData+set}" = set; then :
7645  $as_echo_n "(cached) " >&6
7646else
7647  ac_check_lib_save_LIBS=$LIBS
7648LIBS="-lXpm -lXt $X_PRE_LIBS -lXpm -lX11 $X_EXTRA_LIBS $LIBS"
7649cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7650/* end confdefs.h.  */
7651
7652/* Override any GCC internal prototype to avoid an error.
7653   Use char because int might match the return type of a GCC
7654   builtin and then its argument prototype would still apply.  */
7655#ifdef __cplusplus
7656extern "C"
7657#endif
7658char XpmCreatePixmapFromData ();
7659int
7660main ()
7661{
7662return XpmCreatePixmapFromData ();
7663  ;
7664  return 0;
7665}
7666_ACEOF
7667if ac_fn_c_try_link "$LINENO"; then :
7668  ac_cv_lib_Xpm_XpmCreatePixmapFromData=yes
7669else
7670  ac_cv_lib_Xpm_XpmCreatePixmapFromData=no
7671fi
7672rm -f core conftest.err conftest.$ac_objext \
7673    conftest$ac_exeext conftest.$ac_ext
7674LIBS=$ac_check_lib_save_LIBS
7675fi
7676{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmCreatePixmapFromData" >&5
7677$as_echo "$ac_cv_lib_Xpm_XpmCreatePixmapFromData" >&6; }
7678if test "x$ac_cv_lib_Xpm_XpmCreatePixmapFromData" = x""yes; then :
7679  X_PRE_LIBS="$X_PRE_LIBS -lXpm"
7680fi
7681
7682
7683        { $as_echo "$as_me:${as_lineno-$LINENO}: checking if X11 header files implicitly declare return values" >&5
7684$as_echo_n "checking if X11 header files implicitly declare return values... " >&6; }
7685    cflags_save=$CFLAGS
7686        if test "$GCC" = yes; then
7687      CFLAGS="$CFLAGS $X_CFLAGS -Werror"
7688    else
7689      CFLAGS="$CFLAGS $X_CFLAGS"
7690    fi
7691    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7692/* end confdefs.h.  */
7693#include <X11/Xlib.h>
7694int
7695main ()
7696{
7697
7698  ;
7699  return 0;
7700}
7701_ACEOF
7702if ac_fn_c_try_compile "$LINENO"; then :
7703  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7704$as_echo "no" >&6; }
7705else
7706  CFLAGS="$CFLAGS -Wno-implicit-int"
7707	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7708/* end confdefs.h.  */
7709#include <X11/Xlib.h>
7710int
7711main ()
7712{
7713
7714  ;
7715  return 0;
7716}
7717_ACEOF
7718if ac_fn_c_try_compile "$LINENO"; then :
7719  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7720$as_echo "yes" >&6; }; cflags_save="$cflags_save -Wno-implicit-int"
7721else
7722  { $as_echo "$as_me:${as_lineno-$LINENO}: result: test failed" >&5
7723$as_echo "test failed" >&6; }
7724
7725fi
7726rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7727
7728fi
7729rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7730    CFLAGS=$cflags_save
7731
7732    LDFLAGS="$ac_save_LDFLAGS"
7733
7734    { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of wchar_t is 2 bytes" >&5
7735$as_echo_n "checking size of wchar_t is 2 bytes... " >&6; }
7736    if test "${ac_cv_small_wchar_t+set}" = set; then :
7737  $as_echo_n "(cached) " >&6
7738else
7739  if test "$cross_compiling" = yes; then :
7740  as_fn_error "failed to compile test program" "$LINENO" 5
7741else
7742  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7743/* end confdefs.h.  */
7744
7745#include <X11/Xlib.h>
7746#if STDC_HEADERS
7747# include <stdlib.h>
7748# include <stddef.h>
7749#endif
7750		main()
7751		{
7752		  if (sizeof(wchar_t) <= 2)
7753		    exit(1);
7754		  exit(0);
7755		}
7756_ACEOF
7757if ac_fn_c_try_run "$LINENO"; then :
7758  ac_cv_small_wchar_t="no"
7759else
7760  ac_cv_small_wchar_t="yes"
7761fi
7762rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7763  conftest.$ac_objext conftest.beam conftest.$ac_ext
7764fi
7765
7766fi
7767
7768    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_small_wchar_t" >&5
7769$as_echo "$ac_cv_small_wchar_t" >&6; }
7770    if test "x$ac_cv_small_wchar_t" = "xyes" ; then
7771      $as_echo "#define SMALL_WCHAR_T 1" >>confdefs.h
7772
7773    fi
7774
7775  fi
7776fi
7777
7778test "x$with_x" = xno -a "x$MACOSX" != "xyes" -a "x$QNX" != "xyes" && enable_gui=no
7779
7780{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-gui argument" >&5
7781$as_echo_n "checking --enable-gui argument... " >&6; }
7782# Check whether --enable-gui was given.
7783if test "${enable_gui+set}" = set; then :
7784  enableval=$enable_gui;
7785else
7786  enable_gui="auto"
7787fi
7788
7789
7790enable_gui_canon=`echo "_$enable_gui" | \
7791	sed 's/[ _+-]//g;y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
7792
7793SKIP_GTK2=YES
7794SKIP_GNOME=YES
7795SKIP_MOTIF=YES
7796SKIP_ATHENA=YES
7797SKIP_NEXTAW=YES
7798SKIP_PHOTON=YES
7799SKIP_CARBON=YES
7800GUITYPE=NONE
7801
7802if test "x$QNX" = "xyes" -a "x$with_x" = "xno" ; then
7803  SKIP_PHOTON=
7804  case "$enable_gui_canon" in
7805    no)		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no GUI support" >&5
7806$as_echo "no GUI support" >&6; }
7807		SKIP_PHOTON=YES ;;
7808    yes|"")	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes - automatic GUI support" >&5
7809$as_echo "yes - automatic GUI support" >&6; } ;;
7810    auto)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: auto - automatic GUI support" >&5
7811$as_echo "auto - automatic GUI support" >&6; } ;;
7812    photon)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Photon GUI support" >&5
7813$as_echo "Photon GUI support" >&6; } ;;
7814    *)		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Sorry, $enable_gui GUI is not supported" >&5
7815$as_echo "Sorry, $enable_gui GUI is not supported" >&6; }
7816		SKIP_PHOTON=YES ;;
7817  esac
7818
7819elif test "x$MACOSX" = "xyes" -a "x$with_x" = "xno" ; then
7820  SKIP_CARBON=
7821  case "$enable_gui_canon" in
7822    no)		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no GUI support" >&5
7823$as_echo "no GUI support" >&6; }
7824		SKIP_CARBON=YES ;;
7825    yes|"")	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes - automatic GUI support" >&5
7826$as_echo "yes - automatic GUI support" >&6; } ;;
7827    auto)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: auto - Carbon GUI is outdated - disable GUI support" >&5
7828$as_echo "auto - Carbon GUI is outdated - disable GUI support" >&6; }
7829		SKIP_CARBON=YES ;;
7830    carbon)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Carbon GUI support" >&5
7831$as_echo "Carbon GUI support" >&6; } ;;
7832    *)		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Sorry, $enable_gui GUI is not supported" >&5
7833$as_echo "Sorry, $enable_gui GUI is not supported" >&6; }
7834		SKIP_CARBON=YES ;;
7835  esac
7836
7837else
7838
7839  case "$enable_gui_canon" in
7840    no|none)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no GUI support" >&5
7841$as_echo "no GUI support" >&6; } ;;
7842    yes|""|auto)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes/auto - automatic GUI support" >&5
7843$as_echo "yes/auto - automatic GUI support" >&6; }
7844		SKIP_GTK2=
7845		SKIP_GNOME=
7846		SKIP_MOTIF=
7847		SKIP_ATHENA=
7848		SKIP_NEXTAW=
7849		SKIP_CARBON=;;
7850    gtk2)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: GTK+ 2.x GUI support" >&5
7851$as_echo "GTK+ 2.x GUI support" >&6; }
7852		SKIP_GTK2=;;
7853    gnome2)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: GNOME 2.x GUI support" >&5
7854$as_echo "GNOME 2.x GUI support" >&6; }
7855		SKIP_GNOME=
7856		SKIP_GTK2=;;
7857    motif)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Motif GUI support" >&5
7858$as_echo "Motif GUI support" >&6; }
7859		SKIP_MOTIF=;;
7860    athena)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Athena GUI support" >&5
7861$as_echo "Athena GUI support" >&6; }
7862		SKIP_ATHENA=;;
7863    nextaw)	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: neXtaw GUI support" >&5
7864$as_echo "neXtaw GUI support" >&6; }
7865		SKIP_NEXTAW=;;
7866    *)		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Sorry, $enable_gui GUI is not supported" >&5
7867$as_echo "Sorry, $enable_gui GUI is not supported" >&6; } ;;
7868  esac
7869
7870fi
7871
7872if test "x$SKIP_GTK2" != "xYES" -a "$enable_gui_canon" != "gtk2" \
7873				-a "$enable_gui_canon" != "gnome2"; then
7874  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether or not to look for GTK+ 2" >&5
7875$as_echo_n "checking whether or not to look for GTK+ 2... " >&6; }
7876  # Check whether --enable-gtk2-check was given.
7877if test "${enable_gtk2_check+set}" = set; then :
7878  enableval=$enable_gtk2_check;
7879else
7880  enable_gtk2_check="yes"
7881fi
7882
7883  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_gtk2_check" >&5
7884$as_echo "$enable_gtk2_check" >&6; }
7885  if test "x$enable_gtk2_check" = "xno"; then
7886    SKIP_GTK2=YES
7887    SKIP_GNOME=YES
7888  fi
7889fi
7890
7891if test "x$SKIP_GNOME" != "xYES" -a "$enable_gui_canon" != "gnome2"; then
7892  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether or not to look for GNOME" >&5
7893$as_echo_n "checking whether or not to look for GNOME... " >&6; }
7894  # Check whether --enable-gnome-check was given.
7895if test "${enable_gnome_check+set}" = set; then :
7896  enableval=$enable_gnome_check;
7897else
7898  enable_gnome_check="no"
7899fi
7900
7901  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_gnome_check" >&5
7902$as_echo "$enable_gnome_check" >&6; }
7903  if test "x$enable_gnome_check" = "xno"; then
7904    SKIP_GNOME=YES
7905  fi
7906fi
7907
7908if test "x$SKIP_MOTIF" != "xYES" -a "$enable_gui_canon" != "motif"; then
7909  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether or not to look for Motif" >&5
7910$as_echo_n "checking whether or not to look for Motif... " >&6; }
7911  # Check whether --enable-motif-check was given.
7912if test "${enable_motif_check+set}" = set; then :
7913  enableval=$enable_motif_check;
7914else
7915  enable_motif_check="yes"
7916fi
7917
7918  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_motif_check" >&5
7919$as_echo "$enable_motif_check" >&6; }
7920  if test "x$enable_motif_check" = "xno"; then
7921    SKIP_MOTIF=YES
7922  fi
7923fi
7924
7925if test "x$SKIP_ATHENA" != "xYES" -a "$enable_gui_canon" != "athena"; then
7926  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether or not to look for Athena" >&5
7927$as_echo_n "checking whether or not to look for Athena... " >&6; }
7928  # Check whether --enable-athena-check was given.
7929if test "${enable_athena_check+set}" = set; then :
7930  enableval=$enable_athena_check;
7931else
7932  enable_athena_check="yes"
7933fi
7934
7935  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_athena_check" >&5
7936$as_echo "$enable_athena_check" >&6; }
7937  if test "x$enable_athena_check" = "xno"; then
7938    SKIP_ATHENA=YES
7939  fi
7940fi
7941
7942if test "x$SKIP_NEXTAW" != "xYES" -a "$enable_gui_canon" != "nextaw"; then
7943  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether or not to look for neXtaw" >&5
7944$as_echo_n "checking whether or not to look for neXtaw... " >&6; }
7945  # Check whether --enable-nextaw-check was given.
7946if test "${enable_nextaw_check+set}" = set; then :
7947  enableval=$enable_nextaw_check;
7948else
7949  enable_nextaw_check="yes"
7950fi
7951
7952  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_nextaw_check" >&5
7953$as_echo "$enable_nextaw_check" >&6; };
7954  if test "x$enable_nextaw_check" = "xno"; then
7955    SKIP_NEXTAW=YES
7956  fi
7957fi
7958
7959if test "x$SKIP_CARBON" != "xYES" -a "$enable_gui_canon" != "carbon"; then
7960  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether or not to look for Carbon" >&5
7961$as_echo_n "checking whether or not to look for Carbon... " >&6; }
7962  # Check whether --enable-carbon-check was given.
7963if test "${enable_carbon_check+set}" = set; then :
7964  enableval=$enable_carbon_check;
7965else
7966  enable_carbon_check="yes"
7967fi
7968
7969  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_carbon_check" >&5
7970$as_echo "$enable_carbon_check" >&6; };
7971  if test "x$enable_carbon_check" = "xno"; then
7972    SKIP_CARBON=YES
7973  fi
7974fi
7975
7976
7977if test "x$MACOSX" = "xyes" -a -z "$SKIP_CARBON" -a "x$CARBON" = "xyes"; then
7978  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Carbon GUI" >&5
7979$as_echo_n "checking for Carbon GUI... " >&6; }
7980    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7981$as_echo "yes" >&6; };
7982  GUITYPE=CARBONGUI
7983  if test "$VIMNAME" = "vim"; then
7984    VIMNAME=Vim
7985  fi
7986
7987  if test "x$MACARCH" = "xboth"; then
7988    CPPFLAGS="$CPPFLAGS -I$DEVELOPER_DIR/SDKs/MacOSX10.4u.sdk/Developer/Headers/FlatCarbon"
7989  else
7990    CPPFLAGS="$CPPFLAGS -I$DEVELOPER_DIR/Headers/FlatCarbon"
7991  fi
7992
7993    if test x$prefix = xNONE; then
7994    prefix=/Applications
7995  fi
7996
7997    datadir='${prefix}/Vim.app/Contents/Resources'
7998
7999    SKIP_GTK2=YES;
8000  SKIP_GNOME=YES;
8001  SKIP_MOTIF=YES;
8002  SKIP_ATHENA=YES;
8003  SKIP_NEXTAW=YES;
8004  SKIP_PHOTON=YES;
8005  SKIP_CARBON=YES
8006fi
8007
8008
8009
8010
8011
8012
8013
8014
8015if test -z "$SKIP_GTK2"; then
8016
8017  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-gtktest argument" >&5
8018$as_echo_n "checking --disable-gtktest argument... " >&6; }
8019  # Check whether --enable-gtktest was given.
8020if test "${enable_gtktest+set}" = set; then :
8021  enableval=$enable_gtktest;
8022else
8023  enable_gtktest=yes
8024fi
8025
8026  if test "x$enable_gtktest" = "xyes" ; then
8027    { $as_echo "$as_me:${as_lineno-$LINENO}: result: gtk test enabled" >&5
8028$as_echo "gtk test enabled" >&6; }
8029  else
8030    { $as_echo "$as_me:${as_lineno-$LINENO}: result: gtk test disabled" >&5
8031$as_echo "gtk test disabled" >&6; }
8032  fi
8033
8034  if test "X$PKG_CONFIG" = "X"; then
8035    # Extract the first word of "pkg-config", so it can be a program name with args.
8036set dummy pkg-config; ac_word=$2
8037{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8038$as_echo_n "checking for $ac_word... " >&6; }
8039if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8040  $as_echo_n "(cached) " >&6
8041else
8042  case $PKG_CONFIG in
8043  [\\/]* | ?:[\\/]*)
8044  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8045  ;;
8046  *)
8047  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8048for as_dir in $PATH
8049do
8050  IFS=$as_save_IFS
8051  test -z "$as_dir" && as_dir=.
8052    for ac_exec_ext in '' $ac_executable_extensions; do
8053  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8054    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8055    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8056    break 2
8057  fi
8058done
8059  done
8060IFS=$as_save_IFS
8061
8062  test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8063  ;;
8064esac
8065fi
8066PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8067if test -n "$PKG_CONFIG"; then
8068  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8069$as_echo "$PKG_CONFIG" >&6; }
8070else
8071  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8072$as_echo "no" >&6; }
8073fi
8074
8075
8076  fi
8077
8078  if test "x$PKG_CONFIG" != "xno"; then
8079
8080  if test "X$GTK_CONFIG" != "Xno" -o "X$PKG_CONFIG" != "Xno"; then
8081  {
8082    min_gtk_version=2.2.0
8083    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTK - version >= $min_gtk_version" >&5
8084$as_echo_n "checking for GTK - version >= $min_gtk_version... " >&6; }
8085    no_gtk=""
8086    if (test "X$SKIP_GTK2" != "XYES" -a "X$PKG_CONFIG" != "Xno") \
8087	  && $PKG_CONFIG --exists gtk+-2.0; then
8088    {
8089                        GTK_CFLAGS=`$PKG_CONFIG --cflags gtk+-2.0`
8090      GTK_LIBDIR=`$PKG_CONFIG --libs-only-L gtk+-2.0`
8091      GTK_LIBS=`$PKG_CONFIG --libs gtk+-2.0`
8092      gtk_major_version=`$PKG_CONFIG --modversion gtk+-2.0 | \
8093	     sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\)/\1/'`
8094      gtk_minor_version=`$PKG_CONFIG --modversion gtk+-2.0 | \
8095	     sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\)/\2/'`
8096      gtk_micro_version=`$PKG_CONFIG --modversion gtk+-2.0 | \
8097	     sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\)/\3/'`
8098    }
8099    else
8100      no_gtk=yes
8101    fi
8102
8103    if test "x$enable_gtktest" = "xyes" -a "x$no_gtk" = "x"; then
8104    {
8105      ac_save_CFLAGS="$CFLAGS"
8106      ac_save_LIBS="$LIBS"
8107      CFLAGS="$CFLAGS $GTK_CFLAGS"
8108      LIBS="$LIBS $GTK_LIBS"
8109
8110                        rm -f conf.gtktest
8111      if test "$cross_compiling" = yes; then :
8112  echo $ac_n "cross compiling; assumed OK... $ac_c"
8113else
8114  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8115/* end confdefs.h.  */
8116
8117#include <gtk/gtk.h>
8118#include <stdio.h>
8119#if STDC_HEADERS
8120# include <stdlib.h>
8121# include <stddef.h>
8122#endif
8123
8124int
8125main ()
8126{
8127int major, minor, micro;
8128char *tmp_version;
8129
8130system ("touch conf.gtktest");
8131
8132/* HP/UX 9 (%@#!) writes to sscanf strings */
8133tmp_version = g_strdup("$min_gtk_version");
8134if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
8135   printf("%s, bad version string\n", "$min_gtk_version");
8136   exit(1);
8137 }
8138
8139if ((gtk_major_version > major) ||
8140    ((gtk_major_version == major) && (gtk_minor_version > minor)) ||
8141    ((gtk_major_version == major) && (gtk_minor_version == minor) &&
8142				     (gtk_micro_version >= micro)))
8143{
8144    return 0;
8145}
8146return 1;
8147}
8148
8149_ACEOF
8150if ac_fn_c_try_run "$LINENO"; then :
8151
8152else
8153  no_gtk=yes
8154fi
8155rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8156  conftest.$ac_objext conftest.beam conftest.$ac_ext
8157fi
8158
8159      CFLAGS="$ac_save_CFLAGS"
8160      LIBS="$ac_save_LIBS"
8161    }
8162    fi
8163    if test "x$no_gtk" = x ; then
8164      if test "x$enable_gtktest" = "xyes"; then
8165	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; found version $gtk_major_version.$gtk_minor_version.$gtk_micro_version" >&5
8166$as_echo "yes; found version $gtk_major_version.$gtk_minor_version.$gtk_micro_version" >&6; }
8167      else
8168	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: found version $gtk_major_version.$gtk_minor_version.$gtk_micro_version" >&5
8169$as_echo "found version $gtk_major_version.$gtk_minor_version.$gtk_micro_version" >&6; }
8170      fi
8171      GUI_LIB_LOC="$GTK_LIBDIR"
8172		 GTK_LIBNAME="$GTK_LIBS"
8173		GUI_INC_LOC="$GTK_CFLAGS"
8174    else
8175    {
8176      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8177$as_echo "no" >&6; }
8178      GTK_CFLAGS=""
8179      GTK_LIBS=""
8180      :
8181    }
8182    fi
8183  }
8184  else
8185    GTK_CFLAGS=""
8186    GTK_LIBS=""
8187    :
8188  fi
8189
8190
8191  rm -f conf.gtktest
8192
8193    if test "x$GTK_CFLAGS" != "x"; then
8194      SKIP_ATHENA=YES
8195      SKIP_NEXTAW=YES
8196      SKIP_MOTIF=YES
8197      GUITYPE=GTK
8198
8199    fi
8200  fi
8201  if test "x$GUITYPE" = "xGTK"; then
8202    if test "$gtk_minor_version" = 1 -a "0$gtk_micro_version" -ge 1 \
8203	|| test "0$gtk_minor_version" -ge 2; then
8204      $as_echo "#define HAVE_GTK_MULTIHEAD 1" >>confdefs.h
8205
8206    fi
8207                if test -z "$SKIP_GNOME"; then
8208    {
8209
8210
8211
8212
8213
8214
8215# Check whether --with-gnome-includes was given.
8216if test "${with_gnome_includes+set}" = set; then :
8217  withval=$with_gnome_includes; CFLAGS="$CFLAGS -I$withval"
8218
8219fi
8220
8221
8222
8223# Check whether --with-gnome-libs was given.
8224if test "${with_gnome_libs+set}" = set; then :
8225  withval=$with_gnome_libs; LDFLAGS="$LDFLAGS -L$withval" gnome_prefix=$withval
8226
8227fi
8228
8229
8230
8231# Check whether --with-gnome was given.
8232if test "${with_gnome+set}" = set; then :
8233  withval=$with_gnome; if test x$withval = xyes; then
8234      want_gnome=yes
8235      have_gnome=yes
8236    else
8237      if test "x$withval" = xno; then
8238	want_gnome=no
8239      else
8240	want_gnome=yes
8241	LDFLAGS="$LDFLAGS -L$withval/lib"
8242	CFLAGS="$CFLAGS -I$withval/include"
8243	gnome_prefix=$withval/lib
8244      fi
8245    fi
8246else
8247  want_gnome=yes
8248fi
8249
8250
8251  if test "x$want_gnome" = xyes; then
8252  {
8253    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libgnomeui-2.0" >&5
8254$as_echo_n "checking for libgnomeui-2.0... " >&6; }
8255    if $PKG_CONFIG --exists libgnomeui-2.0; then
8256      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8257$as_echo "yes" >&6; }
8258      GNOME_LIBS=`$PKG_CONFIG --libs-only-l libgnomeui-2.0`
8259      GNOME_LIBDIR=`$PKG_CONFIG --libs-only-L libgnomeui-2.0`
8260      GNOME_INCLUDEDIR=`$PKG_CONFIG --cflags libgnomeui-2.0`
8261
8262                  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FreeBSD" >&5
8263$as_echo_n "checking for FreeBSD... " >&6; }
8264      if test "`(uname) 2>/dev/null`" = FreeBSD; then
8265	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8266$as_echo "yes" >&6; }
8267	GNOME_INCLUDEDIR="$GNOME_INCLUDEDIR -D_THREAD_SAFE"
8268	GNOME_LIBS="$GNOME_LIBS -pthread"
8269      else
8270	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8271$as_echo "no" >&6; }
8272      fi
8273      have_gnome=yes
8274    else
8275      { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8276$as_echo "not found" >&6; }
8277      if test "x" = xfail; then
8278	as_fn_error "Could not find libgnomeui-2.0 via pkg-config" "$LINENO" 5
8279      fi
8280    fi
8281  }
8282  fi
8283
8284      if test "x$have_gnome" = xyes ; then
8285	$as_echo "#define FEAT_GUI_GNOME 1" >>confdefs.h
8286
8287	GUI_INC_LOC="$GUI_INC_LOC $GNOME_INCLUDEDIR"
8288	GTK_LIBNAME="$GTK_LIBNAME $GNOME_LIBDIR $GNOME_LIBS"
8289      fi
8290    }
8291    fi
8292  fi
8293fi
8294
8295
8296if test -z "$SKIP_MOTIF"; then
8297  gui_XXX="/usr/XXX/Motif* /usr/Motif*/XXX /usr/XXX /usr/shlib /usr/X11*/XXX /usr/XXX/X11* /usr/dt/XXX /local/Motif*/XXX /local/XXX/Motif* /usr/local/Motif*/XXX /usr/local/XXX/Motif* /usr/local/XXX /usr/local/X11*/XXX /usr/local/LessTif/Motif*/XXX $MOTIFHOME/XXX"
8298    GUI_INC_LOC="`echo $GUI_INC_LOC|sed 's%-I%%g'`"
8299
8300  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for location of Motif GUI includes" >&5
8301$as_echo_n "checking for location of Motif GUI includes... " >&6; }
8302  gui_includes="`echo $x_includes|sed 's%/^/^/*$%%'` `echo "$gui_XXX" | sed s/XXX/include/g` $GUI_INC_LOC"
8303  GUI_INC_LOC=
8304  for try in $gui_includes; do
8305    if test -f "$try/Xm/Xm.h"; then
8306      GUI_INC_LOC=$try
8307    fi
8308  done
8309  if test -n "$GUI_INC_LOC"; then
8310    if test "$GUI_INC_LOC" = /usr/include; then
8311      GUI_INC_LOC=
8312      { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default path" >&5
8313$as_echo "in default path" >&6; }
8314    else
8315      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUI_INC_LOC" >&5
8316$as_echo "$GUI_INC_LOC" >&6; }
8317    fi
8318  else
8319    { $as_echo "$as_me:${as_lineno-$LINENO}: result: <not found>" >&5
8320$as_echo "<not found>" >&6; }
8321    SKIP_MOTIF=YES
8322  fi
8323fi
8324
8325
8326if test -z "$SKIP_MOTIF"; then
8327  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-motif-lib argument" >&5
8328$as_echo_n "checking --with-motif-lib argument... " >&6; }
8329
8330# Check whether --with-motif-lib was given.
8331if test "${with_motif_lib+set}" = set; then :
8332  withval=$with_motif_lib;  MOTIF_LIBNAME="${withval}"
8333fi
8334
8335
8336  if test -n "$MOTIF_LIBNAME"; then
8337    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MOTIF_LIBNAME" >&5
8338$as_echo "$MOTIF_LIBNAME" >&6; }
8339    GUI_LIB_LOC=
8340  else
8341    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8342$as_echo "no" >&6; }
8343
8344        GUI_LIB_LOC="`echo $GUI_LIB_LOC|sed 's%-L%%g'`"
8345
8346    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for location of Motif GUI libs" >&5
8347$as_echo_n "checking for location of Motif GUI libs... " >&6; }
8348    gui_libs="`echo $x_libraries|sed 's%/^/^/*$%%'` `echo "$gui_XXX" | sed s/XXX/lib/g` `echo "$GUI_INC_LOC" | sed s/include/lib/` $GUI_LIB_LOC"
8349    GUI_LIB_LOC=
8350    for try in $gui_libs; do
8351      for libtry in "$try"/libXm.a "$try"/libXm.so* "$try"/libXm.sl "$try"/libXm.dylib; do
8352	if test -f "$libtry"; then
8353	  GUI_LIB_LOC=$try
8354	fi
8355      done
8356    done
8357    if test -n "$GUI_LIB_LOC"; then
8358            if test "$GUI_LIB_LOC" = /usr/lib; then
8359	GUI_LIB_LOC=
8360	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: in default path" >&5
8361$as_echo "in default path" >&6; }
8362      else
8363	if test -n "$GUI_LIB_LOC"; then
8364	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUI_LIB_LOC" >&5
8365$as_echo "$GUI_LIB_LOC" >&6; }
8366	  if test "`(uname) 2>/dev/null`" = SunOS &&
8367					 uname -r | grep '^5' >/dev/null; then
8368	    GUI_LIB_LOC="$GUI_LIB_LOC -R $GUI_LIB_LOC"
8369	  fi
8370	fi
8371      fi
8372      MOTIF_LIBNAME=-lXm
8373    else
8374      { $as_echo "$as_me:${as_lineno-$LINENO}: result: <not found>" >&5
8375$as_echo "<not found>" >&6; }
8376      SKIP_MOTIF=YES
8377    fi
8378  fi
8379fi
8380
8381if test -z "$SKIP_MOTIF"; then
8382  SKIP_ATHENA=YES
8383  SKIP_NEXTAW=YES
8384  GUITYPE=MOTIF
8385
8386fi
8387
8388
8389GUI_X_LIBS=
8390
8391if test -z "$SKIP_ATHENA"; then
8392  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Athena header files can be found" >&5
8393$as_echo_n "checking if Athena header files can be found... " >&6; }
8394  cflags_save=$CFLAGS
8395  CFLAGS="$CFLAGS $X_CFLAGS"
8396  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8397/* end confdefs.h.  */
8398
8399#include <X11/Intrinsic.h>
8400#include <X11/Xaw/Paned.h>
8401int
8402main ()
8403{
8404
8405  ;
8406  return 0;
8407}
8408_ACEOF
8409if ac_fn_c_try_compile "$LINENO"; then :
8410  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8411$as_echo "yes" >&6; }
8412else
8413  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8414$as_echo "no" >&6; }; SKIP_ATHENA=YES
8415fi
8416rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8417  CFLAGS=$cflags_save
8418fi
8419
8420if test -z "$SKIP_ATHENA"; then
8421  GUITYPE=ATHENA
8422fi
8423
8424if test -z "$SKIP_NEXTAW"; then
8425  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if neXtaw header files can be found" >&5
8426$as_echo_n "checking if neXtaw header files can be found... " >&6; }
8427  cflags_save=$CFLAGS
8428  CFLAGS="$CFLAGS $X_CFLAGS"
8429  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8430/* end confdefs.h.  */
8431
8432#include <X11/Intrinsic.h>
8433#include <X11/neXtaw/Paned.h>
8434int
8435main ()
8436{
8437
8438  ;
8439  return 0;
8440}
8441_ACEOF
8442if ac_fn_c_try_compile "$LINENO"; then :
8443  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8444$as_echo "yes" >&6; }
8445else
8446  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8447$as_echo "no" >&6; }; SKIP_NEXTAW=YES
8448fi
8449rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8450  CFLAGS=$cflags_save
8451fi
8452
8453if test -z "$SKIP_NEXTAW"; then
8454  GUITYPE=NEXTAW
8455fi
8456
8457if test -z "$SKIP_ATHENA" -o -z "$SKIP_NEXTAW" -o -z "$SKIP_MOTIF"; then
8458      if test -n "$GUI_INC_LOC"; then
8459    GUI_INC_LOC=-I"`echo $GUI_INC_LOC|sed 's%-I%%'`"
8460  fi
8461  if test -n "$GUI_LIB_LOC"; then
8462    GUI_LIB_LOC=-L"`echo $GUI_LIB_LOC|sed 's%-L%%'`"
8463  fi
8464
8465    ldflags_save=$LDFLAGS
8466  LDFLAGS="$X_LIBS $LDFLAGS"
8467  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
8468$as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
8469if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
8470  $as_echo_n "(cached) " >&6
8471else
8472  ac_check_lib_save_LIBS=$LIBS
8473LIBS="-lXext -lXt $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
8474cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8475/* end confdefs.h.  */
8476
8477/* Override any GCC internal prototype to avoid an error.
8478   Use char because int might match the return type of a GCC
8479   builtin and then its argument prototype would still apply.  */
8480#ifdef __cplusplus
8481extern "C"
8482#endif
8483char XShapeQueryExtension ();
8484int
8485main ()
8486{
8487return XShapeQueryExtension ();
8488  ;
8489  return 0;
8490}
8491_ACEOF
8492if ac_fn_c_try_link "$LINENO"; then :
8493  ac_cv_lib_Xext_XShapeQueryExtension=yes
8494else
8495  ac_cv_lib_Xext_XShapeQueryExtension=no
8496fi
8497rm -f core conftest.err conftest.$ac_objext \
8498    conftest$ac_exeext conftest.$ac_ext
8499LIBS=$ac_check_lib_save_LIBS
8500fi
8501{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
8502$as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
8503if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
8504  GUI_X_LIBS="-lXext"
8505fi
8506
8507    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wslen in -lw" >&5
8508$as_echo_n "checking for wslen in -lw... " >&6; }
8509if test "${ac_cv_lib_w_wslen+set}" = set; then :
8510  $as_echo_n "(cached) " >&6
8511else
8512  ac_check_lib_save_LIBS=$LIBS
8513LIBS="-lw $GUI_X_LIBS -lXt $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
8514cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8515/* end confdefs.h.  */
8516
8517/* Override any GCC internal prototype to avoid an error.
8518   Use char because int might match the return type of a GCC
8519   builtin and then its argument prototype would still apply.  */
8520#ifdef __cplusplus
8521extern "C"
8522#endif
8523char wslen ();
8524int
8525main ()
8526{
8527return wslen ();
8528  ;
8529  return 0;
8530}
8531_ACEOF
8532if ac_fn_c_try_link "$LINENO"; then :
8533  ac_cv_lib_w_wslen=yes
8534else
8535  ac_cv_lib_w_wslen=no
8536fi
8537rm -f core conftest.err conftest.$ac_objext \
8538    conftest$ac_exeext conftest.$ac_ext
8539LIBS=$ac_check_lib_save_LIBS
8540fi
8541{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_w_wslen" >&5
8542$as_echo "$ac_cv_lib_w_wslen" >&6; }
8543if test "x$ac_cv_lib_w_wslen" = x""yes; then :
8544  X_EXTRA_LIBS="$X_EXTRA_LIBS -lw"
8545fi
8546
8547  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlsym in -ldl" >&5
8548$as_echo_n "checking for dlsym in -ldl... " >&6; }
8549if test "${ac_cv_lib_dl_dlsym+set}" = set; then :
8550  $as_echo_n "(cached) " >&6
8551else
8552  ac_check_lib_save_LIBS=$LIBS
8553LIBS="-ldl $GUI_X_LIBS -lXt $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
8554cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8555/* end confdefs.h.  */
8556
8557/* Override any GCC internal prototype to avoid an error.
8558   Use char because int might match the return type of a GCC
8559   builtin and then its argument prototype would still apply.  */
8560#ifdef __cplusplus
8561extern "C"
8562#endif
8563char dlsym ();
8564int
8565main ()
8566{
8567return dlsym ();
8568  ;
8569  return 0;
8570}
8571_ACEOF
8572if ac_fn_c_try_link "$LINENO"; then :
8573  ac_cv_lib_dl_dlsym=yes
8574else
8575  ac_cv_lib_dl_dlsym=no
8576fi
8577rm -f core conftest.err conftest.$ac_objext \
8578    conftest$ac_exeext conftest.$ac_ext
8579LIBS=$ac_check_lib_save_LIBS
8580fi
8581{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlsym" >&5
8582$as_echo "$ac_cv_lib_dl_dlsym" >&6; }
8583if test "x$ac_cv_lib_dl_dlsym" = x""yes; then :
8584  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldl"
8585fi
8586
8587  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuCreateStippledPixmap in -lXmu" >&5
8588$as_echo_n "checking for XmuCreateStippledPixmap in -lXmu... " >&6; }
8589if test "${ac_cv_lib_Xmu_XmuCreateStippledPixmap+set}" = set; then :
8590  $as_echo_n "(cached) " >&6
8591else
8592  ac_check_lib_save_LIBS=$LIBS
8593LIBS="-lXmu $GUI_X_LIBS -lXt $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
8594cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8595/* end confdefs.h.  */
8596
8597/* Override any GCC internal prototype to avoid an error.
8598   Use char because int might match the return type of a GCC
8599   builtin and then its argument prototype would still apply.  */
8600#ifdef __cplusplus
8601extern "C"
8602#endif
8603char XmuCreateStippledPixmap ();
8604int
8605main ()
8606{
8607return XmuCreateStippledPixmap ();
8608  ;
8609  return 0;
8610}
8611_ACEOF
8612if ac_fn_c_try_link "$LINENO"; then :
8613  ac_cv_lib_Xmu_XmuCreateStippledPixmap=yes
8614else
8615  ac_cv_lib_Xmu_XmuCreateStippledPixmap=no
8616fi
8617rm -f core conftest.err conftest.$ac_objext \
8618    conftest$ac_exeext conftest.$ac_ext
8619LIBS=$ac_check_lib_save_LIBS
8620fi
8621{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuCreateStippledPixmap" >&5
8622$as_echo "$ac_cv_lib_Xmu_XmuCreateStippledPixmap" >&6; }
8623if test "x$ac_cv_lib_Xmu_XmuCreateStippledPixmap" = x""yes; then :
8624  GUI_X_LIBS="-lXmu $GUI_X_LIBS"
8625fi
8626
8627  if test -z "$SKIP_MOTIF"; then
8628    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpEndJob in -lXp" >&5
8629$as_echo_n "checking for XpEndJob in -lXp... " >&6; }
8630if test "${ac_cv_lib_Xp_XpEndJob+set}" = set; then :
8631  $as_echo_n "(cached) " >&6
8632else
8633  ac_check_lib_save_LIBS=$LIBS
8634LIBS="-lXp $GUI_X_LIBS -lXm -lXt $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
8635cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8636/* end confdefs.h.  */
8637
8638/* Override any GCC internal prototype to avoid an error.
8639   Use char because int might match the return type of a GCC
8640   builtin and then its argument prototype would still apply.  */
8641#ifdef __cplusplus
8642extern "C"
8643#endif
8644char XpEndJob ();
8645int
8646main ()
8647{
8648return XpEndJob ();
8649  ;
8650  return 0;
8651}
8652_ACEOF
8653if ac_fn_c_try_link "$LINENO"; then :
8654  ac_cv_lib_Xp_XpEndJob=yes
8655else
8656  ac_cv_lib_Xp_XpEndJob=no
8657fi
8658rm -f core conftest.err conftest.$ac_objext \
8659    conftest$ac_exeext conftest.$ac_ext
8660LIBS=$ac_check_lib_save_LIBS
8661fi
8662{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpEndJob" >&5
8663$as_echo "$ac_cv_lib_Xp_XpEndJob" >&6; }
8664if test "x$ac_cv_lib_Xp_XpEndJob" = x""yes; then :
8665  GUI_X_LIBS="-lXp $GUI_X_LIBS"
8666fi
8667
8668  fi
8669  LDFLAGS=$ldflags_save
8670
8671    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra X11 defines" >&5
8672$as_echo_n "checking for extra X11 defines... " >&6; }
8673  NARROW_PROTO=
8674  rm -fr conftestdir
8675  if mkdir conftestdir; then
8676    cd conftestdir
8677    cat > Imakefile <<'EOF'
8678acfindx:
8679	@echo 'NARROW_PROTO="${PROTO_DEFINES}"'
8680EOF
8681    if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
8682      eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
8683    fi
8684    cd ..
8685    rm -fr conftestdir
8686  fi
8687  if test -z "$NARROW_PROTO"; then
8688    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8689$as_echo "no" >&6; }
8690  else
8691    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NARROW_PROTO" >&5
8692$as_echo "$NARROW_PROTO" >&6; }
8693  fi
8694
8695fi
8696
8697if test "$enable_xsmp" = "yes"; then
8698  cppflags_save=$CPPFLAGS
8699  CPPFLAGS="$CPPFLAGS $X_CFLAGS"
8700  for ac_header in X11/SM/SMlib.h
8701do :
8702  ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
8703if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
8704  cat >>confdefs.h <<_ACEOF
8705#define HAVE_X11_SM_SMLIB_H 1
8706_ACEOF
8707
8708fi
8709
8710done
8711
8712  CPPFLAGS=$cppflags_save
8713fi
8714
8715
8716if test -z "$SKIP_ATHENA" -o -z "$SKIP_NEXTAW" -o -z "$SKIP_MOTIF" -o -z "$SKIP_GTK2"; then
8717    cppflags_save=$CPPFLAGS
8718  CPPFLAGS="$CPPFLAGS $X_CFLAGS"
8719  for ac_header in X11/xpm.h X11/Sunkeysym.h
8720do :
8721  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8722ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8723eval as_val=\$$as_ac_Header
8724   if test "x$as_val" = x""yes; then :
8725  cat >>confdefs.h <<_ACEOF
8726#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8727_ACEOF
8728
8729fi
8730
8731done
8732
8733
8734    if test ! "$enable_xim" = "no"; then
8735    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XIMText in X11/Xlib.h" >&5
8736$as_echo_n "checking for XIMText in X11/Xlib.h... " >&6; }
8737    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8738/* end confdefs.h.  */
8739#include <X11/Xlib.h>
8740_ACEOF
8741if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8742  $EGREP "XIMText" >/dev/null 2>&1; then :
8743  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8744$as_echo "yes" >&6; }
8745else
8746  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no; xim has been disabled" >&5
8747$as_echo "no; xim has been disabled" >&6; }; enable_xim = "no"
8748fi
8749rm -f conftest*
8750
8751  fi
8752  CPPFLAGS=$cppflags_save
8753
8754    if test "$enable_xim" = "auto" -a "$enable_hangulinput" != "yes" \
8755		-a "x$GUITYPE" != "xNONE" ; then
8756    { $as_echo "$as_me:${as_lineno-$LINENO}: result: X GUI selected; xim has been enabled" >&5
8757$as_echo "X GUI selected; xim has been enabled" >&6; }
8758    enable_xim="yes"
8759  fi
8760fi
8761
8762if test -z "$SKIP_ATHENA" -o -z "$SKIP_NEXTAW" -o -z "$SKIP_MOTIF"; then
8763  cppflags_save=$CPPFLAGS
8764  CPPFLAGS="$CPPFLAGS $X_CFLAGS"
8765  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X11/Xmu/Editres.h" >&5
8766$as_echo_n "checking for X11/Xmu/Editres.h... " >&6; }
8767  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8768/* end confdefs.h.  */
8769
8770#include <X11/Intrinsic.h>
8771#include <X11/Xmu/Editres.h>
8772int
8773main ()
8774{
8775int i; i = 0;
8776  ;
8777  return 0;
8778}
8779_ACEOF
8780if ac_fn_c_try_compile "$LINENO"; then :
8781  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8782$as_echo "yes" >&6; }
8783		      $as_echo "#define HAVE_X11_XMU_EDITRES_H 1" >>confdefs.h
8784
8785else
8786  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8787$as_echo "no" >&6; }
8788fi
8789rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8790  CPPFLAGS=$cppflags_save
8791fi
8792
8793if test -z "$SKIP_MOTIF"; then
8794  cppflags_save=$CPPFLAGS
8795  CPPFLAGS="$CPPFLAGS $X_CFLAGS"
8796  if test "$zOSUnix" = "yes"; then
8797	xmheader="Xm/Xm.h"
8798  else
8799	xmheader="Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h
8800	   Xm/UnhighlightT.h Xm/Notebook.h"
8801  fi
8802  for ac_header in $xmheader
8803do :
8804  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8805ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8806eval as_val=\$$as_ac_Header
8807   if test "x$as_val" = x""yes; then :
8808  cat >>confdefs.h <<_ACEOF
8809#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8810_ACEOF
8811
8812fi
8813
8814done
8815
8816
8817  if test "x$ac_cv_header_Xm_XpmP_h" = "xyes"; then
8818        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmAttributes_21 in Xm/XpmP.h" >&5
8819$as_echo_n "checking for XpmAttributes_21 in Xm/XpmP.h... " >&6; }
8820    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8821/* end confdefs.h.  */
8822#include <Xm/XpmP.h>
8823int
8824main ()
8825{
8826XpmAttributes_21 attr;
8827  ;
8828  return 0;
8829}
8830_ACEOF
8831if ac_fn_c_try_compile "$LINENO"; then :
8832  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8833$as_echo "yes" >&6; }; $as_echo "#define XPMATTRIBUTES_TYPE XpmAttributes_21" >>confdefs.h
8834
8835else
8836  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8837$as_echo "no" >&6; }; $as_echo "#define XPMATTRIBUTES_TYPE XpmAttributes" >>confdefs.h
8838
8839
8840fi
8841rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8842  else
8843    $as_echo "#define XPMATTRIBUTES_TYPE XpmAttributes" >>confdefs.h
8844
8845  fi
8846  CPPFLAGS=$cppflags_save
8847fi
8848
8849if test "x$GUITYPE" = "xNONE" -a "$enable_xim" = "yes"; then
8850  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no GUI selected; xim has been disabled" >&5
8851$as_echo "no GUI selected; xim has been disabled" >&6; }
8852  enable_xim="no"
8853fi
8854if test "x$GUITYPE" = "xNONE" -a "$enable_fontset" = "yes"; then
8855  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no GUI selected; fontset has been disabled" >&5
8856$as_echo "no GUI selected; fontset has been disabled" >&6; }
8857  enable_fontset="no"
8858fi
8859if test "x$GUITYPE:$enable_fontset" = "xGTK:yes"; then
8860  { $as_echo "$as_me:${as_lineno-$LINENO}: result: GTK+ 2 GUI selected; fontset has been disabled" >&5
8861$as_echo "GTK+ 2 GUI selected; fontset has been disabled" >&6; }
8862  enable_fontset="no"
8863fi
8864
8865if test -z "$SKIP_PHOTON"; then
8866  GUITYPE=PHOTONGUI
8867fi
8868
8869
8870
8871
8872
8873
8874if test "$enable_workshop" = "yes" -a -n "$SKIP_MOTIF"; then
8875  as_fn_error "cannot use workshop without Motif" "$LINENO" 5
8876fi
8877
8878if test "$enable_xim" = "yes"; then
8879  $as_echo "#define FEAT_XIM 1" >>confdefs.h
8880
8881fi
8882if test "$enable_fontset" = "yes"; then
8883  $as_echo "#define FEAT_XFONTSET 1" >>confdefs.h
8884
8885fi
8886
8887
8888
8889{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGWIN environment" >&5
8890$as_echo_n "checking for CYGWIN environment... " >&6; }
8891case `uname` in
8892    CYGWIN*)    CYGWIN=yes; { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8893$as_echo "yes" >&6; }
8894                { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGWIN clipboard support" >&5
8895$as_echo_n "checking for CYGWIN clipboard support... " >&6; }
8896                if test "x$with_x" = "xno" ; then
8897                  OS_EXTRA_SRC=winclip.c; OS_EXTRA_OBJ=objects/winclip.o
8898                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8899$as_echo "yes" >&6; }
8900                  $as_echo "#define FEAT_CYGWIN_WIN32_CLIPBOARD 1" >>confdefs.h
8901
8902                else
8903                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no - using X11" >&5
8904$as_echo "no - using X11" >&6; }
8905                fi ;;
8906
8907    *)          CYGWIN=no; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8908$as_echo "no" >&6; };;
8909esac
8910
8911if test "$enable_hangulinput" = "yes"; then
8912  if test "x$GUITYPE" = "xNONE"; then
8913    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no GUI selected; hangul input has been disabled" >&5
8914$as_echo "no GUI selected; hangul input has been disabled" >&6; }
8915    enable_hangulinput=no
8916  else
8917    $as_echo "#define FEAT_HANGULIN 1" >>confdefs.h
8918
8919    HANGULIN_SRC=hangulin.c
8920
8921    HANGULIN_OBJ=objects/hangulin.o
8922
8923  fi
8924fi
8925
8926
8927{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether toupper is broken" >&5
8928$as_echo_n "checking whether toupper is broken... " >&6; }
8929if test "${vim_cv_toupper_broken+set}" = set; then :
8930  $as_echo_n "(cached) " >&6
8931else
8932
8933    if test "$cross_compiling" = yes; then :
8934
8935    as_fn_error "cross-compiling: please set 'vim_cv_toupper_broken'" "$LINENO" 5
8936
8937else
8938  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8939/* end confdefs.h.  */
8940
8941#include "confdefs.h"
8942#include <ctype.h>
8943#if STDC_HEADERS
8944# include <stdlib.h>
8945# include <stddef.h>
8946#endif
8947main() { exit(toupper('A') == 'A' && tolower('z') == 'z'); }
8948
8949_ACEOF
8950if ac_fn_c_try_run "$LINENO"; then :
8951
8952    vim_cv_toupper_broken=yes
8953
8954else
8955
8956    vim_cv_toupper_broken=no
8957
8958fi
8959rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8960  conftest.$ac_objext conftest.beam conftest.$ac_ext
8961fi
8962
8963fi
8964{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vim_cv_toupper_broken" >&5
8965$as_echo "$vim_cv_toupper_broken" >&6; }
8966
8967if test "x$vim_cv_toupper_broken" = "xyes" ; then
8968  $as_echo "#define BROKEN_TOUPPER 1" >>confdefs.h
8969
8970fi
8971
8972{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __DATE__ and __TIME__ work" >&5
8973$as_echo_n "checking whether __DATE__ and __TIME__ work... " >&6; }
8974cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8975/* end confdefs.h.  */
8976#include <stdio.h>
8977int
8978main ()
8979{
8980printf("(" __DATE__ " " __TIME__ ")");
8981  ;
8982  return 0;
8983}
8984_ACEOF
8985if ac_fn_c_try_compile "$LINENO"; then :
8986  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8987$as_echo "yes" >&6; }; $as_echo "#define HAVE_DATE_TIME 1" >>confdefs.h
8988
8989else
8990  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8991$as_echo "no" >&6; }
8992fi
8993rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8994
8995{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __attribute__((unused)) is allowed" >&5
8996$as_echo_n "checking whether __attribute__((unused)) is allowed... " >&6; }
8997cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8998/* end confdefs.h.  */
8999#include <stdio.h>
9000int
9001main ()
9002{
9003int x __attribute__((unused));
9004  ;
9005  return 0;
9006}
9007_ACEOF
9008if ac_fn_c_try_compile "$LINENO"; then :
9009  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9010$as_echo "yes" >&6; }; $as_echo "#define HAVE_ATTRIBUTE_UNUSED 1" >>confdefs.h
9011
9012else
9013  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9014$as_echo "no" >&6; }
9015fi
9016rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9017
9018ac_fn_c_check_header_mongrel "$LINENO" "elf.h" "ac_cv_header_elf_h" "$ac_includes_default"
9019if test "x$ac_cv_header_elf_h" = x""yes; then :
9020  HAS_ELF=1
9021fi
9022
9023
9024if test "$HAS_ELF" = 1; then
9025  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lelf" >&5
9026$as_echo_n "checking for main in -lelf... " >&6; }
9027if test "${ac_cv_lib_elf_main+set}" = set; then :
9028  $as_echo_n "(cached) " >&6
9029else
9030  ac_check_lib_save_LIBS=$LIBS
9031LIBS="-lelf  $LIBS"
9032cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9033/* end confdefs.h.  */
9034
9035
9036int
9037main ()
9038{
9039return main ();
9040  ;
9041  return 0;
9042}
9043_ACEOF
9044if ac_fn_c_try_link "$LINENO"; then :
9045  ac_cv_lib_elf_main=yes
9046else
9047  ac_cv_lib_elf_main=no
9048fi
9049rm -f core conftest.err conftest.$ac_objext \
9050    conftest$ac_exeext conftest.$ac_ext
9051LIBS=$ac_check_lib_save_LIBS
9052fi
9053{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_main" >&5
9054$as_echo "$ac_cv_lib_elf_main" >&6; }
9055if test "x$ac_cv_lib_elf_main" = x""yes; then :
9056  cat >>confdefs.h <<_ACEOF
9057#define HAVE_LIBELF 1
9058_ACEOF
9059
9060  LIBS="-lelf $LIBS"
9061
9062fi
9063
9064fi
9065
9066ac_header_dirent=no
9067for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
9068  as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
9069{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
9070$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
9071if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then :
9072  $as_echo_n "(cached) " >&6
9073else
9074  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9075/* end confdefs.h.  */
9076#include <sys/types.h>
9077#include <$ac_hdr>
9078
9079int
9080main ()
9081{
9082if ((DIR *) 0)
9083return 0;
9084  ;
9085  return 0;
9086}
9087_ACEOF
9088if ac_fn_c_try_compile "$LINENO"; then :
9089  eval "$as_ac_Header=yes"
9090else
9091  eval "$as_ac_Header=no"
9092fi
9093rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9094fi
9095eval ac_res=\$$as_ac_Header
9096	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9097$as_echo "$ac_res" >&6; }
9098eval as_val=\$$as_ac_Header
9099   if test "x$as_val" = x""yes; then :
9100  cat >>confdefs.h <<_ACEOF
9101#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
9102_ACEOF
9103
9104ac_header_dirent=$ac_hdr; break
9105fi
9106
9107done
9108# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
9109if test $ac_header_dirent = dirent.h; then
9110  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
9111$as_echo_n "checking for library containing opendir... " >&6; }
9112if test "${ac_cv_search_opendir+set}" = set; then :
9113  $as_echo_n "(cached) " >&6
9114else
9115  ac_func_search_save_LIBS=$LIBS
9116cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9117/* end confdefs.h.  */
9118
9119/* Override any GCC internal prototype to avoid an error.
9120   Use char because int might match the return type of a GCC
9121   builtin and then its argument prototype would still apply.  */
9122#ifdef __cplusplus
9123extern "C"
9124#endif
9125char opendir ();
9126int
9127main ()
9128{
9129return opendir ();
9130  ;
9131  return 0;
9132}
9133_ACEOF
9134for ac_lib in '' dir; do
9135  if test -z "$ac_lib"; then
9136    ac_res="none required"
9137  else
9138    ac_res=-l$ac_lib
9139    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9140  fi
9141  if ac_fn_c_try_link "$LINENO"; then :
9142  ac_cv_search_opendir=$ac_res
9143fi
9144rm -f core conftest.err conftest.$ac_objext \
9145    conftest$ac_exeext
9146  if test "${ac_cv_search_opendir+set}" = set; then :
9147  break
9148fi
9149done
9150if test "${ac_cv_search_opendir+set}" = set; then :
9151
9152else
9153  ac_cv_search_opendir=no
9154fi
9155rm conftest.$ac_ext
9156LIBS=$ac_func_search_save_LIBS
9157fi
9158{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
9159$as_echo "$ac_cv_search_opendir" >&6; }
9160ac_res=$ac_cv_search_opendir
9161if test "$ac_res" != no; then :
9162  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9163
9164fi
9165
9166else
9167  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
9168$as_echo_n "checking for library containing opendir... " >&6; }
9169if test "${ac_cv_search_opendir+set}" = set; then :
9170  $as_echo_n "(cached) " >&6
9171else
9172  ac_func_search_save_LIBS=$LIBS
9173cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9174/* end confdefs.h.  */
9175
9176/* Override any GCC internal prototype to avoid an error.
9177   Use char because int might match the return type of a GCC
9178   builtin and then its argument prototype would still apply.  */
9179#ifdef __cplusplus
9180extern "C"
9181#endif
9182char opendir ();
9183int
9184main ()
9185{
9186return opendir ();
9187  ;
9188  return 0;
9189}
9190_ACEOF
9191for ac_lib in '' x; do
9192  if test -z "$ac_lib"; then
9193    ac_res="none required"
9194  else
9195    ac_res=-l$ac_lib
9196    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9197  fi
9198  if ac_fn_c_try_link "$LINENO"; then :
9199  ac_cv_search_opendir=$ac_res
9200fi
9201rm -f core conftest.err conftest.$ac_objext \
9202    conftest$ac_exeext
9203  if test "${ac_cv_search_opendir+set}" = set; then :
9204  break
9205fi
9206done
9207if test "${ac_cv_search_opendir+set}" = set; then :
9208
9209else
9210  ac_cv_search_opendir=no
9211fi
9212rm conftest.$ac_ext
9213LIBS=$ac_func_search_save_LIBS
9214fi
9215{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
9216$as_echo "$ac_cv_search_opendir" >&6; }
9217ac_res=$ac_cv_search_opendir
9218if test "$ac_res" != no; then :
9219  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9220
9221fi
9222
9223fi
9224
9225
9226if test $ac_cv_header_sys_wait_h = no; then
9227  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that defines union wait" >&5
9228$as_echo_n "checking for sys/wait.h that defines union wait... " >&6; }
9229  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9230/* end confdefs.h.  */
9231#include <sys/wait.h>
9232int
9233main ()
9234{
9235union wait xx, yy; xx = yy
9236  ;
9237  return 0;
9238}
9239_ACEOF
9240if ac_fn_c_try_compile "$LINENO"; then :
9241  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9242$as_echo "yes" >&6; }
9243			$as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
9244
9245			$as_echo "#define HAVE_UNION_WAIT 1" >>confdefs.h
9246
9247else
9248  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9249$as_echo "no" >&6; }
9250fi
9251rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9252fi
9253
9254for ac_header in stdarg.h stdint.h stdlib.h string.h \
9255	sys/select.h sys/utsname.h termcap.h fcntl.h \
9256	sgtty.h sys/ioctl.h sys/time.h sys/types.h \
9257	termio.h iconv.h inttypes.h langinfo.h math.h \
9258	unistd.h stropts.h errno.h sys/resource.h \
9259	sys/systeminfo.h locale.h sys/stream.h termios.h \
9260	libc.h sys/statfs.h poll.h sys/poll.h pwd.h \
9261	utime.h sys/param.h libintl.h libgen.h \
9262	util/debug.h util/msg18n.h frame.h sys/acl.h \
9263	sys/access.h sys/sysinfo.h wchar.h wctype.h
9264do :
9265  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9266ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
9267eval as_val=\$$as_ac_Header
9268   if test "x$as_val" = x""yes; then :
9269  cat >>confdefs.h <<_ACEOF
9270#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9271_ACEOF
9272
9273fi
9274
9275done
9276
9277
9278for ac_header in sys/ptem.h
9279do :
9280  ac_fn_c_check_header_compile "$LINENO" "sys/ptem.h" "ac_cv_header_sys_ptem_h" "#if defined HAVE_SYS_STREAM_H
9281#  include <sys/stream.h>
9282#endif
9283"
9284if test "x$ac_cv_header_sys_ptem_h" = x""yes; then :
9285  cat >>confdefs.h <<_ACEOF
9286#define HAVE_SYS_PTEM_H 1
9287_ACEOF
9288
9289fi
9290
9291done
9292
9293
9294for ac_header in sys/sysctl.h
9295do :
9296  ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "#if defined HAVE_SYS_PARAM_H
9297#  include <sys/param.h>
9298#endif
9299"
9300if test "x$ac_cv_header_sys_sysctl_h" = x""yes; then :
9301  cat >>confdefs.h <<_ACEOF
9302#define HAVE_SYS_SYSCTL_H 1
9303_ACEOF
9304
9305fi
9306
9307done
9308
9309
9310
9311{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_np.h" >&5
9312$as_echo_n "checking for pthread_np.h... " >&6; }
9313cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9314/* end confdefs.h.  */
9315
9316#include <pthread.h>
9317#include <pthread_np.h>
9318int
9319main ()
9320{
9321int i; i = 0;
9322  ;
9323  return 0;
9324}
9325_ACEOF
9326if ac_fn_c_try_compile "$LINENO"; then :
9327  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9328$as_echo "yes" >&6; }
9329		      $as_echo "#define HAVE_PTHREAD_NP_H 1" >>confdefs.h
9330
9331else
9332  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9333$as_echo "no" >&6; }
9334fi
9335rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9336
9337for ac_header in strings.h
9338do :
9339  ac_fn_c_check_header_mongrel "$LINENO" "strings.h" "ac_cv_header_strings_h" "$ac_includes_default"
9340if test "x$ac_cv_header_strings_h" = x""yes; then :
9341  cat >>confdefs.h <<_ACEOF
9342#define HAVE_STRINGS_H 1
9343_ACEOF
9344
9345fi
9346
9347done
9348
9349if test "x$MACOSX" = "xyes"; then
9350    $as_echo "#define NO_STRINGS_WITH_STRING_H 1" >>confdefs.h
9351
9352else
9353
9354{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if strings.h can be included after string.h" >&5
9355$as_echo_n "checking if strings.h can be included after string.h... " >&6; }
9356cppflags_save=$CPPFLAGS
9357CPPFLAGS="$CPPFLAGS $X_CFLAGS"
9358cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9359/* end confdefs.h.  */
9360
9361#if defined(_AIX) && !defined(_AIX51) && !defined(_NO_PROTO)
9362# define _NO_PROTO	/* like in os_unix.h, causes conflict for AIX (Winn) */
9363			/* but don't do it on AIX 5.1 (Uribarri) */
9364#endif
9365#ifdef HAVE_XM_XM_H
9366# include <Xm/Xm.h>	/* This breaks it for HP-UX 11 (Squassabia) */
9367#endif
9368#ifdef HAVE_STRING_H
9369# include <string.h>
9370#endif
9371#if defined(HAVE_STRINGS_H)
9372# include <strings.h>
9373#endif
9374
9375int
9376main ()
9377{
9378int i; i = 0;
9379  ;
9380  return 0;
9381}
9382_ACEOF
9383if ac_fn_c_try_compile "$LINENO"; then :
9384  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9385$as_echo "yes" >&6; }
9386else
9387  $as_echo "#define NO_STRINGS_WITH_STRING_H 1" >>confdefs.h
9388
9389		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9390$as_echo "no" >&6; }
9391fi
9392rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9393CPPFLAGS=$cppflags_save
9394fi
9395
9396if test $ac_cv_c_compiler_gnu = yes; then
9397    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5
9398$as_echo_n "checking whether $CC needs -traditional... " >&6; }
9399if test "${ac_cv_prog_gcc_traditional+set}" = set; then :
9400  $as_echo_n "(cached) " >&6
9401else
9402    ac_pattern="Autoconf.*'x'"
9403  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9404/* end confdefs.h.  */
9405#include <sgtty.h>
9406Autoconf TIOCGETP
9407_ACEOF
9408if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9409  $EGREP "$ac_pattern" >/dev/null 2>&1; then :
9410  ac_cv_prog_gcc_traditional=yes
9411else
9412  ac_cv_prog_gcc_traditional=no
9413fi
9414rm -f conftest*
9415
9416
9417  if test $ac_cv_prog_gcc_traditional = no; then
9418    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9419/* end confdefs.h.  */
9420#include <termio.h>
9421Autoconf TCGETA
9422_ACEOF
9423if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9424  $EGREP "$ac_pattern" >/dev/null 2>&1; then :
9425  ac_cv_prog_gcc_traditional=yes
9426fi
9427rm -f conftest*
9428
9429  fi
9430fi
9431{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5
9432$as_echo "$ac_cv_prog_gcc_traditional" >&6; }
9433  if test $ac_cv_prog_gcc_traditional = yes; then
9434    CC="$CC -traditional"
9435  fi
9436fi
9437
9438{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
9439$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
9440if test "${ac_cv_c_const+set}" = set; then :
9441  $as_echo_n "(cached) " >&6
9442else
9443  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9444/* end confdefs.h.  */
9445
9446int
9447main ()
9448{
9449/* FIXME: Include the comments suggested by Paul. */
9450#ifndef __cplusplus
9451  /* Ultrix mips cc rejects this.  */
9452  typedef int charset[2];
9453  const charset cs;
9454  /* SunOS 4.1.1 cc rejects this.  */
9455  char const *const *pcpcc;
9456  char **ppc;
9457  /* NEC SVR4.0.2 mips cc rejects this.  */
9458  struct point {int x, y;};
9459  static struct point const zero = {0,0};
9460  /* AIX XL C 1.02.0.0 rejects this.
9461     It does not let you subtract one const X* pointer from another in
9462     an arm of an if-expression whose if-part is not a constant
9463     expression */
9464  const char *g = "string";
9465  pcpcc = &g + (g ? g-g : 0);
9466  /* HPUX 7.0 cc rejects these. */
9467  ++pcpcc;
9468  ppc = (char**) pcpcc;
9469  pcpcc = (char const *const *) ppc;
9470  { /* SCO 3.2v4 cc rejects this.  */
9471    char *t;
9472    char const *s = 0 ? (char *) 0 : (char const *) 0;
9473
9474    *t++ = 0;
9475    if (s) return 0;
9476  }
9477  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
9478    int x[] = {25, 17};
9479    const int *foo = &x[0];
9480    ++foo;
9481  }
9482  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
9483    typedef const int *iptr;
9484    iptr p = 0;
9485    ++p;
9486  }
9487  { /* AIX XL C 1.02.0.0 rejects this saying
9488       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
9489    struct s { int j; const int *ap[3]; };
9490    struct s *b; b->j = 5;
9491  }
9492  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
9493    const int foo = 10;
9494    if (!foo) return 0;
9495  }
9496  return !cs[0] && !zero.x;
9497#endif
9498
9499  ;
9500  return 0;
9501}
9502_ACEOF
9503if ac_fn_c_try_compile "$LINENO"; then :
9504  ac_cv_c_const=yes
9505else
9506  ac_cv_c_const=no
9507fi
9508rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9509fi
9510{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
9511$as_echo "$ac_cv_c_const" >&6; }
9512if test $ac_cv_c_const = no; then
9513
9514$as_echo "#define const /**/" >>confdefs.h
9515
9516fi
9517
9518{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
9519$as_echo_n "checking for working volatile... " >&6; }
9520if test "${ac_cv_c_volatile+set}" = set; then :
9521  $as_echo_n "(cached) " >&6
9522else
9523  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9524/* end confdefs.h.  */
9525
9526int
9527main ()
9528{
9529
9530volatile int x;
9531int * volatile y = (int *) 0;
9532return !x && !y;
9533  ;
9534  return 0;
9535}
9536_ACEOF
9537if ac_fn_c_try_compile "$LINENO"; then :
9538  ac_cv_c_volatile=yes
9539else
9540  ac_cv_c_volatile=no
9541fi
9542rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9543fi
9544{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
9545$as_echo "$ac_cv_c_volatile" >&6; }
9546if test $ac_cv_c_volatile = no; then
9547
9548$as_echo "#define volatile /**/" >>confdefs.h
9549
9550fi
9551
9552ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
9553if test "x$ac_cv_type_mode_t" = x""yes; then :
9554
9555else
9556
9557cat >>confdefs.h <<_ACEOF
9558#define mode_t int
9559_ACEOF
9560
9561fi
9562
9563ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
9564if test "x$ac_cv_type_off_t" = x""yes; then :
9565
9566else
9567
9568cat >>confdefs.h <<_ACEOF
9569#define off_t long int
9570_ACEOF
9571
9572fi
9573
9574ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
9575if test "x$ac_cv_type_pid_t" = x""yes; then :
9576
9577else
9578
9579cat >>confdefs.h <<_ACEOF
9580#define pid_t int
9581_ACEOF
9582
9583fi
9584
9585ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
9586if test "x$ac_cv_type_size_t" = x""yes; then :
9587
9588else
9589
9590cat >>confdefs.h <<_ACEOF
9591#define size_t unsigned int
9592_ACEOF
9593
9594fi
9595
9596{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
9597$as_echo_n "checking for uid_t in sys/types.h... " >&6; }
9598if test "${ac_cv_type_uid_t+set}" = set; then :
9599  $as_echo_n "(cached) " >&6
9600else
9601  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9602/* end confdefs.h.  */
9603#include <sys/types.h>
9604
9605_ACEOF
9606if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9607  $EGREP "uid_t" >/dev/null 2>&1; then :
9608  ac_cv_type_uid_t=yes
9609else
9610  ac_cv_type_uid_t=no
9611fi
9612rm -f conftest*
9613
9614fi
9615{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
9616$as_echo "$ac_cv_type_uid_t" >&6; }
9617if test $ac_cv_type_uid_t = no; then
9618
9619$as_echo "#define uid_t int" >>confdefs.h
9620
9621
9622$as_echo "#define gid_t int" >>confdefs.h
9623
9624fi
9625
9626ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t"
9627case $ac_cv_c_uint32_t in #(
9628  no|yes) ;; #(
9629  *)
9630
9631$as_echo "#define _UINT32_T 1" >>confdefs.h
9632
9633
9634cat >>confdefs.h <<_ACEOF
9635#define uint32_t $ac_cv_c_uint32_t
9636_ACEOF
9637;;
9638  esac
9639
9640
9641{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
9642$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
9643if test "${ac_cv_header_time+set}" = set; then :
9644  $as_echo_n "(cached) " >&6
9645else
9646  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9647/* end confdefs.h.  */
9648#include <sys/types.h>
9649#include <sys/time.h>
9650#include <time.h>
9651
9652int
9653main ()
9654{
9655if ((struct tm *) 0)
9656return 0;
9657  ;
9658  return 0;
9659}
9660_ACEOF
9661if ac_fn_c_try_compile "$LINENO"; then :
9662  ac_cv_header_time=yes
9663else
9664  ac_cv_header_time=no
9665fi
9666rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9667fi
9668{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
9669$as_echo "$ac_cv_header_time" >&6; }
9670if test $ac_cv_header_time = yes; then
9671
9672$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
9673
9674fi
9675
9676ac_fn_c_check_type "$LINENO" "ino_t" "ac_cv_type_ino_t" "$ac_includes_default"
9677if test "x$ac_cv_type_ino_t" = x""yes; then :
9678
9679else
9680
9681cat >>confdefs.h <<_ACEOF
9682#define ino_t long
9683_ACEOF
9684
9685fi
9686
9687ac_fn_c_check_type "$LINENO" "dev_t" "ac_cv_type_dev_t" "$ac_includes_default"
9688if test "x$ac_cv_type_dev_t" = x""yes; then :
9689
9690else
9691
9692cat >>confdefs.h <<_ACEOF
9693#define dev_t unsigned
9694_ACEOF
9695
9696fi
9697
9698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
9699$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
9700if test "${ac_cv_c_bigendian+set}" = set; then :
9701  $as_echo_n "(cached) " >&6
9702else
9703  ac_cv_c_bigendian=unknown
9704    # See if we're dealing with a universal compiler.
9705    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9706/* end confdefs.h.  */
9707#ifndef __APPLE_CC__
9708	       not a universal capable compiler
9709	     #endif
9710	     typedef int dummy;
9711
9712_ACEOF
9713if ac_fn_c_try_compile "$LINENO"; then :
9714
9715	# Check for potential -arch flags.  It is not universal unless
9716	# there are at least two -arch flags with different values.
9717	ac_arch=
9718	ac_prev=
9719	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
9720	 if test -n "$ac_prev"; then
9721	   case $ac_word in
9722	     i?86 | x86_64 | ppc | ppc64)
9723	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
9724		 ac_arch=$ac_word
9725	       else
9726		 ac_cv_c_bigendian=universal
9727		 break
9728	       fi
9729	       ;;
9730	   esac
9731	   ac_prev=
9732	 elif test "x$ac_word" = "x-arch"; then
9733	   ac_prev=arch
9734	 fi
9735       done
9736fi
9737rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9738    if test $ac_cv_c_bigendian = unknown; then
9739      # See if sys/param.h defines the BYTE_ORDER macro.
9740      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9741/* end confdefs.h.  */
9742#include <sys/types.h>
9743	     #include <sys/param.h>
9744
9745int
9746main ()
9747{
9748#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
9749		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
9750		     && LITTLE_ENDIAN)
9751	      bogus endian macros
9752	     #endif
9753
9754  ;
9755  return 0;
9756}
9757_ACEOF
9758if ac_fn_c_try_compile "$LINENO"; then :
9759  # It does; now see whether it defined to BIG_ENDIAN or not.
9760	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9761/* end confdefs.h.  */
9762#include <sys/types.h>
9763		#include <sys/param.h>
9764
9765int
9766main ()
9767{
9768#if BYTE_ORDER != BIG_ENDIAN
9769		 not big endian
9770		#endif
9771
9772  ;
9773  return 0;
9774}
9775_ACEOF
9776if ac_fn_c_try_compile "$LINENO"; then :
9777  ac_cv_c_bigendian=yes
9778else
9779  ac_cv_c_bigendian=no
9780fi
9781rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9782fi
9783rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9784    fi
9785    if test $ac_cv_c_bigendian = unknown; then
9786      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
9787      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9788/* end confdefs.h.  */
9789#include <limits.h>
9790
9791int
9792main ()
9793{
9794#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
9795	      bogus endian macros
9796	     #endif
9797
9798  ;
9799  return 0;
9800}
9801_ACEOF
9802if ac_fn_c_try_compile "$LINENO"; then :
9803  # It does; now see whether it defined to _BIG_ENDIAN or not.
9804	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9805/* end confdefs.h.  */
9806#include <limits.h>
9807
9808int
9809main ()
9810{
9811#ifndef _BIG_ENDIAN
9812		 not big endian
9813		#endif
9814
9815  ;
9816  return 0;
9817}
9818_ACEOF
9819if ac_fn_c_try_compile "$LINENO"; then :
9820  ac_cv_c_bigendian=yes
9821else
9822  ac_cv_c_bigendian=no
9823fi
9824rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9825fi
9826rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9827    fi
9828    if test $ac_cv_c_bigendian = unknown; then
9829      # Compile a test program.
9830      if test "$cross_compiling" = yes; then :
9831  # Try to guess by grepping values from an object file.
9832	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9833/* end confdefs.h.  */
9834short int ascii_mm[] =
9835		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
9836		short int ascii_ii[] =
9837		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
9838		int use_ascii (int i) {
9839		  return ascii_mm[i] + ascii_ii[i];
9840		}
9841		short int ebcdic_ii[] =
9842		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
9843		short int ebcdic_mm[] =
9844		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
9845		int use_ebcdic (int i) {
9846		  return ebcdic_mm[i] + ebcdic_ii[i];
9847		}
9848		extern int foo;
9849
9850int
9851main ()
9852{
9853return use_ascii (foo) == use_ebcdic (foo);
9854  ;
9855  return 0;
9856}
9857_ACEOF
9858if ac_fn_c_try_compile "$LINENO"; then :
9859  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
9860	      ac_cv_c_bigendian=yes
9861	    fi
9862	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
9863	      if test "$ac_cv_c_bigendian" = unknown; then
9864		ac_cv_c_bigendian=no
9865	      else
9866		# finding both strings is unlikely to happen, but who knows?
9867		ac_cv_c_bigendian=unknown
9868	      fi
9869	    fi
9870fi
9871rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9872else
9873  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9874/* end confdefs.h.  */
9875$ac_includes_default
9876int
9877main ()
9878{
9879
9880	     /* Are we little or big endian?  From Harbison&Steele.  */
9881	     union
9882	     {
9883	       long int l;
9884	       char c[sizeof (long int)];
9885	     } u;
9886	     u.l = 1;
9887	     return u.c[sizeof (long int) - 1] == 1;
9888
9889  ;
9890  return 0;
9891}
9892_ACEOF
9893if ac_fn_c_try_run "$LINENO"; then :
9894  ac_cv_c_bigendian=no
9895else
9896  ac_cv_c_bigendian=yes
9897fi
9898rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9899  conftest.$ac_objext conftest.beam conftest.$ac_ext
9900fi
9901
9902    fi
9903fi
9904{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
9905$as_echo "$ac_cv_c_bigendian" >&6; }
9906 case $ac_cv_c_bigendian in #(
9907   yes)
9908     $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
9909;; #(
9910   no)
9911      ;; #(
9912   universal)
9913
9914$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
9915
9916     ;; #(
9917   *)
9918     as_fn_error "unknown endianness
9919 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
9920 esac
9921
9922
9923{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for rlim_t" >&5
9924$as_echo_n "checking for rlim_t... " >&6; }
9925if eval "test \"`echo '$''{'ac_cv_type_rlim_t'+set}'`\" = set"; then
9926  { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_type_rlim_t" >&5
9927$as_echo "(cached) $ac_cv_type_rlim_t" >&6; }
9928else
9929  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9930/* end confdefs.h.  */
9931
9932#include <sys/types.h>
9933#if STDC_HEADERS
9934# include <stdlib.h>
9935# include <stddef.h>
9936#endif
9937#ifdef HAVE_SYS_RESOURCE_H
9938# include <sys/resource.h>
9939#endif
9940
9941_ACEOF
9942if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9943  $EGREP "(^|[^a-zA-Z_0-9])rlim_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then :
9944  ac_cv_type_rlim_t=yes
9945else
9946  ac_cv_type_rlim_t=no
9947fi
9948rm -f conftest*
9949
9950	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_rlim_t" >&5
9951$as_echo "$ac_cv_type_rlim_t" >&6; }
9952fi
9953if test $ac_cv_type_rlim_t = no; then
9954  cat >> confdefs.h <<\EOF
9955#define rlim_t unsigned long
9956EOF
9957fi
9958
9959{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stack_t" >&5
9960$as_echo_n "checking for stack_t... " >&6; }
9961if eval "test \"`echo '$''{'ac_cv_type_stack_t'+set}'`\" = set"; then
9962  { $as_echo "$as_me:${as_lineno-$LINENO}: result: (cached) $ac_cv_type_stack_t" >&5
9963$as_echo "(cached) $ac_cv_type_stack_t" >&6; }
9964else
9965  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9966/* end confdefs.h.  */
9967
9968#include <sys/types.h>
9969#if STDC_HEADERS
9970# include <stdlib.h>
9971# include <stddef.h>
9972#endif
9973#include <signal.h>
9974
9975_ACEOF
9976if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9977  $EGREP "stack_t" >/dev/null 2>&1; then :
9978  ac_cv_type_stack_t=yes
9979else
9980  ac_cv_type_stack_t=no
9981fi
9982rm -f conftest*
9983
9984	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_stack_t" >&5
9985$as_echo "$ac_cv_type_stack_t" >&6; }
9986fi
9987if test $ac_cv_type_stack_t = no; then
9988  cat >> confdefs.h <<\EOF
9989#define stack_t struct sigaltstack
9990EOF
9991fi
9992
9993{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stack_t has an ss_base field" >&5
9994$as_echo_n "checking whether stack_t has an ss_base field... " >&6; }
9995cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9996/* end confdefs.h.  */
9997
9998#include <sys/types.h>
9999#if STDC_HEADERS
10000# include <stdlib.h>
10001# include <stddef.h>
10002#endif
10003#include <signal.h>
10004#include "confdefs.h"
10005
10006int
10007main ()
10008{
10009stack_t sigstk; sigstk.ss_base = 0;
10010  ;
10011  return 0;
10012}
10013_ACEOF
10014if ac_fn_c_try_compile "$LINENO"; then :
10015  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10016$as_echo "yes" >&6; }; $as_echo "#define HAVE_SS_BASE 1" >>confdefs.h
10017
10018else
10019  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10020$as_echo "no" >&6; }
10021fi
10022rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10023
10024olibs="$LIBS"
10025{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-tlib argument" >&5
10026$as_echo_n "checking --with-tlib argument... " >&6; }
10027
10028# Check whether --with-tlib was given.
10029if test "${with_tlib+set}" = set; then :
10030  withval=$with_tlib;
10031fi
10032
10033if test -n "$with_tlib"; then
10034  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_tlib" >&5
10035$as_echo "$with_tlib" >&6; }
10036  LIBS="$LIBS -l$with_tlib"
10037  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for linking with $with_tlib library" >&5
10038$as_echo_n "checking for linking with $with_tlib library... " >&6; }
10039  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10040/* end confdefs.h.  */
10041
10042int
10043main ()
10044{
10045
10046  ;
10047  return 0;
10048}
10049_ACEOF
10050if ac_fn_c_try_link "$LINENO"; then :
10051  { $as_echo "$as_me:${as_lineno-$LINENO}: result: OK" >&5
10052$as_echo "OK" >&6; }
10053else
10054  as_fn_error "FAILED" "$LINENO" 5
10055fi
10056rm -f core conftest.err conftest.$ac_objext \
10057    conftest$ac_exeext conftest.$ac_ext
10058    olibs="$LIBS"
10059else
10060  { $as_echo "$as_me:${as_lineno-$LINENO}: result: empty: automatic terminal library selection" >&5
10061$as_echo "empty: automatic terminal library selection" >&6; }
10062                case "`uname -s 2>/dev/null`" in
10063	OSF1|SCO_SV)	tlibs="tinfo ncurses curses termlib termcap";;
10064	*)	tlibs="tinfo ncurses termlib termcap curses";;
10065  esac
10066  for libname in $tlibs; do
10067    as_ac_Lib=`$as_echo "ac_cv_lib_${libname}''_tgetent" | $as_tr_sh`
10068{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -l${libname}" >&5
10069$as_echo_n "checking for tgetent in -l${libname}... " >&6; }
10070if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10071  $as_echo_n "(cached) " >&6
10072else
10073  ac_check_lib_save_LIBS=$LIBS
10074LIBS="-l${libname}  $LIBS"
10075cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10076/* end confdefs.h.  */
10077
10078/* Override any GCC internal prototype to avoid an error.
10079   Use char because int might match the return type of a GCC
10080   builtin and then its argument prototype would still apply.  */
10081#ifdef __cplusplus
10082extern "C"
10083#endif
10084char tgetent ();
10085int
10086main ()
10087{
10088return tgetent ();
10089  ;
10090  return 0;
10091}
10092_ACEOF
10093if ac_fn_c_try_link "$LINENO"; then :
10094  eval "$as_ac_Lib=yes"
10095else
10096  eval "$as_ac_Lib=no"
10097fi
10098rm -f core conftest.err conftest.$ac_objext \
10099    conftest$ac_exeext conftest.$ac_ext
10100LIBS=$ac_check_lib_save_LIBS
10101fi
10102eval ac_res=\$$as_ac_Lib
10103	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10104$as_echo "$ac_res" >&6; }
10105eval as_val=\$$as_ac_Lib
10106   if test "x$as_val" = x""yes; then :
10107  cat >>confdefs.h <<_ACEOF
10108#define `$as_echo "HAVE_LIB${libname}" | $as_tr_cpp` 1
10109_ACEOF
10110
10111  LIBS="-l${libname} $LIBS"
10112
10113fi
10114
10115    if test "x$olibs" != "x$LIBS"; then
10116                        if test "$cross_compiling" = yes; then :
10117  res="FAIL"
10118else
10119  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10120/* end confdefs.h.  */
10121
10122#ifdef HAVE_TERMCAP_H
10123# include <termcap.h>
10124#endif
10125#if STDC_HEADERS
10126# include <stdlib.h>
10127# include <stddef.h>
10128#endif
10129main() {char *s; s=(char *)tgoto("%p1%d", 0, 1); exit(0); }
10130_ACEOF
10131if ac_fn_c_try_run "$LINENO"; then :
10132  res="OK"
10133else
10134  res="FAIL"
10135fi
10136rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10137  conftest.$ac_objext conftest.beam conftest.$ac_ext
10138fi
10139
10140      if test "$res" = "OK"; then
10141	break
10142      fi
10143      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libname library is not usable" >&5
10144$as_echo "$libname library is not usable" >&6; }
10145      LIBS="$olibs"
10146    fi
10147  done
10148  if test "x$olibs" = "x$LIBS"; then
10149    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no terminal library found" >&5
10150$as_echo "no terminal library found" >&6; }
10151  fi
10152fi
10153
10154if test "x$olibs" = "x$LIBS"; then
10155  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent()" >&5
10156$as_echo_n "checking for tgetent()... " >&6; }
10157  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10158/* end confdefs.h.  */
10159
10160int
10161main ()
10162{
10163char s[10000]; int res = tgetent(s, "thisterminaldoesnotexist");
10164  ;
10165  return 0;
10166}
10167_ACEOF
10168if ac_fn_c_try_link "$LINENO"; then :
10169  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10170$as_echo "yes" >&6; }
10171else
10172  as_fn_error "NOT FOUND!
10173      You need to install a terminal library; for example ncurses.
10174      Or specify the name of the library with --with-tlib." "$LINENO" 5
10175fi
10176rm -f core conftest.err conftest.$ac_objext \
10177    conftest$ac_exeext conftest.$ac_ext
10178fi
10179
10180{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we talk terminfo" >&5
10181$as_echo_n "checking whether we talk terminfo... " >&6; }
10182if test "${vim_cv_terminfo+set}" = set; then :
10183  $as_echo_n "(cached) " >&6
10184else
10185
10186    if test "$cross_compiling" = yes; then :
10187
10188      as_fn_error "cross-compiling: please set 'vim_cv_terminfo'" "$LINENO" 5
10189
10190else
10191  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10192/* end confdefs.h.  */
10193
10194#include "confdefs.h"
10195#ifdef HAVE_TERMCAP_H
10196# include <termcap.h>
10197#endif
10198#ifdef HAVE_STRING_H
10199# include <string.h>
10200#endif
10201#if STDC_HEADERS
10202# include <stdlib.h>
10203# include <stddef.h>
10204#endif
10205main()
10206{char *s; s=(char *)tgoto("%p1%d", 0, 1); exit(!strcmp(s==0 ? "" : s, "1")); }
10207
10208_ACEOF
10209if ac_fn_c_try_run "$LINENO"; then :
10210
10211      vim_cv_terminfo=no
10212
10213else
10214
10215      vim_cv_terminfo=yes
10216
10217fi
10218rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10219  conftest.$ac_objext conftest.beam conftest.$ac_ext
10220fi
10221
10222
10223fi
10224{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vim_cv_terminfo" >&5
10225$as_echo "$vim_cv_terminfo" >&6; }
10226
10227if test "x$vim_cv_terminfo" = "xyes" ; then
10228  $as_echo "#define TERMINFO 1" >>confdefs.h
10229
10230fi
10231
10232if test "x$olibs" != "x$LIBS"; then
10233  { $as_echo "$as_me:${as_lineno-$LINENO}: checking what tgetent() returns for an unknown terminal" >&5
10234$as_echo_n "checking what tgetent() returns for an unknown terminal... " >&6; }
10235if test "${vim_cv_tgent+set}" = set; then :
10236  $as_echo_n "(cached) " >&6
10237else
10238
10239      if test "$cross_compiling" = yes; then :
10240
10241	as_fn_error "failed to compile test program." "$LINENO" 5
10242
10243else
10244  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10245/* end confdefs.h.  */
10246
10247#include "confdefs.h"
10248#ifdef HAVE_TERMCAP_H
10249# include <termcap.h>
10250#endif
10251#if STDC_HEADERS
10252# include <stdlib.h>
10253# include <stddef.h>
10254#endif
10255main()
10256{char s[10000]; int res = tgetent(s, "thisterminaldoesnotexist"); exit(res != 0); }
10257
10258_ACEOF
10259if ac_fn_c_try_run "$LINENO"; then :
10260
10261	vim_cv_tgent=zero
10262
10263else
10264
10265	vim_cv_tgent=non-zero
10266
10267fi
10268rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10269  conftest.$ac_objext conftest.beam conftest.$ac_ext
10270fi
10271
10272
10273fi
10274{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vim_cv_tgent" >&5
10275$as_echo "$vim_cv_tgent" >&6; }
10276
10277  if test "x$vim_cv_tgent" = "xzero" ; then
10278    $as_echo "#define TGETENT_ZERO_ERR 0" >>confdefs.h
10279
10280  fi
10281fi
10282
10283{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether termcap.h contains ospeed" >&5
10284$as_echo_n "checking whether termcap.h contains ospeed... " >&6; }
10285cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10286/* end confdefs.h.  */
10287
10288#ifdef HAVE_TERMCAP_H
10289# include <termcap.h>
10290#endif
10291
10292int
10293main ()
10294{
10295ospeed = 20000
10296  ;
10297  return 0;
10298}
10299_ACEOF
10300if ac_fn_c_try_link "$LINENO"; then :
10301  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10302$as_echo "yes" >&6; }; $as_echo "#define HAVE_OSPEED 1" >>confdefs.h
10303
10304else
10305  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10306$as_echo "no" >&6; }
10307	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ospeed can be extern" >&5
10308$as_echo_n "checking whether ospeed can be extern... " >&6; }
10309	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10310/* end confdefs.h.  */
10311
10312#ifdef HAVE_TERMCAP_H
10313# include <termcap.h>
10314#endif
10315extern short ospeed;
10316
10317int
10318main ()
10319{
10320ospeed = 20000
10321  ;
10322  return 0;
10323}
10324_ACEOF
10325if ac_fn_c_try_link "$LINENO"; then :
10326  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10327$as_echo "yes" >&6; }; $as_echo "#define OSPEED_EXTERN 1" >>confdefs.h
10328
10329else
10330  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10331$as_echo "no" >&6; }
10332fi
10333rm -f core conftest.err conftest.$ac_objext \
10334    conftest$ac_exeext conftest.$ac_ext
10335
10336fi
10337rm -f core conftest.err conftest.$ac_objext \
10338    conftest$ac_exeext conftest.$ac_ext
10339
10340{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether termcap.h contains UP, BC and PC" >&5
10341$as_echo_n "checking whether termcap.h contains UP, BC and PC... " >&6; }
10342cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10343/* end confdefs.h.  */
10344
10345#ifdef HAVE_TERMCAP_H
10346# include <termcap.h>
10347#endif
10348
10349int
10350main ()
10351{
10352if (UP == 0 && BC == 0) PC = 1
10353  ;
10354  return 0;
10355}
10356_ACEOF
10357if ac_fn_c_try_link "$LINENO"; then :
10358  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10359$as_echo "yes" >&6; }; $as_echo "#define HAVE_UP_BC_PC 1" >>confdefs.h
10360
10361else
10362  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10363$as_echo "no" >&6; }
10364	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UP, BC and PC can be extern" >&5
10365$as_echo_n "checking whether UP, BC and PC can be extern... " >&6; }
10366	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10367/* end confdefs.h.  */
10368
10369#ifdef HAVE_TERMCAP_H
10370# include <termcap.h>
10371#endif
10372extern char *UP, *BC, PC;
10373
10374int
10375main ()
10376{
10377if (UP == 0 && BC == 0) PC = 1
10378  ;
10379  return 0;
10380}
10381_ACEOF
10382if ac_fn_c_try_link "$LINENO"; then :
10383  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10384$as_echo "yes" >&6; }; $as_echo "#define UP_BC_PC_EXTERN 1" >>confdefs.h
10385
10386else
10387  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10388$as_echo "no" >&6; }
10389fi
10390rm -f core conftest.err conftest.$ac_objext \
10391    conftest$ac_exeext conftest.$ac_ext
10392
10393fi
10394rm -f core conftest.err conftest.$ac_objext \
10395    conftest$ac_exeext conftest.$ac_ext
10396
10397{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether tputs() uses outfuntype" >&5
10398$as_echo_n "checking whether tputs() uses outfuntype... " >&6; }
10399cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10400/* end confdefs.h.  */
10401
10402#ifdef HAVE_TERMCAP_H
10403# include <termcap.h>
10404#endif
10405
10406int
10407main ()
10408{
10409extern int xx(); tputs("test", 1, (outfuntype)xx)
10410  ;
10411  return 0;
10412}
10413_ACEOF
10414if ac_fn_c_try_compile "$LINENO"; then :
10415  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10416$as_echo "yes" >&6; }; $as_echo "#define HAVE_OUTFUNTYPE 1" >>confdefs.h
10417
10418else
10419  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10420$as_echo "no" >&6; }
10421fi
10422rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10423
10424{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/select.h and sys/time.h may both be included" >&5
10425$as_echo_n "checking whether sys/select.h and sys/time.h may both be included... " >&6; }
10426cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10427/* end confdefs.h.  */
10428
10429#include <sys/types.h>
10430#include <sys/time.h>
10431#include <sys/select.h>
10432int
10433main ()
10434{
10435
10436  ;
10437  return 0;
10438}
10439_ACEOF
10440if ac_fn_c_try_compile "$LINENO"; then :
10441  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10442$as_echo "yes" >&6; }
10443			$as_echo "#define SYS_SELECT_WITH_SYS_TIME 1" >>confdefs.h
10444
10445else
10446  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10447$as_echo "no" >&6; }
10448fi
10449rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10450
10451
10452{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5
10453$as_echo_n "checking for /dev/ptc... " >&6; }
10454if test -r /dev/ptc; then
10455  $as_echo "#define HAVE_DEV_PTC 1" >>confdefs.h
10456
10457  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10458$as_echo "yes" >&6; }
10459else
10460  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10461$as_echo "no" >&6; }
10462fi
10463
10464{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SVR4 ptys" >&5
10465$as_echo_n "checking for SVR4 ptys... " >&6; }
10466if test -c /dev/ptmx ; then
10467  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10468/* end confdefs.h.  */
10469
10470int
10471main ()
10472{
10473ptsname(0);grantpt(0);unlockpt(0);
10474  ;
10475  return 0;
10476}
10477_ACEOF
10478if ac_fn_c_try_link "$LINENO"; then :
10479  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10480$as_echo "yes" >&6; }; $as_echo "#define HAVE_SVR4_PTYS 1" >>confdefs.h
10481
10482else
10483  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10484$as_echo "no" >&6; }
10485fi
10486rm -f core conftest.err conftest.$ac_objext \
10487    conftest$ac_exeext conftest.$ac_ext
10488else
10489  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10490$as_echo "no" >&6; }
10491fi
10492
10493{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ptyranges" >&5
10494$as_echo_n "checking for ptyranges... " >&6; }
10495if test -d /dev/ptym ; then
10496  pdir='/dev/ptym'
10497else
10498  pdir='/dev'
10499fi
10500cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10501/* end confdefs.h.  */
10502#ifdef M_UNIX
10503   yes;
10504#endif
10505
10506_ACEOF
10507if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10508  $EGREP "yes" >/dev/null 2>&1; then :
10509  ptys=`echo /dev/ptyp??`
10510else
10511  ptys=`echo $pdir/pty??`
10512fi
10513rm -f conftest*
10514
10515if test "$ptys" != "$pdir/pty??" ; then
10516  p0=`echo $ptys | tr ' ' '\012' | sed -e 's/^.*\(.\).$/\1/g' | sort -u | tr -d '\012'`
10517  p1=`echo $ptys | tr ' ' '\012' | sed -e 's/^.*\(.\)$/\1/g'  | sort -u | tr -d '\012'`
10518  cat >>confdefs.h <<_ACEOF
10519#define PTYRANGE0 "$p0"
10520_ACEOF
10521
10522  cat >>confdefs.h <<_ACEOF
10523#define PTYRANGE1 "$p1"
10524_ACEOF
10525
10526  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $p0 / $p1" >&5
10527$as_echo "$p0 / $p1" >&6; }
10528else
10529  { $as_echo "$as_me:${as_lineno-$LINENO}: result: don't know" >&5
10530$as_echo "don't know" >&6; }
10531fi
10532
10533rm -f conftest_grp
10534{ $as_echo "$as_me:${as_lineno-$LINENO}: checking default tty permissions/group" >&5
10535$as_echo_n "checking default tty permissions/group... " >&6; }
10536if test "${vim_cv_tty_group+set}" = set; then :
10537  $as_echo_n "(cached) " >&6
10538else
10539
10540    if test "$cross_compiling" = yes; then :
10541
10542      as_fn_error "cross-compiling: please set 'vim_cv_tty_group' and 'vim_cv_tty_mode'" "$LINENO" 5
10543
10544else
10545  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10546/* end confdefs.h.  */
10547
10548#include "confdefs.h"
10549#include <sys/types.h>
10550#if STDC_HEADERS
10551# include <stdlib.h>
10552# include <stddef.h>
10553#endif
10554#ifdef HAVE_UNISTD_H
10555#include <unistd.h>
10556#endif
10557#include <sys/stat.h>
10558#include <stdio.h>
10559main()
10560{
10561  struct stat sb;
10562  char *x,*ttyname();
10563  int om, m;
10564  FILE *fp;
10565
10566  if (!(x = ttyname(0))) exit(1);
10567  if (stat(x, &sb)) exit(1);
10568  om = sb.st_mode;
10569  if (om & 002) exit(0);
10570  m = system("mesg y");
10571  if (m == -1 || m == 127) exit(1);
10572  if (stat(x, &sb)) exit(1);
10573  m = sb.st_mode;
10574  if (chmod(x, om)) exit(1);
10575  if (m & 002) exit(0);
10576  if (sb.st_gid == getgid()) exit(1);
10577  if (!(fp=fopen("conftest_grp", "w")))
10578    exit(1);
10579  fprintf(fp, "%d\n", sb.st_gid);
10580  fclose(fp);
10581  exit(0);
10582}
10583
10584_ACEOF
10585if ac_fn_c_try_run "$LINENO"; then :
10586
10587      if test -f conftest_grp; then
10588	vim_cv_tty_group=`cat conftest_grp`
10589	if test "x$vim_cv_tty_mode" = "x" ; then
10590	  vim_cv_tty_mode=0620
10591	fi
10592	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: pty mode: $vim_cv_tty_mode, group: $vim_cv_tty_group" >&5
10593$as_echo "pty mode: $vim_cv_tty_mode, group: $vim_cv_tty_group" >&6; }
10594      else
10595	vim_cv_tty_group=world
10596	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ptys are world accessible" >&5
10597$as_echo "ptys are world accessible" >&6; }
10598      fi
10599
10600else
10601
10602      vim_cv_tty_group=world
10603      { $as_echo "$as_me:${as_lineno-$LINENO}: result: can't determine - assume ptys are world accessible" >&5
10604$as_echo "can't determine - assume ptys are world accessible" >&6; }
10605
10606fi
10607rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10608  conftest.$ac_objext conftest.beam conftest.$ac_ext
10609fi
10610
10611
10612fi
10613{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vim_cv_tty_group" >&5
10614$as_echo "$vim_cv_tty_group" >&6; }
10615rm -f conftest_grp
10616
10617if test "x$vim_cv_tty_group" != "xworld" ; then
10618  cat >>confdefs.h <<_ACEOF
10619#define PTYGROUP $vim_cv_tty_group
10620_ACEOF
10621
10622  if test "x$vim_cv_tty_mode" = "x" ; then
10623    as_fn_error "It seems you're cross compiling and have 'vim_cv_tty_group' set, please also set the environment variable 'vim_cv_tty_mode' to the correct mode (probably 0620)" "$LINENO" 5
10624  else
10625    $as_echo "#define PTYMODE 0620" >>confdefs.h
10626
10627  fi
10628fi
10629
10630
10631{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
10632$as_echo_n "checking return type of signal handlers... " >&6; }
10633if test "${ac_cv_type_signal+set}" = set; then :
10634  $as_echo_n "(cached) " >&6
10635else
10636  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10637/* end confdefs.h.  */
10638#include <sys/types.h>
10639#include <signal.h>
10640
10641int
10642main ()
10643{
10644return *(signal (0, 0)) (0) == 1;
10645  ;
10646  return 0;
10647}
10648_ACEOF
10649if ac_fn_c_try_compile "$LINENO"; then :
10650  ac_cv_type_signal=int
10651else
10652  ac_cv_type_signal=void
10653fi
10654rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10655fi
10656{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
10657$as_echo "$ac_cv_type_signal" >&6; }
10658
10659cat >>confdefs.h <<_ACEOF
10660#define RETSIGTYPE $ac_cv_type_signal
10661_ACEOF
10662
10663
10664
10665if test $ac_cv_type_signal = void; then
10666  $as_echo "#define SIGRETURN return" >>confdefs.h
10667
10668else
10669  $as_echo "#define SIGRETURN return 0" >>confdefs.h
10670
10671fi
10672
10673{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sigcontext" >&5
10674$as_echo_n "checking for struct sigcontext... " >&6; }
10675cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10676/* end confdefs.h.  */
10677
10678#include <signal.h>
10679test_sig()
10680{
10681    struct sigcontext *scont;
10682    scont = (struct sigcontext *)0;
10683    return 1;
10684}
10685int
10686main ()
10687{
10688
10689  ;
10690  return 0;
10691}
10692_ACEOF
10693if ac_fn_c_try_compile "$LINENO"; then :
10694  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10695$as_echo "yes" >&6; }
10696		$as_echo "#define HAVE_SIGCONTEXT 1" >>confdefs.h
10697
10698else
10699  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10700$as_echo "no" >&6; }
10701fi
10702rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10703
10704{ $as_echo "$as_me:${as_lineno-$LINENO}: checking getcwd implementation is broken" >&5
10705$as_echo_n "checking getcwd implementation is broken... " >&6; }
10706if test "${vim_cv_getcwd_broken+set}" = set; then :
10707  $as_echo_n "(cached) " >&6
10708else
10709
10710    if test "$cross_compiling" = yes; then :
10711
10712      as_fn_error "cross-compiling: please set 'vim_cv_getcwd_broken'" "$LINENO" 5
10713
10714else
10715  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10716/* end confdefs.h.  */
10717
10718#include "confdefs.h"
10719#ifdef HAVE_UNISTD_H
10720#include <unistd.h>
10721#endif
10722char *dagger[] = { "IFS=pwd", 0 };
10723main()
10724{
10725  char buffer[500];
10726  extern char **environ;
10727  environ = dagger;
10728  return getcwd(buffer, 500) ? 0 : 1;
10729}
10730
10731_ACEOF
10732if ac_fn_c_try_run "$LINENO"; then :
10733
10734      vim_cv_getcwd_broken=no
10735
10736else
10737
10738      vim_cv_getcwd_broken=yes
10739
10740fi
10741rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10742  conftest.$ac_objext conftest.beam conftest.$ac_ext
10743fi
10744
10745
10746fi
10747{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vim_cv_getcwd_broken" >&5
10748$as_echo "$vim_cv_getcwd_broken" >&6; }
10749
10750if test "x$vim_cv_getcwd_broken" = "xyes" ; then
10751  $as_echo "#define BAD_GETCWD 1" >>confdefs.h
10752
10753fi
10754
10755for ac_func in bcmp fchdir fchown fsync getcwd getpseudotty \
10756	getpwent getpwnam getpwuid getrlimit gettimeofday getwd lstat memcmp \
10757	memset mkdtemp nanosleep opendir putenv qsort readlink select setenv \
10758	setpgid setsid sigaltstack sigstack sigset sigsetjmp sigaction \
10759	sigvec strcasecmp strerror strftime stricmp strncasecmp \
10760	strnicmp strpbrk strtol tgetent towlower towupper iswupper \
10761	usleep utime utimes
10762do :
10763  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10764ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10765eval as_val=\$$as_ac_var
10766   if test "x$as_val" = x""yes; then :
10767  cat >>confdefs.h <<_ACEOF
10768#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10769_ACEOF
10770
10771fi
10772done
10773
10774{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
10775$as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
10776if test "${ac_cv_sys_largefile_source+set}" = set; then :
10777  $as_echo_n "(cached) " >&6
10778else
10779  while :; do
10780  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10781/* end confdefs.h.  */
10782#include <sys/types.h> /* for off_t */
10783     #include <stdio.h>
10784int
10785main ()
10786{
10787int (*fp) (FILE *, off_t, int) = fseeko;
10788     return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
10789  ;
10790  return 0;
10791}
10792_ACEOF
10793if ac_fn_c_try_link "$LINENO"; then :
10794  ac_cv_sys_largefile_source=no; break
10795fi
10796rm -f core conftest.err conftest.$ac_objext \
10797    conftest$ac_exeext conftest.$ac_ext
10798  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10799/* end confdefs.h.  */
10800#define _LARGEFILE_SOURCE 1
10801#include <sys/types.h> /* for off_t */
10802     #include <stdio.h>
10803int
10804main ()
10805{
10806int (*fp) (FILE *, off_t, int) = fseeko;
10807     return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
10808  ;
10809  return 0;
10810}
10811_ACEOF
10812if ac_fn_c_try_link "$LINENO"; then :
10813  ac_cv_sys_largefile_source=1; break
10814fi
10815rm -f core conftest.err conftest.$ac_objext \
10816    conftest$ac_exeext conftest.$ac_ext
10817  ac_cv_sys_largefile_source=unknown
10818  break
10819done
10820fi
10821{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
10822$as_echo "$ac_cv_sys_largefile_source" >&6; }
10823case $ac_cv_sys_largefile_source in #(
10824  no | unknown) ;;
10825  *)
10826cat >>confdefs.h <<_ACEOF
10827#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
10828_ACEOF
10829;;
10830esac
10831rm -rf conftest*
10832
10833# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
10834# in glibc 2.1.3, but that breaks too many other things.
10835# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
10836if test $ac_cv_sys_largefile_source != unknown; then
10837
10838$as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
10839
10840fi
10841
10842
10843# Check whether --enable-largefile was given.
10844if test "${enable_largefile+set}" = set; then :
10845  enableval=$enable_largefile;
10846fi
10847
10848if test "$enable_largefile" != no; then
10849
10850  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
10851$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
10852if test "${ac_cv_sys_largefile_CC+set}" = set; then :
10853  $as_echo_n "(cached) " >&6
10854else
10855  ac_cv_sys_largefile_CC=no
10856     if test "$GCC" != yes; then
10857       ac_save_CC=$CC
10858       while :; do
10859	 # IRIX 6.2 and later do not support large files by default,
10860	 # so use the C compiler's -n32 option if that helps.
10861	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10862/* end confdefs.h.  */
10863#include <sys/types.h>
10864 /* Check that off_t can represent 2**63 - 1 correctly.
10865    We can't simply define LARGE_OFF_T to be 9223372036854775807,
10866    since some C++ compilers masquerading as C compilers
10867    incorrectly reject 9223372036854775807.  */
10868#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
10869  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10870		       && LARGE_OFF_T % 2147483647 == 1)
10871		      ? 1 : -1];
10872int
10873main ()
10874{
10875
10876  ;
10877  return 0;
10878}
10879_ACEOF
10880	 if ac_fn_c_try_compile "$LINENO"; then :
10881  break
10882fi
10883rm -f core conftest.err conftest.$ac_objext
10884	 CC="$CC -n32"
10885	 if ac_fn_c_try_compile "$LINENO"; then :
10886  ac_cv_sys_largefile_CC=' -n32'; break
10887fi
10888rm -f core conftest.err conftest.$ac_objext
10889	 break
10890       done
10891       CC=$ac_save_CC
10892       rm -f conftest.$ac_ext
10893    fi
10894fi
10895{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
10896$as_echo "$ac_cv_sys_largefile_CC" >&6; }
10897  if test "$ac_cv_sys_largefile_CC" != no; then
10898    CC=$CC$ac_cv_sys_largefile_CC
10899  fi
10900
10901  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
10902$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
10903if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
10904  $as_echo_n "(cached) " >&6
10905else
10906  while :; do
10907  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10908/* end confdefs.h.  */
10909#include <sys/types.h>
10910 /* Check that off_t can represent 2**63 - 1 correctly.
10911    We can't simply define LARGE_OFF_T to be 9223372036854775807,
10912    since some C++ compilers masquerading as C compilers
10913    incorrectly reject 9223372036854775807.  */
10914#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
10915  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10916		       && LARGE_OFF_T % 2147483647 == 1)
10917		      ? 1 : -1];
10918int
10919main ()
10920{
10921
10922  ;
10923  return 0;
10924}
10925_ACEOF
10926if ac_fn_c_try_compile "$LINENO"; then :
10927  ac_cv_sys_file_offset_bits=no; break
10928fi
10929rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10930  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10931/* end confdefs.h.  */
10932#define _FILE_OFFSET_BITS 64
10933#include <sys/types.h>
10934 /* Check that off_t can represent 2**63 - 1 correctly.
10935    We can't simply define LARGE_OFF_T to be 9223372036854775807,
10936    since some C++ compilers masquerading as C compilers
10937    incorrectly reject 9223372036854775807.  */
10938#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
10939  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10940		       && LARGE_OFF_T % 2147483647 == 1)
10941		      ? 1 : -1];
10942int
10943main ()
10944{
10945
10946  ;
10947  return 0;
10948}
10949_ACEOF
10950if ac_fn_c_try_compile "$LINENO"; then :
10951  ac_cv_sys_file_offset_bits=64; break
10952fi
10953rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10954  ac_cv_sys_file_offset_bits=unknown
10955  break
10956done
10957fi
10958{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
10959$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
10960case $ac_cv_sys_file_offset_bits in #(
10961  no | unknown) ;;
10962  *)
10963cat >>confdefs.h <<_ACEOF
10964#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
10965_ACEOF
10966;;
10967esac
10968rm -rf conftest*
10969  if test $ac_cv_sys_file_offset_bits = unknown; then
10970    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
10971$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
10972if test "${ac_cv_sys_large_files+set}" = set; then :
10973  $as_echo_n "(cached) " >&6
10974else
10975  while :; do
10976  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10977/* end confdefs.h.  */
10978#include <sys/types.h>
10979 /* Check that off_t can represent 2**63 - 1 correctly.
10980    We can't simply define LARGE_OFF_T to be 9223372036854775807,
10981    since some C++ compilers masquerading as C compilers
10982    incorrectly reject 9223372036854775807.  */
10983#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
10984  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
10985		       && LARGE_OFF_T % 2147483647 == 1)
10986		      ? 1 : -1];
10987int
10988main ()
10989{
10990
10991  ;
10992  return 0;
10993}
10994_ACEOF
10995if ac_fn_c_try_compile "$LINENO"; then :
10996  ac_cv_sys_large_files=no; break
10997fi
10998rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10999  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11000/* end confdefs.h.  */
11001#define _LARGE_FILES 1
11002#include <sys/types.h>
11003 /* Check that off_t can represent 2**63 - 1 correctly.
11004    We can't simply define LARGE_OFF_T to be 9223372036854775807,
11005    since some C++ compilers masquerading as C compilers
11006    incorrectly reject 9223372036854775807.  */
11007#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
11008  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
11009		       && LARGE_OFF_T % 2147483647 == 1)
11010		      ? 1 : -1];
11011int
11012main ()
11013{
11014
11015  ;
11016  return 0;
11017}
11018_ACEOF
11019if ac_fn_c_try_compile "$LINENO"; then :
11020  ac_cv_sys_large_files=1; break
11021fi
11022rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11023  ac_cv_sys_large_files=unknown
11024  break
11025done
11026fi
11027{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
11028$as_echo "$ac_cv_sys_large_files" >&6; }
11029case $ac_cv_sys_large_files in #(
11030  no | unknown) ;;
11031  *)
11032cat >>confdefs.h <<_ACEOF
11033#define _LARGE_FILES $ac_cv_sys_large_files
11034_ACEOF
11035;;
11036esac
11037rm -rf conftest*
11038  fi
11039fi
11040
11041
11042{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_blksize" >&5
11043$as_echo_n "checking for st_blksize... " >&6; }
11044cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11045/* end confdefs.h.  */
11046#include <sys/types.h>
11047#include <sys/stat.h>
11048int
11049main ()
11050{
11051	struct stat st;
11052	int n;
11053
11054	stat("/", &st);
11055	n = (int)st.st_blksize;
11056  ;
11057  return 0;
11058}
11059_ACEOF
11060if ac_fn_c_try_compile "$LINENO"; then :
11061  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11062$as_echo "yes" >&6; }; $as_echo "#define HAVE_ST_BLKSIZE 1" >>confdefs.h
11063
11064else
11065  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11066$as_echo "no" >&6; }
11067fi
11068rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11069
11070{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat() ignores a trailing slash" >&5
11071$as_echo_n "checking whether stat() ignores a trailing slash... " >&6; }
11072if test "${vim_cv_stat_ignores_slash+set}" = set; then :
11073  $as_echo_n "(cached) " >&6
11074else
11075
11076    if test "$cross_compiling" = yes; then :
11077
11078      as_fn_error "cross-compiling: please set 'vim_cv_stat_ignores_slash'" "$LINENO" 5
11079
11080else
11081  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11082/* end confdefs.h.  */
11083
11084#include "confdefs.h"
11085#if STDC_HEADERS
11086# include <stdlib.h>
11087# include <stddef.h>
11088#endif
11089#include <sys/types.h>
11090#include <sys/stat.h>
11091main() {struct stat st;  exit(stat("configure/", &st) != 0); }
11092
11093_ACEOF
11094if ac_fn_c_try_run "$LINENO"; then :
11095
11096      vim_cv_stat_ignores_slash=yes
11097
11098else
11099
11100      vim_cv_stat_ignores_slash=no
11101
11102fi
11103rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11104  conftest.$ac_objext conftest.beam conftest.$ac_ext
11105fi
11106
11107
11108fi
11109{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vim_cv_stat_ignores_slash" >&5
11110$as_echo "$vim_cv_stat_ignores_slash" >&6; }
11111
11112if test "x$vim_cv_stat_ignores_slash" = "xyes" ; then
11113  $as_echo "#define STAT_IGNORES_SLASH 1" >>confdefs.h
11114
11115fi
11116
11117{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv_open()" >&5
11118$as_echo_n "checking for iconv_open()... " >&6; }
11119save_LIBS="$LIBS"
11120LIBS="$LIBS -liconv"
11121cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11122/* end confdefs.h.  */
11123
11124#ifdef HAVE_ICONV_H
11125# include <iconv.h>
11126#endif
11127
11128int
11129main ()
11130{
11131iconv_open("fr", "to");
11132  ;
11133  return 0;
11134}
11135_ACEOF
11136if ac_fn_c_try_link "$LINENO"; then :
11137  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; with -liconv" >&5
11138$as_echo "yes; with -liconv" >&6; }; $as_echo "#define HAVE_ICONV 1" >>confdefs.h
11139
11140else
11141  LIBS="$save_LIBS"
11142    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11143/* end confdefs.h.  */
11144
11145#ifdef HAVE_ICONV_H
11146# include <iconv.h>
11147#endif
11148
11149int
11150main ()
11151{
11152iconv_open("fr", "to");
11153  ;
11154  return 0;
11155}
11156_ACEOF
11157if ac_fn_c_try_link "$LINENO"; then :
11158  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11159$as_echo "yes" >&6; }; $as_echo "#define HAVE_ICONV 1" >>confdefs.h
11160
11161else
11162  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11163$as_echo "no" >&6; }
11164fi
11165rm -f core conftest.err conftest.$ac_objext \
11166    conftest$ac_exeext conftest.$ac_ext
11167fi
11168rm -f core conftest.err conftest.$ac_objext \
11169    conftest$ac_exeext conftest.$ac_ext
11170
11171
11172{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo(CODESET)" >&5
11173$as_echo_n "checking for nl_langinfo(CODESET)... " >&6; }
11174cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11175/* end confdefs.h.  */
11176
11177#ifdef HAVE_LANGINFO_H
11178# include <langinfo.h>
11179#endif
11180
11181int
11182main ()
11183{
11184char *cs = nl_langinfo(CODESET);
11185  ;
11186  return 0;
11187}
11188_ACEOF
11189if ac_fn_c_try_link "$LINENO"; then :
11190  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11191$as_echo "yes" >&6; }; $as_echo "#define HAVE_NL_LANGINFO_CODESET 1" >>confdefs.h
11192
11193else
11194  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11195$as_echo "no" >&6; }
11196fi
11197rm -f core conftest.err conftest.$ac_objext \
11198    conftest$ac_exeext conftest.$ac_ext
11199
11200{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for strtod in -lm" >&5
11201$as_echo_n "checking for strtod in -lm... " >&6; }
11202if test "${ac_cv_lib_m_strtod+set}" = set; then :
11203  $as_echo_n "(cached) " >&6
11204else
11205  ac_check_lib_save_LIBS=$LIBS
11206LIBS="-lm  $LIBS"
11207cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11208/* end confdefs.h.  */
11209
11210/* Override any GCC internal prototype to avoid an error.
11211   Use char because int might match the return type of a GCC
11212   builtin and then its argument prototype would still apply.  */
11213#ifdef __cplusplus
11214extern "C"
11215#endif
11216char strtod ();
11217int
11218main ()
11219{
11220return strtod ();
11221  ;
11222  return 0;
11223}
11224_ACEOF
11225if ac_fn_c_try_link "$LINENO"; then :
11226  ac_cv_lib_m_strtod=yes
11227else
11228  ac_cv_lib_m_strtod=no
11229fi
11230rm -f core conftest.err conftest.$ac_objext \
11231    conftest$ac_exeext conftest.$ac_ext
11232LIBS=$ac_check_lib_save_LIBS
11233fi
11234{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_strtod" >&5
11235$as_echo "$ac_cv_lib_m_strtod" >&6; }
11236if test "x$ac_cv_lib_m_strtod" = x""yes; then :
11237  cat >>confdefs.h <<_ACEOF
11238#define HAVE_LIBM 1
11239_ACEOF
11240
11241  LIBS="-lm $LIBS"
11242
11243fi
11244
11245{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for strtod() and other floating point functions" >&5
11246$as_echo_n "checking for strtod() and other floating point functions... " >&6; }
11247cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11248/* end confdefs.h.  */
11249
11250#ifdef HAVE_MATH_H
11251# include <math.h>
11252#endif
11253#if STDC_HEADERS
11254# include <stdlib.h>
11255# include <stddef.h>
11256#endif
11257
11258int
11259main ()
11260{
11261char *s; double d;
11262    d = strtod("1.1", &s);
11263    d = fabs(1.11);
11264    d = ceil(1.11);
11265    d = floor(1.11);
11266    d = log10(1.11);
11267    d = pow(1.11, 2.22);
11268    d = sqrt(1.11);
11269    d = sin(1.11);
11270    d = cos(1.11);
11271    d = atan(1.11);
11272
11273  ;
11274  return 0;
11275}
11276_ACEOF
11277if ac_fn_c_try_link "$LINENO"; then :
11278  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11279$as_echo "yes" >&6; }; $as_echo "#define HAVE_FLOAT_FUNCS 1" >>confdefs.h
11280
11281else
11282  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11283$as_echo "no" >&6; }
11284fi
11285rm -f core conftest.err conftest.$ac_objext \
11286    conftest$ac_exeext conftest.$ac_ext
11287
11288{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-acl argument" >&5
11289$as_echo_n "checking --disable-acl argument... " >&6; }
11290# Check whether --enable-acl was given.
11291if test "${enable_acl+set}" = set; then :
11292  enableval=$enable_acl;
11293else
11294  enable_acl="yes"
11295fi
11296
11297if test "$enable_acl" = "yes"; then
11298{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11299$as_echo "no" >&6; }
11300{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for acl_get_file in -lposix1e" >&5
11301$as_echo_n "checking for acl_get_file in -lposix1e... " >&6; }
11302if test "${ac_cv_lib_posix1e_acl_get_file+set}" = set; then :
11303  $as_echo_n "(cached) " >&6
11304else
11305  ac_check_lib_save_LIBS=$LIBS
11306LIBS="-lposix1e  $LIBS"
11307cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11308/* end confdefs.h.  */
11309
11310/* Override any GCC internal prototype to avoid an error.
11311   Use char because int might match the return type of a GCC
11312   builtin and then its argument prototype would still apply.  */
11313#ifdef __cplusplus
11314extern "C"
11315#endif
11316char acl_get_file ();
11317int
11318main ()
11319{
11320return acl_get_file ();
11321  ;
11322  return 0;
11323}
11324_ACEOF
11325if ac_fn_c_try_link "$LINENO"; then :
11326  ac_cv_lib_posix1e_acl_get_file=yes
11327else
11328  ac_cv_lib_posix1e_acl_get_file=no
11329fi
11330rm -f core conftest.err conftest.$ac_objext \
11331    conftest$ac_exeext conftest.$ac_ext
11332LIBS=$ac_check_lib_save_LIBS
11333fi
11334{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix1e_acl_get_file" >&5
11335$as_echo "$ac_cv_lib_posix1e_acl_get_file" >&6; }
11336if test "x$ac_cv_lib_posix1e_acl_get_file" = x""yes; then :
11337  LIBS="$LIBS -lposix1e"
11338else
11339  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for acl_get_file in -lacl" >&5
11340$as_echo_n "checking for acl_get_file in -lacl... " >&6; }
11341if test "${ac_cv_lib_acl_acl_get_file+set}" = set; then :
11342  $as_echo_n "(cached) " >&6
11343else
11344  ac_check_lib_save_LIBS=$LIBS
11345LIBS="-lacl  $LIBS"
11346cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11347/* end confdefs.h.  */
11348
11349/* Override any GCC internal prototype to avoid an error.
11350   Use char because int might match the return type of a GCC
11351   builtin and then its argument prototype would still apply.  */
11352#ifdef __cplusplus
11353extern "C"
11354#endif
11355char acl_get_file ();
11356int
11357main ()
11358{
11359return acl_get_file ();
11360  ;
11361  return 0;
11362}
11363_ACEOF
11364if ac_fn_c_try_link "$LINENO"; then :
11365  ac_cv_lib_acl_acl_get_file=yes
11366else
11367  ac_cv_lib_acl_acl_get_file=no
11368fi
11369rm -f core conftest.err conftest.$ac_objext \
11370    conftest$ac_exeext conftest.$ac_ext
11371LIBS=$ac_check_lib_save_LIBS
11372fi
11373{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_acl_acl_get_file" >&5
11374$as_echo "$ac_cv_lib_acl_acl_get_file" >&6; }
11375if test "x$ac_cv_lib_acl_acl_get_file" = x""yes; then :
11376  LIBS="$LIBS -lacl"
11377		  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgetxattr in -lattr" >&5
11378$as_echo_n "checking for fgetxattr in -lattr... " >&6; }
11379if test "${ac_cv_lib_attr_fgetxattr+set}" = set; then :
11380  $as_echo_n "(cached) " >&6
11381else
11382  ac_check_lib_save_LIBS=$LIBS
11383LIBS="-lattr  $LIBS"
11384cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11385/* end confdefs.h.  */
11386
11387/* Override any GCC internal prototype to avoid an error.
11388   Use char because int might match the return type of a GCC
11389   builtin and then its argument prototype would still apply.  */
11390#ifdef __cplusplus
11391extern "C"
11392#endif
11393char fgetxattr ();
11394int
11395main ()
11396{
11397return fgetxattr ();
11398  ;
11399  return 0;
11400}
11401_ACEOF
11402if ac_fn_c_try_link "$LINENO"; then :
11403  ac_cv_lib_attr_fgetxattr=yes
11404else
11405  ac_cv_lib_attr_fgetxattr=no
11406fi
11407rm -f core conftest.err conftest.$ac_objext \
11408    conftest$ac_exeext conftest.$ac_ext
11409LIBS=$ac_check_lib_save_LIBS
11410fi
11411{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_attr_fgetxattr" >&5
11412$as_echo "$ac_cv_lib_attr_fgetxattr" >&6; }
11413if test "x$ac_cv_lib_attr_fgetxattr" = x""yes; then :
11414  LIBS="$LIBS -lattr"
11415fi
11416
11417fi
11418
11419fi
11420
11421
11422{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for POSIX ACL support" >&5
11423$as_echo_n "checking for POSIX ACL support... " >&6; }
11424cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11425/* end confdefs.h.  */
11426
11427#include <sys/types.h>
11428#ifdef HAVE_SYS_ACL_H
11429# include <sys/acl.h>
11430#endif
11431acl_t acl;
11432int
11433main ()
11434{
11435acl = acl_get_file("foo", ACL_TYPE_ACCESS);
11436	acl_set_file("foo", ACL_TYPE_ACCESS, acl);
11437	acl_free(acl);
11438  ;
11439  return 0;
11440}
11441_ACEOF
11442if ac_fn_c_try_link "$LINENO"; then :
11443  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11444$as_echo "yes" >&6; }; $as_echo "#define HAVE_POSIX_ACL 1" >>confdefs.h
11445
11446else
11447  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11448$as_echo "no" >&6; }
11449fi
11450rm -f core conftest.err conftest.$ac_objext \
11451    conftest$ac_exeext conftest.$ac_ext
11452
11453{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for acl_get in -lsec" >&5
11454$as_echo_n "checking for acl_get in -lsec... " >&6; }
11455if test "${ac_cv_lib_sec_acl_get+set}" = set; then :
11456  $as_echo_n "(cached) " >&6
11457else
11458  ac_check_lib_save_LIBS=$LIBS
11459LIBS="-lsec  $LIBS"
11460cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11461/* end confdefs.h.  */
11462
11463/* Override any GCC internal prototype to avoid an error.
11464   Use char because int might match the return type of a GCC
11465   builtin and then its argument prototype would still apply.  */
11466#ifdef __cplusplus
11467extern "C"
11468#endif
11469char acl_get ();
11470int
11471main ()
11472{
11473return acl_get ();
11474  ;
11475  return 0;
11476}
11477_ACEOF
11478if ac_fn_c_try_link "$LINENO"; then :
11479  ac_cv_lib_sec_acl_get=yes
11480else
11481  ac_cv_lib_sec_acl_get=no
11482fi
11483rm -f core conftest.err conftest.$ac_objext \
11484    conftest$ac_exeext conftest.$ac_ext
11485LIBS=$ac_check_lib_save_LIBS
11486fi
11487{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sec_acl_get" >&5
11488$as_echo "$ac_cv_lib_sec_acl_get" >&6; }
11489if test "x$ac_cv_lib_sec_acl_get" = x""yes; then :
11490  LIBS="$LIBS -lsec"; $as_echo "#define HAVE_SOLARIS_ZFS_ACL 1" >>confdefs.h
11491
11492else
11493  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Solaris ACL support" >&5
11494$as_echo_n "checking for Solaris ACL support... " >&6; }
11495cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11496/* end confdefs.h.  */
11497
11498#ifdef HAVE_SYS_ACL_H
11499# include <sys/acl.h>
11500#endif
11501int
11502main ()
11503{
11504acl("foo", GETACLCNT, 0, NULL);
11505
11506  ;
11507  return 0;
11508}
11509_ACEOF
11510if ac_fn_c_try_link "$LINENO"; then :
11511  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11512$as_echo "yes" >&6; }; $as_echo "#define HAVE_SOLARIS_ACL 1" >>confdefs.h
11513
11514else
11515  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11516$as_echo "no" >&6; }
11517fi
11518rm -f core conftest.err conftest.$ac_objext \
11519    conftest$ac_exeext conftest.$ac_ext
11520fi
11521
11522
11523{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for AIX ACL support" >&5
11524$as_echo_n "checking for AIX ACL support... " >&6; }
11525cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11526/* end confdefs.h.  */
11527
11528#if STDC_HEADERS
11529# include <stdlib.h>
11530# include <stddef.h>
11531#endif
11532#ifdef HAVE_SYS_ACL_H
11533# include <sys/acl.h>
11534#endif
11535#ifdef HAVE_SYS_ACCESS_H
11536# include <sys/access.h>
11537#endif
11538#define _ALL_SOURCE
11539
11540#include <sys/stat.h>
11541
11542int aclsize;
11543struct acl *aclent;
11544int
11545main ()
11546{
11547aclsize = sizeof(struct acl);
11548	aclent = (void *)malloc(aclsize);
11549	statacl("foo", STX_NORMAL, aclent, aclsize);
11550
11551  ;
11552  return 0;
11553}
11554_ACEOF
11555if ac_fn_c_try_link "$LINENO"; then :
11556  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11557$as_echo "yes" >&6; }; $as_echo "#define HAVE_AIX_ACL 1" >>confdefs.h
11558
11559else
11560  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11561$as_echo "no" >&6; }
11562fi
11563rm -f core conftest.err conftest.$ac_objext \
11564    conftest$ac_exeext conftest.$ac_ext
11565else
11566  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11567$as_echo "yes" >&6; }
11568fi
11569
11570{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-gpm argument" >&5
11571$as_echo_n "checking --disable-gpm argument... " >&6; }
11572# Check whether --enable-gpm was given.
11573if test "${enable_gpm+set}" = set; then :
11574  enableval=$enable_gpm;
11575else
11576  enable_gpm="yes"
11577fi
11578
11579
11580if test "$enable_gpm" = "yes"; then
11581  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11582$as_echo "no" >&6; }
11583    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gpm" >&5
11584$as_echo_n "checking for gpm... " >&6; }
11585if test "${vi_cv_have_gpm+set}" = set; then :
11586  $as_echo_n "(cached) " >&6
11587else
11588  olibs="$LIBS" ; LIBS="-lgpm"
11589	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11590/* end confdefs.h.  */
11591#include <gpm.h>
11592	    #include <linux/keyboard.h>
11593int
11594main ()
11595{
11596Gpm_GetLibVersion(NULL);
11597  ;
11598  return 0;
11599}
11600_ACEOF
11601if ac_fn_c_try_link "$LINENO"; then :
11602  	    	    vi_cv_have_gpm=yes
11603else
11604  vi_cv_have_gpm=no
11605fi
11606rm -f core conftest.err conftest.$ac_objext \
11607    conftest$ac_exeext conftest.$ac_ext
11608	LIBS="$olibs"
11609
11610fi
11611{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_have_gpm" >&5
11612$as_echo "$vi_cv_have_gpm" >&6; }
11613  if test $vi_cv_have_gpm = yes; then
11614    LIBS="$LIBS -lgpm"
11615    $as_echo "#define HAVE_GPM 1" >>confdefs.h
11616
11617  fi
11618else
11619  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11620$as_echo "yes" >&6; }
11621fi
11622
11623{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-sysmouse argument" >&5
11624$as_echo_n "checking --disable-sysmouse argument... " >&6; }
11625# Check whether --enable-sysmouse was given.
11626if test "${enable_sysmouse+set}" = set; then :
11627  enableval=$enable_sysmouse;
11628else
11629  enable_sysmouse="yes"
11630fi
11631
11632
11633if test "$enable_sysmouse" = "yes"; then
11634  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11635$as_echo "no" >&6; }
11636        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysmouse" >&5
11637$as_echo_n "checking for sysmouse... " >&6; }
11638if test "${vi_cv_have_sysmouse+set}" = set; then :
11639  $as_echo_n "(cached) " >&6
11640else
11641  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11642/* end confdefs.h.  */
11643#include <sys/consio.h>
11644	     #include <signal.h>
11645	     #include <sys/fbio.h>
11646int
11647main ()
11648{
11649struct mouse_info   mouse;
11650	     mouse.operation = MOUSE_MODE;
11651	     mouse.operation = MOUSE_SHOW;
11652	     mouse.u.mode.mode = 0;
11653	     mouse.u.mode.signal = SIGUSR2;
11654  ;
11655  return 0;
11656}
11657_ACEOF
11658if ac_fn_c_try_link "$LINENO"; then :
11659  vi_cv_have_sysmouse=yes
11660else
11661  vi_cv_have_sysmouse=no
11662fi
11663rm -f core conftest.err conftest.$ac_objext \
11664    conftest$ac_exeext conftest.$ac_ext
11665
11666fi
11667{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_have_sysmouse" >&5
11668$as_echo "$vi_cv_have_sysmouse" >&6; }
11669  if test $vi_cv_have_sysmouse = yes; then
11670    $as_echo "#define HAVE_SYSMOUSE 1" >>confdefs.h
11671
11672  fi
11673else
11674  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11675$as_echo "yes" >&6; }
11676fi
11677
11678{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for FD_CLOEXEC" >&5
11679$as_echo_n "checking for FD_CLOEXEC... " >&6; }
11680cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11681/* end confdefs.h.  */
11682#if HAVE_FCNTL_H
11683# include <fcntl.h>
11684#endif
11685int
11686main ()
11687{
11688	int flag = FD_CLOEXEC;
11689  ;
11690  return 0;
11691}
11692_ACEOF
11693if ac_fn_c_try_compile "$LINENO"; then :
11694  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11695$as_echo "yes" >&6; }; $as_echo "#define HAVE_FD_CLOEXEC 1" >>confdefs.h
11696
11697else
11698  { $as_echo "$as_me:${as_lineno-$LINENO}: result: not usable" >&5
11699$as_echo "not usable" >&6; }
11700fi
11701rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11702
11703{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for rename" >&5
11704$as_echo_n "checking for rename... " >&6; }
11705cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11706/* end confdefs.h.  */
11707#include <stdio.h>
11708int
11709main ()
11710{
11711rename("this", "that")
11712  ;
11713  return 0;
11714}
11715_ACEOF
11716if ac_fn_c_try_link "$LINENO"; then :
11717  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11718$as_echo "yes" >&6; }; $as_echo "#define HAVE_RENAME 1" >>confdefs.h
11719
11720else
11721  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11722$as_echo "no" >&6; }
11723fi
11724rm -f core conftest.err conftest.$ac_objext \
11725    conftest$ac_exeext conftest.$ac_ext
11726
11727{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysctl" >&5
11728$as_echo_n "checking for sysctl... " >&6; }
11729cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11730/* end confdefs.h.  */
11731#include <sys/types.h>
11732#include <sys/sysctl.h>
11733int
11734main ()
11735{
11736	int mib[2], r;
11737	size_t len;
11738
11739	mib[0] = CTL_HW;
11740	mib[1] = HW_USERMEM;
11741	len = sizeof(r);
11742	(void)sysctl(mib, 2, &r, &len, (void *)0, (size_t)0);
11743
11744  ;
11745  return 0;
11746}
11747_ACEOF
11748if ac_fn_c_try_compile "$LINENO"; then :
11749  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11750$as_echo "yes" >&6; }; $as_echo "#define HAVE_SYSCTL 1" >>confdefs.h
11751
11752else
11753  { $as_echo "$as_me:${as_lineno-$LINENO}: result: not usable" >&5
11754$as_echo "not usable" >&6; }
11755fi
11756rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11757
11758{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysinfo" >&5
11759$as_echo_n "checking for sysinfo... " >&6; }
11760cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11761/* end confdefs.h.  */
11762#include <sys/types.h>
11763#include <sys/sysinfo.h>
11764int
11765main ()
11766{
11767	struct sysinfo sinfo;
11768	int t;
11769
11770	(void)sysinfo(&sinfo);
11771	t = sinfo.totalram;
11772
11773  ;
11774  return 0;
11775}
11776_ACEOF
11777if ac_fn_c_try_compile "$LINENO"; then :
11778  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11779$as_echo "yes" >&6; }; $as_echo "#define HAVE_SYSINFO 1" >>confdefs.h
11780
11781else
11782  { $as_echo "$as_me:${as_lineno-$LINENO}: result: not usable" >&5
11783$as_echo "not usable" >&6; }
11784fi
11785rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11786
11787{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysinfo.mem_unit" >&5
11788$as_echo_n "checking for sysinfo.mem_unit... " >&6; }
11789cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11790/* end confdefs.h.  */
11791#include <sys/types.h>
11792#include <sys/sysinfo.h>
11793int
11794main ()
11795{
11796	struct sysinfo sinfo;
11797	sinfo.mem_unit = 1;
11798
11799  ;
11800  return 0;
11801}
11802_ACEOF
11803if ac_fn_c_try_compile "$LINENO"; then :
11804  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11805$as_echo "yes" >&6; }; $as_echo "#define HAVE_SYSINFO_MEM_UNIT 1" >>confdefs.h
11806
11807else
11808  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11809$as_echo "no" >&6; }
11810fi
11811rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11812
11813{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysconf" >&5
11814$as_echo_n "checking for sysconf... " >&6; }
11815cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11816/* end confdefs.h.  */
11817#include <unistd.h>
11818int
11819main ()
11820{
11821	(void)sysconf(_SC_PAGESIZE);
11822	(void)sysconf(_SC_PHYS_PAGES);
11823
11824  ;
11825  return 0;
11826}
11827_ACEOF
11828if ac_fn_c_try_compile "$LINENO"; then :
11829  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11830$as_echo "yes" >&6; }; $as_echo "#define HAVE_SYSCONF 1" >>confdefs.h
11831
11832else
11833  { $as_echo "$as_me:${as_lineno-$LINENO}: result: not usable" >&5
11834$as_echo "not usable" >&6; }
11835fi
11836rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11837
11838# The cast to long int works around a bug in the HP C Compiler
11839# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11840# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11841# This bug is HP SR number 8606223364.
11842{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
11843$as_echo_n "checking size of int... " >&6; }
11844if test "${ac_cv_sizeof_int+set}" = set; then :
11845  $as_echo_n "(cached) " >&6
11846else
11847  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
11848
11849else
11850  if test "$ac_cv_type_int" = yes; then
11851     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11852$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11853{ as_fn_set_status 77
11854as_fn_error "cannot compute sizeof (int)
11855See \`config.log' for more details." "$LINENO" 5; }; }
11856   else
11857     ac_cv_sizeof_int=0
11858   fi
11859fi
11860
11861fi
11862{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
11863$as_echo "$ac_cv_sizeof_int" >&6; }
11864
11865
11866
11867cat >>confdefs.h <<_ACEOF
11868#define SIZEOF_INT $ac_cv_sizeof_int
11869_ACEOF
11870
11871
11872# The cast to long int works around a bug in the HP C Compiler
11873# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11874# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11875# This bug is HP SR number 8606223364.
11876{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
11877$as_echo_n "checking size of long... " >&6; }
11878if test "${ac_cv_sizeof_long+set}" = set; then :
11879  $as_echo_n "(cached) " >&6
11880else
11881  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
11882
11883else
11884  if test "$ac_cv_type_long" = yes; then
11885     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11886$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11887{ as_fn_set_status 77
11888as_fn_error "cannot compute sizeof (long)
11889See \`config.log' for more details." "$LINENO" 5; }; }
11890   else
11891     ac_cv_sizeof_long=0
11892   fi
11893fi
11894
11895fi
11896{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
11897$as_echo "$ac_cv_sizeof_long" >&6; }
11898
11899
11900
11901cat >>confdefs.h <<_ACEOF
11902#define SIZEOF_LONG $ac_cv_sizeof_long
11903_ACEOF
11904
11905
11906# The cast to long int works around a bug in the HP C Compiler
11907# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11908# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11909# This bug is HP SR number 8606223364.
11910{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
11911$as_echo_n "checking size of time_t... " >&6; }
11912if test "${ac_cv_sizeof_time_t+set}" = set; then :
11913  $as_echo_n "(cached) " >&6
11914else
11915  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t"        "$ac_includes_default"; then :
11916
11917else
11918  if test "$ac_cv_type_time_t" = yes; then
11919     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11920$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11921{ as_fn_set_status 77
11922as_fn_error "cannot compute sizeof (time_t)
11923See \`config.log' for more details." "$LINENO" 5; }; }
11924   else
11925     ac_cv_sizeof_time_t=0
11926   fi
11927fi
11928
11929fi
11930{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
11931$as_echo "$ac_cv_sizeof_time_t" >&6; }
11932
11933
11934
11935cat >>confdefs.h <<_ACEOF
11936#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
11937_ACEOF
11938
11939
11940# The cast to long int works around a bug in the HP C Compiler
11941# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11942# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11943# This bug is HP SR number 8606223364.
11944{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
11945$as_echo_n "checking size of off_t... " >&6; }
11946if test "${ac_cv_sizeof_off_t+set}" = set; then :
11947  $as_echo_n "(cached) " >&6
11948else
11949  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t"        "$ac_includes_default"; then :
11950
11951else
11952  if test "$ac_cv_type_off_t" = yes; then
11953     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11954$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11955{ as_fn_set_status 77
11956as_fn_error "cannot compute sizeof (off_t)
11957See \`config.log' for more details." "$LINENO" 5; }; }
11958   else
11959     ac_cv_sizeof_off_t=0
11960   fi
11961fi
11962
11963fi
11964{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
11965$as_echo "$ac_cv_sizeof_off_t" >&6; }
11966
11967
11968
11969cat >>confdefs.h <<_ACEOF
11970#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
11971_ACEOF
11972
11973
11974
11975{ $as_echo "$as_me:${as_lineno-$LINENO}: checking uint32_t is 32 bits" >&5
11976$as_echo_n "checking uint32_t is 32 bits... " >&6; }
11977if test "$cross_compiling" = yes; then :
11978  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check uint32_t when cross-compiling." >&5
11979$as_echo "$as_me: WARNING: cannot check uint32_t when cross-compiling." >&2;}
11980else
11981  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11982/* end confdefs.h.  */
11983
11984#ifdef HAVE_STDINT_H
11985# include <stdint.h>
11986#endif
11987#ifdef HAVE_INTTYPES_H
11988# include <inttypes.h>
11989#endif
11990main() {
11991  uint32_t nr1 = (uint32_t)-1;
11992  uint32_t nr2 = (uint32_t)0xffffffffUL;
11993  if (sizeof(uint32_t) != 4 || nr1 != 0xffffffffUL || nr2 + 1 != 0) exit(1);
11994  exit(0);
11995}
11996_ACEOF
11997if ac_fn_c_try_run "$LINENO"; then :
11998  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
11999$as_echo "ok" >&6; }
12000else
12001  as_fn_error "WRONG!  uint32_t not defined correctly." "$LINENO" 5
12002fi
12003rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12004  conftest.$ac_objext conftest.beam conftest.$ac_ext
12005fi
12006
12007
12008
12009bcopy_test_prog='
12010#include "confdefs.h"
12011#ifdef HAVE_STRING_H
12012# include <string.h>
12013#endif
12014#if STDC_HEADERS
12015# include <stdlib.h>
12016# include <stddef.h>
12017#endif
12018main() {
12019  char buf[10];
12020  strcpy(buf, "abcdefghi");
12021  mch_memmove(buf, buf + 2, 3);
12022  if (strncmp(buf, "ababcf", 6))
12023    exit(1);
12024  strcpy(buf, "abcdefghi");
12025  mch_memmove(buf + 2, buf, 3);
12026  if (strncmp(buf, "cdedef", 6))
12027    exit(1);
12028  exit(0); /* libc version works properly.  */
12029}'
12030
12031{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memmove handles overlaps" >&5
12032$as_echo_n "checking whether memmove handles overlaps... " >&6; }
12033if test "${vim_cv_memmove_handles_overlap+set}" = set; then :
12034  $as_echo_n "(cached) " >&6
12035else
12036
12037    if test "$cross_compiling" = yes; then :
12038
12039	as_fn_error "cross-compiling: please set 'vim_cv_memmove_handles_overlap'" "$LINENO" 5
12040
12041else
12042  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12043/* end confdefs.h.  */
12044#define mch_memmove(s,d,l) memmove(d,s,l) $bcopy_test_prog
12045_ACEOF
12046if ac_fn_c_try_run "$LINENO"; then :
12047
12048	vim_cv_memmove_handles_overlap=yes
12049
12050else
12051
12052	vim_cv_memmove_handles_overlap=no
12053
12054fi
12055rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12056  conftest.$ac_objext conftest.beam conftest.$ac_ext
12057fi
12058
12059
12060fi
12061{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vim_cv_memmove_handles_overlap" >&5
12062$as_echo "$vim_cv_memmove_handles_overlap" >&6; }
12063
12064if test "x$vim_cv_memmove_handles_overlap" = "xyes" ; then
12065  $as_echo "#define USEMEMMOVE 1" >>confdefs.h
12066
12067else
12068  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether bcopy handles overlaps" >&5
12069$as_echo_n "checking whether bcopy handles overlaps... " >&6; }
12070if test "${vim_cv_bcopy_handles_overlap+set}" = set; then :
12071  $as_echo_n "(cached) " >&6
12072else
12073
12074      if test "$cross_compiling" = yes; then :
12075
12076	as_fn_error "cross-compiling: please set 'vim_cv_bcopy_handles_overlap'" "$LINENO" 5
12077
12078else
12079  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12080/* end confdefs.h.  */
12081#define mch_bcopy(s,d,l) bcopy(d,s,l) $bcopy_test_prog
12082_ACEOF
12083if ac_fn_c_try_run "$LINENO"; then :
12084
12085	vim_cv_bcopy_handles_overlap=yes
12086
12087else
12088
12089	vim_cv_bcopy_handles_overlap=no
12090
12091fi
12092rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12093  conftest.$ac_objext conftest.beam conftest.$ac_ext
12094fi
12095
12096
12097fi
12098{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vim_cv_bcopy_handles_overlap" >&5
12099$as_echo "$vim_cv_bcopy_handles_overlap" >&6; }
12100
12101  if test "x$vim_cv_bcopy_handles_overlap" = "xyes" ; then
12102    $as_echo "#define USEBCOPY 1" >>confdefs.h
12103
12104  else
12105    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memcpy handles overlaps" >&5
12106$as_echo_n "checking whether memcpy handles overlaps... " >&6; }
12107if test "${vim_cv_memcpy_handles_overlap+set}" = set; then :
12108  $as_echo_n "(cached) " >&6
12109else
12110
12111	if test "$cross_compiling" = yes; then :
12112
12113	    as_fn_error "cross-compiling: please set 'vim_cv_memcpy_handles_overlap'" "$LINENO" 5
12114
12115else
12116  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12117/* end confdefs.h.  */
12118#define mch_memcpy(s,d,l) memcpy(d,s,l) $bcopy_test_prog
12119_ACEOF
12120if ac_fn_c_try_run "$LINENO"; then :
12121
12122	    vim_cv_memcpy_handles_overlap=yes
12123
12124else
12125
12126	    vim_cv_memcpy_handles_overlap=no
12127
12128fi
12129rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12130  conftest.$ac_objext conftest.beam conftest.$ac_ext
12131fi
12132
12133
12134fi
12135{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vim_cv_memcpy_handles_overlap" >&5
12136$as_echo "$vim_cv_memcpy_handles_overlap" >&6; }
12137
12138    if test "x$vim_cv_memcpy_handles_overlap" = "xyes" ; then
12139      $as_echo "#define USEMEMCPY 1" >>confdefs.h
12140
12141    fi
12142  fi
12143fi
12144
12145
12146
12147if test "$enable_multibyte" = "yes"; then
12148  cflags_save=$CFLAGS
12149  ldflags_save=$LDFLAGS
12150  if test "x$x_includes" != "xNONE" ; then
12151    CFLAGS="$CFLAGS -I$x_includes"
12152    LDFLAGS="$X_LIBS $LDFLAGS -lX11"
12153    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X_LOCALE needed" >&5
12154$as_echo_n "checking whether X_LOCALE needed... " >&6; }
12155    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12156/* end confdefs.h.  */
12157#include <X11/Xlocale.h>
12158int
12159main ()
12160{
12161
12162  ;
12163  return 0;
12164}
12165_ACEOF
12166if ac_fn_c_try_compile "$LINENO"; then :
12167  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12168/* end confdefs.h.  */
12169
12170/* Override any GCC internal prototype to avoid an error.
12171   Use char because int might match the return type of a GCC
12172   builtin and then its argument prototype would still apply.  */
12173#ifdef __cplusplus
12174extern "C"
12175#endif
12176char _Xsetlocale ();
12177int
12178main ()
12179{
12180return _Xsetlocale ();
12181  ;
12182  return 0;
12183}
12184_ACEOF
12185if ac_fn_c_try_link "$LINENO"; then :
12186  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12187$as_echo "yes" >&6; }
12188		$as_echo "#define X_LOCALE 1" >>confdefs.h
12189
12190else
12191  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12192$as_echo "no" >&6; }
12193fi
12194rm -f core conftest.err conftest.$ac_objext \
12195    conftest$ac_exeext conftest.$ac_ext
12196else
12197  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12198$as_echo "no" >&6; }
12199fi
12200rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12201  fi
12202  CFLAGS=$cflags_save
12203  LDFLAGS=$ldflags_save
12204fi
12205
12206{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _xpg4_setrunelocale in -lxpg4" >&5
12207$as_echo_n "checking for _xpg4_setrunelocale in -lxpg4... " >&6; }
12208if test "${ac_cv_lib_xpg4__xpg4_setrunelocale+set}" = set; then :
12209  $as_echo_n "(cached) " >&6
12210else
12211  ac_check_lib_save_LIBS=$LIBS
12212LIBS="-lxpg4  $LIBS"
12213cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12214/* end confdefs.h.  */
12215
12216/* Override any GCC internal prototype to avoid an error.
12217   Use char because int might match the return type of a GCC
12218   builtin and then its argument prototype would still apply.  */
12219#ifdef __cplusplus
12220extern "C"
12221#endif
12222char _xpg4_setrunelocale ();
12223int
12224main ()
12225{
12226return _xpg4_setrunelocale ();
12227  ;
12228  return 0;
12229}
12230_ACEOF
12231if ac_fn_c_try_link "$LINENO"; then :
12232  ac_cv_lib_xpg4__xpg4_setrunelocale=yes
12233else
12234  ac_cv_lib_xpg4__xpg4_setrunelocale=no
12235fi
12236rm -f core conftest.err conftest.$ac_objext \
12237    conftest$ac_exeext conftest.$ac_ext
12238LIBS=$ac_check_lib_save_LIBS
12239fi
12240{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xpg4__xpg4_setrunelocale" >&5
12241$as_echo "$ac_cv_lib_xpg4__xpg4_setrunelocale" >&6; }
12242if test "x$ac_cv_lib_xpg4__xpg4_setrunelocale" = x""yes; then :
12243  LIBS="$LIBS -lxpg4"
12244fi
12245
12246
12247{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to create tags" >&5
12248$as_echo_n "checking how to create tags... " >&6; }
12249test -f tags && mv tags tags.save
12250if (eval ctags --version /dev/null | grep Exuberant) < /dev/null 1>&5 2>&1; then
12251  TAGPRG="ctags -I INIT+ --fields=+S"
12252elif (eval exctags --version /dev/null | grep Exuberant) < /dev/null 1>&5 2>&1; then
12253  TAGPRG="exctags -I INIT+ --fields=+S"
12254elif (eval exuberant-ctags --version /dev/null | grep Exuberant) < /dev/null 1>&5 2>&1; then
12255  TAGPRG="exuberant-ctags -I INIT+ --fields=+S"
12256else
12257  TAGPRG="ctags"
12258  (eval etags	   /dev/null) < /dev/null 1>&5 2>&1 && TAGPRG="etags"
12259  (eval etags -c   /dev/null) < /dev/null 1>&5 2>&1 && TAGPRG="etags -c"
12260  (eval ctags	   /dev/null) < /dev/null 1>&5 2>&1 && TAGPRG="ctags"
12261  (eval ctags -t   /dev/null) < /dev/null 1>&5 2>&1 && TAGPRG="ctags -t"
12262  (eval ctags -ts  /dev/null) < /dev/null 1>&5 2>&1 && TAGPRG="ctags -ts"
12263  (eval ctags -tvs /dev/null) < /dev/null 1>&5 2>&1 && TAGPRG="ctags -tvs"
12264  (eval ctags -i+m /dev/null) < /dev/null 1>&5 2>&1 && TAGPRG="ctags -i+m"
12265fi
12266test -f tags.save && mv tags.save tags
12267{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAGPRG" >&5
12268$as_echo "$TAGPRG" >&6; }
12269
12270{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run man with a section nr" >&5
12271$as_echo_n "checking how to run man with a section nr... " >&6; }
12272MANDEF="man"
12273(eval MANPAGER=cat PAGER=cat man -s 2 read) < /dev/null > /dev/null 2>&5 && MANDEF="man -s"
12274{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANDEF" >&5
12275$as_echo "$MANDEF" >&6; }
12276if test "$MANDEF" = "man -s"; then
12277  $as_echo "#define USEMAN_S 1" >>confdefs.h
12278
12279fi
12280
12281{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-nls argument" >&5
12282$as_echo_n "checking --disable-nls argument... " >&6; }
12283# Check whether --enable-nls was given.
12284if test "${enable_nls+set}" = set; then :
12285  enableval=$enable_nls;
12286else
12287  enable_nls="yes"
12288fi
12289
12290
12291if test "$enable_nls" = "yes"; then
12292  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12293$as_echo "no" >&6; }
12294
12295  INSTALL_LANGS=install-languages
12296
12297  INSTALL_TOOL_LANGS=install-tool-languages
12298
12299
12300  # Extract the first word of "msgfmt", so it can be a program name with args.
12301set dummy msgfmt; ac_word=$2
12302{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12303$as_echo_n "checking for $ac_word... " >&6; }
12304if test "${ac_cv_prog_MSGFMT+set}" = set; then :
12305  $as_echo_n "(cached) " >&6
12306else
12307  if test -n "$MSGFMT"; then
12308  ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
12309else
12310as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12311for as_dir in $PATH
12312do
12313  IFS=$as_save_IFS
12314  test -z "$as_dir" && as_dir=.
12315    for ac_exec_ext in '' $ac_executable_extensions; do
12316  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12317    ac_cv_prog_MSGFMT="msgfmt"
12318    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12319    break 2
12320  fi
12321done
12322  done
12323IFS=$as_save_IFS
12324
12325fi
12326fi
12327MSGFMT=$ac_cv_prog_MSGFMT
12328if test -n "$MSGFMT"; then
12329  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
12330$as_echo "$MSGFMT" >&6; }
12331else
12332  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12333$as_echo "no" >&6; }
12334fi
12335
12336
12337  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NLS" >&5
12338$as_echo_n "checking for NLS... " >&6; }
12339  if test -f po/Makefile; then
12340    have_gettext="no"
12341    if test -n "$MSGFMT"; then
12342      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12343/* end confdefs.h.  */
12344#include <libintl.h>
12345int
12346main ()
12347{
12348gettext("Test");
12349  ;
12350  return 0;
12351}
12352_ACEOF
12353if ac_fn_c_try_link "$LINENO"; then :
12354  { $as_echo "$as_me:${as_lineno-$LINENO}: result: gettext() works" >&5
12355$as_echo "gettext() works" >&6; }; have_gettext="yes"
12356else
12357  olibs=$LIBS
12358	  LIBS="$LIBS -lintl"
12359	  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12360/* end confdefs.h.  */
12361#include <libintl.h>
12362int
12363main ()
12364{
12365gettext("Test");
12366  ;
12367  return 0;
12368}
12369_ACEOF
12370if ac_fn_c_try_link "$LINENO"; then :
12371  { $as_echo "$as_me:${as_lineno-$LINENO}: result: gettext() works with -lintl" >&5
12372$as_echo "gettext() works with -lintl" >&6; }; have_gettext="yes"
12373else
12374  { $as_echo "$as_me:${as_lineno-$LINENO}: result: gettext() doesn't work" >&5
12375$as_echo "gettext() doesn't work" >&6; };
12376	      LIBS=$olibs
12377fi
12378rm -f core conftest.err conftest.$ac_objext \
12379    conftest$ac_exeext conftest.$ac_ext
12380fi
12381rm -f core conftest.err conftest.$ac_objext \
12382    conftest$ac_exeext conftest.$ac_ext
12383    else
12384      { $as_echo "$as_me:${as_lineno-$LINENO}: result: msgfmt not found - disabled" >&5
12385$as_echo "msgfmt not found - disabled" >&6; };
12386    fi
12387    if test $have_gettext = "yes"; then
12388      $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
12389
12390      MAKEMO=yes
12391
12392            for ac_func in bind_textdomain_codeset
12393do :
12394  ac_fn_c_check_func "$LINENO" "bind_textdomain_codeset" "ac_cv_func_bind_textdomain_codeset"
12395if test "x$ac_cv_func_bind_textdomain_codeset" = x""yes; then :
12396  cat >>confdefs.h <<_ACEOF
12397#define HAVE_BIND_TEXTDOMAIN_CODESET 1
12398_ACEOF
12399
12400fi
12401done
12402
12403            { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _nl_msg_cat_cntr" >&5
12404$as_echo_n "checking for _nl_msg_cat_cntr... " >&6; }
12405      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12406/* end confdefs.h.  */
12407#include <libintl.h>
12408		extern int _nl_msg_cat_cntr;
12409int
12410main ()
12411{
12412++_nl_msg_cat_cntr;
12413  ;
12414  return 0;
12415}
12416_ACEOF
12417if ac_fn_c_try_link "$LINENO"; then :
12418  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12419$as_echo "yes" >&6; }; $as_echo "#define HAVE_NL_MSG_CAT_CNTR 1" >>confdefs.h
12420
12421else
12422  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12423$as_echo "no" >&6; }
12424fi
12425rm -f core conftest.err conftest.$ac_objext \
12426    conftest$ac_exeext conftest.$ac_ext
12427    fi
12428  else
12429    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no \"po/Makefile\" - disabled" >&5
12430$as_echo "no \"po/Makefile\" - disabled" >&6; };
12431  fi
12432else
12433  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12434$as_echo "yes" >&6; }
12435fi
12436
12437ac_fn_c_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default"
12438if test "x$ac_cv_header_dlfcn_h" = x""yes; then :
12439  DLL=dlfcn.h
12440else
12441  ac_fn_c_check_header_mongrel "$LINENO" "dl.h" "ac_cv_header_dl_h" "$ac_includes_default"
12442if test "x$ac_cv_header_dl_h" = x""yes; then :
12443  DLL=dl.h
12444fi
12445
12446
12447fi
12448
12449
12450if test x${DLL} = xdlfcn.h; then
12451
12452$as_echo "#define HAVE_DLFCN_H 1" >>confdefs.h
12453
12454  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen()" >&5
12455$as_echo_n "checking for dlopen()... " >&6; }
12456  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12457/* end confdefs.h.  */
12458
12459int
12460main ()
12461{
12462
12463		extern void* dlopen();
12464		dlopen();
12465
12466  ;
12467  return 0;
12468}
12469_ACEOF
12470if ac_fn_c_try_link "$LINENO"; then :
12471  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12472$as_echo "yes" >&6; };
12473
12474$as_echo "#define HAVE_DLOPEN 1" >>confdefs.h
12475
12476else
12477  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12478$as_echo "no" >&6; };
12479	      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen() in -ldl" >&5
12480$as_echo_n "checking for dlopen() in -ldl... " >&6; }
12481	      olibs=$LIBS
12482	      LIBS="$LIBS -ldl"
12483	      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12484/* end confdefs.h.  */
12485
12486int
12487main ()
12488{
12489
12490				extern void* dlopen();
12491				dlopen();
12492
12493  ;
12494  return 0;
12495}
12496_ACEOF
12497if ac_fn_c_try_link "$LINENO"; then :
12498  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12499$as_echo "yes" >&6; };
12500
12501$as_echo "#define HAVE_DLOPEN 1" >>confdefs.h
12502
12503else
12504  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12505$as_echo "no" >&6; };
12506			  LIBS=$olibs
12507fi
12508rm -f core conftest.err conftest.$ac_objext \
12509    conftest$ac_exeext conftest.$ac_ext
12510fi
12511rm -f core conftest.err conftest.$ac_objext \
12512    conftest$ac_exeext conftest.$ac_ext
12513      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlsym()" >&5
12514$as_echo_n "checking for dlsym()... " >&6; }
12515  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12516/* end confdefs.h.  */
12517
12518int
12519main ()
12520{
12521
12522		extern void* dlsym();
12523		dlsym();
12524
12525  ;
12526  return 0;
12527}
12528_ACEOF
12529if ac_fn_c_try_link "$LINENO"; then :
12530  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12531$as_echo "yes" >&6; };
12532
12533$as_echo "#define HAVE_DLSYM 1" >>confdefs.h
12534
12535else
12536  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12537$as_echo "no" >&6; };
12538	      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlsym() in -ldl" >&5
12539$as_echo_n "checking for dlsym() in -ldl... " >&6; }
12540	      olibs=$LIBS
12541	      LIBS="$LIBS -ldl"
12542	      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12543/* end confdefs.h.  */
12544
12545int
12546main ()
12547{
12548
12549				extern void* dlsym();
12550				dlsym();
12551
12552  ;
12553  return 0;
12554}
12555_ACEOF
12556if ac_fn_c_try_link "$LINENO"; then :
12557  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12558$as_echo "yes" >&6; };
12559
12560$as_echo "#define HAVE_DLSYM 1" >>confdefs.h
12561
12562else
12563  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12564$as_echo "no" >&6; };
12565			  LIBS=$olibs
12566fi
12567rm -f core conftest.err conftest.$ac_objext \
12568    conftest$ac_exeext conftest.$ac_ext
12569fi
12570rm -f core conftest.err conftest.$ac_objext \
12571    conftest$ac_exeext conftest.$ac_ext
12572elif test x${DLL} = xdl.h; then
12573
12574$as_echo "#define HAVE_DL_H 1" >>confdefs.h
12575
12576  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load()" >&5
12577$as_echo_n "checking for shl_load()... " >&6; }
12578  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12579/* end confdefs.h.  */
12580
12581int
12582main ()
12583{
12584
12585		extern void* shl_load();
12586		shl_load();
12587
12588  ;
12589  return 0;
12590}
12591_ACEOF
12592if ac_fn_c_try_link "$LINENO"; then :
12593  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12594$as_echo "yes" >&6; };
12595
12596$as_echo "#define HAVE_SHL_LOAD 1" >>confdefs.h
12597
12598else
12599  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12600$as_echo "no" >&6; };
12601	  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load() in -ldld" >&5
12602$as_echo_n "checking for shl_load() in -ldld... " >&6; }
12603	  olibs=$LIBS
12604	  LIBS="$LIBS -ldld"
12605	  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12606/* end confdefs.h.  */
12607
12608int
12609main ()
12610{
12611
12612			extern void* shl_load();
12613			shl_load();
12614
12615  ;
12616  return 0;
12617}
12618_ACEOF
12619if ac_fn_c_try_link "$LINENO"; then :
12620  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12621$as_echo "yes" >&6; };
12622
12623$as_echo "#define HAVE_SHL_LOAD 1" >>confdefs.h
12624
12625else
12626  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12627$as_echo "no" >&6; };
12628		  LIBS=$olibs
12629fi
12630rm -f core conftest.err conftest.$ac_objext \
12631    conftest$ac_exeext conftest.$ac_ext
12632fi
12633rm -f core conftest.err conftest.$ac_objext \
12634    conftest$ac_exeext conftest.$ac_ext
12635fi
12636for ac_header in setjmp.h
12637do :
12638  ac_fn_c_check_header_mongrel "$LINENO" "setjmp.h" "ac_cv_header_setjmp_h" "$ac_includes_default"
12639if test "x$ac_cv_header_setjmp_h" = x""yes; then :
12640  cat >>confdefs.h <<_ACEOF
12641#define HAVE_SETJMP_H 1
12642_ACEOF
12643
12644fi
12645
12646done
12647
12648
12649if test "x$MACOSX" = "xyes" -a -n "$PERL"; then
12650    if echo $LIBS | grep -e '-ldl' >/dev/null; then
12651    LIBS=`echo $LIBS | sed s/-ldl//`
12652    PERL_LIBS="$PERL_LIBS -ldl"
12653  fi
12654fi
12655
12656if test "x$MACOSX" = "xyes"; then
12657  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -framework Cocoa" >&5
12658$as_echo_n "checking whether we need -framework Cocoa... " >&6; }
12659      if test "x$features" != "xtiny" || test "x$enable_multibyte" = "xyes"; then
12660    LIBS=$"$LIBS -framework Cocoa"
12661    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12662$as_echo "yes" >&6; }
12663  else
12664    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12665$as_echo "no" >&6; }
12666  fi
12667fi
12668if test "x$MACARCH" = "xboth" && test "x$GUITYPE" = "xCARBONGUI"; then
12669  LDFLAGS="$LDFLAGS -isysroot $DEVELOPER_DIR/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
12670fi
12671
12672DEPEND_CFLAGS_FILTER=
12673if test "$GCC" = yes; then
12674  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GCC 3 or later" >&5
12675$as_echo_n "checking for GCC 3 or later... " >&6; }
12676  gccmajor=`echo "$gccversion" | sed -e 's/^\([1-9]\)\..*$/\1/g'`
12677  if test "$gccmajor" -gt "2"; then
12678    DEPEND_CFLAGS_FILTER="| sed 's+-I */+-isystem /+g'"
12679    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12680$as_echo "yes" >&6; }
12681  else
12682    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12683$as_echo "no" >&6; }
12684  fi
12685          { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_FORTIFY_SOURCE=1" >&5
12686$as_echo_n "checking whether we need -D_FORTIFY_SOURCE=1... " >&6; }
12687  if test "$gccmajor" -gt "3"; then
12688    CFLAGS=`echo "$CFLAGS" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/-D_FORTIFY_SOURCE=.//g' -e 's/$/ -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'`
12689    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12690$as_echo "yes" >&6; }
12691  else
12692    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12693$as_echo "no" >&6; }
12694  fi
12695fi
12696
12697
12698{ $as_echo "$as_me:${as_lineno-$LINENO}: checking linker --as-needed support" >&5
12699$as_echo_n "checking linker --as-needed support... " >&6; }
12700LINK_AS_NEEDED=
12701# Check if linker supports --as-needed and --no-as-needed options
12702if $CC -Wl,--help 2>/dev/null | grep as-needed > /dev/null; then
12703  LDFLAGS="$LDFLAGS -Wl,--as-needed"
12704  LINK_AS_NEEDED=yes
12705fi
12706if test "$LINK_AS_NEEDED" = yes; then
12707  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12708$as_echo "yes" >&6; }
12709else
12710  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12711$as_echo "no" >&6; }
12712fi
12713
12714
12715# IBM z/OS reset CFLAGS for config.mk
12716if test "$zOSUnix" = "yes"; then
12717	CFLAGS="-D_ALL_SOURCE -Wc,float\(ieee\),dll"
12718fi
12719
12720ac_config_files="$ac_config_files auto/config.mk:config.mk.in"
12721
12722cat >confcache <<\_ACEOF
12723# This file is a shell script that caches the results of configure
12724# tests run on this system so they can be shared between configure
12725# scripts and configure runs, see configure's option --config-cache.
12726# It is not useful on other systems.  If it contains results you don't
12727# want to keep, you may remove or edit it.
12728#
12729# config.status only pays attention to the cache file if you give it
12730# the --recheck option to rerun configure.
12731#
12732# `ac_cv_env_foo' variables (set or unset) will be overridden when
12733# loading this file, other *unset* `ac_cv_foo' will be assigned the
12734# following values.
12735
12736_ACEOF
12737
12738# The following way of writing the cache mishandles newlines in values,
12739# but we know of no workaround that is simple, portable, and efficient.
12740# So, we kill variables containing newlines.
12741# Ultrix sh set writes to stderr and can't be redirected directly,
12742# and sets the high bit in the cache file unless we assign to the vars.
12743(
12744  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
12745    eval ac_val=\$$ac_var
12746    case $ac_val in #(
12747    *${as_nl}*)
12748      case $ac_var in #(
12749      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
12750$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
12751      esac
12752      case $ac_var in #(
12753      _ | IFS | as_nl) ;; #(
12754      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
12755      *) { eval $ac_var=; unset $ac_var;} ;;
12756      esac ;;
12757    esac
12758  done
12759
12760  (set) 2>&1 |
12761    case $as_nl`(ac_space=' '; set) 2>&1` in #(
12762    *${as_nl}ac_space=\ *)
12763      # `set' does not quote correctly, so add quotes: double-quote
12764      # substitution turns \\\\ into \\, and sed turns \\ into \.
12765      sed -n \
12766	"s/'/'\\\\''/g;
12767	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
12768      ;; #(
12769    *)
12770      # `set' quotes correctly as required by POSIX, so do not add quotes.
12771      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
12772      ;;
12773    esac |
12774    sort
12775) |
12776  sed '
12777     /^ac_cv_env_/b end
12778     t clear
12779     :clear
12780     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
12781     t end
12782     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
12783     :end' >>confcache
12784if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
12785  if test -w "$cache_file"; then
12786    test "x$cache_file" != "x/dev/null" &&
12787      { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
12788$as_echo "$as_me: updating cache $cache_file" >&6;}
12789    cat confcache >$cache_file
12790  else
12791    { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
12792$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
12793  fi
12794fi
12795rm -f confcache
12796
12797test "x$prefix" = xNONE && prefix=$ac_default_prefix
12798# Let make expand exec_prefix.
12799test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
12800
12801DEFS=-DHAVE_CONFIG_H
12802
12803ac_libobjs=
12804ac_ltlibobjs=
12805for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
12806  # 1. Remove the extension, and $U if already installed.
12807  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
12808  ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
12809  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
12810  #    will be set to the directory where LIBOBJS objects are built.
12811  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
12812  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
12813done
12814LIBOBJS=$ac_libobjs
12815
12816LTLIBOBJS=$ac_ltlibobjs
12817
12818
12819
12820
12821: ${CONFIG_STATUS=./config.status}
12822ac_write_fail=0
12823ac_clean_files_save=$ac_clean_files
12824ac_clean_files="$ac_clean_files $CONFIG_STATUS"
12825{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
12826$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
12827as_write_fail=0
12828cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
12829#! $SHELL
12830# Generated by $as_me.
12831# Run this file to recreate the current configuration.
12832# Compiler output produced by configure, useful for debugging
12833# configure, is in config.log if it exists.
12834
12835debug=false
12836ac_cs_recheck=false
12837ac_cs_silent=false
12838
12839SHELL=\${CONFIG_SHELL-$SHELL}
12840export SHELL
12841_ASEOF
12842cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
12843## -------------------- ##
12844## M4sh Initialization. ##
12845## -------------------- ##
12846
12847# Be more Bourne compatible
12848DUALCASE=1; export DUALCASE # for MKS sh
12849if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
12850  emulate sh
12851  NULLCMD=:
12852  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
12853  # is contrary to our usage.  Disable this feature.
12854  alias -g '${1+"$@"}'='"$@"'
12855  setopt NO_GLOB_SUBST
12856else
12857  case `(set -o) 2>/dev/null` in #(
12858  *posix*) :
12859    set -o posix ;; #(
12860  *) :
12861     ;;
12862esac
12863fi
12864
12865
12866as_nl='
12867'
12868export as_nl
12869# Printing a long string crashes Solaris 7 /usr/bin/printf.
12870as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
12871as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
12872as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
12873# Prefer a ksh shell builtin over an external printf program on Solaris,
12874# but without wasting forks for bash or zsh.
12875if test -z "$BASH_VERSION$ZSH_VERSION" \
12876    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
12877  as_echo='print -r --'
12878  as_echo_n='print -rn --'
12879elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
12880  as_echo='printf %s\n'
12881  as_echo_n='printf %s'
12882else
12883  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
12884    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
12885    as_echo_n='/usr/ucb/echo -n'
12886  else
12887    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
12888    as_echo_n_body='eval
12889      arg=$1;
12890      case $arg in #(
12891      *"$as_nl"*)
12892	expr "X$arg" : "X\\(.*\\)$as_nl";
12893	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
12894      esac;
12895      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
12896    '
12897    export as_echo_n_body
12898    as_echo_n='sh -c $as_echo_n_body as_echo'
12899  fi
12900  export as_echo_body
12901  as_echo='sh -c $as_echo_body as_echo'
12902fi
12903
12904# The user is always right.
12905if test "${PATH_SEPARATOR+set}" != set; then
12906  PATH_SEPARATOR=:
12907  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
12908    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
12909      PATH_SEPARATOR=';'
12910  }
12911fi
12912
12913
12914# IFS
12915# We need space, tab and new line, in precisely that order.  Quoting is
12916# there to prevent editors from complaining about space-tab.
12917# (If _AS_PATH_WALK were called with IFS unset, it would disable word
12918# splitting by setting IFS to empty value.)
12919IFS=" ""	$as_nl"
12920
12921# Find who we are.  Look in the path if we contain no directory separator.
12922case $0 in #((
12923  *[\\/]* ) as_myself=$0 ;;
12924  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12925for as_dir in $PATH
12926do
12927  IFS=$as_save_IFS
12928  test -z "$as_dir" && as_dir=.
12929    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
12930  done
12931IFS=$as_save_IFS
12932
12933     ;;
12934esac
12935# We did not find ourselves, most probably we were run as `sh COMMAND'
12936# in which case we are not to be found in the path.
12937if test "x$as_myself" = x; then
12938  as_myself=$0
12939fi
12940if test ! -f "$as_myself"; then
12941  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
12942  exit 1
12943fi
12944
12945# Unset variables that we do not need and which cause bugs (e.g. in
12946# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
12947# suppresses any "Segmentation fault" message there.  '((' could
12948# trigger a bug in pdksh 5.2.14.
12949for as_var in BASH_ENV ENV MAIL MAILPATH
12950do eval test x\${$as_var+set} = xset \
12951  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
12952done
12953PS1='$ '
12954PS2='> '
12955PS4='+ '
12956
12957# NLS nuisances.
12958LC_ALL=C
12959export LC_ALL
12960LANGUAGE=C
12961export LANGUAGE
12962
12963# CDPATH.
12964(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
12965
12966
12967# as_fn_error ERROR [LINENO LOG_FD]
12968# ---------------------------------
12969# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
12970# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
12971# script with status $?, using 1 if that was 0.
12972as_fn_error ()
12973{
12974  as_status=$?; test $as_status -eq 0 && as_status=1
12975  if test "$3"; then
12976    as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
12977    $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
12978  fi
12979  $as_echo "$as_me: error: $1" >&2
12980  as_fn_exit $as_status
12981} # as_fn_error
12982
12983
12984# as_fn_set_status STATUS
12985# -----------------------
12986# Set $? to STATUS, without forking.
12987as_fn_set_status ()
12988{
12989  return $1
12990} # as_fn_set_status
12991
12992# as_fn_exit STATUS
12993# -----------------
12994# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
12995as_fn_exit ()
12996{
12997  set +e
12998  as_fn_set_status $1
12999  exit $1
13000} # as_fn_exit
13001
13002# as_fn_unset VAR
13003# ---------------
13004# Portably unset VAR.
13005as_fn_unset ()
13006{
13007  { eval $1=; unset $1;}
13008}
13009as_unset=as_fn_unset
13010# as_fn_append VAR VALUE
13011# ----------------------
13012# Append the text in VALUE to the end of the definition contained in VAR. Take
13013# advantage of any shell optimizations that allow amortized linear growth over
13014# repeated appends, instead of the typical quadratic growth present in naive
13015# implementations.
13016if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
13017  eval 'as_fn_append ()
13018  {
13019    eval $1+=\$2
13020  }'
13021else
13022  as_fn_append ()
13023  {
13024    eval $1=\$$1\$2
13025  }
13026fi # as_fn_append
13027
13028# as_fn_arith ARG...
13029# ------------------
13030# Perform arithmetic evaluation on the ARGs, and store the result in the
13031# global $as_val. Take advantage of shells that can avoid forks. The arguments
13032# must be portable across $(()) and expr.
13033if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
13034  eval 'as_fn_arith ()
13035  {
13036    as_val=$(( $* ))
13037  }'
13038else
13039  as_fn_arith ()
13040  {
13041    as_val=`expr "$@" || test $? -eq 1`
13042  }
13043fi # as_fn_arith
13044
13045
13046if expr a : '\(a\)' >/dev/null 2>&1 &&
13047   test "X`expr 00001 : '.*\(...\)'`" = X001; then
13048  as_expr=expr
13049else
13050  as_expr=false
13051fi
13052
13053if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
13054  as_basename=basename
13055else
13056  as_basename=false
13057fi
13058
13059if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
13060  as_dirname=dirname
13061else
13062  as_dirname=false
13063fi
13064
13065as_me=`$as_basename -- "$0" ||
13066$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
13067	 X"$0" : 'X\(//\)$' \| \
13068	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
13069$as_echo X/"$0" |
13070    sed '/^.*\/\([^/][^/]*\)\/*$/{
13071	    s//\1/
13072	    q
13073	  }
13074	  /^X\/\(\/\/\)$/{
13075	    s//\1/
13076	    q
13077	  }
13078	  /^X\/\(\/\).*/{
13079	    s//\1/
13080	    q
13081	  }
13082	  s/.*/./; q'`
13083
13084# Avoid depending upon Character Ranges.
13085as_cr_letters='abcdefghijklmnopqrstuvwxyz'
13086as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
13087as_cr_Letters=$as_cr_letters$as_cr_LETTERS
13088as_cr_digits='0123456789'
13089as_cr_alnum=$as_cr_Letters$as_cr_digits
13090
13091ECHO_C= ECHO_N= ECHO_T=
13092case `echo -n x` in #(((((
13093-n*)
13094  case `echo 'xy\c'` in
13095  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
13096  xy)  ECHO_C='\c';;
13097  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
13098       ECHO_T='	';;
13099  esac;;
13100*)
13101  ECHO_N='-n';;
13102esac
13103
13104rm -f conf$$ conf$$.exe conf$$.file
13105if test -d conf$$.dir; then
13106  rm -f conf$$.dir/conf$$.file
13107else
13108  rm -f conf$$.dir
13109  mkdir conf$$.dir 2>/dev/null
13110fi
13111if (echo >conf$$.file) 2>/dev/null; then
13112  if ln -s conf$$.file conf$$ 2>/dev/null; then
13113    as_ln_s='ln -s'
13114    # ... but there are two gotchas:
13115    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
13116    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
13117    # In both cases, we have to default to `cp -p'.
13118    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
13119      as_ln_s='cp -p'
13120  elif ln conf$$.file conf$$ 2>/dev/null; then
13121    as_ln_s=ln
13122  else
13123    as_ln_s='cp -p'
13124  fi
13125else
13126  as_ln_s='cp -p'
13127fi
13128rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
13129rmdir conf$$.dir 2>/dev/null
13130
13131
13132# as_fn_mkdir_p
13133# -------------
13134# Create "$as_dir" as a directory, including parents if necessary.
13135as_fn_mkdir_p ()
13136{
13137
13138  case $as_dir in #(
13139  -*) as_dir=./$as_dir;;
13140  esac
13141  test -d "$as_dir" || eval $as_mkdir_p || {
13142    as_dirs=
13143    while :; do
13144      case $as_dir in #(
13145      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
13146      *) as_qdir=$as_dir;;
13147      esac
13148      as_dirs="'$as_qdir' $as_dirs"
13149      as_dir=`$as_dirname -- "$as_dir" ||
13150$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
13151	 X"$as_dir" : 'X\(//\)[^/]' \| \
13152	 X"$as_dir" : 'X\(//\)$' \| \
13153	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
13154$as_echo X"$as_dir" |
13155    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
13156	    s//\1/
13157	    q
13158	  }
13159	  /^X\(\/\/\)[^/].*/{
13160	    s//\1/
13161	    q
13162	  }
13163	  /^X\(\/\/\)$/{
13164	    s//\1/
13165	    q
13166	  }
13167	  /^X\(\/\).*/{
13168	    s//\1/
13169	    q
13170	  }
13171	  s/.*/./; q'`
13172      test -d "$as_dir" && break
13173    done
13174    test -z "$as_dirs" || eval "mkdir $as_dirs"
13175  } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
13176
13177
13178} # as_fn_mkdir_p
13179if mkdir -p . 2>/dev/null; then
13180  as_mkdir_p='mkdir -p "$as_dir"'
13181else
13182  test -d ./-p && rmdir ./-p
13183  as_mkdir_p=false
13184fi
13185
13186if test -x / >/dev/null 2>&1; then
13187  as_test_x='test -x'
13188else
13189  if ls -dL / >/dev/null 2>&1; then
13190    as_ls_L_option=L
13191  else
13192    as_ls_L_option=
13193  fi
13194  as_test_x='
13195    eval sh -c '\''
13196      if test -d "$1"; then
13197	test -d "$1/.";
13198      else
13199	case $1 in #(
13200	-*)set "./$1";;
13201	esac;
13202	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
13203	???[sx]*):;;*)false;;esac;fi
13204    '\'' sh
13205  '
13206fi
13207as_executable_p=$as_test_x
13208
13209# Sed expression to map a string onto a valid CPP name.
13210as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
13211
13212# Sed expression to map a string onto a valid variable name.
13213as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
13214
13215
13216exec 6>&1
13217## ----------------------------------- ##
13218## Main body of $CONFIG_STATUS script. ##
13219## ----------------------------------- ##
13220_ASEOF
13221test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
13222
13223cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13224# Save the log message, to keep $0 and so on meaningful, and to
13225# report actual input values of CONFIG_FILES etc. instead of their
13226# values after options handling.
13227ac_log="
13228This file was extended by $as_me, which was
13229generated by GNU Autoconf 2.65.  Invocation command line was
13230
13231  CONFIG_FILES    = $CONFIG_FILES
13232  CONFIG_HEADERS  = $CONFIG_HEADERS
13233  CONFIG_LINKS    = $CONFIG_LINKS
13234  CONFIG_COMMANDS = $CONFIG_COMMANDS
13235  $ $0 $@
13236
13237on `(hostname || uname -n) 2>/dev/null | sed 1q`
13238"
13239
13240_ACEOF
13241
13242case $ac_config_files in *"
13243"*) set x $ac_config_files; shift; ac_config_files=$*;;
13244esac
13245
13246case $ac_config_headers in *"
13247"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
13248esac
13249
13250
13251cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13252# Files that config.status was made for.
13253config_files="$ac_config_files"
13254config_headers="$ac_config_headers"
13255
13256_ACEOF
13257
13258cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13259ac_cs_usage="\
13260\`$as_me' instantiates files and other configuration actions
13261from templates according to the current configuration.  Unless the files
13262and actions are specified as TAGs, all are instantiated by default.
13263
13264Usage: $0 [OPTION]... [TAG]...
13265
13266  -h, --help       print this help, then exit
13267  -V, --version    print version number and configuration settings, then exit
13268      --config     print configuration, then exit
13269  -q, --quiet, --silent
13270                   do not print progress messages
13271  -d, --debug      don't remove temporary files
13272      --recheck    update $as_me by reconfiguring in the same conditions
13273      --file=FILE[:TEMPLATE]
13274                   instantiate the configuration file FILE
13275      --header=FILE[:TEMPLATE]
13276                   instantiate the configuration header FILE
13277
13278Configuration files:
13279$config_files
13280
13281Configuration headers:
13282$config_headers
13283
13284Report bugs to the package provider."
13285
13286_ACEOF
13287cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13288ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
13289ac_cs_version="\\
13290config.status
13291configured by $0, generated by GNU Autoconf 2.65,
13292  with options \\"\$ac_cs_config\\"
13293
13294Copyright (C) 2009 Free Software Foundation, Inc.
13295This config.status script is free software; the Free Software Foundation
13296gives unlimited permission to copy, distribute and modify it."
13297
13298ac_pwd='$ac_pwd'
13299srcdir='$srcdir'
13300AWK='$AWK'
13301test -n "\$AWK" || AWK=awk
13302_ACEOF
13303
13304cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13305# The default lists apply if the user does not specify any file.
13306ac_need_defaults=:
13307while test $# != 0
13308do
13309  case $1 in
13310  --*=*)
13311    ac_option=`expr "X$1" : 'X\([^=]*\)='`
13312    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
13313    ac_shift=:
13314    ;;
13315  *)
13316    ac_option=$1
13317    ac_optarg=$2
13318    ac_shift=shift
13319    ;;
13320  esac
13321
13322  case $ac_option in
13323  # Handling of the options.
13324  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
13325    ac_cs_recheck=: ;;
13326  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
13327    $as_echo "$ac_cs_version"; exit ;;
13328  --config | --confi | --conf | --con | --co | --c )
13329    $as_echo "$ac_cs_config"; exit ;;
13330  --debug | --debu | --deb | --de | --d | -d )
13331    debug=: ;;
13332  --file | --fil | --fi | --f )
13333    $ac_shift
13334    case $ac_optarg in
13335    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
13336    esac
13337    as_fn_append CONFIG_FILES " '$ac_optarg'"
13338    ac_need_defaults=false;;
13339  --header | --heade | --head | --hea )
13340    $ac_shift
13341    case $ac_optarg in
13342    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
13343    esac
13344    as_fn_append CONFIG_HEADERS " '$ac_optarg'"
13345    ac_need_defaults=false;;
13346  --he | --h)
13347    # Conflict between --help and --header
13348    as_fn_error "ambiguous option: \`$1'
13349Try \`$0 --help' for more information.";;
13350  --help | --hel | -h )
13351    $as_echo "$ac_cs_usage"; exit ;;
13352  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
13353  | -silent | --silent | --silen | --sile | --sil | --si | --s)
13354    ac_cs_silent=: ;;
13355
13356  # This is an error.
13357  -*) as_fn_error "unrecognized option: \`$1'
13358Try \`$0 --help' for more information." ;;
13359
13360  *) as_fn_append ac_config_targets " $1"
13361     ac_need_defaults=false ;;
13362
13363  esac
13364  shift
13365done
13366
13367ac_configure_extra_args=
13368
13369if $ac_cs_silent; then
13370  exec 6>/dev/null
13371  ac_configure_extra_args="$ac_configure_extra_args --silent"
13372fi
13373
13374_ACEOF
13375cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13376if \$ac_cs_recheck; then
13377  set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
13378  shift
13379  \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
13380  CONFIG_SHELL='$SHELL'
13381  export CONFIG_SHELL
13382  exec "\$@"
13383fi
13384
13385_ACEOF
13386cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13387exec 5>>auto/config.log
13388{
13389  echo
13390  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
13391## Running $as_me. ##
13392_ASBOX
13393  $as_echo "$ac_log"
13394} >&5
13395
13396_ACEOF
13397cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13398_ACEOF
13399
13400cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13401
13402# Handling of arguments.
13403for ac_config_target in $ac_config_targets
13404do
13405  case $ac_config_target in
13406    "auto/config.h") CONFIG_HEADERS="$CONFIG_HEADERS auto/config.h:config.h.in" ;;
13407    "auto/config.mk") CONFIG_FILES="$CONFIG_FILES auto/config.mk:config.mk.in" ;;
13408
13409  *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
13410  esac
13411done
13412
13413
13414# If the user did not use the arguments to specify the items to instantiate,
13415# then the envvar interface is used.  Set only those that are not.
13416# We use the long form for the default assignment because of an extremely
13417# bizarre bug on SunOS 4.1.3.
13418if $ac_need_defaults; then
13419  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
13420  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
13421fi
13422
13423# Have a temporary directory for convenience.  Make it in the build tree
13424# simply because there is no reason against having it here, and in addition,
13425# creating and moving files from /tmp can sometimes cause problems.
13426# Hook for its removal unless debugging.
13427# Note that there is a small window in which the directory will not be cleaned:
13428# after its creation but before its name has been assigned to `$tmp'.
13429$debug ||
13430{
13431  tmp=
13432  trap 'exit_status=$?
13433  { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
13434' 0
13435  trap 'as_fn_exit 1' 1 2 13 15
13436}
13437# Create a (secure) tmp directory for tmp files.
13438
13439{
13440  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
13441  test -n "$tmp" && test -d "$tmp"
13442}  ||
13443{
13444  tmp=./conf$$-$RANDOM
13445  (umask 077 && mkdir "$tmp")
13446} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
13447
13448# Set up the scripts for CONFIG_FILES section.
13449# No need to generate them if there are no CONFIG_FILES.
13450# This happens for instance with `./config.status config.h'.
13451if test -n "$CONFIG_FILES"; then
13452
13453
13454ac_cr=`echo X | tr X '\015'`
13455# On cygwin, bash can eat \r inside `` if the user requested igncr.
13456# But we know of no other shell where ac_cr would be empty at this
13457# point, so we can use a bashism as a fallback.
13458if test "x$ac_cr" = x; then
13459  eval ac_cr=\$\'\\r\'
13460fi
13461ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
13462if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
13463  ac_cs_awk_cr='\r'
13464else
13465  ac_cs_awk_cr=$ac_cr
13466fi
13467
13468echo 'BEGIN {' >"$tmp/subs1.awk" &&
13469_ACEOF
13470
13471
13472{
13473  echo "cat >conf$$subs.awk <<_ACEOF" &&
13474  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
13475  echo "_ACEOF"
13476} >conf$$subs.sh ||
13477  as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
13478ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
13479ac_delim='%!_!# '
13480for ac_last_try in false false false false false :; do
13481  . ./conf$$subs.sh ||
13482    as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
13483
13484  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
13485  if test $ac_delim_n = $ac_delim_num; then
13486    break
13487  elif $ac_last_try; then
13488    as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
13489  else
13490    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
13491  fi
13492done
13493rm -f conf$$subs.sh
13494
13495cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13496cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
13497_ACEOF
13498sed -n '
13499h
13500s/^/S["/; s/!.*/"]=/
13501p
13502g
13503s/^[^!]*!//
13504:repl
13505t repl
13506s/'"$ac_delim"'$//
13507t delim
13508:nl
13509h
13510s/\(.\{148\}\)..*/\1/
13511t more1
13512s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
13513p
13514n
13515b repl
13516:more1
13517s/["\\]/\\&/g; s/^/"/; s/$/"\\/
13518p
13519g
13520s/.\{148\}//
13521t nl
13522:delim
13523h
13524s/\(.\{148\}\)..*/\1/
13525t more2
13526s/["\\]/\\&/g; s/^/"/; s/$/"/
13527p
13528b
13529:more2
13530s/["\\]/\\&/g; s/^/"/; s/$/"\\/
13531p
13532g
13533s/.\{148\}//
13534t delim
13535' <conf$$subs.awk | sed '
13536/^[^""]/{
13537  N
13538  s/\n//
13539}
13540' >>$CONFIG_STATUS || ac_write_fail=1
13541rm -f conf$$subs.awk
13542cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13543_ACAWK
13544cat >>"\$tmp/subs1.awk" <<_ACAWK &&
13545  for (key in S) S_is_set[key] = 1
13546  FS = ""
13547
13548}
13549{
13550  line = $ 0
13551  nfields = split(line, field, "@")
13552  substed = 0
13553  len = length(field[1])
13554  for (i = 2; i < nfields; i++) {
13555    key = field[i]
13556    keylen = length(key)
13557    if (S_is_set[key]) {
13558      value = S[key]
13559      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
13560      len += length(value) + length(field[++i])
13561      substed = 1
13562    } else
13563      len += 1 + keylen
13564  }
13565
13566  print line
13567}
13568
13569_ACAWK
13570_ACEOF
13571cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13572if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
13573  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
13574else
13575  cat
13576fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
13577  || as_fn_error "could not setup config files machinery" "$LINENO" 5
13578_ACEOF
13579
13580# VPATH may cause trouble with some makes, so we remove $(srcdir),
13581# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
13582# trailing colons and then remove the whole line if VPATH becomes empty
13583# (actually we leave an empty line to preserve line numbers).
13584if test "x$srcdir" = x.; then
13585  ac_vpsub='/^[	 ]*VPATH[	 ]*=/{
13586s/:*\$(srcdir):*/:/
13587s/:*\${srcdir}:*/:/
13588s/:*@srcdir@:*/:/
13589s/^\([^=]*=[	 ]*\):*/\1/
13590s/:*$//
13591s/^[^=]*=[	 ]*$//
13592}'
13593fi
13594
13595cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13596fi # test -n "$CONFIG_FILES"
13597
13598# Set up the scripts for CONFIG_HEADERS section.
13599# No need to generate them if there are no CONFIG_HEADERS.
13600# This happens for instance with `./config.status Makefile'.
13601if test -n "$CONFIG_HEADERS"; then
13602cat >"$tmp/defines.awk" <<\_ACAWK ||
13603BEGIN {
13604_ACEOF
13605
13606# Transform confdefs.h into an awk script `defines.awk', embedded as
13607# here-document in config.status, that substitutes the proper values into
13608# config.h.in to produce config.h.
13609
13610# Create a delimiter string that does not exist in confdefs.h, to ease
13611# handling of long lines.
13612ac_delim='%!_!# '
13613for ac_last_try in false false :; do
13614  ac_t=`sed -n "/$ac_delim/p" confdefs.h`
13615  if test -z "$ac_t"; then
13616    break
13617  elif $ac_last_try; then
13618    as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
13619  else
13620    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
13621  fi
13622done
13623
13624# For the awk script, D is an array of macro values keyed by name,
13625# likewise P contains macro parameters if any.  Preserve backslash
13626# newline sequences.
13627
13628ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
13629sed -n '
13630s/.\{148\}/&'"$ac_delim"'/g
13631t rset
13632:rset
13633s/^[	 ]*#[	 ]*define[	 ][	 ]*/ /
13634t def
13635d
13636:def
13637s/\\$//
13638t bsnl
13639s/["\\]/\\&/g
13640s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
13641D["\1"]=" \3"/p
13642s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2"/p
13643d
13644:bsnl
13645s/["\\]/\\&/g
13646s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
13647D["\1"]=" \3\\\\\\n"\\/p
13648t cont
13649s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
13650t cont
13651d
13652:cont
13653n
13654s/.\{148\}/&'"$ac_delim"'/g
13655t clear
13656:clear
13657s/\\$//
13658t bsnlc
13659s/["\\]/\\&/g; s/^/"/; s/$/"/p
13660d
13661:bsnlc
13662s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
13663b cont
13664' <confdefs.h | sed '
13665s/'"$ac_delim"'/"\\\
13666"/g' >>$CONFIG_STATUS || ac_write_fail=1
13667
13668cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13669  for (key in D) D_is_set[key] = 1
13670  FS = ""
13671}
13672/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
13673  line = \$ 0
13674  split(line, arg, " ")
13675  if (arg[1] == "#") {
13676    defundef = arg[2]
13677    mac1 = arg[3]
13678  } else {
13679    defundef = substr(arg[1], 2)
13680    mac1 = arg[2]
13681  }
13682  split(mac1, mac2, "(") #)
13683  macro = mac2[1]
13684  prefix = substr(line, 1, index(line, defundef) - 1)
13685  if (D_is_set[macro]) {
13686    # Preserve the white space surrounding the "#".
13687    print prefix "define", macro P[macro] D[macro]
13688    next
13689  } else {
13690    # Replace #undef with comments.  This is necessary, for example,
13691    # in the case of _POSIX_SOURCE, which is predefined and required
13692    # on some systems where configure will not decide to define it.
13693    if (defundef == "undef") {
13694      print "/*", prefix defundef, macro, "*/"
13695      next
13696    }
13697  }
13698}
13699{ print }
13700_ACAWK
13701_ACEOF
13702cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13703  as_fn_error "could not setup config headers machinery" "$LINENO" 5
13704fi # test -n "$CONFIG_HEADERS"
13705
13706
13707eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    "
13708shift
13709for ac_tag
13710do
13711  case $ac_tag in
13712  :[FHLC]) ac_mode=$ac_tag; continue;;
13713  esac
13714  case $ac_mode$ac_tag in
13715  :[FHL]*:*);;
13716  :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
13717  :[FH]-) ac_tag=-:-;;
13718  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
13719  esac
13720  ac_save_IFS=$IFS
13721  IFS=:
13722  set x $ac_tag
13723  IFS=$ac_save_IFS
13724  shift
13725  ac_file=$1
13726  shift
13727
13728  case $ac_mode in
13729  :L) ac_source=$1;;
13730  :[FH])
13731    ac_file_inputs=
13732    for ac_f
13733    do
13734      case $ac_f in
13735      -) ac_f="$tmp/stdin";;
13736      *) # Look for the file first in the build tree, then in the source tree
13737	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
13738	 # because $ac_f cannot contain `:'.
13739	 test -f "$ac_f" ||
13740	   case $ac_f in
13741	   [\\/$]*) false;;
13742	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
13743	   esac ||
13744	   as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
13745      esac
13746      case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
13747      as_fn_append ac_file_inputs " '$ac_f'"
13748    done
13749
13750    # Let's still pretend it is `configure' which instantiates (i.e., don't
13751    # use $as_me), people would be surprised to read:
13752    #    /* config.h.  Generated by config.status.  */
13753    configure_input='Generated from '`
13754	  $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
13755	`' by configure.'
13756    if test x"$ac_file" != x-; then
13757      configure_input="$ac_file.  $configure_input"
13758      { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
13759$as_echo "$as_me: creating $ac_file" >&6;}
13760    fi
13761    # Neutralize special characters interpreted by sed in replacement strings.
13762    case $configure_input in #(
13763    *\&* | *\|* | *\\* )
13764       ac_sed_conf_input=`$as_echo "$configure_input" |
13765       sed 's/[\\\\&|]/\\\\&/g'`;; #(
13766    *) ac_sed_conf_input=$configure_input;;
13767    esac
13768
13769    case $ac_tag in
13770    *:-:* | *:-) cat >"$tmp/stdin" \
13771      || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
13772    esac
13773    ;;
13774  esac
13775
13776  ac_dir=`$as_dirname -- "$ac_file" ||
13777$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
13778	 X"$ac_file" : 'X\(//\)[^/]' \| \
13779	 X"$ac_file" : 'X\(//\)$' \| \
13780	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
13781$as_echo X"$ac_file" |
13782    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
13783	    s//\1/
13784	    q
13785	  }
13786	  /^X\(\/\/\)[^/].*/{
13787	    s//\1/
13788	    q
13789	  }
13790	  /^X\(\/\/\)$/{
13791	    s//\1/
13792	    q
13793	  }
13794	  /^X\(\/\).*/{
13795	    s//\1/
13796	    q
13797	  }
13798	  s/.*/./; q'`
13799  as_dir="$ac_dir"; as_fn_mkdir_p
13800  ac_builddir=.
13801
13802case "$ac_dir" in
13803.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
13804*)
13805  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
13806  # A ".." for each directory in $ac_dir_suffix.
13807  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
13808  case $ac_top_builddir_sub in
13809  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
13810  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
13811  esac ;;
13812esac
13813ac_abs_top_builddir=$ac_pwd
13814ac_abs_builddir=$ac_pwd$ac_dir_suffix
13815# for backward compatibility:
13816ac_top_builddir=$ac_top_build_prefix
13817
13818case $srcdir in
13819  .)  # We are building in place.
13820    ac_srcdir=.
13821    ac_top_srcdir=$ac_top_builddir_sub
13822    ac_abs_top_srcdir=$ac_pwd ;;
13823  [\\/]* | ?:[\\/]* )  # Absolute name.
13824    ac_srcdir=$srcdir$ac_dir_suffix;
13825    ac_top_srcdir=$srcdir
13826    ac_abs_top_srcdir=$srcdir ;;
13827  *) # Relative name.
13828    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
13829    ac_top_srcdir=$ac_top_build_prefix$srcdir
13830    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
13831esac
13832ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
13833
13834
13835  case $ac_mode in
13836  :F)
13837  #
13838  # CONFIG_FILE
13839  #
13840
13841_ACEOF
13842
13843cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13844# If the template does not know about datarootdir, expand it.
13845# FIXME: This hack should be removed a few years after 2.60.
13846ac_datarootdir_hack=; ac_datarootdir_seen=
13847ac_sed_dataroot='
13848/datarootdir/ {
13849  p
13850  q
13851}
13852/@datadir@/p
13853/@docdir@/p
13854/@infodir@/p
13855/@localedir@/p
13856/@mandir@/p'
13857case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
13858*datarootdir*) ac_datarootdir_seen=yes;;
13859*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
13860  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
13861$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
13862_ACEOF
13863cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13864  ac_datarootdir_hack='
13865  s&@datadir@&$datadir&g
13866  s&@docdir@&$docdir&g
13867  s&@infodir@&$infodir&g
13868  s&@localedir@&$localedir&g
13869  s&@mandir@&$mandir&g
13870  s&\\\${datarootdir}&$datarootdir&g' ;;
13871esac
13872_ACEOF
13873
13874# Neutralize VPATH when `$srcdir' = `.'.
13875# Shell code in configure.ac might set extrasub.
13876# FIXME: do we really want to maintain this feature?
13877cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13878ac_sed_extra="$ac_vpsub
13879$extrasub
13880_ACEOF
13881cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
13882:t
13883/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
13884s|@configure_input@|$ac_sed_conf_input|;t t
13885s&@top_builddir@&$ac_top_builddir_sub&;t t
13886s&@top_build_prefix@&$ac_top_build_prefix&;t t
13887s&@srcdir@&$ac_srcdir&;t t
13888s&@abs_srcdir@&$ac_abs_srcdir&;t t
13889s&@top_srcdir@&$ac_top_srcdir&;t t
13890s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
13891s&@builddir@&$ac_builddir&;t t
13892s&@abs_builddir@&$ac_abs_builddir&;t t
13893s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
13894$ac_datarootdir_hack
13895"
13896eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
13897  || as_fn_error "could not create $ac_file" "$LINENO" 5
13898
13899test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
13900  { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
13901  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
13902  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
13903which seems to be undefined.  Please make sure it is defined." >&5
13904$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
13905which seems to be undefined.  Please make sure it is defined." >&2;}
13906
13907  rm -f "$tmp/stdin"
13908  case $ac_file in
13909  -) cat "$tmp/out" && rm -f "$tmp/out";;
13910  *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
13911  esac \
13912  || as_fn_error "could not create $ac_file" "$LINENO" 5
13913 ;;
13914  :H)
13915  #
13916  # CONFIG_HEADER
13917  #
13918  if test x"$ac_file" != x-; then
13919    {
13920      $as_echo "/* $configure_input  */" \
13921      && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
13922    } >"$tmp/config.h" \
13923      || as_fn_error "could not create $ac_file" "$LINENO" 5
13924    if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
13925      { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
13926$as_echo "$as_me: $ac_file is unchanged" >&6;}
13927    else
13928      rm -f "$ac_file"
13929      mv "$tmp/config.h" "$ac_file" \
13930	|| as_fn_error "could not create $ac_file" "$LINENO" 5
13931    fi
13932  else
13933    $as_echo "/* $configure_input  */" \
13934      && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
13935      || as_fn_error "could not create -" "$LINENO" 5
13936  fi
13937 ;;
13938
13939
13940  esac
13941
13942done # for ac_tag
13943
13944
13945as_fn_exit 0
13946_ACEOF
13947ac_clean_files=$ac_clean_files_save
13948
13949test $ac_write_fail = 0 ||
13950  as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
13951
13952
13953# configure is writing to config.log, and then calls config.status.
13954# config.status does its own redirection, appending to config.log.
13955# Unfortunately, on DOS this fails, as config.log is still kept open
13956# by configure, so config.status won't be able to write to it; its
13957# output is simply discarded.  So we exec the FD to /dev/null,
13958# effectively closing config.log, so it can be properly (re)opened and
13959# appended to by config.status.  When coming back to configure, we
13960# need to make the FD available again.
13961if test "$no_create" != yes; then
13962  ac_cs_success=:
13963  ac_config_status_args=
13964  test "$silent" = yes &&
13965    ac_config_status_args="$ac_config_status_args --quiet"
13966  exec 5>/dev/null
13967  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
13968  exec 5>>auto/config.log
13969  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
13970  # would make configure fail if this is the last instruction.
13971  $ac_cs_success || as_fn_exit $?
13972fi
13973if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
13974  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
13975$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
13976fi
13977
13978
13979