1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.61.
4#
5# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
6# 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
7# This configure script is free software; the Free Software Foundation
8# gives unlimited permission to copy, distribute and modify it.
9## --------------------- ##
10## M4sh Initialization.  ##
11## --------------------- ##
12
13# Be more Bourne compatible
14DUALCASE=1; export DUALCASE # for MKS sh
15if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16  emulate sh
17  NULLCMD=:
18  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
19  # is contrary to our usage.  Disable this feature.
20  alias -g '${1+"$@"}'='"$@"'
21  setopt NO_GLOB_SUBST
22else
23  case `(set -o) 2>/dev/null` in
24  *posix*) set -o posix ;;
25esac
26
27fi
28
29
30
31
32# PATH needs CR
33# Avoid depending upon Character Ranges.
34as_cr_letters='abcdefghijklmnopqrstuvwxyz'
35as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
36as_cr_Letters=$as_cr_letters$as_cr_LETTERS
37as_cr_digits='0123456789'
38as_cr_alnum=$as_cr_Letters$as_cr_digits
39
40# The user is always right.
41if test "${PATH_SEPARATOR+set}" != set; then
42  echo "#! /bin/sh" >conf$$.sh
43  echo  "exit 0"   >>conf$$.sh
44  chmod +x conf$$.sh
45  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
46    PATH_SEPARATOR=';'
47  else
48    PATH_SEPARATOR=:
49  fi
50  rm -f conf$$.sh
51fi
52
53# Support unset when possible.
54if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
55  as_unset=unset
56else
57  as_unset=false
58fi
59
60
61# IFS
62# We need space, tab and new line, in precisely that order.  Quoting is
63# there to prevent editors from complaining about space-tab.
64# (If _AS_PATH_WALK were called with IFS unset, it would disable word
65# splitting by setting IFS to empty value.)
66as_nl='
67'
68IFS=" ""	$as_nl"
69
70# Find who we are.  Look in the path if we contain no directory separator.
71case $0 in
72  *[\\/]* ) as_myself=$0 ;;
73  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
74for as_dir in $PATH
75do
76  IFS=$as_save_IFS
77  test -z "$as_dir" && as_dir=.
78  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
79done
80IFS=$as_save_IFS
81
82     ;;
83esac
84# We did not find ourselves, most probably we were run as `sh COMMAND'
85# in which case we are not to be found in the path.
86if test "x$as_myself" = x; then
87  as_myself=$0
88fi
89if test ! -f "$as_myself"; then
90  echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
91  { (exit 1); exit 1; }
92fi
93
94# Work around bugs in pre-3.0 UWIN ksh.
95for as_var in ENV MAIL MAILPATH
96do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
97done
98PS1='$ '
99PS2='> '
100PS4='+ '
101
102# NLS nuisances.
103for as_var in \
104  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
105  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
106  LC_TELEPHONE LC_TIME
107do
108  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
109    eval $as_var=C; export $as_var
110  else
111    ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
112  fi
113done
114
115# Required to use basename.
116if expr a : '\(a\)' >/dev/null 2>&1 &&
117   test "X`expr 00001 : '.*\(...\)'`" = X001; then
118  as_expr=expr
119else
120  as_expr=false
121fi
122
123if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
124  as_basename=basename
125else
126  as_basename=false
127fi
128
129
130# Name of the executable.
131as_me=`$as_basename -- "$0" ||
132$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
133	 X"$0" : 'X\(//\)$' \| \
134	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
135echo X/"$0" |
136    sed '/^.*\/\([^/][^/]*\)\/*$/{
137	    s//\1/
138	    q
139	  }
140	  /^X\/\(\/\/\)$/{
141	    s//\1/
142	    q
143	  }
144	  /^X\/\(\/\).*/{
145	    s//\1/
146	    q
147	  }
148	  s/.*/./; q'`
149
150# CDPATH.
151$as_unset CDPATH
152
153
154if test "x$CONFIG_SHELL" = x; then
155  if (eval ":") 2>/dev/null; then
156  as_have_required=yes
157else
158  as_have_required=no
159fi
160
161  if test $as_have_required = yes && 	 (eval ":
162(as_func_return () {
163  (exit \$1)
164}
165as_func_success () {
166  as_func_return 0
167}
168as_func_failure () {
169  as_func_return 1
170}
171as_func_ret_success () {
172  return 0
173}
174as_func_ret_failure () {
175  return 1
176}
177
178exitcode=0
179if as_func_success; then
180  :
181else
182  exitcode=1
183  echo as_func_success failed.
184fi
185
186if as_func_failure; then
187  exitcode=1
188  echo as_func_failure succeeded.
189fi
190
191if as_func_ret_success; then
192  :
193else
194  exitcode=1
195  echo as_func_ret_success failed.
196fi
197
198if as_func_ret_failure; then
199  exitcode=1
200  echo as_func_ret_failure succeeded.
201fi
202
203if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
204  :
205else
206  exitcode=1
207  echo positional parameters were not saved.
208fi
209
210test \$exitcode = 0) || { (exit 1); exit 1; }
211
212(
213  as_lineno_1=\$LINENO
214  as_lineno_2=\$LINENO
215  test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
216  test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
217") 2> /dev/null; then
218  :
219else
220  as_candidate_shells=
221    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
222for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
223do
224  IFS=$as_save_IFS
225  test -z "$as_dir" && as_dir=.
226  case $as_dir in
227	 /*)
228	   for as_base in sh bash ksh sh5; do
229	     as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
230	   done;;
231       esac
232done
233IFS=$as_save_IFS
234
235
236      for as_shell in $as_candidate_shells $SHELL; do
237	 # Try only shells that exist, to save several forks.
238	 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
239		{ ("$as_shell") 2> /dev/null <<\_ASEOF
240if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
241  emulate sh
242  NULLCMD=:
243  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
244  # is contrary to our usage.  Disable this feature.
245  alias -g '${1+"$@"}'='"$@"'
246  setopt NO_GLOB_SUBST
247else
248  case `(set -o) 2>/dev/null` in
249  *posix*) set -o posix ;;
250esac
251
252fi
253
254
255:
256_ASEOF
257}; then
258  CONFIG_SHELL=$as_shell
259	       as_have_required=yes
260	       if { "$as_shell" 2> /dev/null <<\_ASEOF
261if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
262  emulate sh
263  NULLCMD=:
264  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
265  # is contrary to our usage.  Disable this feature.
266  alias -g '${1+"$@"}'='"$@"'
267  setopt NO_GLOB_SUBST
268else
269  case `(set -o) 2>/dev/null` in
270  *posix*) set -o posix ;;
271esac
272
273fi
274
275
276:
277(as_func_return () {
278  (exit $1)
279}
280as_func_success () {
281  as_func_return 0
282}
283as_func_failure () {
284  as_func_return 1
285}
286as_func_ret_success () {
287  return 0
288}
289as_func_ret_failure () {
290  return 1
291}
292
293exitcode=0
294if as_func_success; then
295  :
296else
297  exitcode=1
298  echo as_func_success failed.
299fi
300
301if as_func_failure; then
302  exitcode=1
303  echo as_func_failure succeeded.
304fi
305
306if as_func_ret_success; then
307  :
308else
309  exitcode=1
310  echo as_func_ret_success failed.
311fi
312
313if as_func_ret_failure; then
314  exitcode=1
315  echo as_func_ret_failure succeeded.
316fi
317
318if ( set x; as_func_ret_success y && test x = "$1" ); then
319  :
320else
321  exitcode=1
322  echo positional parameters were not saved.
323fi
324
325test $exitcode = 0) || { (exit 1); exit 1; }
326
327(
328  as_lineno_1=$LINENO
329  as_lineno_2=$LINENO
330  test "x$as_lineno_1" != "x$as_lineno_2" &&
331  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
332
333_ASEOF
334}; then
335  break
336fi
337
338fi
339
340      done
341
342      if test "x$CONFIG_SHELL" != x; then
343  for as_var in BASH_ENV ENV
344        do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
345        done
346        export CONFIG_SHELL
347        exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
348fi
349
350
351    if test $as_have_required = no; then
352  echo This script requires a shell more modern than all the
353      echo shells that I found on your system.  Please install a
354      echo modern shell, or manually run the script under such a
355      echo shell if you do have one.
356      { (exit 1); exit 1; }
357fi
358
359
360fi
361
362fi
363
364
365
366(eval "as_func_return () {
367  (exit \$1)
368}
369as_func_success () {
370  as_func_return 0
371}
372as_func_failure () {
373  as_func_return 1
374}
375as_func_ret_success () {
376  return 0
377}
378as_func_ret_failure () {
379  return 1
380}
381
382exitcode=0
383if as_func_success; then
384  :
385else
386  exitcode=1
387  echo as_func_success failed.
388fi
389
390if as_func_failure; then
391  exitcode=1
392  echo as_func_failure succeeded.
393fi
394
395if as_func_ret_success; then
396  :
397else
398  exitcode=1
399  echo as_func_ret_success failed.
400fi
401
402if as_func_ret_failure; then
403  exitcode=1
404  echo as_func_ret_failure succeeded.
405fi
406
407if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
408  :
409else
410  exitcode=1
411  echo positional parameters were not saved.
412fi
413
414test \$exitcode = 0") || {
415  echo Please tell bug-autoconf@gnu.org about your system,
416  echo including any error possibly output before this message.
417  echo This can help us improve future autoconf versions.
418  echo Configuration will now proceed without shell functions.
419}
420
421
422
423  as_lineno_1=$LINENO
424  as_lineno_2=$LINENO
425  test "x$as_lineno_1" != "x$as_lineno_2" &&
426  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
427
428  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
429  # uniformly replaced by the line number.  The first 'sed' inserts a
430  # line-number line after each line using $LINENO; the second 'sed'
431  # does the real work.  The second script uses 'N' to pair each
432  # line-number line with the line containing $LINENO, and appends
433  # trailing '-' during substitution so that $LINENO is not a special
434  # case at line end.
435  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
436  # scripts with optimization help from Paolo Bonzini.  Blame Lee
437  # E. McMahon (1931-1989) for sed's syntax.  :-)
438  sed -n '
439    p
440    /[$]LINENO/=
441  ' <$as_myself |
442    sed '
443      s/[$]LINENO.*/&-/
444      t lineno
445      b
446      :lineno
447      N
448      :loop
449      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
450      t loop
451      s/-\n.*//
452    ' >$as_me.lineno &&
453  chmod +x "$as_me.lineno" ||
454    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
455   { (exit 1); exit 1; }; }
456
457  # Don't try to exec as it changes $[0], causing all sort of problems
458  # (the dirname of $[0] is not the place where we might find the
459  # original and so on.  Autoconf is especially sensitive to this).
460  . "./$as_me.lineno"
461  # Exit status is that of the last command.
462  exit
463}
464
465
466if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
467  as_dirname=dirname
468else
469  as_dirname=false
470fi
471
472ECHO_C= ECHO_N= ECHO_T=
473case `echo -n x` in
474-n*)
475  case `echo 'x\c'` in
476  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
477  *)   ECHO_C='\c';;
478  esac;;
479*)
480  ECHO_N='-n';;
481esac
482
483if expr a : '\(a\)' >/dev/null 2>&1 &&
484   test "X`expr 00001 : '.*\(...\)'`" = X001; then
485  as_expr=expr
486else
487  as_expr=false
488fi
489
490rm -f conf$$ conf$$.exe conf$$.file
491if test -d conf$$.dir; then
492  rm -f conf$$.dir/conf$$.file
493else
494  rm -f conf$$.dir
495  mkdir conf$$.dir
496fi
497echo >conf$$.file
498if ln -s conf$$.file conf$$ 2>/dev/null; then
499  as_ln_s='ln -s'
500  # ... but there are two gotchas:
501  # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
502  # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
503  # In both cases, we have to default to `cp -p'.
504  ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
505    as_ln_s='cp -p'
506elif ln conf$$.file conf$$ 2>/dev/null; then
507  as_ln_s=ln
508else
509  as_ln_s='cp -p'
510fi
511rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
512rmdir conf$$.dir 2>/dev/null
513
514if mkdir -p . 2>/dev/null; then
515  as_mkdir_p=:
516else
517  test -d ./-p && rmdir ./-p
518  as_mkdir_p=false
519fi
520
521if test -x / >/dev/null 2>&1; then
522  as_test_x='test -x'
523else
524  if ls -dL / >/dev/null 2>&1; then
525    as_ls_L_option=L
526  else
527    as_ls_L_option=
528  fi
529  as_test_x='
530    eval sh -c '\''
531      if test -d "$1"; then
532        test -d "$1/.";
533      else
534	case $1 in
535        -*)set "./$1";;
536	esac;
537	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
538	???[sx]*):;;*)false;;esac;fi
539    '\'' sh
540  '
541fi
542as_executable_p=$as_test_x
543
544# Sed expression to map a string onto a valid CPP name.
545as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
546
547# Sed expression to map a string onto a valid variable name.
548as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
549
550
551
552exec 7<&0 </dev/null 6>&1
553
554# Name of the host.
555# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
556# so uname gets run too.
557ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
558
559#
560# Initializations.
561#
562ac_default_prefix=/usr/local
563ac_clean_files=
564ac_config_libobj_dir=.
565LIBOBJS=
566cross_compiling=no
567subdirs=
568MFLAGS=
569MAKEFLAGS=
570SHELL=${CONFIG_SHELL-/bin/sh}
571
572# Identity of this package.
573PACKAGE_NAME=
574PACKAGE_TARNAME=
575PACKAGE_VERSION=
576PACKAGE_STRING=
577PACKAGE_BUGREPORT=
578
579ac_unique_file="src/lisp.h"
580ac_config_libobj_dir=src
581# Factoring default headers for most tests.
582ac_includes_default="\
583#include <stdio.h>
584#ifdef HAVE_SYS_TYPES_H
585# include <sys/types.h>
586#endif
587#ifdef HAVE_SYS_STAT_H
588# include <sys/stat.h>
589#endif
590#ifdef STDC_HEADERS
591# include <stdlib.h>
592# include <stddef.h>
593#else
594# ifdef HAVE_STDLIB_H
595#  include <stdlib.h>
596# endif
597#endif
598#ifdef HAVE_STRING_H
599# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
600#  include <memory.h>
601# endif
602# include <string.h>
603#endif
604#ifdef HAVE_STRINGS_H
605# include <strings.h>
606#endif
607#ifdef HAVE_INTTYPES_H
608# include <inttypes.h>
609#endif
610#ifdef HAVE_STDINT_H
611# include <stdint.h>
612#endif
613#ifdef HAVE_UNISTD_H
614# include <unistd.h>
615#endif"
616
617ac_header_list=
618ac_func_list=
619ac_subst_vars='SHELL
620PATH_SEPARATOR
621PACKAGE_NAME
622PACKAGE_TARNAME
623PACKAGE_VERSION
624PACKAGE_STRING
625PACKAGE_BUGREPORT
626exec_prefix
627prefix
628program_transform_name
629bindir
630sbindir
631libexecdir
632datarootdir
633datadir
634sysconfdir
635sharedstatedir
636localstatedir
637includedir
638oldincludedir
639docdir
640infodir
641htmldir
642dvidir
643pdfdir
644psdir
645libdir
646localedir
647mandir
648DEFS
649ECHO_C
650ECHO_N
651ECHO_T
652LIBS
653build_alias
654host_alias
655target_alias
656MAINT
657build
658build_cpu
659build_vendor
660build_os
661host
662host_cpu
663host_vendor
664host_os
665CC
666CFLAGS
667LDFLAGS
668CPPFLAGS
669ac_ct_CC
670EXEEXT
671OBJEXT
672CPP
673GREP
674EGREP
675LN_S
676INSTALL_PROGRAM
677INSTALL_SCRIPT
678INSTALL_DATA
679RANLIB
680INSTALL_INFO
681GZIP_PROG
682LIBSOUND
683PKG_CONFIG
684ALSA_CFLAGS
685ALSA_LIBS
686CFLAGS_SOUND
687SET_MAKE
688XMKMF
689GTK_CFLAGS
690GTK_LIBS
691XFT_CFLAGS
692XFT_LIBS
693ALLOCA
694liblockfile
695LIBOBJS
696NEED_SETGID
697KMEM_GROUP
698GETLOADAVG_LIBS
699GETOPT_H
700GETOPTOBJS
701version
702configuration
703canonical
704srcdir
705lispdir
706locallisppath
707lisppath
708x_default_search_path
709etcdir
710archlibdir
711bitmapdir
712gamedir
713gameuser
714c_switch_system
715c_switch_machine
716LD_SWITCH_X_SITE
717LD_SWITCH_X_SITE_AUX
718C_SWITCH_X_SITE
719X_TOOLKIT_TYPE
720machfile
721opsysfile
722carbon_appdir
723LTLIBOBJS'
724ac_subst_files=''
725      ac_precious_vars='build_alias
726host_alias
727target_alias
728CC
729CFLAGS
730LDFLAGS
731LIBS
732CPPFLAGS
733CPP
734XMKMF'
735
736
737# Initialize some variables set by options.
738ac_init_help=
739ac_init_version=false
740# The variables have the same names as the options, with
741# dashes changed to underlines.
742cache_file=/dev/null
743exec_prefix=NONE
744no_create=
745no_recursion=
746prefix=NONE
747program_prefix=NONE
748program_suffix=NONE
749program_transform_name=s,x,x,
750silent=
751site=
752srcdir=
753verbose=
754x_includes=NONE
755x_libraries=NONE
756
757# Installation directory options.
758# These are left unexpanded so users can "make install exec_prefix=/foo"
759# and all the variables that are supposed to be based on exec_prefix
760# by default will actually change.
761# Use braces instead of parens because sh, perl, etc. also accept them.
762# (The list follows the same order as the GNU Coding Standards.)
763bindir='${exec_prefix}/bin'
764sbindir='${exec_prefix}/sbin'
765libexecdir='${exec_prefix}/libexec'
766datarootdir='${prefix}/share'
767datadir='${datarootdir}'
768sysconfdir='${prefix}/etc'
769sharedstatedir='${prefix}/com'
770localstatedir='${prefix}/var'
771includedir='${prefix}/include'
772oldincludedir='/usr/include'
773docdir='${datarootdir}/doc/${PACKAGE}'
774infodir='${datarootdir}/info'
775htmldir='${docdir}'
776dvidir='${docdir}'
777pdfdir='${docdir}'
778psdir='${docdir}'
779libdir='${exec_prefix}/lib'
780localedir='${datarootdir}/locale'
781mandir='${datarootdir}/man'
782
783ac_prev=
784ac_dashdash=
785for ac_option
786do
787  # If the previous option needs an argument, assign it.
788  if test -n "$ac_prev"; then
789    eval $ac_prev=\$ac_option
790    ac_prev=
791    continue
792  fi
793
794  case $ac_option in
795  *=*)	ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
796  *)	ac_optarg=yes ;;
797  esac
798
799  # Accept the important Cygnus configure options, so we can diagnose typos.
800
801  case $ac_dashdash$ac_option in
802  --)
803    ac_dashdash=yes ;;
804
805  -bindir | --bindir | --bindi | --bind | --bin | --bi)
806    ac_prev=bindir ;;
807  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
808    bindir=$ac_optarg ;;
809
810  -build | --build | --buil | --bui | --bu)
811    ac_prev=build_alias ;;
812  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
813    build_alias=$ac_optarg ;;
814
815  -cache-file | --cache-file | --cache-fil | --cache-fi \
816  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
817    ac_prev=cache_file ;;
818  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
819  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
820    cache_file=$ac_optarg ;;
821
822  --config-cache | -C)
823    cache_file=config.cache ;;
824
825  -datadir | --datadir | --datadi | --datad)
826    ac_prev=datadir ;;
827  -datadir=* | --datadir=* | --datadi=* | --datad=*)
828    datadir=$ac_optarg ;;
829
830  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
831  | --dataroo | --dataro | --datar)
832    ac_prev=datarootdir ;;
833  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
834  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
835    datarootdir=$ac_optarg ;;
836
837  -disable-* | --disable-*)
838    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
839    # Reject names that are not valid shell variable names.
840    expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
841      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
842   { (exit 1); exit 1; }; }
843    ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
844    eval enable_$ac_feature=no ;;
845
846  -docdir | --docdir | --docdi | --doc | --do)
847    ac_prev=docdir ;;
848  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
849    docdir=$ac_optarg ;;
850
851  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
852    ac_prev=dvidir ;;
853  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
854    dvidir=$ac_optarg ;;
855
856  -enable-* | --enable-*)
857    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
858    # Reject names that are not valid shell variable names.
859    expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
860      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
861   { (exit 1); exit 1; }; }
862    ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
863    eval enable_$ac_feature=\$ac_optarg ;;
864
865  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
866  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
867  | --exec | --exe | --ex)
868    ac_prev=exec_prefix ;;
869  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
870  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
871  | --exec=* | --exe=* | --ex=*)
872    exec_prefix=$ac_optarg ;;
873
874  -gas | --gas | --ga | --g)
875    # Obsolete; use --with-gas.
876    with_gas=yes ;;
877
878  -help | --help | --hel | --he | -h)
879    ac_init_help=long ;;
880  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
881    ac_init_help=recursive ;;
882  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
883    ac_init_help=short ;;
884
885  -host | --host | --hos | --ho)
886    ac_prev=host_alias ;;
887  -host=* | --host=* | --hos=* | --ho=*)
888    host_alias=$ac_optarg ;;
889
890  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
891    ac_prev=htmldir ;;
892  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
893  | --ht=*)
894    htmldir=$ac_optarg ;;
895
896  -includedir | --includedir | --includedi | --included | --include \
897  | --includ | --inclu | --incl | --inc)
898    ac_prev=includedir ;;
899  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
900  | --includ=* | --inclu=* | --incl=* | --inc=*)
901    includedir=$ac_optarg ;;
902
903  -infodir | --infodir | --infodi | --infod | --info | --inf)
904    ac_prev=infodir ;;
905  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
906    infodir=$ac_optarg ;;
907
908  -libdir | --libdir | --libdi | --libd)
909    ac_prev=libdir ;;
910  -libdir=* | --libdir=* | --libdi=* | --libd=*)
911    libdir=$ac_optarg ;;
912
913  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
914  | --libexe | --libex | --libe)
915    ac_prev=libexecdir ;;
916  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
917  | --libexe=* | --libex=* | --libe=*)
918    libexecdir=$ac_optarg ;;
919
920  -localedir | --localedir | --localedi | --localed | --locale)
921    ac_prev=localedir ;;
922  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
923    localedir=$ac_optarg ;;
924
925  -localstatedir | --localstatedir | --localstatedi | --localstated \
926  | --localstate | --localstat | --localsta | --localst | --locals)
927    ac_prev=localstatedir ;;
928  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
929  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
930    localstatedir=$ac_optarg ;;
931
932  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
933    ac_prev=mandir ;;
934  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
935    mandir=$ac_optarg ;;
936
937  -nfp | --nfp | --nf)
938    # Obsolete; use --without-fp.
939    with_fp=no ;;
940
941  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
942  | --no-cr | --no-c | -n)
943    no_create=yes ;;
944
945  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
946  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
947    no_recursion=yes ;;
948
949  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
950  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
951  | --oldin | --oldi | --old | --ol | --o)
952    ac_prev=oldincludedir ;;
953  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
954  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
955  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
956    oldincludedir=$ac_optarg ;;
957
958  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
959    ac_prev=prefix ;;
960  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
961    prefix=$ac_optarg ;;
962
963  -program-prefix | --program-prefix | --program-prefi | --program-pref \
964  | --program-pre | --program-pr | --program-p)
965    ac_prev=program_prefix ;;
966  -program-prefix=* | --program-prefix=* | --program-prefi=* \
967  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
968    program_prefix=$ac_optarg ;;
969
970  -program-suffix | --program-suffix | --program-suffi | --program-suff \
971  | --program-suf | --program-su | --program-s)
972    ac_prev=program_suffix ;;
973  -program-suffix=* | --program-suffix=* | --program-suffi=* \
974  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
975    program_suffix=$ac_optarg ;;
976
977  -program-transform-name | --program-transform-name \
978  | --program-transform-nam | --program-transform-na \
979  | --program-transform-n | --program-transform- \
980  | --program-transform | --program-transfor \
981  | --program-transfo | --program-transf \
982  | --program-trans | --program-tran \
983  | --progr-tra | --program-tr | --program-t)
984    ac_prev=program_transform_name ;;
985  -program-transform-name=* | --program-transform-name=* \
986  | --program-transform-nam=* | --program-transform-na=* \
987  | --program-transform-n=* | --program-transform-=* \
988  | --program-transform=* | --program-transfor=* \
989  | --program-transfo=* | --program-transf=* \
990  | --program-trans=* | --program-tran=* \
991  | --progr-tra=* | --program-tr=* | --program-t=*)
992    program_transform_name=$ac_optarg ;;
993
994  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
995    ac_prev=pdfdir ;;
996  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
997    pdfdir=$ac_optarg ;;
998
999  -psdir | --psdir | --psdi | --psd | --ps)
1000    ac_prev=psdir ;;
1001  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1002    psdir=$ac_optarg ;;
1003
1004  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1005  | -silent | --silent | --silen | --sile | --sil)
1006    silent=yes ;;
1007
1008  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1009    ac_prev=sbindir ;;
1010  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1011  | --sbi=* | --sb=*)
1012    sbindir=$ac_optarg ;;
1013
1014  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1015  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1016  | --sharedst | --shareds | --shared | --share | --shar \
1017  | --sha | --sh)
1018    ac_prev=sharedstatedir ;;
1019  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1020  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1021  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1022  | --sha=* | --sh=*)
1023    sharedstatedir=$ac_optarg ;;
1024
1025  -site | --site | --sit)
1026    ac_prev=site ;;
1027  -site=* | --site=* | --sit=*)
1028    site=$ac_optarg ;;
1029
1030  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1031    ac_prev=srcdir ;;
1032  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1033    srcdir=$ac_optarg ;;
1034
1035  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1036  | --syscon | --sysco | --sysc | --sys | --sy)
1037    ac_prev=sysconfdir ;;
1038  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1039  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1040    sysconfdir=$ac_optarg ;;
1041
1042  -target | --target | --targe | --targ | --tar | --ta | --t)
1043    ac_prev=target_alias ;;
1044  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1045    target_alias=$ac_optarg ;;
1046
1047  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1048    verbose=yes ;;
1049
1050  -version | --version | --versio | --versi | --vers | -V)
1051    ac_init_version=: ;;
1052
1053  -with-* | --with-*)
1054    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1055    # Reject names that are not valid shell variable names.
1056    expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1057      { echo "$as_me: error: invalid package name: $ac_package" >&2
1058   { (exit 1); exit 1; }; }
1059    ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1060    eval with_$ac_package=\$ac_optarg ;;
1061
1062  -without-* | --without-*)
1063    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1064    # Reject names that are not valid shell variable names.
1065    expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1066      { echo "$as_me: error: invalid package name: $ac_package" >&2
1067   { (exit 1); exit 1; }; }
1068    ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1069    eval with_$ac_package=no ;;
1070
1071  --x)
1072    # Obsolete; use --with-x.
1073    with_x=yes ;;
1074
1075  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1076  | --x-incl | --x-inc | --x-in | --x-i)
1077    ac_prev=x_includes ;;
1078  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1079  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1080    x_includes=$ac_optarg ;;
1081
1082  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1083  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1084    ac_prev=x_libraries ;;
1085  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1086  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1087    x_libraries=$ac_optarg ;;
1088
1089  -*) { echo "$as_me: error: unrecognized option: $ac_option
1090Try \`$0 --help' for more information." >&2
1091   { (exit 1); exit 1; }; }
1092    ;;
1093
1094  *=*)
1095    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1096    # Reject names that are not valid shell variable names.
1097    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1098      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1099   { (exit 1); exit 1; }; }
1100    eval $ac_envvar=\$ac_optarg
1101    export $ac_envvar ;;
1102
1103  *)
1104    # FIXME: should be removed in autoconf 3.0.
1105    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1106    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1107      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1108    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1109    ;;
1110
1111  esac
1112done
1113
1114if test -n "$ac_prev"; then
1115  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1116  { echo "$as_me: error: missing argument to $ac_option" >&2
1117   { (exit 1); exit 1; }; }
1118fi
1119
1120# Be sure to have absolute directory names.
1121for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1122		datadir sysconfdir sharedstatedir localstatedir includedir \
1123		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1124		libdir localedir mandir
1125do
1126  eval ac_val=\$$ac_var
1127  case $ac_val in
1128    [\\/$]* | ?:[\\/]* )  continue;;
1129    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1130  esac
1131  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1132   { (exit 1); exit 1; }; }
1133done
1134
1135# There might be people who depend on the old broken behavior: `$host'
1136# used to hold the argument of --host etc.
1137# FIXME: To remove some day.
1138build=$build_alias
1139host=$host_alias
1140target=$target_alias
1141
1142# FIXME: To remove some day.
1143if test "x$host_alias" != x; then
1144  if test "x$build_alias" = x; then
1145    cross_compiling=maybe
1146    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1147    If a cross compiler is detected then cross compile mode will be used." >&2
1148  elif test "x$build_alias" != "x$host_alias"; then
1149    cross_compiling=yes
1150  fi
1151fi
1152
1153ac_tool_prefix=
1154test -n "$host_alias" && ac_tool_prefix=$host_alias-
1155
1156test "$silent" = yes && exec 6>/dev/null
1157
1158
1159ac_pwd=`pwd` && test -n "$ac_pwd" &&
1160ac_ls_di=`ls -di .` &&
1161ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1162  { echo "$as_me: error: Working directory cannot be determined" >&2
1163   { (exit 1); exit 1; }; }
1164test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1165  { echo "$as_me: error: pwd does not report name of working directory" >&2
1166   { (exit 1); exit 1; }; }
1167
1168
1169# Find the source files, if location was not specified.
1170if test -z "$srcdir"; then
1171  ac_srcdir_defaulted=yes
1172  # Try the directory containing this script, then the parent directory.
1173  ac_confdir=`$as_dirname -- "$0" ||
1174$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1175	 X"$0" : 'X\(//\)[^/]' \| \
1176	 X"$0" : 'X\(//\)$' \| \
1177	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
1178echo X"$0" |
1179    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1180	    s//\1/
1181	    q
1182	  }
1183	  /^X\(\/\/\)[^/].*/{
1184	    s//\1/
1185	    q
1186	  }
1187	  /^X\(\/\/\)$/{
1188	    s//\1/
1189	    q
1190	  }
1191	  /^X\(\/\).*/{
1192	    s//\1/
1193	    q
1194	  }
1195	  s/.*/./; q'`
1196  srcdir=$ac_confdir
1197  if test ! -r "$srcdir/$ac_unique_file"; then
1198    srcdir=..
1199  fi
1200else
1201  ac_srcdir_defaulted=no
1202fi
1203if test ! -r "$srcdir/$ac_unique_file"; then
1204  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1205  { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1206   { (exit 1); exit 1; }; }
1207fi
1208ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1209ac_abs_confdir=`(
1210	cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2
1211   { (exit 1); exit 1; }; }
1212	pwd)`
1213# When building in place, set srcdir=.
1214if test "$ac_abs_confdir" = "$ac_pwd"; then
1215  srcdir=.
1216fi
1217# Remove unnecessary trailing slashes from srcdir.
1218# Double slashes in file names in object file debugging info
1219# mess up M-x gdb in Emacs.
1220case $srcdir in
1221*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1222esac
1223for ac_var in $ac_precious_vars; do
1224  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1225  eval ac_env_${ac_var}_value=\$${ac_var}
1226  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1227  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1228done
1229
1230#
1231# Report the --help message.
1232#
1233if test "$ac_init_help" = "long"; then
1234  # Omit some internal or obsolete options to make the list less imposing.
1235  # This message is too long to be a string in the A/UX 3.1 sh.
1236  cat <<_ACEOF
1237\`configure' configures this package to adapt to many kinds of systems.
1238
1239Usage: $0 [OPTION]... [VAR=VALUE]...
1240
1241To assign environment variables (e.g., CC, CFLAGS...), specify them as
1242VAR=VALUE.  See below for descriptions of some of the useful variables.
1243
1244Defaults for the options are specified in brackets.
1245
1246Configuration:
1247  -h, --help              display this help and exit
1248      --help=short        display options specific to this package
1249      --help=recursive    display the short help of all the included packages
1250  -V, --version           display version information and exit
1251  -q, --quiet, --silent   do not print \`checking...' messages
1252      --cache-file=FILE   cache test results in FILE [disabled]
1253  -C, --config-cache      alias for \`--cache-file=config.cache'
1254  -n, --no-create         do not create output files
1255      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1256
1257Installation directories:
1258  --prefix=PREFIX         install architecture-independent files in PREFIX
1259			  [$ac_default_prefix]
1260  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1261			  [PREFIX]
1262
1263By default, \`make install' will install all the files in
1264\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1265an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1266for instance \`--prefix=\$HOME'.
1267
1268For better control, use the options below.
1269
1270Fine tuning of the installation directories:
1271  --bindir=DIR           user executables [EPREFIX/bin]
1272  --sbindir=DIR          system admin executables [EPREFIX/sbin]
1273  --libexecdir=DIR       program executables [EPREFIX/libexec]
1274  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
1275  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
1276  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
1277  --libdir=DIR           object code libraries [EPREFIX/lib]
1278  --includedir=DIR       C header files [PREFIX/include]
1279  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
1280  --datarootdir=DIR      read-only arch.-independent data root [PREFIX/share]
1281  --datadir=DIR          read-only architecture-independent data [DATAROOTDIR]
1282  --infodir=DIR          info documentation [DATAROOTDIR/info]
1283  --localedir=DIR        locale-dependent data [DATAROOTDIR/locale]
1284  --mandir=DIR           man documentation [DATAROOTDIR/man]
1285  --docdir=DIR           documentation root [DATAROOTDIR/doc/PACKAGE]
1286  --htmldir=DIR          html documentation [DOCDIR]
1287  --dvidir=DIR           dvi documentation [DOCDIR]
1288  --pdfdir=DIR           pdf documentation [DOCDIR]
1289  --psdir=DIR            ps documentation [DOCDIR]
1290_ACEOF
1291
1292  cat <<\_ACEOF
1293
1294Program names:
1295  --program-prefix=PREFIX            prepend PREFIX to installed program names
1296  --program-suffix=SUFFIX            append SUFFIX to installed program names
1297  --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1298
1299X features:
1300  --x-includes=DIR    X include files are in DIR
1301  --x-libraries=DIR   X library files are in DIR
1302
1303System types:
1304  --build=BUILD     configure for building on BUILD [guessed]
1305  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1306_ACEOF
1307fi
1308
1309if test -n "$ac_init_help"; then
1310
1311  cat <<\_ACEOF
1312
1313Optional Features:
1314  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1315  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1316  --enable-carbon-app[=DIR]  [DIR=/Application]
1317                          specify install directory for Emacs.app on Mac OS X
1318  --enable-asserts        compile code with asserts enabled
1319  --enable-maintainer-mode enable make rules and dependencies not useful
1320                          (and sometimes confusing) to the casual installer
1321  --enable-locallisppath=PATH
1322                          directories Emacs should search for lisp files
1323                          specific to this site
1324  --disable-largefile     omit support for large files
1325
1326Optional Packages:
1327  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1328  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1329  --without-gcc           don't use GCC to compile Emacs if GCC is found
1330  --without-pop           don't support POP mail retrieval with movemail
1331  --with-kerberos         support Kerberos-authenticated POP
1332  --with-kerberos5        support Kerberos version 5 authenticated POP
1333  --with-hesiod           support Hesiod to get the POP server host
1334  --without-sound         don't compile with sound support
1335  --with-x-toolkit=KIT    use an X toolkit
1336                              (KIT = yes/lucid/athena/motif/gtk/no)
1337  --with-xpm              use -lXpm for displaying XPM images
1338  --with-jpeg             use -ljpeg for displaying JPEG images
1339  --with-tiff             use -ltiff for displaying TIFF images
1340  --with-gif              use -lungif for displaying GIF images
1341  --with-png              use -lpng for displaying PNG images
1342  --with-gtk              use GTK (same as --with-x-toolkit=gtk)
1343  --with-pkg-config-prog  Path to pkg-config to use for finding GTK
1344  --without-toolkit-scroll-bars
1345                          don't use Motif or Xaw3d scroll bars
1346  --without-xim           don't use X11 XIM
1347  --without-carbon        don't use Carbon GUI on Mac OS X
1348  --with-x                use the X Window System
1349
1350Some influential environment variables:
1351  CC          C compiler command
1352  CFLAGS      C compiler flags
1353  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1354              nonstandard directory <lib dir>
1355  LIBS        libraries to pass to the linker, e.g. -l<library>
1356  CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1357              you have headers in a nonstandard directory <include dir>
1358  CPP         C preprocessor
1359  XMKMF       Path to xmkmf, Makefile generator for X Window System
1360
1361Use these variables to override the choices made by `configure' or to help
1362it to find libraries and programs with nonstandard names/locations.
1363
1364_ACEOF
1365ac_status=$?
1366fi
1367
1368if test "$ac_init_help" = "recursive"; then
1369  # If there are subdirs, report their specific --help.
1370  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1371    test -d "$ac_dir" || continue
1372    ac_builddir=.
1373
1374case "$ac_dir" in
1375.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1376*)
1377  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1378  # A ".." for each directory in $ac_dir_suffix.
1379  ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
1380  case $ac_top_builddir_sub in
1381  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1382  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1383  esac ;;
1384esac
1385ac_abs_top_builddir=$ac_pwd
1386ac_abs_builddir=$ac_pwd$ac_dir_suffix
1387# for backward compatibility:
1388ac_top_builddir=$ac_top_build_prefix
1389
1390case $srcdir in
1391  .)  # We are building in place.
1392    ac_srcdir=.
1393    ac_top_srcdir=$ac_top_builddir_sub
1394    ac_abs_top_srcdir=$ac_pwd ;;
1395  [\\/]* | ?:[\\/]* )  # Absolute name.
1396    ac_srcdir=$srcdir$ac_dir_suffix;
1397    ac_top_srcdir=$srcdir
1398    ac_abs_top_srcdir=$srcdir ;;
1399  *) # Relative name.
1400    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1401    ac_top_srcdir=$ac_top_build_prefix$srcdir
1402    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1403esac
1404ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1405
1406    cd "$ac_dir" || { ac_status=$?; continue; }
1407    # Check for guested configure.
1408    if test -f "$ac_srcdir/configure.gnu"; then
1409      echo &&
1410      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1411    elif test -f "$ac_srcdir/configure"; then
1412      echo &&
1413      $SHELL "$ac_srcdir/configure" --help=recursive
1414    else
1415      echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1416    fi || ac_status=$?
1417    cd "$ac_pwd" || { ac_status=$?; break; }
1418  done
1419fi
1420
1421test -n "$ac_init_help" && exit $ac_status
1422if $ac_init_version; then
1423  cat <<\_ACEOF
1424configure
1425generated by GNU Autoconf 2.61
1426
1427Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
14282002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
1429This configure script is free software; the Free Software Foundation
1430gives unlimited permission to copy, distribute and modify it.
1431_ACEOF
1432  exit
1433fi
1434cat >config.log <<_ACEOF
1435This file contains any messages produced by compilers while
1436running configure, to aid debugging if configure makes a mistake.
1437
1438It was created by $as_me, which was
1439generated by GNU Autoconf 2.61.  Invocation command line was
1440
1441  $ $0 $@
1442
1443_ACEOF
1444exec 5>>config.log
1445{
1446cat <<_ASUNAME
1447## --------- ##
1448## Platform. ##
1449## --------- ##
1450
1451hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1452uname -m = `(uname -m) 2>/dev/null || echo unknown`
1453uname -r = `(uname -r) 2>/dev/null || echo unknown`
1454uname -s = `(uname -s) 2>/dev/null || echo unknown`
1455uname -v = `(uname -v) 2>/dev/null || echo unknown`
1456
1457/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1458/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1459
1460/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1461/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1462/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1463/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1464/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1465/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1466/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1467
1468_ASUNAME
1469
1470as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1471for as_dir in $PATH
1472do
1473  IFS=$as_save_IFS
1474  test -z "$as_dir" && as_dir=.
1475  echo "PATH: $as_dir"
1476done
1477IFS=$as_save_IFS
1478
1479} >&5
1480
1481cat >&5 <<_ACEOF
1482
1483
1484## ----------- ##
1485## Core tests. ##
1486## ----------- ##
1487
1488_ACEOF
1489
1490
1491# Keep a trace of the command line.
1492# Strip out --no-create and --no-recursion so they do not pile up.
1493# Strip out --silent because we don't want to record it for future runs.
1494# Also quote any args containing shell meta-characters.
1495# Make two passes to allow for proper duplicate-argument suppression.
1496ac_configure_args=
1497ac_configure_args0=
1498ac_configure_args1=
1499ac_must_keep_next=false
1500for ac_pass in 1 2
1501do
1502  for ac_arg
1503  do
1504    case $ac_arg in
1505    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1506    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1507    | -silent | --silent | --silen | --sile | --sil)
1508      continue ;;
1509    *\'*)
1510      ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1511    esac
1512    case $ac_pass in
1513    1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1514    2)
1515      ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1516      if test $ac_must_keep_next = true; then
1517	ac_must_keep_next=false # Got value, back to normal.
1518      else
1519	case $ac_arg in
1520	  *=* | --config-cache | -C | -disable-* | --disable-* \
1521	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1522	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1523	  | -with-* | --with-* | -without-* | --without-* | --x)
1524	    case "$ac_configure_args0 " in
1525	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1526	    esac
1527	    ;;
1528	  -* ) ac_must_keep_next=true ;;
1529	esac
1530      fi
1531      ac_configure_args="$ac_configure_args '$ac_arg'"
1532      ;;
1533    esac
1534  done
1535done
1536$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1537$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1538
1539# When interrupted or exit'd, cleanup temporary files, and complete
1540# config.log.  We remove comments because anyway the quotes in there
1541# would cause problems or look ugly.
1542# WARNING: Use '\'' to represent an apostrophe within the trap.
1543# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1544trap 'exit_status=$?
1545  # Save into config.log some information that might help in debugging.
1546  {
1547    echo
1548
1549    cat <<\_ASBOX
1550## ---------------- ##
1551## Cache variables. ##
1552## ---------------- ##
1553_ASBOX
1554    echo
1555    # The following way of writing the cache mishandles newlines in values,
1556(
1557  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1558    eval ac_val=\$$ac_var
1559    case $ac_val in #(
1560    *${as_nl}*)
1561      case $ac_var in #(
1562      *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
1563echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
1564      esac
1565      case $ac_var in #(
1566      _ | IFS | as_nl) ;; #(
1567      *) $as_unset $ac_var ;;
1568      esac ;;
1569    esac
1570  done
1571  (set) 2>&1 |
1572    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1573    *${as_nl}ac_space=\ *)
1574      sed -n \
1575	"s/'\''/'\''\\\\'\'''\''/g;
1576	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1577      ;; #(
1578    *)
1579      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1580      ;;
1581    esac |
1582    sort
1583)
1584    echo
1585
1586    cat <<\_ASBOX
1587## ----------------- ##
1588## Output variables. ##
1589## ----------------- ##
1590_ASBOX
1591    echo
1592    for ac_var in $ac_subst_vars
1593    do
1594      eval ac_val=\$$ac_var
1595      case $ac_val in
1596      *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1597      esac
1598      echo "$ac_var='\''$ac_val'\''"
1599    done | sort
1600    echo
1601
1602    if test -n "$ac_subst_files"; then
1603      cat <<\_ASBOX
1604## ------------------- ##
1605## File substitutions. ##
1606## ------------------- ##
1607_ASBOX
1608      echo
1609      for ac_var in $ac_subst_files
1610      do
1611	eval ac_val=\$$ac_var
1612	case $ac_val in
1613	*\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1614	esac
1615	echo "$ac_var='\''$ac_val'\''"
1616      done | sort
1617      echo
1618    fi
1619
1620    if test -s confdefs.h; then
1621      cat <<\_ASBOX
1622## ----------- ##
1623## confdefs.h. ##
1624## ----------- ##
1625_ASBOX
1626      echo
1627      cat confdefs.h
1628      echo
1629    fi
1630    test "$ac_signal" != 0 &&
1631      echo "$as_me: caught signal $ac_signal"
1632    echo "$as_me: exit $exit_status"
1633  } >&5
1634  rm -f core *.core core.conftest.* &&
1635    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1636    exit $exit_status
1637' 0
1638for ac_signal in 1 2 13 15; do
1639  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1640done
1641ac_signal=0
1642
1643# confdefs.h avoids OS command line length limits that DEFS can exceed.
1644rm -f -r conftest* confdefs.h
1645
1646# Predefined preprocessor variables.
1647
1648cat >>confdefs.h <<_ACEOF
1649#define PACKAGE_NAME "$PACKAGE_NAME"
1650_ACEOF
1651
1652
1653cat >>confdefs.h <<_ACEOF
1654#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1655_ACEOF
1656
1657
1658cat >>confdefs.h <<_ACEOF
1659#define PACKAGE_VERSION "$PACKAGE_VERSION"
1660_ACEOF
1661
1662
1663cat >>confdefs.h <<_ACEOF
1664#define PACKAGE_STRING "$PACKAGE_STRING"
1665_ACEOF
1666
1667
1668cat >>confdefs.h <<_ACEOF
1669#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1670_ACEOF
1671
1672
1673# Let the site file select an alternate cache file if it wants to.
1674# Prefer explicitly selected file to automatically selected ones.
1675if test -n "$CONFIG_SITE"; then
1676  set x "$CONFIG_SITE"
1677elif test "x$prefix" != xNONE; then
1678  set x "$prefix/share/config.site" "$prefix/etc/config.site"
1679else
1680  set x "$ac_default_prefix/share/config.site" \
1681	"$ac_default_prefix/etc/config.site"
1682fi
1683shift
1684for ac_site_file
1685do
1686  if test -r "$ac_site_file"; then
1687    { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1688echo "$as_me: loading site script $ac_site_file" >&6;}
1689    sed 's/^/| /' "$ac_site_file" >&5
1690    . "$ac_site_file"
1691  fi
1692done
1693
1694if test -r "$cache_file"; then
1695  # Some versions of bash will fail to source /dev/null (special
1696  # files actually), so we avoid doing that.
1697  if test -f "$cache_file"; then
1698    { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1699echo "$as_me: loading cache $cache_file" >&6;}
1700    case $cache_file in
1701      [\\/]* | ?:[\\/]* ) . "$cache_file";;
1702      *)                      . "./$cache_file";;
1703    esac
1704  fi
1705else
1706  { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1707echo "$as_me: creating cache $cache_file" >&6;}
1708  >$cache_file
1709fi
1710
1711ac_header_list="$ac_header_list sys/time.h"
1712ac_header_list="$ac_header_list unistd.h"
1713ac_func_list="$ac_func_list alarm"
1714# Check that the precious variables saved in the cache have kept the same
1715# value.
1716ac_cache_corrupted=false
1717for ac_var in $ac_precious_vars; do
1718  eval ac_old_set=\$ac_cv_env_${ac_var}_set
1719  eval ac_new_set=\$ac_env_${ac_var}_set
1720  eval ac_old_val=\$ac_cv_env_${ac_var}_value
1721  eval ac_new_val=\$ac_env_${ac_var}_value
1722  case $ac_old_set,$ac_new_set in
1723    set,)
1724      { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1725echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1726      ac_cache_corrupted=: ;;
1727    ,set)
1728      { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1729echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1730      ac_cache_corrupted=: ;;
1731    ,);;
1732    *)
1733      if test "x$ac_old_val" != "x$ac_new_val"; then
1734	{ echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1735echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1736	{ echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1737echo "$as_me:   former value:  $ac_old_val" >&2;}
1738	{ echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1739echo "$as_me:   current value: $ac_new_val" >&2;}
1740	ac_cache_corrupted=:
1741      fi;;
1742  esac
1743  # Pass precious variables to config.status.
1744  if test "$ac_new_set" = set; then
1745    case $ac_new_val in
1746    *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1747    *) ac_arg=$ac_var=$ac_new_val ;;
1748    esac
1749    case " $ac_configure_args " in
1750      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1751      *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1752    esac
1753  fi
1754done
1755if $ac_cache_corrupted; then
1756  { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1757echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1758  { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1759echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1760   { (exit 1); exit 1; }; }
1761fi
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779ac_ext=c
1780ac_cpp='$CPP $CPPFLAGS'
1781ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1782ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1783ac_compiler_gnu=$ac_cv_c_compiler_gnu
1784
1785
1786ac_config_headers="$ac_config_headers src/config.h:src/config.in"
1787
1788
1789test "$program_prefix" != NONE &&
1790  program_transform_name="s&^&$program_prefix&;$program_transform_name"
1791# Use a double $ so make ignores it.
1792test "$program_suffix" != NONE &&
1793  program_transform_name="s&\$&$program_suffix&;$program_transform_name"
1794# Double any \ or $.  echo might interpret backslashes.
1795# By default was `s,x,x', remove it if useless.
1796cat <<\_ACEOF >conftest.sed
1797s/[\\$]/&&/g;s/;s,x,x,$//
1798_ACEOF
1799program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1800rm -f conftest.sed
1801
1802
1803lispdir='${datadir}/emacs/${version}/lisp'
1804locallisppath='${datadir}/emacs/${version}/site-lisp:'\
1805'${datadir}/emacs/site-lisp'
1806lisppath='${locallisppath}:${lispdir}:${datadir}/emacs/${version}/leim'
1807etcdir='${datadir}/emacs/${version}/etc'
1808archlibdir='${libexecdir}/emacs/${version}/${configuration}'
1809docdir='${datadir}/emacs/${version}/etc'
1810gamedir='${localstatedir}/games/emacs'
1811
1812gameuser=games
1813
1814
1815# Check whether --with-gcc was given.
1816if test "${with_gcc+set}" = set; then
1817  withval=$with_gcc;
1818fi
1819
1820
1821# Check whether --with-pop was given.
1822if test "${with_pop+set}" = set; then
1823  withval=$with_pop; if test "$withval" = yes; then
1824   cat >>confdefs.h <<\_ACEOF
1825#define MAIL_USE_POP 1
1826_ACEOF
1827
1828else :
1829fi
1830else
1831  cat >>confdefs.h <<\_ACEOF
1832#define MAIL_USE_POP 1
1833_ACEOF
1834
1835fi
1836
1837
1838
1839# Check whether --with-kerberos was given.
1840if test "${with_kerberos+set}" = set; then
1841  withval=$with_kerberos; if test "$withval" = yes; then
1842   cat >>confdefs.h <<\_ACEOF
1843#define KERBEROS 1
1844_ACEOF
1845
1846fi
1847fi
1848
1849
1850
1851# Check whether --with-kerberos5 was given.
1852if test "${with_kerberos5+set}" = set; then
1853  withval=$with_kerberos5; if test "${with_kerberos5+set}" = set; then
1854  if test "${with_kerberos+set}" != set; then
1855    with_kerberos=yes
1856    cat >>confdefs.h <<\_ACEOF
1857#define KERBEROS 1
1858_ACEOF
1859
1860  fi
1861
1862cat >>confdefs.h <<\_ACEOF
1863#define KERBEROS5 1
1864_ACEOF
1865
1866fi
1867fi
1868
1869
1870# Check whether --with-hesiod was given.
1871if test "${with_hesiod+set}" = set; then
1872  withval=$with_hesiod; if test "$withval" = yes; then
1873
1874cat >>confdefs.h <<\_ACEOF
1875#define HESIOD 1
1876_ACEOF
1877
1878fi
1879fi
1880
1881
1882
1883# Check whether --with-sound was given.
1884if test "${with_sound+set}" = set; then
1885  withval=$with_sound;
1886fi
1887
1888
1889
1890# Check whether --with-x-toolkit was given.
1891if test "${with_x_toolkit+set}" = set; then
1892  withval=$with_x_toolkit; 	  case "${withval}" in
1893	    y | ye | yes )	val=athena ;;
1894	    n | no )		val=no  ;;
1895	    l | lu | luc | luci | lucid )	val=lucid ;;
1896	    a | at | ath | athe | athen | athena )	val=athena ;;
1897	    m | mo | mot | moti | motif )	val=motif ;;
1898	    g | gt | gtk  )	val=gtk ;;
1899	    * )
1900{ { echo "$as_me:$LINENO: error: \`--with-x-toolkit=$withval' is invalid\;
1901this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
1902Currently, \`yes', \`athena' and \`lucid' are synonyms." >&5
1903echo "$as_me: error: \`--with-x-toolkit=$withval' is invalid\;
1904this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
1905Currently, \`yes', \`athena' and \`lucid' are synonyms." >&2;}
1906   { (exit 1); exit 1; }; }
1907	    ;;
1908	  esac
1909	  with_x_toolkit=$val
1910
1911fi
1912
1913
1914# Check whether --with-xpm was given.
1915if test "${with_xpm+set}" = set; then
1916  withval=$with_xpm;
1917fi
1918
1919
1920# Check whether --with-jpeg was given.
1921if test "${with_jpeg+set}" = set; then
1922  withval=$with_jpeg;
1923fi
1924
1925
1926# Check whether --with-tiff was given.
1927if test "${with_tiff+set}" = set; then
1928  withval=$with_tiff;
1929fi
1930
1931
1932# Check whether --with-gif was given.
1933if test "${with_gif+set}" = set; then
1934  withval=$with_gif;
1935fi
1936
1937
1938# Check whether --with-png was given.
1939if test "${with_png+set}" = set; then
1940  withval=$with_png;
1941fi
1942
1943
1944# Check whether --with-gtk was given.
1945if test "${with_gtk+set}" = set; then
1946  withval=$with_gtk;
1947fi
1948
1949
1950# Check whether --with-pkg-config-prog was given.
1951if test "${with_pkg_config_prog+set}" = set; then
1952  withval=$with_pkg_config_prog;
1953fi
1954
1955
1956# Check whether --with-toolkit-scroll-bars was given.
1957if test "${with_toolkit_scroll_bars+set}" = set; then
1958  withval=$with_toolkit_scroll_bars;
1959fi
1960
1961
1962# Check whether --with-xim was given.
1963if test "${with_xim+set}" = set; then
1964  withval=$with_xim;
1965fi
1966
1967
1968# Check whether --with-carbon was given.
1969if test "${with_carbon+set}" = set; then
1970  withval=$with_carbon;
1971fi
1972
1973# Check whether --enable-carbon-app was given.
1974if test "${enable_carbon_app+set}" = set; then
1975  enableval=$enable_carbon_app;  carbon_appdir_x=${enableval}
1976fi
1977
1978
1979# Check whether --enable-asserts was given.
1980if test "${enable_asserts+set}" = set; then
1981  enableval=$enable_asserts; USE_XASSERTS=$enableval
1982else
1983  USE_XASSERTS=no
1984fi
1985
1986
1987# Check whether --enable-maintainer-mode was given.
1988if test "${enable_maintainer_mode+set}" = set; then
1989  enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
1990else
1991  USE_MAINTAINER_MODE=no
1992fi
1993
1994if test $USE_MAINTAINER_MODE = yes; then
1995  MAINT=
1996else
1997  MAINT=#
1998fi
1999
2000
2001# Check whether --enable-locallisppath was given.
2002if test "${enable_locallisppath+set}" = set; then
2003  enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
2004  locallisppath=
2005elif test "${enableval}" != "yes"; then
2006  locallisppath=${enableval}
2007fi
2008fi
2009
2010
2011#### Make srcdir absolute, if it isn't already.  It's important to
2012#### avoid running the path through pwd unnecessarily, since pwd can
2013#### give you automounter prefixes, which can go away.  We do all this
2014#### so Emacs can find its files when run uninstalled.
2015## Make sure CDPATH doesn't affect cd (in case PWD is relative).
2016unset CDPATH
2017case "${srcdir}" in
2018  /* ) ;;
2019  . )
2020    ## We may be able to use the $PWD environment variable to make this
2021    ## absolute.  But sometimes PWD is inaccurate.
2022    ## Note: we used to use ${PWD} at the end instead of `pwd`,
2023    ## but that tested only for a well-formed and valid PWD,
2024    ## it did not object when PWD was well-formed and valid but just wrong.
2025    if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`"  ;
2026    then
2027      srcdir="$PWD"
2028    else
2029      srcdir="`(cd ${srcdir}; pwd)`"
2030    fi
2031  ;;
2032  *  ) srcdir="`(cd ${srcdir}; pwd)`" ;;
2033esac
2034
2035#### Check if the source directory already has a configured system in it.
2036if test `pwd` != `(cd ${srcdir} && pwd)` \
2037   && test -f "${srcdir}/src/config.h" ; then
2038  { echo "$as_me:$LINENO: WARNING: The directory tree \`${srcdir}' is being used
2039   as a build directory right now; it has been configured in its own
2040   right.  To configure in another directory as well, you MUST
2041   use GNU make.  If you do not have GNU make, then you must
2042   now do \`make distclean' in ${srcdir},
2043   and then run $0 again." >&5
2044echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used
2045   as a build directory right now; it has been configured in its own
2046   right.  To configure in another directory as well, you MUST
2047   use GNU make.  If you do not have GNU make, then you must
2048   now do \`make distclean' in ${srcdir},
2049   and then run $0 again." >&2;}
2050fi
2051
2052#### Given the configuration name, set machfile and opsysfile to the
2053#### names of the m/*.h and s/*.h files we should use.
2054
2055### Canonicalize the configuration name.
2056
2057ac_aux_dir=
2058for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
2059  if test -f "$ac_dir/install-sh"; then
2060    ac_aux_dir=$ac_dir
2061    ac_install_sh="$ac_aux_dir/install-sh -c"
2062    break
2063  elif test -f "$ac_dir/install.sh"; then
2064    ac_aux_dir=$ac_dir
2065    ac_install_sh="$ac_aux_dir/install.sh -c"
2066    break
2067  elif test -f "$ac_dir/shtool"; then
2068    ac_aux_dir=$ac_dir
2069    ac_install_sh="$ac_aux_dir/shtool install -c"
2070    break
2071  fi
2072done
2073if test -z "$ac_aux_dir"; then
2074  { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5
2075echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;}
2076   { (exit 1); exit 1; }; }
2077fi
2078
2079# These three variables are undocumented and unsupported,
2080# and are intended to be withdrawn in a future Autoconf release.
2081# They can cause serious problems if a builder's source tree is in a directory
2082# whose full name contains unusual characters.
2083ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2084ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2085ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2086
2087
2088# Make sure we can run config.sub.
2089$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2090  { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2091echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2092   { (exit 1); exit 1; }; }
2093
2094{ echo "$as_me:$LINENO: checking build system type" >&5
2095echo $ECHO_N "checking build system type... $ECHO_C" >&6; }
2096if test "${ac_cv_build+set}" = set; then
2097  echo $ECHO_N "(cached) $ECHO_C" >&6
2098else
2099  ac_build_alias=$build_alias
2100test "x$ac_build_alias" = x &&
2101  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2102test "x$ac_build_alias" = x &&
2103  { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2104echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2105   { (exit 1); exit 1; }; }
2106ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2107  { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2108echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2109   { (exit 1); exit 1; }; }
2110
2111fi
2112{ echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2113echo "${ECHO_T}$ac_cv_build" >&6; }
2114case $ac_cv_build in
2115*-*-*) ;;
2116*) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2117echo "$as_me: error: invalid value of canonical build" >&2;}
2118   { (exit 1); exit 1; }; };;
2119esac
2120build=$ac_cv_build
2121ac_save_IFS=$IFS; IFS='-'
2122set x $ac_cv_build
2123shift
2124build_cpu=$1
2125build_vendor=$2
2126shift; shift
2127# Remember, the first character of IFS is used to create $*,
2128# except with old shells:
2129build_os=$*
2130IFS=$ac_save_IFS
2131case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2132
2133
2134{ echo "$as_me:$LINENO: checking host system type" >&5
2135echo $ECHO_N "checking host system type... $ECHO_C" >&6; }
2136if test "${ac_cv_host+set}" = set; then
2137  echo $ECHO_N "(cached) $ECHO_C" >&6
2138else
2139  if test "x$host_alias" = x; then
2140  ac_cv_host=$ac_cv_build
2141else
2142  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2143    { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2144echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2145   { (exit 1); exit 1; }; }
2146fi
2147
2148fi
2149{ echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2150echo "${ECHO_T}$ac_cv_host" >&6; }
2151case $ac_cv_host in
2152*-*-*) ;;
2153*) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2154echo "$as_me: error: invalid value of canonical host" >&2;}
2155   { (exit 1); exit 1; }; };;
2156esac
2157host=$ac_cv_host
2158ac_save_IFS=$IFS; IFS='-'
2159set x $ac_cv_host
2160shift
2161host_cpu=$1
2162host_vendor=$2
2163shift; shift
2164# Remember, the first character of IFS is used to create $*,
2165# except with old shells:
2166host_os=$*
2167IFS=$ac_save_IFS
2168case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2169
2170
2171canonical=$host
2172configuration=${host_alias-$host}
2173
2174
2175
2176### If you add support for a new configuration, add code to this
2177### switch statement to recognize your configuration name and select
2178### the appropriate operating system and machine description files.
2179
2180### You would hope that you could choose an m/*.h file pretty much
2181### based on the machine portion of the configuration name, and an s-
2182### file based on the operating system portion.  However, it turns out
2183### that each m/*.h file is pretty manufacturer-specific - for
2184### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are
2185### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS
2186### machines.  So we basically have to have a special case for each
2187### configuration name.
2188###
2189### As far as handling version numbers on operating systems is
2190### concerned, make sure things will fail in a fixable way.  If
2191### /etc/MACHINES doesn't say anything about version numbers, be
2192### prepared to handle anything reasonably.  If version numbers
2193### matter, be sure /etc/MACHINES says something about it.
2194###
2195### Eric Raymond says we should accept strings like "sysvr4" to mean
2196### "System V Release 4"; he writes, "The old convention encouraged
2197### confusion between `system' and `release' levels'."
2198
2199machine='' opsys='' unported=no
2200case "${canonical}" in
2201
2202  ## FreeBSD ports
2203  *-*-freebsd* )
2204    opsys=freebsd
2205    case "${canonical}" in
2206      alpha*-*-freebsd*)	machine=alpha ;;
2207      ia64-*-freebsd*)		machine=ia64 ;;
2208      sparc64-*-freebsd*)	machine=sparc ;;
2209      powerpc-*-freebsd*)	machine=macppc ;;
2210      i[3456]86-*-freebsd*)	machine=intel386 ;;
2211      amd64-*-freebsd*|x86_64-*-freebsd*) machine=amdx86-64 ;;
2212    esac
2213  ;;
2214
2215  ## NetBSD ports
2216  *-*-netbsd* )
2217    opsys=netbsd
2218    if test -f /usr/lib/crti.o; then
2219
2220cat >>confdefs.h <<\_ACEOF
2221#define HAVE_CRTIN
2222_ACEOF
2223
2224   fi
2225
2226    case "${canonical}" in
2227      alpha*-*-netbsd*)	machine=alpha ;;
2228      i[3456]86-*-netbsd*) machine=intel386 ;;
2229      m68k-*-netbsd*)
2230			# This is somewhat bogus.
2231			machine=hp9000s300 ;;
2232      mips-*-netbsd*)	machine=pmax ;;
2233      mipsel-*-netbsd*)	machine=pmax ;;
2234      mipseb-*-netbsd*)	machine=pmax ;;
2235      ns32k-*-netbsd*)	machine=ns32000 ;;
2236      powerpc-*-netbsd*) machine=macppc ;;
2237      sparc*-*-netbsd*)	machine=sparc ;;
2238      vax-*-netbsd*)	machine=vax ;;
2239      arm-*-netbsd*)	machine=arm ;;
2240      x86_64-*-netbsd*)	machine=amdx86-64 ;;
2241      hppa-*-netbsd*)	machine=hp800 ;;
2242      shle-*-netbsd*)	machine=sh3el ;;
2243    esac
2244  ;;
2245
2246  ## OpenBSD ports
2247  *-*-openbsd* )
2248    opsys=openbsd
2249    case "${canonical}" in
2250      alpha*-*-openbsd*)	machine=alpha ;;
2251      arm-*-openbsd*)          machine=arm ;;
2252      hppa-*-openbsd*)         machine=hp9000s300 ;;
2253      i386-*-openbsd*)         machine=intel386 ;;
2254      m68k-*-openbsd*)         machine=hp9000s300 ;;
2255      m88k-*-openbsd*)         machine=aviion ;;
2256      mips64-*-openbsd*)       machine=mips64 ;;
2257      powerpc-*-openbsd*)      machine=macppc ;;
2258      sh-*-openbsd*)           machine=sh3el ;;
2259      sparc*-*-openbsd*)       machine=sparc ;;
2260      vax-*-openbsd*)          machine=vax ;;
2261      x86_64-*-openbsd*)       machine=amdx86-64 ;;
2262    esac
2263  ;;
2264
2265  ## LynxOS ports
2266  *-*-lynxos* )
2267    opsys=lynxos
2268    case "${canonical}" in
2269      i[3456]86-*-lynxos*) machine=intel386 ;;
2270      powerpc-*-lynxos*) machine=powerpc ;;
2271    esac
2272  ;;
2273
2274  ## Acorn RISCiX:
2275  arm-acorn-riscix1.1* )
2276    machine=acorn opsys=riscix1-1
2277  ;;
2278  arm-acorn-riscix1.2* | arm-acorn-riscix )
2279    ## This name is riscix12 instead of riscix1.2
2280    ## to avoid a file name conflict on MSDOS.
2281    machine=acorn opsys=riscix12
2282  ;;
2283
2284  ## BSDI ports
2285  *-*-bsdi* )
2286    opsys=bsdi
2287    case "${canonical}" in
2288      i[345]86-*-bsdi*) machine=intel386 ;;
2289      sparc-*-bsdi*)  machine=sparc ;;
2290      powerpc-*-bsdi*)  machine=macppc ;;
2291    esac
2292    case "${canonical}" in
2293      *-*-bsd386* | *-*-bsdi1* )	opsys=bsd386 ;;
2294      *-*-bsdi2.0* )		opsys=bsdos2 ;;
2295      *-*-bsdi2* )		opsys=bsdos2-1 ;;
2296      *-*-bsdi3* )		opsys=bsdos3 ;;
2297      *-*-bsdi[45]* )		opsys=bsdos4 ;;
2298    esac
2299  ;;
2300
2301  ## Alliant machines
2302  ## Strictly speaking, we need the version of the alliant operating
2303  ## system to choose the right machine file, but currently the
2304  ## configuration name doesn't tell us enough to choose the right
2305  ## one; we need to give alliants their own operating system name to
2306  ## do this right.  When someone cares, they can help us.
2307  fx80-alliant-* )
2308    machine=alliant4 opsys=bsd4-2
2309  ;;
2310  i860-alliant-* )
2311    machine=alliant-2800 opsys=bsd4-3
2312  ;;
2313
2314  ## Alpha (DEC) machines.
2315  alpha*-dec-osf* )
2316    machine=alpha opsys=osf1
2317    # This is needed to find X11R6.1 libraries for certain tests.
2318    NON_GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
2319    GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
2320    # NON_GNU_CPP is necessary on 5.0 to avoid mangling src/Makefile
2321    # due to non-traditional preprocessing with the current compiler
2322    # defaults.  OSF 4 can also have that compiler version, and there
2323    # seems always to have been a usable /usr/bin/cpp.
2324    NON_GNU_CPP=/usr/bin/cpp
2325    case "${canonical}" in
2326    alpha*-dec-osf[5-9]*)
2327      opsys=osf5-0 ;;
2328    esac
2329  ;;
2330
2331  alpha*-*-linux-gnu* )
2332    machine=alpha opsys=gnu-linux
2333  ;;
2334
2335  arm*-*-linux-gnu* )
2336    machine=arm opsys=gnu-linux
2337  ;;
2338
2339  ## Altos 3068
2340  m68*-altos-sysv* )
2341    machine=altos opsys=usg5-2
2342  ;;
2343
2344  ## Amdahl UTS
2345  580-amdahl-sysv* )
2346    machine=amdahl opsys=usg5-2-2
2347  ;;
2348
2349  ## Apollo, Domain/OS
2350  m68*-apollo-* )
2351    machine=apollo opsys=bsd4-3
2352  ;;
2353
2354  ## Apple Darwin / Mac OS X
2355  *-apple-darwin* )
2356    case "${canonical}" in
2357      i[3456]86-* )  machine=mac ;;
2358      powerpc-* )    machine=mac ;;
2359      mac-apple-darwin* ) machine=mac;;
2360      * )            unported=yes ;;
2361    esac
2362    opsys=darwin
2363    # Define CPP as follows to make autoconf work correctly.
2364    CPP="${CC-cc} -E -no-cpp-precomp"
2365    # Use fink packages if available.
2366    if false && test -d /sw/include && test -d /sw/lib; then
2367      GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
2368      CPP="${CPP} ${GCC_TEST_OPTIONS}"
2369      NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
2370    fi
2371  ;;
2372
2373  ## AT&T 3b2, 3b5, 3b15, 3b20
2374  we32k-att-sysv* )
2375    machine=att3b opsys=usg5-2-2
2376  ;;
2377
2378  ## AT&T 3b1 - The Mighty Unix PC!
2379  m68*-att-sysv* )
2380    machine=7300 opsys=usg5-2-2
2381  ;;
2382
2383  ## Bull dpx20
2384  rs6000-bull-bosx* )
2385    machine=ibmrs6000 opsys=aix3-2
2386  ;;
2387
2388  ## Bull dpx2
2389  m68*-bull-sysv3* )
2390    machine=dpx2 opsys=usg5-3
2391  ;;
2392
2393  ## Bull sps7
2394  m68*-bull-sysv2* )
2395    machine=sps7 opsys=usg5-2
2396  ;;
2397
2398  ## CCI 5/32, 6/32 -- see "Tahoe".
2399
2400  ## Celerity
2401  ## I don't know what configuration name to use for this; config.sub
2402  ## doesn't seem to know anything about it.  Hey, Celerity users, get
2403  ## in touch with us!
2404  celerity-celerity-bsd* )
2405    machine=celerity opsys=bsd4-2
2406  ;;
2407
2408  ## Clipper
2409  ## What operating systems does this chip run that Emacs has been
2410  ## tested on?
2411  clipper-* )
2412    machine=clipper
2413    ## We'll use the catch-all code at the bottom to guess the
2414    ## operating system.
2415  ;;
2416
2417  ## Compaq Nonstop
2418  mips-compaq-nonstopux* )
2419    machine=nonstopux opsys=nonstopux
2420    ;;
2421
2422  ## Convex
2423  *-convex-bsd* | *-convex-convexos* )
2424    machine=convex opsys=bsd4-3
2425    ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov
2426    NON_GNU_CPP="cc -E -P"
2427  ;;
2428
2429  ## Cubix QBx/386
2430  i[3456]86-cubix-sysv* )
2431    machine=intel386 opsys=usg5-3
2432  ;;
2433
2434  ## Cydra 5
2435  cydra*-cydrome-sysv* )
2436    machine=cydra5 opsys=usg5-3
2437  ;;
2438
2439  ## Data General AViiON Machines
2440  ## DG changed naming conventions with the release of 5.4.4.10, they
2441  ## dropped the initial 5.4 but left the intervening R.  Because of the
2442  ## R this shouldn't conflict with older versions of the OS (which I
2443  ## think were named like dgux4.*). In addition, DG new AViiONs series
2444  ## uses either Motorola M88k or Intel Pentium CPUs.
2445  m88k-dg-dguxR4.* | m88k-dg-dgux4* )
2446    machine=aviion opsys=dgux4
2447  ;;
2448  m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* )
2449    ## This name is dgux5-4-3 instead of dgux5-4r3
2450    ## to avoid a file name conflict on MSDOS.
2451    machine=aviion opsys=dgux5-4-3
2452  ;;
2453  m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* )
2454    machine=aviion opsys=dgux5-4r2
2455  ;;
2456  m88k-dg-dgux* )
2457    machine=aviion opsys=dgux
2458  ;;
2459
2460  ## Data General AViiON Intel (x86) Machines
2461  ## Exists from 5.4.3 (current i586-dg-dguxR4.11)
2462  ## Ehud Karni, 1998-may-30, ehud@unix.simonwiesel.co.il
2463  i[345]86-dg-dguxR4* )
2464    machine=aviion-intel opsys=dgux4
2465  ;;
2466
2467  ## DECstations
2468  mips-dec-ultrix[0-3].* | mips-dec-ultrix4.0* | mips-dec-bsd4.2* )
2469    machine=pmax opsys=bsd4-2
2470  ;;
2471  mips-dec-ultrix4.[12]* | mips-dec-bsd* )
2472    machine=pmax opsys=bsd4-3
2473  ;;
2474  mips-dec-ultrix* )
2475    machine=pmax opsys=ultrix4-3
2476  ;;
2477  mips-dec-osf* )
2478    machine=pmax opsys=osf1
2479  ;;
2480  mips-dec-mach_bsd4.3* )
2481    machine=pmax opsys=mach-bsd4-3
2482  ;;
2483
2484  ## Motorola Delta machines
2485  m68k-motorola-sysv* | m68000-motorola-sysv* )
2486    machine=delta opsys=usg5-3
2487    if test -z "`type gnucc | grep 'not found'`"
2488    then
2489      if test -s /etc/167config
2490      then CC="gnucc -m68040"
2491      else CC="gnucc -m68881"
2492      fi
2493    else
2494      if test -z "`type gcc | grep 'not found'`"
2495      then CC=gcc
2496      else CC=cc
2497      fi
2498    fi
2499  ;;
2500  m88k-motorola-sysv4* )
2501    # jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110
2502    # needs POSIX_SIGNALS and therefore needs usg5-4-2.
2503    # I hope there are not other 4.0 versions for this machine
2504    # which really need usg5-4 instead.
2505    machine=delta88k opsys=usg5-4-2
2506  ;;
2507  m88k-motorola-sysv* | m88k-motorola-m88kbcs* )
2508    machine=delta88k opsys=usg5-3
2509  ;;
2510
2511  ## Dual machines
2512  m68*-dual-sysv* )
2513    machine=dual opsys=usg5-2
2514  ;;
2515  m68*-dual-uniplus* )
2516    machine=dual opsys=unipl5-2
2517  ;;
2518
2519  ## Elxsi 6400
2520  elxsi-elxsi-sysv* )
2521    machine=elxsi opsys=usg5-2
2522  ;;
2523
2524  ## Encore machines
2525  ns16k-encore-bsd* )
2526    machine=ns16000 opsys=umax
2527  ;;
2528
2529  ## The GEC 63 - apparently, this port isn't really finished yet.
2530  #  I'm sure we finished off the last of the machines, though.  -- fx
2531
2532  ## Gould Power Node and NP1
2533  pn-gould-bsd4.2* )
2534    machine=gould opsys=bsd4-2
2535  ;;
2536  pn-gould-bsd4.3* )
2537    machine=gould opsys=bsd4-3
2538  ;;
2539  np1-gould-bsd* )
2540    machine=gould-np1 opsys=bsd4-3
2541  ;;
2542
2543  ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000
2544  ## as far as Emacs is concerned).
2545  m88k-harris-cxux* )
2546    # Build needs to be different on 7.0 and later releases
2547    case "`uname -r`" in
2548       [56].[0-9] ) machine=nh4000 opsys=cxux ;;
2549       [7].[0-9] ) machine=nh4000 opsys=cxux7 ;;
2550    esac
2551    NON_GNU_CPP="/lib/cpp"
2552  ;;
2553  ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000)
2554  m68k-harris-cxux* )
2555    machine=nh3000 opsys=cxux
2556  ;;
2557  ## Harris power pc NightHawk running Power UNIX (Series 6000)
2558  powerpc-harris-powerunix )
2559    machine=nh6000 opsys=powerunix
2560    NON_GNU_CPP="cc -Xo -E -P"
2561  ;;
2562  ## SR2001/SR2201 running HI-UX/MPP
2563  hppa1.1-hitachi-hiuxmpp* )
2564    machine=sr2k opsys=hiuxmpp
2565  ;;
2566  hppa1.1-hitachi-hiuxwe2* )
2567    machine=sr2k opsys=hiuxwe2
2568  ;;
2569  ## Honeywell XPS100
2570  xps*-honeywell-sysv* )
2571    machine=xps100 opsys=usg5-2
2572  ;;
2573
2574  ## HP 9000 series 200 or 300
2575  m68*-hp-bsd* )
2576    machine=hp9000s300 opsys=bsd4-3
2577  ;;
2578  ## HP/UX 7, 8, 9, and 10 are supported on these machines.
2579  m68*-hp-hpux* )
2580    case "`uname -r`" in
2581      ## Someone's system reports A.B8.05 for this.
2582      ## I wonder what other possibilities there are.
2583      *.B8.* ) machine=hp9000s300 opsys=hpux8 ;;
2584      *.08.* ) machine=hp9000s300 opsys=hpux8 ;;
2585      *.09.* ) machine=hp9000s300 opsys=hpux9 ;;
2586      *.1[0-9].* ) machine=hp9000s300 opsys=hpux9shr ;;
2587      *) machine=hp9000s300 opsys=hpux ;;
2588    esac
2589  ;;
2590
2591  ## HP 9000 series 700 and 800, running HP/UX
2592  hppa*-hp-hpux7* )
2593    machine=hp800 opsys=hpux
2594  ;;
2595  hppa*-hp-hpux8* )
2596    machine=hp800 opsys=hpux8
2597  ;;
2598  hppa*-hp-hpux9shr* )
2599    machine=hp800 opsys=hpux9shr
2600  ;;
2601  hppa*-hp-hpux9* )
2602    machine=hp800 opsys=hpux9
2603  ;;
2604  hppa*-hp-hpux10.2* )
2605    machine=hp800 opsys=hpux10-20
2606  ;;
2607  hppa*-hp-hpux10* )
2608    machine=hp800 opsys=hpux10
2609  ;;
2610  hppa*-hp-hpux1[1-9]* )
2611    machine=hp800 opsys=hpux11
2612    CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
2613  ;;
2614
2615  hppa*-*-linux-gnu* )
2616    machine=hp800 opsys=gnu-linux
2617  ;;
2618
2619  ## HP 9000 series 700 and 800, running HP/UX
2620  hppa*-hp-hpux* )
2621    ## Cross-compilation?  Nah!
2622    case "`uname -r`" in
2623      ## Someone's system reports A.B8.05 for this.
2624      ## I wonder what other possibilities there are.
2625      *.B8.* ) machine=hp800 opsys=hpux8 ;;
2626      *.08.* ) machine=hp800 opsys=hpux8 ;;
2627      *.09.* ) machine=hp800 opsys=hpux9 ;;
2628      *) machine=hp800 opsys=hpux10 ;;
2629    esac
2630  ;;
2631  hppa*-*-nextstep* )
2632    machine=hp800 opsys=nextstep
2633  ;;
2634
2635  ## Orion machines
2636  orion-orion-bsd* )
2637    machine=orion opsys=bsd4-2
2638  ;;
2639  clipper-orion-bsd* )
2640    machine=orion105 opsys=bsd4-2
2641  ;;
2642
2643  ## IBM machines
2644  i[3456]86-ibm-aix1.1* )
2645    machine=ibmps2-aix opsys=usg5-2-2
2646  ;;
2647  i[3456]86-ibm-aix1.[23]* | i[3456]86-ibm-aix* )
2648    machine=ibmps2-aix opsys=usg5-3
2649  ;;
2650  i370-ibm-aix*)
2651    machine=ibm370aix opsys=usg5-3
2652  ;;
2653  s390-*-linux-gnu* )
2654    machine=ibms390 opsys=gnu-linux
2655  ;;
2656  s390x-*-linux-gnu* )
2657    machine=ibms390x opsys=gnu-linux
2658  ;;
2659  rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1*  )
2660    machine=ibmrs6000 opsys=aix3-1
2661  ;;
2662  rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 )
2663    machine=ibmrs6000 opsys=aix3-2-5
2664  ;;
2665  rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1*  )
2666    machine=ibmrs6000 opsys=aix4-1
2667  ;;
2668  rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2*  )
2669    machine=ibmrs6000 opsys=aix4-2
2670  ;;
2671  rs6000-ibm-aix4.3* | powerpc-ibm-aix4.3*  )
2672    machine=ibmrs6000 opsys=aix4-2
2673  ;;
2674  rs6000-ibm-aix5* | powerpc-ibm-aix5*  )
2675    machine=ibmrs6000 opsys=aix4-2
2676  ;;
2677  rs6000-ibm-aix4.0* | powerpc-ibm-aix4.0*  )
2678    machine=ibmrs6000 opsys=aix4
2679  ;;
2680  rs6000-ibm-aix4* | powerpc-ibm-aix4*  )
2681    machine=ibmrs6000 opsys=aix4-1
2682  ;;
2683  rs6000-ibm-aix* | powerpc-ibm-aix* )
2684    machine=ibmrs6000 opsys=aix3-2
2685  ;;
2686  romp-ibm-bsd4.3* )
2687    machine=ibmrt opsys=bsd4-3
2688  ;;
2689  romp-ibm-bsd4.2* )
2690    machine=ibmrt opsys=bsd4-2
2691  ;;
2692  romp-ibm-aos4.3* )
2693    machine=ibmrt opsys=bsd4-3
2694  ;;
2695  romp-ibm-aos4.2* )
2696    machine=ibmrt opsys=bsd4-2
2697  ;;
2698  romp-ibm-aos* )
2699    machine=ibmrt opsys=bsd4-3
2700  ;;
2701  romp-ibm-bsd* )
2702    machine=ibmrt opsys=bsd4-3
2703  ;;
2704  romp-ibm-aix* )
2705    machine=ibmrt-aix opsys=usg5-2-2
2706  ;;
2707
2708  ## Integrated Solutions `Optimum V'
2709  m68*-isi-bsd4.2* )
2710    machine=isi-ov opsys=bsd4-2
2711  ;;
2712  m68*-isi-bsd4.3* )
2713    machine=isi-ov opsys=bsd4-3
2714  ;;
2715
2716  ## Intel 386 machines where we do care about the manufacturer
2717  i[3456]86-intsys-sysv* )
2718    machine=is386 opsys=usg5-2-2
2719  ;;
2720
2721  ## Prime EXL
2722  i[3456]86-prime-sysv* )
2723    machine=i386 opsys=usg5-3
2724  ;;
2725
2726  ## Sequent Symmetry running Dynix
2727  i[3456]86-sequent-bsd* )
2728    machine=symmetry opsys=bsd4-3
2729  ;;
2730
2731  ## Sequent Symmetry running ptx 4, which is a modified SVR4.
2732  i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* )
2733    machine=sequent-ptx opsys=ptx4
2734    NON_GNU_CPP=/lib/cpp
2735  ;;
2736
2737  ## Sequent Symmetry running DYNIX/ptx
2738  ## Use the old cpp rather than the newer ANSI one.
2739  i[3456]86-sequent-ptx* )
2740    machine=sequent-ptx opsys=ptx
2741    NON_GNU_CPP="/lib/cpp"
2742  ;;
2743
2744  ## ncr machine running svr4.3.
2745  i[3456]86-ncr-sysv4.3 )
2746    machine=ncr386 opsys=usg5-4-3
2747  ;;
2748
2749  ## Unspecified sysv on an ncr machine defaults to svr4.2.
2750  ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.)
2751  i[3456]86-ncr-sysv* )
2752    machine=ncr386 opsys=usg5-4-2
2753  ;;
2754
2755  ## Intel Paragon OSF/1
2756  i860-intel-osf1* )
2757    machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp
2758  ;;
2759
2760  ## Intel 860
2761  i860-*-sysv4* )
2762    machine=i860 opsys=usg5-4
2763    NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc.
2764    NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion.
2765  ;;
2766
2767  ## Macintosh PowerPC
2768  powerpc*-*-linux-gnu* )
2769    machine=macppc opsys=gnu-linux
2770  ;;
2771
2772  ## Masscomp machines
2773  m68*-masscomp-rtu* )
2774    machine=masscomp opsys=rtu
2775  ;;
2776
2777  ## Megatest machines
2778  m68*-megatest-bsd* )
2779    machine=mega68 opsys=bsd4-2
2780  ;;
2781
2782  ## Workstations sold by MIPS
2783  ## This is not necessarily all workstations using the MIPS processor -
2784  ## Irises are produced by SGI, and DECstations by DEC.
2785
2786  ## etc/MACHINES lists mips.h and mips4.h as possible machine files,
2787  ## and usg5-2-2 and bsd4-3 as possible OS files.  The only guidance
2788  ## it gives for choosing between the alternatives seems to be "Use
2789  ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with
2790  ## the BSD world."  I'll assume that these are instructions for
2791  ## handling two odd situations, and that every other situation
2792  ## should use mips.h and usg5-2-2, they being listed first.
2793  mips-mips-usg* )
2794    machine=mips4
2795    ## Fall through to the general code at the bottom to decide on the OS.
2796  ;;
2797  mips-mips-riscos4* )
2798    machine=mips4 opsys=bsd4-3
2799    NON_GNU_CC="cc -systype bsd43"
2800    NON_GNU_CPP="cc -systype bsd43 -E"
2801  ;;
2802  mips-mips-riscos5* )
2803    machine=mips4 opsys=riscos5
2804    NON_GNU_CC="cc -systype bsd43"
2805    NON_GNU_CPP="cc -systype bsd43 -E"
2806  ;;
2807  mips-mips-bsd* )
2808    machine=mips opsys=bsd4-3
2809  ;;
2810  mips-mips-* )
2811    machine=mips opsys=usg5-2-2
2812  ;;
2813
2814  ## NeXT
2815  m68*-next-* | m68k-*-nextstep* )
2816    machine=m68k opsys=nextstep
2817  ;;
2818
2819  ## The complete machine from National Semiconductor
2820  ns32k-ns-genix* )
2821    machine=ns32000 opsys=usg5-2
2822  ;;
2823
2824  ## NCR machines
2825  m68*-ncr-sysv2* | m68*-ncr-sysvr2* )
2826    machine=tower32 opsys=usg5-2-2
2827  ;;
2828  m68*-ncr-sysv3* | m68*-ncr-sysvr3* )
2829    machine=tower32v3 opsys=usg5-3
2830  ;;
2831
2832  ## NEC EWS4800
2833  mips-nec-sysv4*)
2834  machine=ews4800 opsys=ux4800
2835  ;;
2836
2837  ## Nixdorf Targon 31
2838  m68*-nixdorf-sysv* )
2839    machine=targon31 opsys=usg5-2-2
2840  ;;
2841
2842  ## Nu (TI or LMI)
2843  m68*-nu-sysv* )
2844    machine=nu opsys=usg5-2
2845  ;;
2846
2847  ## Plexus
2848  m68*-plexus-sysv* )
2849    machine=plexus opsys=usg5-2
2850  ;;
2851
2852  ## Pyramid machines
2853  ## I don't really have any idea what sort of processor the Pyramid has,
2854  ## so I'm assuming it is its own architecture.
2855  pyramid-pyramid-bsd* )
2856    machine=pyramid opsys=bsd4-2
2857  ;;
2858
2859  ## Sequent Balance
2860  ns32k-sequent-bsd4.2* )
2861    machine=sequent opsys=bsd4-2
2862  ;;
2863  ns32k-sequent-bsd4.3* )
2864    machine=sequent opsys=bsd4-3
2865  ;;
2866
2867  ## Siemens Nixdorf
2868  mips-siemens-sysv* | mips-sni-sysv*)
2869    machine=mips-siemens opsys=usg5-4
2870    NON_GNU_CC=/usr/ccs/bin/cc
2871    NON_GNU_CPP=/usr/ccs/lib/cpp
2872  ;;
2873
2874  ## Silicon Graphics machines
2875  ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030)
2876  m68*-sgi-iris3.5* )
2877    machine=irist opsys=iris3-5
2878  ;;
2879  m68*-sgi-iris3.6* | m68*-sgi-iris*)
2880    machine=irist opsys=iris3-6
2881  ;;
2882  ## Iris 4D
2883  mips-sgi-irix3* )
2884    machine=iris4d opsys=irix3-3
2885  ;;
2886  mips-sgi-irix4* )
2887    machine=iris4d opsys=irix4-0
2888  ;;
2889  mips-sgi-irix6.5 )
2890    machine=iris4d opsys=irix6-5
2891    # Without defining _LANGUAGE_C, things get masked out in the headers
2892    # so that, for instance, grepping for `free' in stdlib.h fails and
2893    # AC_HEADER_STD_C fails.   (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
2894    NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
2895    NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
2896  ;;
2897  mips-sgi-irix6* )
2898    machine=iris4d opsys=irix6-0
2899    # It's not clear whether -D_LANGUAGE_C is necessary as it is for 6.5,
2900    # but presumably it does no harm.
2901    NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
2902    # -32 probably isn't necessary in later v.6s -- anyone know which?
2903    NON_GCC_TEST_OPTIONS=-32
2904  ;;
2905  mips-sgi-irix5.[01]* )
2906    machine=iris4d opsys=irix5-0
2907  ;;
2908  mips-sgi-irix5* | mips-sgi-irix* )
2909    machine=iris4d opsys=irix5-2
2910  ;;
2911
2912  ## SONY machines
2913  m68*-sony-bsd4.2* )
2914    machine=news opsys=bsd4-2
2915  ;;
2916  m68*-sony-bsd4.3* )
2917    machine=news opsys=bsd4-3
2918  ;;
2919  m68*-sony-newsos3* | m68*-sony-news3*)
2920    machine=news opsys=bsd4-3
2921  ;;
2922  mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*)
2923    machine=news-risc opsys=bsd4-3
2924  ;;
2925  mips-sony-newsos6* )
2926    machine=news-r6 opsys=newsos6
2927  ;;
2928  mips-sony-news* )
2929    machine=news-risc opsys=newsos5
2930  ;;
2931
2932  ## Stride
2933  m68*-stride-sysv* )
2934    machine=stride opsys=usg5-2
2935  ;;
2936
2937  ## Suns
2938  sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
2939    machine=sparc opsys=gnu-linux
2940  ;;
2941
2942  *-auspex-sunos* | *-sun-sunos* | *-sun-bsd* | *-sun-solaris* \
2943    | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* | powerpc*-*-solaris2* \
2944    | rs6000-*-solaris2*)
2945    case "${canonical}" in
2946      m68*-sunos1* )	machine=sun1 ;;
2947      m68*-sunos2* )	machine=sun2 ;;
2948      m68* )		machine=sun3 ;;
2949      i[3456]86-sun-sunos[34]* )	machine=sun386 ;;
2950      i[3456]86-*-* )     machine=intel386 ;;
2951      amd64-*-*|x86_64-*-*)	machine=amdx86-64 ;;
2952      powerpcle* )      machine=powerpcle ;;
2953      powerpc* | rs6000* )  machine=ibmrs6000 ;;
2954      sparc* )		machine=sparc ;;
2955      * )		unported=yes ;;
2956    esac
2957    case "${canonical}" in
2958      ## The Sun386 didn't get past 4.0.
2959      i[3456]86-*-sunos4	  ) opsys=sunos4-0 ;;
2960      *-sunos4.0*	  ) opsys=sunos4-0 ;;
2961      *-sunos4.1.[3-9]*noshare )
2962		## This name is sunos413 instead of sunos4-1-3
2963		## to avoid a file name conflict on MSDOS.
2964		opsys=sunos413
2965		NON_GNU_CPP=/usr/lib/cpp
2966		NON_GCC_TEST_OPTIONS=-Bstatic
2967		GCC_TEST_OPTIONS=-static
2968		;;
2969      *-sunos4.1.[3-9]* | *-sunos4shr*)
2970		opsys=sunos4shr
2971		NON_GNU_CPP=/usr/lib/cpp
2972		;;
2973      *-sunos4* | *-sunos )
2974		opsys=sunos4-1
2975		NON_GCC_TEST_OPTIONS=-Bstatic
2976		GCC_TEST_OPTIONS=-static
2977		;;
2978      *-sunos5.3* | *-solaris2.3* )
2979		opsys=sol2-3
2980		NON_GNU_CPP=/usr/ccs/lib/cpp
2981		;;
2982      *-sunos5.4* | *-solaris2.4* )
2983		opsys=sol2-4
2984		NON_GNU_CPP=/usr/ccs/lib/cpp
2985		RANLIB="ar -ts"
2986		;;
2987      *-sunos5.5* | *-solaris2.5* )
2988		opsys=sol2-5
2989		NON_GNU_CPP=/usr/ccs/lib/cpp
2990		RANLIB="ar -ts"
2991		;;
2992      *-sunos5.6* | *-solaris2.6* )
2993		opsys=sol2-6
2994		NON_GNU_CPP=/usr/ccs/lib/cpp
2995		RANLIB="ar -ts"
2996		;;
2997      *-sunos5* | *-solaris* )
2998		opsys=sol2-6
2999## FIXME: make this into a proper fix that checks the compiler type,
3000## rather than relying on path. Or is /usr/ccs/lib/cpp a bad default now?
3001		if [ "x$CC" = x/opt/SUNWspro/bin/cc ]; then
3002		  ## -Xs prevents spurious whitespace.
3003		  NON_GNU_CPP="/opt/SUNWspro/bin/cc -E -Xs"
3004		else
3005		  NON_GNU_CPP=/usr/ccs/lib/cpp
3006		fi
3007		;;
3008      *			  ) opsys=bsd4-2   ;;
3009    esac
3010    ## Watch out for a compiler that we know will not work.
3011    case "${canonical}" in
3012     *-solaris* | *-sunos5* )
3013		if [ "x$CC" = x/usr/ucb/cc ]; then
3014		  ## /usr/ucb/cc doesn't work;
3015		  ## we should find some other compiler that does work.
3016		  unset CC
3017		fi
3018		;;
3019      *) ;;
3020    esac
3021  ;;
3022  sparc-*-nextstep* )
3023    machine=sparc opsys=nextstep
3024  ;;
3025
3026  ## Tadpole 68k
3027  m68*-tadpole-sysv* )
3028    machine=tad68k opsys=usg5-3
3029  ;;
3030
3031  ## Tahoe machines
3032  tahoe-tahoe-bsd4.2* )
3033    machine=tahoe opsys=bsd4-2
3034  ;;
3035  tahoe-tahoe-bsd4.3* )
3036    machine=tahoe opsys=bsd4-3
3037  ;;
3038
3039  ## Tandem Integrity S2
3040  mips-tandem-sysv* )
3041    machine=tandem-s2 opsys=usg5-3
3042  ;;
3043
3044  ## Tektronix XD88
3045  m88k-tektronix-sysv3* )
3046  machine=tekxd88 opsys=usg5-3
3047  ;;
3048
3049  ## Tektronix 16000 box (6130?)
3050  ns16k-tektronix-bsd* )
3051    machine=ns16000 opsys=bsd4-2
3052  ;;
3053  ## Tektronix 4300
3054  ## src/m/tek4300.h hints that this is a m68k machine.
3055  m68*-tektronix-bsd* )
3056    machine=tek4300 opsys=bsd4-3
3057  ;;
3058
3059  ## Titan P2 or P3
3060  ## We seem to have lost the machine-description file titan.h!
3061  titan-titan-sysv* )
3062    machine=titan opsys=usg5-3
3063  ;;
3064
3065  ## Ustation E30 (SS5E)
3066  m68*-unisys-uniplus* )
3067    machine=ustation opsystem=unipl5-2
3068  ;;
3069
3070  ## Vaxen.
3071  vax-dec-* )
3072    machine=vax
3073    case "${canonical}" in
3074      *-bsd4.1* ) 					opsys=bsd4-1 ;;
3075      *-bsd4.2* | *-ultrix[0-3].* | *-ultrix4.0* )	opsys=bsd4-2 ;;
3076      *-bsd4.3* | *-ultrix* ) 				opsys=bsd4-3 ;;
3077      *-sysv[01]* | *-sysvr[01]* ) 			opsys=usg5-0 ;;
3078      *-sysv2* | *-sysvr2* )				opsys=usg5-2 ;;
3079      *-vms* ) 						opsys=vms ;;
3080      * ) 						unported=yes
3081    esac
3082  ;;
3083
3084  ## Whitechapel MG1
3085  ns16k-whitechapel-* )
3086    machine=mg1
3087    ## We don't know what sort of OS runs on these; we'll let the
3088    ## operating system guessing code below try.
3089  ;;
3090
3091  ## Wicat
3092  m68*-wicat-sysv* )
3093    machine=wicat opsys=usg5-2
3094  ;;
3095
3096  ## IA-64
3097  ia64*-*-linux* )
3098    machine=ia64 opsys=gnu-linux
3099  ;;
3100
3101  ## Intel 386 machines where we don't care about the manufacturer
3102  i[3456]86-*-* )
3103    machine=intel386
3104    case "${canonical}" in
3105      *-cygwin )                opsys=cygwin ;;
3106      *-darwin* )               opsys=darwin
3107	                        machine=mac #For univeral building
3108                                CPP="${CC-cc} -E -no-cpp-precomp"
3109 				;;
3110      *-isc1.* | *-isc2.[01]* )	opsys=386-ix ;;
3111      *-isc2.2* )		opsys=isc2-2 ;;
3112      *-isc4.0* )		opsys=isc4-0 ;;
3113      *-isc4.* )		opsys=isc4-1
3114				GCC_TEST_OPTIONS=-posix
3115				NON_GCC_TEST_OPTIONS=-Xp
3116				;;
3117      *-isc* )			opsys=isc3-0 ;;
3118      *-esix5* )		opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;;
3119      *-esix* )			opsys=esix ;;
3120      *-xenix* )		opsys=xenix ;;
3121      *-linux-gnu* )		opsys=gnu-linux ;;
3122      *-sco3.2v4* )		opsys=sco4 ; NON_GNU_CPP=/lib/cpp  ;;
3123      *-sco3.2v5* )		opsys=sco5
3124				NON_GNU_CPP=/lib/cpp
3125				# Prevent -belf from being passed to $CPP.
3126				# /lib/cpp does not accept it.
3127				OVERRIDE_CPPFLAGS=" "
3128				;;
3129      *-sysv4.2uw* )	  	opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
3130      *-sysv5uw* )	  	opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
3131      *-sysv5OpenUNIX* )  	opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
3132      *-386bsd* )	        opsys=386bsd ;;
3133      *-nextstep* )             opsys=nextstep ;;
3134      ## Otherwise, we'll fall through to the generic opsys code at the bottom.
3135    esac
3136  ;;
3137
3138  ## m68k Linux-based GNU system
3139  m68k-*-linux-gnu* )
3140    machine=m68k opsys=gnu-linux
3141  ;;
3142
3143  ## Mips Linux-based GNU system
3144  mips-*-linux-gnu* | mipsel-*-linux-gnu* )
3145    machine=mips opsys=gnu-linux
3146  ;;
3147
3148  ## UXP/DS
3149  sparc-fujitsu-sysv4* )
3150    machine=sparc opsys=uxpds
3151    NON_GNU_CPP=/usr/ccs/lib/cpp
3152    RANLIB="ar -ts"
3153  ;;
3154
3155  ## UXP/V
3156  f301-fujitsu-uxpv4.1)
3157    machine=f301 opsys=uxpv
3158  ;;
3159
3160  ## AMD x86-64 Linux-based GNU system
3161  x86_64-*-linux-gnu* )
3162    machine=amdx86-64 opsys=gnu-linux
3163  ;;
3164
3165  ## Tensilica Xtensa Linux-based GNU system
3166  xtensa-*-linux-gnu* )
3167    machine=xtensa opsys=gnu-linux
3168    ;;
3169
3170  * )
3171    unported=yes
3172  ;;
3173esac
3174
3175### If the code above didn't choose an operating system, just choose
3176### an operating system based on the configuration name.  You really
3177### only want to use this when you have no idea what the right
3178### operating system is; if you know what operating systems a machine
3179### runs, it's cleaner to make it explicit in the case statement
3180### above.
3181if test x"${opsys}" = x; then
3182  case "${canonical}" in
3183    *-gnu* )				opsys=gnu ;;
3184    *-bsd4.[01] )			opsys=bsd4-1 ;;
3185    *-bsd4.2 )				opsys=bsd4-2 ;;
3186    *-bsd4.3 )				opsys=bsd4-3 ;;
3187    *-sysv0 | *-sysvr0 )		opsys=usg5-0 ;;
3188    *-sysv2 | *-sysvr2 )		opsys=usg5-2 ;;
3189    *-sysv2.2 | *-sysvr2.2 )		opsys=usg5-2-2 ;;
3190    *-sysv3* | *-sysvr3* )		opsys=usg5-3 ;;
3191    *-sysv4.2uw* )			opsys=unixware ;;
3192    *-sysv5uw* )			opsys=unixware ;;
3193    *-sysv5OpenUNIX* )			opsys=unixware ;;
3194    *-sysv4.1* | *-sysvr4.1* )
3195	NON_GNU_CPP=/usr/lib/cpp
3196	opsys=usg5-4 ;;
3197    *-sysv4.[2-9]* | *-sysvr4.[2-9]* )
3198	if [ x$NON_GNU_CPP = x ]; then
3199	  if [ -f /usr/ccs/lib/cpp ]; then
3200	    NON_GNU_CPP=/usr/ccs/lib/cpp
3201	  else
3202	    NON_GNU_CPP=/lib/cpp
3203	  fi
3204	fi
3205	opsys=usg5-4-2 ;;
3206    *-sysv4* | *-sysvr4* )		opsys=usg5-4 ;;
3207    * )
3208      unported=yes
3209    ;;
3210  esac
3211fi
3212
3213
3214
3215if test $unported = yes; then
3216  { { echo "$as_me:$LINENO: error: Emacs hasn't been ported to \`${canonical}' systems.
3217Check \`etc/MACHINES' for recognized configuration names." >&5
3218echo "$as_me: error: Emacs hasn't been ported to \`${canonical}' systems.
3219Check \`etc/MACHINES' for recognized configuration names." >&2;}
3220   { (exit 1); exit 1; }; }
3221fi
3222
3223machfile="m/${machine}.h"
3224opsysfile="s/${opsys}.h"
3225
3226
3227#### Choose a compiler.
3228test -n "$CC" && cc_specified=yes
3229
3230# Save the value of CFLAGS that the user specified.
3231SPECIFIED_CFLAGS="$CFLAGS"
3232
3233case ${with_gcc} in
3234  "yes" ) CC="gcc" GCC=yes ;;
3235  "no"  ) : ${CC=cc} ;;
3236  * )
3237esac
3238ac_ext=c
3239ac_cpp='$CPP $CPPFLAGS'
3240ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3241ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3242ac_compiler_gnu=$ac_cv_c_compiler_gnu
3243if test -n "$ac_tool_prefix"; then
3244  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3245set dummy ${ac_tool_prefix}gcc; ac_word=$2
3246{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3247echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
3248if test "${ac_cv_prog_CC+set}" = set; then
3249  echo $ECHO_N "(cached) $ECHO_C" >&6
3250else
3251  if test -n "$CC"; then
3252  ac_cv_prog_CC="$CC" # Let the user override the test.
3253else
3254as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3255for as_dir in $PATH
3256do
3257  IFS=$as_save_IFS
3258  test -z "$as_dir" && as_dir=.
3259  for ac_exec_ext in '' $ac_executable_extensions; do
3260  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3261    ac_cv_prog_CC="${ac_tool_prefix}gcc"
3262    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3263    break 2
3264  fi
3265done
3266done
3267IFS=$as_save_IFS
3268
3269fi
3270fi
3271CC=$ac_cv_prog_CC
3272if test -n "$CC"; then
3273  { echo "$as_me:$LINENO: result: $CC" >&5
3274echo "${ECHO_T}$CC" >&6; }
3275else
3276  { echo "$as_me:$LINENO: result: no" >&5
3277echo "${ECHO_T}no" >&6; }
3278fi
3279
3280
3281fi
3282if test -z "$ac_cv_prog_CC"; then
3283  ac_ct_CC=$CC
3284  # Extract the first word of "gcc", so it can be a program name with args.
3285set dummy gcc; ac_word=$2
3286{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3287echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
3288if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3289  echo $ECHO_N "(cached) $ECHO_C" >&6
3290else
3291  if test -n "$ac_ct_CC"; then
3292  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3293else
3294as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3295for as_dir in $PATH
3296do
3297  IFS=$as_save_IFS
3298  test -z "$as_dir" && as_dir=.
3299  for ac_exec_ext in '' $ac_executable_extensions; do
3300  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3301    ac_cv_prog_ac_ct_CC="gcc"
3302    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3303    break 2
3304  fi
3305done
3306done
3307IFS=$as_save_IFS
3308
3309fi
3310fi
3311ac_ct_CC=$ac_cv_prog_ac_ct_CC
3312if test -n "$ac_ct_CC"; then
3313  { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3314echo "${ECHO_T}$ac_ct_CC" >&6; }
3315else
3316  { echo "$as_me:$LINENO: result: no" >&5
3317echo "${ECHO_T}no" >&6; }
3318fi
3319
3320  if test "x$ac_ct_CC" = x; then
3321    CC=""
3322  else
3323    case $cross_compiling:$ac_tool_warned in
3324yes:)
3325{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
3326whose name does not start with the host triplet.  If you think this
3327configuration is useful to you, please write to autoconf@gnu.org." >&5
3328echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
3329whose name does not start with the host triplet.  If you think this
3330configuration is useful to you, please write to autoconf@gnu.org." >&2;}
3331ac_tool_warned=yes ;;
3332esac
3333    CC=$ac_ct_CC
3334  fi
3335else
3336  CC="$ac_cv_prog_CC"
3337fi
3338
3339if test -z "$CC"; then
3340          if test -n "$ac_tool_prefix"; then
3341    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3342set dummy ${ac_tool_prefix}cc; ac_word=$2
3343{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3344echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
3345if test "${ac_cv_prog_CC+set}" = set; then
3346  echo $ECHO_N "(cached) $ECHO_C" >&6
3347else
3348  if test -n "$CC"; then
3349  ac_cv_prog_CC="$CC" # Let the user override the test.
3350else
3351as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3352for as_dir in $PATH
3353do
3354  IFS=$as_save_IFS
3355  test -z "$as_dir" && as_dir=.
3356  for ac_exec_ext in '' $ac_executable_extensions; do
3357  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3358    ac_cv_prog_CC="${ac_tool_prefix}cc"
3359    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3360    break 2
3361  fi
3362done
3363done
3364IFS=$as_save_IFS
3365
3366fi
3367fi
3368CC=$ac_cv_prog_CC
3369if test -n "$CC"; then
3370  { echo "$as_me:$LINENO: result: $CC" >&5
3371echo "${ECHO_T}$CC" >&6; }
3372else
3373  { echo "$as_me:$LINENO: result: no" >&5
3374echo "${ECHO_T}no" >&6; }
3375fi
3376
3377
3378  fi
3379fi
3380if test -z "$CC"; then
3381  # Extract the first word of "cc", so it can be a program name with args.
3382set dummy cc; ac_word=$2
3383{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3384echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
3385if test "${ac_cv_prog_CC+set}" = set; then
3386  echo $ECHO_N "(cached) $ECHO_C" >&6
3387else
3388  if test -n "$CC"; then
3389  ac_cv_prog_CC="$CC" # Let the user override the test.
3390else
3391  ac_prog_rejected=no
3392as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3393for as_dir in $PATH
3394do
3395  IFS=$as_save_IFS
3396  test -z "$as_dir" && as_dir=.
3397  for ac_exec_ext in '' $ac_executable_extensions; do
3398  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3399    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3400       ac_prog_rejected=yes
3401       continue
3402     fi
3403    ac_cv_prog_CC="cc"
3404    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3405    break 2
3406  fi
3407done
3408done
3409IFS=$as_save_IFS
3410
3411if test $ac_prog_rejected = yes; then
3412  # We found a bogon in the path, so make sure we never use it.
3413  set dummy $ac_cv_prog_CC
3414  shift
3415  if test $# != 0; then
3416    # We chose a different compiler from the bogus one.
3417    # However, it has the same basename, so the bogon will be chosen
3418    # first if we set CC to just the basename; use the full file name.
3419    shift
3420    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3421  fi
3422fi
3423fi
3424fi
3425CC=$ac_cv_prog_CC
3426if test -n "$CC"; then
3427  { echo "$as_me:$LINENO: result: $CC" >&5
3428echo "${ECHO_T}$CC" >&6; }
3429else
3430  { echo "$as_me:$LINENO: result: no" >&5
3431echo "${ECHO_T}no" >&6; }
3432fi
3433
3434
3435fi
3436if test -z "$CC"; then
3437  if test -n "$ac_tool_prefix"; then
3438  for ac_prog in cl.exe
3439  do
3440    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3441set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3442{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3443echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
3444if test "${ac_cv_prog_CC+set}" = set; then
3445  echo $ECHO_N "(cached) $ECHO_C" >&6
3446else
3447  if test -n "$CC"; then
3448  ac_cv_prog_CC="$CC" # Let the user override the test.
3449else
3450as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3451for as_dir in $PATH
3452do
3453  IFS=$as_save_IFS
3454  test -z "$as_dir" && as_dir=.
3455  for ac_exec_ext in '' $ac_executable_extensions; do
3456  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3457    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3458    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3459    break 2
3460  fi
3461done
3462done
3463IFS=$as_save_IFS
3464
3465fi
3466fi
3467CC=$ac_cv_prog_CC
3468if test -n "$CC"; then
3469  { echo "$as_me:$LINENO: result: $CC" >&5
3470echo "${ECHO_T}$CC" >&6; }
3471else
3472  { echo "$as_me:$LINENO: result: no" >&5
3473echo "${ECHO_T}no" >&6; }
3474fi
3475
3476
3477    test -n "$CC" && break
3478  done
3479fi
3480if test -z "$CC"; then
3481  ac_ct_CC=$CC
3482  for ac_prog in cl.exe
3483do
3484  # Extract the first word of "$ac_prog", so it can be a program name with args.
3485set dummy $ac_prog; ac_word=$2
3486{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3487echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
3488if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3489  echo $ECHO_N "(cached) $ECHO_C" >&6
3490else
3491  if test -n "$ac_ct_CC"; then
3492  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3493else
3494as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3495for as_dir in $PATH
3496do
3497  IFS=$as_save_IFS
3498  test -z "$as_dir" && as_dir=.
3499  for ac_exec_ext in '' $ac_executable_extensions; do
3500  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3501    ac_cv_prog_ac_ct_CC="$ac_prog"
3502    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3503    break 2
3504  fi
3505done
3506done
3507IFS=$as_save_IFS
3508
3509fi
3510fi
3511ac_ct_CC=$ac_cv_prog_ac_ct_CC
3512if test -n "$ac_ct_CC"; then
3513  { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3514echo "${ECHO_T}$ac_ct_CC" >&6; }
3515else
3516  { echo "$as_me:$LINENO: result: no" >&5
3517echo "${ECHO_T}no" >&6; }
3518fi
3519
3520
3521  test -n "$ac_ct_CC" && break
3522done
3523
3524  if test "x$ac_ct_CC" = x; then
3525    CC=""
3526  else
3527    case $cross_compiling:$ac_tool_warned in
3528yes:)
3529{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
3530whose name does not start with the host triplet.  If you think this
3531configuration is useful to you, please write to autoconf@gnu.org." >&5
3532echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
3533whose name does not start with the host triplet.  If you think this
3534configuration is useful to you, please write to autoconf@gnu.org." >&2;}
3535ac_tool_warned=yes ;;
3536esac
3537    CC=$ac_ct_CC
3538  fi
3539fi
3540
3541fi
3542
3543
3544test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
3545See \`config.log' for more details." >&5
3546echo "$as_me: error: no acceptable C compiler found in \$PATH
3547See \`config.log' for more details." >&2;}
3548   { (exit 1); exit 1; }; }
3549
3550# Provide some information about the compiler.
3551echo "$as_me:$LINENO: checking for C compiler version" >&5
3552ac_compiler=`set X $ac_compile; echo $2`
3553{ (ac_try="$ac_compiler --version >&5"
3554case "(($ac_try" in
3555  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3556  *) ac_try_echo=$ac_try;;
3557esac
3558eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3559  (eval "$ac_compiler --version >&5") 2>&5
3560  ac_status=$?
3561  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3562  (exit $ac_status); }
3563{ (ac_try="$ac_compiler -v >&5"
3564case "(($ac_try" in
3565  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3566  *) ac_try_echo=$ac_try;;
3567esac
3568eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3569  (eval "$ac_compiler -v >&5") 2>&5
3570  ac_status=$?
3571  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3572  (exit $ac_status); }
3573{ (ac_try="$ac_compiler -V >&5"
3574case "(($ac_try" in
3575  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3576  *) ac_try_echo=$ac_try;;
3577esac
3578eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3579  (eval "$ac_compiler -V >&5") 2>&5
3580  ac_status=$?
3581  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3582  (exit $ac_status); }
3583
3584cat >conftest.$ac_ext <<_ACEOF
3585/* confdefs.h.  */
3586_ACEOF
3587cat confdefs.h >>conftest.$ac_ext
3588cat >>conftest.$ac_ext <<_ACEOF
3589/* end confdefs.h.  */
3590
3591int
3592main ()
3593{
3594
3595  ;
3596  return 0;
3597}
3598_ACEOF
3599ac_clean_files_save=$ac_clean_files
3600ac_clean_files="$ac_clean_files a.out a.exe b.out"
3601# Try to create an executable without -o first, disregard a.out.
3602# It will help us diagnose broken compilers, and finding out an intuition
3603# of exeext.
3604{ echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3605echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; }
3606ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3607#
3608# List of possible output files, starting from the most likely.
3609# The algorithm is not robust to junk in `.', hence go to wildcards (a.*)
3610# only as a last resort.  b.out is created by i960 compilers.
3611ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out'
3612#
3613# The IRIX 6 linker writes into existing files which may not be
3614# executable, retaining their permissions.  Remove them first so a
3615# subsequent execution test works.
3616ac_rmfiles=
3617for ac_file in $ac_files
3618do
3619  case $ac_file in
3620    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
3621    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3622  esac
3623done
3624rm -f $ac_rmfiles
3625
3626if { (ac_try="$ac_link_default"
3627case "(($ac_try" in
3628  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3629  *) ac_try_echo=$ac_try;;
3630esac
3631eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3632  (eval "$ac_link_default") 2>&5
3633  ac_status=$?
3634  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3635  (exit $ac_status); }; then
3636  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3637# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3638# in a Makefile.  We should not override ac_cv_exeext if it was cached,
3639# so that the user can short-circuit this test for compilers unknown to
3640# Autoconf.
3641for ac_file in $ac_files ''
3642do
3643  test -f "$ac_file" || continue
3644  case $ac_file in
3645    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
3646	;;
3647    [ab].out )
3648	# We found the default executable, but exeext='' is most
3649	# certainly right.
3650	break;;
3651    *.* )
3652        if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3653	then :; else
3654	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3655	fi
3656	# We set ac_cv_exeext here because the later test for it is not
3657	# safe: cross compilers may not add the suffix if given an `-o'
3658	# argument, so we may need to know it at that point already.
3659	# Even if this section looks crufty: it has the advantage of
3660	# actually working.
3661	break;;
3662    * )
3663	break;;
3664  esac
3665done
3666test "$ac_cv_exeext" = no && ac_cv_exeext=
3667
3668else
3669  ac_file=''
3670fi
3671
3672{ echo "$as_me:$LINENO: result: $ac_file" >&5
3673echo "${ECHO_T}$ac_file" >&6; }
3674if test -z "$ac_file"; then
3675  echo "$as_me: failed program was:" >&5
3676sed 's/^/| /' conftest.$ac_ext >&5
3677
3678{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
3679See \`config.log' for more details." >&5
3680echo "$as_me: error: C compiler cannot create executables
3681See \`config.log' for more details." >&2;}
3682   { (exit 77); exit 77; }; }
3683fi
3684
3685ac_exeext=$ac_cv_exeext
3686
3687# Check that the compiler produces executables we can run.  If not, either
3688# the compiler is broken, or we cross compile.
3689{ echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3690echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; }
3691# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3692# If not cross compiling, check that we can run a simple program.
3693if test "$cross_compiling" != yes; then
3694  if { ac_try='./$ac_file'
3695  { (case "(($ac_try" in
3696  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3697  *) ac_try_echo=$ac_try;;
3698esac
3699eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3700  (eval "$ac_try") 2>&5
3701  ac_status=$?
3702  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3703  (exit $ac_status); }; }; then
3704    cross_compiling=no
3705  else
3706    if test "$cross_compiling" = maybe; then
3707	cross_compiling=yes
3708    else
3709	{ { echo "$as_me:$LINENO: error: cannot run C compiled programs.
3710If you meant to cross compile, use \`--host'.
3711See \`config.log' for more details." >&5
3712echo "$as_me: error: cannot run C compiled programs.
3713If you meant to cross compile, use \`--host'.
3714See \`config.log' for more details." >&2;}
3715   { (exit 1); exit 1; }; }
3716    fi
3717  fi
3718fi
3719{ echo "$as_me:$LINENO: result: yes" >&5
3720echo "${ECHO_T}yes" >&6; }
3721
3722rm -f a.out a.exe conftest$ac_cv_exeext b.out
3723ac_clean_files=$ac_clean_files_save
3724# Check that the compiler produces executables we can run.  If not, either
3725# the compiler is broken, or we cross compile.
3726{ echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3727echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; }
3728{ echo "$as_me:$LINENO: result: $cross_compiling" >&5
3729echo "${ECHO_T}$cross_compiling" >&6; }
3730
3731{ echo "$as_me:$LINENO: checking for suffix of executables" >&5
3732echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; }
3733if { (ac_try="$ac_link"
3734case "(($ac_try" in
3735  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3736  *) ac_try_echo=$ac_try;;
3737esac
3738eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3739  (eval "$ac_link") 2>&5
3740  ac_status=$?
3741  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3742  (exit $ac_status); }; then
3743  # If both `conftest.exe' and `conftest' are `present' (well, observable)
3744# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3745# work properly (i.e., refer to `conftest.exe'), while it won't with
3746# `rm'.
3747for ac_file in conftest.exe conftest conftest.*; do
3748  test -f "$ac_file" || continue
3749  case $ac_file in
3750    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
3751    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3752	  break;;
3753    * ) break;;
3754  esac
3755done
3756else
3757  { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3758See \`config.log' for more details." >&5
3759echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3760See \`config.log' for more details." >&2;}
3761   { (exit 1); exit 1; }; }
3762fi
3763
3764rm -f conftest$ac_cv_exeext
3765{ echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3766echo "${ECHO_T}$ac_cv_exeext" >&6; }
3767
3768rm -f conftest.$ac_ext
3769EXEEXT=$ac_cv_exeext
3770ac_exeext=$EXEEXT
3771{ echo "$as_me:$LINENO: checking for suffix of object files" >&5
3772echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
3773if test "${ac_cv_objext+set}" = set; then
3774  echo $ECHO_N "(cached) $ECHO_C" >&6
3775else
3776  cat >conftest.$ac_ext <<_ACEOF
3777/* confdefs.h.  */
3778_ACEOF
3779cat confdefs.h >>conftest.$ac_ext
3780cat >>conftest.$ac_ext <<_ACEOF
3781/* end confdefs.h.  */
3782
3783int
3784main ()
3785{
3786
3787  ;
3788  return 0;
3789}
3790_ACEOF
3791rm -f conftest.o conftest.obj
3792if { (ac_try="$ac_compile"
3793case "(($ac_try" in
3794  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3795  *) ac_try_echo=$ac_try;;
3796esac
3797eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3798  (eval "$ac_compile") 2>&5
3799  ac_status=$?
3800  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3801  (exit $ac_status); }; then
3802  for ac_file in conftest.o conftest.obj conftest.*; do
3803  test -f "$ac_file" || continue;
3804  case $ac_file in
3805    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
3806    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3807       break;;
3808  esac
3809done
3810else
3811  echo "$as_me: failed program was:" >&5
3812sed 's/^/| /' conftest.$ac_ext >&5
3813
3814{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3815See \`config.log' for more details." >&5
3816echo "$as_me: error: cannot compute suffix of object files: cannot compile
3817See \`config.log' for more details." >&2;}
3818   { (exit 1); exit 1; }; }
3819fi
3820
3821rm -f conftest.$ac_cv_objext conftest.$ac_ext
3822fi
3823{ echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3824echo "${ECHO_T}$ac_cv_objext" >&6; }
3825OBJEXT=$ac_cv_objext
3826ac_objext=$OBJEXT
3827{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3828echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
3829if test "${ac_cv_c_compiler_gnu+set}" = set; then
3830  echo $ECHO_N "(cached) $ECHO_C" >&6
3831else
3832  cat >conftest.$ac_ext <<_ACEOF
3833/* confdefs.h.  */
3834_ACEOF
3835cat confdefs.h >>conftest.$ac_ext
3836cat >>conftest.$ac_ext <<_ACEOF
3837/* end confdefs.h.  */
3838
3839int
3840main ()
3841{
3842#ifndef __GNUC__
3843       choke me
3844#endif
3845
3846  ;
3847  return 0;
3848}
3849_ACEOF
3850rm -f conftest.$ac_objext
3851if { (ac_try="$ac_compile"
3852case "(($ac_try" in
3853  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3854  *) ac_try_echo=$ac_try;;
3855esac
3856eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3857  (eval "$ac_compile") 2>conftest.er1
3858  ac_status=$?
3859  grep -v '^ *+' conftest.er1 >conftest.err
3860  rm -f conftest.er1
3861  cat conftest.err >&5
3862  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3863  (exit $ac_status); } && {
3864	 test -z "$ac_c_werror_flag" ||
3865	 test ! -s conftest.err
3866       } && test -s conftest.$ac_objext; then
3867  ac_compiler_gnu=yes
3868else
3869  echo "$as_me: failed program was:" >&5
3870sed 's/^/| /' conftest.$ac_ext >&5
3871
3872	ac_compiler_gnu=no
3873fi
3874
3875rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3876ac_cv_c_compiler_gnu=$ac_compiler_gnu
3877
3878fi
3879{ echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3880echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
3881GCC=`test $ac_compiler_gnu = yes && echo yes`
3882ac_test_CFLAGS=${CFLAGS+set}
3883ac_save_CFLAGS=$CFLAGS
3884{ echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3885echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
3886if test "${ac_cv_prog_cc_g+set}" = set; then
3887  echo $ECHO_N "(cached) $ECHO_C" >&6
3888else
3889  ac_save_c_werror_flag=$ac_c_werror_flag
3890   ac_c_werror_flag=yes
3891   ac_cv_prog_cc_g=no
3892   CFLAGS="-g"
3893   cat >conftest.$ac_ext <<_ACEOF
3894/* confdefs.h.  */
3895_ACEOF
3896cat confdefs.h >>conftest.$ac_ext
3897cat >>conftest.$ac_ext <<_ACEOF
3898/* end confdefs.h.  */
3899
3900int
3901main ()
3902{
3903
3904  ;
3905  return 0;
3906}
3907_ACEOF
3908rm -f conftest.$ac_objext
3909if { (ac_try="$ac_compile"
3910case "(($ac_try" in
3911  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3912  *) ac_try_echo=$ac_try;;
3913esac
3914eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3915  (eval "$ac_compile") 2>conftest.er1
3916  ac_status=$?
3917  grep -v '^ *+' conftest.er1 >conftest.err
3918  rm -f conftest.er1
3919  cat conftest.err >&5
3920  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3921  (exit $ac_status); } && {
3922	 test -z "$ac_c_werror_flag" ||
3923	 test ! -s conftest.err
3924       } && test -s conftest.$ac_objext; then
3925  ac_cv_prog_cc_g=yes
3926else
3927  echo "$as_me: failed program was:" >&5
3928sed 's/^/| /' conftest.$ac_ext >&5
3929
3930	CFLAGS=""
3931      cat >conftest.$ac_ext <<_ACEOF
3932/* confdefs.h.  */
3933_ACEOF
3934cat confdefs.h >>conftest.$ac_ext
3935cat >>conftest.$ac_ext <<_ACEOF
3936/* end confdefs.h.  */
3937
3938int
3939main ()
3940{
3941
3942  ;
3943  return 0;
3944}
3945_ACEOF
3946rm -f conftest.$ac_objext
3947if { (ac_try="$ac_compile"
3948case "(($ac_try" in
3949  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3950  *) ac_try_echo=$ac_try;;
3951esac
3952eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3953  (eval "$ac_compile") 2>conftest.er1
3954  ac_status=$?
3955  grep -v '^ *+' conftest.er1 >conftest.err
3956  rm -f conftest.er1
3957  cat conftest.err >&5
3958  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3959  (exit $ac_status); } && {
3960	 test -z "$ac_c_werror_flag" ||
3961	 test ! -s conftest.err
3962       } && test -s conftest.$ac_objext; then
3963  :
3964else
3965  echo "$as_me: failed program was:" >&5
3966sed 's/^/| /' conftest.$ac_ext >&5
3967
3968	ac_c_werror_flag=$ac_save_c_werror_flag
3969	 CFLAGS="-g"
3970	 cat >conftest.$ac_ext <<_ACEOF
3971/* confdefs.h.  */
3972_ACEOF
3973cat confdefs.h >>conftest.$ac_ext
3974cat >>conftest.$ac_ext <<_ACEOF
3975/* end confdefs.h.  */
3976
3977int
3978main ()
3979{
3980
3981  ;
3982  return 0;
3983}
3984_ACEOF
3985rm -f conftest.$ac_objext
3986if { (ac_try="$ac_compile"
3987case "(($ac_try" in
3988  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3989  *) ac_try_echo=$ac_try;;
3990esac
3991eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3992  (eval "$ac_compile") 2>conftest.er1
3993  ac_status=$?
3994  grep -v '^ *+' conftest.er1 >conftest.err
3995  rm -f conftest.er1
3996  cat conftest.err >&5
3997  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3998  (exit $ac_status); } && {
3999	 test -z "$ac_c_werror_flag" ||
4000	 test ! -s conftest.err
4001       } && test -s conftest.$ac_objext; then
4002  ac_cv_prog_cc_g=yes
4003else
4004  echo "$as_me: failed program was:" >&5
4005sed 's/^/| /' conftest.$ac_ext >&5
4006
4007
4008fi
4009
4010rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4011fi
4012
4013rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4014fi
4015
4016rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4017   ac_c_werror_flag=$ac_save_c_werror_flag
4018fi
4019{ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
4020echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
4021if test "$ac_test_CFLAGS" = set; then
4022  CFLAGS=$ac_save_CFLAGS
4023elif test $ac_cv_prog_cc_g = yes; then
4024  if test "$GCC" = yes; then
4025    CFLAGS="-g -O2"
4026  else
4027    CFLAGS="-g"
4028  fi
4029else
4030  if test "$GCC" = yes; then
4031    CFLAGS="-O2"
4032  else
4033    CFLAGS=
4034  fi
4035fi
4036{ echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
4037echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
4038if test "${ac_cv_prog_cc_c89+set}" = set; then
4039  echo $ECHO_N "(cached) $ECHO_C" >&6
4040else
4041  ac_cv_prog_cc_c89=no
4042ac_save_CC=$CC
4043cat >conftest.$ac_ext <<_ACEOF
4044/* confdefs.h.  */
4045_ACEOF
4046cat confdefs.h >>conftest.$ac_ext
4047cat >>conftest.$ac_ext <<_ACEOF
4048/* end confdefs.h.  */
4049#include <stdarg.h>
4050#include <stdio.h>
4051#include <sys/types.h>
4052#include <sys/stat.h>
4053/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4054struct buf { int x; };
4055FILE * (*rcsopen) (struct buf *, struct stat *, int);
4056static char *e (p, i)
4057     char **p;
4058     int i;
4059{
4060  return p[i];
4061}
4062static char *f (char * (*g) (char **, int), char **p, ...)
4063{
4064  char *s;
4065  va_list v;
4066  va_start (v,p);
4067  s = g (p, va_arg (v,int));
4068  va_end (v);
4069  return s;
4070}
4071
4072/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4073   function prototypes and stuff, but not '\xHH' hex character constants.
4074   These don't provoke an error unfortunately, instead are silently treated
4075   as 'x'.  The following induces an error, until -std is added to get
4076   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4077   array size at least.  It's necessary to write '\x00'==0 to get something
4078   that's true only with -std.  */
4079int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4080
4081/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4082   inside strings and character constants.  */
4083#define FOO(x) 'x'
4084int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4085
4086int test (int i, double x);
4087struct s1 {int (*f) (int a);};
4088struct s2 {int (*f) (double a);};
4089int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4090int argc;
4091char **argv;
4092int
4093main ()
4094{
4095return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4096  ;
4097  return 0;
4098}
4099_ACEOF
4100for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4101	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4102do
4103  CC="$ac_save_CC $ac_arg"
4104  rm -f conftest.$ac_objext
4105if { (ac_try="$ac_compile"
4106case "(($ac_try" in
4107  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4108  *) ac_try_echo=$ac_try;;
4109esac
4110eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4111  (eval "$ac_compile") 2>conftest.er1
4112  ac_status=$?
4113  grep -v '^ *+' conftest.er1 >conftest.err
4114  rm -f conftest.er1
4115  cat conftest.err >&5
4116  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4117  (exit $ac_status); } && {
4118	 test -z "$ac_c_werror_flag" ||
4119	 test ! -s conftest.err
4120       } && test -s conftest.$ac_objext; then
4121  ac_cv_prog_cc_c89=$ac_arg
4122else
4123  echo "$as_me: failed program was:" >&5
4124sed 's/^/| /' conftest.$ac_ext >&5
4125
4126
4127fi
4128
4129rm -f core conftest.err conftest.$ac_objext
4130  test "x$ac_cv_prog_cc_c89" != "xno" && break
4131done
4132rm -f conftest.$ac_ext
4133CC=$ac_save_CC
4134
4135fi
4136# AC_CACHE_VAL
4137case "x$ac_cv_prog_cc_c89" in
4138  x)
4139    { echo "$as_me:$LINENO: result: none needed" >&5
4140echo "${ECHO_T}none needed" >&6; } ;;
4141  xno)
4142    { echo "$as_me:$LINENO: result: unsupported" >&5
4143echo "${ECHO_T}unsupported" >&6; } ;;
4144  *)
4145    CC="$CC $ac_cv_prog_cc_c89"
4146    { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
4147echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
4148esac
4149
4150
4151ac_ext=c
4152ac_cpp='$CPP $CPPFLAGS'
4153ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4154ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4155ac_compiler_gnu=$ac_cv_c_compiler_gnu
4156
4157
4158# On Suns, sometimes $CPP names a directory.
4159if test -n "$CPP" && test -d "$CPP"; then
4160  CPP=
4161fi
4162
4163#### Some systems specify a CPP to use unless we are using GCC.
4164#### Now that we know whether we are using GCC, we can decide whether
4165#### to use that one.
4166if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
4167then
4168  CPP="$NON_GNU_CPP"
4169fi
4170
4171#### Some systems specify a CC to use unless we are using GCC.
4172#### Now that we know whether we are using GCC, we can decide whether
4173#### to use that one.
4174if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
4175  test x$cc_specified != xyes
4176then
4177  CC="$NON_GNU_CC"
4178fi
4179
4180if test x$GCC = xyes && test "x$GCC_TEST_OPTIONS" != x
4181then
4182  CC="$CC $GCC_TEST_OPTIONS"
4183fi
4184
4185if test x$GCC = x && test "x$NON_GCC_TEST_OPTIONS" != x
4186then
4187  CC="$CC $NON_GCC_TEST_OPTIONS"
4188fi
4189
4190
4191ac_ext=c
4192ac_cpp='$CPP $CPPFLAGS'
4193ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4194ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4195ac_compiler_gnu=$ac_cv_c_compiler_gnu
4196{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4197echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
4198# On Suns, sometimes $CPP names a directory.
4199if test -n "$CPP" && test -d "$CPP"; then
4200  CPP=
4201fi
4202if test -z "$CPP"; then
4203  if test "${ac_cv_prog_CPP+set}" = set; then
4204  echo $ECHO_N "(cached) $ECHO_C" >&6
4205else
4206      # Double quotes because CPP needs to be expanded
4207    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4208    do
4209      ac_preproc_ok=false
4210for ac_c_preproc_warn_flag in '' yes
4211do
4212  # Use a header file that comes with gcc, so configuring glibc
4213  # with a fresh cross-compiler works.
4214  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4215  # <limits.h> exists even on freestanding compilers.
4216  # On the NeXT, cc -E runs the code through the compiler's parser,
4217  # not just through cpp. "Syntax error" is here to catch this case.
4218  cat >conftest.$ac_ext <<_ACEOF
4219/* confdefs.h.  */
4220_ACEOF
4221cat confdefs.h >>conftest.$ac_ext
4222cat >>conftest.$ac_ext <<_ACEOF
4223/* end confdefs.h.  */
4224#ifdef __STDC__
4225# include <limits.h>
4226#else
4227# include <assert.h>
4228#endif
4229		     Syntax error
4230_ACEOF
4231if { (ac_try="$ac_cpp conftest.$ac_ext"
4232case "(($ac_try" in
4233  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4234  *) ac_try_echo=$ac_try;;
4235esac
4236eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4237  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4238  ac_status=$?
4239  grep -v '^ *+' conftest.er1 >conftest.err
4240  rm -f conftest.er1
4241  cat conftest.err >&5
4242  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4243  (exit $ac_status); } >/dev/null && {
4244	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4245	 test ! -s conftest.err
4246       }; then
4247  :
4248else
4249  echo "$as_me: failed program was:" >&5
4250sed 's/^/| /' conftest.$ac_ext >&5
4251
4252  # Broken: fails on valid input.
4253continue
4254fi
4255
4256rm -f conftest.err conftest.$ac_ext
4257
4258  # OK, works on sane cases.  Now check whether nonexistent headers
4259  # can be detected and how.
4260  cat >conftest.$ac_ext <<_ACEOF
4261/* confdefs.h.  */
4262_ACEOF
4263cat confdefs.h >>conftest.$ac_ext
4264cat >>conftest.$ac_ext <<_ACEOF
4265/* end confdefs.h.  */
4266#include <ac_nonexistent.h>
4267_ACEOF
4268if { (ac_try="$ac_cpp conftest.$ac_ext"
4269case "(($ac_try" in
4270  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4271  *) ac_try_echo=$ac_try;;
4272esac
4273eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4274  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4275  ac_status=$?
4276  grep -v '^ *+' conftest.er1 >conftest.err
4277  rm -f conftest.er1
4278  cat conftest.err >&5
4279  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4280  (exit $ac_status); } >/dev/null && {
4281	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4282	 test ! -s conftest.err
4283       }; then
4284  # Broken: success on invalid input.
4285continue
4286else
4287  echo "$as_me: failed program was:" >&5
4288sed 's/^/| /' conftest.$ac_ext >&5
4289
4290  # Passes both tests.
4291ac_preproc_ok=:
4292break
4293fi
4294
4295rm -f conftest.err conftest.$ac_ext
4296
4297done
4298# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4299rm -f conftest.err conftest.$ac_ext
4300if $ac_preproc_ok; then
4301  break
4302fi
4303
4304    done
4305    ac_cv_prog_CPP=$CPP
4306
4307fi
4308  CPP=$ac_cv_prog_CPP
4309else
4310  ac_cv_prog_CPP=$CPP
4311fi
4312{ echo "$as_me:$LINENO: result: $CPP" >&5
4313echo "${ECHO_T}$CPP" >&6; }
4314ac_preproc_ok=false
4315for ac_c_preproc_warn_flag in '' yes
4316do
4317  # Use a header file that comes with gcc, so configuring glibc
4318  # with a fresh cross-compiler works.
4319  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4320  # <limits.h> exists even on freestanding compilers.
4321  # On the NeXT, cc -E runs the code through the compiler's parser,
4322  # not just through cpp. "Syntax error" is here to catch this case.
4323  cat >conftest.$ac_ext <<_ACEOF
4324/* confdefs.h.  */
4325_ACEOF
4326cat confdefs.h >>conftest.$ac_ext
4327cat >>conftest.$ac_ext <<_ACEOF
4328/* end confdefs.h.  */
4329#ifdef __STDC__
4330# include <limits.h>
4331#else
4332# include <assert.h>
4333#endif
4334		     Syntax error
4335_ACEOF
4336if { (ac_try="$ac_cpp conftest.$ac_ext"
4337case "(($ac_try" in
4338  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4339  *) ac_try_echo=$ac_try;;
4340esac
4341eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4342  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4343  ac_status=$?
4344  grep -v '^ *+' conftest.er1 >conftest.err
4345  rm -f conftest.er1
4346  cat conftest.err >&5
4347  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4348  (exit $ac_status); } >/dev/null && {
4349	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4350	 test ! -s conftest.err
4351       }; then
4352  :
4353else
4354  echo "$as_me: failed program was:" >&5
4355sed 's/^/| /' conftest.$ac_ext >&5
4356
4357  # Broken: fails on valid input.
4358continue
4359fi
4360
4361rm -f conftest.err conftest.$ac_ext
4362
4363  # OK, works on sane cases.  Now check whether nonexistent headers
4364  # can be detected and how.
4365  cat >conftest.$ac_ext <<_ACEOF
4366/* confdefs.h.  */
4367_ACEOF
4368cat confdefs.h >>conftest.$ac_ext
4369cat >>conftest.$ac_ext <<_ACEOF
4370/* end confdefs.h.  */
4371#include <ac_nonexistent.h>
4372_ACEOF
4373if { (ac_try="$ac_cpp conftest.$ac_ext"
4374case "(($ac_try" in
4375  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4376  *) ac_try_echo=$ac_try;;
4377esac
4378eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4379  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4380  ac_status=$?
4381  grep -v '^ *+' conftest.er1 >conftest.err
4382  rm -f conftest.er1
4383  cat conftest.err >&5
4384  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4385  (exit $ac_status); } >/dev/null && {
4386	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4387	 test ! -s conftest.err
4388       }; then
4389  # Broken: success on invalid input.
4390continue
4391else
4392  echo "$as_me: failed program was:" >&5
4393sed 's/^/| /' conftest.$ac_ext >&5
4394
4395  # Passes both tests.
4396ac_preproc_ok=:
4397break
4398fi
4399
4400rm -f conftest.err conftest.$ac_ext
4401
4402done
4403# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4404rm -f conftest.err conftest.$ac_ext
4405if $ac_preproc_ok; then
4406  :
4407else
4408  { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4409See \`config.log' for more details." >&5
4410echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4411See \`config.log' for more details." >&2;}
4412   { (exit 1); exit 1; }; }
4413fi
4414
4415ac_ext=c
4416ac_cpp='$CPP $CPPFLAGS'
4417ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4418ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4419ac_compiler_gnu=$ac_cv_c_compiler_gnu
4420
4421
4422{ echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
4423echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
4424if test "${ac_cv_path_GREP+set}" = set; then
4425  echo $ECHO_N "(cached) $ECHO_C" >&6
4426else
4427  # Extract the first word of "grep ggrep" to use in msg output
4428if test -z "$GREP"; then
4429set dummy grep ggrep; ac_prog_name=$2
4430if test "${ac_cv_path_GREP+set}" = set; then
4431  echo $ECHO_N "(cached) $ECHO_C" >&6
4432else
4433  ac_path_GREP_found=false
4434# Loop through the user's path and test for each of PROGNAME-LIST
4435as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4436for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4437do
4438  IFS=$as_save_IFS
4439  test -z "$as_dir" && as_dir=.
4440  for ac_prog in grep ggrep; do
4441  for ac_exec_ext in '' $ac_executable_extensions; do
4442    ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4443    { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
4444    # Check for GNU ac_path_GREP and select it if it is found.
4445  # Check for GNU $ac_path_GREP
4446case `"$ac_path_GREP" --version 2>&1` in
4447*GNU*)
4448  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4449*)
4450  ac_count=0
4451  echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
4452  while :
4453  do
4454    cat "conftest.in" "conftest.in" >"conftest.tmp"
4455    mv "conftest.tmp" "conftest.in"
4456    cp "conftest.in" "conftest.nl"
4457    echo 'GREP' >> "conftest.nl"
4458    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4459    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4460    ac_count=`expr $ac_count + 1`
4461    if test $ac_count -gt ${ac_path_GREP_max-0}; then
4462      # Best one so far, save it but keep looking for a better one
4463      ac_cv_path_GREP="$ac_path_GREP"
4464      ac_path_GREP_max=$ac_count
4465    fi
4466    # 10*(2^10) chars as input seems more than enough
4467    test $ac_count -gt 10 && break
4468  done
4469  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4470esac
4471
4472
4473    $ac_path_GREP_found && break 3
4474  done
4475done
4476
4477done
4478IFS=$as_save_IFS
4479
4480
4481fi
4482
4483GREP="$ac_cv_path_GREP"
4484if test -z "$GREP"; then
4485  { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
4486echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
4487   { (exit 1); exit 1; }; }
4488fi
4489
4490else
4491  ac_cv_path_GREP=$GREP
4492fi
4493
4494
4495fi
4496{ echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
4497echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
4498 GREP="$ac_cv_path_GREP"
4499
4500
4501{ echo "$as_me:$LINENO: checking for egrep" >&5
4502echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
4503if test "${ac_cv_path_EGREP+set}" = set; then
4504  echo $ECHO_N "(cached) $ECHO_C" >&6
4505else
4506  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4507   then ac_cv_path_EGREP="$GREP -E"
4508   else
4509     # Extract the first word of "egrep" to use in msg output
4510if test -z "$EGREP"; then
4511set dummy egrep; ac_prog_name=$2
4512if test "${ac_cv_path_EGREP+set}" = set; then
4513  echo $ECHO_N "(cached) $ECHO_C" >&6
4514else
4515  ac_path_EGREP_found=false
4516# Loop through the user's path and test for each of PROGNAME-LIST
4517as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4518for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4519do
4520  IFS=$as_save_IFS
4521  test -z "$as_dir" && as_dir=.
4522  for ac_prog in egrep; do
4523  for ac_exec_ext in '' $ac_executable_extensions; do
4524    ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4525    { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4526    # Check for GNU ac_path_EGREP and select it if it is found.
4527  # Check for GNU $ac_path_EGREP
4528case `"$ac_path_EGREP" --version 2>&1` in
4529*GNU*)
4530  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4531*)
4532  ac_count=0
4533  echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
4534  while :
4535  do
4536    cat "conftest.in" "conftest.in" >"conftest.tmp"
4537    mv "conftest.tmp" "conftest.in"
4538    cp "conftest.in" "conftest.nl"
4539    echo 'EGREP' >> "conftest.nl"
4540    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4541    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4542    ac_count=`expr $ac_count + 1`
4543    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4544      # Best one so far, save it but keep looking for a better one
4545      ac_cv_path_EGREP="$ac_path_EGREP"
4546      ac_path_EGREP_max=$ac_count
4547    fi
4548    # 10*(2^10) chars as input seems more than enough
4549    test $ac_count -gt 10 && break
4550  done
4551  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4552esac
4553
4554
4555    $ac_path_EGREP_found && break 3
4556  done
4557done
4558
4559done
4560IFS=$as_save_IFS
4561
4562
4563fi
4564
4565EGREP="$ac_cv_path_EGREP"
4566if test -z "$EGREP"; then
4567  { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
4568echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
4569   { (exit 1); exit 1; }; }
4570fi
4571
4572else
4573  ac_cv_path_EGREP=$EGREP
4574fi
4575
4576
4577   fi
4578fi
4579{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
4580echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
4581 EGREP="$ac_cv_path_EGREP"
4582
4583
4584
4585{ echo "$as_me:$LINENO: checking for AIX" >&5
4586echo $ECHO_N "checking for AIX... $ECHO_C" >&6; }
4587cat >conftest.$ac_ext <<_ACEOF
4588/* confdefs.h.  */
4589_ACEOF
4590cat confdefs.h >>conftest.$ac_ext
4591cat >>conftest.$ac_ext <<_ACEOF
4592/* end confdefs.h.  */
4593#ifdef _AIX
4594  yes
4595#endif
4596
4597_ACEOF
4598if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4599  $EGREP "yes" >/dev/null 2>&1; then
4600  { echo "$as_me:$LINENO: result: yes" >&5
4601echo "${ECHO_T}yes" >&6; }
4602cat >>confdefs.h <<\_ACEOF
4603#define _ALL_SOURCE 1
4604_ACEOF
4605
4606else
4607  { echo "$as_me:$LINENO: result: no" >&5
4608echo "${ECHO_T}no" >&6; }
4609fi
4610rm -f conftest*
4611
4612
4613
4614cat >>confdefs.h <<\_ACEOF
4615#define _GNU_SOURCE 1
4616_ACEOF
4617
4618
4619
4620### Use -Wno-pointer-sign if the compiler supports it
4621{ echo "$as_me:$LINENO: checking whether gcc understands -Wno-pointer-sign" >&5
4622echo $ECHO_N "checking whether gcc understands -Wno-pointer-sign... $ECHO_C" >&6; }
4623SAVE_CFLAGS="$CFLAGS"
4624CFLAGS="$CFLAGS -Wno-pointer-sign"
4625cat >conftest.$ac_ext <<_ACEOF
4626/* confdefs.h.  */
4627_ACEOF
4628cat confdefs.h >>conftest.$ac_ext
4629cat >>conftest.$ac_ext <<_ACEOF
4630/* end confdefs.h.  */
4631
4632int
4633main ()
4634{
4635
4636  ;
4637  return 0;
4638}
4639_ACEOF
4640rm -f conftest.$ac_objext
4641if { (ac_try="$ac_compile"
4642case "(($ac_try" in
4643  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4644  *) ac_try_echo=$ac_try;;
4645esac
4646eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4647  (eval "$ac_compile") 2>conftest.er1
4648  ac_status=$?
4649  grep -v '^ *+' conftest.er1 >conftest.err
4650  rm -f conftest.er1
4651  cat conftest.err >&5
4652  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4653  (exit $ac_status); } && {
4654	 test -z "$ac_c_werror_flag" ||
4655	 test ! -s conftest.err
4656       } && test -s conftest.$ac_objext; then
4657  has_option=yes
4658else
4659  echo "$as_me: failed program was:" >&5
4660sed 's/^/| /' conftest.$ac_ext >&5
4661
4662	has_option=no
4663fi
4664
4665rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4666if test $has_option = yes; then
4667   C_WARNINGS_SWITCH="-Wno-pointer-sign $C_WARNINGS_SWITCH"
4668fi
4669{ echo "$as_me:$LINENO: result: $has_option" >&5
4670echo "${ECHO_T}$has_option" >&6; }
4671CFLAGS="$SAVE_CFLAGS"
4672unset has_option
4673unset SAVE_CFLAGS
4674
4675#### Some other nice autoconf tests.
4676
4677{ echo "$as_me:$LINENO: checking whether ln -s works" >&5
4678echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; }
4679LN_S=$as_ln_s
4680if test "$LN_S" = "ln -s"; then
4681  { echo "$as_me:$LINENO: result: yes" >&5
4682echo "${ECHO_T}yes" >&6; }
4683else
4684  { echo "$as_me:$LINENO: result: no, using $LN_S" >&5
4685echo "${ECHO_T}no, using $LN_S" >&6; }
4686fi
4687
4688ac_ext=c
4689ac_cpp='$CPP $CPPFLAGS'
4690ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4691ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4692ac_compiler_gnu=$ac_cv_c_compiler_gnu
4693{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4694echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
4695# On Suns, sometimes $CPP names a directory.
4696if test -n "$CPP" && test -d "$CPP"; then
4697  CPP=
4698fi
4699if test -z "$CPP"; then
4700  if test "${ac_cv_prog_CPP+set}" = set; then
4701  echo $ECHO_N "(cached) $ECHO_C" >&6
4702else
4703      # Double quotes because CPP needs to be expanded
4704    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4705    do
4706      ac_preproc_ok=false
4707for ac_c_preproc_warn_flag in '' yes
4708do
4709  # Use a header file that comes with gcc, so configuring glibc
4710  # with a fresh cross-compiler works.
4711  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4712  # <limits.h> exists even on freestanding compilers.
4713  # On the NeXT, cc -E runs the code through the compiler's parser,
4714  # not just through cpp. "Syntax error" is here to catch this case.
4715  cat >conftest.$ac_ext <<_ACEOF
4716/* confdefs.h.  */
4717_ACEOF
4718cat confdefs.h >>conftest.$ac_ext
4719cat >>conftest.$ac_ext <<_ACEOF
4720/* end confdefs.h.  */
4721#ifdef __STDC__
4722# include <limits.h>
4723#else
4724# include <assert.h>
4725#endif
4726		     Syntax error
4727_ACEOF
4728if { (ac_try="$ac_cpp conftest.$ac_ext"
4729case "(($ac_try" in
4730  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4731  *) ac_try_echo=$ac_try;;
4732esac
4733eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4734  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4735  ac_status=$?
4736  grep -v '^ *+' conftest.er1 >conftest.err
4737  rm -f conftest.er1
4738  cat conftest.err >&5
4739  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4740  (exit $ac_status); } >/dev/null && {
4741	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4742	 test ! -s conftest.err
4743       }; then
4744  :
4745else
4746  echo "$as_me: failed program was:" >&5
4747sed 's/^/| /' conftest.$ac_ext >&5
4748
4749  # Broken: fails on valid input.
4750continue
4751fi
4752
4753rm -f conftest.err conftest.$ac_ext
4754
4755  # OK, works on sane cases.  Now check whether nonexistent headers
4756  # can be detected and how.
4757  cat >conftest.$ac_ext <<_ACEOF
4758/* confdefs.h.  */
4759_ACEOF
4760cat confdefs.h >>conftest.$ac_ext
4761cat >>conftest.$ac_ext <<_ACEOF
4762/* end confdefs.h.  */
4763#include <ac_nonexistent.h>
4764_ACEOF
4765if { (ac_try="$ac_cpp conftest.$ac_ext"
4766case "(($ac_try" in
4767  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4768  *) ac_try_echo=$ac_try;;
4769esac
4770eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4771  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4772  ac_status=$?
4773  grep -v '^ *+' conftest.er1 >conftest.err
4774  rm -f conftest.er1
4775  cat conftest.err >&5
4776  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4777  (exit $ac_status); } >/dev/null && {
4778	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4779	 test ! -s conftest.err
4780       }; then
4781  # Broken: success on invalid input.
4782continue
4783else
4784  echo "$as_me: failed program was:" >&5
4785sed 's/^/| /' conftest.$ac_ext >&5
4786
4787  # Passes both tests.
4788ac_preproc_ok=:
4789break
4790fi
4791
4792rm -f conftest.err conftest.$ac_ext
4793
4794done
4795# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4796rm -f conftest.err conftest.$ac_ext
4797if $ac_preproc_ok; then
4798  break
4799fi
4800
4801    done
4802    ac_cv_prog_CPP=$CPP
4803
4804fi
4805  CPP=$ac_cv_prog_CPP
4806else
4807  ac_cv_prog_CPP=$CPP
4808fi
4809{ echo "$as_me:$LINENO: result: $CPP" >&5
4810echo "${ECHO_T}$CPP" >&6; }
4811ac_preproc_ok=false
4812for ac_c_preproc_warn_flag in '' yes
4813do
4814  # Use a header file that comes with gcc, so configuring glibc
4815  # with a fresh cross-compiler works.
4816  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4817  # <limits.h> exists even on freestanding compilers.
4818  # On the NeXT, cc -E runs the code through the compiler's parser,
4819  # not just through cpp. "Syntax error" is here to catch this case.
4820  cat >conftest.$ac_ext <<_ACEOF
4821/* confdefs.h.  */
4822_ACEOF
4823cat confdefs.h >>conftest.$ac_ext
4824cat >>conftest.$ac_ext <<_ACEOF
4825/* end confdefs.h.  */
4826#ifdef __STDC__
4827# include <limits.h>
4828#else
4829# include <assert.h>
4830#endif
4831		     Syntax error
4832_ACEOF
4833if { (ac_try="$ac_cpp conftest.$ac_ext"
4834case "(($ac_try" in
4835  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4836  *) ac_try_echo=$ac_try;;
4837esac
4838eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4839  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4840  ac_status=$?
4841  grep -v '^ *+' conftest.er1 >conftest.err
4842  rm -f conftest.er1
4843  cat conftest.err >&5
4844  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4845  (exit $ac_status); } >/dev/null && {
4846	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4847	 test ! -s conftest.err
4848       }; then
4849  :
4850else
4851  echo "$as_me: failed program was:" >&5
4852sed 's/^/| /' conftest.$ac_ext >&5
4853
4854  # Broken: fails on valid input.
4855continue
4856fi
4857
4858rm -f conftest.err conftest.$ac_ext
4859
4860  # OK, works on sane cases.  Now check whether nonexistent headers
4861  # can be detected and how.
4862  cat >conftest.$ac_ext <<_ACEOF
4863/* confdefs.h.  */
4864_ACEOF
4865cat confdefs.h >>conftest.$ac_ext
4866cat >>conftest.$ac_ext <<_ACEOF
4867/* end confdefs.h.  */
4868#include <ac_nonexistent.h>
4869_ACEOF
4870if { (ac_try="$ac_cpp conftest.$ac_ext"
4871case "(($ac_try" in
4872  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4873  *) ac_try_echo=$ac_try;;
4874esac
4875eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4876  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4877  ac_status=$?
4878  grep -v '^ *+' conftest.er1 >conftest.err
4879  rm -f conftest.er1
4880  cat conftest.err >&5
4881  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4882  (exit $ac_status); } >/dev/null && {
4883	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4884	 test ! -s conftest.err
4885       }; then
4886  # Broken: success on invalid input.
4887continue
4888else
4889  echo "$as_me: failed program was:" >&5
4890sed 's/^/| /' conftest.$ac_ext >&5
4891
4892  # Passes both tests.
4893ac_preproc_ok=:
4894break
4895fi
4896
4897rm -f conftest.err conftest.$ac_ext
4898
4899done
4900# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4901rm -f conftest.err conftest.$ac_ext
4902if $ac_preproc_ok; then
4903  :
4904else
4905  { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4906See \`config.log' for more details." >&5
4907echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4908See \`config.log' for more details." >&2;}
4909   { (exit 1); exit 1; }; }
4910fi
4911
4912ac_ext=c
4913ac_cpp='$CPP $CPPFLAGS'
4914ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4915ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4916ac_compiler_gnu=$ac_cv_c_compiler_gnu
4917
4918# Find a good install program.  We prefer a C program (faster),
4919# so one script is as good as another.  But avoid the broken or
4920# incompatible versions:
4921# SysV /etc/install, /usr/sbin/install
4922# SunOS /usr/etc/install
4923# IRIX /sbin/install
4924# AIX /bin/install
4925# AmigaOS /C/install, which installs bootblocks on floppy discs
4926# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4927# AFS /usr/afsws/bin/install, which mishandles nonexistent args
4928# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4929# OS/2's system install, which has a completely different semantic
4930# ./install, which can be erroneously created by make from ./install.sh.
4931{ echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
4932echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; }
4933if test -z "$INSTALL"; then
4934if test "${ac_cv_path_install+set}" = set; then
4935  echo $ECHO_N "(cached) $ECHO_C" >&6
4936else
4937  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4938for as_dir in $PATH
4939do
4940  IFS=$as_save_IFS
4941  test -z "$as_dir" && as_dir=.
4942  # Account for people who put trailing slashes in PATH elements.
4943case $as_dir/ in
4944  ./ | .// | /cC/* | \
4945  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4946  ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
4947  /usr/ucb/* ) ;;
4948  *)
4949    # OSF1 and SCO ODT 3.0 have their own names for install.
4950    # Don't use installbsd from OSF since it installs stuff as root
4951    # by default.
4952    for ac_prog in ginstall scoinst install; do
4953      for ac_exec_ext in '' $ac_executable_extensions; do
4954	if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
4955	  if test $ac_prog = install &&
4956	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4957	    # AIX install.  It has an incompatible calling convention.
4958	    :
4959	  elif test $ac_prog = install &&
4960	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4961	    # program-specific install script used by HP pwplus--don't use.
4962	    :
4963	  else
4964	    ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4965	    break 3
4966	  fi
4967	fi
4968      done
4969    done
4970    ;;
4971esac
4972done
4973IFS=$as_save_IFS
4974
4975
4976fi
4977  if test "${ac_cv_path_install+set}" = set; then
4978    INSTALL=$ac_cv_path_install
4979  else
4980    # As a last resort, use the slow shell script.  Don't cache a
4981    # value for INSTALL within a source directory, because that will
4982    # break other packages using the cache if that directory is
4983    # removed, or if the value is a relative name.
4984    INSTALL=$ac_install_sh
4985  fi
4986fi
4987{ echo "$as_me:$LINENO: result: $INSTALL" >&5
4988echo "${ECHO_T}$INSTALL" >&6; }
4989
4990# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4991# It thinks the first close brace ends the variable substitution.
4992test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4993
4994test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
4995
4996test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4997
4998if test "x$RANLIB" = x; then
4999  if test -n "$ac_tool_prefix"; then
5000  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5001set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5002{ echo "$as_me:$LINENO: checking for $ac_word" >&5
5003echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5004if test "${ac_cv_prog_RANLIB+set}" = set; then
5005  echo $ECHO_N "(cached) $ECHO_C" >&6
5006else
5007  if test -n "$RANLIB"; then
5008  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5009else
5010as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5011for as_dir in $PATH
5012do
5013  IFS=$as_save_IFS
5014  test -z "$as_dir" && as_dir=.
5015  for ac_exec_ext in '' $ac_executable_extensions; do
5016  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5017    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5018    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5019    break 2
5020  fi
5021done
5022done
5023IFS=$as_save_IFS
5024
5025fi
5026fi
5027RANLIB=$ac_cv_prog_RANLIB
5028if test -n "$RANLIB"; then
5029  { echo "$as_me:$LINENO: result: $RANLIB" >&5
5030echo "${ECHO_T}$RANLIB" >&6; }
5031else
5032  { echo "$as_me:$LINENO: result: no" >&5
5033echo "${ECHO_T}no" >&6; }
5034fi
5035
5036
5037fi
5038if test -z "$ac_cv_prog_RANLIB"; then
5039  ac_ct_RANLIB=$RANLIB
5040  # Extract the first word of "ranlib", so it can be a program name with args.
5041set dummy ranlib; ac_word=$2
5042{ echo "$as_me:$LINENO: checking for $ac_word" >&5
5043echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5044if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
5045  echo $ECHO_N "(cached) $ECHO_C" >&6
5046else
5047  if test -n "$ac_ct_RANLIB"; then
5048  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5049else
5050as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5051for as_dir in $PATH
5052do
5053  IFS=$as_save_IFS
5054  test -z "$as_dir" && as_dir=.
5055  for ac_exec_ext in '' $ac_executable_extensions; do
5056  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5057    ac_cv_prog_ac_ct_RANLIB="ranlib"
5058    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5059    break 2
5060  fi
5061done
5062done
5063IFS=$as_save_IFS
5064
5065fi
5066fi
5067ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5068if test -n "$ac_ct_RANLIB"; then
5069  { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
5070echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
5071else
5072  { echo "$as_me:$LINENO: result: no" >&5
5073echo "${ECHO_T}no" >&6; }
5074fi
5075
5076  if test "x$ac_ct_RANLIB" = x; then
5077    RANLIB=":"
5078  else
5079    case $cross_compiling:$ac_tool_warned in
5080yes:)
5081{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
5082whose name does not start with the host triplet.  If you think this
5083configuration is useful to you, please write to autoconf@gnu.org." >&5
5084echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
5085whose name does not start with the host triplet.  If you think this
5086configuration is useful to you, please write to autoconf@gnu.org." >&2;}
5087ac_tool_warned=yes ;;
5088esac
5089    RANLIB=$ac_ct_RANLIB
5090  fi
5091else
5092  RANLIB="$ac_cv_prog_RANLIB"
5093fi
5094
5095fi
5096# Extract the first word of "install-info", so it can be a program name with args.
5097set dummy install-info; ac_word=$2
5098{ echo "$as_me:$LINENO: checking for $ac_word" >&5
5099echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5100if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
5101  echo $ECHO_N "(cached) $ECHO_C" >&6
5102else
5103  case $INSTALL_INFO in
5104  [\\/]* | ?:[\\/]*)
5105  ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
5106  ;;
5107  *)
5108  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5109for as_dir in $PATH
5110do
5111  IFS=$as_save_IFS
5112  test -z "$as_dir" && as_dir=.
5113  for ac_exec_ext in '' $ac_executable_extensions; do
5114  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5115    ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
5116    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5117    break 2
5118  fi
5119done
5120done
5121IFS=$as_save_IFS
5122
5123  ;;
5124esac
5125fi
5126INSTALL_INFO=$ac_cv_path_INSTALL_INFO
5127if test -n "$INSTALL_INFO"; then
5128  { echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
5129echo "${ECHO_T}$INSTALL_INFO" >&6; }
5130else
5131  { echo "$as_me:$LINENO: result: no" >&5
5132echo "${ECHO_T}no" >&6; }
5133fi
5134
5135
5136# Extract the first word of "install-info", so it can be a program name with args.
5137set dummy install-info; ac_word=$2
5138{ echo "$as_me:$LINENO: checking for $ac_word" >&5
5139echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5140if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
5141  echo $ECHO_N "(cached) $ECHO_C" >&6
5142else
5143  case $INSTALL_INFO in
5144  [\\/]* | ?:[\\/]*)
5145  ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
5146  ;;
5147  *)
5148  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5149for as_dir in /usr/sbin
5150do
5151  IFS=$as_save_IFS
5152  test -z "$as_dir" && as_dir=.
5153  for ac_exec_ext in '' $ac_executable_extensions; do
5154  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5155    ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
5156    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5157    break 2
5158  fi
5159done
5160done
5161IFS=$as_save_IFS
5162
5163  ;;
5164esac
5165fi
5166INSTALL_INFO=$ac_cv_path_INSTALL_INFO
5167if test -n "$INSTALL_INFO"; then
5168  { echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
5169echo "${ECHO_T}$INSTALL_INFO" >&6; }
5170else
5171  { echo "$as_me:$LINENO: result: no" >&5
5172echo "${ECHO_T}no" >&6; }
5173fi
5174
5175
5176# Extract the first word of "install-info", so it can be a program name with args.
5177set dummy install-info; ac_word=$2
5178{ echo "$as_me:$LINENO: checking for $ac_word" >&5
5179echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5180if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
5181  echo $ECHO_N "(cached) $ECHO_C" >&6
5182else
5183  case $INSTALL_INFO in
5184  [\\/]* | ?:[\\/]*)
5185  ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
5186  ;;
5187  *)
5188  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5189for as_dir in /sbin
5190do
5191  IFS=$as_save_IFS
5192  test -z "$as_dir" && as_dir=.
5193  for ac_exec_ext in '' $ac_executable_extensions; do
5194  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5195    ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
5196    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5197    break 2
5198  fi
5199done
5200done
5201IFS=$as_save_IFS
5202
5203  test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
5204  ;;
5205esac
5206fi
5207INSTALL_INFO=$ac_cv_path_INSTALL_INFO
5208if test -n "$INSTALL_INFO"; then
5209  { echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
5210echo "${ECHO_T}$INSTALL_INFO" >&6; }
5211else
5212  { echo "$as_me:$LINENO: result: no" >&5
5213echo "${ECHO_T}no" >&6; }
5214fi
5215
5216
5217# Extract the first word of "gzip", so it can be a program name with args.
5218set dummy gzip; ac_word=$2
5219{ echo "$as_me:$LINENO: checking for $ac_word" >&5
5220echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5221if test "${ac_cv_path_GZIP_PROG+set}" = set; then
5222  echo $ECHO_N "(cached) $ECHO_C" >&6
5223else
5224  case $GZIP_PROG in
5225  [\\/]* | ?:[\\/]*)
5226  ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
5227  ;;
5228  *)
5229  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5230for as_dir in $PATH
5231do
5232  IFS=$as_save_IFS
5233  test -z "$as_dir" && as_dir=.
5234  for ac_exec_ext in '' $ac_executable_extensions; do
5235  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5236    ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
5237    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5238    break 2
5239  fi
5240done
5241done
5242IFS=$as_save_IFS
5243
5244  ;;
5245esac
5246fi
5247GZIP_PROG=$ac_cv_path_GZIP_PROG
5248if test -n "$GZIP_PROG"; then
5249  { echo "$as_me:$LINENO: result: $GZIP_PROG" >&5
5250echo "${ECHO_T}$GZIP_PROG" >&6; }
5251else
5252  { echo "$as_me:$LINENO: result: no" >&5
5253echo "${ECHO_T}no" >&6; }
5254fi
5255
5256
5257
5258
5259if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
5260then
5261  ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
5262fi
5263
5264if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
5265then
5266  ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
5267fi
5268
5269
5270late_LDFLAGS=$LDFLAGS
5271if test "$GCC" = yes; then
5272  LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
5273else
5274  LDFLAGS="$LDFLAGS -znocombreloc"
5275fi
5276
5277{ echo "$as_me:$LINENO: checking for -znocombreloc" >&5
5278echo $ECHO_N "checking for -znocombreloc... $ECHO_C" >&6; }
5279cat >conftest.$ac_ext <<_ACEOF
5280main(){return 0;}
5281_ACEOF
5282rm -f conftest.$ac_objext conftest$ac_exeext
5283if { (ac_try="$ac_link"
5284case "(($ac_try" in
5285  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5286  *) ac_try_echo=$ac_try;;
5287esac
5288eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5289  (eval "$ac_link") 2>conftest.er1
5290  ac_status=$?
5291  grep -v '^ *+' conftest.er1 >conftest.err
5292  rm -f conftest.er1
5293  cat conftest.err >&5
5294  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5295  (exit $ac_status); } && {
5296	 test -z "$ac_c_werror_flag" ||
5297	 test ! -s conftest.err
5298       } && test -s conftest$ac_exeext &&
5299       $as_test_x conftest$ac_exeext; then
5300  { echo "$as_me:$LINENO: result: yes" >&5
5301echo "${ECHO_T}yes" >&6; }
5302else
5303  echo "$as_me: failed program was:" >&5
5304sed 's/^/| /' conftest.$ac_ext >&5
5305
5306	LDFLAGS=$late_LDFLAGS
5307  { echo "$as_me:$LINENO: result: no" >&5
5308echo "${ECHO_T}no" >&6; }
5309fi
5310
5311rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
5312      conftest$ac_exeext conftest.$ac_ext
5313
5314#### Extract some information from the operating system and machine files.
5315
5316{ echo "$as_me:$LINENO: checking the machine- and system-dependent files to find out
5317 - which libraries the lib-src programs will want, and
5318 - whether the GNU malloc routines are usable..." >&5
5319echo "$as_me: checking the machine- and system-dependent files to find out
5320 - which libraries the lib-src programs will want, and
5321 - whether the GNU malloc routines are usable..." >&6;}
5322
5323### First figure out CFLAGS (which we use for running the compiler here)
5324### and REAL_CFLAGS (which we use for real compilation).
5325### The two are the same except on a few systems, where they are made
5326### different to work around various lossages.  For example,
5327### GCC 2.5 on GNU/Linux needs them to be different because it treats -g
5328### as implying static linking.
5329
5330### If the CFLAGS env var is specified, we use that value
5331### instead of the default.
5332
5333### It's not important that this name contain the PID; you can't run
5334### two configures in the same directory and have anything work
5335### anyway.
5336tempcname="conftest.c"
5337
5338echo '
5339#include "'${srcdir}'/src/'${opsysfile}'"
5340#include "'${srcdir}'/src/'${machfile}'"
5341#ifndef LIBS_MACHINE
5342#define LIBS_MACHINE
5343#endif
5344#ifndef LIBS_SYSTEM
5345#define LIBS_SYSTEM
5346#endif
5347#ifndef C_SWITCH_SYSTEM
5348#define C_SWITCH_SYSTEM
5349#endif
5350#ifndef C_SWITCH_MACHINE
5351#define C_SWITCH_MACHINE
5352#endif
5353configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM
5354configure___ c_switch_system=C_SWITCH_SYSTEM
5355configure___ c_switch_machine=C_SWITCH_MACHINE
5356
5357#ifndef LIB_X11_LIB
5358#define LIB_X11_LIB -lX11
5359#endif
5360
5361#ifndef LIBX11_MACHINE
5362#define LIBX11_MACHINE
5363#endif
5364
5365#ifndef LIBX11_SYSTEM
5366#define LIBX11_SYSTEM
5367#endif
5368configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM
5369
5370#ifdef UNEXEC
5371configure___ unexec=UNEXEC
5372#else
5373configure___ unexec=unexec.o
5374#endif
5375
5376#ifdef SYSTEM_MALLOC
5377configure___ system_malloc=yes
5378#else
5379configure___ system_malloc=no
5380#endif
5381
5382#ifdef USE_MMAP_FOR_BUFFERS
5383configure___ use_mmap_for_buffers=yes
5384#else
5385configure___ use_mmap_for_buffers=no
5386#endif
5387
5388#ifndef C_DEBUG_SWITCH
5389#define C_DEBUG_SWITCH -g
5390#endif
5391
5392#ifndef C_OPTIMIZE_SWITCH
5393#ifdef __GNUC__
5394#define C_OPTIMIZE_SWITCH -O2
5395#else
5396#define C_OPTIMIZE_SWITCH -O
5397#endif
5398#endif
5399
5400#ifndef C_WARNINGS_SWITCH
5401#define C_WARNINGS_SWITCH ${C_WARNINGS_SWITCH}
5402#endif
5403
5404#ifndef LD_SWITCH_MACHINE
5405#define LD_SWITCH_MACHINE
5406#endif
5407
5408#ifndef LD_SWITCH_SYSTEM
5409#define LD_SWITCH_SYSTEM
5410#endif
5411
5412#ifndef LD_SWITCH_X_SITE_AUX
5413#define LD_SWITCH_X_SITE_AUX
5414#endif
5415
5416configure___ ld_switch_system=LD_SWITCH_SYSTEM
5417configure___ ld_switch_machine=LD_SWITCH_MACHINE
5418
5419#ifdef THIS_IS_CONFIGURE
5420
5421/* Get the CFLAGS for tests in configure.  */
5422#ifdef __GNUC__
5423configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
5424#else
5425configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
5426#endif
5427
5428#else /* not THIS_IS_CONFIGURE */
5429
5430/* Get the CFLAGS for real compilation.  */
5431#ifdef __GNUC__
5432configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH C_WARNINGS_SWITCH '${SPECIFIED_CFLAGS}'
5433#else
5434configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
5435#endif
5436
5437#endif /* not THIS_IS_CONFIGURE */
5438' > ${tempcname}
5439
5440# The value of CPP is a quoted variable reference, so we need to do this
5441# to get its actual value...
5442CPP=`eval "echo $CPP"`
5443eval `${CPP} -Isrc ${tempcname} \
5444       | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
5445if test "x$SPECIFIED_CFLAGS" = x; then
5446  eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \
5447	 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
5448else
5449  REAL_CFLAGS="$CFLAGS"
5450fi
5451rm ${tempcname}
5452
5453ac_link="$ac_link $ld_switch_machine $ld_switch_system"
5454
5455### Make sure subsequent tests use flags consistent with the build flags.
5456
5457if test x"${OVERRIDE_CPPFLAGS}" != x; then
5458  CPPFLAGS="${OVERRIDE_CPPFLAGS}"
5459else
5460  CPPFLAGS="$c_switch_system $c_switch_machine $CPPFLAGS"
5461fi
5462
5463
5464
5465# Check whether --enable-largefile was given.
5466if test "${enable_largefile+set}" = set; then
5467  enableval=$enable_largefile;
5468fi
5469
5470if test "$enable_largefile" != no; then
5471
5472  { echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
5473echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6; }
5474if test "${ac_cv_sys_largefile_CC+set}" = set; then
5475  echo $ECHO_N "(cached) $ECHO_C" >&6
5476else
5477  ac_cv_sys_largefile_CC=no
5478     if test "$GCC" != yes; then
5479       ac_save_CC=$CC
5480       while :; do
5481	 # IRIX 6.2 and later do not support large files by default,
5482	 # so use the C compiler's -n32 option if that helps.
5483	 cat >conftest.$ac_ext <<_ACEOF
5484/* confdefs.h.  */
5485_ACEOF
5486cat confdefs.h >>conftest.$ac_ext
5487cat >>conftest.$ac_ext <<_ACEOF
5488/* end confdefs.h.  */
5489#include <sys/types.h>
5490 /* Check that off_t can represent 2**63 - 1 correctly.
5491    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5492    since some C++ compilers masquerading as C compilers
5493    incorrectly reject 9223372036854775807.  */
5494#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5495  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5496		       && LARGE_OFF_T % 2147483647 == 1)
5497		      ? 1 : -1];
5498int
5499main ()
5500{
5501
5502  ;
5503  return 0;
5504}
5505_ACEOF
5506	 rm -f conftest.$ac_objext
5507if { (ac_try="$ac_compile"
5508case "(($ac_try" in
5509  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5510  *) ac_try_echo=$ac_try;;
5511esac
5512eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5513  (eval "$ac_compile") 2>conftest.er1
5514  ac_status=$?
5515  grep -v '^ *+' conftest.er1 >conftest.err
5516  rm -f conftest.er1
5517  cat conftest.err >&5
5518  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5519  (exit $ac_status); } && {
5520	 test -z "$ac_c_werror_flag" ||
5521	 test ! -s conftest.err
5522       } && test -s conftest.$ac_objext; then
5523  break
5524else
5525  echo "$as_me: failed program was:" >&5
5526sed 's/^/| /' conftest.$ac_ext >&5
5527
5528
5529fi
5530
5531rm -f core conftest.err conftest.$ac_objext
5532	 CC="$CC -n32"
5533	 rm -f conftest.$ac_objext
5534if { (ac_try="$ac_compile"
5535case "(($ac_try" in
5536  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5537  *) ac_try_echo=$ac_try;;
5538esac
5539eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5540  (eval "$ac_compile") 2>conftest.er1
5541  ac_status=$?
5542  grep -v '^ *+' conftest.er1 >conftest.err
5543  rm -f conftest.er1
5544  cat conftest.err >&5
5545  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5546  (exit $ac_status); } && {
5547	 test -z "$ac_c_werror_flag" ||
5548	 test ! -s conftest.err
5549       } && test -s conftest.$ac_objext; then
5550  ac_cv_sys_largefile_CC=' -n32'; break
5551else
5552  echo "$as_me: failed program was:" >&5
5553sed 's/^/| /' conftest.$ac_ext >&5
5554
5555
5556fi
5557
5558rm -f core conftest.err conftest.$ac_objext
5559	 break
5560       done
5561       CC=$ac_save_CC
5562       rm -f conftest.$ac_ext
5563    fi
5564fi
5565{ echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
5566echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6; }
5567  if test "$ac_cv_sys_largefile_CC" != no; then
5568    CC=$CC$ac_cv_sys_largefile_CC
5569  fi
5570
5571  { echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5572echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6; }
5573if test "${ac_cv_sys_file_offset_bits+set}" = set; then
5574  echo $ECHO_N "(cached) $ECHO_C" >&6
5575else
5576  while :; do
5577  cat >conftest.$ac_ext <<_ACEOF
5578/* confdefs.h.  */
5579_ACEOF
5580cat confdefs.h >>conftest.$ac_ext
5581cat >>conftest.$ac_ext <<_ACEOF
5582/* end confdefs.h.  */
5583#include <sys/types.h>
5584 /* Check that off_t can represent 2**63 - 1 correctly.
5585    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5586    since some C++ compilers masquerading as C compilers
5587    incorrectly reject 9223372036854775807.  */
5588#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5589  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5590		       && LARGE_OFF_T % 2147483647 == 1)
5591		      ? 1 : -1];
5592int
5593main ()
5594{
5595
5596  ;
5597  return 0;
5598}
5599_ACEOF
5600rm -f conftest.$ac_objext
5601if { (ac_try="$ac_compile"
5602case "(($ac_try" in
5603  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5604  *) ac_try_echo=$ac_try;;
5605esac
5606eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5607  (eval "$ac_compile") 2>conftest.er1
5608  ac_status=$?
5609  grep -v '^ *+' conftest.er1 >conftest.err
5610  rm -f conftest.er1
5611  cat conftest.err >&5
5612  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5613  (exit $ac_status); } && {
5614	 test -z "$ac_c_werror_flag" ||
5615	 test ! -s conftest.err
5616       } && test -s conftest.$ac_objext; then
5617  ac_cv_sys_file_offset_bits=no; break
5618else
5619  echo "$as_me: failed program was:" >&5
5620sed 's/^/| /' conftest.$ac_ext >&5
5621
5622
5623fi
5624
5625rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5626  cat >conftest.$ac_ext <<_ACEOF
5627/* confdefs.h.  */
5628_ACEOF
5629cat confdefs.h >>conftest.$ac_ext
5630cat >>conftest.$ac_ext <<_ACEOF
5631/* end confdefs.h.  */
5632#define _FILE_OFFSET_BITS 64
5633#include <sys/types.h>
5634 /* Check that off_t can represent 2**63 - 1 correctly.
5635    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5636    since some C++ compilers masquerading as C compilers
5637    incorrectly reject 9223372036854775807.  */
5638#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5639  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5640		       && LARGE_OFF_T % 2147483647 == 1)
5641		      ? 1 : -1];
5642int
5643main ()
5644{
5645
5646  ;
5647  return 0;
5648}
5649_ACEOF
5650rm -f conftest.$ac_objext
5651if { (ac_try="$ac_compile"
5652case "(($ac_try" in
5653  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5654  *) ac_try_echo=$ac_try;;
5655esac
5656eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5657  (eval "$ac_compile") 2>conftest.er1
5658  ac_status=$?
5659  grep -v '^ *+' conftest.er1 >conftest.err
5660  rm -f conftest.er1
5661  cat conftest.err >&5
5662  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5663  (exit $ac_status); } && {
5664	 test -z "$ac_c_werror_flag" ||
5665	 test ! -s conftest.err
5666       } && test -s conftest.$ac_objext; then
5667  ac_cv_sys_file_offset_bits=64; break
5668else
5669  echo "$as_me: failed program was:" >&5
5670sed 's/^/| /' conftest.$ac_ext >&5
5671
5672
5673fi
5674
5675rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5676  ac_cv_sys_file_offset_bits=unknown
5677  break
5678done
5679fi
5680{ echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
5681echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6; }
5682case $ac_cv_sys_file_offset_bits in #(
5683  no | unknown) ;;
5684  *)
5685cat >>confdefs.h <<_ACEOF
5686#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5687_ACEOF
5688;;
5689esac
5690rm -f conftest*
5691  if test $ac_cv_sys_file_offset_bits = unknown; then
5692    { echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
5693echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6; }
5694if test "${ac_cv_sys_large_files+set}" = set; then
5695  echo $ECHO_N "(cached) $ECHO_C" >&6
5696else
5697  while :; do
5698  cat >conftest.$ac_ext <<_ACEOF
5699/* confdefs.h.  */
5700_ACEOF
5701cat confdefs.h >>conftest.$ac_ext
5702cat >>conftest.$ac_ext <<_ACEOF
5703/* end confdefs.h.  */
5704#include <sys/types.h>
5705 /* Check that off_t can represent 2**63 - 1 correctly.
5706    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5707    since some C++ compilers masquerading as C compilers
5708    incorrectly reject 9223372036854775807.  */
5709#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5710  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5711		       && LARGE_OFF_T % 2147483647 == 1)
5712		      ? 1 : -1];
5713int
5714main ()
5715{
5716
5717  ;
5718  return 0;
5719}
5720_ACEOF
5721rm -f conftest.$ac_objext
5722if { (ac_try="$ac_compile"
5723case "(($ac_try" in
5724  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5725  *) ac_try_echo=$ac_try;;
5726esac
5727eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5728  (eval "$ac_compile") 2>conftest.er1
5729  ac_status=$?
5730  grep -v '^ *+' conftest.er1 >conftest.err
5731  rm -f conftest.er1
5732  cat conftest.err >&5
5733  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5734  (exit $ac_status); } && {
5735	 test -z "$ac_c_werror_flag" ||
5736	 test ! -s conftest.err
5737       } && test -s conftest.$ac_objext; then
5738  ac_cv_sys_large_files=no; break
5739else
5740  echo "$as_me: failed program was:" >&5
5741sed 's/^/| /' conftest.$ac_ext >&5
5742
5743
5744fi
5745
5746rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5747  cat >conftest.$ac_ext <<_ACEOF
5748/* confdefs.h.  */
5749_ACEOF
5750cat confdefs.h >>conftest.$ac_ext
5751cat >>conftest.$ac_ext <<_ACEOF
5752/* end confdefs.h.  */
5753#define _LARGE_FILES 1
5754#include <sys/types.h>
5755 /* Check that off_t can represent 2**63 - 1 correctly.
5756    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5757    since some C++ compilers masquerading as C compilers
5758    incorrectly reject 9223372036854775807.  */
5759#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5760  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5761		       && LARGE_OFF_T % 2147483647 == 1)
5762		      ? 1 : -1];
5763int
5764main ()
5765{
5766
5767  ;
5768  return 0;
5769}
5770_ACEOF
5771rm -f conftest.$ac_objext
5772if { (ac_try="$ac_compile"
5773case "(($ac_try" in
5774  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5775  *) ac_try_echo=$ac_try;;
5776esac
5777eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5778  (eval "$ac_compile") 2>conftest.er1
5779  ac_status=$?
5780  grep -v '^ *+' conftest.er1 >conftest.err
5781  rm -f conftest.er1
5782  cat conftest.err >&5
5783  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5784  (exit $ac_status); } && {
5785	 test -z "$ac_c_werror_flag" ||
5786	 test ! -s conftest.err
5787       } && test -s conftest.$ac_objext; then
5788  ac_cv_sys_large_files=1; break
5789else
5790  echo "$as_me: failed program was:" >&5
5791sed 's/^/| /' conftest.$ac_ext >&5
5792
5793
5794fi
5795
5796rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5797  ac_cv_sys_large_files=unknown
5798  break
5799done
5800fi
5801{ echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
5802echo "${ECHO_T}$ac_cv_sys_large_files" >&6; }
5803case $ac_cv_sys_large_files in #(
5804  no | unknown) ;;
5805  *)
5806cat >>confdefs.h <<_ACEOF
5807#define _LARGE_FILES $ac_cv_sys_large_files
5808_ACEOF
5809;;
5810esac
5811rm -f conftest*
5812  fi
5813fi
5814
5815
5816
5817### The standard library on x86-64 GNU/Linux distributions can
5818### be located in either /usr/lib64 or /usr/lib.
5819case "${canonical}" in
5820  x86_64-*-linux-gnu* )
5821    if test -d /usr/lib64; then
5822
5823cat >>confdefs.h <<\_ACEOF
5824#define HAVE_X86_64_LIB64_DIR 1
5825_ACEOF
5826
5827fi
5828esac
5829
5830
5831
5832
5833if test "${with_sound}" != "no"; then
5834  # Sound support for GNU/Linux and the free BSDs.
5835  { echo "$as_me:$LINENO: checking for ANSI C header files" >&5
5836echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
5837if test "${ac_cv_header_stdc+set}" = set; then
5838  echo $ECHO_N "(cached) $ECHO_C" >&6
5839else
5840  cat >conftest.$ac_ext <<_ACEOF
5841/* confdefs.h.  */
5842_ACEOF
5843cat confdefs.h >>conftest.$ac_ext
5844cat >>conftest.$ac_ext <<_ACEOF
5845/* end confdefs.h.  */
5846#include <stdlib.h>
5847#include <stdarg.h>
5848#include <string.h>
5849#include <float.h>
5850
5851int
5852main ()
5853{
5854
5855  ;
5856  return 0;
5857}
5858_ACEOF
5859rm -f conftest.$ac_objext
5860if { (ac_try="$ac_compile"
5861case "(($ac_try" in
5862  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5863  *) ac_try_echo=$ac_try;;
5864esac
5865eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5866  (eval "$ac_compile") 2>conftest.er1
5867  ac_status=$?
5868  grep -v '^ *+' conftest.er1 >conftest.err
5869  rm -f conftest.er1
5870  cat conftest.err >&5
5871  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5872  (exit $ac_status); } && {
5873	 test -z "$ac_c_werror_flag" ||
5874	 test ! -s conftest.err
5875       } && test -s conftest.$ac_objext; then
5876  ac_cv_header_stdc=yes
5877else
5878  echo "$as_me: failed program was:" >&5
5879sed 's/^/| /' conftest.$ac_ext >&5
5880
5881	ac_cv_header_stdc=no
5882fi
5883
5884rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5885
5886if test $ac_cv_header_stdc = yes; then
5887  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5888  cat >conftest.$ac_ext <<_ACEOF
5889/* confdefs.h.  */
5890_ACEOF
5891cat confdefs.h >>conftest.$ac_ext
5892cat >>conftest.$ac_ext <<_ACEOF
5893/* end confdefs.h.  */
5894#include <string.h>
5895
5896_ACEOF
5897if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5898  $EGREP "memchr" >/dev/null 2>&1; then
5899  :
5900else
5901  ac_cv_header_stdc=no
5902fi
5903rm -f conftest*
5904
5905fi
5906
5907if test $ac_cv_header_stdc = yes; then
5908  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5909  cat >conftest.$ac_ext <<_ACEOF
5910/* confdefs.h.  */
5911_ACEOF
5912cat confdefs.h >>conftest.$ac_ext
5913cat >>conftest.$ac_ext <<_ACEOF
5914/* end confdefs.h.  */
5915#include <stdlib.h>
5916
5917_ACEOF
5918if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5919  $EGREP "free" >/dev/null 2>&1; then
5920  :
5921else
5922  ac_cv_header_stdc=no
5923fi
5924rm -f conftest*
5925
5926fi
5927
5928if test $ac_cv_header_stdc = yes; then
5929  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5930  if test "$cross_compiling" = yes; then
5931  :
5932else
5933  cat >conftest.$ac_ext <<_ACEOF
5934/* confdefs.h.  */
5935_ACEOF
5936cat confdefs.h >>conftest.$ac_ext
5937cat >>conftest.$ac_ext <<_ACEOF
5938/* end confdefs.h.  */
5939#include <ctype.h>
5940#include <stdlib.h>
5941#if ((' ' & 0x0FF) == 0x020)
5942# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5943# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5944#else
5945# define ISLOWER(c) \
5946		   (('a' <= (c) && (c) <= 'i') \
5947		     || ('j' <= (c) && (c) <= 'r') \
5948		     || ('s' <= (c) && (c) <= 'z'))
5949# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5950#endif
5951
5952#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5953int
5954main ()
5955{
5956  int i;
5957  for (i = 0; i < 256; i++)
5958    if (XOR (islower (i), ISLOWER (i))
5959	|| toupper (i) != TOUPPER (i))
5960      return 2;
5961  return 0;
5962}
5963_ACEOF
5964rm -f conftest$ac_exeext
5965if { (ac_try="$ac_link"
5966case "(($ac_try" in
5967  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5968  *) ac_try_echo=$ac_try;;
5969esac
5970eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5971  (eval "$ac_link") 2>&5
5972  ac_status=$?
5973  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5974  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5975  { (case "(($ac_try" in
5976  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5977  *) ac_try_echo=$ac_try;;
5978esac
5979eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5980  (eval "$ac_try") 2>&5
5981  ac_status=$?
5982  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5983  (exit $ac_status); }; }; then
5984  :
5985else
5986  echo "$as_me: program exited with status $ac_status" >&5
5987echo "$as_me: failed program was:" >&5
5988sed 's/^/| /' conftest.$ac_ext >&5
5989
5990( exit $ac_status )
5991ac_cv_header_stdc=no
5992fi
5993rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5994fi
5995
5996
5997fi
5998fi
5999{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
6000echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
6001if test $ac_cv_header_stdc = yes; then
6002
6003cat >>confdefs.h <<\_ACEOF
6004#define STDC_HEADERS 1
6005_ACEOF
6006
6007fi
6008
6009# On IRIX 5.3, sys/types and inttypes.h are conflicting.
6010
6011
6012
6013
6014
6015
6016
6017
6018
6019for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6020		  inttypes.h stdint.h unistd.h
6021do
6022as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6023{ echo "$as_me:$LINENO: checking for $ac_header" >&5
6024echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
6025if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6026  echo $ECHO_N "(cached) $ECHO_C" >&6
6027else
6028  cat >conftest.$ac_ext <<_ACEOF
6029/* confdefs.h.  */
6030_ACEOF
6031cat confdefs.h >>conftest.$ac_ext
6032cat >>conftest.$ac_ext <<_ACEOF
6033/* end confdefs.h.  */
6034$ac_includes_default
6035
6036#include <$ac_header>
6037_ACEOF
6038rm -f conftest.$ac_objext
6039if { (ac_try="$ac_compile"
6040case "(($ac_try" in
6041  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6042  *) ac_try_echo=$ac_try;;
6043esac
6044eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6045  (eval "$ac_compile") 2>conftest.er1
6046  ac_status=$?
6047  grep -v '^ *+' conftest.er1 >conftest.err
6048  rm -f conftest.er1
6049  cat conftest.err >&5
6050  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6051  (exit $ac_status); } && {
6052	 test -z "$ac_c_werror_flag" ||
6053	 test ! -s conftest.err
6054       } && test -s conftest.$ac_objext; then
6055  eval "$as_ac_Header=yes"
6056else
6057  echo "$as_me: failed program was:" >&5
6058sed 's/^/| /' conftest.$ac_ext >&5
6059
6060	eval "$as_ac_Header=no"
6061fi
6062
6063rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6064fi
6065ac_res=`eval echo '${'$as_ac_Header'}'`
6066	       { echo "$as_me:$LINENO: result: $ac_res" >&5
6067echo "${ECHO_T}$ac_res" >&6; }
6068if test `eval echo '${'$as_ac_Header'}'` = yes; then
6069  cat >>confdefs.h <<_ACEOF
6070#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6071_ACEOF
6072
6073fi
6074
6075done
6076
6077
6078
6079
6080
6081for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
6082do
6083as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6084if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6085  { echo "$as_me:$LINENO: checking for $ac_header" >&5
6086echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
6087if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6088  echo $ECHO_N "(cached) $ECHO_C" >&6
6089fi
6090ac_res=`eval echo '${'$as_ac_Header'}'`
6091	       { echo "$as_me:$LINENO: result: $ac_res" >&5
6092echo "${ECHO_T}$ac_res" >&6; }
6093else
6094  # Is the header compilable?
6095{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
6096echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
6097cat >conftest.$ac_ext <<_ACEOF
6098/* confdefs.h.  */
6099_ACEOF
6100cat confdefs.h >>conftest.$ac_ext
6101cat >>conftest.$ac_ext <<_ACEOF
6102/* end confdefs.h.  */
6103$ac_includes_default
6104#include <$ac_header>
6105_ACEOF
6106rm -f conftest.$ac_objext
6107if { (ac_try="$ac_compile"
6108case "(($ac_try" in
6109  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6110  *) ac_try_echo=$ac_try;;
6111esac
6112eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6113  (eval "$ac_compile") 2>conftest.er1
6114  ac_status=$?
6115  grep -v '^ *+' conftest.er1 >conftest.err
6116  rm -f conftest.er1
6117  cat conftest.err >&5
6118  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6119  (exit $ac_status); } && {
6120	 test -z "$ac_c_werror_flag" ||
6121	 test ! -s conftest.err
6122       } && test -s conftest.$ac_objext; then
6123  ac_header_compiler=yes
6124else
6125  echo "$as_me: failed program was:" >&5
6126sed 's/^/| /' conftest.$ac_ext >&5
6127
6128	ac_header_compiler=no
6129fi
6130
6131rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6132{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6133echo "${ECHO_T}$ac_header_compiler" >&6; }
6134
6135# Is the header present?
6136{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
6137echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
6138cat >conftest.$ac_ext <<_ACEOF
6139/* confdefs.h.  */
6140_ACEOF
6141cat confdefs.h >>conftest.$ac_ext
6142cat >>conftest.$ac_ext <<_ACEOF
6143/* end confdefs.h.  */
6144#include <$ac_header>
6145_ACEOF
6146if { (ac_try="$ac_cpp conftest.$ac_ext"
6147case "(($ac_try" in
6148  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6149  *) ac_try_echo=$ac_try;;
6150esac
6151eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6152  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
6153  ac_status=$?
6154  grep -v '^ *+' conftest.er1 >conftest.err
6155  rm -f conftest.er1
6156  cat conftest.err >&5
6157  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6158  (exit $ac_status); } >/dev/null && {
6159	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6160	 test ! -s conftest.err
6161       }; then
6162  ac_header_preproc=yes
6163else
6164  echo "$as_me: failed program was:" >&5
6165sed 's/^/| /' conftest.$ac_ext >&5
6166
6167  ac_header_preproc=no
6168fi
6169
6170rm -f conftest.err conftest.$ac_ext
6171{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6172echo "${ECHO_T}$ac_header_preproc" >&6; }
6173
6174# So?  What about this header?
6175case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6176  yes:no: )
6177    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6178echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6179    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6180echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6181    ac_header_preproc=yes
6182    ;;
6183  no:yes:* )
6184    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6185echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6186    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
6187echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
6188    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6189echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6190    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
6191echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
6192    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6193echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6194    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6195echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6196
6197    ;;
6198esac
6199{ echo "$as_me:$LINENO: checking for $ac_header" >&5
6200echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
6201if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6202  echo $ECHO_N "(cached) $ECHO_C" >&6
6203else
6204  eval "$as_ac_Header=\$ac_header_preproc"
6205fi
6206ac_res=`eval echo '${'$as_ac_Header'}'`
6207	       { echo "$as_me:$LINENO: result: $ac_res" >&5
6208echo "${ECHO_T}$ac_res" >&6; }
6209
6210fi
6211if test `eval echo '${'$as_ac_Header'}'` = yes; then
6212  cat >>confdefs.h <<_ACEOF
6213#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6214_ACEOF
6215
6216fi
6217
6218done
6219
6220  # Emulation library used on NetBSD.
6221  { echo "$as_me:$LINENO: checking for _oss_ioctl in -lossaudio" >&5
6222echo $ECHO_N "checking for _oss_ioctl in -lossaudio... $ECHO_C" >&6; }
6223if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then
6224  echo $ECHO_N "(cached) $ECHO_C" >&6
6225else
6226  ac_check_lib_save_LIBS=$LIBS
6227LIBS="-lossaudio  $LIBS"
6228cat >conftest.$ac_ext <<_ACEOF
6229/* confdefs.h.  */
6230_ACEOF
6231cat confdefs.h >>conftest.$ac_ext
6232cat >>conftest.$ac_ext <<_ACEOF
6233/* end confdefs.h.  */
6234
6235/* Override any GCC internal prototype to avoid an error.
6236   Use char because int might match the return type of a GCC
6237   builtin and then its argument prototype would still apply.  */
6238#ifdef __cplusplus
6239extern "C"
6240#endif
6241char _oss_ioctl ();
6242int
6243main ()
6244{
6245return _oss_ioctl ();
6246  ;
6247  return 0;
6248}
6249_ACEOF
6250rm -f conftest.$ac_objext conftest$ac_exeext
6251if { (ac_try="$ac_link"
6252case "(($ac_try" in
6253  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6254  *) ac_try_echo=$ac_try;;
6255esac
6256eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6257  (eval "$ac_link") 2>conftest.er1
6258  ac_status=$?
6259  grep -v '^ *+' conftest.er1 >conftest.err
6260  rm -f conftest.er1
6261  cat conftest.err >&5
6262  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6263  (exit $ac_status); } && {
6264	 test -z "$ac_c_werror_flag" ||
6265	 test ! -s conftest.err
6266       } && test -s conftest$ac_exeext &&
6267       $as_test_x conftest$ac_exeext; then
6268  ac_cv_lib_ossaudio__oss_ioctl=yes
6269else
6270  echo "$as_me: failed program was:" >&5
6271sed 's/^/| /' conftest.$ac_ext >&5
6272
6273	ac_cv_lib_ossaudio__oss_ioctl=no
6274fi
6275
6276rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6277      conftest$ac_exeext conftest.$ac_ext
6278LIBS=$ac_check_lib_save_LIBS
6279fi
6280{ echo "$as_me:$LINENO: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
6281echo "${ECHO_T}$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
6282if test $ac_cv_lib_ossaudio__oss_ioctl = yes; then
6283  LIBSOUND=-lossaudio
6284else
6285  LIBSOUND=
6286fi
6287
6288
6289
6290  ALSA_REQUIRED=1.0.0
6291  ALSA_MODULES="alsa >= $ALSA_REQUIRED"
6292    if test "X${with_pkg_config_prog}" != X; then
6293    PKG_CONFIG="${with_pkg_config_prog}"
6294  fi
6295
6296  succeeded=no
6297
6298  if test -z "$PKG_CONFIG"; then
6299    # Extract the first word of "pkg-config", so it can be a program name with args.
6300set dummy pkg-config; ac_word=$2
6301{ echo "$as_me:$LINENO: checking for $ac_word" >&5
6302echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
6303if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
6304  echo $ECHO_N "(cached) $ECHO_C" >&6
6305else
6306  case $PKG_CONFIG in
6307  [\\/]* | ?:[\\/]*)
6308  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
6309  ;;
6310  *)
6311  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6312for as_dir in $PATH
6313do
6314  IFS=$as_save_IFS
6315  test -z "$as_dir" && as_dir=.
6316  for ac_exec_ext in '' $ac_executable_extensions; do
6317  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6318    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
6319    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6320    break 2
6321  fi
6322done
6323done
6324IFS=$as_save_IFS
6325
6326  test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
6327  ;;
6328esac
6329fi
6330PKG_CONFIG=$ac_cv_path_PKG_CONFIG
6331if test -n "$PKG_CONFIG"; then
6332  { echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
6333echo "${ECHO_T}$PKG_CONFIG" >&6; }
6334else
6335  { echo "$as_me:$LINENO: result: no" >&5
6336echo "${ECHO_T}no" >&6; }
6337fi
6338
6339
6340  fi
6341
6342  if test "$PKG_CONFIG" = "no" ; then
6343     HAVE_ALSA=no
6344  else
6345     PKG_CONFIG_MIN_VERSION=0.9.0
6346     if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
6347        { echo "$as_me:$LINENO: checking for $ALSA_MODULES" >&5
6348echo $ECHO_N "checking for $ALSA_MODULES... $ECHO_C" >&6; }
6349
6350        if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5; then
6351            { echo "$as_me:$LINENO: result: yes" >&5
6352echo "${ECHO_T}yes" >&6; }
6353            succeeded=yes
6354
6355            { echo "$as_me:$LINENO: checking ALSA_CFLAGS" >&5
6356echo $ECHO_N "checking ALSA_CFLAGS... $ECHO_C" >&6; }
6357            ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES"|sed -e 's,///*,/,g'`
6358            { echo "$as_me:$LINENO: result: $ALSA_CFLAGS" >&5
6359echo "${ECHO_T}$ALSA_CFLAGS" >&6; }
6360
6361            { echo "$as_me:$LINENO: checking ALSA_LIBS" >&5
6362echo $ECHO_N "checking ALSA_LIBS... $ECHO_C" >&6; }
6363            ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES"|sed -e 's,///*,/,g'`
6364            { echo "$as_me:$LINENO: result: $ALSA_LIBS" >&5
6365echo "${ECHO_T}$ALSA_LIBS" >&6; }
6366        else
6367            { echo "$as_me:$LINENO: result: no" >&5
6368echo "${ECHO_T}no" >&6; }
6369            ALSA_CFLAGS=""
6370            ALSA_LIBS=""
6371            ## If we have a custom action on failure, don't print errors, but
6372            ## do set a variable so people can do so.
6373            ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
6374
6375        fi
6376
6377
6378
6379     else
6380        echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
6381        echo "*** See http://www.freedesktop.org/software/pkgconfig"
6382     fi
6383  fi
6384
6385  if test $succeeded = yes; then
6386     HAVE_ALSA=yes
6387  else
6388     HAVE_ALSA=no
6389  fi
6390
6391  if test $HAVE_ALSA = yes; then
6392    SAVE_CFLAGS="$CFLAGS"
6393    SAVE_LDFLAGS="$LDFLAGS"
6394    CFLAGS="$ALSA_CFLAGS $CFLAGS"
6395    LDFLAGS="$ALSA_LIBS $LDFLAGS"
6396    cat >conftest.$ac_ext <<_ACEOF
6397/* confdefs.h.  */
6398_ACEOF
6399cat confdefs.h >>conftest.$ac_ext
6400cat >>conftest.$ac_ext <<_ACEOF
6401/* end confdefs.h.  */
6402#include <asoundlib.h>
6403int
6404main ()
6405{
6406snd_lib_error_set_handler (0);
6407  ;
6408  return 0;
6409}
6410_ACEOF
6411rm -f conftest.$ac_objext
6412if { (ac_try="$ac_compile"
6413case "(($ac_try" in
6414  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6415  *) ac_try_echo=$ac_try;;
6416esac
6417eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6418  (eval "$ac_compile") 2>conftest.er1
6419  ac_status=$?
6420  grep -v '^ *+' conftest.er1 >conftest.err
6421  rm -f conftest.er1
6422  cat conftest.err >&5
6423  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6424  (exit $ac_status); } && {
6425	 test -z "$ac_c_werror_flag" ||
6426	 test ! -s conftest.err
6427       } && test -s conftest.$ac_objext; then
6428  emacs_alsa_normal=yes
6429else
6430  echo "$as_me: failed program was:" >&5
6431sed 's/^/| /' conftest.$ac_ext >&5
6432
6433	emacs_alsa_normal=no
6434fi
6435
6436rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6437    if test "$emacs_alsa_normal" != yes; then
6438      cat >conftest.$ac_ext <<_ACEOF
6439/* confdefs.h.  */
6440_ACEOF
6441cat confdefs.h >>conftest.$ac_ext
6442cat >>conftest.$ac_ext <<_ACEOF
6443/* end confdefs.h.  */
6444#include <alsa/asoundlib.h>
6445int
6446main ()
6447{
6448snd_lib_error_set_handler (0);
6449  ;
6450  return 0;
6451}
6452_ACEOF
6453rm -f conftest.$ac_objext
6454if { (ac_try="$ac_compile"
6455case "(($ac_try" in
6456  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6457  *) ac_try_echo=$ac_try;;
6458esac
6459eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6460  (eval "$ac_compile") 2>conftest.er1
6461  ac_status=$?
6462  grep -v '^ *+' conftest.er1 >conftest.err
6463  rm -f conftest.er1
6464  cat conftest.err >&5
6465  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6466  (exit $ac_status); } && {
6467	 test -z "$ac_c_werror_flag" ||
6468	 test ! -s conftest.err
6469       } && test -s conftest.$ac_objext; then
6470  emacs_alsa_subdir=yes
6471else
6472  echo "$as_me: failed program was:" >&5
6473sed 's/^/| /' conftest.$ac_ext >&5
6474
6475	emacs_alsa_subdir=no
6476fi
6477
6478rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6479      if test "$emacs_alsa_subdir" != yes; then
6480        { { echo "$as_me:$LINENO: error: pkg-config found alsa, but it does not compile.  See config.log for error messages." >&5
6481echo "$as_me: error: pkg-config found alsa, but it does not compile.  See config.log for error messages." >&2;}
6482   { (exit 1); exit 1; }; }
6483      fi
6484      ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
6485    fi
6486
6487    CFLAGS="$SAVE_CFLAGS"
6488    LDFLAGS="$SAVE_LDFLAGS"
6489    LIBSOUND="$LIBSOUND $ALSA_LIBS"
6490    CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
6491
6492cat >>confdefs.h <<\_ACEOF
6493#define HAVE_ALSA 1
6494_ACEOF
6495
6496  fi
6497
6498fi
6499
6500
6501
6502
6503
6504
6505
6506
6507
6508
6509
6510
6511
6512
6513
6514
6515
6516
6517
6518
6519
6520
6521
6522
6523
6524
6525for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
6526  linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
6527  termcap.h stdio_ext.h fcntl.h strings.h coff.h pty.h sys/mman.h \
6528  sys/param.h sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \
6529  sys/utsname.h pwd.h
6530do
6531as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6532if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6533  { echo "$as_me:$LINENO: checking for $ac_header" >&5
6534echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
6535if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6536  echo $ECHO_N "(cached) $ECHO_C" >&6
6537fi
6538ac_res=`eval echo '${'$as_ac_Header'}'`
6539	       { echo "$as_me:$LINENO: result: $ac_res" >&5
6540echo "${ECHO_T}$ac_res" >&6; }
6541else
6542  # Is the header compilable?
6543{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
6544echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
6545cat >conftest.$ac_ext <<_ACEOF
6546/* confdefs.h.  */
6547_ACEOF
6548cat confdefs.h >>conftest.$ac_ext
6549cat >>conftest.$ac_ext <<_ACEOF
6550/* end confdefs.h.  */
6551$ac_includes_default
6552#include <$ac_header>
6553_ACEOF
6554rm -f conftest.$ac_objext
6555if { (ac_try="$ac_compile"
6556case "(($ac_try" in
6557  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6558  *) ac_try_echo=$ac_try;;
6559esac
6560eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6561  (eval "$ac_compile") 2>conftest.er1
6562  ac_status=$?
6563  grep -v '^ *+' conftest.er1 >conftest.err
6564  rm -f conftest.er1
6565  cat conftest.err >&5
6566  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6567  (exit $ac_status); } && {
6568	 test -z "$ac_c_werror_flag" ||
6569	 test ! -s conftest.err
6570       } && test -s conftest.$ac_objext; then
6571  ac_header_compiler=yes
6572else
6573  echo "$as_me: failed program was:" >&5
6574sed 's/^/| /' conftest.$ac_ext >&5
6575
6576	ac_header_compiler=no
6577fi
6578
6579rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6580{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6581echo "${ECHO_T}$ac_header_compiler" >&6; }
6582
6583# Is the header present?
6584{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
6585echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
6586cat >conftest.$ac_ext <<_ACEOF
6587/* confdefs.h.  */
6588_ACEOF
6589cat confdefs.h >>conftest.$ac_ext
6590cat >>conftest.$ac_ext <<_ACEOF
6591/* end confdefs.h.  */
6592#include <$ac_header>
6593_ACEOF
6594if { (ac_try="$ac_cpp conftest.$ac_ext"
6595case "(($ac_try" in
6596  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6597  *) ac_try_echo=$ac_try;;
6598esac
6599eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6600  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
6601  ac_status=$?
6602  grep -v '^ *+' conftest.er1 >conftest.err
6603  rm -f conftest.er1
6604  cat conftest.err >&5
6605  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6606  (exit $ac_status); } >/dev/null && {
6607	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6608	 test ! -s conftest.err
6609       }; then
6610  ac_header_preproc=yes
6611else
6612  echo "$as_me: failed program was:" >&5
6613sed 's/^/| /' conftest.$ac_ext >&5
6614
6615  ac_header_preproc=no
6616fi
6617
6618rm -f conftest.err conftest.$ac_ext
6619{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6620echo "${ECHO_T}$ac_header_preproc" >&6; }
6621
6622# So?  What about this header?
6623case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6624  yes:no: )
6625    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6626echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6627    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6628echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6629    ac_header_preproc=yes
6630    ;;
6631  no:yes:* )
6632    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6633echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6634    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
6635echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
6636    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6637echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6638    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
6639echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
6640    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6641echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6642    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6643echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6644
6645    ;;
6646esac
6647{ echo "$as_me:$LINENO: checking for $ac_header" >&5
6648echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
6649if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6650  echo $ECHO_N "(cached) $ECHO_C" >&6
6651else
6652  eval "$as_ac_Header=\$ac_header_preproc"
6653fi
6654ac_res=`eval echo '${'$as_ac_Header'}'`
6655	       { echo "$as_me:$LINENO: result: $ac_res" >&5
6656echo "${ECHO_T}$ac_res" >&6; }
6657
6658fi
6659if test `eval echo '${'$as_ac_Header'}'` = yes; then
6660  cat >>confdefs.h <<_ACEOF
6661#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6662_ACEOF
6663
6664fi
6665
6666done
6667
6668
6669{ echo "$as_me:$LINENO: checking if personality LINUX32 can be set" >&5
6670echo $ECHO_N "checking if personality LINUX32 can be set... $ECHO_C" >&6; }
6671cat >conftest.$ac_ext <<_ACEOF
6672/* confdefs.h.  */
6673_ACEOF
6674cat confdefs.h >>conftest.$ac_ext
6675cat >>conftest.$ac_ext <<_ACEOF
6676/* end confdefs.h.  */
6677#include <sys/personality.h>
6678int
6679main ()
6680{
6681personality (PER_LINUX32)
6682  ;
6683  return 0;
6684}
6685_ACEOF
6686rm -f conftest.$ac_objext
6687if { (ac_try="$ac_compile"
6688case "(($ac_try" in
6689  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6690  *) ac_try_echo=$ac_try;;
6691esac
6692eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6693  (eval "$ac_compile") 2>conftest.er1
6694  ac_status=$?
6695  grep -v '^ *+' conftest.er1 >conftest.err
6696  rm -f conftest.er1
6697  cat conftest.err >&5
6698  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6699  (exit $ac_status); } && {
6700	 test -z "$ac_c_werror_flag" ||
6701	 test ! -s conftest.err
6702       } && test -s conftest.$ac_objext; then
6703  emacs_cv_personality_linux32=yes
6704else
6705  echo "$as_me: failed program was:" >&5
6706sed 's/^/| /' conftest.$ac_ext >&5
6707
6708	emacs_cv_personality_linux32=no
6709fi
6710
6711rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6712{ echo "$as_me:$LINENO: result: $emacs_cv_personality_linux32" >&5
6713echo "${ECHO_T}$emacs_cv_personality_linux32" >&6; }
6714
6715if test $emacs_cv_personality_linux32 = yes; then
6716
6717cat >>confdefs.h <<\_ACEOF
6718#define HAVE_PERSONALITY_LINUX32 1
6719_ACEOF
6720
6721fi
6722
6723
6724for ac_header in term.h
6725do
6726as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6727{ echo "$as_me:$LINENO: checking for $ac_header" >&5
6728echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
6729if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6730  echo $ECHO_N "(cached) $ECHO_C" >&6
6731else
6732  cat >conftest.$ac_ext <<_ACEOF
6733/* confdefs.h.  */
6734_ACEOF
6735cat confdefs.h >>conftest.$ac_ext
6736cat >>conftest.$ac_ext <<_ACEOF
6737/* end confdefs.h.  */
6738#include <$ac_header>
6739_ACEOF
6740if { (ac_try="$ac_cpp conftest.$ac_ext"
6741case "(($ac_try" in
6742  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6743  *) ac_try_echo=$ac_try;;
6744esac
6745eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6746  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
6747  ac_status=$?
6748  grep -v '^ *+' conftest.er1 >conftest.err
6749  rm -f conftest.er1
6750  cat conftest.err >&5
6751  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6752  (exit $ac_status); } >/dev/null && {
6753	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6754	 test ! -s conftest.err
6755       }; then
6756  eval "$as_ac_Header=yes"
6757else
6758  echo "$as_me: failed program was:" >&5
6759sed 's/^/| /' conftest.$ac_ext >&5
6760
6761  eval "$as_ac_Header=no"
6762fi
6763
6764rm -f conftest.err conftest.$ac_ext
6765fi
6766ac_res=`eval echo '${'$as_ac_Header'}'`
6767	       { echo "$as_me:$LINENO: result: $ac_res" >&5
6768echo "${ECHO_T}$ac_res" >&6; }
6769if test `eval echo '${'$as_ac_Header'}'` = yes; then
6770  cat >>confdefs.h <<_ACEOF
6771#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6772_ACEOF
6773
6774fi
6775
6776done
6777
6778{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5
6779echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
6780if test "${ac_cv_header_stdc+set}" = set; then
6781  echo $ECHO_N "(cached) $ECHO_C" >&6
6782else
6783  cat >conftest.$ac_ext <<_ACEOF
6784/* confdefs.h.  */
6785_ACEOF
6786cat confdefs.h >>conftest.$ac_ext
6787cat >>conftest.$ac_ext <<_ACEOF
6788/* end confdefs.h.  */
6789#include <stdlib.h>
6790#include <stdarg.h>
6791#include <string.h>
6792#include <float.h>
6793
6794int
6795main ()
6796{
6797
6798  ;
6799  return 0;
6800}
6801_ACEOF
6802rm -f conftest.$ac_objext
6803if { (ac_try="$ac_compile"
6804case "(($ac_try" in
6805  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6806  *) ac_try_echo=$ac_try;;
6807esac
6808eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6809  (eval "$ac_compile") 2>conftest.er1
6810  ac_status=$?
6811  grep -v '^ *+' conftest.er1 >conftest.err
6812  rm -f conftest.er1
6813  cat conftest.err >&5
6814  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6815  (exit $ac_status); } && {
6816	 test -z "$ac_c_werror_flag" ||
6817	 test ! -s conftest.err
6818       } && test -s conftest.$ac_objext; then
6819  ac_cv_header_stdc=yes
6820else
6821  echo "$as_me: failed program was:" >&5
6822sed 's/^/| /' conftest.$ac_ext >&5
6823
6824	ac_cv_header_stdc=no
6825fi
6826
6827rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6828
6829if test $ac_cv_header_stdc = yes; then
6830  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6831  cat >conftest.$ac_ext <<_ACEOF
6832/* confdefs.h.  */
6833_ACEOF
6834cat confdefs.h >>conftest.$ac_ext
6835cat >>conftest.$ac_ext <<_ACEOF
6836/* end confdefs.h.  */
6837#include <string.h>
6838
6839_ACEOF
6840if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6841  $EGREP "memchr" >/dev/null 2>&1; then
6842  :
6843else
6844  ac_cv_header_stdc=no
6845fi
6846rm -f conftest*
6847
6848fi
6849
6850if test $ac_cv_header_stdc = yes; then
6851  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6852  cat >conftest.$ac_ext <<_ACEOF
6853/* confdefs.h.  */
6854_ACEOF
6855cat confdefs.h >>conftest.$ac_ext
6856cat >>conftest.$ac_ext <<_ACEOF
6857/* end confdefs.h.  */
6858#include <stdlib.h>
6859
6860_ACEOF
6861if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6862  $EGREP "free" >/dev/null 2>&1; then
6863  :
6864else
6865  ac_cv_header_stdc=no
6866fi
6867rm -f conftest*
6868
6869fi
6870
6871if test $ac_cv_header_stdc = yes; then
6872  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6873  if test "$cross_compiling" = yes; then
6874  :
6875else
6876  cat >conftest.$ac_ext <<_ACEOF
6877/* confdefs.h.  */
6878_ACEOF
6879cat confdefs.h >>conftest.$ac_ext
6880cat >>conftest.$ac_ext <<_ACEOF
6881/* end confdefs.h.  */
6882#include <ctype.h>
6883#include <stdlib.h>
6884#if ((' ' & 0x0FF) == 0x020)
6885# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6886# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6887#else
6888# define ISLOWER(c) \
6889		   (('a' <= (c) && (c) <= 'i') \
6890		     || ('j' <= (c) && (c) <= 'r') \
6891		     || ('s' <= (c) && (c) <= 'z'))
6892# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6893#endif
6894
6895#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6896int
6897main ()
6898{
6899  int i;
6900  for (i = 0; i < 256; i++)
6901    if (XOR (islower (i), ISLOWER (i))
6902	|| toupper (i) != TOUPPER (i))
6903      return 2;
6904  return 0;
6905}
6906_ACEOF
6907rm -f conftest$ac_exeext
6908if { (ac_try="$ac_link"
6909case "(($ac_try" in
6910  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6911  *) ac_try_echo=$ac_try;;
6912esac
6913eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6914  (eval "$ac_link") 2>&5
6915  ac_status=$?
6916  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6917  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6918  { (case "(($ac_try" in
6919  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6920  *) ac_try_echo=$ac_try;;
6921esac
6922eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6923  (eval "$ac_try") 2>&5
6924  ac_status=$?
6925  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6926  (exit $ac_status); }; }; then
6927  :
6928else
6929  echo "$as_me: program exited with status $ac_status" >&5
6930echo "$as_me: failed program was:" >&5
6931sed 's/^/| /' conftest.$ac_ext >&5
6932
6933( exit $ac_status )
6934ac_cv_header_stdc=no
6935fi
6936rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6937fi
6938
6939
6940fi
6941fi
6942{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
6943echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
6944if test $ac_cv_header_stdc = yes; then
6945
6946cat >>confdefs.h <<\_ACEOF
6947#define STDC_HEADERS 1
6948_ACEOF
6949
6950fi
6951
6952{ echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
6953echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6; }
6954if test "${ac_cv_header_time+set}" = set; then
6955  echo $ECHO_N "(cached) $ECHO_C" >&6
6956else
6957  cat >conftest.$ac_ext <<_ACEOF
6958/* confdefs.h.  */
6959_ACEOF
6960cat confdefs.h >>conftest.$ac_ext
6961cat >>conftest.$ac_ext <<_ACEOF
6962/* end confdefs.h.  */
6963#include <sys/types.h>
6964#include <sys/time.h>
6965#include <time.h>
6966
6967int
6968main ()
6969{
6970if ((struct tm *) 0)
6971return 0;
6972  ;
6973  return 0;
6974}
6975_ACEOF
6976rm -f conftest.$ac_objext
6977if { (ac_try="$ac_compile"
6978case "(($ac_try" in
6979  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6980  *) ac_try_echo=$ac_try;;
6981esac
6982eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6983  (eval "$ac_compile") 2>conftest.er1
6984  ac_status=$?
6985  grep -v '^ *+' conftest.er1 >conftest.err
6986  rm -f conftest.er1
6987  cat conftest.err >&5
6988  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6989  (exit $ac_status); } && {
6990	 test -z "$ac_c_werror_flag" ||
6991	 test ! -s conftest.err
6992       } && test -s conftest.$ac_objext; then
6993  ac_cv_header_time=yes
6994else
6995  echo "$as_me: failed program was:" >&5
6996sed 's/^/| /' conftest.$ac_ext >&5
6997
6998	ac_cv_header_time=no
6999fi
7000
7001rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7002fi
7003{ echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
7004echo "${ECHO_T}$ac_cv_header_time" >&6; }
7005if test $ac_cv_header_time = yes; then
7006
7007cat >>confdefs.h <<\_ACEOF
7008#define TIME_WITH_SYS_TIME 1
7009_ACEOF
7010
7011fi
7012
7013{ echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
7014echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6; }
7015if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
7016  echo $ECHO_N "(cached) $ECHO_C" >&6
7017else
7018  cat >conftest.$ac_ext <<_ACEOF
7019/* confdefs.h.  */
7020_ACEOF
7021cat confdefs.h >>conftest.$ac_ext
7022cat >>conftest.$ac_ext <<_ACEOF
7023/* end confdefs.h.  */
7024$ac_includes_default
7025int
7026main ()
7027{
7028#ifndef sys_siglist
7029  (void) sys_siglist;
7030#endif
7031
7032  ;
7033  return 0;
7034}
7035_ACEOF
7036rm -f conftest.$ac_objext
7037if { (ac_try="$ac_compile"
7038case "(($ac_try" in
7039  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7040  *) ac_try_echo=$ac_try;;
7041esac
7042eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7043  (eval "$ac_compile") 2>conftest.er1
7044  ac_status=$?
7045  grep -v '^ *+' conftest.er1 >conftest.err
7046  rm -f conftest.er1
7047  cat conftest.err >&5
7048  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7049  (exit $ac_status); } && {
7050	 test -z "$ac_c_werror_flag" ||
7051	 test ! -s conftest.err
7052       } && test -s conftest.$ac_objext; then
7053  ac_cv_have_decl_sys_siglist=yes
7054else
7055  echo "$as_me: failed program was:" >&5
7056sed 's/^/| /' conftest.$ac_ext >&5
7057
7058	ac_cv_have_decl_sys_siglist=no
7059fi
7060
7061rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7062fi
7063{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
7064echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6; }
7065if test $ac_cv_have_decl_sys_siglist = yes; then
7066
7067cat >>confdefs.h <<_ACEOF
7068#define HAVE_DECL_SYS_SIGLIST 1
7069_ACEOF
7070
7071
7072else
7073  cat >>confdefs.h <<_ACEOF
7074#define HAVE_DECL_SYS_SIGLIST 0
7075_ACEOF
7076
7077
7078fi
7079
7080
7081if test $ac_cv_have_decl_sys_siglist != yes; then
7082  # For Tru64, at least:
7083  { echo "$as_me:$LINENO: checking whether __sys_siglist is declared" >&5
7084echo $ECHO_N "checking whether __sys_siglist is declared... $ECHO_C" >&6; }
7085if test "${ac_cv_have_decl___sys_siglist+set}" = set; then
7086  echo $ECHO_N "(cached) $ECHO_C" >&6
7087else
7088  cat >conftest.$ac_ext <<_ACEOF
7089/* confdefs.h.  */
7090_ACEOF
7091cat confdefs.h >>conftest.$ac_ext
7092cat >>conftest.$ac_ext <<_ACEOF
7093/* end confdefs.h.  */
7094$ac_includes_default
7095int
7096main ()
7097{
7098#ifndef __sys_siglist
7099  (void) __sys_siglist;
7100#endif
7101
7102  ;
7103  return 0;
7104}
7105_ACEOF
7106rm -f conftest.$ac_objext
7107if { (ac_try="$ac_compile"
7108case "(($ac_try" in
7109  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7110  *) ac_try_echo=$ac_try;;
7111esac
7112eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7113  (eval "$ac_compile") 2>conftest.er1
7114  ac_status=$?
7115  grep -v '^ *+' conftest.er1 >conftest.err
7116  rm -f conftest.er1
7117  cat conftest.err >&5
7118  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7119  (exit $ac_status); } && {
7120	 test -z "$ac_c_werror_flag" ||
7121	 test ! -s conftest.err
7122       } && test -s conftest.$ac_objext; then
7123  ac_cv_have_decl___sys_siglist=yes
7124else
7125  echo "$as_me: failed program was:" >&5
7126sed 's/^/| /' conftest.$ac_ext >&5
7127
7128	ac_cv_have_decl___sys_siglist=no
7129fi
7130
7131rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7132fi
7133{ echo "$as_me:$LINENO: result: $ac_cv_have_decl___sys_siglist" >&5
7134echo "${ECHO_T}$ac_cv_have_decl___sys_siglist" >&6; }
7135if test $ac_cv_have_decl___sys_siglist = yes; then
7136
7137cat >>confdefs.h <<_ACEOF
7138#define HAVE_DECL___SYS_SIGLIST 1
7139_ACEOF
7140
7141
7142else
7143  cat >>confdefs.h <<_ACEOF
7144#define HAVE_DECL___SYS_SIGLIST 0
7145_ACEOF
7146
7147
7148fi
7149
7150
7151  if test $ac_cv_have_decl___sys_siglist = yes; then
7152
7153cat >>confdefs.h <<\_ACEOF
7154#define sys_siglist __sys_siglist
7155_ACEOF
7156
7157  fi
7158fi
7159{ echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
7160echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6; }
7161if test "${ac_cv_header_sys_wait_h+set}" = set; then
7162  echo $ECHO_N "(cached) $ECHO_C" >&6
7163else
7164  cat >conftest.$ac_ext <<_ACEOF
7165/* confdefs.h.  */
7166_ACEOF
7167cat confdefs.h >>conftest.$ac_ext
7168cat >>conftest.$ac_ext <<_ACEOF
7169/* end confdefs.h.  */
7170#include <sys/types.h>
7171#include <sys/wait.h>
7172#ifndef WEXITSTATUS
7173# define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
7174#endif
7175#ifndef WIFEXITED
7176# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
7177#endif
7178
7179int
7180main ()
7181{
7182  int s;
7183  wait (&s);
7184  s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
7185  ;
7186  return 0;
7187}
7188_ACEOF
7189rm -f conftest.$ac_objext
7190if { (ac_try="$ac_compile"
7191case "(($ac_try" in
7192  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7193  *) ac_try_echo=$ac_try;;
7194esac
7195eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7196  (eval "$ac_compile") 2>conftest.er1
7197  ac_status=$?
7198  grep -v '^ *+' conftest.er1 >conftest.err
7199  rm -f conftest.er1
7200  cat conftest.err >&5
7201  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7202  (exit $ac_status); } && {
7203	 test -z "$ac_c_werror_flag" ||
7204	 test ! -s conftest.err
7205       } && test -s conftest.$ac_objext; then
7206  ac_cv_header_sys_wait_h=yes
7207else
7208  echo "$as_me: failed program was:" >&5
7209sed 's/^/| /' conftest.$ac_ext >&5
7210
7211	ac_cv_header_sys_wait_h=no
7212fi
7213
7214rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7215fi
7216{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
7217echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6; }
7218if test $ac_cv_header_sys_wait_h = yes; then
7219
7220cat >>confdefs.h <<\_ACEOF
7221#define HAVE_SYS_WAIT_H 1
7222_ACEOF
7223
7224fi
7225
7226
7227{ echo "$as_me:$LINENO: checking for struct utimbuf" >&5
7228echo $ECHO_N "checking for struct utimbuf... $ECHO_C" >&6; }
7229if test "${emacs_cv_struct_utimbuf+set}" = set; then
7230  echo $ECHO_N "(cached) $ECHO_C" >&6
7231else
7232  cat >conftest.$ac_ext <<_ACEOF
7233/* confdefs.h.  */
7234_ACEOF
7235cat confdefs.h >>conftest.$ac_ext
7236cat >>conftest.$ac_ext <<_ACEOF
7237/* end confdefs.h.  */
7238#ifdef TIME_WITH_SYS_TIME
7239#include <sys/time.h>
7240#include <time.h>
7241#else
7242#ifdef HAVE_SYS_TIME_H
7243#include <sys/time.h>
7244#else
7245#include <time.h>
7246#endif
7247#endif
7248#ifdef HAVE_UTIME_H
7249#include <utime.h>
7250#endif
7251int
7252main ()
7253{
7254static struct utimbuf x; x.actime = x.modtime;
7255  ;
7256  return 0;
7257}
7258_ACEOF
7259rm -f conftest.$ac_objext
7260if { (ac_try="$ac_compile"
7261case "(($ac_try" in
7262  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7263  *) ac_try_echo=$ac_try;;
7264esac
7265eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7266  (eval "$ac_compile") 2>conftest.er1
7267  ac_status=$?
7268  grep -v '^ *+' conftest.er1 >conftest.err
7269  rm -f conftest.er1
7270  cat conftest.err >&5
7271  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7272  (exit $ac_status); } && {
7273	 test -z "$ac_c_werror_flag" ||
7274	 test ! -s conftest.err
7275       } && test -s conftest.$ac_objext; then
7276  emacs_cv_struct_utimbuf=yes
7277else
7278  echo "$as_me: failed program was:" >&5
7279sed 's/^/| /' conftest.$ac_ext >&5
7280
7281	emacs_cv_struct_utimbuf=no
7282fi
7283
7284rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7285fi
7286{ echo "$as_me:$LINENO: result: $emacs_cv_struct_utimbuf" >&5
7287echo "${ECHO_T}$emacs_cv_struct_utimbuf" >&6; }
7288if test $emacs_cv_struct_utimbuf = yes; then
7289
7290cat >>confdefs.h <<\_ACEOF
7291#define HAVE_STRUCT_UTIMBUF 1
7292_ACEOF
7293
7294fi
7295
7296{ echo "$as_me:$LINENO: checking return type of signal handlers" >&5
7297echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6; }
7298if test "${ac_cv_type_signal+set}" = set; then
7299  echo $ECHO_N "(cached) $ECHO_C" >&6
7300else
7301  cat >conftest.$ac_ext <<_ACEOF
7302/* confdefs.h.  */
7303_ACEOF
7304cat confdefs.h >>conftest.$ac_ext
7305cat >>conftest.$ac_ext <<_ACEOF
7306/* end confdefs.h.  */
7307#include <sys/types.h>
7308#include <signal.h>
7309
7310int
7311main ()
7312{
7313return *(signal (0, 0)) (0) == 1;
7314  ;
7315  return 0;
7316}
7317_ACEOF
7318rm -f conftest.$ac_objext
7319if { (ac_try="$ac_compile"
7320case "(($ac_try" in
7321  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7322  *) ac_try_echo=$ac_try;;
7323esac
7324eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7325  (eval "$ac_compile") 2>conftest.er1
7326  ac_status=$?
7327  grep -v '^ *+' conftest.er1 >conftest.err
7328  rm -f conftest.er1
7329  cat conftest.err >&5
7330  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7331  (exit $ac_status); } && {
7332	 test -z "$ac_c_werror_flag" ||
7333	 test ! -s conftest.err
7334       } && test -s conftest.$ac_objext; then
7335  ac_cv_type_signal=int
7336else
7337  echo "$as_me: failed program was:" >&5
7338sed 's/^/| /' conftest.$ac_ext >&5
7339
7340	ac_cv_type_signal=void
7341fi
7342
7343rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7344fi
7345{ echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
7346echo "${ECHO_T}$ac_cv_type_signal" >&6; }
7347
7348cat >>confdefs.h <<_ACEOF
7349#define RETSIGTYPE $ac_cv_type_signal
7350_ACEOF
7351
7352
7353
7354{ echo "$as_me:$LINENO: checking for speed_t" >&5
7355echo $ECHO_N "checking for speed_t... $ECHO_C" >&6; }
7356if test "${emacs_cv_speed_t+set}" = set; then
7357  echo $ECHO_N "(cached) $ECHO_C" >&6
7358else
7359  cat >conftest.$ac_ext <<_ACEOF
7360/* confdefs.h.  */
7361_ACEOF
7362cat confdefs.h >>conftest.$ac_ext
7363cat >>conftest.$ac_ext <<_ACEOF
7364/* end confdefs.h.  */
7365#include <termios.h>
7366int
7367main ()
7368{
7369speed_t x = 1;
7370  ;
7371  return 0;
7372}
7373_ACEOF
7374rm -f conftest.$ac_objext
7375if { (ac_try="$ac_compile"
7376case "(($ac_try" in
7377  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7378  *) ac_try_echo=$ac_try;;
7379esac
7380eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7381  (eval "$ac_compile") 2>conftest.er1
7382  ac_status=$?
7383  grep -v '^ *+' conftest.er1 >conftest.err
7384  rm -f conftest.er1
7385  cat conftest.err >&5
7386  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7387  (exit $ac_status); } && {
7388	 test -z "$ac_c_werror_flag" ||
7389	 test ! -s conftest.err
7390       } && test -s conftest.$ac_objext; then
7391  emacs_cv_speed_t=yes
7392else
7393  echo "$as_me: failed program was:" >&5
7394sed 's/^/| /' conftest.$ac_ext >&5
7395
7396	emacs_cv_speed_t=no
7397fi
7398
7399rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7400fi
7401{ echo "$as_me:$LINENO: result: $emacs_cv_speed_t" >&5
7402echo "${ECHO_T}$emacs_cv_speed_t" >&6; }
7403if test $emacs_cv_speed_t = yes; then
7404
7405cat >>confdefs.h <<\_ACEOF
7406#define HAVE_SPEED_T 1
7407_ACEOF
7408
7409fi
7410
7411{ echo "$as_me:$LINENO: checking for struct timeval" >&5
7412echo $ECHO_N "checking for struct timeval... $ECHO_C" >&6; }
7413if test "${emacs_cv_struct_timeval+set}" = set; then
7414  echo $ECHO_N "(cached) $ECHO_C" >&6
7415else
7416  cat >conftest.$ac_ext <<_ACEOF
7417/* confdefs.h.  */
7418_ACEOF
7419cat confdefs.h >>conftest.$ac_ext
7420cat >>conftest.$ac_ext <<_ACEOF
7421/* end confdefs.h.  */
7422#ifdef TIME_WITH_SYS_TIME
7423#include <sys/time.h>
7424#include <time.h>
7425#else
7426#ifdef HAVE_SYS_TIME_H
7427#include <sys/time.h>
7428#else
7429#include <time.h>
7430#endif
7431#endif
7432int
7433main ()
7434{
7435static struct timeval x; x.tv_sec = x.tv_usec;
7436  ;
7437  return 0;
7438}
7439_ACEOF
7440rm -f conftest.$ac_objext
7441if { (ac_try="$ac_compile"
7442case "(($ac_try" in
7443  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7444  *) ac_try_echo=$ac_try;;
7445esac
7446eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7447  (eval "$ac_compile") 2>conftest.er1
7448  ac_status=$?
7449  grep -v '^ *+' conftest.er1 >conftest.err
7450  rm -f conftest.er1
7451  cat conftest.err >&5
7452  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7453  (exit $ac_status); } && {
7454	 test -z "$ac_c_werror_flag" ||
7455	 test ! -s conftest.err
7456       } && test -s conftest.$ac_objext; then
7457  emacs_cv_struct_timeval=yes
7458else
7459  echo "$as_me: failed program was:" >&5
7460sed 's/^/| /' conftest.$ac_ext >&5
7461
7462	emacs_cv_struct_timeval=no
7463fi
7464
7465rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7466fi
7467{ echo "$as_me:$LINENO: result: $emacs_cv_struct_timeval" >&5
7468echo "${ECHO_T}$emacs_cv_struct_timeval" >&6; }
7469HAVE_TIMEVAL=$emacs_cv_struct_timeval
7470if test $emacs_cv_struct_timeval = yes; then
7471
7472cat >>confdefs.h <<\_ACEOF
7473#define HAVE_TIMEVAL 1
7474_ACEOF
7475
7476fi
7477
7478{ echo "$as_me:$LINENO: checking for struct exception" >&5
7479echo $ECHO_N "checking for struct exception... $ECHO_C" >&6; }
7480if test "${emacs_cv_struct_exception+set}" = set; then
7481  echo $ECHO_N "(cached) $ECHO_C" >&6
7482else
7483  cat >conftest.$ac_ext <<_ACEOF
7484/* confdefs.h.  */
7485_ACEOF
7486cat confdefs.h >>conftest.$ac_ext
7487cat >>conftest.$ac_ext <<_ACEOF
7488/* end confdefs.h.  */
7489#include <math.h>
7490int
7491main ()
7492{
7493static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
7494  ;
7495  return 0;
7496}
7497_ACEOF
7498rm -f conftest.$ac_objext
7499if { (ac_try="$ac_compile"
7500case "(($ac_try" in
7501  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7502  *) ac_try_echo=$ac_try;;
7503esac
7504eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7505  (eval "$ac_compile") 2>conftest.er1
7506  ac_status=$?
7507  grep -v '^ *+' conftest.er1 >conftest.err
7508  rm -f conftest.er1
7509  cat conftest.err >&5
7510  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7511  (exit $ac_status); } && {
7512	 test -z "$ac_c_werror_flag" ||
7513	 test ! -s conftest.err
7514       } && test -s conftest.$ac_objext; then
7515  emacs_cv_struct_exception=yes
7516else
7517  echo "$as_me: failed program was:" >&5
7518sed 's/^/| /' conftest.$ac_ext >&5
7519
7520	emacs_cv_struct_exception=no
7521fi
7522
7523rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7524fi
7525{ echo "$as_me:$LINENO: result: $emacs_cv_struct_exception" >&5
7526echo "${ECHO_T}$emacs_cv_struct_exception" >&6; }
7527HAVE_EXCEPTION=$emacs_cv_struct_exception
7528if test $emacs_cv_struct_exception != yes; then
7529
7530cat >>confdefs.h <<\_ACEOF
7531#define NO_MATHERR 1
7532_ACEOF
7533
7534fi
7535
7536
7537for ac_header in sys/socket.h
7538do
7539as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7540if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7541  { echo "$as_me:$LINENO: checking for $ac_header" >&5
7542echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7543if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7544  echo $ECHO_N "(cached) $ECHO_C" >&6
7545fi
7546ac_res=`eval echo '${'$as_ac_Header'}'`
7547	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7548echo "${ECHO_T}$ac_res" >&6; }
7549else
7550  # Is the header compilable?
7551{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
7552echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
7553cat >conftest.$ac_ext <<_ACEOF
7554/* confdefs.h.  */
7555_ACEOF
7556cat confdefs.h >>conftest.$ac_ext
7557cat >>conftest.$ac_ext <<_ACEOF
7558/* end confdefs.h.  */
7559$ac_includes_default
7560#include <$ac_header>
7561_ACEOF
7562rm -f conftest.$ac_objext
7563if { (ac_try="$ac_compile"
7564case "(($ac_try" in
7565  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7566  *) ac_try_echo=$ac_try;;
7567esac
7568eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7569  (eval "$ac_compile") 2>conftest.er1
7570  ac_status=$?
7571  grep -v '^ *+' conftest.er1 >conftest.err
7572  rm -f conftest.er1
7573  cat conftest.err >&5
7574  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7575  (exit $ac_status); } && {
7576	 test -z "$ac_c_werror_flag" ||
7577	 test ! -s conftest.err
7578       } && test -s conftest.$ac_objext; then
7579  ac_header_compiler=yes
7580else
7581  echo "$as_me: failed program was:" >&5
7582sed 's/^/| /' conftest.$ac_ext >&5
7583
7584	ac_header_compiler=no
7585fi
7586
7587rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7588{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7589echo "${ECHO_T}$ac_header_compiler" >&6; }
7590
7591# Is the header present?
7592{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
7593echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
7594cat >conftest.$ac_ext <<_ACEOF
7595/* confdefs.h.  */
7596_ACEOF
7597cat confdefs.h >>conftest.$ac_ext
7598cat >>conftest.$ac_ext <<_ACEOF
7599/* end confdefs.h.  */
7600#include <$ac_header>
7601_ACEOF
7602if { (ac_try="$ac_cpp conftest.$ac_ext"
7603case "(($ac_try" in
7604  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7605  *) ac_try_echo=$ac_try;;
7606esac
7607eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7608  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
7609  ac_status=$?
7610  grep -v '^ *+' conftest.er1 >conftest.err
7611  rm -f conftest.er1
7612  cat conftest.err >&5
7613  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7614  (exit $ac_status); } >/dev/null && {
7615	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
7616	 test ! -s conftest.err
7617       }; then
7618  ac_header_preproc=yes
7619else
7620  echo "$as_me: failed program was:" >&5
7621sed 's/^/| /' conftest.$ac_ext >&5
7622
7623  ac_header_preproc=no
7624fi
7625
7626rm -f conftest.err conftest.$ac_ext
7627{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7628echo "${ECHO_T}$ac_header_preproc" >&6; }
7629
7630# So?  What about this header?
7631case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7632  yes:no: )
7633    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7634echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7635    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7636echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7637    ac_header_preproc=yes
7638    ;;
7639  no:yes:* )
7640    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7641echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7642    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7643echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7644    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7645echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7646    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7647echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7648    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7649echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7650    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7651echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7652
7653    ;;
7654esac
7655{ echo "$as_me:$LINENO: checking for $ac_header" >&5
7656echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7657if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7658  echo $ECHO_N "(cached) $ECHO_C" >&6
7659else
7660  eval "$as_ac_Header=\$ac_header_preproc"
7661fi
7662ac_res=`eval echo '${'$as_ac_Header'}'`
7663	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7664echo "${ECHO_T}$ac_res" >&6; }
7665
7666fi
7667if test `eval echo '${'$as_ac_Header'}'` = yes; then
7668  cat >>confdefs.h <<_ACEOF
7669#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7670_ACEOF
7671
7672fi
7673
7674done
7675
7676
7677for ac_header in net/if.h
7678do
7679as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7680{ echo "$as_me:$LINENO: checking for $ac_header" >&5
7681echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7682if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7683  echo $ECHO_N "(cached) $ECHO_C" >&6
7684else
7685  cat >conftest.$ac_ext <<_ACEOF
7686/* confdefs.h.  */
7687_ACEOF
7688cat confdefs.h >>conftest.$ac_ext
7689cat >>conftest.$ac_ext <<_ACEOF
7690/* end confdefs.h.  */
7691$ac_includes_default
7692#if HAVE_SYS_SOCKET_H
7693#include <sys/socket.h>
7694#endif
7695
7696#include <$ac_header>
7697_ACEOF
7698rm -f conftest.$ac_objext
7699if { (ac_try="$ac_compile"
7700case "(($ac_try" in
7701  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7702  *) ac_try_echo=$ac_try;;
7703esac
7704eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7705  (eval "$ac_compile") 2>conftest.er1
7706  ac_status=$?
7707  grep -v '^ *+' conftest.er1 >conftest.err
7708  rm -f conftest.er1
7709  cat conftest.err >&5
7710  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7711  (exit $ac_status); } && {
7712	 test -z "$ac_c_werror_flag" ||
7713	 test ! -s conftest.err
7714       } && test -s conftest.$ac_objext; then
7715  eval "$as_ac_Header=yes"
7716else
7717  echo "$as_me: failed program was:" >&5
7718sed 's/^/| /' conftest.$ac_ext >&5
7719
7720	eval "$as_ac_Header=no"
7721fi
7722
7723rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7724fi
7725ac_res=`eval echo '${'$as_ac_Header'}'`
7726	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7727echo "${ECHO_T}$ac_res" >&6; }
7728if test `eval echo '${'$as_ac_Header'}'` = yes; then
7729  cat >>confdefs.h <<_ACEOF
7730#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7731_ACEOF
7732
7733fi
7734
7735done
7736
7737
7738{ echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
7739echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6; }
7740if test "${ac_cv_struct_tm+set}" = set; then
7741  echo $ECHO_N "(cached) $ECHO_C" >&6
7742else
7743  cat >conftest.$ac_ext <<_ACEOF
7744/* confdefs.h.  */
7745_ACEOF
7746cat confdefs.h >>conftest.$ac_ext
7747cat >>conftest.$ac_ext <<_ACEOF
7748/* end confdefs.h.  */
7749#include <sys/types.h>
7750#include <time.h>
7751
7752int
7753main ()
7754{
7755struct tm tm;
7756				     int *p = &tm.tm_sec;
7757 				     return !p;
7758  ;
7759  return 0;
7760}
7761_ACEOF
7762rm -f conftest.$ac_objext
7763if { (ac_try="$ac_compile"
7764case "(($ac_try" in
7765  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7766  *) ac_try_echo=$ac_try;;
7767esac
7768eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7769  (eval "$ac_compile") 2>conftest.er1
7770  ac_status=$?
7771  grep -v '^ *+' conftest.er1 >conftest.err
7772  rm -f conftest.er1
7773  cat conftest.err >&5
7774  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7775  (exit $ac_status); } && {
7776	 test -z "$ac_c_werror_flag" ||
7777	 test ! -s conftest.err
7778       } && test -s conftest.$ac_objext; then
7779  ac_cv_struct_tm=time.h
7780else
7781  echo "$as_me: failed program was:" >&5
7782sed 's/^/| /' conftest.$ac_ext >&5
7783
7784	ac_cv_struct_tm=sys/time.h
7785fi
7786
7787rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7788fi
7789{ echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
7790echo "${ECHO_T}$ac_cv_struct_tm" >&6; }
7791if test $ac_cv_struct_tm = sys/time.h; then
7792
7793cat >>confdefs.h <<\_ACEOF
7794#define TM_IN_SYS_TIME 1
7795_ACEOF
7796
7797fi
7798
7799{ echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
7800echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6; }
7801if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
7802  echo $ECHO_N "(cached) $ECHO_C" >&6
7803else
7804  cat >conftest.$ac_ext <<_ACEOF
7805/* confdefs.h.  */
7806_ACEOF
7807cat confdefs.h >>conftest.$ac_ext
7808cat >>conftest.$ac_ext <<_ACEOF
7809/* end confdefs.h.  */
7810#include <sys/types.h>
7811#include <$ac_cv_struct_tm>
7812
7813
7814int
7815main ()
7816{
7817static struct tm ac_aggr;
7818if (ac_aggr.tm_zone)
7819return 0;
7820  ;
7821  return 0;
7822}
7823_ACEOF
7824rm -f conftest.$ac_objext
7825if { (ac_try="$ac_compile"
7826case "(($ac_try" in
7827  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7828  *) ac_try_echo=$ac_try;;
7829esac
7830eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7831  (eval "$ac_compile") 2>conftest.er1
7832  ac_status=$?
7833  grep -v '^ *+' conftest.er1 >conftest.err
7834  rm -f conftest.er1
7835  cat conftest.err >&5
7836  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7837  (exit $ac_status); } && {
7838	 test -z "$ac_c_werror_flag" ||
7839	 test ! -s conftest.err
7840       } && test -s conftest.$ac_objext; then
7841  ac_cv_member_struct_tm_tm_zone=yes
7842else
7843  echo "$as_me: failed program was:" >&5
7844sed 's/^/| /' conftest.$ac_ext >&5
7845
7846	cat >conftest.$ac_ext <<_ACEOF
7847/* confdefs.h.  */
7848_ACEOF
7849cat confdefs.h >>conftest.$ac_ext
7850cat >>conftest.$ac_ext <<_ACEOF
7851/* end confdefs.h.  */
7852#include <sys/types.h>
7853#include <$ac_cv_struct_tm>
7854
7855
7856int
7857main ()
7858{
7859static struct tm ac_aggr;
7860if (sizeof ac_aggr.tm_zone)
7861return 0;
7862  ;
7863  return 0;
7864}
7865_ACEOF
7866rm -f conftest.$ac_objext
7867if { (ac_try="$ac_compile"
7868case "(($ac_try" in
7869  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7870  *) ac_try_echo=$ac_try;;
7871esac
7872eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7873  (eval "$ac_compile") 2>conftest.er1
7874  ac_status=$?
7875  grep -v '^ *+' conftest.er1 >conftest.err
7876  rm -f conftest.er1
7877  cat conftest.err >&5
7878  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7879  (exit $ac_status); } && {
7880	 test -z "$ac_c_werror_flag" ||
7881	 test ! -s conftest.err
7882       } && test -s conftest.$ac_objext; then
7883  ac_cv_member_struct_tm_tm_zone=yes
7884else
7885  echo "$as_me: failed program was:" >&5
7886sed 's/^/| /' conftest.$ac_ext >&5
7887
7888	ac_cv_member_struct_tm_tm_zone=no
7889fi
7890
7891rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7892fi
7893
7894rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7895fi
7896{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
7897echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6; }
7898if test $ac_cv_member_struct_tm_tm_zone = yes; then
7899
7900cat >>confdefs.h <<_ACEOF
7901#define HAVE_STRUCT_TM_TM_ZONE 1
7902_ACEOF
7903
7904
7905fi
7906
7907if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
7908
7909cat >>confdefs.h <<\_ACEOF
7910#define HAVE_TM_ZONE 1
7911_ACEOF
7912
7913else
7914  { echo "$as_me:$LINENO: checking whether tzname is declared" >&5
7915echo $ECHO_N "checking whether tzname is declared... $ECHO_C" >&6; }
7916if test "${ac_cv_have_decl_tzname+set}" = set; then
7917  echo $ECHO_N "(cached) $ECHO_C" >&6
7918else
7919  cat >conftest.$ac_ext <<_ACEOF
7920/* confdefs.h.  */
7921_ACEOF
7922cat confdefs.h >>conftest.$ac_ext
7923cat >>conftest.$ac_ext <<_ACEOF
7924/* end confdefs.h.  */
7925#include <time.h>
7926
7927int
7928main ()
7929{
7930#ifndef tzname
7931  (void) tzname;
7932#endif
7933
7934  ;
7935  return 0;
7936}
7937_ACEOF
7938rm -f conftest.$ac_objext
7939if { (ac_try="$ac_compile"
7940case "(($ac_try" in
7941  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7942  *) ac_try_echo=$ac_try;;
7943esac
7944eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7945  (eval "$ac_compile") 2>conftest.er1
7946  ac_status=$?
7947  grep -v '^ *+' conftest.er1 >conftest.err
7948  rm -f conftest.er1
7949  cat conftest.err >&5
7950  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7951  (exit $ac_status); } && {
7952	 test -z "$ac_c_werror_flag" ||
7953	 test ! -s conftest.err
7954       } && test -s conftest.$ac_objext; then
7955  ac_cv_have_decl_tzname=yes
7956else
7957  echo "$as_me: failed program was:" >&5
7958sed 's/^/| /' conftest.$ac_ext >&5
7959
7960	ac_cv_have_decl_tzname=no
7961fi
7962
7963rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7964fi
7965{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_tzname" >&5
7966echo "${ECHO_T}$ac_cv_have_decl_tzname" >&6; }
7967if test $ac_cv_have_decl_tzname = yes; then
7968
7969cat >>confdefs.h <<_ACEOF
7970#define HAVE_DECL_TZNAME 1
7971_ACEOF
7972
7973
7974else
7975  cat >>confdefs.h <<_ACEOF
7976#define HAVE_DECL_TZNAME 0
7977_ACEOF
7978
7979
7980fi
7981
7982
7983  { echo "$as_me:$LINENO: checking for tzname" >&5
7984echo $ECHO_N "checking for tzname... $ECHO_C" >&6; }
7985if test "${ac_cv_var_tzname+set}" = set; then
7986  echo $ECHO_N "(cached) $ECHO_C" >&6
7987else
7988  cat >conftest.$ac_ext <<_ACEOF
7989/* confdefs.h.  */
7990_ACEOF
7991cat confdefs.h >>conftest.$ac_ext
7992cat >>conftest.$ac_ext <<_ACEOF
7993/* end confdefs.h.  */
7994#include <time.h>
7995#if !HAVE_DECL_TZNAME
7996extern char *tzname[];
7997#endif
7998
7999int
8000main ()
8001{
8002return tzname[0][0];
8003  ;
8004  return 0;
8005}
8006_ACEOF
8007rm -f conftest.$ac_objext conftest$ac_exeext
8008if { (ac_try="$ac_link"
8009case "(($ac_try" in
8010  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8011  *) ac_try_echo=$ac_try;;
8012esac
8013eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8014  (eval "$ac_link") 2>conftest.er1
8015  ac_status=$?
8016  grep -v '^ *+' conftest.er1 >conftest.err
8017  rm -f conftest.er1
8018  cat conftest.err >&5
8019  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8020  (exit $ac_status); } && {
8021	 test -z "$ac_c_werror_flag" ||
8022	 test ! -s conftest.err
8023       } && test -s conftest$ac_exeext &&
8024       $as_test_x conftest$ac_exeext; then
8025  ac_cv_var_tzname=yes
8026else
8027  echo "$as_me: failed program was:" >&5
8028sed 's/^/| /' conftest.$ac_ext >&5
8029
8030	ac_cv_var_tzname=no
8031fi
8032
8033rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8034      conftest$ac_exeext conftest.$ac_ext
8035fi
8036{ echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
8037echo "${ECHO_T}$ac_cv_var_tzname" >&6; }
8038  if test $ac_cv_var_tzname = yes; then
8039
8040cat >>confdefs.h <<\_ACEOF
8041#define HAVE_TZNAME 1
8042_ACEOF
8043
8044  fi
8045fi
8046
8047{ echo "$as_me:$LINENO: checking for struct tm.tm_gmtoff" >&5
8048echo $ECHO_N "checking for struct tm.tm_gmtoff... $ECHO_C" >&6; }
8049if test "${ac_cv_member_struct_tm_tm_gmtoff+set}" = set; then
8050  echo $ECHO_N "(cached) $ECHO_C" >&6
8051else
8052  cat >conftest.$ac_ext <<_ACEOF
8053/* confdefs.h.  */
8054_ACEOF
8055cat confdefs.h >>conftest.$ac_ext
8056cat >>conftest.$ac_ext <<_ACEOF
8057/* end confdefs.h.  */
8058#include <time.h>
8059
8060int
8061main ()
8062{
8063static struct tm ac_aggr;
8064if (ac_aggr.tm_gmtoff)
8065return 0;
8066  ;
8067  return 0;
8068}
8069_ACEOF
8070rm -f conftest.$ac_objext
8071if { (ac_try="$ac_compile"
8072case "(($ac_try" in
8073  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8074  *) ac_try_echo=$ac_try;;
8075esac
8076eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8077  (eval "$ac_compile") 2>conftest.er1
8078  ac_status=$?
8079  grep -v '^ *+' conftest.er1 >conftest.err
8080  rm -f conftest.er1
8081  cat conftest.err >&5
8082  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8083  (exit $ac_status); } && {
8084	 test -z "$ac_c_werror_flag" ||
8085	 test ! -s conftest.err
8086       } && test -s conftest.$ac_objext; then
8087  ac_cv_member_struct_tm_tm_gmtoff=yes
8088else
8089  echo "$as_me: failed program was:" >&5
8090sed 's/^/| /' conftest.$ac_ext >&5
8091
8092	cat >conftest.$ac_ext <<_ACEOF
8093/* confdefs.h.  */
8094_ACEOF
8095cat confdefs.h >>conftest.$ac_ext
8096cat >>conftest.$ac_ext <<_ACEOF
8097/* end confdefs.h.  */
8098#include <time.h>
8099
8100int
8101main ()
8102{
8103static struct tm ac_aggr;
8104if (sizeof ac_aggr.tm_gmtoff)
8105return 0;
8106  ;
8107  return 0;
8108}
8109_ACEOF
8110rm -f conftest.$ac_objext
8111if { (ac_try="$ac_compile"
8112case "(($ac_try" in
8113  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8114  *) ac_try_echo=$ac_try;;
8115esac
8116eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8117  (eval "$ac_compile") 2>conftest.er1
8118  ac_status=$?
8119  grep -v '^ *+' conftest.er1 >conftest.err
8120  rm -f conftest.er1
8121  cat conftest.err >&5
8122  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8123  (exit $ac_status); } && {
8124	 test -z "$ac_c_werror_flag" ||
8125	 test ! -s conftest.err
8126       } && test -s conftest.$ac_objext; then
8127  ac_cv_member_struct_tm_tm_gmtoff=yes
8128else
8129  echo "$as_me: failed program was:" >&5
8130sed 's/^/| /' conftest.$ac_ext >&5
8131
8132	ac_cv_member_struct_tm_tm_gmtoff=no
8133fi
8134
8135rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8136fi
8137
8138rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8139fi
8140{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_gmtoff" >&5
8141echo "${ECHO_T}$ac_cv_member_struct_tm_tm_gmtoff" >&6; }
8142if test $ac_cv_member_struct_tm_tm_gmtoff = yes; then
8143
8144cat >>confdefs.h <<\_ACEOF
8145#define HAVE_TM_GMTOFF 1
8146_ACEOF
8147
8148fi
8149
8150{ echo "$as_me:$LINENO: checking for struct ifreq.ifr_flags" >&5
8151echo $ECHO_N "checking for struct ifreq.ifr_flags... $ECHO_C" >&6; }
8152if test "${ac_cv_member_struct_ifreq_ifr_flags+set}" = set; then
8153  echo $ECHO_N "(cached) $ECHO_C" >&6
8154else
8155  cat >conftest.$ac_ext <<_ACEOF
8156/* confdefs.h.  */
8157_ACEOF
8158cat confdefs.h >>conftest.$ac_ext
8159cat >>conftest.$ac_ext <<_ACEOF
8160/* end confdefs.h.  */
8161$ac_includes_default
8162#if HAVE_SYS_SOCKET_H
8163#include <sys/socket.h>
8164#endif
8165#if HAVE_NET_IF_H
8166#include <net/if.h>
8167#endif
8168
8169int
8170main ()
8171{
8172static struct ifreq ac_aggr;
8173if (ac_aggr.ifr_flags)
8174return 0;
8175  ;
8176  return 0;
8177}
8178_ACEOF
8179rm -f conftest.$ac_objext
8180if { (ac_try="$ac_compile"
8181case "(($ac_try" in
8182  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8183  *) ac_try_echo=$ac_try;;
8184esac
8185eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8186  (eval "$ac_compile") 2>conftest.er1
8187  ac_status=$?
8188  grep -v '^ *+' conftest.er1 >conftest.err
8189  rm -f conftest.er1
8190  cat conftest.err >&5
8191  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8192  (exit $ac_status); } && {
8193	 test -z "$ac_c_werror_flag" ||
8194	 test ! -s conftest.err
8195       } && test -s conftest.$ac_objext; then
8196  ac_cv_member_struct_ifreq_ifr_flags=yes
8197else
8198  echo "$as_me: failed program was:" >&5
8199sed 's/^/| /' conftest.$ac_ext >&5
8200
8201	cat >conftest.$ac_ext <<_ACEOF
8202/* confdefs.h.  */
8203_ACEOF
8204cat confdefs.h >>conftest.$ac_ext
8205cat >>conftest.$ac_ext <<_ACEOF
8206/* end confdefs.h.  */
8207$ac_includes_default
8208#if HAVE_SYS_SOCKET_H
8209#include <sys/socket.h>
8210#endif
8211#if HAVE_NET_IF_H
8212#include <net/if.h>
8213#endif
8214
8215int
8216main ()
8217{
8218static struct ifreq ac_aggr;
8219if (sizeof ac_aggr.ifr_flags)
8220return 0;
8221  ;
8222  return 0;
8223}
8224_ACEOF
8225rm -f conftest.$ac_objext
8226if { (ac_try="$ac_compile"
8227case "(($ac_try" in
8228  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8229  *) ac_try_echo=$ac_try;;
8230esac
8231eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8232  (eval "$ac_compile") 2>conftest.er1
8233  ac_status=$?
8234  grep -v '^ *+' conftest.er1 >conftest.err
8235  rm -f conftest.er1
8236  cat conftest.err >&5
8237  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8238  (exit $ac_status); } && {
8239	 test -z "$ac_c_werror_flag" ||
8240	 test ! -s conftest.err
8241       } && test -s conftest.$ac_objext; then
8242  ac_cv_member_struct_ifreq_ifr_flags=yes
8243else
8244  echo "$as_me: failed program was:" >&5
8245sed 's/^/| /' conftest.$ac_ext >&5
8246
8247	ac_cv_member_struct_ifreq_ifr_flags=no
8248fi
8249
8250rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8251fi
8252
8253rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8254fi
8255{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_flags" >&5
8256echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_flags" >&6; }
8257if test $ac_cv_member_struct_ifreq_ifr_flags = yes; then
8258
8259cat >>confdefs.h <<_ACEOF
8260#define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
8261_ACEOF
8262
8263
8264fi
8265{ echo "$as_me:$LINENO: checking for struct ifreq.ifr_hwaddr" >&5
8266echo $ECHO_N "checking for struct ifreq.ifr_hwaddr... $ECHO_C" >&6; }
8267if test "${ac_cv_member_struct_ifreq_ifr_hwaddr+set}" = set; then
8268  echo $ECHO_N "(cached) $ECHO_C" >&6
8269else
8270  cat >conftest.$ac_ext <<_ACEOF
8271/* confdefs.h.  */
8272_ACEOF
8273cat confdefs.h >>conftest.$ac_ext
8274cat >>conftest.$ac_ext <<_ACEOF
8275/* end confdefs.h.  */
8276$ac_includes_default
8277#if HAVE_SYS_SOCKET_H
8278#include <sys/socket.h>
8279#endif
8280#if HAVE_NET_IF_H
8281#include <net/if.h>
8282#endif
8283
8284int
8285main ()
8286{
8287static struct ifreq ac_aggr;
8288if (ac_aggr.ifr_hwaddr)
8289return 0;
8290  ;
8291  return 0;
8292}
8293_ACEOF
8294rm -f conftest.$ac_objext
8295if { (ac_try="$ac_compile"
8296case "(($ac_try" in
8297  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8298  *) ac_try_echo=$ac_try;;
8299esac
8300eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8301  (eval "$ac_compile") 2>conftest.er1
8302  ac_status=$?
8303  grep -v '^ *+' conftest.er1 >conftest.err
8304  rm -f conftest.er1
8305  cat conftest.err >&5
8306  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8307  (exit $ac_status); } && {
8308	 test -z "$ac_c_werror_flag" ||
8309	 test ! -s conftest.err
8310       } && test -s conftest.$ac_objext; then
8311  ac_cv_member_struct_ifreq_ifr_hwaddr=yes
8312else
8313  echo "$as_me: failed program was:" >&5
8314sed 's/^/| /' conftest.$ac_ext >&5
8315
8316	cat >conftest.$ac_ext <<_ACEOF
8317/* confdefs.h.  */
8318_ACEOF
8319cat confdefs.h >>conftest.$ac_ext
8320cat >>conftest.$ac_ext <<_ACEOF
8321/* end confdefs.h.  */
8322$ac_includes_default
8323#if HAVE_SYS_SOCKET_H
8324#include <sys/socket.h>
8325#endif
8326#if HAVE_NET_IF_H
8327#include <net/if.h>
8328#endif
8329
8330int
8331main ()
8332{
8333static struct ifreq ac_aggr;
8334if (sizeof ac_aggr.ifr_hwaddr)
8335return 0;
8336  ;
8337  return 0;
8338}
8339_ACEOF
8340rm -f conftest.$ac_objext
8341if { (ac_try="$ac_compile"
8342case "(($ac_try" in
8343  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8344  *) ac_try_echo=$ac_try;;
8345esac
8346eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8347  (eval "$ac_compile") 2>conftest.er1
8348  ac_status=$?
8349  grep -v '^ *+' conftest.er1 >conftest.err
8350  rm -f conftest.er1
8351  cat conftest.err >&5
8352  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8353  (exit $ac_status); } && {
8354	 test -z "$ac_c_werror_flag" ||
8355	 test ! -s conftest.err
8356       } && test -s conftest.$ac_objext; then
8357  ac_cv_member_struct_ifreq_ifr_hwaddr=yes
8358else
8359  echo "$as_me: failed program was:" >&5
8360sed 's/^/| /' conftest.$ac_ext >&5
8361
8362	ac_cv_member_struct_ifreq_ifr_hwaddr=no
8363fi
8364
8365rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8366fi
8367
8368rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8369fi
8370{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_hwaddr" >&5
8371echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_hwaddr" >&6; }
8372if test $ac_cv_member_struct_ifreq_ifr_hwaddr = yes; then
8373
8374cat >>confdefs.h <<_ACEOF
8375#define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
8376_ACEOF
8377
8378
8379fi
8380{ echo "$as_me:$LINENO: checking for struct ifreq.ifr_netmask" >&5
8381echo $ECHO_N "checking for struct ifreq.ifr_netmask... $ECHO_C" >&6; }
8382if test "${ac_cv_member_struct_ifreq_ifr_netmask+set}" = set; then
8383  echo $ECHO_N "(cached) $ECHO_C" >&6
8384else
8385  cat >conftest.$ac_ext <<_ACEOF
8386/* confdefs.h.  */
8387_ACEOF
8388cat confdefs.h >>conftest.$ac_ext
8389cat >>conftest.$ac_ext <<_ACEOF
8390/* end confdefs.h.  */
8391$ac_includes_default
8392#if HAVE_SYS_SOCKET_H
8393#include <sys/socket.h>
8394#endif
8395#if HAVE_NET_IF_H
8396#include <net/if.h>
8397#endif
8398
8399int
8400main ()
8401{
8402static struct ifreq ac_aggr;
8403if (ac_aggr.ifr_netmask)
8404return 0;
8405  ;
8406  return 0;
8407}
8408_ACEOF
8409rm -f conftest.$ac_objext
8410if { (ac_try="$ac_compile"
8411case "(($ac_try" in
8412  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8413  *) ac_try_echo=$ac_try;;
8414esac
8415eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8416  (eval "$ac_compile") 2>conftest.er1
8417  ac_status=$?
8418  grep -v '^ *+' conftest.er1 >conftest.err
8419  rm -f conftest.er1
8420  cat conftest.err >&5
8421  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8422  (exit $ac_status); } && {
8423	 test -z "$ac_c_werror_flag" ||
8424	 test ! -s conftest.err
8425       } && test -s conftest.$ac_objext; then
8426  ac_cv_member_struct_ifreq_ifr_netmask=yes
8427else
8428  echo "$as_me: failed program was:" >&5
8429sed 's/^/| /' conftest.$ac_ext >&5
8430
8431	cat >conftest.$ac_ext <<_ACEOF
8432/* confdefs.h.  */
8433_ACEOF
8434cat confdefs.h >>conftest.$ac_ext
8435cat >>conftest.$ac_ext <<_ACEOF
8436/* end confdefs.h.  */
8437$ac_includes_default
8438#if HAVE_SYS_SOCKET_H
8439#include <sys/socket.h>
8440#endif
8441#if HAVE_NET_IF_H
8442#include <net/if.h>
8443#endif
8444
8445int
8446main ()
8447{
8448static struct ifreq ac_aggr;
8449if (sizeof ac_aggr.ifr_netmask)
8450return 0;
8451  ;
8452  return 0;
8453}
8454_ACEOF
8455rm -f conftest.$ac_objext
8456if { (ac_try="$ac_compile"
8457case "(($ac_try" in
8458  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8459  *) ac_try_echo=$ac_try;;
8460esac
8461eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8462  (eval "$ac_compile") 2>conftest.er1
8463  ac_status=$?
8464  grep -v '^ *+' conftest.er1 >conftest.err
8465  rm -f conftest.er1
8466  cat conftest.err >&5
8467  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8468  (exit $ac_status); } && {
8469	 test -z "$ac_c_werror_flag" ||
8470	 test ! -s conftest.err
8471       } && test -s conftest.$ac_objext; then
8472  ac_cv_member_struct_ifreq_ifr_netmask=yes
8473else
8474  echo "$as_me: failed program was:" >&5
8475sed 's/^/| /' conftest.$ac_ext >&5
8476
8477	ac_cv_member_struct_ifreq_ifr_netmask=no
8478fi
8479
8480rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8481fi
8482
8483rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8484fi
8485{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_netmask" >&5
8486echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_netmask" >&6; }
8487if test $ac_cv_member_struct_ifreq_ifr_netmask = yes; then
8488
8489cat >>confdefs.h <<_ACEOF
8490#define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
8491_ACEOF
8492
8493
8494fi
8495{ echo "$as_me:$LINENO: checking for struct ifreq.ifr_broadaddr" >&5
8496echo $ECHO_N "checking for struct ifreq.ifr_broadaddr... $ECHO_C" >&6; }
8497if test "${ac_cv_member_struct_ifreq_ifr_broadaddr+set}" = set; then
8498  echo $ECHO_N "(cached) $ECHO_C" >&6
8499else
8500  cat >conftest.$ac_ext <<_ACEOF
8501/* confdefs.h.  */
8502_ACEOF
8503cat confdefs.h >>conftest.$ac_ext
8504cat >>conftest.$ac_ext <<_ACEOF
8505/* end confdefs.h.  */
8506$ac_includes_default
8507#if HAVE_SYS_SOCKET_H
8508#include <sys/socket.h>
8509#endif
8510#if HAVE_NET_IF_H
8511#include <net/if.h>
8512#endif
8513
8514int
8515main ()
8516{
8517static struct ifreq ac_aggr;
8518if (ac_aggr.ifr_broadaddr)
8519return 0;
8520  ;
8521  return 0;
8522}
8523_ACEOF
8524rm -f conftest.$ac_objext
8525if { (ac_try="$ac_compile"
8526case "(($ac_try" in
8527  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8528  *) ac_try_echo=$ac_try;;
8529esac
8530eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8531  (eval "$ac_compile") 2>conftest.er1
8532  ac_status=$?
8533  grep -v '^ *+' conftest.er1 >conftest.err
8534  rm -f conftest.er1
8535  cat conftest.err >&5
8536  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8537  (exit $ac_status); } && {
8538	 test -z "$ac_c_werror_flag" ||
8539	 test ! -s conftest.err
8540       } && test -s conftest.$ac_objext; then
8541  ac_cv_member_struct_ifreq_ifr_broadaddr=yes
8542else
8543  echo "$as_me: failed program was:" >&5
8544sed 's/^/| /' conftest.$ac_ext >&5
8545
8546	cat >conftest.$ac_ext <<_ACEOF
8547/* confdefs.h.  */
8548_ACEOF
8549cat confdefs.h >>conftest.$ac_ext
8550cat >>conftest.$ac_ext <<_ACEOF
8551/* end confdefs.h.  */
8552$ac_includes_default
8553#if HAVE_SYS_SOCKET_H
8554#include <sys/socket.h>
8555#endif
8556#if HAVE_NET_IF_H
8557#include <net/if.h>
8558#endif
8559
8560int
8561main ()
8562{
8563static struct ifreq ac_aggr;
8564if (sizeof ac_aggr.ifr_broadaddr)
8565return 0;
8566  ;
8567  return 0;
8568}
8569_ACEOF
8570rm -f conftest.$ac_objext
8571if { (ac_try="$ac_compile"
8572case "(($ac_try" in
8573  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8574  *) ac_try_echo=$ac_try;;
8575esac
8576eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8577  (eval "$ac_compile") 2>conftest.er1
8578  ac_status=$?
8579  grep -v '^ *+' conftest.er1 >conftest.err
8580  rm -f conftest.er1
8581  cat conftest.err >&5
8582  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8583  (exit $ac_status); } && {
8584	 test -z "$ac_c_werror_flag" ||
8585	 test ! -s conftest.err
8586       } && test -s conftest.$ac_objext; then
8587  ac_cv_member_struct_ifreq_ifr_broadaddr=yes
8588else
8589  echo "$as_me: failed program was:" >&5
8590sed 's/^/| /' conftest.$ac_ext >&5
8591
8592	ac_cv_member_struct_ifreq_ifr_broadaddr=no
8593fi
8594
8595rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8596fi
8597
8598rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8599fi
8600{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_broadaddr" >&5
8601echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_broadaddr" >&6; }
8602if test $ac_cv_member_struct_ifreq_ifr_broadaddr = yes; then
8603
8604cat >>confdefs.h <<_ACEOF
8605#define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
8606_ACEOF
8607
8608
8609fi
8610{ echo "$as_me:$LINENO: checking for struct ifreq.ifr_addr" >&5
8611echo $ECHO_N "checking for struct ifreq.ifr_addr... $ECHO_C" >&6; }
8612if test "${ac_cv_member_struct_ifreq_ifr_addr+set}" = set; then
8613  echo $ECHO_N "(cached) $ECHO_C" >&6
8614else
8615  cat >conftest.$ac_ext <<_ACEOF
8616/* confdefs.h.  */
8617_ACEOF
8618cat confdefs.h >>conftest.$ac_ext
8619cat >>conftest.$ac_ext <<_ACEOF
8620/* end confdefs.h.  */
8621$ac_includes_default
8622#if HAVE_SYS_SOCKET_H
8623#include <sys/socket.h>
8624#endif
8625#if HAVE_NET_IF_H
8626#include <net/if.h>
8627#endif
8628
8629int
8630main ()
8631{
8632static struct ifreq ac_aggr;
8633if (ac_aggr.ifr_addr)
8634return 0;
8635  ;
8636  return 0;
8637}
8638_ACEOF
8639rm -f conftest.$ac_objext
8640if { (ac_try="$ac_compile"
8641case "(($ac_try" in
8642  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8643  *) ac_try_echo=$ac_try;;
8644esac
8645eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8646  (eval "$ac_compile") 2>conftest.er1
8647  ac_status=$?
8648  grep -v '^ *+' conftest.er1 >conftest.err
8649  rm -f conftest.er1
8650  cat conftest.err >&5
8651  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8652  (exit $ac_status); } && {
8653	 test -z "$ac_c_werror_flag" ||
8654	 test ! -s conftest.err
8655       } && test -s conftest.$ac_objext; then
8656  ac_cv_member_struct_ifreq_ifr_addr=yes
8657else
8658  echo "$as_me: failed program was:" >&5
8659sed 's/^/| /' conftest.$ac_ext >&5
8660
8661	cat >conftest.$ac_ext <<_ACEOF
8662/* confdefs.h.  */
8663_ACEOF
8664cat confdefs.h >>conftest.$ac_ext
8665cat >>conftest.$ac_ext <<_ACEOF
8666/* end confdefs.h.  */
8667$ac_includes_default
8668#if HAVE_SYS_SOCKET_H
8669#include <sys/socket.h>
8670#endif
8671#if HAVE_NET_IF_H
8672#include <net/if.h>
8673#endif
8674
8675int
8676main ()
8677{
8678static struct ifreq ac_aggr;
8679if (sizeof ac_aggr.ifr_addr)
8680return 0;
8681  ;
8682  return 0;
8683}
8684_ACEOF
8685rm -f conftest.$ac_objext
8686if { (ac_try="$ac_compile"
8687case "(($ac_try" in
8688  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8689  *) ac_try_echo=$ac_try;;
8690esac
8691eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8692  (eval "$ac_compile") 2>conftest.er1
8693  ac_status=$?
8694  grep -v '^ *+' conftest.er1 >conftest.err
8695  rm -f conftest.er1
8696  cat conftest.err >&5
8697  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8698  (exit $ac_status); } && {
8699	 test -z "$ac_c_werror_flag" ||
8700	 test ! -s conftest.err
8701       } && test -s conftest.$ac_objext; then
8702  ac_cv_member_struct_ifreq_ifr_addr=yes
8703else
8704  echo "$as_me: failed program was:" >&5
8705sed 's/^/| /' conftest.$ac_ext >&5
8706
8707	ac_cv_member_struct_ifreq_ifr_addr=no
8708fi
8709
8710rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8711fi
8712
8713rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8714fi
8715{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_addr" >&5
8716echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_addr" >&6; }
8717if test $ac_cv_member_struct_ifreq_ifr_addr = yes; then
8718
8719cat >>confdefs.h <<_ACEOF
8720#define HAVE_STRUCT_IFREQ_IFR_ADDR 1
8721_ACEOF
8722
8723
8724fi
8725
8726
8727
8728{ echo "$as_me:$LINENO: checking for function prototypes" >&5
8729echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6; }
8730if test "$ac_cv_prog_cc_c89" != no; then
8731  { echo "$as_me:$LINENO: result: yes" >&5
8732echo "${ECHO_T}yes" >&6; }
8733
8734cat >>confdefs.h <<\_ACEOF
8735#define PROTOTYPES 1
8736_ACEOF
8737
8738
8739cat >>confdefs.h <<\_ACEOF
8740#define __PROTOTYPES 1
8741_ACEOF
8742
8743else
8744  { echo "$as_me:$LINENO: result: no" >&5
8745echo "${ECHO_T}no" >&6; }
8746fi
8747
8748{ echo "$as_me:$LINENO: checking for working volatile" >&5
8749echo $ECHO_N "checking for working volatile... $ECHO_C" >&6; }
8750if test "${ac_cv_c_volatile+set}" = set; then
8751  echo $ECHO_N "(cached) $ECHO_C" >&6
8752else
8753  cat >conftest.$ac_ext <<_ACEOF
8754/* confdefs.h.  */
8755_ACEOF
8756cat confdefs.h >>conftest.$ac_ext
8757cat >>conftest.$ac_ext <<_ACEOF
8758/* end confdefs.h.  */
8759
8760int
8761main ()
8762{
8763
8764volatile int x;
8765int * volatile y = (int *) 0;
8766return !x && !y;
8767  ;
8768  return 0;
8769}
8770_ACEOF
8771rm -f conftest.$ac_objext
8772if { (ac_try="$ac_compile"
8773case "(($ac_try" in
8774  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8775  *) ac_try_echo=$ac_try;;
8776esac
8777eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8778  (eval "$ac_compile") 2>conftest.er1
8779  ac_status=$?
8780  grep -v '^ *+' conftest.er1 >conftest.err
8781  rm -f conftest.er1
8782  cat conftest.err >&5
8783  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8784  (exit $ac_status); } && {
8785	 test -z "$ac_c_werror_flag" ||
8786	 test ! -s conftest.err
8787       } && test -s conftest.$ac_objext; then
8788  ac_cv_c_volatile=yes
8789else
8790  echo "$as_me: failed program was:" >&5
8791sed 's/^/| /' conftest.$ac_ext >&5
8792
8793	ac_cv_c_volatile=no
8794fi
8795
8796rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8797fi
8798{ echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
8799echo "${ECHO_T}$ac_cv_c_volatile" >&6; }
8800if test $ac_cv_c_volatile = no; then
8801
8802cat >>confdefs.h <<\_ACEOF
8803#define volatile
8804_ACEOF
8805
8806fi
8807
8808{ echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
8809echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6; }
8810if test "${ac_cv_c_const+set}" = set; then
8811  echo $ECHO_N "(cached) $ECHO_C" >&6
8812else
8813  cat >conftest.$ac_ext <<_ACEOF
8814/* confdefs.h.  */
8815_ACEOF
8816cat confdefs.h >>conftest.$ac_ext
8817cat >>conftest.$ac_ext <<_ACEOF
8818/* end confdefs.h.  */
8819
8820int
8821main ()
8822{
8823/* FIXME: Include the comments suggested by Paul. */
8824#ifndef __cplusplus
8825  /* Ultrix mips cc rejects this.  */
8826  typedef int charset[2];
8827  const charset cs;
8828  /* SunOS 4.1.1 cc rejects this.  */
8829  char const *const *pcpcc;
8830  char **ppc;
8831  /* NEC SVR4.0.2 mips cc rejects this.  */
8832  struct point {int x, y;};
8833  static struct point const zero = {0,0};
8834  /* AIX XL C 1.02.0.0 rejects this.
8835     It does not let you subtract one const X* pointer from another in
8836     an arm of an if-expression whose if-part is not a constant
8837     expression */
8838  const char *g = "string";
8839  pcpcc = &g + (g ? g-g : 0);
8840  /* HPUX 7.0 cc rejects these. */
8841  ++pcpcc;
8842  ppc = (char**) pcpcc;
8843  pcpcc = (char const *const *) ppc;
8844  { /* SCO 3.2v4 cc rejects this.  */
8845    char *t;
8846    char const *s = 0 ? (char *) 0 : (char const *) 0;
8847
8848    *t++ = 0;
8849    if (s) return 0;
8850  }
8851  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
8852    int x[] = {25, 17};
8853    const int *foo = &x[0];
8854    ++foo;
8855  }
8856  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
8857    typedef const int *iptr;
8858    iptr p = 0;
8859    ++p;
8860  }
8861  { /* AIX XL C 1.02.0.0 rejects this saying
8862       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
8863    struct s { int j; const int *ap[3]; };
8864    struct s *b; b->j = 5;
8865  }
8866  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
8867    const int foo = 10;
8868    if (!foo) return 0;
8869  }
8870  return !cs[0] && !zero.x;
8871#endif
8872
8873  ;
8874  return 0;
8875}
8876_ACEOF
8877rm -f conftest.$ac_objext
8878if { (ac_try="$ac_compile"
8879case "(($ac_try" in
8880  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8881  *) ac_try_echo=$ac_try;;
8882esac
8883eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8884  (eval "$ac_compile") 2>conftest.er1
8885  ac_status=$?
8886  grep -v '^ *+' conftest.er1 >conftest.err
8887  rm -f conftest.er1
8888  cat conftest.err >&5
8889  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8890  (exit $ac_status); } && {
8891	 test -z "$ac_c_werror_flag" ||
8892	 test ! -s conftest.err
8893       } && test -s conftest.$ac_objext; then
8894  ac_cv_c_const=yes
8895else
8896  echo "$as_me: failed program was:" >&5
8897sed 's/^/| /' conftest.$ac_ext >&5
8898
8899	ac_cv_c_const=no
8900fi
8901
8902rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8903fi
8904{ echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
8905echo "${ECHO_T}$ac_cv_c_const" >&6; }
8906if test $ac_cv_c_const = no; then
8907
8908cat >>confdefs.h <<\_ACEOF
8909#define const
8910_ACEOF
8911
8912fi
8913
8914{ echo "$as_me:$LINENO: checking for void * support" >&5
8915echo $ECHO_N "checking for void * support... $ECHO_C" >&6; }
8916if test "${emacs_cv_void_star+set}" = set; then
8917  echo $ECHO_N "(cached) $ECHO_C" >&6
8918else
8919  cat >conftest.$ac_ext <<_ACEOF
8920/* confdefs.h.  */
8921_ACEOF
8922cat confdefs.h >>conftest.$ac_ext
8923cat >>conftest.$ac_ext <<_ACEOF
8924/* end confdefs.h.  */
8925
8926int
8927main ()
8928{
8929void * foo;
8930  ;
8931  return 0;
8932}
8933_ACEOF
8934rm -f conftest.$ac_objext
8935if { (ac_try="$ac_compile"
8936case "(($ac_try" in
8937  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8938  *) ac_try_echo=$ac_try;;
8939esac
8940eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8941  (eval "$ac_compile") 2>conftest.er1
8942  ac_status=$?
8943  grep -v '^ *+' conftest.er1 >conftest.err
8944  rm -f conftest.er1
8945  cat conftest.err >&5
8946  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8947  (exit $ac_status); } && {
8948	 test -z "$ac_c_werror_flag" ||
8949	 test ! -s conftest.err
8950       } && test -s conftest.$ac_objext; then
8951  emacs_cv_void_star=yes
8952else
8953  echo "$as_me: failed program was:" >&5
8954sed 's/^/| /' conftest.$ac_ext >&5
8955
8956	emacs_cv_void_star=no
8957fi
8958
8959rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8960fi
8961{ echo "$as_me:$LINENO: result: $emacs_cv_void_star" >&5
8962echo "${ECHO_T}$emacs_cv_void_star" >&6; }
8963if test $emacs_cv_void_star = yes; then
8964  cat >>confdefs.h <<\_ACEOF
8965#define POINTER_TYPE void
8966_ACEOF
8967
8968else
8969  cat >>confdefs.h <<\_ACEOF
8970#define POINTER_TYPE char
8971_ACEOF
8972
8973fi
8974
8975
8976
8977
8978
8979{ echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
8980echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; }
8981set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
8982if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then
8983  echo $ECHO_N "(cached) $ECHO_C" >&6
8984else
8985  cat >conftest.make <<\_ACEOF
8986SHELL = /bin/sh
8987all:
8988	@echo '@@@%%%=$(MAKE)=@@@%%%'
8989_ACEOF
8990# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
8991case `${MAKE-make} -f conftest.make 2>/dev/null` in
8992  *@@@%%%=?*=@@@%%%*)
8993    eval ac_cv_prog_make_${ac_make}_set=yes;;
8994  *)
8995    eval ac_cv_prog_make_${ac_make}_set=no;;
8996esac
8997rm -f conftest.make
8998fi
8999if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
9000  { echo "$as_me:$LINENO: result: yes" >&5
9001echo "${ECHO_T}yes" >&6; }
9002  SET_MAKE=
9003else
9004  { echo "$as_me:$LINENO: result: no" >&5
9005echo "${ECHO_T}no" >&6; }
9006  SET_MAKE="MAKE=${MAKE-make}"
9007fi
9008
9009
9010{ echo "$as_me:$LINENO: checking for long file names" >&5
9011echo $ECHO_N "checking for long file names... $ECHO_C" >&6; }
9012if test "${ac_cv_sys_long_file_names+set}" = set; then
9013  echo $ECHO_N "(cached) $ECHO_C" >&6
9014else
9015  ac_cv_sys_long_file_names=yes
9016# Test for long file names in all the places we know might matter:
9017#      .		the current directory, where building will happen
9018#      $prefix/lib	where we will be installing things
9019#      $exec_prefix/lib	likewise
9020#      $TMPDIR		if set, where it might want to write temporary files
9021#      /tmp		where it might want to write temporary files
9022#      /var/tmp		likewise
9023#      /usr/tmp		likewise
9024for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9025  # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9026  # in the usual case where exec_prefix is '${prefix}'.
9027  case $ac_dir in #(
9028    . | /* | ?:[\\/]*) ;; #(
9029    *) continue;;
9030  esac
9031  test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9032  ac_xdir=$ac_dir/cf$$
9033  (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9034  ac_tf1=$ac_xdir/conftest9012345
9035  ac_tf2=$ac_xdir/conftest9012346
9036  touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9037    ac_cv_sys_long_file_names=no
9038  rm -f -r "$ac_xdir" 2>/dev/null
9039  test $ac_cv_sys_long_file_names = no && break
9040done
9041fi
9042{ echo "$as_me:$LINENO: result: $ac_cv_sys_long_file_names" >&5
9043echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6; }
9044if test $ac_cv_sys_long_file_names = yes; then
9045
9046cat >>confdefs.h <<\_ACEOF
9047#define HAVE_LONG_FILE_NAMES 1
9048_ACEOF
9049
9050fi
9051
9052
9053#### Choose a window system.
9054
9055{ echo "$as_me:$LINENO: checking for X" >&5
9056echo $ECHO_N "checking for X... $ECHO_C" >&6; }
9057
9058
9059# Check whether --with-x was given.
9060if test "${with_x+set}" = set; then
9061  withval=$with_x;
9062fi
9063
9064# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9065if test "x$with_x" = xno; then
9066  # The user explicitly disabled X.
9067  have_x=disabled
9068else
9069  case $x_includes,$x_libraries in #(
9070    *\'*) { { echo "$as_me:$LINENO: error: Cannot use X directory names containing '" >&5
9071echo "$as_me: error: Cannot use X directory names containing '" >&2;}
9072   { (exit 1); exit 1; }; };; #(
9073    *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then
9074  echo $ECHO_N "(cached) $ECHO_C" >&6
9075else
9076  # One or both of the vars are not set, and there is no cached value.
9077ac_x_includes=no ac_x_libraries=no
9078rm -f -r conftest.dir
9079if mkdir conftest.dir; then
9080  cd conftest.dir
9081  cat >Imakefile <<'_ACEOF'
9082incroot:
9083	@echo incroot='${INCROOT}'
9084usrlibdir:
9085	@echo usrlibdir='${USRLIBDIR}'
9086libdir:
9087	@echo libdir='${LIBDIR}'
9088_ACEOF
9089  if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9090    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9091    for ac_var in incroot usrlibdir libdir; do
9092      eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9093    done
9094    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9095    for ac_extension in a so sl; do
9096      if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9097	 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9098	ac_im_usrlibdir=$ac_im_libdir; break
9099      fi
9100    done
9101    # Screen out bogus values from the imake configuration.  They are
9102    # bogus both because they are the default anyway, and because
9103    # using them would break gcc on systems where it needs fixed includes.
9104    case $ac_im_incroot in
9105	/usr/include) ac_x_includes= ;;
9106	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9107    esac
9108    case $ac_im_usrlibdir in
9109	/usr/lib | /lib) ;;
9110	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9111    esac
9112  fi
9113  cd ..
9114  rm -f -r conftest.dir
9115fi
9116
9117# Standard set of common directories for X headers.
9118# Check X11 before X11Rn because it is often a symlink to the current release.
9119ac_x_header_dirs='
9120/usr/X11/include
9121/usr/X11R6/include
9122/usr/X11R5/include
9123/usr/X11R4/include
9124
9125/usr/include/X11
9126/usr/include/X11R6
9127/usr/include/X11R5
9128/usr/include/X11R4
9129
9130/usr/local/X11/include
9131/usr/local/X11R6/include
9132/usr/local/X11R5/include
9133/usr/local/X11R4/include
9134
9135/usr/local/include/X11
9136/usr/local/include/X11R6
9137/usr/local/include/X11R5
9138/usr/local/include/X11R4
9139
9140/usr/X386/include
9141/usr/x386/include
9142/usr/XFree86/include/X11
9143
9144/usr/include
9145/usr/local/include
9146/usr/unsupported/include
9147/usr/athena/include
9148/usr/local/x11r5/include
9149/usr/lpp/Xamples/include
9150
9151/usr/openwin/include
9152/usr/openwin/share/include'
9153
9154if test "$ac_x_includes" = no; then
9155  # Guess where to find include files, by looking for Xlib.h.
9156  # First, try using that file with no special directory specified.
9157  cat >conftest.$ac_ext <<_ACEOF
9158/* confdefs.h.  */
9159_ACEOF
9160cat confdefs.h >>conftest.$ac_ext
9161cat >>conftest.$ac_ext <<_ACEOF
9162/* end confdefs.h.  */
9163#include <X11/Xlib.h>
9164_ACEOF
9165if { (ac_try="$ac_cpp conftest.$ac_ext"
9166case "(($ac_try" in
9167  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9168  *) ac_try_echo=$ac_try;;
9169esac
9170eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9171  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9172  ac_status=$?
9173  grep -v '^ *+' conftest.er1 >conftest.err
9174  rm -f conftest.er1
9175  cat conftest.err >&5
9176  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9177  (exit $ac_status); } >/dev/null && {
9178	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9179	 test ! -s conftest.err
9180       }; then
9181  # We can compile using X headers with no special include directory.
9182ac_x_includes=
9183else
9184  echo "$as_me: failed program was:" >&5
9185sed 's/^/| /' conftest.$ac_ext >&5
9186
9187  for ac_dir in $ac_x_header_dirs; do
9188  if test -r "$ac_dir/X11/Xlib.h"; then
9189    ac_x_includes=$ac_dir
9190    break
9191  fi
9192done
9193fi
9194
9195rm -f conftest.err conftest.$ac_ext
9196fi # $ac_x_includes = no
9197
9198if test "$ac_x_libraries" = no; then
9199  # Check for the libraries.
9200  # See if we find them without any special options.
9201  # Don't add to $LIBS permanently.
9202  ac_save_LIBS=$LIBS
9203  LIBS="-lX11 $LIBS"
9204  cat >conftest.$ac_ext <<_ACEOF
9205/* confdefs.h.  */
9206_ACEOF
9207cat confdefs.h >>conftest.$ac_ext
9208cat >>conftest.$ac_ext <<_ACEOF
9209/* end confdefs.h.  */
9210#include <X11/Xlib.h>
9211int
9212main ()
9213{
9214XrmInitialize ()
9215  ;
9216  return 0;
9217}
9218_ACEOF
9219rm -f conftest.$ac_objext conftest$ac_exeext
9220if { (ac_try="$ac_link"
9221case "(($ac_try" in
9222  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9223  *) ac_try_echo=$ac_try;;
9224esac
9225eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9226  (eval "$ac_link") 2>conftest.er1
9227  ac_status=$?
9228  grep -v '^ *+' conftest.er1 >conftest.err
9229  rm -f conftest.er1
9230  cat conftest.err >&5
9231  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9232  (exit $ac_status); } && {
9233	 test -z "$ac_c_werror_flag" ||
9234	 test ! -s conftest.err
9235       } && test -s conftest$ac_exeext &&
9236       $as_test_x conftest$ac_exeext; then
9237  LIBS=$ac_save_LIBS
9238# We can link X programs with no special library path.
9239ac_x_libraries=
9240else
9241  echo "$as_me: failed program was:" >&5
9242sed 's/^/| /' conftest.$ac_ext >&5
9243
9244	LIBS=$ac_save_LIBS
9245for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9246do
9247  # Don't even attempt the hair of trying to link an X program!
9248  for ac_extension in a so sl; do
9249    if test -r "$ac_dir/libX11.$ac_extension"; then
9250      ac_x_libraries=$ac_dir
9251      break 2
9252    fi
9253  done
9254done
9255fi
9256
9257rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9258      conftest$ac_exeext conftest.$ac_ext
9259fi # $ac_x_libraries = no
9260
9261case $ac_x_includes,$ac_x_libraries in #(
9262  no,* | *,no | *\'*)
9263    # Didn't find X, or a directory has "'" in its name.
9264    ac_cv_have_x="have_x=no";; #(
9265  *)
9266    # Record where we found X for the cache.
9267    ac_cv_have_x="have_x=yes\
9268	ac_x_includes='$ac_x_includes'\
9269	ac_x_libraries='$ac_x_libraries'"
9270esac
9271fi
9272;; #(
9273    *) have_x=yes;;
9274  esac
9275  eval "$ac_cv_have_x"
9276fi # $with_x != no
9277
9278if test "$have_x" != yes; then
9279  { echo "$as_me:$LINENO: result: $have_x" >&5
9280echo "${ECHO_T}$have_x" >&6; }
9281  no_x=yes
9282else
9283  # If each of the values was on the command line, it overrides each guess.
9284  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9285  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9286  # Update the cache value to reflect the command line values.
9287  ac_cv_have_x="have_x=yes\
9288	ac_x_includes='$x_includes'\
9289	ac_x_libraries='$x_libraries'"
9290  { echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
9291echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6; }
9292fi
9293
9294if test "$no_x" = yes; then
9295  window_system=none
9296else
9297  window_system=x11
9298fi
9299
9300if test "${x_libraries}" != NONE; then
9301  if test -n "${x_libraries}"; then
9302    LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9303    LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
9304  fi
9305  x_default_search_path=""
9306  x_search_path=${x_libraries}
9307  if test -z "${x_search_path}"; then
9308    x_search_path=/usr/lib
9309  fi
9310  for x_library in `echo ${x_search_path}: | \
9311		    sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9312    x_search_path="\
9313${x_library}/X11/%L/%T/%N%C%S:\
9314${x_library}/X11/%l/%T/%N%C%S:\
9315${x_library}/X11/%T/%N%C%S:\
9316${x_library}/X11/%L/%T/%N%S:\
9317${x_library}/X11/%l/%T/%N%S:\
9318${x_library}/X11/%T/%N%S"
9319    if test x"${x_default_search_path}" = x; then
9320      x_default_search_path=${x_search_path}
9321    else
9322      x_default_search_path="${x_search_path}:${x_default_search_path}"
9323    fi
9324  done
9325fi
9326if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9327  C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
9328fi
9329
9330if test x"${x_includes}" = x; then
9331  bitmapdir=/usr/include/X11/bitmaps
9332else
9333  # accumulate include directories that have X11 bitmap subdirectories
9334  bmd_acc="dummyval"
9335  for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9336    if test -d "${bmd}/X11/bitmaps"; then
9337      bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9338    fi
9339    if test -d "${bmd}/bitmaps"; then
9340      bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9341    fi
9342  done
9343  if test ${bmd_acc} != "dummyval"; then
9344    bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9345  fi
9346fi
9347
9348HAVE_CARBON=no
9349if test "${with_carbon}" != no; then
9350  if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
9351  { echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
9352echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6; }
9353if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
9354  echo $ECHO_N "(cached) $ECHO_C" >&6
9355fi
9356{ echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
9357echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6; }
9358else
9359  # Is the header compilable?
9360{ echo "$as_me:$LINENO: checking Carbon/Carbon.h usability" >&5
9361echo $ECHO_N "checking Carbon/Carbon.h usability... $ECHO_C" >&6; }
9362cat >conftest.$ac_ext <<_ACEOF
9363/* confdefs.h.  */
9364_ACEOF
9365cat confdefs.h >>conftest.$ac_ext
9366cat >>conftest.$ac_ext <<_ACEOF
9367/* end confdefs.h.  */
9368$ac_includes_default
9369#include <Carbon/Carbon.h>
9370_ACEOF
9371rm -f conftest.$ac_objext
9372if { (ac_try="$ac_compile"
9373case "(($ac_try" in
9374  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9375  *) ac_try_echo=$ac_try;;
9376esac
9377eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9378  (eval "$ac_compile") 2>conftest.er1
9379  ac_status=$?
9380  grep -v '^ *+' conftest.er1 >conftest.err
9381  rm -f conftest.er1
9382  cat conftest.err >&5
9383  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9384  (exit $ac_status); } && {
9385	 test -z "$ac_c_werror_flag" ||
9386	 test ! -s conftest.err
9387       } && test -s conftest.$ac_objext; then
9388  ac_header_compiler=yes
9389else
9390  echo "$as_me: failed program was:" >&5
9391sed 's/^/| /' conftest.$ac_ext >&5
9392
9393	ac_header_compiler=no
9394fi
9395
9396rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9397{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9398echo "${ECHO_T}$ac_header_compiler" >&6; }
9399
9400# Is the header present?
9401{ echo "$as_me:$LINENO: checking Carbon/Carbon.h presence" >&5
9402echo $ECHO_N "checking Carbon/Carbon.h presence... $ECHO_C" >&6; }
9403cat >conftest.$ac_ext <<_ACEOF
9404/* confdefs.h.  */
9405_ACEOF
9406cat confdefs.h >>conftest.$ac_ext
9407cat >>conftest.$ac_ext <<_ACEOF
9408/* end confdefs.h.  */
9409#include <Carbon/Carbon.h>
9410_ACEOF
9411if { (ac_try="$ac_cpp conftest.$ac_ext"
9412case "(($ac_try" in
9413  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9414  *) ac_try_echo=$ac_try;;
9415esac
9416eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9417  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9418  ac_status=$?
9419  grep -v '^ *+' conftest.er1 >conftest.err
9420  rm -f conftest.er1
9421  cat conftest.err >&5
9422  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9423  (exit $ac_status); } >/dev/null && {
9424	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9425	 test ! -s conftest.err
9426       }; then
9427  ac_header_preproc=yes
9428else
9429  echo "$as_me: failed program was:" >&5
9430sed 's/^/| /' conftest.$ac_ext >&5
9431
9432  ac_header_preproc=no
9433fi
9434
9435rm -f conftest.err conftest.$ac_ext
9436{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9437echo "${ECHO_T}$ac_header_preproc" >&6; }
9438
9439# So?  What about this header?
9440case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9441  yes:no: )
9442    { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&5
9443echo "$as_me: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9444    { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&5
9445echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&2;}
9446    ac_header_preproc=yes
9447    ;;
9448  no:yes:* )
9449    { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&5
9450echo "$as_me: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&2;}
9451    { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h:     check for missing prerequisite headers?" >&5
9452echo "$as_me: WARNING: Carbon/Carbon.h:     check for missing prerequisite headers?" >&2;}
9453    { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&5
9454echo "$as_me: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&2;}
9455    { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h:     section \"Present But Cannot Be Compiled\"" >&5
9456echo "$as_me: WARNING: Carbon/Carbon.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9457    { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
9458echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
9459    { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&5
9460echo "$as_me: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&2;}
9461
9462    ;;
9463esac
9464{ echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
9465echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6; }
9466if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
9467  echo $ECHO_N "(cached) $ECHO_C" >&6
9468else
9469  ac_cv_header_Carbon_Carbon_h=$ac_header_preproc
9470fi
9471{ echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
9472echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6; }
9473
9474fi
9475if test $ac_cv_header_Carbon_Carbon_h = yes; then
9476  HAVE_CARBON=yes
9477fi
9478
9479
9480fi
9481if test "${window_system}" = x11 && test "${HAVE_CARBON}" = yes; then
9482  if test "${with_carbon+set}" != set \
9483     && test "${carbon_appdir_x+set}" != set; then
9484    for var in with_x with_x_toolkit with_gtk with_xim \
9485               with_xpm with_jpeg with_tiff with_gif with_png; do
9486      if eval test \"\${$var+set}\" = set; then
9487        HAVE_CARBON=no
9488        break
9489      fi
9490    done
9491  fi
9492fi
9493if test "${HAVE_CARBON}" = yes; then
9494  window_system=mac
9495fi
9496
9497case "${window_system}" in
9498  x11 )
9499    HAVE_X_WINDOWS=yes
9500    HAVE_X11=yes
9501    case "${with_x_toolkit}" in
9502      athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9503      motif ) USE_X_TOOLKIT=MOTIF ;;
9504      gtk ) with_gtk=yes
9505            USE_X_TOOLKIT=none ;;
9506      no ) USE_X_TOOLKIT=none ;;
9507      * ) USE_X_TOOLKIT=maybe ;;
9508    esac
9509  ;;
9510  mac | none )
9511    HAVE_X_WINDOWS=no
9512    HAVE_X11=no
9513    USE_X_TOOLKIT=none
9514  ;;
9515esac
9516
9517### If we're using X11, we should use the X menu package.
9518HAVE_MENUS=no
9519case ${HAVE_X11} in
9520  yes ) HAVE_MENUS=yes ;;
9521esac
9522
9523if test "${opsys}" = "hpux9"; then
9524  case "${x_libraries}" in
9525    *X11R4* )
9526      opsysfile="s/hpux9-x11r4.h"
9527      ;;
9528  esac
9529fi
9530
9531if test "${opsys}" = "hpux9shr"; then
9532  case "${x_libraries}" in
9533    *X11R4* )
9534      opsysfile="s/hpux9shxr4.h"
9535      ;;
9536  esac
9537fi
9538
9539### Compute the unexec source name from the object name.
9540UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`"
9541
9542# Do the opsystem or machine files prohibit the use of the GNU malloc?
9543# Assume not, until told otherwise.
9544GNU_MALLOC=yes
9545doug_lea_malloc=yes
9546{ echo "$as_me:$LINENO: checking for malloc_get_state" >&5
9547echo $ECHO_N "checking for malloc_get_state... $ECHO_C" >&6; }
9548if test "${ac_cv_func_malloc_get_state+set}" = set; then
9549  echo $ECHO_N "(cached) $ECHO_C" >&6
9550else
9551  cat >conftest.$ac_ext <<_ACEOF
9552/* confdefs.h.  */
9553_ACEOF
9554cat confdefs.h >>conftest.$ac_ext
9555cat >>conftest.$ac_ext <<_ACEOF
9556/* end confdefs.h.  */
9557/* Define malloc_get_state to an innocuous variant, in case <limits.h> declares malloc_get_state.
9558   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9559#define malloc_get_state innocuous_malloc_get_state
9560
9561/* System header to define __stub macros and hopefully few prototypes,
9562    which can conflict with char malloc_get_state (); below.
9563    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9564    <limits.h> exists even on freestanding compilers.  */
9565
9566#ifdef __STDC__
9567# include <limits.h>
9568#else
9569# include <assert.h>
9570#endif
9571
9572#undef malloc_get_state
9573
9574/* Override any GCC internal prototype to avoid an error.
9575   Use char because int might match the return type of a GCC
9576   builtin and then its argument prototype would still apply.  */
9577#ifdef __cplusplus
9578extern "C"
9579#endif
9580char malloc_get_state ();
9581/* The GNU C library defines this for functions which it implements
9582    to always fail with ENOSYS.  Some functions are actually named
9583    something starting with __ and the normal name is an alias.  */
9584#if defined __stub_malloc_get_state || defined __stub___malloc_get_state
9585choke me
9586#endif
9587
9588int
9589main ()
9590{
9591return malloc_get_state ();
9592  ;
9593  return 0;
9594}
9595_ACEOF
9596rm -f conftest.$ac_objext conftest$ac_exeext
9597if { (ac_try="$ac_link"
9598case "(($ac_try" in
9599  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9600  *) ac_try_echo=$ac_try;;
9601esac
9602eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9603  (eval "$ac_link") 2>conftest.er1
9604  ac_status=$?
9605  grep -v '^ *+' conftest.er1 >conftest.err
9606  rm -f conftest.er1
9607  cat conftest.err >&5
9608  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9609  (exit $ac_status); } && {
9610	 test -z "$ac_c_werror_flag" ||
9611	 test ! -s conftest.err
9612       } && test -s conftest$ac_exeext &&
9613       $as_test_x conftest$ac_exeext; then
9614  ac_cv_func_malloc_get_state=yes
9615else
9616  echo "$as_me: failed program was:" >&5
9617sed 's/^/| /' conftest.$ac_ext >&5
9618
9619	ac_cv_func_malloc_get_state=no
9620fi
9621
9622rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9623      conftest$ac_exeext conftest.$ac_ext
9624fi
9625{ echo "$as_me:$LINENO: result: $ac_cv_func_malloc_get_state" >&5
9626echo "${ECHO_T}$ac_cv_func_malloc_get_state" >&6; }
9627if test $ac_cv_func_malloc_get_state = yes; then
9628  :
9629else
9630  doug_lea_malloc=no
9631fi
9632
9633{ echo "$as_me:$LINENO: checking for malloc_set_state" >&5
9634echo $ECHO_N "checking for malloc_set_state... $ECHO_C" >&6; }
9635if test "${ac_cv_func_malloc_set_state+set}" = set; then
9636  echo $ECHO_N "(cached) $ECHO_C" >&6
9637else
9638  cat >conftest.$ac_ext <<_ACEOF
9639/* confdefs.h.  */
9640_ACEOF
9641cat confdefs.h >>conftest.$ac_ext
9642cat >>conftest.$ac_ext <<_ACEOF
9643/* end confdefs.h.  */
9644/* Define malloc_set_state to an innocuous variant, in case <limits.h> declares malloc_set_state.
9645   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9646#define malloc_set_state innocuous_malloc_set_state
9647
9648/* System header to define __stub macros and hopefully few prototypes,
9649    which can conflict with char malloc_set_state (); below.
9650    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9651    <limits.h> exists even on freestanding compilers.  */
9652
9653#ifdef __STDC__
9654# include <limits.h>
9655#else
9656# include <assert.h>
9657#endif
9658
9659#undef malloc_set_state
9660
9661/* Override any GCC internal prototype to avoid an error.
9662   Use char because int might match the return type of a GCC
9663   builtin and then its argument prototype would still apply.  */
9664#ifdef __cplusplus
9665extern "C"
9666#endif
9667char malloc_set_state ();
9668/* The GNU C library defines this for functions which it implements
9669    to always fail with ENOSYS.  Some functions are actually named
9670    something starting with __ and the normal name is an alias.  */
9671#if defined __stub_malloc_set_state || defined __stub___malloc_set_state
9672choke me
9673#endif
9674
9675int
9676main ()
9677{
9678return malloc_set_state ();
9679  ;
9680  return 0;
9681}
9682_ACEOF
9683rm -f conftest.$ac_objext conftest$ac_exeext
9684if { (ac_try="$ac_link"
9685case "(($ac_try" in
9686  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9687  *) ac_try_echo=$ac_try;;
9688esac
9689eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9690  (eval "$ac_link") 2>conftest.er1
9691  ac_status=$?
9692  grep -v '^ *+' conftest.er1 >conftest.err
9693  rm -f conftest.er1
9694  cat conftest.err >&5
9695  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9696  (exit $ac_status); } && {
9697	 test -z "$ac_c_werror_flag" ||
9698	 test ! -s conftest.err
9699       } && test -s conftest$ac_exeext &&
9700       $as_test_x conftest$ac_exeext; then
9701  ac_cv_func_malloc_set_state=yes
9702else
9703  echo "$as_me: failed program was:" >&5
9704sed 's/^/| /' conftest.$ac_ext >&5
9705
9706	ac_cv_func_malloc_set_state=no
9707fi
9708
9709rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9710      conftest$ac_exeext conftest.$ac_ext
9711fi
9712{ echo "$as_me:$LINENO: result: $ac_cv_func_malloc_set_state" >&5
9713echo "${ECHO_T}$ac_cv_func_malloc_set_state" >&6; }
9714if test $ac_cv_func_malloc_set_state = yes; then
9715  :
9716else
9717  doug_lea_malloc=no
9718fi
9719
9720{ echo "$as_me:$LINENO: checking whether __after_morecore_hook exists" >&5
9721echo $ECHO_N "checking whether __after_morecore_hook exists... $ECHO_C" >&6; }
9722if test "${emacs_cv_var___after_morecore_hook+set}" = set; then
9723  echo $ECHO_N "(cached) $ECHO_C" >&6
9724else
9725  cat >conftest.$ac_ext <<_ACEOF
9726/* confdefs.h.  */
9727_ACEOF
9728cat confdefs.h >>conftest.$ac_ext
9729cat >>conftest.$ac_ext <<_ACEOF
9730/* end confdefs.h.  */
9731extern void (* __after_morecore_hook)();
9732int
9733main ()
9734{
9735__after_morecore_hook = 0
9736  ;
9737  return 0;
9738}
9739_ACEOF
9740rm -f conftest.$ac_objext conftest$ac_exeext
9741if { (ac_try="$ac_link"
9742case "(($ac_try" in
9743  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9744  *) ac_try_echo=$ac_try;;
9745esac
9746eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9747  (eval "$ac_link") 2>conftest.er1
9748  ac_status=$?
9749  grep -v '^ *+' conftest.er1 >conftest.err
9750  rm -f conftest.er1
9751  cat conftest.err >&5
9752  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9753  (exit $ac_status); } && {
9754	 test -z "$ac_c_werror_flag" ||
9755	 test ! -s conftest.err
9756       } && test -s conftest$ac_exeext &&
9757       $as_test_x conftest$ac_exeext; then
9758  emacs_cv_var___after_morecore_hook=yes
9759else
9760  echo "$as_me: failed program was:" >&5
9761sed 's/^/| /' conftest.$ac_ext >&5
9762
9763	emacs_cv_var___after_morecore_hook=no
9764fi
9765
9766rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9767      conftest$ac_exeext conftest.$ac_ext
9768fi
9769{ echo "$as_me:$LINENO: result: $emacs_cv_var___after_morecore_hook" >&5
9770echo "${ECHO_T}$emacs_cv_var___after_morecore_hook" >&6; }
9771if test $emacs_cv_var___after_morecore_hook = no; then
9772  doug_lea_malloc=no
9773fi
9774if test "${system_malloc}" = "yes"; then
9775  GNU_MALLOC=no
9776  GNU_MALLOC_reason="
9777    (The GNU allocators don't work with this system configuration.)"
9778fi
9779if test "$doug_lea_malloc" = "yes" ; then
9780  if test "$GNU_MALLOC" = yes ; then
9781    GNU_MALLOC_reason="
9782      (Using Doug Lea's new malloc from the GNU C Library.)"
9783  fi
9784
9785cat >>confdefs.h <<\_ACEOF
9786#define DOUG_LEA_MALLOC 1
9787_ACEOF
9788
9789fi
9790
9791if test x"${REL_ALLOC}" = x; then
9792  REL_ALLOC=${GNU_MALLOC}
9793fi
9794
9795
9796
9797
9798for ac_header in stdlib.h unistd.h
9799do
9800as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9801if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9802  { echo "$as_me:$LINENO: checking for $ac_header" >&5
9803echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9804if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9805  echo $ECHO_N "(cached) $ECHO_C" >&6
9806fi
9807ac_res=`eval echo '${'$as_ac_Header'}'`
9808	       { echo "$as_me:$LINENO: result: $ac_res" >&5
9809echo "${ECHO_T}$ac_res" >&6; }
9810else
9811  # Is the header compilable?
9812{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
9813echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9814cat >conftest.$ac_ext <<_ACEOF
9815/* confdefs.h.  */
9816_ACEOF
9817cat confdefs.h >>conftest.$ac_ext
9818cat >>conftest.$ac_ext <<_ACEOF
9819/* end confdefs.h.  */
9820$ac_includes_default
9821#include <$ac_header>
9822_ACEOF
9823rm -f conftest.$ac_objext
9824if { (ac_try="$ac_compile"
9825case "(($ac_try" in
9826  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9827  *) ac_try_echo=$ac_try;;
9828esac
9829eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9830  (eval "$ac_compile") 2>conftest.er1
9831  ac_status=$?
9832  grep -v '^ *+' conftest.er1 >conftest.err
9833  rm -f conftest.er1
9834  cat conftest.err >&5
9835  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9836  (exit $ac_status); } && {
9837	 test -z "$ac_c_werror_flag" ||
9838	 test ! -s conftest.err
9839       } && test -s conftest.$ac_objext; then
9840  ac_header_compiler=yes
9841else
9842  echo "$as_me: failed program was:" >&5
9843sed 's/^/| /' conftest.$ac_ext >&5
9844
9845	ac_header_compiler=no
9846fi
9847
9848rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9849{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9850echo "${ECHO_T}$ac_header_compiler" >&6; }
9851
9852# Is the header present?
9853{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
9854echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9855cat >conftest.$ac_ext <<_ACEOF
9856/* confdefs.h.  */
9857_ACEOF
9858cat confdefs.h >>conftest.$ac_ext
9859cat >>conftest.$ac_ext <<_ACEOF
9860/* end confdefs.h.  */
9861#include <$ac_header>
9862_ACEOF
9863if { (ac_try="$ac_cpp conftest.$ac_ext"
9864case "(($ac_try" in
9865  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9866  *) ac_try_echo=$ac_try;;
9867esac
9868eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9869  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9870  ac_status=$?
9871  grep -v '^ *+' conftest.er1 >conftest.err
9872  rm -f conftest.er1
9873  cat conftest.err >&5
9874  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9875  (exit $ac_status); } >/dev/null && {
9876	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9877	 test ! -s conftest.err
9878       }; then
9879  ac_header_preproc=yes
9880else
9881  echo "$as_me: failed program was:" >&5
9882sed 's/^/| /' conftest.$ac_ext >&5
9883
9884  ac_header_preproc=no
9885fi
9886
9887rm -f conftest.err conftest.$ac_ext
9888{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9889echo "${ECHO_T}$ac_header_preproc" >&6; }
9890
9891# So?  What about this header?
9892case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9893  yes:no: )
9894    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9895echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9896    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9897echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9898    ac_header_preproc=yes
9899    ;;
9900  no:yes:* )
9901    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9902echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9903    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9904echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9905    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9906echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9907    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9908echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9909    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9910echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9911    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9912echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9913
9914    ;;
9915esac
9916{ echo "$as_me:$LINENO: checking for $ac_header" >&5
9917echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9918if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9919  echo $ECHO_N "(cached) $ECHO_C" >&6
9920else
9921  eval "$as_ac_Header=\$ac_header_preproc"
9922fi
9923ac_res=`eval echo '${'$as_ac_Header'}'`
9924	       { echo "$as_me:$LINENO: result: $ac_res" >&5
9925echo "${ECHO_T}$ac_res" >&6; }
9926
9927fi
9928if test `eval echo '${'$as_ac_Header'}'` = yes; then
9929  cat >>confdefs.h <<_ACEOF
9930#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9931_ACEOF
9932
9933fi
9934
9935done
9936
9937
9938for ac_func in getpagesize
9939do
9940as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9941{ echo "$as_me:$LINENO: checking for $ac_func" >&5
9942echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
9943if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
9944  echo $ECHO_N "(cached) $ECHO_C" >&6
9945else
9946  cat >conftest.$ac_ext <<_ACEOF
9947/* confdefs.h.  */
9948_ACEOF
9949cat confdefs.h >>conftest.$ac_ext
9950cat >>conftest.$ac_ext <<_ACEOF
9951/* end confdefs.h.  */
9952/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
9953   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9954#define $ac_func innocuous_$ac_func
9955
9956/* System header to define __stub macros and hopefully few prototypes,
9957    which can conflict with char $ac_func (); below.
9958    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9959    <limits.h> exists even on freestanding compilers.  */
9960
9961#ifdef __STDC__
9962# include <limits.h>
9963#else
9964# include <assert.h>
9965#endif
9966
9967#undef $ac_func
9968
9969/* Override any GCC internal prototype to avoid an error.
9970   Use char because int might match the return type of a GCC
9971   builtin and then its argument prototype would still apply.  */
9972#ifdef __cplusplus
9973extern "C"
9974#endif
9975char $ac_func ();
9976/* The GNU C library defines this for functions which it implements
9977    to always fail with ENOSYS.  Some functions are actually named
9978    something starting with __ and the normal name is an alias.  */
9979#if defined __stub_$ac_func || defined __stub___$ac_func
9980choke me
9981#endif
9982
9983int
9984main ()
9985{
9986return $ac_func ();
9987  ;
9988  return 0;
9989}
9990_ACEOF
9991rm -f conftest.$ac_objext conftest$ac_exeext
9992if { (ac_try="$ac_link"
9993case "(($ac_try" in
9994  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9995  *) ac_try_echo=$ac_try;;
9996esac
9997eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9998  (eval "$ac_link") 2>conftest.er1
9999  ac_status=$?
10000  grep -v '^ *+' conftest.er1 >conftest.err
10001  rm -f conftest.er1
10002  cat conftest.err >&5
10003  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10004  (exit $ac_status); } && {
10005	 test -z "$ac_c_werror_flag" ||
10006	 test ! -s conftest.err
10007       } && test -s conftest$ac_exeext &&
10008       $as_test_x conftest$ac_exeext; then
10009  eval "$as_ac_var=yes"
10010else
10011  echo "$as_me: failed program was:" >&5
10012sed 's/^/| /' conftest.$ac_ext >&5
10013
10014	eval "$as_ac_var=no"
10015fi
10016
10017rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10018      conftest$ac_exeext conftest.$ac_ext
10019fi
10020ac_res=`eval echo '${'$as_ac_var'}'`
10021	       { echo "$as_me:$LINENO: result: $ac_res" >&5
10022echo "${ECHO_T}$ac_res" >&6; }
10023if test `eval echo '${'$as_ac_var'}'` = yes; then
10024  cat >>confdefs.h <<_ACEOF
10025#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10026_ACEOF
10027
10028fi
10029done
10030
10031{ echo "$as_me:$LINENO: checking for working mmap" >&5
10032echo $ECHO_N "checking for working mmap... $ECHO_C" >&6; }
10033if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
10034  echo $ECHO_N "(cached) $ECHO_C" >&6
10035else
10036  if test "$cross_compiling" = yes; then
10037  ac_cv_func_mmap_fixed_mapped=no
10038else
10039  cat >conftest.$ac_ext <<_ACEOF
10040/* confdefs.h.  */
10041_ACEOF
10042cat confdefs.h >>conftest.$ac_ext
10043cat >>conftest.$ac_ext <<_ACEOF
10044/* end confdefs.h.  */
10045$ac_includes_default
10046/* malloc might have been renamed as rpl_malloc. */
10047#undef malloc
10048
10049/* Thanks to Mike Haertel and Jim Avera for this test.
10050   Here is a matrix of mmap possibilities:
10051	mmap private not fixed
10052	mmap private fixed at somewhere currently unmapped
10053	mmap private fixed at somewhere already mapped
10054	mmap shared not fixed
10055	mmap shared fixed at somewhere currently unmapped
10056	mmap shared fixed at somewhere already mapped
10057   For private mappings, we should verify that changes cannot be read()
10058   back from the file, nor mmap's back from the file at a different
10059   address.  (There have been systems where private was not correctly
10060   implemented like the infamous i386 svr4.0, and systems where the
10061   VM page cache was not coherent with the file system buffer cache
10062   like early versions of FreeBSD and possibly contemporary NetBSD.)
10063   For shared mappings, we should conversely verify that changes get
10064   propagated back to all the places they're supposed to be.
10065
10066   Grep wants private fixed already mapped.
10067   The main things grep needs to know about mmap are:
10068   * does it exist and is it safe to write into the mmap'd area
10069   * how to use it (BSD variants)  */
10070
10071#include <fcntl.h>
10072#include <sys/mman.h>
10073
10074#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10075char *malloc ();
10076#endif
10077
10078/* This mess was copied from the GNU getpagesize.h.  */
10079#ifndef HAVE_GETPAGESIZE
10080/* Assume that all systems that can run configure have sys/param.h.  */
10081# ifndef HAVE_SYS_PARAM_H
10082#  define HAVE_SYS_PARAM_H 1
10083# endif
10084
10085# ifdef _SC_PAGESIZE
10086#  define getpagesize() sysconf(_SC_PAGESIZE)
10087# else /* no _SC_PAGESIZE */
10088#  ifdef HAVE_SYS_PARAM_H
10089#   include <sys/param.h>
10090#   ifdef EXEC_PAGESIZE
10091#    define getpagesize() EXEC_PAGESIZE
10092#   else /* no EXEC_PAGESIZE */
10093#    ifdef NBPG
10094#     define getpagesize() NBPG * CLSIZE
10095#     ifndef CLSIZE
10096#      define CLSIZE 1
10097#     endif /* no CLSIZE */
10098#    else /* no NBPG */
10099#     ifdef NBPC
10100#      define getpagesize() NBPC
10101#     else /* no NBPC */
10102#      ifdef PAGESIZE
10103#       define getpagesize() PAGESIZE
10104#      endif /* PAGESIZE */
10105#     endif /* no NBPC */
10106#    endif /* no NBPG */
10107#   endif /* no EXEC_PAGESIZE */
10108#  else /* no HAVE_SYS_PARAM_H */
10109#   define getpagesize() 8192	/* punt totally */
10110#  endif /* no HAVE_SYS_PARAM_H */
10111# endif /* no _SC_PAGESIZE */
10112
10113#endif /* no HAVE_GETPAGESIZE */
10114
10115int
10116main ()
10117{
10118  char *data, *data2, *data3;
10119  int i, pagesize;
10120  int fd;
10121
10122  pagesize = getpagesize ();
10123
10124  /* First, make a file with some known garbage in it. */
10125  data = (char *) malloc (pagesize);
10126  if (!data)
10127    return 1;
10128  for (i = 0; i < pagesize; ++i)
10129    *(data + i) = rand ();
10130  umask (0);
10131  fd = creat ("conftest.mmap", 0600);
10132  if (fd < 0)
10133    return 1;
10134  if (write (fd, data, pagesize) != pagesize)
10135    return 1;
10136  close (fd);
10137
10138  /* Next, try to mmap the file at a fixed address which already has
10139     something else allocated at it.  If we can, also make sure that
10140     we see the same garbage.  */
10141  fd = open ("conftest.mmap", O_RDWR);
10142  if (fd < 0)
10143    return 1;
10144  data2 = (char *) malloc (2 * pagesize);
10145  if (!data2)
10146    return 1;
10147  data2 += (pagesize - ((long int) data2 & (pagesize - 1))) & (pagesize - 1);
10148  if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10149		     MAP_PRIVATE | MAP_FIXED, fd, 0L))
10150    return 1;
10151  for (i = 0; i < pagesize; ++i)
10152    if (*(data + i) != *(data2 + i))
10153      return 1;
10154
10155  /* Finally, make sure that changes to the mapped area do not
10156     percolate back to the file as seen by read().  (This is a bug on
10157     some variants of i386 svr4.0.)  */
10158  for (i = 0; i < pagesize; ++i)
10159    *(data2 + i) = *(data2 + i) + 1;
10160  data3 = (char *) malloc (pagesize);
10161  if (!data3)
10162    return 1;
10163  if (read (fd, data3, pagesize) != pagesize)
10164    return 1;
10165  for (i = 0; i < pagesize; ++i)
10166    if (*(data + i) != *(data3 + i))
10167      return 1;
10168  close (fd);
10169  return 0;
10170}
10171_ACEOF
10172rm -f conftest$ac_exeext
10173if { (ac_try="$ac_link"
10174case "(($ac_try" in
10175  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10176  *) ac_try_echo=$ac_try;;
10177esac
10178eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10179  (eval "$ac_link") 2>&5
10180  ac_status=$?
10181  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10182  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10183  { (case "(($ac_try" in
10184  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10185  *) ac_try_echo=$ac_try;;
10186esac
10187eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10188  (eval "$ac_try") 2>&5
10189  ac_status=$?
10190  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10191  (exit $ac_status); }; }; then
10192  ac_cv_func_mmap_fixed_mapped=yes
10193else
10194  echo "$as_me: program exited with status $ac_status" >&5
10195echo "$as_me: failed program was:" >&5
10196sed 's/^/| /' conftest.$ac_ext >&5
10197
10198( exit $ac_status )
10199ac_cv_func_mmap_fixed_mapped=no
10200fi
10201rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10202fi
10203
10204
10205fi
10206{ echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
10207echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6; }
10208if test $ac_cv_func_mmap_fixed_mapped = yes; then
10209
10210cat >>confdefs.h <<\_ACEOF
10211#define HAVE_MMAP 1
10212_ACEOF
10213
10214fi
10215rm -f conftest.mmap
10216
10217if test $use_mmap_for_buffers = yes; then
10218  REL_ALLOC=no
10219fi
10220
10221LIBS="$libsrc_libs $LIBS"
10222
10223
10224{ echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet" >&5
10225echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6; }
10226if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
10227  echo $ECHO_N "(cached) $ECHO_C" >&6
10228else
10229  ac_check_lib_save_LIBS=$LIBS
10230LIBS="-ldnet  $LIBS"
10231cat >conftest.$ac_ext <<_ACEOF
10232/* confdefs.h.  */
10233_ACEOF
10234cat confdefs.h >>conftest.$ac_ext
10235cat >>conftest.$ac_ext <<_ACEOF
10236/* end confdefs.h.  */
10237
10238/* Override any GCC internal prototype to avoid an error.
10239   Use char because int might match the return type of a GCC
10240   builtin and then its argument prototype would still apply.  */
10241#ifdef __cplusplus
10242extern "C"
10243#endif
10244char dnet_ntoa ();
10245int
10246main ()
10247{
10248return dnet_ntoa ();
10249  ;
10250  return 0;
10251}
10252_ACEOF
10253rm -f conftest.$ac_objext conftest$ac_exeext
10254if { (ac_try="$ac_link"
10255case "(($ac_try" in
10256  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10257  *) ac_try_echo=$ac_try;;
10258esac
10259eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10260  (eval "$ac_link") 2>conftest.er1
10261  ac_status=$?
10262  grep -v '^ *+' conftest.er1 >conftest.err
10263  rm -f conftest.er1
10264  cat conftest.err >&5
10265  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10266  (exit $ac_status); } && {
10267	 test -z "$ac_c_werror_flag" ||
10268	 test ! -s conftest.err
10269       } && test -s conftest$ac_exeext &&
10270       $as_test_x conftest$ac_exeext; then
10271  ac_cv_lib_dnet_dnet_ntoa=yes
10272else
10273  echo "$as_me: failed program was:" >&5
10274sed 's/^/| /' conftest.$ac_ext >&5
10275
10276	ac_cv_lib_dnet_dnet_ntoa=no
10277fi
10278
10279rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10280      conftest$ac_exeext conftest.$ac_ext
10281LIBS=$ac_check_lib_save_LIBS
10282fi
10283{ echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10284echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10285if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
10286  cat >>confdefs.h <<_ACEOF
10287#define HAVE_LIBDNET 1
10288_ACEOF
10289
10290  LIBS="-ldnet $LIBS"
10291
10292fi
10293
10294
10295{ echo "$as_me:$LINENO: checking for main in -lXbsd" >&5
10296echo $ECHO_N "checking for main in -lXbsd... $ECHO_C" >&6; }
10297if test "${ac_cv_lib_Xbsd_main+set}" = set; then
10298  echo $ECHO_N "(cached) $ECHO_C" >&6
10299else
10300  ac_check_lib_save_LIBS=$LIBS
10301LIBS="-lXbsd  $LIBS"
10302cat >conftest.$ac_ext <<_ACEOF
10303/* confdefs.h.  */
10304_ACEOF
10305cat confdefs.h >>conftest.$ac_ext
10306cat >>conftest.$ac_ext <<_ACEOF
10307/* end confdefs.h.  */
10308
10309
10310int
10311main ()
10312{
10313return main ();
10314  ;
10315  return 0;
10316}
10317_ACEOF
10318rm -f conftest.$ac_objext conftest$ac_exeext
10319if { (ac_try="$ac_link"
10320case "(($ac_try" in
10321  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10322  *) ac_try_echo=$ac_try;;
10323esac
10324eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10325  (eval "$ac_link") 2>conftest.er1
10326  ac_status=$?
10327  grep -v '^ *+' conftest.er1 >conftest.err
10328  rm -f conftest.er1
10329  cat conftest.err >&5
10330  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10331  (exit $ac_status); } && {
10332	 test -z "$ac_c_werror_flag" ||
10333	 test ! -s conftest.err
10334       } && test -s conftest$ac_exeext &&
10335       $as_test_x conftest$ac_exeext; then
10336  ac_cv_lib_Xbsd_main=yes
10337else
10338  echo "$as_me: failed program was:" >&5
10339sed 's/^/| /' conftest.$ac_ext >&5
10340
10341	ac_cv_lib_Xbsd_main=no
10342fi
10343
10344rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10345      conftest$ac_exeext conftest.$ac_ext
10346LIBS=$ac_check_lib_save_LIBS
10347fi
10348{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xbsd_main" >&5
10349echo "${ECHO_T}$ac_cv_lib_Xbsd_main" >&6; }
10350if test $ac_cv_lib_Xbsd_main = yes; then
10351  LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10352fi
10353
10354
10355
10356{ echo "$as_me:$LINENO: checking for cma_open in -lpthreads" >&5
10357echo $ECHO_N "checking for cma_open in -lpthreads... $ECHO_C" >&6; }
10358if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then
10359  echo $ECHO_N "(cached) $ECHO_C" >&6
10360else
10361  ac_check_lib_save_LIBS=$LIBS
10362LIBS="-lpthreads  $LIBS"
10363cat >conftest.$ac_ext <<_ACEOF
10364/* confdefs.h.  */
10365_ACEOF
10366cat confdefs.h >>conftest.$ac_ext
10367cat >>conftest.$ac_ext <<_ACEOF
10368/* end confdefs.h.  */
10369
10370/* Override any GCC internal prototype to avoid an error.
10371   Use char because int might match the return type of a GCC
10372   builtin and then its argument prototype would still apply.  */
10373#ifdef __cplusplus
10374extern "C"
10375#endif
10376char cma_open ();
10377int
10378main ()
10379{
10380return cma_open ();
10381  ;
10382  return 0;
10383}
10384_ACEOF
10385rm -f conftest.$ac_objext conftest$ac_exeext
10386if { (ac_try="$ac_link"
10387case "(($ac_try" in
10388  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10389  *) ac_try_echo=$ac_try;;
10390esac
10391eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10392  (eval "$ac_link") 2>conftest.er1
10393  ac_status=$?
10394  grep -v '^ *+' conftest.er1 >conftest.err
10395  rm -f conftest.er1
10396  cat conftest.err >&5
10397  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10398  (exit $ac_status); } && {
10399	 test -z "$ac_c_werror_flag" ||
10400	 test ! -s conftest.err
10401       } && test -s conftest$ac_exeext &&
10402       $as_test_x conftest$ac_exeext; then
10403  ac_cv_lib_pthreads_cma_open=yes
10404else
10405  echo "$as_me: failed program was:" >&5
10406sed 's/^/| /' conftest.$ac_ext >&5
10407
10408	ac_cv_lib_pthreads_cma_open=no
10409fi
10410
10411rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10412      conftest$ac_exeext conftest.$ac_ext
10413LIBS=$ac_check_lib_save_LIBS
10414fi
10415{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_cma_open" >&5
10416echo "${ECHO_T}$ac_cv_lib_pthreads_cma_open" >&6; }
10417if test $ac_cv_lib_pthreads_cma_open = yes; then
10418  cat >>confdefs.h <<_ACEOF
10419#define HAVE_LIBPTHREADS 1
10420_ACEOF
10421
10422  LIBS="-lpthreads $LIBS"
10423
10424fi
10425
10426
10427{ echo "$as_me:$LINENO: checking for XFree86 in /usr/X386" >&5
10428echo $ECHO_N "checking for XFree86 in /usr/X386... $ECHO_C" >&6; }
10429if test -d /usr/X386/include; then
10430  HAVE_XFREE386=yes
10431  : ${C_SWITCH_X_SITE="-I/usr/X386/include"}
10432else
10433  HAVE_XFREE386=no
10434fi
10435{ echo "$as_me:$LINENO: result: $HAVE_XFREE386" >&5
10436echo "${ECHO_T}$HAVE_XFREE386" >&6; }
10437
10438
10439case ${host_os} in
10440aix*)
10441  { echo "$as_me:$LINENO: checking for -bbigtoc option" >&5
10442echo $ECHO_N "checking for -bbigtoc option... $ECHO_C" >&6; }
10443if test "${gdb_cv_bigtoc+set}" = set; then
10444  echo $ECHO_N "(cached) $ECHO_C" >&6
10445else
10446
10447    case $GCC in
10448    yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10449    *) gdb_cv_bigtoc=-bbigtoc ;;
10450    esac
10451
10452    LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10453    cat >conftest.$ac_ext <<_ACEOF
10454/* confdefs.h.  */
10455_ACEOF
10456cat confdefs.h >>conftest.$ac_ext
10457cat >>conftest.$ac_ext <<_ACEOF
10458/* end confdefs.h.  */
10459
10460int
10461main ()
10462{
10463int i;
10464  ;
10465  return 0;
10466}
10467_ACEOF
10468rm -f conftest.$ac_objext conftest$ac_exeext
10469if { (ac_try="$ac_link"
10470case "(($ac_try" in
10471  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10472  *) ac_try_echo=$ac_try;;
10473esac
10474eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10475  (eval "$ac_link") 2>conftest.er1
10476  ac_status=$?
10477  grep -v '^ *+' conftest.er1 >conftest.err
10478  rm -f conftest.er1
10479  cat conftest.err >&5
10480  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10481  (exit $ac_status); } && {
10482	 test -z "$ac_c_werror_flag" ||
10483	 test ! -s conftest.err
10484       } && test -s conftest$ac_exeext &&
10485       $as_test_x conftest$ac_exeext; then
10486  :
10487else
10488  echo "$as_me: failed program was:" >&5
10489sed 's/^/| /' conftest.$ac_ext >&5
10490
10491	gdb_cv_bigtoc=
10492fi
10493
10494rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10495      conftest$ac_exeext conftest.$ac_ext
10496
10497fi
10498{ echo "$as_me:$LINENO: result: $gdb_cv_bigtoc" >&5
10499echo "${ECHO_T}$gdb_cv_bigtoc" >&6; }
10500  ;;
10501esac
10502
10503# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10504# used for the tests that follow.  We set them back to REAL_CFLAGS and
10505# REAL_CPPFLAGS later on.
10506
10507REAL_CPPFLAGS="$CPPFLAGS"
10508
10509if test "${HAVE_X11}" = "yes"; then
10510  DEFS="$C_SWITCH_X_SITE $DEFS"
10511  LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10512  LIBS="$LIBX $LIBS"
10513  CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10514  CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10515
10516  # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10517  # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
10518  # but it's more convenient here to set LD_RUN_PATH
10519  # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
10520  if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10521    LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10522    export LD_RUN_PATH
10523  fi
10524
10525  if test "${opsys}" = "gnu-linux"; then
10526    { echo "$as_me:$LINENO: checking whether X on GNU/Linux needs -b to link" >&5
10527echo $ECHO_N "checking whether X on GNU/Linux needs -b to link... $ECHO_C" >&6; }
10528    cat >conftest.$ac_ext <<_ACEOF
10529/* confdefs.h.  */
10530_ACEOF
10531cat confdefs.h >>conftest.$ac_ext
10532cat >>conftest.$ac_ext <<_ACEOF
10533/* end confdefs.h.  */
10534
10535int
10536main ()
10537{
10538XOpenDisplay ("foo");
10539  ;
10540  return 0;
10541}
10542_ACEOF
10543rm -f conftest.$ac_objext conftest$ac_exeext
10544if { (ac_try="$ac_link"
10545case "(($ac_try" in
10546  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10547  *) ac_try_echo=$ac_try;;
10548esac
10549eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10550  (eval "$ac_link") 2>conftest.er1
10551  ac_status=$?
10552  grep -v '^ *+' conftest.er1 >conftest.err
10553  rm -f conftest.er1
10554  cat conftest.err >&5
10555  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10556  (exit $ac_status); } && {
10557	 test -z "$ac_c_werror_flag" ||
10558	 test ! -s conftest.err
10559       } && test -s conftest$ac_exeext &&
10560       $as_test_x conftest$ac_exeext; then
10561  xlinux_first_failure=no
10562else
10563  echo "$as_me: failed program was:" >&5
10564sed 's/^/| /' conftest.$ac_ext >&5
10565
10566	xlinux_first_failure=yes
10567fi
10568
10569rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10570      conftest$ac_exeext conftest.$ac_ext
10571    if test "${xlinux_first_failure}" = "yes"; then
10572      OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10573      OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10574      OLD_CPPFLAGS="$CPPFLAGS"
10575      OLD_LIBS="$LIBS"
10576      LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10577      C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10578      CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10579      LIBS="$LIBS -b i486-linuxaout"
10580      cat >conftest.$ac_ext <<_ACEOF
10581/* confdefs.h.  */
10582_ACEOF
10583cat confdefs.h >>conftest.$ac_ext
10584cat >>conftest.$ac_ext <<_ACEOF
10585/* end confdefs.h.  */
10586
10587int
10588main ()
10589{
10590XOpenDisplay ("foo");
10591  ;
10592  return 0;
10593}
10594_ACEOF
10595rm -f conftest.$ac_objext conftest$ac_exeext
10596if { (ac_try="$ac_link"
10597case "(($ac_try" in
10598  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10599  *) ac_try_echo=$ac_try;;
10600esac
10601eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10602  (eval "$ac_link") 2>conftest.er1
10603  ac_status=$?
10604  grep -v '^ *+' conftest.er1 >conftest.err
10605  rm -f conftest.er1
10606  cat conftest.err >&5
10607  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10608  (exit $ac_status); } && {
10609	 test -z "$ac_c_werror_flag" ||
10610	 test ! -s conftest.err
10611       } && test -s conftest$ac_exeext &&
10612       $as_test_x conftest$ac_exeext; then
10613  xlinux_second_failure=no
10614else
10615  echo "$as_me: failed program was:" >&5
10616sed 's/^/| /' conftest.$ac_ext >&5
10617
10618	xlinux_second_failure=yes
10619fi
10620
10621rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10622      conftest$ac_exeext conftest.$ac_ext
10623      if test "${xlinux_second_failure}" = "yes"; then
10624	# If we get the same failure with -b, there is no use adding -b.
10625	# So take it out.  This plays safe.
10626	LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10627	C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10628	CPPFLAGS="$OLD_CPPFLAGS"
10629	LIBS="$OLD_LIBS"
10630        { echo "$as_me:$LINENO: result: no" >&5
10631echo "${ECHO_T}no" >&6; }
10632      else
10633        { echo "$as_me:$LINENO: result: yes" >&5
10634echo "${ECHO_T}yes" >&6; }
10635      fi
10636    else
10637      { echo "$as_me:$LINENO: result: no" >&5
10638echo "${ECHO_T}no" >&6; }
10639    fi
10640  fi
10641
10642  # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10643  # header files included from there.
10644  { echo "$as_me:$LINENO: checking for Xkb" >&5
10645echo $ECHO_N "checking for Xkb... $ECHO_C" >&6; }
10646  cat >conftest.$ac_ext <<_ACEOF
10647/* confdefs.h.  */
10648_ACEOF
10649cat confdefs.h >>conftest.$ac_ext
10650cat >>conftest.$ac_ext <<_ACEOF
10651/* end confdefs.h.  */
10652#include <X11/Xlib.h>
10653#include <X11/XKBlib.h>
10654int
10655main ()
10656{
10657XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10658  ;
10659  return 0;
10660}
10661_ACEOF
10662rm -f conftest.$ac_objext conftest$ac_exeext
10663if { (ac_try="$ac_link"
10664case "(($ac_try" in
10665  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10666  *) ac_try_echo=$ac_try;;
10667esac
10668eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10669  (eval "$ac_link") 2>conftest.er1
10670  ac_status=$?
10671  grep -v '^ *+' conftest.er1 >conftest.err
10672  rm -f conftest.er1
10673  cat conftest.err >&5
10674  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10675  (exit $ac_status); } && {
10676	 test -z "$ac_c_werror_flag" ||
10677	 test ! -s conftest.err
10678       } && test -s conftest$ac_exeext &&
10679       $as_test_x conftest$ac_exeext; then
10680  emacs_xkb=yes
10681else
10682  echo "$as_me: failed program was:" >&5
10683sed 's/^/| /' conftest.$ac_ext >&5
10684
10685	emacs_xkb=no
10686fi
10687
10688rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10689      conftest$ac_exeext conftest.$ac_ext
10690  { echo "$as_me:$LINENO: result: $emacs_xkb" >&5
10691echo "${ECHO_T}$emacs_xkb" >&6; }
10692  if test $emacs_xkb = yes; then
10693
10694cat >>confdefs.h <<\_ACEOF
10695#define HAVE_XKBGETKEYBOARD 1
10696_ACEOF
10697
10698  fi
10699
10700
10701
10702
10703
10704for ac_func in XrmSetDatabase XScreenResourceString \
10705XScreenNumberOfScreen XSetWMProtocols
10706do
10707as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10708{ echo "$as_me:$LINENO: checking for $ac_func" >&5
10709echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
10710if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
10711  echo $ECHO_N "(cached) $ECHO_C" >&6
10712else
10713  cat >conftest.$ac_ext <<_ACEOF
10714/* confdefs.h.  */
10715_ACEOF
10716cat confdefs.h >>conftest.$ac_ext
10717cat >>conftest.$ac_ext <<_ACEOF
10718/* end confdefs.h.  */
10719/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
10720   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
10721#define $ac_func innocuous_$ac_func
10722
10723/* System header to define __stub macros and hopefully few prototypes,
10724    which can conflict with char $ac_func (); below.
10725    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10726    <limits.h> exists even on freestanding compilers.  */
10727
10728#ifdef __STDC__
10729# include <limits.h>
10730#else
10731# include <assert.h>
10732#endif
10733
10734#undef $ac_func
10735
10736/* Override any GCC internal prototype to avoid an error.
10737   Use char because int might match the return type of a GCC
10738   builtin and then its argument prototype would still apply.  */
10739#ifdef __cplusplus
10740extern "C"
10741#endif
10742char $ac_func ();
10743/* The GNU C library defines this for functions which it implements
10744    to always fail with ENOSYS.  Some functions are actually named
10745    something starting with __ and the normal name is an alias.  */
10746#if defined __stub_$ac_func || defined __stub___$ac_func
10747choke me
10748#endif
10749
10750int
10751main ()
10752{
10753return $ac_func ();
10754  ;
10755  return 0;
10756}
10757_ACEOF
10758rm -f conftest.$ac_objext conftest$ac_exeext
10759if { (ac_try="$ac_link"
10760case "(($ac_try" in
10761  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10762  *) ac_try_echo=$ac_try;;
10763esac
10764eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10765  (eval "$ac_link") 2>conftest.er1
10766  ac_status=$?
10767  grep -v '^ *+' conftest.er1 >conftest.err
10768  rm -f conftest.er1
10769  cat conftest.err >&5
10770  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10771  (exit $ac_status); } && {
10772	 test -z "$ac_c_werror_flag" ||
10773	 test ! -s conftest.err
10774       } && test -s conftest$ac_exeext &&
10775       $as_test_x conftest$ac_exeext; then
10776  eval "$as_ac_var=yes"
10777else
10778  echo "$as_me: failed program was:" >&5
10779sed 's/^/| /' conftest.$ac_ext >&5
10780
10781	eval "$as_ac_var=no"
10782fi
10783
10784rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10785      conftest$ac_exeext conftest.$ac_ext
10786fi
10787ac_res=`eval echo '${'$as_ac_var'}'`
10788	       { echo "$as_me:$LINENO: result: $ac_res" >&5
10789echo "${ECHO_T}$ac_res" >&6; }
10790if test `eval echo '${'$as_ac_var'}'` = yes; then
10791  cat >>confdefs.h <<_ACEOF
10792#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10793_ACEOF
10794
10795fi
10796done
10797
10798fi
10799
10800if test "${window_system}" = "x11"; then
10801  { echo "$as_me:$LINENO: checking X11 version 6" >&5
10802echo $ECHO_N "checking X11 version 6... $ECHO_C" >&6; }
10803  if test "${emacs_cv_x11_version_6+set}" = set; then
10804  echo $ECHO_N "(cached) $ECHO_C" >&6
10805else
10806  cat >conftest.$ac_ext <<_ACEOF
10807/* confdefs.h.  */
10808_ACEOF
10809cat confdefs.h >>conftest.$ac_ext
10810cat >>conftest.$ac_ext <<_ACEOF
10811/* end confdefs.h.  */
10812#include <X11/Xlib.h>
10813int
10814main ()
10815{
10816#if XlibSpecificationRelease < 6
10817fail;
10818#endif
10819
10820  ;
10821  return 0;
10822}
10823_ACEOF
10824rm -f conftest.$ac_objext conftest$ac_exeext
10825if { (ac_try="$ac_link"
10826case "(($ac_try" in
10827  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10828  *) ac_try_echo=$ac_try;;
10829esac
10830eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10831  (eval "$ac_link") 2>conftest.er1
10832  ac_status=$?
10833  grep -v '^ *+' conftest.er1 >conftest.err
10834  rm -f conftest.er1
10835  cat conftest.err >&5
10836  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10837  (exit $ac_status); } && {
10838	 test -z "$ac_c_werror_flag" ||
10839	 test ! -s conftest.err
10840       } && test -s conftest$ac_exeext &&
10841       $as_test_x conftest$ac_exeext; then
10842  emacs_cv_x11_version_6=yes
10843else
10844  echo "$as_me: failed program was:" >&5
10845sed 's/^/| /' conftest.$ac_ext >&5
10846
10847	emacs_cv_x11_version_6=no
10848fi
10849
10850rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10851      conftest$ac_exeext conftest.$ac_ext
10852fi
10853
10854  if test $emacs_cv_x11_version_6 = yes; then
10855    { echo "$as_me:$LINENO: result: 6 or newer" >&5
10856echo "${ECHO_T}6 or newer" >&6; }
10857
10858cat >>confdefs.h <<\_ACEOF
10859#define HAVE_X11R6 1
10860_ACEOF
10861
10862  else
10863    { echo "$as_me:$LINENO: result: before 6" >&5
10864echo "${ECHO_T}before 6" >&6; }
10865  fi
10866fi
10867
10868if test "${window_system}" = "x11"; then
10869  { echo "$as_me:$LINENO: checking X11 version 5" >&5
10870echo $ECHO_N "checking X11 version 5... $ECHO_C" >&6; }
10871  if test "${emacs_cv_x11_version_5+set}" = set; then
10872  echo $ECHO_N "(cached) $ECHO_C" >&6
10873else
10874  cat >conftest.$ac_ext <<_ACEOF
10875/* confdefs.h.  */
10876_ACEOF
10877cat confdefs.h >>conftest.$ac_ext
10878cat >>conftest.$ac_ext <<_ACEOF
10879/* end confdefs.h.  */
10880#include <X11/Xlib.h>
10881int
10882main ()
10883{
10884#if XlibSpecificationRelease < 5
10885fail;
10886#endif
10887
10888  ;
10889  return 0;
10890}
10891_ACEOF
10892rm -f conftest.$ac_objext conftest$ac_exeext
10893if { (ac_try="$ac_link"
10894case "(($ac_try" in
10895  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10896  *) ac_try_echo=$ac_try;;
10897esac
10898eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10899  (eval "$ac_link") 2>conftest.er1
10900  ac_status=$?
10901  grep -v '^ *+' conftest.er1 >conftest.err
10902  rm -f conftest.er1
10903  cat conftest.err >&5
10904  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10905  (exit $ac_status); } && {
10906	 test -z "$ac_c_werror_flag" ||
10907	 test ! -s conftest.err
10908       } && test -s conftest$ac_exeext &&
10909       $as_test_x conftest$ac_exeext; then
10910  emacs_cv_x11_version_5=yes
10911else
10912  echo "$as_me: failed program was:" >&5
10913sed 's/^/| /' conftest.$ac_ext >&5
10914
10915	emacs_cv_x11_version_5=no
10916fi
10917
10918rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10919      conftest$ac_exeext conftest.$ac_ext
10920fi
10921
10922  if test $emacs_cv_x11_version_5 = yes; then
10923    { echo "$as_me:$LINENO: result: 5 or newer" >&5
10924echo "${ECHO_T}5 or newer" >&6; }
10925    HAVE_X11R5=yes
10926
10927cat >>confdefs.h <<\_ACEOF
10928#define HAVE_X11R5 1
10929_ACEOF
10930
10931  else
10932    HAVE_X11R5=no
10933    { echo "$as_me:$LINENO: result: before 5" >&5
10934echo "${ECHO_T}before 5" >&6; }
10935  fi
10936fi
10937
10938HAVE_GTK=no
10939if test "${with_gtk}" = "yes" && test "$USE_X_TOOLKIT" = "gtk"; then
10940  USE_X_TOOLKIT=none
10941fi
10942if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "gtk"; then
10943  if test "$USE_X_TOOLKIT" != "none" && test "$USE_X_TOOLKIT" != "maybe"; then
10944    { { echo "$as_me:$LINENO: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&5
10945echo "$as_me: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&2;}
10946   { (exit 1); exit 1; }; };
10947  fi
10948  GLIB_REQUIRED=2.4
10949  GTK_REQUIRED=2.4
10950  GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10951
10952    if test "X${with_pkg_config_prog}" != X; then
10953    PKG_CONFIG="${with_pkg_config_prog}"
10954  fi
10955
10956  succeeded=no
10957
10958  if test -z "$PKG_CONFIG"; then
10959    # Extract the first word of "pkg-config", so it can be a program name with args.
10960set dummy pkg-config; ac_word=$2
10961{ echo "$as_me:$LINENO: checking for $ac_word" >&5
10962echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
10963if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
10964  echo $ECHO_N "(cached) $ECHO_C" >&6
10965else
10966  case $PKG_CONFIG in
10967  [\\/]* | ?:[\\/]*)
10968  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10969  ;;
10970  *)
10971  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10972for as_dir in $PATH
10973do
10974  IFS=$as_save_IFS
10975  test -z "$as_dir" && as_dir=.
10976  for ac_exec_ext in '' $ac_executable_extensions; do
10977  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10978    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10979    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
10980    break 2
10981  fi
10982done
10983done
10984IFS=$as_save_IFS
10985
10986  test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10987  ;;
10988esac
10989fi
10990PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10991if test -n "$PKG_CONFIG"; then
10992  { echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
10993echo "${ECHO_T}$PKG_CONFIG" >&6; }
10994else
10995  { echo "$as_me:$LINENO: result: no" >&5
10996echo "${ECHO_T}no" >&6; }
10997fi
10998
10999
11000  fi
11001
11002  if test "$PKG_CONFIG" = "no" ; then
11003     { { echo "$as_me:$LINENO: error:
11004      *** The pkg-config script could not be found. Make sure it is in your path, or give the full path to pkg-config with the PKG_CONFIG environment variable or --with-pkg-config-prog.  Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config." >&5
11005echo "$as_me: error:
11006      *** The pkg-config script could not be found. Make sure it is in your path, or give the full path to pkg-config with the PKG_CONFIG environment variable or --with-pkg-config-prog.  Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config." >&2;}
11007   { (exit 1); exit 1; }; }
11008  else
11009     PKG_CONFIG_MIN_VERSION=0.9.0
11010     if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11011        { echo "$as_me:$LINENO: checking for $GTK_MODULES" >&5
11012echo $ECHO_N "checking for $GTK_MODULES... $ECHO_C" >&6; }
11013
11014        if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
11015            { echo "$as_me:$LINENO: result: yes" >&5
11016echo "${ECHO_T}yes" >&6; }
11017            succeeded=yes
11018
11019            { echo "$as_me:$LINENO: checking GTK_CFLAGS" >&5
11020echo $ECHO_N "checking GTK_CFLAGS... $ECHO_C" >&6; }
11021            GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
11022            { echo "$as_me:$LINENO: result: $GTK_CFLAGS" >&5
11023echo "${ECHO_T}$GTK_CFLAGS" >&6; }
11024
11025            { echo "$as_me:$LINENO: checking GTK_LIBS" >&5
11026echo $ECHO_N "checking GTK_LIBS... $ECHO_C" >&6; }
11027            GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
11028            { echo "$as_me:$LINENO: result: $GTK_LIBS" >&5
11029echo "${ECHO_T}$GTK_LIBS" >&6; }
11030        else
11031            { echo "$as_me:$LINENO: result: no" >&5
11032echo "${ECHO_T}no" >&6; }
11033            GTK_CFLAGS=""
11034            GTK_LIBS=""
11035            ## If we have a custom action on failure, don't print errors, but
11036            ## do set a variable so people can do so.
11037            GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
11038            echo $GTK_PKG_ERRORS
11039        fi
11040
11041
11042
11043     else
11044        echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11045        echo "*** See http://www.freedesktop.org/software/pkgconfig"
11046     fi
11047  fi
11048
11049  if test $succeeded = yes; then
11050     :
11051  else
11052     { { echo "$as_me:$LINENO: error: Library requirements ($GTK_MODULES) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them." >&5
11053echo "$as_me: error: Library requirements ($GTK_MODULES) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them." >&2;}
11054   { (exit 1); exit 1; }; }
11055  fi
11056
11057
11058
11059  C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
11060  CFLAGS="$CFLAGS $GTK_CFLAGS"
11061  LIBS="$GTK_LIBS $LIBS"
11062    GTK_COMPILES=no
11063
11064for ac_func in gtk_main
11065do
11066as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11067{ echo "$as_me:$LINENO: checking for $ac_func" >&5
11068echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
11069if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
11070  echo $ECHO_N "(cached) $ECHO_C" >&6
11071else
11072  cat >conftest.$ac_ext <<_ACEOF
11073/* confdefs.h.  */
11074_ACEOF
11075cat confdefs.h >>conftest.$ac_ext
11076cat >>conftest.$ac_ext <<_ACEOF
11077/* end confdefs.h.  */
11078/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
11079   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11080#define $ac_func innocuous_$ac_func
11081
11082/* System header to define __stub macros and hopefully few prototypes,
11083    which can conflict with char $ac_func (); below.
11084    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11085    <limits.h> exists even on freestanding compilers.  */
11086
11087#ifdef __STDC__
11088# include <limits.h>
11089#else
11090# include <assert.h>
11091#endif
11092
11093#undef $ac_func
11094
11095/* Override any GCC internal prototype to avoid an error.
11096   Use char because int might match the return type of a GCC
11097   builtin and then its argument prototype would still apply.  */
11098#ifdef __cplusplus
11099extern "C"
11100#endif
11101char $ac_func ();
11102/* The GNU C library defines this for functions which it implements
11103    to always fail with ENOSYS.  Some functions are actually named
11104    something starting with __ and the normal name is an alias.  */
11105#if defined __stub_$ac_func || defined __stub___$ac_func
11106choke me
11107#endif
11108
11109int
11110main ()
11111{
11112return $ac_func ();
11113  ;
11114  return 0;
11115}
11116_ACEOF
11117rm -f conftest.$ac_objext conftest$ac_exeext
11118if { (ac_try="$ac_link"
11119case "(($ac_try" in
11120  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11121  *) ac_try_echo=$ac_try;;
11122esac
11123eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11124  (eval "$ac_link") 2>conftest.er1
11125  ac_status=$?
11126  grep -v '^ *+' conftest.er1 >conftest.err
11127  rm -f conftest.er1
11128  cat conftest.err >&5
11129  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11130  (exit $ac_status); } && {
11131	 test -z "$ac_c_werror_flag" ||
11132	 test ! -s conftest.err
11133       } && test -s conftest$ac_exeext &&
11134       $as_test_x conftest$ac_exeext; then
11135  eval "$as_ac_var=yes"
11136else
11137  echo "$as_me: failed program was:" >&5
11138sed 's/^/| /' conftest.$ac_ext >&5
11139
11140	eval "$as_ac_var=no"
11141fi
11142
11143rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11144      conftest$ac_exeext conftest.$ac_ext
11145fi
11146ac_res=`eval echo '${'$as_ac_var'}'`
11147	       { echo "$as_me:$LINENO: result: $ac_res" >&5
11148echo "${ECHO_T}$ac_res" >&6; }
11149if test `eval echo '${'$as_ac_var'}'` = yes; then
11150  cat >>confdefs.h <<_ACEOF
11151#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11152_ACEOF
11153 GTK_COMPILES=yes
11154fi
11155done
11156
11157  if test "${GTK_COMPILES}" != "yes"; then
11158    { { echo "$as_me:$LINENO: error: Gtk+ wanted, but it does not compile, see config.log.  Maybe some x11-devel files missing?" >&5
11159echo "$as_me: error: Gtk+ wanted, but it does not compile, see config.log.  Maybe some x11-devel files missing?" >&2;}
11160   { (exit 1); exit 1; }; };
11161  fi
11162
11163  HAVE_GTK=yes
11164
11165cat >>confdefs.h <<\_ACEOF
11166#define HAVE_GTK 1
11167_ACEOF
11168
11169  USE_X_TOOLKIT=none
11170
11171      if test "$with_toolkit_scroll_bars" != no; then
11172    with_toolkit_scroll_bars=yes
11173  fi
11174
11175      HAVE_GTK_MULTIDISPLAY=no
11176
11177for ac_func in gdk_display_open
11178do
11179as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11180{ echo "$as_me:$LINENO: checking for $ac_func" >&5
11181echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
11182if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
11183  echo $ECHO_N "(cached) $ECHO_C" >&6
11184else
11185  cat >conftest.$ac_ext <<_ACEOF
11186/* confdefs.h.  */
11187_ACEOF
11188cat confdefs.h >>conftest.$ac_ext
11189cat >>conftest.$ac_ext <<_ACEOF
11190/* end confdefs.h.  */
11191/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
11192   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11193#define $ac_func innocuous_$ac_func
11194
11195/* System header to define __stub macros and hopefully few prototypes,
11196    which can conflict with char $ac_func (); below.
11197    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11198    <limits.h> exists even on freestanding compilers.  */
11199
11200#ifdef __STDC__
11201# include <limits.h>
11202#else
11203# include <assert.h>
11204#endif
11205
11206#undef $ac_func
11207
11208/* Override any GCC internal prototype to avoid an error.
11209   Use char because int might match the return type of a GCC
11210   builtin and then its argument prototype would still apply.  */
11211#ifdef __cplusplus
11212extern "C"
11213#endif
11214char $ac_func ();
11215/* The GNU C library defines this for functions which it implements
11216    to always fail with ENOSYS.  Some functions are actually named
11217    something starting with __ and the normal name is an alias.  */
11218#if defined __stub_$ac_func || defined __stub___$ac_func
11219choke me
11220#endif
11221
11222int
11223main ()
11224{
11225return $ac_func ();
11226  ;
11227  return 0;
11228}
11229_ACEOF
11230rm -f conftest.$ac_objext conftest$ac_exeext
11231if { (ac_try="$ac_link"
11232case "(($ac_try" in
11233  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11234  *) ac_try_echo=$ac_try;;
11235esac
11236eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11237  (eval "$ac_link") 2>conftest.er1
11238  ac_status=$?
11239  grep -v '^ *+' conftest.er1 >conftest.err
11240  rm -f conftest.er1
11241  cat conftest.err >&5
11242  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11243  (exit $ac_status); } && {
11244	 test -z "$ac_c_werror_flag" ||
11245	 test ! -s conftest.err
11246       } && test -s conftest$ac_exeext &&
11247       $as_test_x conftest$ac_exeext; then
11248  eval "$as_ac_var=yes"
11249else
11250  echo "$as_me: failed program was:" >&5
11251sed 's/^/| /' conftest.$ac_ext >&5
11252
11253	eval "$as_ac_var=no"
11254fi
11255
11256rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11257      conftest$ac_exeext conftest.$ac_ext
11258fi
11259ac_res=`eval echo '${'$as_ac_var'}'`
11260	       { echo "$as_me:$LINENO: result: $ac_res" >&5
11261echo "${ECHO_T}$ac_res" >&6; }
11262if test `eval echo '${'$as_ac_var'}'` = yes; then
11263  cat >>confdefs.h <<_ACEOF
11264#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11265_ACEOF
11266 HAVE_GTK_MULTIDISPLAY=yes
11267fi
11268done
11269
11270  if test "${HAVE_GTK_MULTIDISPLAY}" = "yes"; then
11271
11272cat >>confdefs.h <<\_ACEOF
11273#define HAVE_GTK_MULTIDISPLAY 1
11274_ACEOF
11275
11276  fi
11277      HAVE_GTK_FILE_SELECTION=no
11278
11279for ac_func in gtk_file_selection_new
11280do
11281as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11282{ echo "$as_me:$LINENO: checking for $ac_func" >&5
11283echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
11284if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
11285  echo $ECHO_N "(cached) $ECHO_C" >&6
11286else
11287  cat >conftest.$ac_ext <<_ACEOF
11288/* confdefs.h.  */
11289_ACEOF
11290cat confdefs.h >>conftest.$ac_ext
11291cat >>conftest.$ac_ext <<_ACEOF
11292/* end confdefs.h.  */
11293/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
11294   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11295#define $ac_func innocuous_$ac_func
11296
11297/* System header to define __stub macros and hopefully few prototypes,
11298    which can conflict with char $ac_func (); below.
11299    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11300    <limits.h> exists even on freestanding compilers.  */
11301
11302#ifdef __STDC__
11303# include <limits.h>
11304#else
11305# include <assert.h>
11306#endif
11307
11308#undef $ac_func
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 $ac_func ();
11317/* The GNU C library defines this for functions which it implements
11318    to always fail with ENOSYS.  Some functions are actually named
11319    something starting with __ and the normal name is an alias.  */
11320#if defined __stub_$ac_func || defined __stub___$ac_func
11321choke me
11322#endif
11323
11324int
11325main ()
11326{
11327return $ac_func ();
11328  ;
11329  return 0;
11330}
11331_ACEOF
11332rm -f conftest.$ac_objext conftest$ac_exeext
11333if { (ac_try="$ac_link"
11334case "(($ac_try" in
11335  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11336  *) ac_try_echo=$ac_try;;
11337esac
11338eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11339  (eval "$ac_link") 2>conftest.er1
11340  ac_status=$?
11341  grep -v '^ *+' conftest.er1 >conftest.err
11342  rm -f conftest.er1
11343  cat conftest.err >&5
11344  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11345  (exit $ac_status); } && {
11346	 test -z "$ac_c_werror_flag" ||
11347	 test ! -s conftest.err
11348       } && test -s conftest$ac_exeext &&
11349       $as_test_x conftest$ac_exeext; then
11350  eval "$as_ac_var=yes"
11351else
11352  echo "$as_me: failed program was:" >&5
11353sed 's/^/| /' conftest.$ac_ext >&5
11354
11355	eval "$as_ac_var=no"
11356fi
11357
11358rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11359      conftest$ac_exeext conftest.$ac_ext
11360fi
11361ac_res=`eval echo '${'$as_ac_var'}'`
11362	       { echo "$as_me:$LINENO: result: $ac_res" >&5
11363echo "${ECHO_T}$ac_res" >&6; }
11364if test `eval echo '${'$as_ac_var'}'` = yes; then
11365  cat >>confdefs.h <<_ACEOF
11366#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11367_ACEOF
11368 HAVE_GTK_FILE_SELECTION=yes
11369fi
11370done
11371
11372
11373      HAVE_GTK_FILE_CHOOSER=no
11374
11375for ac_func in gtk_file_chooser_dialog_new
11376do
11377as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11378{ echo "$as_me:$LINENO: checking for $ac_func" >&5
11379echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
11380if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
11381  echo $ECHO_N "(cached) $ECHO_C" >&6
11382else
11383  cat >conftest.$ac_ext <<_ACEOF
11384/* confdefs.h.  */
11385_ACEOF
11386cat confdefs.h >>conftest.$ac_ext
11387cat >>conftest.$ac_ext <<_ACEOF
11388/* end confdefs.h.  */
11389/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
11390   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11391#define $ac_func innocuous_$ac_func
11392
11393/* System header to define __stub macros and hopefully few prototypes,
11394    which can conflict with char $ac_func (); below.
11395    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11396    <limits.h> exists even on freestanding compilers.  */
11397
11398#ifdef __STDC__
11399# include <limits.h>
11400#else
11401# include <assert.h>
11402#endif
11403
11404#undef $ac_func
11405
11406/* Override any GCC internal prototype to avoid an error.
11407   Use char because int might match the return type of a GCC
11408   builtin and then its argument prototype would still apply.  */
11409#ifdef __cplusplus
11410extern "C"
11411#endif
11412char $ac_func ();
11413/* The GNU C library defines this for functions which it implements
11414    to always fail with ENOSYS.  Some functions are actually named
11415    something starting with __ and the normal name is an alias.  */
11416#if defined __stub_$ac_func || defined __stub___$ac_func
11417choke me
11418#endif
11419
11420int
11421main ()
11422{
11423return $ac_func ();
11424  ;
11425  return 0;
11426}
11427_ACEOF
11428rm -f conftest.$ac_objext conftest$ac_exeext
11429if { (ac_try="$ac_link"
11430case "(($ac_try" in
11431  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11432  *) ac_try_echo=$ac_try;;
11433esac
11434eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11435  (eval "$ac_link") 2>conftest.er1
11436  ac_status=$?
11437  grep -v '^ *+' conftest.er1 >conftest.err
11438  rm -f conftest.er1
11439  cat conftest.err >&5
11440  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11441  (exit $ac_status); } && {
11442	 test -z "$ac_c_werror_flag" ||
11443	 test ! -s conftest.err
11444       } && test -s conftest$ac_exeext &&
11445       $as_test_x conftest$ac_exeext; then
11446  eval "$as_ac_var=yes"
11447else
11448  echo "$as_me: failed program was:" >&5
11449sed 's/^/| /' conftest.$ac_ext >&5
11450
11451	eval "$as_ac_var=no"
11452fi
11453
11454rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11455      conftest$ac_exeext conftest.$ac_ext
11456fi
11457ac_res=`eval echo '${'$as_ac_var'}'`
11458	       { echo "$as_me:$LINENO: result: $ac_res" >&5
11459echo "${ECHO_T}$ac_res" >&6; }
11460if test `eval echo '${'$as_ac_var'}'` = yes; then
11461  cat >>confdefs.h <<_ACEOF
11462#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11463_ACEOF
11464 HAVE_GTK_FILE_CHOOSER=yes
11465fi
11466done
11467
11468
11469  if test "$HAVE_GTK_FILE_SELECTION" = yes \
11470     && test "$HAVE_GTK_FILE_CHOOSER" = yes;  then
11471
11472cat >>confdefs.h <<\_ACEOF
11473#define HAVE_GTK_FILE_BOTH 1
11474_ACEOF
11475
11476  fi
11477
11478      if test "$HAVE_GTK_FILE_CHOOSER" = yes; then
11479    HAVE_GTK_AND_PTHREAD=no
11480
11481for ac_header in pthread.h
11482do
11483as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11484if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11485  { echo "$as_me:$LINENO: checking for $ac_header" >&5
11486echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11487if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11488  echo $ECHO_N "(cached) $ECHO_C" >&6
11489fi
11490ac_res=`eval echo '${'$as_ac_Header'}'`
11491	       { echo "$as_me:$LINENO: result: $ac_res" >&5
11492echo "${ECHO_T}$ac_res" >&6; }
11493else
11494  # Is the header compilable?
11495{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
11496echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
11497cat >conftest.$ac_ext <<_ACEOF
11498/* confdefs.h.  */
11499_ACEOF
11500cat confdefs.h >>conftest.$ac_ext
11501cat >>conftest.$ac_ext <<_ACEOF
11502/* end confdefs.h.  */
11503$ac_includes_default
11504#include <$ac_header>
11505_ACEOF
11506rm -f conftest.$ac_objext
11507if { (ac_try="$ac_compile"
11508case "(($ac_try" in
11509  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11510  *) ac_try_echo=$ac_try;;
11511esac
11512eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11513  (eval "$ac_compile") 2>conftest.er1
11514  ac_status=$?
11515  grep -v '^ *+' conftest.er1 >conftest.err
11516  rm -f conftest.er1
11517  cat conftest.err >&5
11518  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11519  (exit $ac_status); } && {
11520	 test -z "$ac_c_werror_flag" ||
11521	 test ! -s conftest.err
11522       } && test -s conftest.$ac_objext; then
11523  ac_header_compiler=yes
11524else
11525  echo "$as_me: failed program was:" >&5
11526sed 's/^/| /' conftest.$ac_ext >&5
11527
11528	ac_header_compiler=no
11529fi
11530
11531rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11532{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11533echo "${ECHO_T}$ac_header_compiler" >&6; }
11534
11535# Is the header present?
11536{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
11537echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
11538cat >conftest.$ac_ext <<_ACEOF
11539/* confdefs.h.  */
11540_ACEOF
11541cat confdefs.h >>conftest.$ac_ext
11542cat >>conftest.$ac_ext <<_ACEOF
11543/* end confdefs.h.  */
11544#include <$ac_header>
11545_ACEOF
11546if { (ac_try="$ac_cpp conftest.$ac_ext"
11547case "(($ac_try" in
11548  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11549  *) ac_try_echo=$ac_try;;
11550esac
11551eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11552  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11553  ac_status=$?
11554  grep -v '^ *+' conftest.er1 >conftest.err
11555  rm -f conftest.er1
11556  cat conftest.err >&5
11557  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11558  (exit $ac_status); } >/dev/null && {
11559	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11560	 test ! -s conftest.err
11561       }; then
11562  ac_header_preproc=yes
11563else
11564  echo "$as_me: failed program was:" >&5
11565sed 's/^/| /' conftest.$ac_ext >&5
11566
11567  ac_header_preproc=no
11568fi
11569
11570rm -f conftest.err conftest.$ac_ext
11571{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11572echo "${ECHO_T}$ac_header_preproc" >&6; }
11573
11574# So?  What about this header?
11575case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11576  yes:no: )
11577    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11578echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11579    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11580echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11581    ac_header_preproc=yes
11582    ;;
11583  no:yes:* )
11584    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11585echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11586    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11587echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11588    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11589echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11590    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11591echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11592    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11593echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11594    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11595echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11596
11597    ;;
11598esac
11599{ echo "$as_me:$LINENO: checking for $ac_header" >&5
11600echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11601if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11602  echo $ECHO_N "(cached) $ECHO_C" >&6
11603else
11604  eval "$as_ac_Header=\$ac_header_preproc"
11605fi
11606ac_res=`eval echo '${'$as_ac_Header'}'`
11607	       { echo "$as_me:$LINENO: result: $ac_res" >&5
11608echo "${ECHO_T}$ac_res" >&6; }
11609
11610fi
11611if test `eval echo '${'$as_ac_Header'}'` = yes; then
11612  cat >>confdefs.h <<_ACEOF
11613#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11614_ACEOF
11615
11616fi
11617
11618done
11619
11620    if test "$ac_cv_header_pthread_h"; then
11621      { echo "$as_me:$LINENO: checking for pthread_self in -lpthread" >&5
11622echo $ECHO_N "checking for pthread_self in -lpthread... $ECHO_C" >&6; }
11623if test "${ac_cv_lib_pthread_pthread_self+set}" = set; then
11624  echo $ECHO_N "(cached) $ECHO_C" >&6
11625else
11626  ac_check_lib_save_LIBS=$LIBS
11627LIBS="-lpthread  $LIBS"
11628cat >conftest.$ac_ext <<_ACEOF
11629/* confdefs.h.  */
11630_ACEOF
11631cat confdefs.h >>conftest.$ac_ext
11632cat >>conftest.$ac_ext <<_ACEOF
11633/* end confdefs.h.  */
11634
11635/* Override any GCC internal prototype to avoid an error.
11636   Use char because int might match the return type of a GCC
11637   builtin and then its argument prototype would still apply.  */
11638#ifdef __cplusplus
11639extern "C"
11640#endif
11641char pthread_self ();
11642int
11643main ()
11644{
11645return pthread_self ();
11646  ;
11647  return 0;
11648}
11649_ACEOF
11650rm -f conftest.$ac_objext conftest$ac_exeext
11651if { (ac_try="$ac_link"
11652case "(($ac_try" in
11653  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11654  *) ac_try_echo=$ac_try;;
11655esac
11656eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11657  (eval "$ac_link") 2>conftest.er1
11658  ac_status=$?
11659  grep -v '^ *+' conftest.er1 >conftest.err
11660  rm -f conftest.er1
11661  cat conftest.err >&5
11662  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11663  (exit $ac_status); } && {
11664	 test -z "$ac_c_werror_flag" ||
11665	 test ! -s conftest.err
11666       } && test -s conftest$ac_exeext &&
11667       $as_test_x conftest$ac_exeext; then
11668  ac_cv_lib_pthread_pthread_self=yes
11669else
11670  echo "$as_me: failed program was:" >&5
11671sed 's/^/| /' conftest.$ac_ext >&5
11672
11673	ac_cv_lib_pthread_pthread_self=no
11674fi
11675
11676rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11677      conftest$ac_exeext conftest.$ac_ext
11678LIBS=$ac_check_lib_save_LIBS
11679fi
11680{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_self" >&5
11681echo "${ECHO_T}$ac_cv_lib_pthread_pthread_self" >&6; }
11682if test $ac_cv_lib_pthread_pthread_self = yes; then
11683  HAVE_GTK_AND_PTHREAD=yes
11684fi
11685
11686    fi
11687    if test "$HAVE_GTK_AND_PTHREAD" = yes; then
11688      GTK_LIBS="$GTK_LIBS -lpthread"
11689
11690cat >>confdefs.h <<\_ACEOF
11691#define HAVE_GTK_AND_PTHREAD 1
11692_ACEOF
11693
11694    fi
11695  fi
11696fi
11697
11698### Link with -lXft if available to work around a bug.
11699HAVE_XFT=maybe
11700if test "${HAVE_GTK}" = "yes"; then
11701    if test "X${with_pkg_config_prog}" != X; then
11702    PKG_CONFIG="${with_pkg_config_prog}"
11703  fi
11704
11705
11706  succeeded=no
11707
11708  if test -z "$PKG_CONFIG"; then
11709    # Extract the first word of "pkg-config", so it can be a program name with args.
11710set dummy pkg-config; ac_word=$2
11711{ echo "$as_me:$LINENO: checking for $ac_word" >&5
11712echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
11713if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
11714  echo $ECHO_N "(cached) $ECHO_C" >&6
11715else
11716  case $PKG_CONFIG in
11717  [\\/]* | ?:[\\/]*)
11718  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11719  ;;
11720  *)
11721  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11722for as_dir in $PATH
11723do
11724  IFS=$as_save_IFS
11725  test -z "$as_dir" && as_dir=.
11726  for ac_exec_ext in '' $ac_executable_extensions; do
11727  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11728    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11729    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11730    break 2
11731  fi
11732done
11733done
11734IFS=$as_save_IFS
11735
11736  test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11737  ;;
11738esac
11739fi
11740PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11741if test -n "$PKG_CONFIG"; then
11742  { echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
11743echo "${ECHO_T}$PKG_CONFIG" >&6; }
11744else
11745  { echo "$as_me:$LINENO: result: no" >&5
11746echo "${ECHO_T}no" >&6; }
11747fi
11748
11749
11750  fi
11751
11752  if test "$PKG_CONFIG" = "no" ; then
11753     HAVE_XFT=no
11754  else
11755     PKG_CONFIG_MIN_VERSION=0.9.0
11756     if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11757        { echo "$as_me:$LINENO: checking for xft >= 0.13.0" >&5
11758echo $ECHO_N "checking for xft >= 0.13.0... $ECHO_C" >&6; }
11759
11760        if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5; then
11761            { echo "$as_me:$LINENO: result: yes" >&5
11762echo "${ECHO_T}yes" >&6; }
11763            succeeded=yes
11764
11765            { echo "$as_me:$LINENO: checking XFT_CFLAGS" >&5
11766echo $ECHO_N "checking XFT_CFLAGS... $ECHO_C" >&6; }
11767            XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0"|sed -e 's,///*,/,g'`
11768            { echo "$as_me:$LINENO: result: $XFT_CFLAGS" >&5
11769echo "${ECHO_T}$XFT_CFLAGS" >&6; }
11770
11771            { echo "$as_me:$LINENO: checking XFT_LIBS" >&5
11772echo $ECHO_N "checking XFT_LIBS... $ECHO_C" >&6; }
11773            XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0"|sed -e 's,///*,/,g'`
11774            { echo "$as_me:$LINENO: result: $XFT_LIBS" >&5
11775echo "${ECHO_T}$XFT_LIBS" >&6; }
11776        else
11777            { echo "$as_me:$LINENO: result: no" >&5
11778echo "${ECHO_T}no" >&6; }
11779            XFT_CFLAGS=""
11780            XFT_LIBS=""
11781            ## If we have a custom action on failure, don't print errors, but
11782            ## do set a variable so people can do so.
11783            XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
11784
11785        fi
11786
11787
11788
11789     else
11790        echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11791        echo "*** See http://www.freedesktop.org/software/pkgconfig"
11792     fi
11793  fi
11794
11795  if test $succeeded = yes; then
11796     :
11797  else
11798     HAVE_XFT=no
11799  fi
11800
11801  if test "$HAVE_XFT" != no; then
11802    OLD_CFLAGS="$CPPFLAGS"
11803    OLD_CPPFLAGS="$CFLAGS"
11804    OLD_LIBS="$LIBS"
11805    CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
11806    CFLAGS="$CFLAGS $XFT_CFLAGS"
11807    LIBS="$XFT_LIBS $LIBS"
11808    if test "${ac_cv_header_X11_Xft_Xft_h+set}" = set; then
11809  { echo "$as_me:$LINENO: checking for X11/Xft/Xft.h" >&5
11810echo $ECHO_N "checking for X11/Xft/Xft.h... $ECHO_C" >&6; }
11811if test "${ac_cv_header_X11_Xft_Xft_h+set}" = set; then
11812  echo $ECHO_N "(cached) $ECHO_C" >&6
11813fi
11814{ echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xft_Xft_h" >&5
11815echo "${ECHO_T}$ac_cv_header_X11_Xft_Xft_h" >&6; }
11816else
11817  # Is the header compilable?
11818{ echo "$as_me:$LINENO: checking X11/Xft/Xft.h usability" >&5
11819echo $ECHO_N "checking X11/Xft/Xft.h usability... $ECHO_C" >&6; }
11820cat >conftest.$ac_ext <<_ACEOF
11821/* confdefs.h.  */
11822_ACEOF
11823cat confdefs.h >>conftest.$ac_ext
11824cat >>conftest.$ac_ext <<_ACEOF
11825/* end confdefs.h.  */
11826$ac_includes_default
11827#include <X11/Xft/Xft.h>
11828_ACEOF
11829rm -f conftest.$ac_objext
11830if { (ac_try="$ac_compile"
11831case "(($ac_try" in
11832  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11833  *) ac_try_echo=$ac_try;;
11834esac
11835eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11836  (eval "$ac_compile") 2>conftest.er1
11837  ac_status=$?
11838  grep -v '^ *+' conftest.er1 >conftest.err
11839  rm -f conftest.er1
11840  cat conftest.err >&5
11841  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11842  (exit $ac_status); } && {
11843	 test -z "$ac_c_werror_flag" ||
11844	 test ! -s conftest.err
11845       } && test -s conftest.$ac_objext; then
11846  ac_header_compiler=yes
11847else
11848  echo "$as_me: failed program was:" >&5
11849sed 's/^/| /' conftest.$ac_ext >&5
11850
11851	ac_header_compiler=no
11852fi
11853
11854rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11855{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11856echo "${ECHO_T}$ac_header_compiler" >&6; }
11857
11858# Is the header present?
11859{ echo "$as_me:$LINENO: checking X11/Xft/Xft.h presence" >&5
11860echo $ECHO_N "checking X11/Xft/Xft.h presence... $ECHO_C" >&6; }
11861cat >conftest.$ac_ext <<_ACEOF
11862/* confdefs.h.  */
11863_ACEOF
11864cat confdefs.h >>conftest.$ac_ext
11865cat >>conftest.$ac_ext <<_ACEOF
11866/* end confdefs.h.  */
11867#include <X11/Xft/Xft.h>
11868_ACEOF
11869if { (ac_try="$ac_cpp conftest.$ac_ext"
11870case "(($ac_try" in
11871  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11872  *) ac_try_echo=$ac_try;;
11873esac
11874eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11875  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11876  ac_status=$?
11877  grep -v '^ *+' conftest.er1 >conftest.err
11878  rm -f conftest.er1
11879  cat conftest.err >&5
11880  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11881  (exit $ac_status); } >/dev/null && {
11882	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11883	 test ! -s conftest.err
11884       }; then
11885  ac_header_preproc=yes
11886else
11887  echo "$as_me: failed program was:" >&5
11888sed 's/^/| /' conftest.$ac_ext >&5
11889
11890  ac_header_preproc=no
11891fi
11892
11893rm -f conftest.err conftest.$ac_ext
11894{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11895echo "${ECHO_T}$ac_header_preproc" >&6; }
11896
11897# So?  What about this header?
11898case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11899  yes:no: )
11900    { echo "$as_me:$LINENO: WARNING: X11/Xft/Xft.h: accepted by the compiler, rejected by the preprocessor!" >&5
11901echo "$as_me: WARNING: X11/Xft/Xft.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11902    { echo "$as_me:$LINENO: WARNING: X11/Xft/Xft.h: proceeding with the compiler's result" >&5
11903echo "$as_me: WARNING: X11/Xft/Xft.h: proceeding with the compiler's result" >&2;}
11904    ac_header_preproc=yes
11905    ;;
11906  no:yes:* )
11907    { echo "$as_me:$LINENO: WARNING: X11/Xft/Xft.h: present but cannot be compiled" >&5
11908echo "$as_me: WARNING: X11/Xft/Xft.h: present but cannot be compiled" >&2;}
11909    { echo "$as_me:$LINENO: WARNING: X11/Xft/Xft.h:     check for missing prerequisite headers?" >&5
11910echo "$as_me: WARNING: X11/Xft/Xft.h:     check for missing prerequisite headers?" >&2;}
11911    { echo "$as_me:$LINENO: WARNING: X11/Xft/Xft.h: see the Autoconf documentation" >&5
11912echo "$as_me: WARNING: X11/Xft/Xft.h: see the Autoconf documentation" >&2;}
11913    { echo "$as_me:$LINENO: WARNING: X11/Xft/Xft.h:     section \"Present But Cannot Be Compiled\"" >&5
11914echo "$as_me: WARNING: X11/Xft/Xft.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11915    { echo "$as_me:$LINENO: WARNING: X11/Xft/Xft.h: proceeding with the preprocessor's result" >&5
11916echo "$as_me: WARNING: X11/Xft/Xft.h: proceeding with the preprocessor's result" >&2;}
11917    { echo "$as_me:$LINENO: WARNING: X11/Xft/Xft.h: in the future, the compiler will take precedence" >&5
11918echo "$as_me: WARNING: X11/Xft/Xft.h: in the future, the compiler will take precedence" >&2;}
11919
11920    ;;
11921esac
11922{ echo "$as_me:$LINENO: checking for X11/Xft/Xft.h" >&5
11923echo $ECHO_N "checking for X11/Xft/Xft.h... $ECHO_C" >&6; }
11924if test "${ac_cv_header_X11_Xft_Xft_h+set}" = set; then
11925  echo $ECHO_N "(cached) $ECHO_C" >&6
11926else
11927  ac_cv_header_X11_Xft_Xft_h=$ac_header_preproc
11928fi
11929{ echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xft_Xft_h" >&5
11930echo "${ECHO_T}$ac_cv_header_X11_Xft_Xft_h" >&6; }
11931
11932fi
11933if test $ac_cv_header_X11_Xft_Xft_h = yes; then
11934  { echo "$as_me:$LINENO: checking for XftFontOpen in -lXft" >&5
11935echo $ECHO_N "checking for XftFontOpen in -lXft... $ECHO_C" >&6; }
11936if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then
11937  echo $ECHO_N "(cached) $ECHO_C" >&6
11938else
11939  ac_check_lib_save_LIBS=$LIBS
11940LIBS="-lXft $XFT_LIBS $LIBS"
11941cat >conftest.$ac_ext <<_ACEOF
11942/* confdefs.h.  */
11943_ACEOF
11944cat confdefs.h >>conftest.$ac_ext
11945cat >>conftest.$ac_ext <<_ACEOF
11946/* end confdefs.h.  */
11947
11948/* Override any GCC internal prototype to avoid an error.
11949   Use char because int might match the return type of a GCC
11950   builtin and then its argument prototype would still apply.  */
11951#ifdef __cplusplus
11952extern "C"
11953#endif
11954char XftFontOpen ();
11955int
11956main ()
11957{
11958return XftFontOpen ();
11959  ;
11960  return 0;
11961}
11962_ACEOF
11963rm -f conftest.$ac_objext conftest$ac_exeext
11964if { (ac_try="$ac_link"
11965case "(($ac_try" in
11966  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11967  *) ac_try_echo=$ac_try;;
11968esac
11969eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11970  (eval "$ac_link") 2>conftest.er1
11971  ac_status=$?
11972  grep -v '^ *+' conftest.er1 >conftest.err
11973  rm -f conftest.er1
11974  cat conftest.err >&5
11975  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11976  (exit $ac_status); } && {
11977	 test -z "$ac_c_werror_flag" ||
11978	 test ! -s conftest.err
11979       } && test -s conftest$ac_exeext &&
11980       $as_test_x conftest$ac_exeext; then
11981  ac_cv_lib_Xft_XftFontOpen=yes
11982else
11983  echo "$as_me: failed program was:" >&5
11984sed 's/^/| /' conftest.$ac_ext >&5
11985
11986	ac_cv_lib_Xft_XftFontOpen=no
11987fi
11988
11989rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11990      conftest$ac_exeext conftest.$ac_ext
11991LIBS=$ac_check_lib_save_LIBS
11992fi
11993{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xft_XftFontOpen" >&5
11994echo "${ECHO_T}$ac_cv_lib_Xft_XftFontOpen" >&6; }
11995if test $ac_cv_lib_Xft_XftFontOpen = yes; then
11996  HAVE_XFT=yes
11997fi
11998
11999fi
12000
12001
12002
12003    if test "${HAVE_XFT}" = "yes"; then
12004
12005cat >>confdefs.h <<\_ACEOF
12006#define HAVE_XFT 1
12007_ACEOF
12008
12009
12010      C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12011    else
12012      CFLAGS="$OLD_CPPFLAGS"
12013      CFLAGS="$OLD_CFLAGS"
12014      LIBS="$OLD_LIBS"
12015    fi
12016  fi
12017fi
12018
12019if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
12020  if test x"${HAVE_X11R5}" = xyes; then
12021    { echo "$as_me:$LINENO: checking X11 version 5 with Xaw" >&5
12022echo $ECHO_N "checking X11 version 5 with Xaw... $ECHO_C" >&6; }
12023    if test "${emacs_cv_x11_version_5_with_xaw+set}" = set; then
12024  echo $ECHO_N "(cached) $ECHO_C" >&6
12025else
12026  cat >conftest.$ac_ext <<_ACEOF
12027/* confdefs.h.  */
12028_ACEOF
12029cat confdefs.h >>conftest.$ac_ext
12030cat >>conftest.$ac_ext <<_ACEOF
12031/* end confdefs.h.  */
12032
12033#include <X11/Intrinsic.h>
12034#include <X11/Xaw/Simple.h>
12035int
12036main ()
12037{
12038
12039  ;
12040  return 0;
12041}
12042_ACEOF
12043rm -f conftest.$ac_objext conftest$ac_exeext
12044if { (ac_try="$ac_link"
12045case "(($ac_try" in
12046  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12047  *) ac_try_echo=$ac_try;;
12048esac
12049eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12050  (eval "$ac_link") 2>conftest.er1
12051  ac_status=$?
12052  grep -v '^ *+' conftest.er1 >conftest.err
12053  rm -f conftest.er1
12054  cat conftest.err >&5
12055  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12056  (exit $ac_status); } && {
12057	 test -z "$ac_c_werror_flag" ||
12058	 test ! -s conftest.err
12059       } && test -s conftest$ac_exeext &&
12060       $as_test_x conftest$ac_exeext; then
12061  emacs_cv_x11_version_5_with_xaw=yes
12062else
12063  echo "$as_me: failed program was:" >&5
12064sed 's/^/| /' conftest.$ac_ext >&5
12065
12066	emacs_cv_x11_version_5_with_xaw=no
12067fi
12068
12069rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12070      conftest$ac_exeext conftest.$ac_ext
12071fi
12072
12073    if test $emacs_cv_x11_version_5_with_xaw = yes; then
12074      { echo "$as_me:$LINENO: result: 5 or newer, with Xaw; use toolkit by default" >&5
12075echo "${ECHO_T}5 or newer, with Xaw; use toolkit by default" >&6; }
12076      USE_X_TOOLKIT=LUCID
12077    else
12078      if test x"${USE_X_TOOLKIT}" = xLUCID; then
12079        { { echo "$as_me:$LINENO: error: Lucid toolkit requires X11/Xaw include files" >&5
12080echo "$as_me: error: Lucid toolkit requires X11/Xaw include files" >&2;}
12081   { (exit 1); exit 1; }; }
12082      else
12083        { echo "$as_me:$LINENO: result: before 5 or no Xaw; do not use toolkit by default" >&5
12084echo "${ECHO_T}before 5 or no Xaw; do not use toolkit by default" >&6; }
12085        USE_X_TOOLKIT=none
12086      fi
12087    fi
12088  else
12089    USE_X_TOOLKIT=none
12090  fi
12091fi
12092
12093X_TOOLKIT_TYPE=$USE_X_TOOLKIT
12094
12095if test "${USE_X_TOOLKIT}" != "none"; then
12096  { echo "$as_me:$LINENO: checking X11 toolkit version" >&5
12097echo $ECHO_N "checking X11 toolkit version... $ECHO_C" >&6; }
12098  if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then
12099  echo $ECHO_N "(cached) $ECHO_C" >&6
12100else
12101  cat >conftest.$ac_ext <<_ACEOF
12102/* confdefs.h.  */
12103_ACEOF
12104cat confdefs.h >>conftest.$ac_ext
12105cat >>conftest.$ac_ext <<_ACEOF
12106/* end confdefs.h.  */
12107#include <X11/Intrinsic.h>
12108int
12109main ()
12110{
12111#if XtSpecificationRelease < 6
12112fail;
12113#endif
12114
12115  ;
12116  return 0;
12117}
12118_ACEOF
12119rm -f conftest.$ac_objext conftest$ac_exeext
12120if { (ac_try="$ac_link"
12121case "(($ac_try" in
12122  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12123  *) ac_try_echo=$ac_try;;
12124esac
12125eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12126  (eval "$ac_link") 2>conftest.er1
12127  ac_status=$?
12128  grep -v '^ *+' conftest.er1 >conftest.err
12129  rm -f conftest.er1
12130  cat conftest.err >&5
12131  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12132  (exit $ac_status); } && {
12133	 test -z "$ac_c_werror_flag" ||
12134	 test ! -s conftest.err
12135       } && test -s conftest$ac_exeext &&
12136       $as_test_x conftest$ac_exeext; then
12137  emacs_cv_x11_toolkit_version_6=yes
12138else
12139  echo "$as_me: failed program was:" >&5
12140sed 's/^/| /' conftest.$ac_ext >&5
12141
12142	emacs_cv_x11_toolkit_version_6=no
12143fi
12144
12145rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12146      conftest$ac_exeext conftest.$ac_ext
12147fi
12148
12149  HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
12150  if test $emacs_cv_x11_toolkit_version_6 = yes; then
12151    { echo "$as_me:$LINENO: result: 6 or newer" >&5
12152echo "${ECHO_T}6 or newer" >&6; }
12153
12154cat >>confdefs.h <<\_ACEOF
12155#define HAVE_X11XTR6 1
12156_ACEOF
12157
12158  else
12159    { echo "$as_me:$LINENO: result: before 6" >&5
12160echo "${ECHO_T}before 6" >&6; }
12161  fi
12162
12163  OLDLIBS="$LIBS"
12164  if test x$HAVE_X11XTR6 = xyes; then
12165    LIBS="-lXt -lSM -lICE $LIBS"
12166  else
12167    LIBS="-lXt $LIBS"
12168  fi
12169
12170{ echo "$as_me:$LINENO: checking for XmuConvertStandardSelection in -lXmu" >&5
12171echo $ECHO_N "checking for XmuConvertStandardSelection in -lXmu... $ECHO_C" >&6; }
12172if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then
12173  echo $ECHO_N "(cached) $ECHO_C" >&6
12174else
12175  ac_check_lib_save_LIBS=$LIBS
12176LIBS="-lXmu  $LIBS"
12177cat >conftest.$ac_ext <<_ACEOF
12178/* confdefs.h.  */
12179_ACEOF
12180cat confdefs.h >>conftest.$ac_ext
12181cat >>conftest.$ac_ext <<_ACEOF
12182/* end confdefs.h.  */
12183
12184/* Override any GCC internal prototype to avoid an error.
12185   Use char because int might match the return type of a GCC
12186   builtin and then its argument prototype would still apply.  */
12187#ifdef __cplusplus
12188extern "C"
12189#endif
12190char XmuConvertStandardSelection ();
12191int
12192main ()
12193{
12194return XmuConvertStandardSelection ();
12195  ;
12196  return 0;
12197}
12198_ACEOF
12199rm -f conftest.$ac_objext conftest$ac_exeext
12200if { (ac_try="$ac_link"
12201case "(($ac_try" in
12202  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12203  *) ac_try_echo=$ac_try;;
12204esac
12205eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12206  (eval "$ac_link") 2>conftest.er1
12207  ac_status=$?
12208  grep -v '^ *+' conftest.er1 >conftest.err
12209  rm -f conftest.er1
12210  cat conftest.err >&5
12211  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12212  (exit $ac_status); } && {
12213	 test -z "$ac_c_werror_flag" ||
12214	 test ! -s conftest.err
12215       } && test -s conftest$ac_exeext &&
12216       $as_test_x conftest$ac_exeext; then
12217  ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
12218else
12219  echo "$as_me: failed program was:" >&5
12220sed 's/^/| /' conftest.$ac_ext >&5
12221
12222	ac_cv_lib_Xmu_XmuConvertStandardSelection=no
12223fi
12224
12225rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12226      conftest$ac_exeext conftest.$ac_ext
12227LIBS=$ac_check_lib_save_LIBS
12228fi
12229{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
12230echo "${ECHO_T}$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
12231if test $ac_cv_lib_Xmu_XmuConvertStandardSelection = yes; then
12232  cat >>confdefs.h <<_ACEOF
12233#define HAVE_LIBXMU 1
12234_ACEOF
12235
12236  LIBS="-lXmu $LIBS"
12237
12238fi
12239
12240  test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
12241fi
12242
12243# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
12244if test "${HAVE_X11}" = "yes"; then
12245  if test "${USE_X_TOOLKIT}" != "none"; then
12246
12247{ echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
12248echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6; }
12249if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
12250  echo $ECHO_N "(cached) $ECHO_C" >&6
12251else
12252  ac_check_lib_save_LIBS=$LIBS
12253LIBS="-lXext  $LIBS"
12254cat >conftest.$ac_ext <<_ACEOF
12255/* confdefs.h.  */
12256_ACEOF
12257cat confdefs.h >>conftest.$ac_ext
12258cat >>conftest.$ac_ext <<_ACEOF
12259/* end confdefs.h.  */
12260
12261/* Override any GCC internal prototype to avoid an error.
12262   Use char because int might match the return type of a GCC
12263   builtin and then its argument prototype would still apply.  */
12264#ifdef __cplusplus
12265extern "C"
12266#endif
12267char XShapeQueryExtension ();
12268int
12269main ()
12270{
12271return XShapeQueryExtension ();
12272  ;
12273  return 0;
12274}
12275_ACEOF
12276rm -f conftest.$ac_objext conftest$ac_exeext
12277if { (ac_try="$ac_link"
12278case "(($ac_try" in
12279  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12280  *) ac_try_echo=$ac_try;;
12281esac
12282eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12283  (eval "$ac_link") 2>conftest.er1
12284  ac_status=$?
12285  grep -v '^ *+' conftest.er1 >conftest.err
12286  rm -f conftest.er1
12287  cat conftest.err >&5
12288  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12289  (exit $ac_status); } && {
12290	 test -z "$ac_c_werror_flag" ||
12291	 test ! -s conftest.err
12292       } && test -s conftest$ac_exeext &&
12293       $as_test_x conftest$ac_exeext; then
12294  ac_cv_lib_Xext_XShapeQueryExtension=yes
12295else
12296  echo "$as_me: failed program was:" >&5
12297sed 's/^/| /' conftest.$ac_ext >&5
12298
12299	ac_cv_lib_Xext_XShapeQueryExtension=no
12300fi
12301
12302rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12303      conftest$ac_exeext conftest.$ac_ext
12304LIBS=$ac_check_lib_save_LIBS
12305fi
12306{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
12307echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
12308if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
12309  cat >>confdefs.h <<_ACEOF
12310#define HAVE_LIBXEXT 1
12311_ACEOF
12312
12313  LIBS="-lXext $LIBS"
12314
12315fi
12316
12317  fi
12318fi
12319
12320if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12321  { echo "$as_me:$LINENO: checking for Motif version 2.1" >&5
12322echo $ECHO_N "checking for Motif version 2.1... $ECHO_C" >&6; }
12323if test "${emacs_cv_motif_version_2_1+set}" = set; then
12324  echo $ECHO_N "(cached) $ECHO_C" >&6
12325else
12326  cat >conftest.$ac_ext <<_ACEOF
12327/* confdefs.h.  */
12328_ACEOF
12329cat confdefs.h >>conftest.$ac_ext
12330cat >>conftest.$ac_ext <<_ACEOF
12331/* end confdefs.h.  */
12332#include <Xm/Xm.h>
12333int
12334main ()
12335{
12336#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
12337int x = 5;
12338#else
12339Motif version prior to 2.1.
12340#endif
12341  ;
12342  return 0;
12343}
12344_ACEOF
12345rm -f conftest.$ac_objext
12346if { (ac_try="$ac_compile"
12347case "(($ac_try" in
12348  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12349  *) ac_try_echo=$ac_try;;
12350esac
12351eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12352  (eval "$ac_compile") 2>conftest.er1
12353  ac_status=$?
12354  grep -v '^ *+' conftest.er1 >conftest.err
12355  rm -f conftest.er1
12356  cat conftest.err >&5
12357  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12358  (exit $ac_status); } && {
12359	 test -z "$ac_c_werror_flag" ||
12360	 test ! -s conftest.err
12361       } && test -s conftest.$ac_objext; then
12362  emacs_cv_motif_version_2_1=yes
12363else
12364  echo "$as_me: failed program was:" >&5
12365sed 's/^/| /' conftest.$ac_ext >&5
12366
12367	emacs_cv_motif_version_2_1=no
12368fi
12369
12370rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12371fi
12372{ echo "$as_me:$LINENO: result: $emacs_cv_motif_version_2_1" >&5
12373echo "${ECHO_T}$emacs_cv_motif_version_2_1" >&6; }
12374  HAVE_MOTIF_2_1=$emacs_cv_motif_version_2_1
12375  if test $emacs_cv_motif_version_2_1 = yes; then
12376    HAVE_LIBXP=no
12377
12378cat >>confdefs.h <<\_ACEOF
12379#define HAVE_MOTIF_2_1 1
12380_ACEOF
12381
12382    { echo "$as_me:$LINENO: checking for XpCreateContext in -lXp" >&5
12383echo $ECHO_N "checking for XpCreateContext in -lXp... $ECHO_C" >&6; }
12384if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then
12385  echo $ECHO_N "(cached) $ECHO_C" >&6
12386else
12387  ac_check_lib_save_LIBS=$LIBS
12388LIBS="-lXp  $LIBS"
12389cat >conftest.$ac_ext <<_ACEOF
12390/* confdefs.h.  */
12391_ACEOF
12392cat confdefs.h >>conftest.$ac_ext
12393cat >>conftest.$ac_ext <<_ACEOF
12394/* end confdefs.h.  */
12395
12396/* Override any GCC internal prototype to avoid an error.
12397   Use char because int might match the return type of a GCC
12398   builtin and then its argument prototype would still apply.  */
12399#ifdef __cplusplus
12400extern "C"
12401#endif
12402char XpCreateContext ();
12403int
12404main ()
12405{
12406return XpCreateContext ();
12407  ;
12408  return 0;
12409}
12410_ACEOF
12411rm -f conftest.$ac_objext conftest$ac_exeext
12412if { (ac_try="$ac_link"
12413case "(($ac_try" in
12414  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12415  *) ac_try_echo=$ac_try;;
12416esac
12417eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12418  (eval "$ac_link") 2>conftest.er1
12419  ac_status=$?
12420  grep -v '^ *+' conftest.er1 >conftest.err
12421  rm -f conftest.er1
12422  cat conftest.err >&5
12423  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12424  (exit $ac_status); } && {
12425	 test -z "$ac_c_werror_flag" ||
12426	 test ! -s conftest.err
12427       } && test -s conftest$ac_exeext &&
12428       $as_test_x conftest$ac_exeext; then
12429  ac_cv_lib_Xp_XpCreateContext=yes
12430else
12431  echo "$as_me: failed program was:" >&5
12432sed 's/^/| /' conftest.$ac_ext >&5
12433
12434	ac_cv_lib_Xp_XpCreateContext=no
12435fi
12436
12437rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12438      conftest$ac_exeext conftest.$ac_ext
12439LIBS=$ac_check_lib_save_LIBS
12440fi
12441{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xp_XpCreateContext" >&5
12442echo "${ECHO_T}$ac_cv_lib_Xp_XpCreateContext" >&6; }
12443if test $ac_cv_lib_Xp_XpCreateContext = yes; then
12444  HAVE_LIBXP=yes
12445fi
12446
12447    if test ${HAVE_LIBXP} = yes; then
12448
12449cat >>confdefs.h <<\_ACEOF
12450#define HAVE_LIBXP 1
12451_ACEOF
12452
12453    fi
12454  else
12455    { echo "$as_me:$LINENO: checking for LessTif where some systems put it" >&5
12456echo $ECHO_N "checking for LessTif where some systems put it... $ECHO_C" >&6; }
12457if test "${emacs_cv_lesstif+set}" = set; then
12458  echo $ECHO_N "(cached) $ECHO_C" >&6
12459else
12460  # We put this in CFLAGS temporarily to precede other -I options
12461    # that might be in CFLAGS temporarily.
12462    # We put this in CPPFLAGS where it precedes the other -I options.
12463    OLD_CPPFLAGS=$CPPFLAGS
12464    OLD_CFLAGS=$CFLAGS
12465    CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12466    CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12467    cat >conftest.$ac_ext <<_ACEOF
12468/* confdefs.h.  */
12469_ACEOF
12470cat confdefs.h >>conftest.$ac_ext
12471cat >>conftest.$ac_ext <<_ACEOF
12472/* end confdefs.h.  */
12473#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12474int
12475main ()
12476{
12477int x = 5;
12478  ;
12479  return 0;
12480}
12481_ACEOF
12482rm -f conftest.$ac_objext
12483if { (ac_try="$ac_compile"
12484case "(($ac_try" in
12485  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12486  *) ac_try_echo=$ac_try;;
12487esac
12488eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12489  (eval "$ac_compile") 2>conftest.er1
12490  ac_status=$?
12491  grep -v '^ *+' conftest.er1 >conftest.err
12492  rm -f conftest.er1
12493  cat conftest.err >&5
12494  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12495  (exit $ac_status); } && {
12496	 test -z "$ac_c_werror_flag" ||
12497	 test ! -s conftest.err
12498       } && test -s conftest.$ac_objext; then
12499  emacs_cv_lesstif=yes
12500else
12501  echo "$as_me: failed program was:" >&5
12502sed 's/^/| /' conftest.$ac_ext >&5
12503
12504	emacs_cv_lesstif=no
12505fi
12506
12507rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12508fi
12509{ echo "$as_me:$LINENO: result: $emacs_cv_lesstif" >&5
12510echo "${ECHO_T}$emacs_cv_lesstif" >&6; }
12511    if test $emacs_cv_lesstif = yes; then
12512      # Make sure this -I option remains in CPPFLAGS after it is set
12513      # back to REAL_CPPFLAGS.
12514      # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12515      # have those other -I options anyway.  Ultimately, having this
12516      # directory ultimately in CPPFLAGS will be enough.
12517      REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12518      LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12519    else
12520      CFLAGS=$OLD_CFLAGS
12521      CPPFLAGS=$OLD_CPPFLAGS
12522    fi
12523  fi
12524fi
12525
12526### Is -lXaw3d available?
12527HAVE_XAW3D=no
12528if test "${HAVE_X11}" = "yes"; then
12529  if test "${USE_X_TOOLKIT}" != "none" && test "${with_toolkit_scroll_bars}" != "no"; then
12530            { echo "$as_me:$LINENO: checking for X11/Xaw3d/Scrollbar.h" >&5
12531echo $ECHO_N "checking for X11/Xaw3d/Scrollbar.h... $ECHO_C" >&6; }
12532if test "${ac_cv_header_X11_Xaw3d_Scrollbar_h+set}" = set; then
12533  echo $ECHO_N "(cached) $ECHO_C" >&6
12534else
12535  cat >conftest.$ac_ext <<_ACEOF
12536/* confdefs.h.  */
12537_ACEOF
12538cat confdefs.h >>conftest.$ac_ext
12539cat >>conftest.$ac_ext <<_ACEOF
12540/* end confdefs.h.  */
12541#include <X11/Xaw3d/Scrollbar.h>
12542_ACEOF
12543if { (ac_try="$ac_cpp conftest.$ac_ext"
12544case "(($ac_try" in
12545  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12546  *) ac_try_echo=$ac_try;;
12547esac
12548eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12549  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12550  ac_status=$?
12551  grep -v '^ *+' conftest.er1 >conftest.err
12552  rm -f conftest.er1
12553  cat conftest.err >&5
12554  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12555  (exit $ac_status); } >/dev/null && {
12556	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12557	 test ! -s conftest.err
12558       }; then
12559  ac_cv_header_X11_Xaw3d_Scrollbar_h=yes
12560else
12561  echo "$as_me: failed program was:" >&5
12562sed 's/^/| /' conftest.$ac_ext >&5
12563
12564  ac_cv_header_X11_Xaw3d_Scrollbar_h=no
12565fi
12566
12567rm -f conftest.err conftest.$ac_ext
12568fi
12569{ echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xaw3d_Scrollbar_h" >&5
12570echo "${ECHO_T}$ac_cv_header_X11_Xaw3d_Scrollbar_h" >&6; }
12571if test $ac_cv_header_X11_Xaw3d_Scrollbar_h = yes; then
12572  { echo "$as_me:$LINENO: checking for XawScrollbarSetThumb in -lXaw3d" >&5
12573echo $ECHO_N "checking for XawScrollbarSetThumb in -lXaw3d... $ECHO_C" >&6; }
12574if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then
12575  echo $ECHO_N "(cached) $ECHO_C" >&6
12576else
12577  ac_check_lib_save_LIBS=$LIBS
12578LIBS="-lXaw3d  $LIBS"
12579cat >conftest.$ac_ext <<_ACEOF
12580/* confdefs.h.  */
12581_ACEOF
12582cat confdefs.h >>conftest.$ac_ext
12583cat >>conftest.$ac_ext <<_ACEOF
12584/* end confdefs.h.  */
12585
12586/* Override any GCC internal prototype to avoid an error.
12587   Use char because int might match the return type of a GCC
12588   builtin and then its argument prototype would still apply.  */
12589#ifdef __cplusplus
12590extern "C"
12591#endif
12592char XawScrollbarSetThumb ();
12593int
12594main ()
12595{
12596return XawScrollbarSetThumb ();
12597  ;
12598  return 0;
12599}
12600_ACEOF
12601rm -f conftest.$ac_objext conftest$ac_exeext
12602if { (ac_try="$ac_link"
12603case "(($ac_try" in
12604  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12605  *) ac_try_echo=$ac_try;;
12606esac
12607eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12608  (eval "$ac_link") 2>conftest.er1
12609  ac_status=$?
12610  grep -v '^ *+' conftest.er1 >conftest.err
12611  rm -f conftest.er1
12612  cat conftest.err >&5
12613  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12614  (exit $ac_status); } && {
12615	 test -z "$ac_c_werror_flag" ||
12616	 test ! -s conftest.err
12617       } && test -s conftest$ac_exeext &&
12618       $as_test_x conftest$ac_exeext; then
12619  ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
12620else
12621  echo "$as_me: failed program was:" >&5
12622sed 's/^/| /' conftest.$ac_ext >&5
12623
12624	ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
12625fi
12626
12627rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12628      conftest$ac_exeext conftest.$ac_ext
12629LIBS=$ac_check_lib_save_LIBS
12630fi
12631{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
12632echo "${ECHO_T}$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
12633if test $ac_cv_lib_Xaw3d_XawScrollbarSetThumb = yes; then
12634  HAVE_XAW3D=yes
12635fi
12636
12637fi
12638
12639
12640    if test "${HAVE_XAW3D}" = "yes"; then
12641
12642cat >>confdefs.h <<\_ACEOF
12643#define HAVE_XAW3D 1
12644_ACEOF
12645
12646    fi
12647  fi
12648fi
12649
12650
12651
12652USE_TOOLKIT_SCROLL_BARS=no
12653if test "${with_toolkit_scroll_bars}" != "no"; then
12654  if test "${USE_X_TOOLKIT}" != "none"; then
12655    if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12656      cat >>confdefs.h <<\_ACEOF
12657#define USE_TOOLKIT_SCROLL_BARS 1
12658_ACEOF
12659
12660      HAVE_XAW3D=no
12661      USE_TOOLKIT_SCROLL_BARS=yes
12662    elif test "${HAVE_XAW3D}" = "yes"; then
12663      cat >>confdefs.h <<\_ACEOF
12664#define USE_TOOLKIT_SCROLL_BARS 1
12665_ACEOF
12666
12667      USE_TOOLKIT_SCROLL_BARS=yes
12668    fi
12669  elif test "${HAVE_GTK}" = "yes"; then
12670    cat >>confdefs.h <<\_ACEOF
12671#define USE_TOOLKIT_SCROLL_BARS 1
12672_ACEOF
12673
12674    USE_TOOLKIT_SCROLL_BARS=yes
12675  elif test "${HAVE_CARBON}" = "yes"; then
12676    cat >>confdefs.h <<\_ACEOF
12677#define USE_TOOLKIT_SCROLL_BARS 1
12678_ACEOF
12679
12680    USE_TOOLKIT_SCROLL_BARS=yes
12681  fi
12682fi
12683
12684cat >conftest.$ac_ext <<_ACEOF
12685/* confdefs.h.  */
12686_ACEOF
12687cat confdefs.h >>conftest.$ac_ext
12688cat >>conftest.$ac_ext <<_ACEOF
12689/* end confdefs.h.  */
12690
12691	  #include <X11/Xlib.h>
12692	  #include <X11/Xresource.h>
12693int
12694main ()
12695{
12696XIMProc  callback;
12697  ;
12698  return 0;
12699}
12700_ACEOF
12701rm -f conftest.$ac_objext
12702if { (ac_try="$ac_compile"
12703case "(($ac_try" in
12704  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12705  *) ac_try_echo=$ac_try;;
12706esac
12707eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12708  (eval "$ac_compile") 2>conftest.er1
12709  ac_status=$?
12710  grep -v '^ *+' conftest.er1 >conftest.err
12711  rm -f conftest.er1
12712  cat conftest.err >&5
12713  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12714  (exit $ac_status); } && {
12715	 test -z "$ac_c_werror_flag" ||
12716	 test ! -s conftest.err
12717       } && test -s conftest.$ac_objext; then
12718  HAVE_XIM=yes
12719
12720cat >>confdefs.h <<\_ACEOF
12721#define HAVE_XIM 1
12722_ACEOF
12723
12724else
12725  echo "$as_me: failed program was:" >&5
12726sed 's/^/| /' conftest.$ac_ext >&5
12727
12728	HAVE_XIM=no
12729fi
12730
12731rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12732
12733
12734if test "${with_xim}" != "no"; then
12735
12736cat >>confdefs.h <<\_ACEOF
12737#define USE_XIM 1
12738_ACEOF
12739
12740fi
12741
12742
12743if test "${HAVE_XIM}" != "no"; then
12744  late_CFLAGS=$CFLAGS
12745  if test "$GCC" = yes; then
12746    CFLAGS="$CFLAGS --pedantic-errors"
12747  fi
12748  cat >conftest.$ac_ext <<_ACEOF
12749/* confdefs.h.  */
12750_ACEOF
12751cat confdefs.h >>conftest.$ac_ext
12752cat >>conftest.$ac_ext <<_ACEOF
12753/* end confdefs.h.  */
12754
12755#include <X11/Xlib.h>
12756#include <X11/Xresource.h>
12757int
12758main ()
12759{
12760Display *display;
12761XrmDatabase db;
12762char *res_name;
12763char *res_class;
12764XIMProc  callback;
12765XPointer *client_data;
12766#ifndef __GNUC__
12767/* If we're not using GCC, it's probably not XFree86, and this is
12768   probably right, but we can't use something like --pedantic-errors.  */
12769extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
12770                                           char*, XIMProc, XPointer*);
12771#endif
12772(void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
12773   client_data);
12774  ;
12775  return 0;
12776}
12777_ACEOF
12778rm -f conftest.$ac_objext
12779if { (ac_try="$ac_compile"
12780case "(($ac_try" in
12781  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12782  *) ac_try_echo=$ac_try;;
12783esac
12784eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12785  (eval "$ac_compile") 2>conftest.er1
12786  ac_status=$?
12787  grep -v '^ *+' conftest.er1 >conftest.err
12788  rm -f conftest.er1
12789  cat conftest.err >&5
12790  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12791  (exit $ac_status); } && {
12792	 test -z "$ac_c_werror_flag" ||
12793	 test ! -s conftest.err
12794       } && test -s conftest.$ac_objext; then
12795  emacs_cv_arg6_star=yes
12796else
12797  echo "$as_me: failed program was:" >&5
12798sed 's/^/| /' conftest.$ac_ext >&5
12799
12800
12801fi
12802
12803rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12804
12805  if test "$emacs_cv_arg6_star" = yes; then
12806    cat >>confdefs.h <<\_ACEOF
12807#define XRegisterIMInstantiateCallback_arg6 XPointer*
12808_ACEOF
12809
12810  else
12811    cat >>confdefs.h <<\_ACEOF
12812#define XRegisterIMInstantiateCallback_arg6 XPointer
12813_ACEOF
12814
12815  fi
12816  CFLAGS=$late_CFLAGS
12817fi
12818
12819### Use -lXpm if available, unless `--with-xpm=no'.
12820HAVE_XPM=no
12821if test "${HAVE_X11}" = "yes"; then
12822  if test "${with_xpm}" != "no"; then
12823    if test "${ac_cv_header_X11_xpm_h+set}" = set; then
12824  { echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
12825echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6; }
12826if test "${ac_cv_header_X11_xpm_h+set}" = set; then
12827  echo $ECHO_N "(cached) $ECHO_C" >&6
12828fi
12829{ echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
12830echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6; }
12831else
12832  # Is the header compilable?
12833{ echo "$as_me:$LINENO: checking X11/xpm.h usability" >&5
12834echo $ECHO_N "checking X11/xpm.h usability... $ECHO_C" >&6; }
12835cat >conftest.$ac_ext <<_ACEOF
12836/* confdefs.h.  */
12837_ACEOF
12838cat confdefs.h >>conftest.$ac_ext
12839cat >>conftest.$ac_ext <<_ACEOF
12840/* end confdefs.h.  */
12841$ac_includes_default
12842#include <X11/xpm.h>
12843_ACEOF
12844rm -f conftest.$ac_objext
12845if { (ac_try="$ac_compile"
12846case "(($ac_try" in
12847  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12848  *) ac_try_echo=$ac_try;;
12849esac
12850eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12851  (eval "$ac_compile") 2>conftest.er1
12852  ac_status=$?
12853  grep -v '^ *+' conftest.er1 >conftest.err
12854  rm -f conftest.er1
12855  cat conftest.err >&5
12856  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12857  (exit $ac_status); } && {
12858	 test -z "$ac_c_werror_flag" ||
12859	 test ! -s conftest.err
12860       } && test -s conftest.$ac_objext; then
12861  ac_header_compiler=yes
12862else
12863  echo "$as_me: failed program was:" >&5
12864sed 's/^/| /' conftest.$ac_ext >&5
12865
12866	ac_header_compiler=no
12867fi
12868
12869rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12870{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12871echo "${ECHO_T}$ac_header_compiler" >&6; }
12872
12873# Is the header present?
12874{ echo "$as_me:$LINENO: checking X11/xpm.h presence" >&5
12875echo $ECHO_N "checking X11/xpm.h presence... $ECHO_C" >&6; }
12876cat >conftest.$ac_ext <<_ACEOF
12877/* confdefs.h.  */
12878_ACEOF
12879cat confdefs.h >>conftest.$ac_ext
12880cat >>conftest.$ac_ext <<_ACEOF
12881/* end confdefs.h.  */
12882#include <X11/xpm.h>
12883_ACEOF
12884if { (ac_try="$ac_cpp conftest.$ac_ext"
12885case "(($ac_try" in
12886  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12887  *) ac_try_echo=$ac_try;;
12888esac
12889eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12890  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12891  ac_status=$?
12892  grep -v '^ *+' conftest.er1 >conftest.err
12893  rm -f conftest.er1
12894  cat conftest.err >&5
12895  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12896  (exit $ac_status); } >/dev/null && {
12897	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12898	 test ! -s conftest.err
12899       }; then
12900  ac_header_preproc=yes
12901else
12902  echo "$as_me: failed program was:" >&5
12903sed 's/^/| /' conftest.$ac_ext >&5
12904
12905  ac_header_preproc=no
12906fi
12907
12908rm -f conftest.err conftest.$ac_ext
12909{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12910echo "${ECHO_T}$ac_header_preproc" >&6; }
12911
12912# So?  What about this header?
12913case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12914  yes:no: )
12915    { echo "$as_me:$LINENO: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&5
12916echo "$as_me: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12917    { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the compiler's result" >&5
12918echo "$as_me: WARNING: X11/xpm.h: proceeding with the compiler's result" >&2;}
12919    ac_header_preproc=yes
12920    ;;
12921  no:yes:* )
12922    { echo "$as_me:$LINENO: WARNING: X11/xpm.h: present but cannot be compiled" >&5
12923echo "$as_me: WARNING: X11/xpm.h: present but cannot be compiled" >&2;}
12924    { echo "$as_me:$LINENO: WARNING: X11/xpm.h:     check for missing prerequisite headers?" >&5
12925echo "$as_me: WARNING: X11/xpm.h:     check for missing prerequisite headers?" >&2;}
12926    { echo "$as_me:$LINENO: WARNING: X11/xpm.h: see the Autoconf documentation" >&5
12927echo "$as_me: WARNING: X11/xpm.h: see the Autoconf documentation" >&2;}
12928    { echo "$as_me:$LINENO: WARNING: X11/xpm.h:     section \"Present But Cannot Be Compiled\"" >&5
12929echo "$as_me: WARNING: X11/xpm.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12930    { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
12931echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
12932    { echo "$as_me:$LINENO: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&5
12933echo "$as_me: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&2;}
12934
12935    ;;
12936esac
12937{ echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
12938echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6; }
12939if test "${ac_cv_header_X11_xpm_h+set}" = set; then
12940  echo $ECHO_N "(cached) $ECHO_C" >&6
12941else
12942  ac_cv_header_X11_xpm_h=$ac_header_preproc
12943fi
12944{ echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
12945echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6; }
12946
12947fi
12948if test $ac_cv_header_X11_xpm_h = yes; then
12949  { echo "$as_me:$LINENO: checking for XpmReadFileToPixmap in -lXpm" >&5
12950echo $ECHO_N "checking for XpmReadFileToPixmap in -lXpm... $ECHO_C" >&6; }
12951if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then
12952  echo $ECHO_N "(cached) $ECHO_C" >&6
12953else
12954  ac_check_lib_save_LIBS=$LIBS
12955LIBS="-lXpm -lX11 $LIBS"
12956cat >conftest.$ac_ext <<_ACEOF
12957/* confdefs.h.  */
12958_ACEOF
12959cat confdefs.h >>conftest.$ac_ext
12960cat >>conftest.$ac_ext <<_ACEOF
12961/* end confdefs.h.  */
12962
12963/* Override any GCC internal prototype to avoid an error.
12964   Use char because int might match the return type of a GCC
12965   builtin and then its argument prototype would still apply.  */
12966#ifdef __cplusplus
12967extern "C"
12968#endif
12969char XpmReadFileToPixmap ();
12970int
12971main ()
12972{
12973return XpmReadFileToPixmap ();
12974  ;
12975  return 0;
12976}
12977_ACEOF
12978rm -f conftest.$ac_objext conftest$ac_exeext
12979if { (ac_try="$ac_link"
12980case "(($ac_try" in
12981  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12982  *) ac_try_echo=$ac_try;;
12983esac
12984eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12985  (eval "$ac_link") 2>conftest.er1
12986  ac_status=$?
12987  grep -v '^ *+' conftest.er1 >conftest.err
12988  rm -f conftest.er1
12989  cat conftest.err >&5
12990  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12991  (exit $ac_status); } && {
12992	 test -z "$ac_c_werror_flag" ||
12993	 test ! -s conftest.err
12994       } && test -s conftest$ac_exeext &&
12995       $as_test_x conftest$ac_exeext; then
12996  ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12997else
12998  echo "$as_me: failed program was:" >&5
12999sed 's/^/| /' conftest.$ac_ext >&5
13000
13001	ac_cv_lib_Xpm_XpmReadFileToPixmap=no
13002fi
13003
13004rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13005      conftest$ac_exeext conftest.$ac_ext
13006LIBS=$ac_check_lib_save_LIBS
13007fi
13008{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
13009echo "${ECHO_T}$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
13010if test $ac_cv_lib_Xpm_XpmReadFileToPixmap = yes; then
13011  HAVE_XPM=yes
13012fi
13013
13014fi
13015
13016
13017    if test "${HAVE_XPM}" = "yes"; then
13018      { echo "$as_me:$LINENO: checking for XpmReturnAllocPixels preprocessor define" >&5
13019echo $ECHO_N "checking for XpmReturnAllocPixels preprocessor define... $ECHO_C" >&6; }
13020      cat >conftest.$ac_ext <<_ACEOF
13021/* confdefs.h.  */
13022_ACEOF
13023cat confdefs.h >>conftest.$ac_ext
13024cat >>conftest.$ac_ext <<_ACEOF
13025/* end confdefs.h.  */
13026#include "X11/xpm.h"
13027#ifndef XpmReturnAllocPixels
13028no_return_alloc_pixels
13029#endif
13030
13031_ACEOF
13032if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13033  $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then
13034  HAVE_XPM=no
13035else
13036  HAVE_XPM=yes
13037fi
13038rm -f conftest*
13039
13040
13041      if test "${HAVE_XPM}" = "yes"; then
13042	{ echo "$as_me:$LINENO: result: yes" >&5
13043echo "${ECHO_T}yes" >&6; }
13044      else
13045	{ echo "$as_me:$LINENO: result: no" >&5
13046echo "${ECHO_T}no" >&6; }
13047      fi
13048    fi
13049  fi
13050
13051  if test "${HAVE_XPM}" = "yes"; then
13052
13053cat >>confdefs.h <<\_ACEOF
13054#define HAVE_XPM 1
13055_ACEOF
13056
13057  fi
13058fi
13059
13060### Use -ljpeg if available, unless `--with-jpeg=no'.
13061HAVE_JPEG=no
13062if test "${HAVE_X11}" = "yes"; then
13063  if test "${with_jpeg}" != "no"; then
13064            if test "${ac_cv_header_jerror_h+set}" = set; then
13065  { echo "$as_me:$LINENO: checking for jerror.h" >&5
13066echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6; }
13067if test "${ac_cv_header_jerror_h+set}" = set; then
13068  echo $ECHO_N "(cached) $ECHO_C" >&6
13069fi
13070{ echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
13071echo "${ECHO_T}$ac_cv_header_jerror_h" >&6; }
13072else
13073  # Is the header compilable?
13074{ echo "$as_me:$LINENO: checking jerror.h usability" >&5
13075echo $ECHO_N "checking jerror.h usability... $ECHO_C" >&6; }
13076cat >conftest.$ac_ext <<_ACEOF
13077/* confdefs.h.  */
13078_ACEOF
13079cat confdefs.h >>conftest.$ac_ext
13080cat >>conftest.$ac_ext <<_ACEOF
13081/* end confdefs.h.  */
13082$ac_includes_default
13083#include <jerror.h>
13084_ACEOF
13085rm -f conftest.$ac_objext
13086if { (ac_try="$ac_compile"
13087case "(($ac_try" in
13088  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13089  *) ac_try_echo=$ac_try;;
13090esac
13091eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13092  (eval "$ac_compile") 2>conftest.er1
13093  ac_status=$?
13094  grep -v '^ *+' conftest.er1 >conftest.err
13095  rm -f conftest.er1
13096  cat conftest.err >&5
13097  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13098  (exit $ac_status); } && {
13099	 test -z "$ac_c_werror_flag" ||
13100	 test ! -s conftest.err
13101       } && test -s conftest.$ac_objext; then
13102  ac_header_compiler=yes
13103else
13104  echo "$as_me: failed program was:" >&5
13105sed 's/^/| /' conftest.$ac_ext >&5
13106
13107	ac_header_compiler=no
13108fi
13109
13110rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13111{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13112echo "${ECHO_T}$ac_header_compiler" >&6; }
13113
13114# Is the header present?
13115{ echo "$as_me:$LINENO: checking jerror.h presence" >&5
13116echo $ECHO_N "checking jerror.h presence... $ECHO_C" >&6; }
13117cat >conftest.$ac_ext <<_ACEOF
13118/* confdefs.h.  */
13119_ACEOF
13120cat confdefs.h >>conftest.$ac_ext
13121cat >>conftest.$ac_ext <<_ACEOF
13122/* end confdefs.h.  */
13123#include <jerror.h>
13124_ACEOF
13125if { (ac_try="$ac_cpp conftest.$ac_ext"
13126case "(($ac_try" in
13127  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13128  *) ac_try_echo=$ac_try;;
13129esac
13130eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13131  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13132  ac_status=$?
13133  grep -v '^ *+' conftest.er1 >conftest.err
13134  rm -f conftest.er1
13135  cat conftest.err >&5
13136  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13137  (exit $ac_status); } >/dev/null && {
13138	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13139	 test ! -s conftest.err
13140       }; then
13141  ac_header_preproc=yes
13142else
13143  echo "$as_me: failed program was:" >&5
13144sed 's/^/| /' conftest.$ac_ext >&5
13145
13146  ac_header_preproc=no
13147fi
13148
13149rm -f conftest.err conftest.$ac_ext
13150{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13151echo "${ECHO_T}$ac_header_preproc" >&6; }
13152
13153# So?  What about this header?
13154case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13155  yes:no: )
13156    { echo "$as_me:$LINENO: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&5
13157echo "$as_me: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13158    { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the compiler's result" >&5
13159echo "$as_me: WARNING: jerror.h: proceeding with the compiler's result" >&2;}
13160    ac_header_preproc=yes
13161    ;;
13162  no:yes:* )
13163    { echo "$as_me:$LINENO: WARNING: jerror.h: present but cannot be compiled" >&5
13164echo "$as_me: WARNING: jerror.h: present but cannot be compiled" >&2;}
13165    { echo "$as_me:$LINENO: WARNING: jerror.h:     check for missing prerequisite headers?" >&5
13166echo "$as_me: WARNING: jerror.h:     check for missing prerequisite headers?" >&2;}
13167    { echo "$as_me:$LINENO: WARNING: jerror.h: see the Autoconf documentation" >&5
13168echo "$as_me: WARNING: jerror.h: see the Autoconf documentation" >&2;}
13169    { echo "$as_me:$LINENO: WARNING: jerror.h:     section \"Present But Cannot Be Compiled\"" >&5
13170echo "$as_me: WARNING: jerror.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13171    { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
13172echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
13173    { echo "$as_me:$LINENO: WARNING: jerror.h: in the future, the compiler will take precedence" >&5
13174echo "$as_me: WARNING: jerror.h: in the future, the compiler will take precedence" >&2;}
13175
13176    ;;
13177esac
13178{ echo "$as_me:$LINENO: checking for jerror.h" >&5
13179echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6; }
13180if test "${ac_cv_header_jerror_h+set}" = set; then
13181  echo $ECHO_N "(cached) $ECHO_C" >&6
13182else
13183  ac_cv_header_jerror_h=$ac_header_preproc
13184fi
13185{ echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
13186echo "${ECHO_T}$ac_cv_header_jerror_h" >&6; }
13187
13188fi
13189if test $ac_cv_header_jerror_h = yes; then
13190  { echo "$as_me:$LINENO: checking for jpeg_destroy_compress in -ljpeg" >&5
13191echo $ECHO_N "checking for jpeg_destroy_compress in -ljpeg... $ECHO_C" >&6; }
13192if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then
13193  echo $ECHO_N "(cached) $ECHO_C" >&6
13194else
13195  ac_check_lib_save_LIBS=$LIBS
13196LIBS="-ljpeg  $LIBS"
13197cat >conftest.$ac_ext <<_ACEOF
13198/* confdefs.h.  */
13199_ACEOF
13200cat confdefs.h >>conftest.$ac_ext
13201cat >>conftest.$ac_ext <<_ACEOF
13202/* end confdefs.h.  */
13203
13204/* Override any GCC internal prototype to avoid an error.
13205   Use char because int might match the return type of a GCC
13206   builtin and then its argument prototype would still apply.  */
13207#ifdef __cplusplus
13208extern "C"
13209#endif
13210char jpeg_destroy_compress ();
13211int
13212main ()
13213{
13214return jpeg_destroy_compress ();
13215  ;
13216  return 0;
13217}
13218_ACEOF
13219rm -f conftest.$ac_objext conftest$ac_exeext
13220if { (ac_try="$ac_link"
13221case "(($ac_try" in
13222  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13223  *) ac_try_echo=$ac_try;;
13224esac
13225eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13226  (eval "$ac_link") 2>conftest.er1
13227  ac_status=$?
13228  grep -v '^ *+' conftest.er1 >conftest.err
13229  rm -f conftest.er1
13230  cat conftest.err >&5
13231  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13232  (exit $ac_status); } && {
13233	 test -z "$ac_c_werror_flag" ||
13234	 test ! -s conftest.err
13235       } && test -s conftest$ac_exeext &&
13236       $as_test_x conftest$ac_exeext; then
13237  ac_cv_lib_jpeg_jpeg_destroy_compress=yes
13238else
13239  echo "$as_me: failed program was:" >&5
13240sed 's/^/| /' conftest.$ac_ext >&5
13241
13242	ac_cv_lib_jpeg_jpeg_destroy_compress=no
13243fi
13244
13245rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13246      conftest$ac_exeext conftest.$ac_ext
13247LIBS=$ac_check_lib_save_LIBS
13248fi
13249{ echo "$as_me:$LINENO: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
13250echo "${ECHO_T}$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
13251if test $ac_cv_lib_jpeg_jpeg_destroy_compress = yes; then
13252  HAVE_JPEG=yes
13253fi
13254
13255fi
13256
13257
13258  fi
13259
13260
13261  if test "${HAVE_JPEG}" = "yes"; then
13262    cat >>confdefs.h <<\_ACEOF
13263#define HAVE_JPEG 1
13264_ACEOF
13265
13266    cat >conftest.$ac_ext <<_ACEOF
13267/* confdefs.h.  */
13268_ACEOF
13269cat confdefs.h >>conftest.$ac_ext
13270cat >>conftest.$ac_ext <<_ACEOF
13271/* end confdefs.h.  */
13272#include <jpeglib.h>
13273	 version=JPEG_LIB_VERSION
13274
13275_ACEOF
13276if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13277  $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then
13278  cat >>confdefs.h <<\_ACEOF
13279#define HAVE_JPEG 1
13280_ACEOF
13281
13282else
13283  { echo "$as_me:$LINENO: WARNING: libjpeg found, but not version 6b or later" >&5
13284echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13285        HAVE_JPEG=no
13286fi
13287rm -f conftest*
13288
13289  fi
13290fi
13291
13292### Use -lpng if available, unless `--with-png=no'.
13293HAVE_PNG=no
13294if test "${HAVE_X11}" = "yes"; then
13295  if test "${with_png}" != "no"; then
13296    # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
13297    # in /usr/include/libpng.
13298
13299
13300for ac_header in png.h libpng/png.h
13301do
13302as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13303if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13304  { echo "$as_me:$LINENO: checking for $ac_header" >&5
13305echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
13306if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13307  echo $ECHO_N "(cached) $ECHO_C" >&6
13308fi
13309ac_res=`eval echo '${'$as_ac_Header'}'`
13310	       { echo "$as_me:$LINENO: result: $ac_res" >&5
13311echo "${ECHO_T}$ac_res" >&6; }
13312else
13313  # Is the header compilable?
13314{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
13315echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
13316cat >conftest.$ac_ext <<_ACEOF
13317/* confdefs.h.  */
13318_ACEOF
13319cat confdefs.h >>conftest.$ac_ext
13320cat >>conftest.$ac_ext <<_ACEOF
13321/* end confdefs.h.  */
13322$ac_includes_default
13323#include <$ac_header>
13324_ACEOF
13325rm -f conftest.$ac_objext
13326if { (ac_try="$ac_compile"
13327case "(($ac_try" in
13328  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13329  *) ac_try_echo=$ac_try;;
13330esac
13331eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13332  (eval "$ac_compile") 2>conftest.er1
13333  ac_status=$?
13334  grep -v '^ *+' conftest.er1 >conftest.err
13335  rm -f conftest.er1
13336  cat conftest.err >&5
13337  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13338  (exit $ac_status); } && {
13339	 test -z "$ac_c_werror_flag" ||
13340	 test ! -s conftest.err
13341       } && test -s conftest.$ac_objext; then
13342  ac_header_compiler=yes
13343else
13344  echo "$as_me: failed program was:" >&5
13345sed 's/^/| /' conftest.$ac_ext >&5
13346
13347	ac_header_compiler=no
13348fi
13349
13350rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13351{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13352echo "${ECHO_T}$ac_header_compiler" >&6; }
13353
13354# Is the header present?
13355{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
13356echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
13357cat >conftest.$ac_ext <<_ACEOF
13358/* confdefs.h.  */
13359_ACEOF
13360cat confdefs.h >>conftest.$ac_ext
13361cat >>conftest.$ac_ext <<_ACEOF
13362/* end confdefs.h.  */
13363#include <$ac_header>
13364_ACEOF
13365if { (ac_try="$ac_cpp conftest.$ac_ext"
13366case "(($ac_try" in
13367  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13368  *) ac_try_echo=$ac_try;;
13369esac
13370eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13371  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13372  ac_status=$?
13373  grep -v '^ *+' conftest.er1 >conftest.err
13374  rm -f conftest.er1
13375  cat conftest.err >&5
13376  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13377  (exit $ac_status); } >/dev/null && {
13378	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13379	 test ! -s conftest.err
13380       }; then
13381  ac_header_preproc=yes
13382else
13383  echo "$as_me: failed program was:" >&5
13384sed 's/^/| /' conftest.$ac_ext >&5
13385
13386  ac_header_preproc=no
13387fi
13388
13389rm -f conftest.err conftest.$ac_ext
13390{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13391echo "${ECHO_T}$ac_header_preproc" >&6; }
13392
13393# So?  What about this header?
13394case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13395  yes:no: )
13396    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13397echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13398    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13399echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13400    ac_header_preproc=yes
13401    ;;
13402  no:yes:* )
13403    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13404echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13405    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13406echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13407    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13408echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13409    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13410echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13411    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13412echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13413    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13414echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13415
13416    ;;
13417esac
13418{ echo "$as_me:$LINENO: checking for $ac_header" >&5
13419echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
13420if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13421  echo $ECHO_N "(cached) $ECHO_C" >&6
13422else
13423  eval "$as_ac_Header=\$ac_header_preproc"
13424fi
13425ac_res=`eval echo '${'$as_ac_Header'}'`
13426	       { echo "$as_me:$LINENO: result: $ac_res" >&5
13427echo "${ECHO_T}$ac_res" >&6; }
13428
13429fi
13430if test `eval echo '${'$as_ac_Header'}'` = yes; then
13431  cat >>confdefs.h <<_ACEOF
13432#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13433_ACEOF
13434
13435fi
13436
13437done
13438
13439    if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
13440      { echo "$as_me:$LINENO: checking for png_get_channels in -lpng" >&5
13441echo $ECHO_N "checking for png_get_channels in -lpng... $ECHO_C" >&6; }
13442if test "${ac_cv_lib_png_png_get_channels+set}" = set; then
13443  echo $ECHO_N "(cached) $ECHO_C" >&6
13444else
13445  ac_check_lib_save_LIBS=$LIBS
13446LIBS="-lpng -lz -lm $LIBS"
13447cat >conftest.$ac_ext <<_ACEOF
13448/* confdefs.h.  */
13449_ACEOF
13450cat confdefs.h >>conftest.$ac_ext
13451cat >>conftest.$ac_ext <<_ACEOF
13452/* end confdefs.h.  */
13453
13454/* Override any GCC internal prototype to avoid an error.
13455   Use char because int might match the return type of a GCC
13456   builtin and then its argument prototype would still apply.  */
13457#ifdef __cplusplus
13458extern "C"
13459#endif
13460char png_get_channels ();
13461int
13462main ()
13463{
13464return png_get_channels ();
13465  ;
13466  return 0;
13467}
13468_ACEOF
13469rm -f conftest.$ac_objext conftest$ac_exeext
13470if { (ac_try="$ac_link"
13471case "(($ac_try" in
13472  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13473  *) ac_try_echo=$ac_try;;
13474esac
13475eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13476  (eval "$ac_link") 2>conftest.er1
13477  ac_status=$?
13478  grep -v '^ *+' conftest.er1 >conftest.err
13479  rm -f conftest.er1
13480  cat conftest.err >&5
13481  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13482  (exit $ac_status); } && {
13483	 test -z "$ac_c_werror_flag" ||
13484	 test ! -s conftest.err
13485       } && test -s conftest$ac_exeext &&
13486       $as_test_x conftest$ac_exeext; then
13487  ac_cv_lib_png_png_get_channels=yes
13488else
13489  echo "$as_me: failed program was:" >&5
13490sed 's/^/| /' conftest.$ac_ext >&5
13491
13492	ac_cv_lib_png_png_get_channels=no
13493fi
13494
13495rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13496      conftest$ac_exeext conftest.$ac_ext
13497LIBS=$ac_check_lib_save_LIBS
13498fi
13499{ echo "$as_me:$LINENO: result: $ac_cv_lib_png_png_get_channels" >&5
13500echo "${ECHO_T}$ac_cv_lib_png_png_get_channels" >&6; }
13501if test $ac_cv_lib_png_png_get_channels = yes; then
13502  HAVE_PNG=yes
13503fi
13504
13505    fi
13506  fi
13507
13508  if test "${HAVE_PNG}" = "yes"; then
13509
13510cat >>confdefs.h <<\_ACEOF
13511#define HAVE_PNG 1
13512_ACEOF
13513
13514  fi
13515fi
13516
13517### Use -ltiff if available, unless `--with-tiff=no'.
13518HAVE_TIFF=no
13519if test "${HAVE_X11}" = "yes"; then
13520  if test "${with_tiff}" != "no"; then
13521    if test "${ac_cv_header_tiffio_h+set}" = set; then
13522  { echo "$as_me:$LINENO: checking for tiffio.h" >&5
13523echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6; }
13524if test "${ac_cv_header_tiffio_h+set}" = set; then
13525  echo $ECHO_N "(cached) $ECHO_C" >&6
13526fi
13527{ echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
13528echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6; }
13529else
13530  # Is the header compilable?
13531{ echo "$as_me:$LINENO: checking tiffio.h usability" >&5
13532echo $ECHO_N "checking tiffio.h usability... $ECHO_C" >&6; }
13533cat >conftest.$ac_ext <<_ACEOF
13534/* confdefs.h.  */
13535_ACEOF
13536cat confdefs.h >>conftest.$ac_ext
13537cat >>conftest.$ac_ext <<_ACEOF
13538/* end confdefs.h.  */
13539$ac_includes_default
13540#include <tiffio.h>
13541_ACEOF
13542rm -f conftest.$ac_objext
13543if { (ac_try="$ac_compile"
13544case "(($ac_try" in
13545  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13546  *) ac_try_echo=$ac_try;;
13547esac
13548eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13549  (eval "$ac_compile") 2>conftest.er1
13550  ac_status=$?
13551  grep -v '^ *+' conftest.er1 >conftest.err
13552  rm -f conftest.er1
13553  cat conftest.err >&5
13554  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13555  (exit $ac_status); } && {
13556	 test -z "$ac_c_werror_flag" ||
13557	 test ! -s conftest.err
13558       } && test -s conftest.$ac_objext; then
13559  ac_header_compiler=yes
13560else
13561  echo "$as_me: failed program was:" >&5
13562sed 's/^/| /' conftest.$ac_ext >&5
13563
13564	ac_header_compiler=no
13565fi
13566
13567rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13568{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13569echo "${ECHO_T}$ac_header_compiler" >&6; }
13570
13571# Is the header present?
13572{ echo "$as_me:$LINENO: checking tiffio.h presence" >&5
13573echo $ECHO_N "checking tiffio.h presence... $ECHO_C" >&6; }
13574cat >conftest.$ac_ext <<_ACEOF
13575/* confdefs.h.  */
13576_ACEOF
13577cat confdefs.h >>conftest.$ac_ext
13578cat >>conftest.$ac_ext <<_ACEOF
13579/* end confdefs.h.  */
13580#include <tiffio.h>
13581_ACEOF
13582if { (ac_try="$ac_cpp conftest.$ac_ext"
13583case "(($ac_try" in
13584  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13585  *) ac_try_echo=$ac_try;;
13586esac
13587eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13588  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13589  ac_status=$?
13590  grep -v '^ *+' conftest.er1 >conftest.err
13591  rm -f conftest.er1
13592  cat conftest.err >&5
13593  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13594  (exit $ac_status); } >/dev/null && {
13595	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13596	 test ! -s conftest.err
13597       }; then
13598  ac_header_preproc=yes
13599else
13600  echo "$as_me: failed program was:" >&5
13601sed 's/^/| /' conftest.$ac_ext >&5
13602
13603  ac_header_preproc=no
13604fi
13605
13606rm -f conftest.err conftest.$ac_ext
13607{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13608echo "${ECHO_T}$ac_header_preproc" >&6; }
13609
13610# So?  What about this header?
13611case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13612  yes:no: )
13613    { echo "$as_me:$LINENO: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&5
13614echo "$as_me: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13615    { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the compiler's result" >&5
13616echo "$as_me: WARNING: tiffio.h: proceeding with the compiler's result" >&2;}
13617    ac_header_preproc=yes
13618    ;;
13619  no:yes:* )
13620    { echo "$as_me:$LINENO: WARNING: tiffio.h: present but cannot be compiled" >&5
13621echo "$as_me: WARNING: tiffio.h: present but cannot be compiled" >&2;}
13622    { echo "$as_me:$LINENO: WARNING: tiffio.h:     check for missing prerequisite headers?" >&5
13623echo "$as_me: WARNING: tiffio.h:     check for missing prerequisite headers?" >&2;}
13624    { echo "$as_me:$LINENO: WARNING: tiffio.h: see the Autoconf documentation" >&5
13625echo "$as_me: WARNING: tiffio.h: see the Autoconf documentation" >&2;}
13626    { echo "$as_me:$LINENO: WARNING: tiffio.h:     section \"Present But Cannot Be Compiled\"" >&5
13627echo "$as_me: WARNING: tiffio.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13628    { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
13629echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
13630    { echo "$as_me:$LINENO: WARNING: tiffio.h: in the future, the compiler will take precedence" >&5
13631echo "$as_me: WARNING: tiffio.h: in the future, the compiler will take precedence" >&2;}
13632
13633    ;;
13634esac
13635{ echo "$as_me:$LINENO: checking for tiffio.h" >&5
13636echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6; }
13637if test "${ac_cv_header_tiffio_h+set}" = set; then
13638  echo $ECHO_N "(cached) $ECHO_C" >&6
13639else
13640  ac_cv_header_tiffio_h=$ac_header_preproc
13641fi
13642{ echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
13643echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6; }
13644
13645fi
13646if test $ac_cv_header_tiffio_h = yes; then
13647  tifflibs="-lz -lm"
13648      # At least one tiff package requires the jpeg library.
13649      if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
13650      { echo "$as_me:$LINENO: checking for TIFFGetVersion in -ltiff" >&5
13651echo $ECHO_N "checking for TIFFGetVersion in -ltiff... $ECHO_C" >&6; }
13652if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then
13653  echo $ECHO_N "(cached) $ECHO_C" >&6
13654else
13655  ac_check_lib_save_LIBS=$LIBS
13656LIBS="-ltiff $tifflibs $LIBS"
13657cat >conftest.$ac_ext <<_ACEOF
13658/* confdefs.h.  */
13659_ACEOF
13660cat confdefs.h >>conftest.$ac_ext
13661cat >>conftest.$ac_ext <<_ACEOF
13662/* end confdefs.h.  */
13663
13664/* Override any GCC internal prototype to avoid an error.
13665   Use char because int might match the return type of a GCC
13666   builtin and then its argument prototype would still apply.  */
13667#ifdef __cplusplus
13668extern "C"
13669#endif
13670char TIFFGetVersion ();
13671int
13672main ()
13673{
13674return TIFFGetVersion ();
13675  ;
13676  return 0;
13677}
13678_ACEOF
13679rm -f conftest.$ac_objext conftest$ac_exeext
13680if { (ac_try="$ac_link"
13681case "(($ac_try" in
13682  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13683  *) ac_try_echo=$ac_try;;
13684esac
13685eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13686  (eval "$ac_link") 2>conftest.er1
13687  ac_status=$?
13688  grep -v '^ *+' conftest.er1 >conftest.err
13689  rm -f conftest.er1
13690  cat conftest.err >&5
13691  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13692  (exit $ac_status); } && {
13693	 test -z "$ac_c_werror_flag" ||
13694	 test ! -s conftest.err
13695       } && test -s conftest$ac_exeext &&
13696       $as_test_x conftest$ac_exeext; then
13697  ac_cv_lib_tiff_TIFFGetVersion=yes
13698else
13699  echo "$as_me: failed program was:" >&5
13700sed 's/^/| /' conftest.$ac_ext >&5
13701
13702	ac_cv_lib_tiff_TIFFGetVersion=no
13703fi
13704
13705rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13706      conftest$ac_exeext conftest.$ac_ext
13707LIBS=$ac_check_lib_save_LIBS
13708fi
13709{ echo "$as_me:$LINENO: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
13710echo "${ECHO_T}$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
13711if test $ac_cv_lib_tiff_TIFFGetVersion = yes; then
13712  HAVE_TIFF=yes
13713fi
13714
13715fi
13716
13717
13718  fi
13719
13720  if test "${HAVE_TIFF}" = "yes"; then
13721
13722cat >>confdefs.h <<\_ACEOF
13723#define HAVE_TIFF 1
13724_ACEOF
13725
13726  fi
13727fi
13728
13729### Use -lgif if available, unless `--with-gif=no'.
13730HAVE_GIF=no
13731if test "${HAVE_X11}" = "yes"; then
13732  if test "${with_gif}" != "no"; then
13733    if test "${ac_cv_header_gif_lib_h+set}" = set; then
13734  { echo "$as_me:$LINENO: checking for gif_lib.h" >&5
13735echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6; }
13736if test "${ac_cv_header_gif_lib_h+set}" = set; then
13737  echo $ECHO_N "(cached) $ECHO_C" >&6
13738fi
13739{ echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
13740echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6; }
13741else
13742  # Is the header compilable?
13743{ echo "$as_me:$LINENO: checking gif_lib.h usability" >&5
13744echo $ECHO_N "checking gif_lib.h usability... $ECHO_C" >&6; }
13745cat >conftest.$ac_ext <<_ACEOF
13746/* confdefs.h.  */
13747_ACEOF
13748cat confdefs.h >>conftest.$ac_ext
13749cat >>conftest.$ac_ext <<_ACEOF
13750/* end confdefs.h.  */
13751$ac_includes_default
13752#include <gif_lib.h>
13753_ACEOF
13754rm -f conftest.$ac_objext
13755if { (ac_try="$ac_compile"
13756case "(($ac_try" in
13757  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13758  *) ac_try_echo=$ac_try;;
13759esac
13760eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13761  (eval "$ac_compile") 2>conftest.er1
13762  ac_status=$?
13763  grep -v '^ *+' conftest.er1 >conftest.err
13764  rm -f conftest.er1
13765  cat conftest.err >&5
13766  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13767  (exit $ac_status); } && {
13768	 test -z "$ac_c_werror_flag" ||
13769	 test ! -s conftest.err
13770       } && test -s conftest.$ac_objext; then
13771  ac_header_compiler=yes
13772else
13773  echo "$as_me: failed program was:" >&5
13774sed 's/^/| /' conftest.$ac_ext >&5
13775
13776	ac_header_compiler=no
13777fi
13778
13779rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13780{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13781echo "${ECHO_T}$ac_header_compiler" >&6; }
13782
13783# Is the header present?
13784{ echo "$as_me:$LINENO: checking gif_lib.h presence" >&5
13785echo $ECHO_N "checking gif_lib.h presence... $ECHO_C" >&6; }
13786cat >conftest.$ac_ext <<_ACEOF
13787/* confdefs.h.  */
13788_ACEOF
13789cat confdefs.h >>conftest.$ac_ext
13790cat >>conftest.$ac_ext <<_ACEOF
13791/* end confdefs.h.  */
13792#include <gif_lib.h>
13793_ACEOF
13794if { (ac_try="$ac_cpp conftest.$ac_ext"
13795case "(($ac_try" in
13796  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13797  *) ac_try_echo=$ac_try;;
13798esac
13799eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13800  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13801  ac_status=$?
13802  grep -v '^ *+' conftest.er1 >conftest.err
13803  rm -f conftest.er1
13804  cat conftest.err >&5
13805  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13806  (exit $ac_status); } >/dev/null && {
13807	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13808	 test ! -s conftest.err
13809       }; then
13810  ac_header_preproc=yes
13811else
13812  echo "$as_me: failed program was:" >&5
13813sed 's/^/| /' conftest.$ac_ext >&5
13814
13815  ac_header_preproc=no
13816fi
13817
13818rm -f conftest.err conftest.$ac_ext
13819{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13820echo "${ECHO_T}$ac_header_preproc" >&6; }
13821
13822# So?  What about this header?
13823case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13824  yes:no: )
13825    { echo "$as_me:$LINENO: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&5
13826echo "$as_me: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13827    { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the compiler's result" >&5
13828echo "$as_me: WARNING: gif_lib.h: proceeding with the compiler's result" >&2;}
13829    ac_header_preproc=yes
13830    ;;
13831  no:yes:* )
13832    { echo "$as_me:$LINENO: WARNING: gif_lib.h: present but cannot be compiled" >&5
13833echo "$as_me: WARNING: gif_lib.h: present but cannot be compiled" >&2;}
13834    { echo "$as_me:$LINENO: WARNING: gif_lib.h:     check for missing prerequisite headers?" >&5
13835echo "$as_me: WARNING: gif_lib.h:     check for missing prerequisite headers?" >&2;}
13836    { echo "$as_me:$LINENO: WARNING: gif_lib.h: see the Autoconf documentation" >&5
13837echo "$as_me: WARNING: gif_lib.h: see the Autoconf documentation" >&2;}
13838    { echo "$as_me:$LINENO: WARNING: gif_lib.h:     section \"Present But Cannot Be Compiled\"" >&5
13839echo "$as_me: WARNING: gif_lib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13840    { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
13841echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
13842    { echo "$as_me:$LINENO: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&5
13843echo "$as_me: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&2;}
13844
13845    ;;
13846esac
13847{ echo "$as_me:$LINENO: checking for gif_lib.h" >&5
13848echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6; }
13849if test "${ac_cv_header_gif_lib_h+set}" = set; then
13850  echo $ECHO_N "(cached) $ECHO_C" >&6
13851else
13852  ac_cv_header_gif_lib_h=$ac_header_preproc
13853fi
13854{ echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
13855echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6; }
13856
13857fi
13858if test $ac_cv_header_gif_lib_h = yes; then
13859  # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
13860# Earlier versions can crash Emacs.
13861      { echo "$as_me:$LINENO: checking for EGifPutExtensionLast in -lungif" >&5
13862echo $ECHO_N "checking for EGifPutExtensionLast in -lungif... $ECHO_C" >&6; }
13863if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then
13864  echo $ECHO_N "(cached) $ECHO_C" >&6
13865else
13866  ac_check_lib_save_LIBS=$LIBS
13867LIBS="-lungif  $LIBS"
13868cat >conftest.$ac_ext <<_ACEOF
13869/* confdefs.h.  */
13870_ACEOF
13871cat confdefs.h >>conftest.$ac_ext
13872cat >>conftest.$ac_ext <<_ACEOF
13873/* end confdefs.h.  */
13874
13875/* Override any GCC internal prototype to avoid an error.
13876   Use char because int might match the return type of a GCC
13877   builtin and then its argument prototype would still apply.  */
13878#ifdef __cplusplus
13879extern "C"
13880#endif
13881char EGifPutExtensionLast ();
13882int
13883main ()
13884{
13885return EGifPutExtensionLast ();
13886  ;
13887  return 0;
13888}
13889_ACEOF
13890rm -f conftest.$ac_objext conftest$ac_exeext
13891if { (ac_try="$ac_link"
13892case "(($ac_try" in
13893  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13894  *) ac_try_echo=$ac_try;;
13895esac
13896eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13897  (eval "$ac_link") 2>conftest.er1
13898  ac_status=$?
13899  grep -v '^ *+' conftest.er1 >conftest.err
13900  rm -f conftest.er1
13901  cat conftest.err >&5
13902  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13903  (exit $ac_status); } && {
13904	 test -z "$ac_c_werror_flag" ||
13905	 test ! -s conftest.err
13906       } && test -s conftest$ac_exeext &&
13907       $as_test_x conftest$ac_exeext; then
13908  ac_cv_lib_ungif_EGifPutExtensionLast=yes
13909else
13910  echo "$as_me: failed program was:" >&5
13911sed 's/^/| /' conftest.$ac_ext >&5
13912
13913	ac_cv_lib_ungif_EGifPutExtensionLast=no
13914fi
13915
13916rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13917      conftest$ac_exeext conftest.$ac_ext
13918LIBS=$ac_check_lib_save_LIBS
13919fi
13920{ echo "$as_me:$LINENO: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
13921echo "${ECHO_T}$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
13922if test $ac_cv_lib_ungif_EGifPutExtensionLast = yes; then
13923  HAVE_GIF=yes
13924fi
13925
13926fi
13927
13928
13929  fi
13930
13931  if test "${HAVE_GIF}" = "yes"; then
13932
13933cat >>confdefs.h <<\_ACEOF
13934#define HAVE_GIF 1
13935_ACEOF
13936
13937  fi
13938fi
13939
13940if test "${ac_cv_header_malloc_malloc_h+set}" = set; then
13941  { echo "$as_me:$LINENO: checking for malloc/malloc.h" >&5
13942echo $ECHO_N "checking for malloc/malloc.h... $ECHO_C" >&6; }
13943if test "${ac_cv_header_malloc_malloc_h+set}" = set; then
13944  echo $ECHO_N "(cached) $ECHO_C" >&6
13945fi
13946{ echo "$as_me:$LINENO: result: $ac_cv_header_malloc_malloc_h" >&5
13947echo "${ECHO_T}$ac_cv_header_malloc_malloc_h" >&6; }
13948else
13949  # Is the header compilable?
13950{ echo "$as_me:$LINENO: checking malloc/malloc.h usability" >&5
13951echo $ECHO_N "checking malloc/malloc.h usability... $ECHO_C" >&6; }
13952cat >conftest.$ac_ext <<_ACEOF
13953/* confdefs.h.  */
13954_ACEOF
13955cat confdefs.h >>conftest.$ac_ext
13956cat >>conftest.$ac_ext <<_ACEOF
13957/* end confdefs.h.  */
13958$ac_includes_default
13959#include <malloc/malloc.h>
13960_ACEOF
13961rm -f conftest.$ac_objext
13962if { (ac_try="$ac_compile"
13963case "(($ac_try" in
13964  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13965  *) ac_try_echo=$ac_try;;
13966esac
13967eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13968  (eval "$ac_compile") 2>conftest.er1
13969  ac_status=$?
13970  grep -v '^ *+' conftest.er1 >conftest.err
13971  rm -f conftest.er1
13972  cat conftest.err >&5
13973  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13974  (exit $ac_status); } && {
13975	 test -z "$ac_c_werror_flag" ||
13976	 test ! -s conftest.err
13977       } && test -s conftest.$ac_objext; then
13978  ac_header_compiler=yes
13979else
13980  echo "$as_me: failed program was:" >&5
13981sed 's/^/| /' conftest.$ac_ext >&5
13982
13983	ac_header_compiler=no
13984fi
13985
13986rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13987{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13988echo "${ECHO_T}$ac_header_compiler" >&6; }
13989
13990# Is the header present?
13991{ echo "$as_me:$LINENO: checking malloc/malloc.h presence" >&5
13992echo $ECHO_N "checking malloc/malloc.h presence... $ECHO_C" >&6; }
13993cat >conftest.$ac_ext <<_ACEOF
13994/* confdefs.h.  */
13995_ACEOF
13996cat confdefs.h >>conftest.$ac_ext
13997cat >>conftest.$ac_ext <<_ACEOF
13998/* end confdefs.h.  */
13999#include <malloc/malloc.h>
14000_ACEOF
14001if { (ac_try="$ac_cpp conftest.$ac_ext"
14002case "(($ac_try" in
14003  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14004  *) ac_try_echo=$ac_try;;
14005esac
14006eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14007  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14008  ac_status=$?
14009  grep -v '^ *+' conftest.er1 >conftest.err
14010  rm -f conftest.er1
14011  cat conftest.err >&5
14012  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14013  (exit $ac_status); } >/dev/null && {
14014	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14015	 test ! -s conftest.err
14016       }; then
14017  ac_header_preproc=yes
14018else
14019  echo "$as_me: failed program was:" >&5
14020sed 's/^/| /' conftest.$ac_ext >&5
14021
14022  ac_header_preproc=no
14023fi
14024
14025rm -f conftest.err conftest.$ac_ext
14026{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14027echo "${ECHO_T}$ac_header_preproc" >&6; }
14028
14029# So?  What about this header?
14030case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14031  yes:no: )
14032    { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: accepted by the compiler, rejected by the preprocessor!" >&5
14033echo "$as_me: WARNING: malloc/malloc.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14034    { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: proceeding with the compiler's result" >&5
14035echo "$as_me: WARNING: malloc/malloc.h: proceeding with the compiler's result" >&2;}
14036    ac_header_preproc=yes
14037    ;;
14038  no:yes:* )
14039    { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: present but cannot be compiled" >&5
14040echo "$as_me: WARNING: malloc/malloc.h: present but cannot be compiled" >&2;}
14041    { echo "$as_me:$LINENO: WARNING: malloc/malloc.h:     check for missing prerequisite headers?" >&5
14042echo "$as_me: WARNING: malloc/malloc.h:     check for missing prerequisite headers?" >&2;}
14043    { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: see the Autoconf documentation" >&5
14044echo "$as_me: WARNING: malloc/malloc.h: see the Autoconf documentation" >&2;}
14045    { echo "$as_me:$LINENO: WARNING: malloc/malloc.h:     section \"Present But Cannot Be Compiled\"" >&5
14046echo "$as_me: WARNING: malloc/malloc.h:     section \"Present But Cannot Be Compiled\"" >&2;}
14047    { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: proceeding with the preprocessor's result" >&5
14048echo "$as_me: WARNING: malloc/malloc.h: proceeding with the preprocessor's result" >&2;}
14049    { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: in the future, the compiler will take precedence" >&5
14050echo "$as_me: WARNING: malloc/malloc.h: in the future, the compiler will take precedence" >&2;}
14051
14052    ;;
14053esac
14054{ echo "$as_me:$LINENO: checking for malloc/malloc.h" >&5
14055echo $ECHO_N "checking for malloc/malloc.h... $ECHO_C" >&6; }
14056if test "${ac_cv_header_malloc_malloc_h+set}" = set; then
14057  echo $ECHO_N "(cached) $ECHO_C" >&6
14058else
14059  ac_cv_header_malloc_malloc_h=$ac_header_preproc
14060fi
14061{ echo "$as_me:$LINENO: result: $ac_cv_header_malloc_malloc_h" >&5
14062echo "${ECHO_T}$ac_cv_header_malloc_malloc_h" >&6; }
14063
14064fi
14065if test $ac_cv_header_malloc_malloc_h = yes; then
14066
14067cat >>confdefs.h <<\_ACEOF
14068#define HAVE_MALLOC_MALLOC_H 1
14069_ACEOF
14070
14071fi
14072
14073
14074
14075### Use Mac OS X Carbon API to implement GUI.
14076if test "${HAVE_CARBON}" = "yes"; then
14077
14078cat >>confdefs.h <<\_ACEOF
14079#define HAVE_CARBON 1
14080_ACEOF
14081
14082  ## Specify the install directory
14083  carbon_appdir=
14084  if test "${carbon_appdir_x}" != ""; then
14085    case ${carbon_appdir_x} in
14086      y | ye | yes)  carbon_appdir=/Applications ;;
14087      * ) carbon_appdir=${carbon_appdir_x} ;;
14088    esac
14089  fi
14090  # We also have mouse menus.
14091  HAVE_MENUS=yes
14092fi
14093
14094### Use session management (-lSM -lICE) if available
14095HAVE_X_SM=no
14096if test "${HAVE_X11}" = "yes"; then
14097  if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
14098  { echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
14099echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6; }
14100if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
14101  echo $ECHO_N "(cached) $ECHO_C" >&6
14102fi
14103{ echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
14104echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6; }
14105else
14106  # Is the header compilable?
14107{ echo "$as_me:$LINENO: checking X11/SM/SMlib.h usability" >&5
14108echo $ECHO_N "checking X11/SM/SMlib.h usability... $ECHO_C" >&6; }
14109cat >conftest.$ac_ext <<_ACEOF
14110/* confdefs.h.  */
14111_ACEOF
14112cat confdefs.h >>conftest.$ac_ext
14113cat >>conftest.$ac_ext <<_ACEOF
14114/* end confdefs.h.  */
14115$ac_includes_default
14116#include <X11/SM/SMlib.h>
14117_ACEOF
14118rm -f conftest.$ac_objext
14119if { (ac_try="$ac_compile"
14120case "(($ac_try" in
14121  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14122  *) ac_try_echo=$ac_try;;
14123esac
14124eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14125  (eval "$ac_compile") 2>conftest.er1
14126  ac_status=$?
14127  grep -v '^ *+' conftest.er1 >conftest.err
14128  rm -f conftest.er1
14129  cat conftest.err >&5
14130  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14131  (exit $ac_status); } && {
14132	 test -z "$ac_c_werror_flag" ||
14133	 test ! -s conftest.err
14134       } && test -s conftest.$ac_objext; then
14135  ac_header_compiler=yes
14136else
14137  echo "$as_me: failed program was:" >&5
14138sed 's/^/| /' conftest.$ac_ext >&5
14139
14140	ac_header_compiler=no
14141fi
14142
14143rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14144{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14145echo "${ECHO_T}$ac_header_compiler" >&6; }
14146
14147# Is the header present?
14148{ echo "$as_me:$LINENO: checking X11/SM/SMlib.h presence" >&5
14149echo $ECHO_N "checking X11/SM/SMlib.h presence... $ECHO_C" >&6; }
14150cat >conftest.$ac_ext <<_ACEOF
14151/* confdefs.h.  */
14152_ACEOF
14153cat confdefs.h >>conftest.$ac_ext
14154cat >>conftest.$ac_ext <<_ACEOF
14155/* end confdefs.h.  */
14156#include <X11/SM/SMlib.h>
14157_ACEOF
14158if { (ac_try="$ac_cpp conftest.$ac_ext"
14159case "(($ac_try" in
14160  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14161  *) ac_try_echo=$ac_try;;
14162esac
14163eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14164  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14165  ac_status=$?
14166  grep -v '^ *+' conftest.er1 >conftest.err
14167  rm -f conftest.er1
14168  cat conftest.err >&5
14169  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14170  (exit $ac_status); } >/dev/null && {
14171	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14172	 test ! -s conftest.err
14173       }; then
14174  ac_header_preproc=yes
14175else
14176  echo "$as_me: failed program was:" >&5
14177sed 's/^/| /' conftest.$ac_ext >&5
14178
14179  ac_header_preproc=no
14180fi
14181
14182rm -f conftest.err conftest.$ac_ext
14183{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14184echo "${ECHO_T}$ac_header_preproc" >&6; }
14185
14186# So?  What about this header?
14187case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14188  yes:no: )
14189    { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
14190echo "$as_me: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14191    { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&5
14192echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&2;}
14193    ac_header_preproc=yes
14194    ;;
14195  no:yes:* )
14196    { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&5
14197echo "$as_me: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&2;}
14198    { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h:     check for missing prerequisite headers?" >&5
14199echo "$as_me: WARNING: X11/SM/SMlib.h:     check for missing prerequisite headers?" >&2;}
14200    { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&5
14201echo "$as_me: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&2;}
14202    { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h:     section \"Present But Cannot Be Compiled\"" >&5
14203echo "$as_me: WARNING: X11/SM/SMlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
14204    { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
14205echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
14206    { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&5
14207echo "$as_me: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&2;}
14208
14209    ;;
14210esac
14211{ echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
14212echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6; }
14213if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
14214  echo $ECHO_N "(cached) $ECHO_C" >&6
14215else
14216  ac_cv_header_X11_SM_SMlib_h=$ac_header_preproc
14217fi
14218{ echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
14219echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6; }
14220
14221fi
14222if test $ac_cv_header_X11_SM_SMlib_h = yes; then
14223  { echo "$as_me:$LINENO: checking for SmcOpenConnection in -lSM" >&5
14224echo $ECHO_N "checking for SmcOpenConnection in -lSM... $ECHO_C" >&6; }
14225if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then
14226  echo $ECHO_N "(cached) $ECHO_C" >&6
14227else
14228  ac_check_lib_save_LIBS=$LIBS
14229LIBS="-lSM -lICE $LIBS"
14230cat >conftest.$ac_ext <<_ACEOF
14231/* confdefs.h.  */
14232_ACEOF
14233cat confdefs.h >>conftest.$ac_ext
14234cat >>conftest.$ac_ext <<_ACEOF
14235/* end confdefs.h.  */
14236
14237/* Override any GCC internal prototype to avoid an error.
14238   Use char because int might match the return type of a GCC
14239   builtin and then its argument prototype would still apply.  */
14240#ifdef __cplusplus
14241extern "C"
14242#endif
14243char SmcOpenConnection ();
14244int
14245main ()
14246{
14247return SmcOpenConnection ();
14248  ;
14249  return 0;
14250}
14251_ACEOF
14252rm -f conftest.$ac_objext conftest$ac_exeext
14253if { (ac_try="$ac_link"
14254case "(($ac_try" in
14255  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14256  *) ac_try_echo=$ac_try;;
14257esac
14258eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14259  (eval "$ac_link") 2>conftest.er1
14260  ac_status=$?
14261  grep -v '^ *+' conftest.er1 >conftest.err
14262  rm -f conftest.er1
14263  cat conftest.err >&5
14264  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14265  (exit $ac_status); } && {
14266	 test -z "$ac_c_werror_flag" ||
14267	 test ! -s conftest.err
14268       } && test -s conftest$ac_exeext &&
14269       $as_test_x conftest$ac_exeext; then
14270  ac_cv_lib_SM_SmcOpenConnection=yes
14271else
14272  echo "$as_me: failed program was:" >&5
14273sed 's/^/| /' conftest.$ac_ext >&5
14274
14275	ac_cv_lib_SM_SmcOpenConnection=no
14276fi
14277
14278rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14279      conftest$ac_exeext conftest.$ac_ext
14280LIBS=$ac_check_lib_save_LIBS
14281fi
14282{ echo "$as_me:$LINENO: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
14283echo "${ECHO_T}$ac_cv_lib_SM_SmcOpenConnection" >&6; }
14284if test $ac_cv_lib_SM_SmcOpenConnection = yes; then
14285  HAVE_X_SM=yes
14286fi
14287
14288fi
14289
14290
14291
14292  if test "${HAVE_X_SM}" = "yes"; then
14293
14294cat >>confdefs.h <<\_ACEOF
14295#define HAVE_X_SM 1
14296_ACEOF
14297
14298    case "$LIBS" in
14299      *-lSM*) ;;
14300      *)      LIBS="-lSM -lICE $LIBS" ;;
14301    esac
14302  fi
14303fi
14304
14305# If netdb.h doesn't declare h_errno, we must declare it by hand.
14306{ echo "$as_me:$LINENO: checking whether netdb declares h_errno" >&5
14307echo $ECHO_N "checking whether netdb declares h_errno... $ECHO_C" >&6; }
14308if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then
14309  echo $ECHO_N "(cached) $ECHO_C" >&6
14310else
14311  cat >conftest.$ac_ext <<_ACEOF
14312/* confdefs.h.  */
14313_ACEOF
14314cat confdefs.h >>conftest.$ac_ext
14315cat >>conftest.$ac_ext <<_ACEOF
14316/* end confdefs.h.  */
14317#include <netdb.h>
14318int
14319main ()
14320{
14321return h_errno;
14322  ;
14323  return 0;
14324}
14325_ACEOF
14326rm -f conftest.$ac_objext conftest$ac_exeext
14327if { (ac_try="$ac_link"
14328case "(($ac_try" in
14329  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14330  *) ac_try_echo=$ac_try;;
14331esac
14332eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14333  (eval "$ac_link") 2>conftest.er1
14334  ac_status=$?
14335  grep -v '^ *+' conftest.er1 >conftest.err
14336  rm -f conftest.er1
14337  cat conftest.err >&5
14338  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14339  (exit $ac_status); } && {
14340	 test -z "$ac_c_werror_flag" ||
14341	 test ! -s conftest.err
14342       } && test -s conftest$ac_exeext &&
14343       $as_test_x conftest$ac_exeext; then
14344  emacs_cv_netdb_declares_h_errno=yes
14345else
14346  echo "$as_me: failed program was:" >&5
14347sed 's/^/| /' conftest.$ac_ext >&5
14348
14349	emacs_cv_netdb_declares_h_errno=no
14350fi
14351
14352rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14353      conftest$ac_exeext conftest.$ac_ext
14354fi
14355{ echo "$as_me:$LINENO: result: $emacs_cv_netdb_declares_h_errno" >&5
14356echo "${ECHO_T}$emacs_cv_netdb_declares_h_errno" >&6; }
14357if test $emacs_cv_netdb_declares_h_errno = yes; then
14358
14359cat >>confdefs.h <<\_ACEOF
14360#define HAVE_H_ERRNO 1
14361_ACEOF
14362
14363fi
14364
14365# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
14366# for constant arguments.  Useless!
14367{ echo "$as_me:$LINENO: checking for working alloca.h" >&5
14368echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6; }
14369if test "${ac_cv_working_alloca_h+set}" = set; then
14370  echo $ECHO_N "(cached) $ECHO_C" >&6
14371else
14372  cat >conftest.$ac_ext <<_ACEOF
14373/* confdefs.h.  */
14374_ACEOF
14375cat confdefs.h >>conftest.$ac_ext
14376cat >>conftest.$ac_ext <<_ACEOF
14377/* end confdefs.h.  */
14378#include <alloca.h>
14379int
14380main ()
14381{
14382char *p = (char *) alloca (2 * sizeof (int));
14383			  if (p) return 0;
14384  ;
14385  return 0;
14386}
14387_ACEOF
14388rm -f conftest.$ac_objext conftest$ac_exeext
14389if { (ac_try="$ac_link"
14390case "(($ac_try" in
14391  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14392  *) ac_try_echo=$ac_try;;
14393esac
14394eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14395  (eval "$ac_link") 2>conftest.er1
14396  ac_status=$?
14397  grep -v '^ *+' conftest.er1 >conftest.err
14398  rm -f conftest.er1
14399  cat conftest.err >&5
14400  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14401  (exit $ac_status); } && {
14402	 test -z "$ac_c_werror_flag" ||
14403	 test ! -s conftest.err
14404       } && test -s conftest$ac_exeext &&
14405       $as_test_x conftest$ac_exeext; then
14406  ac_cv_working_alloca_h=yes
14407else
14408  echo "$as_me: failed program was:" >&5
14409sed 's/^/| /' conftest.$ac_ext >&5
14410
14411	ac_cv_working_alloca_h=no
14412fi
14413
14414rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14415      conftest$ac_exeext conftest.$ac_ext
14416fi
14417{ echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5
14418echo "${ECHO_T}$ac_cv_working_alloca_h" >&6; }
14419if test $ac_cv_working_alloca_h = yes; then
14420
14421cat >>confdefs.h <<\_ACEOF
14422#define HAVE_ALLOCA_H 1
14423_ACEOF
14424
14425fi
14426
14427{ echo "$as_me:$LINENO: checking for alloca" >&5
14428echo $ECHO_N "checking for alloca... $ECHO_C" >&6; }
14429if test "${ac_cv_func_alloca_works+set}" = set; then
14430  echo $ECHO_N "(cached) $ECHO_C" >&6
14431else
14432  cat >conftest.$ac_ext <<_ACEOF
14433/* confdefs.h.  */
14434_ACEOF
14435cat confdefs.h >>conftest.$ac_ext
14436cat >>conftest.$ac_ext <<_ACEOF
14437/* end confdefs.h.  */
14438#ifdef __GNUC__
14439# define alloca __builtin_alloca
14440#else
14441# ifdef _MSC_VER
14442#  include <malloc.h>
14443#  define alloca _alloca
14444# else
14445#  ifdef HAVE_ALLOCA_H
14446#   include <alloca.h>
14447#  else
14448#   ifdef _AIX
14449 #pragma alloca
14450#   else
14451#    ifndef alloca /* predefined by HP cc +Olibcalls */
14452char *alloca ();
14453#    endif
14454#   endif
14455#  endif
14456# endif
14457#endif
14458
14459int
14460main ()
14461{
14462char *p = (char *) alloca (1);
14463				    if (p) return 0;
14464  ;
14465  return 0;
14466}
14467_ACEOF
14468rm -f conftest.$ac_objext conftest$ac_exeext
14469if { (ac_try="$ac_link"
14470case "(($ac_try" in
14471  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14472  *) ac_try_echo=$ac_try;;
14473esac
14474eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14475  (eval "$ac_link") 2>conftest.er1
14476  ac_status=$?
14477  grep -v '^ *+' conftest.er1 >conftest.err
14478  rm -f conftest.er1
14479  cat conftest.err >&5
14480  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14481  (exit $ac_status); } && {
14482	 test -z "$ac_c_werror_flag" ||
14483	 test ! -s conftest.err
14484       } && test -s conftest$ac_exeext &&
14485       $as_test_x conftest$ac_exeext; then
14486  ac_cv_func_alloca_works=yes
14487else
14488  echo "$as_me: failed program was:" >&5
14489sed 's/^/| /' conftest.$ac_ext >&5
14490
14491	ac_cv_func_alloca_works=no
14492fi
14493
14494rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14495      conftest$ac_exeext conftest.$ac_ext
14496fi
14497{ echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5
14498echo "${ECHO_T}$ac_cv_func_alloca_works" >&6; }
14499
14500if test $ac_cv_func_alloca_works = yes; then
14501
14502cat >>confdefs.h <<\_ACEOF
14503#define HAVE_ALLOCA 1
14504_ACEOF
14505
14506else
14507  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
14508# that cause trouble.  Some versions do not even contain alloca or
14509# contain a buggy version.  If you still want to use their alloca,
14510# use ar to extract alloca.o from them instead of compiling alloca.c.
14511
14512ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
14513
14514cat >>confdefs.h <<\_ACEOF
14515#define C_ALLOCA 1
14516_ACEOF
14517
14518
14519{ echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5
14520echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6; }
14521if test "${ac_cv_os_cray+set}" = set; then
14522  echo $ECHO_N "(cached) $ECHO_C" >&6
14523else
14524  cat >conftest.$ac_ext <<_ACEOF
14525/* confdefs.h.  */
14526_ACEOF
14527cat confdefs.h >>conftest.$ac_ext
14528cat >>conftest.$ac_ext <<_ACEOF
14529/* end confdefs.h.  */
14530#if defined CRAY && ! defined CRAY2
14531webecray
14532#else
14533wenotbecray
14534#endif
14535
14536_ACEOF
14537if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14538  $EGREP "webecray" >/dev/null 2>&1; then
14539  ac_cv_os_cray=yes
14540else
14541  ac_cv_os_cray=no
14542fi
14543rm -f conftest*
14544
14545fi
14546{ echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
14547echo "${ECHO_T}$ac_cv_os_cray" >&6; }
14548if test $ac_cv_os_cray = yes; then
14549  for ac_func in _getb67 GETB67 getb67; do
14550    as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14551{ echo "$as_me:$LINENO: checking for $ac_func" >&5
14552echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
14553if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
14554  echo $ECHO_N "(cached) $ECHO_C" >&6
14555else
14556  cat >conftest.$ac_ext <<_ACEOF
14557/* confdefs.h.  */
14558_ACEOF
14559cat confdefs.h >>conftest.$ac_ext
14560cat >>conftest.$ac_ext <<_ACEOF
14561/* end confdefs.h.  */
14562/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14563   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14564#define $ac_func innocuous_$ac_func
14565
14566/* System header to define __stub macros and hopefully few prototypes,
14567    which can conflict with char $ac_func (); below.
14568    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14569    <limits.h> exists even on freestanding compilers.  */
14570
14571#ifdef __STDC__
14572# include <limits.h>
14573#else
14574# include <assert.h>
14575#endif
14576
14577#undef $ac_func
14578
14579/* Override any GCC internal prototype to avoid an error.
14580   Use char because int might match the return type of a GCC
14581   builtin and then its argument prototype would still apply.  */
14582#ifdef __cplusplus
14583extern "C"
14584#endif
14585char $ac_func ();
14586/* The GNU C library defines this for functions which it implements
14587    to always fail with ENOSYS.  Some functions are actually named
14588    something starting with __ and the normal name is an alias.  */
14589#if defined __stub_$ac_func || defined __stub___$ac_func
14590choke me
14591#endif
14592
14593int
14594main ()
14595{
14596return $ac_func ();
14597  ;
14598  return 0;
14599}
14600_ACEOF
14601rm -f conftest.$ac_objext conftest$ac_exeext
14602if { (ac_try="$ac_link"
14603case "(($ac_try" in
14604  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14605  *) ac_try_echo=$ac_try;;
14606esac
14607eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14608  (eval "$ac_link") 2>conftest.er1
14609  ac_status=$?
14610  grep -v '^ *+' conftest.er1 >conftest.err
14611  rm -f conftest.er1
14612  cat conftest.err >&5
14613  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14614  (exit $ac_status); } && {
14615	 test -z "$ac_c_werror_flag" ||
14616	 test ! -s conftest.err
14617       } && test -s conftest$ac_exeext &&
14618       $as_test_x conftest$ac_exeext; then
14619  eval "$as_ac_var=yes"
14620else
14621  echo "$as_me: failed program was:" >&5
14622sed 's/^/| /' conftest.$ac_ext >&5
14623
14624	eval "$as_ac_var=no"
14625fi
14626
14627rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14628      conftest$ac_exeext conftest.$ac_ext
14629fi
14630ac_res=`eval echo '${'$as_ac_var'}'`
14631	       { echo "$as_me:$LINENO: result: $ac_res" >&5
14632echo "${ECHO_T}$ac_res" >&6; }
14633if test `eval echo '${'$as_ac_var'}'` = yes; then
14634
14635cat >>confdefs.h <<_ACEOF
14636#define CRAY_STACKSEG_END $ac_func
14637_ACEOF
14638
14639    break
14640fi
14641
14642  done
14643fi
14644
14645{ echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
14646echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6; }
14647if test "${ac_cv_c_stack_direction+set}" = set; then
14648  echo $ECHO_N "(cached) $ECHO_C" >&6
14649else
14650  if test "$cross_compiling" = yes; then
14651  ac_cv_c_stack_direction=0
14652else
14653  cat >conftest.$ac_ext <<_ACEOF
14654/* confdefs.h.  */
14655_ACEOF
14656cat confdefs.h >>conftest.$ac_ext
14657cat >>conftest.$ac_ext <<_ACEOF
14658/* end confdefs.h.  */
14659$ac_includes_default
14660int
14661find_stack_direction ()
14662{
14663  static char *addr = 0;
14664  auto char dummy;
14665  if (addr == 0)
14666    {
14667      addr = &dummy;
14668      return find_stack_direction ();
14669    }
14670  else
14671    return (&dummy > addr) ? 1 : -1;
14672}
14673
14674int
14675main ()
14676{
14677  return find_stack_direction () < 0;
14678}
14679_ACEOF
14680rm -f conftest$ac_exeext
14681if { (ac_try="$ac_link"
14682case "(($ac_try" in
14683  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14684  *) ac_try_echo=$ac_try;;
14685esac
14686eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14687  (eval "$ac_link") 2>&5
14688  ac_status=$?
14689  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14690  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14691  { (case "(($ac_try" in
14692  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14693  *) ac_try_echo=$ac_try;;
14694esac
14695eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14696  (eval "$ac_try") 2>&5
14697  ac_status=$?
14698  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14699  (exit $ac_status); }; }; then
14700  ac_cv_c_stack_direction=1
14701else
14702  echo "$as_me: program exited with status $ac_status" >&5
14703echo "$as_me: failed program was:" >&5
14704sed 's/^/| /' conftest.$ac_ext >&5
14705
14706( exit $ac_status )
14707ac_cv_c_stack_direction=-1
14708fi
14709rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14710fi
14711
14712
14713fi
14714{ echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
14715echo "${ECHO_T}$ac_cv_c_stack_direction" >&6; }
14716
14717cat >>confdefs.h <<_ACEOF
14718#define STACK_DIRECTION $ac_cv_c_stack_direction
14719_ACEOF
14720
14721
14722fi
14723
14724
14725# fmod, logb, and frexp are found in -lm on most systems.
14726# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
14727
14728{ echo "$as_me:$LINENO: checking for sqrt in -lm" >&5
14729echo $ECHO_N "checking for sqrt in -lm... $ECHO_C" >&6; }
14730if test "${ac_cv_lib_m_sqrt+set}" = set; then
14731  echo $ECHO_N "(cached) $ECHO_C" >&6
14732else
14733  ac_check_lib_save_LIBS=$LIBS
14734LIBS="-lm  $LIBS"
14735cat >conftest.$ac_ext <<_ACEOF
14736/* confdefs.h.  */
14737_ACEOF
14738cat confdefs.h >>conftest.$ac_ext
14739cat >>conftest.$ac_ext <<_ACEOF
14740/* end confdefs.h.  */
14741
14742/* Override any GCC internal prototype to avoid an error.
14743   Use char because int might match the return type of a GCC
14744   builtin and then its argument prototype would still apply.  */
14745#ifdef __cplusplus
14746extern "C"
14747#endif
14748char sqrt ();
14749int
14750main ()
14751{
14752return sqrt ();
14753  ;
14754  return 0;
14755}
14756_ACEOF
14757rm -f conftest.$ac_objext conftest$ac_exeext
14758if { (ac_try="$ac_link"
14759case "(($ac_try" in
14760  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14761  *) ac_try_echo=$ac_try;;
14762esac
14763eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14764  (eval "$ac_link") 2>conftest.er1
14765  ac_status=$?
14766  grep -v '^ *+' conftest.er1 >conftest.err
14767  rm -f conftest.er1
14768  cat conftest.err >&5
14769  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14770  (exit $ac_status); } && {
14771	 test -z "$ac_c_werror_flag" ||
14772	 test ! -s conftest.err
14773       } && test -s conftest$ac_exeext &&
14774       $as_test_x conftest$ac_exeext; then
14775  ac_cv_lib_m_sqrt=yes
14776else
14777  echo "$as_me: failed program was:" >&5
14778sed 's/^/| /' conftest.$ac_ext >&5
14779
14780	ac_cv_lib_m_sqrt=no
14781fi
14782
14783rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14784      conftest$ac_exeext conftest.$ac_ext
14785LIBS=$ac_check_lib_save_LIBS
14786fi
14787{ echo "$as_me:$LINENO: result: $ac_cv_lib_m_sqrt" >&5
14788echo "${ECHO_T}$ac_cv_lib_m_sqrt" >&6; }
14789if test $ac_cv_lib_m_sqrt = yes; then
14790  cat >>confdefs.h <<_ACEOF
14791#define HAVE_LIBM 1
14792_ACEOF
14793
14794  LIBS="-lm $LIBS"
14795
14796fi
14797
14798
14799# Check for mail-locking functions in a "mail" library.  Probably this should
14800# have the same check as for liblockfile below.
14801
14802{ echo "$as_me:$LINENO: checking for maillock in -lmail" >&5
14803echo $ECHO_N "checking for maillock in -lmail... $ECHO_C" >&6; }
14804if test "${ac_cv_lib_mail_maillock+set}" = set; then
14805  echo $ECHO_N "(cached) $ECHO_C" >&6
14806else
14807  ac_check_lib_save_LIBS=$LIBS
14808LIBS="-lmail  $LIBS"
14809cat >conftest.$ac_ext <<_ACEOF
14810/* confdefs.h.  */
14811_ACEOF
14812cat confdefs.h >>conftest.$ac_ext
14813cat >>conftest.$ac_ext <<_ACEOF
14814/* end confdefs.h.  */
14815
14816/* Override any GCC internal prototype to avoid an error.
14817   Use char because int might match the return type of a GCC
14818   builtin and then its argument prototype would still apply.  */
14819#ifdef __cplusplus
14820extern "C"
14821#endif
14822char maillock ();
14823int
14824main ()
14825{
14826return maillock ();
14827  ;
14828  return 0;
14829}
14830_ACEOF
14831rm -f conftest.$ac_objext conftest$ac_exeext
14832if { (ac_try="$ac_link"
14833case "(($ac_try" in
14834  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14835  *) ac_try_echo=$ac_try;;
14836esac
14837eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14838  (eval "$ac_link") 2>conftest.er1
14839  ac_status=$?
14840  grep -v '^ *+' conftest.er1 >conftest.err
14841  rm -f conftest.er1
14842  cat conftest.err >&5
14843  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14844  (exit $ac_status); } && {
14845	 test -z "$ac_c_werror_flag" ||
14846	 test ! -s conftest.err
14847       } && test -s conftest$ac_exeext &&
14848       $as_test_x conftest$ac_exeext; then
14849  ac_cv_lib_mail_maillock=yes
14850else
14851  echo "$as_me: failed program was:" >&5
14852sed 's/^/| /' conftest.$ac_ext >&5
14853
14854	ac_cv_lib_mail_maillock=no
14855fi
14856
14857rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14858      conftest$ac_exeext conftest.$ac_ext
14859LIBS=$ac_check_lib_save_LIBS
14860fi
14861{ echo "$as_me:$LINENO: result: $ac_cv_lib_mail_maillock" >&5
14862echo "${ECHO_T}$ac_cv_lib_mail_maillock" >&6; }
14863if test $ac_cv_lib_mail_maillock = yes; then
14864  cat >>confdefs.h <<_ACEOF
14865#define HAVE_LIBMAIL 1
14866_ACEOF
14867
14868  LIBS="-lmail $LIBS"
14869
14870fi
14871
14872
14873{ echo "$as_me:$LINENO: checking for maillock in -llockfile" >&5
14874echo $ECHO_N "checking for maillock in -llockfile... $ECHO_C" >&6; }
14875if test "${ac_cv_lib_lockfile_maillock+set}" = set; then
14876  echo $ECHO_N "(cached) $ECHO_C" >&6
14877else
14878  ac_check_lib_save_LIBS=$LIBS
14879LIBS="-llockfile  $LIBS"
14880cat >conftest.$ac_ext <<_ACEOF
14881/* confdefs.h.  */
14882_ACEOF
14883cat confdefs.h >>conftest.$ac_ext
14884cat >>conftest.$ac_ext <<_ACEOF
14885/* end confdefs.h.  */
14886
14887/* Override any GCC internal prototype to avoid an error.
14888   Use char because int might match the return type of a GCC
14889   builtin and then its argument prototype would still apply.  */
14890#ifdef __cplusplus
14891extern "C"
14892#endif
14893char maillock ();
14894int
14895main ()
14896{
14897return maillock ();
14898  ;
14899  return 0;
14900}
14901_ACEOF
14902rm -f conftest.$ac_objext conftest$ac_exeext
14903if { (ac_try="$ac_link"
14904case "(($ac_try" in
14905  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14906  *) ac_try_echo=$ac_try;;
14907esac
14908eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14909  (eval "$ac_link") 2>conftest.er1
14910  ac_status=$?
14911  grep -v '^ *+' conftest.er1 >conftest.err
14912  rm -f conftest.er1
14913  cat conftest.err >&5
14914  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14915  (exit $ac_status); } && {
14916	 test -z "$ac_c_werror_flag" ||
14917	 test ! -s conftest.err
14918       } && test -s conftest$ac_exeext &&
14919       $as_test_x conftest$ac_exeext; then
14920  ac_cv_lib_lockfile_maillock=yes
14921else
14922  echo "$as_me: failed program was:" >&5
14923sed 's/^/| /' conftest.$ac_ext >&5
14924
14925	ac_cv_lib_lockfile_maillock=no
14926fi
14927
14928rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14929      conftest$ac_exeext conftest.$ac_ext
14930LIBS=$ac_check_lib_save_LIBS
14931fi
14932{ echo "$as_me:$LINENO: result: $ac_cv_lib_lockfile_maillock" >&5
14933echo "${ECHO_T}$ac_cv_lib_lockfile_maillock" >&6; }
14934if test $ac_cv_lib_lockfile_maillock = yes; then
14935  cat >>confdefs.h <<_ACEOF
14936#define HAVE_LIBLOCKFILE 1
14937_ACEOF
14938
14939  LIBS="-llockfile $LIBS"
14940
14941fi
14942
14943# If we have the shared liblockfile, assume we must use it for mail
14944# locking (e.g. Debian).  If we couldn't link against liblockfile
14945# (no liblockfile.a installed), ensure that we don't need to.
14946if test "$ac_cv_lib_lockfile_maillock" = no; then
14947      # Extract the first word of "liblockfile.so", so it can be a program name with args.
14948set dummy liblockfile.so; ac_word=$2
14949{ echo "$as_me:$LINENO: checking for $ac_word" >&5
14950echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
14951if test "${ac_cv_prog_liblockfile+set}" = set; then
14952  echo $ECHO_N "(cached) $ECHO_C" >&6
14953else
14954  if test -n "$liblockfile"; then
14955  ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
14956else
14957as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14958as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
14959for as_dir in $as_dummy
14960do
14961  IFS=$as_save_IFS
14962  test -z "$as_dir" && as_dir=.
14963  for ac_exec_ext in '' $ac_executable_extensions; do
14964  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
14965    ac_cv_prog_liblockfile="yes"
14966    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
14967    break 2
14968  fi
14969done
14970done
14971IFS=$as_save_IFS
14972
14973  test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
14974fi
14975fi
14976liblockfile=$ac_cv_prog_liblockfile
14977if test -n "$liblockfile"; then
14978  { echo "$as_me:$LINENO: result: $liblockfile" >&5
14979echo "${ECHO_T}$liblockfile" >&6; }
14980else
14981  { echo "$as_me:$LINENO: result: no" >&5
14982echo "${ECHO_T}no" >&6; }
14983fi
14984
14985
14986  if test $ac_cv_prog_liblockfile = yes; then
14987    { { echo "$as_me:$LINENO: error: Shared liblockfile found but can't link against it.
14988This probably means that movemail could lose mail.
14989There may be a \`development' package to install containing liblockfile." >&5
14990echo "$as_me: error: Shared liblockfile found but can't link against it.
14991This probably means that movemail could lose mail.
14992There may be a \`development' package to install containing liblockfile." >&2;}
14993   { (exit 1); exit 1; }; }
14994  else :
14995  fi
14996fi
14997
14998for ac_func in touchlock
14999do
15000as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15001{ echo "$as_me:$LINENO: checking for $ac_func" >&5
15002echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
15003if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15004  echo $ECHO_N "(cached) $ECHO_C" >&6
15005else
15006  cat >conftest.$ac_ext <<_ACEOF
15007/* confdefs.h.  */
15008_ACEOF
15009cat confdefs.h >>conftest.$ac_ext
15010cat >>conftest.$ac_ext <<_ACEOF
15011/* end confdefs.h.  */
15012/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15013   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15014#define $ac_func innocuous_$ac_func
15015
15016/* System header to define __stub macros and hopefully few prototypes,
15017    which can conflict with char $ac_func (); below.
15018    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15019    <limits.h> exists even on freestanding compilers.  */
15020
15021#ifdef __STDC__
15022# include <limits.h>
15023#else
15024# include <assert.h>
15025#endif
15026
15027#undef $ac_func
15028
15029/* Override any GCC internal prototype to avoid an error.
15030   Use char because int might match the return type of a GCC
15031   builtin and then its argument prototype would still apply.  */
15032#ifdef __cplusplus
15033extern "C"
15034#endif
15035char $ac_func ();
15036/* The GNU C library defines this for functions which it implements
15037    to always fail with ENOSYS.  Some functions are actually named
15038    something starting with __ and the normal name is an alias.  */
15039#if defined __stub_$ac_func || defined __stub___$ac_func
15040choke me
15041#endif
15042
15043int
15044main ()
15045{
15046return $ac_func ();
15047  ;
15048  return 0;
15049}
15050_ACEOF
15051rm -f conftest.$ac_objext conftest$ac_exeext
15052if { (ac_try="$ac_link"
15053case "(($ac_try" in
15054  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15055  *) ac_try_echo=$ac_try;;
15056esac
15057eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15058  (eval "$ac_link") 2>conftest.er1
15059  ac_status=$?
15060  grep -v '^ *+' conftest.er1 >conftest.err
15061  rm -f conftest.er1
15062  cat conftest.err >&5
15063  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15064  (exit $ac_status); } && {
15065	 test -z "$ac_c_werror_flag" ||
15066	 test ! -s conftest.err
15067       } && test -s conftest$ac_exeext &&
15068       $as_test_x conftest$ac_exeext; then
15069  eval "$as_ac_var=yes"
15070else
15071  echo "$as_me: failed program was:" >&5
15072sed 's/^/| /' conftest.$ac_ext >&5
15073
15074	eval "$as_ac_var=no"
15075fi
15076
15077rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15078      conftest$ac_exeext conftest.$ac_ext
15079fi
15080ac_res=`eval echo '${'$as_ac_var'}'`
15081	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15082echo "${ECHO_T}$ac_res" >&6; }
15083if test `eval echo '${'$as_ac_var'}'` = yes; then
15084  cat >>confdefs.h <<_ACEOF
15085#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15086_ACEOF
15087
15088fi
15089done
15090
15091
15092for ac_header in maillock.h
15093do
15094as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15095if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15096  { echo "$as_me:$LINENO: checking for $ac_header" >&5
15097echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
15098if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15099  echo $ECHO_N "(cached) $ECHO_C" >&6
15100fi
15101ac_res=`eval echo '${'$as_ac_Header'}'`
15102	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15103echo "${ECHO_T}$ac_res" >&6; }
15104else
15105  # Is the header compilable?
15106{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
15107echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
15108cat >conftest.$ac_ext <<_ACEOF
15109/* confdefs.h.  */
15110_ACEOF
15111cat confdefs.h >>conftest.$ac_ext
15112cat >>conftest.$ac_ext <<_ACEOF
15113/* end confdefs.h.  */
15114$ac_includes_default
15115#include <$ac_header>
15116_ACEOF
15117rm -f conftest.$ac_objext
15118if { (ac_try="$ac_compile"
15119case "(($ac_try" in
15120  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15121  *) ac_try_echo=$ac_try;;
15122esac
15123eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15124  (eval "$ac_compile") 2>conftest.er1
15125  ac_status=$?
15126  grep -v '^ *+' conftest.er1 >conftest.err
15127  rm -f conftest.er1
15128  cat conftest.err >&5
15129  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15130  (exit $ac_status); } && {
15131	 test -z "$ac_c_werror_flag" ||
15132	 test ! -s conftest.err
15133       } && test -s conftest.$ac_objext; then
15134  ac_header_compiler=yes
15135else
15136  echo "$as_me: failed program was:" >&5
15137sed 's/^/| /' conftest.$ac_ext >&5
15138
15139	ac_header_compiler=no
15140fi
15141
15142rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15143{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15144echo "${ECHO_T}$ac_header_compiler" >&6; }
15145
15146# Is the header present?
15147{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
15148echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
15149cat >conftest.$ac_ext <<_ACEOF
15150/* confdefs.h.  */
15151_ACEOF
15152cat confdefs.h >>conftest.$ac_ext
15153cat >>conftest.$ac_ext <<_ACEOF
15154/* end confdefs.h.  */
15155#include <$ac_header>
15156_ACEOF
15157if { (ac_try="$ac_cpp conftest.$ac_ext"
15158case "(($ac_try" in
15159  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15160  *) ac_try_echo=$ac_try;;
15161esac
15162eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15163  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
15164  ac_status=$?
15165  grep -v '^ *+' conftest.er1 >conftest.err
15166  rm -f conftest.er1
15167  cat conftest.err >&5
15168  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15169  (exit $ac_status); } >/dev/null && {
15170	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
15171	 test ! -s conftest.err
15172       }; then
15173  ac_header_preproc=yes
15174else
15175  echo "$as_me: failed program was:" >&5
15176sed 's/^/| /' conftest.$ac_ext >&5
15177
15178  ac_header_preproc=no
15179fi
15180
15181rm -f conftest.err conftest.$ac_ext
15182{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15183echo "${ECHO_T}$ac_header_preproc" >&6; }
15184
15185# So?  What about this header?
15186case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15187  yes:no: )
15188    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15189echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15190    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15191echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15192    ac_header_preproc=yes
15193    ;;
15194  no:yes:* )
15195    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15196echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15197    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15198echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15199    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15200echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15201    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15202echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15203    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15204echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15205    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15206echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15207
15208    ;;
15209esac
15210{ echo "$as_me:$LINENO: checking for $ac_header" >&5
15211echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
15212if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15213  echo $ECHO_N "(cached) $ECHO_C" >&6
15214else
15215  eval "$as_ac_Header=\$ac_header_preproc"
15216fi
15217ac_res=`eval echo '${'$as_ac_Header'}'`
15218	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15219echo "${ECHO_T}$ac_res" >&6; }
15220
15221fi
15222if test `eval echo '${'$as_ac_Header'}'` = yes; then
15223  cat >>confdefs.h <<_ACEOF
15224#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15225_ACEOF
15226
15227fi
15228
15229done
15230
15231
15232
15233
15234
15235
15236
15237
15238
15239
15240
15241
15242
15243
15244
15245
15246
15247
15248
15249
15250
15251
15252
15253
15254
15255
15256
15257
15258
15259
15260
15261
15262
15263
15264
15265
15266
15267
15268
15269
15270
15271
15272
15273
15274
15275
15276
15277
15278
15279
15280
15281
15282
15283
15284
15285
15286
15287
15288
15289
15290
15291
15292
15293
15294
15295
15296
15297
15298
15299
15300
15301for ac_func in gethostname getdomainname dup2 \
15302rename closedir mkdir rmdir sysinfo getrusage get_current_dir_name \
15303random lrand48 bcopy bcmp logb frexp fmod rint cbrt ftime res_init setsid \
15304strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
15305utimes setrlimit setpgid getcwd getwd shutdown getaddrinfo \
15306__fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
15307sendto recvfrom getsockopt setsockopt getsockname getpeername \
15308gai_strerror mkstemp getline getdelim mremap memmove fsync sync bzero \
15309memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign
15310do
15311as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15312{ echo "$as_me:$LINENO: checking for $ac_func" >&5
15313echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
15314if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15315  echo $ECHO_N "(cached) $ECHO_C" >&6
15316else
15317  cat >conftest.$ac_ext <<_ACEOF
15318/* confdefs.h.  */
15319_ACEOF
15320cat confdefs.h >>conftest.$ac_ext
15321cat >>conftest.$ac_ext <<_ACEOF
15322/* end confdefs.h.  */
15323/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15324   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15325#define $ac_func innocuous_$ac_func
15326
15327/* System header to define __stub macros and hopefully few prototypes,
15328    which can conflict with char $ac_func (); below.
15329    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15330    <limits.h> exists even on freestanding compilers.  */
15331
15332#ifdef __STDC__
15333# include <limits.h>
15334#else
15335# include <assert.h>
15336#endif
15337
15338#undef $ac_func
15339
15340/* Override any GCC internal prototype to avoid an error.
15341   Use char because int might match the return type of a GCC
15342   builtin and then its argument prototype would still apply.  */
15343#ifdef __cplusplus
15344extern "C"
15345#endif
15346char $ac_func ();
15347/* The GNU C library defines this for functions which it implements
15348    to always fail with ENOSYS.  Some functions are actually named
15349    something starting with __ and the normal name is an alias.  */
15350#if defined __stub_$ac_func || defined __stub___$ac_func
15351choke me
15352#endif
15353
15354int
15355main ()
15356{
15357return $ac_func ();
15358  ;
15359  return 0;
15360}
15361_ACEOF
15362rm -f conftest.$ac_objext conftest$ac_exeext
15363if { (ac_try="$ac_link"
15364case "(($ac_try" in
15365  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15366  *) ac_try_echo=$ac_try;;
15367esac
15368eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15369  (eval "$ac_link") 2>conftest.er1
15370  ac_status=$?
15371  grep -v '^ *+' conftest.er1 >conftest.err
15372  rm -f conftest.er1
15373  cat conftest.err >&5
15374  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15375  (exit $ac_status); } && {
15376	 test -z "$ac_c_werror_flag" ||
15377	 test ! -s conftest.err
15378       } && test -s conftest$ac_exeext &&
15379       $as_test_x conftest$ac_exeext; then
15380  eval "$as_ac_var=yes"
15381else
15382  echo "$as_me: failed program was:" >&5
15383sed 's/^/| /' conftest.$ac_ext >&5
15384
15385	eval "$as_ac_var=no"
15386fi
15387
15388rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15389      conftest$ac_exeext conftest.$ac_ext
15390fi
15391ac_res=`eval echo '${'$as_ac_var'}'`
15392	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15393echo "${ECHO_T}$ac_res" >&6; }
15394if test `eval echo '${'$as_ac_var'}'` = yes; then
15395  cat >>confdefs.h <<_ACEOF
15396#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15397_ACEOF
15398
15399fi
15400done
15401
15402
15403
15404for ac_header in sys/un.h
15405do
15406as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15407if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15408  { echo "$as_me:$LINENO: checking for $ac_header" >&5
15409echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
15410if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15411  echo $ECHO_N "(cached) $ECHO_C" >&6
15412fi
15413ac_res=`eval echo '${'$as_ac_Header'}'`
15414	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15415echo "${ECHO_T}$ac_res" >&6; }
15416else
15417  # Is the header compilable?
15418{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
15419echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
15420cat >conftest.$ac_ext <<_ACEOF
15421/* confdefs.h.  */
15422_ACEOF
15423cat confdefs.h >>conftest.$ac_ext
15424cat >>conftest.$ac_ext <<_ACEOF
15425/* end confdefs.h.  */
15426$ac_includes_default
15427#include <$ac_header>
15428_ACEOF
15429rm -f conftest.$ac_objext
15430if { (ac_try="$ac_compile"
15431case "(($ac_try" in
15432  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15433  *) ac_try_echo=$ac_try;;
15434esac
15435eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15436  (eval "$ac_compile") 2>conftest.er1
15437  ac_status=$?
15438  grep -v '^ *+' conftest.er1 >conftest.err
15439  rm -f conftest.er1
15440  cat conftest.err >&5
15441  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15442  (exit $ac_status); } && {
15443	 test -z "$ac_c_werror_flag" ||
15444	 test ! -s conftest.err
15445       } && test -s conftest.$ac_objext; then
15446  ac_header_compiler=yes
15447else
15448  echo "$as_me: failed program was:" >&5
15449sed 's/^/| /' conftest.$ac_ext >&5
15450
15451	ac_header_compiler=no
15452fi
15453
15454rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15455{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15456echo "${ECHO_T}$ac_header_compiler" >&6; }
15457
15458# Is the header present?
15459{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
15460echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
15461cat >conftest.$ac_ext <<_ACEOF
15462/* confdefs.h.  */
15463_ACEOF
15464cat confdefs.h >>conftest.$ac_ext
15465cat >>conftest.$ac_ext <<_ACEOF
15466/* end confdefs.h.  */
15467#include <$ac_header>
15468_ACEOF
15469if { (ac_try="$ac_cpp conftest.$ac_ext"
15470case "(($ac_try" in
15471  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15472  *) ac_try_echo=$ac_try;;
15473esac
15474eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15475  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
15476  ac_status=$?
15477  grep -v '^ *+' conftest.er1 >conftest.err
15478  rm -f conftest.er1
15479  cat conftest.err >&5
15480  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15481  (exit $ac_status); } >/dev/null && {
15482	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
15483	 test ! -s conftest.err
15484       }; then
15485  ac_header_preproc=yes
15486else
15487  echo "$as_me: failed program was:" >&5
15488sed 's/^/| /' conftest.$ac_ext >&5
15489
15490  ac_header_preproc=no
15491fi
15492
15493rm -f conftest.err conftest.$ac_ext
15494{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15495echo "${ECHO_T}$ac_header_preproc" >&6; }
15496
15497# So?  What about this header?
15498case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15499  yes:no: )
15500    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15501echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15502    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15503echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15504    ac_header_preproc=yes
15505    ;;
15506  no:yes:* )
15507    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15508echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15509    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15510echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15511    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15512echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15513    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15514echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15515    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15516echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15517    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15518echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15519
15520    ;;
15521esac
15522{ echo "$as_me:$LINENO: checking for $ac_header" >&5
15523echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
15524if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15525  echo $ECHO_N "(cached) $ECHO_C" >&6
15526else
15527  eval "$as_ac_Header=\$ac_header_preproc"
15528fi
15529ac_res=`eval echo '${'$as_ac_Header'}'`
15530	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15531echo "${ECHO_T}$ac_res" >&6; }
15532
15533fi
15534if test `eval echo '${'$as_ac_Header'}'` = yes; then
15535  cat >>confdefs.h <<_ACEOF
15536#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15537_ACEOF
15538
15539fi
15540
15541done
15542
15543
15544
15545
15546
15547
15548for ac_header in $ac_header_list
15549do
15550as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15551if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15552  { echo "$as_me:$LINENO: checking for $ac_header" >&5
15553echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
15554if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15555  echo $ECHO_N "(cached) $ECHO_C" >&6
15556fi
15557ac_res=`eval echo '${'$as_ac_Header'}'`
15558	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15559echo "${ECHO_T}$ac_res" >&6; }
15560else
15561  # Is the header compilable?
15562{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
15563echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
15564cat >conftest.$ac_ext <<_ACEOF
15565/* confdefs.h.  */
15566_ACEOF
15567cat confdefs.h >>conftest.$ac_ext
15568cat >>conftest.$ac_ext <<_ACEOF
15569/* end confdefs.h.  */
15570$ac_includes_default
15571#include <$ac_header>
15572_ACEOF
15573rm -f conftest.$ac_objext
15574if { (ac_try="$ac_compile"
15575case "(($ac_try" in
15576  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15577  *) ac_try_echo=$ac_try;;
15578esac
15579eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15580  (eval "$ac_compile") 2>conftest.er1
15581  ac_status=$?
15582  grep -v '^ *+' conftest.er1 >conftest.err
15583  rm -f conftest.er1
15584  cat conftest.err >&5
15585  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15586  (exit $ac_status); } && {
15587	 test -z "$ac_c_werror_flag" ||
15588	 test ! -s conftest.err
15589       } && test -s conftest.$ac_objext; then
15590  ac_header_compiler=yes
15591else
15592  echo "$as_me: failed program was:" >&5
15593sed 's/^/| /' conftest.$ac_ext >&5
15594
15595	ac_header_compiler=no
15596fi
15597
15598rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15599{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15600echo "${ECHO_T}$ac_header_compiler" >&6; }
15601
15602# Is the header present?
15603{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
15604echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
15605cat >conftest.$ac_ext <<_ACEOF
15606/* confdefs.h.  */
15607_ACEOF
15608cat confdefs.h >>conftest.$ac_ext
15609cat >>conftest.$ac_ext <<_ACEOF
15610/* end confdefs.h.  */
15611#include <$ac_header>
15612_ACEOF
15613if { (ac_try="$ac_cpp conftest.$ac_ext"
15614case "(($ac_try" in
15615  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15616  *) ac_try_echo=$ac_try;;
15617esac
15618eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15619  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
15620  ac_status=$?
15621  grep -v '^ *+' conftest.er1 >conftest.err
15622  rm -f conftest.er1
15623  cat conftest.err >&5
15624  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15625  (exit $ac_status); } >/dev/null && {
15626	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
15627	 test ! -s conftest.err
15628       }; then
15629  ac_header_preproc=yes
15630else
15631  echo "$as_me: failed program was:" >&5
15632sed 's/^/| /' conftest.$ac_ext >&5
15633
15634  ac_header_preproc=no
15635fi
15636
15637rm -f conftest.err conftest.$ac_ext
15638{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15639echo "${ECHO_T}$ac_header_preproc" >&6; }
15640
15641# So?  What about this header?
15642case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15643  yes:no: )
15644    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15645echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15646    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15647echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15648    ac_header_preproc=yes
15649    ;;
15650  no:yes:* )
15651    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15652echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15653    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15654echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15655    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15656echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15657    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15658echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15659    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15660echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15661    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15662echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15663
15664    ;;
15665esac
15666{ echo "$as_me:$LINENO: checking for $ac_header" >&5
15667echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
15668if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15669  echo $ECHO_N "(cached) $ECHO_C" >&6
15670else
15671  eval "$as_ac_Header=\$ac_header_preproc"
15672fi
15673ac_res=`eval echo '${'$as_ac_Header'}'`
15674	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15675echo "${ECHO_T}$ac_res" >&6; }
15676
15677fi
15678if test `eval echo '${'$as_ac_Header'}'` = yes; then
15679  cat >>confdefs.h <<_ACEOF
15680#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15681_ACEOF
15682
15683fi
15684
15685done
15686
15687
15688
15689
15690
15691
15692
15693
15694
15695for ac_func in $ac_func_list
15696do
15697as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15698{ echo "$as_me:$LINENO: checking for $ac_func" >&5
15699echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
15700if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15701  echo $ECHO_N "(cached) $ECHO_C" >&6
15702else
15703  cat >conftest.$ac_ext <<_ACEOF
15704/* confdefs.h.  */
15705_ACEOF
15706cat confdefs.h >>conftest.$ac_ext
15707cat >>conftest.$ac_ext <<_ACEOF
15708/* end confdefs.h.  */
15709/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15710   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15711#define $ac_func innocuous_$ac_func
15712
15713/* System header to define __stub macros and hopefully few prototypes,
15714    which can conflict with char $ac_func (); below.
15715    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15716    <limits.h> exists even on freestanding compilers.  */
15717
15718#ifdef __STDC__
15719# include <limits.h>
15720#else
15721# include <assert.h>
15722#endif
15723
15724#undef $ac_func
15725
15726/* Override any GCC internal prototype to avoid an error.
15727   Use char because int might match the return type of a GCC
15728   builtin and then its argument prototype would still apply.  */
15729#ifdef __cplusplus
15730extern "C"
15731#endif
15732char $ac_func ();
15733/* The GNU C library defines this for functions which it implements
15734    to always fail with ENOSYS.  Some functions are actually named
15735    something starting with __ and the normal name is an alias.  */
15736#if defined __stub_$ac_func || defined __stub___$ac_func
15737choke me
15738#endif
15739
15740int
15741main ()
15742{
15743return $ac_func ();
15744  ;
15745  return 0;
15746}
15747_ACEOF
15748rm -f conftest.$ac_objext conftest$ac_exeext
15749if { (ac_try="$ac_link"
15750case "(($ac_try" in
15751  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15752  *) ac_try_echo=$ac_try;;
15753esac
15754eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15755  (eval "$ac_link") 2>conftest.er1
15756  ac_status=$?
15757  grep -v '^ *+' conftest.er1 >conftest.err
15758  rm -f conftest.er1
15759  cat conftest.err >&5
15760  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15761  (exit $ac_status); } && {
15762	 test -z "$ac_c_werror_flag" ||
15763	 test ! -s conftest.err
15764       } && test -s conftest$ac_exeext &&
15765       $as_test_x conftest$ac_exeext; then
15766  eval "$as_ac_var=yes"
15767else
15768  echo "$as_me: failed program was:" >&5
15769sed 's/^/| /' conftest.$ac_ext >&5
15770
15771	eval "$as_ac_var=no"
15772fi
15773
15774rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15775      conftest$ac_exeext conftest.$ac_ext
15776fi
15777ac_res=`eval echo '${'$as_ac_var'}'`
15778	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15779echo "${ECHO_T}$ac_res" >&6; }
15780if test `eval echo '${'$as_ac_var'}'` = yes; then
15781  cat >>confdefs.h <<_ACEOF
15782#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15783_ACEOF
15784
15785fi
15786done
15787
15788
15789
15790
15791
15792
15793
15794
15795
15796
15797
15798
15799
15800
15801
15802
15803
15804{ echo "$as_me:$LINENO: checking for working mktime" >&5
15805echo $ECHO_N "checking for working mktime... $ECHO_C" >&6; }
15806if test "${ac_cv_func_working_mktime+set}" = set; then
15807  echo $ECHO_N "(cached) $ECHO_C" >&6
15808else
15809  if test "$cross_compiling" = yes; then
15810  ac_cv_func_working_mktime=no
15811else
15812  cat >conftest.$ac_ext <<_ACEOF
15813/* confdefs.h.  */
15814_ACEOF
15815cat confdefs.h >>conftest.$ac_ext
15816cat >>conftest.$ac_ext <<_ACEOF
15817/* end confdefs.h.  */
15818/* Test program from Paul Eggert and Tony Leneis.  */
15819#ifdef TIME_WITH_SYS_TIME
15820# include <sys/time.h>
15821# include <time.h>
15822#else
15823# ifdef HAVE_SYS_TIME_H
15824#  include <sys/time.h>
15825# else
15826#  include <time.h>
15827# endif
15828#endif
15829
15830#include <stdlib.h>
15831
15832#ifdef HAVE_UNISTD_H
15833# include <unistd.h>
15834#endif
15835
15836#ifndef HAVE_ALARM
15837# define alarm(X) /* empty */
15838#endif
15839
15840/* Work around redefinition to rpl_putenv by other config tests.  */
15841#undef putenv
15842
15843static time_t time_t_max;
15844static time_t time_t_min;
15845
15846/* Values we'll use to set the TZ environment variable.  */
15847static char *tz_strings[] = {
15848  (char *) 0, "TZ=GMT0", "TZ=JST-9",
15849  "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
15850};
15851#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
15852
15853/* Return 0 if mktime fails to convert a date in the spring-forward gap.
15854   Based on a problem report from Andreas Jaeger.  */
15855static int
15856spring_forward_gap ()
15857{
15858  /* glibc (up to about 1998-10-07) failed this test. */
15859  struct tm tm;
15860
15861  /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
15862     instead of "TZ=America/Vancouver" in order to detect the bug even
15863     on systems that don't support the Olson extension, or don't have the
15864     full zoneinfo tables installed.  */
15865  putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
15866
15867  tm.tm_year = 98;
15868  tm.tm_mon = 3;
15869  tm.tm_mday = 5;
15870  tm.tm_hour = 2;
15871  tm.tm_min = 0;
15872  tm.tm_sec = 0;
15873  tm.tm_isdst = -1;
15874  return mktime (&tm) != (time_t) -1;
15875}
15876
15877static int
15878mktime_test1 (now)
15879     time_t now;
15880{
15881  struct tm *lt;
15882  return ! (lt = localtime (&now)) || mktime (lt) == now;
15883}
15884
15885static int
15886mktime_test (now)
15887     time_t now;
15888{
15889  return (mktime_test1 (now)
15890	  && mktime_test1 ((time_t) (time_t_max - now))
15891	  && mktime_test1 ((time_t) (time_t_min + now)));
15892}
15893
15894static int
15895irix_6_4_bug ()
15896{
15897  /* Based on code from Ariel Faigon.  */
15898  struct tm tm;
15899  tm.tm_year = 96;
15900  tm.tm_mon = 3;
15901  tm.tm_mday = 0;
15902  tm.tm_hour = 0;
15903  tm.tm_min = 0;
15904  tm.tm_sec = 0;
15905  tm.tm_isdst = -1;
15906  mktime (&tm);
15907  return tm.tm_mon == 2 && tm.tm_mday == 31;
15908}
15909
15910static int
15911bigtime_test (j)
15912     int j;
15913{
15914  struct tm tm;
15915  time_t now;
15916  tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
15917  now = mktime (&tm);
15918  if (now != (time_t) -1)
15919    {
15920      struct tm *lt = localtime (&now);
15921      if (! (lt
15922	     && lt->tm_year == tm.tm_year
15923	     && lt->tm_mon == tm.tm_mon
15924	     && lt->tm_mday == tm.tm_mday
15925	     && lt->tm_hour == tm.tm_hour
15926	     && lt->tm_min == tm.tm_min
15927	     && lt->tm_sec == tm.tm_sec
15928	     && lt->tm_yday == tm.tm_yday
15929	     && lt->tm_wday == tm.tm_wday
15930	     && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
15931		  == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
15932	return 0;
15933    }
15934  return 1;
15935}
15936
15937static int
15938year_2050_test ()
15939{
15940  /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
15941     ignoring leap seconds.  */
15942  unsigned long int answer = 2527315200UL;
15943
15944  struct tm tm;
15945  time_t t;
15946  tm.tm_year = 2050 - 1900;
15947  tm.tm_mon = 2 - 1;
15948  tm.tm_mday = 1;
15949  tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
15950  tm.tm_isdst = -1;
15951
15952  /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
15953     instead of "TZ=America/Vancouver" in order to detect the bug even
15954     on systems that don't support the Olson extension, or don't have the
15955     full zoneinfo tables installed.  */
15956  putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
15957
15958  t = mktime (&tm);
15959
15960  /* Check that the result is either a failure, or close enough
15961     to the correct answer that we can assume the discrepancy is
15962     due to leap seconds.  */
15963  return (t == (time_t) -1
15964	  || (0 < t && answer - 120 <= t && t <= answer + 120));
15965}
15966
15967int
15968main ()
15969{
15970  time_t t, delta;
15971  int i, j;
15972
15973  /* This test makes some buggy mktime implementations loop.
15974     Give up after 60 seconds; a mktime slower than that
15975     isn't worth using anyway.  */
15976  alarm (60);
15977
15978  for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
15979    continue;
15980  time_t_max--;
15981  if ((time_t) -1 < 0)
15982    for (time_t_min = -1; (time_t) (time_t_min * 2) < 0; time_t_min *= 2)
15983      continue;
15984  delta = time_t_max / 997; /* a suitable prime number */
15985  for (i = 0; i < N_STRINGS; i++)
15986    {
15987      if (tz_strings[i])
15988	putenv (tz_strings[i]);
15989
15990      for (t = 0; t <= time_t_max - delta; t += delta)
15991	if (! mktime_test (t))
15992	  return 1;
15993      if (! (mktime_test ((time_t) 1)
15994	     && mktime_test ((time_t) (60 * 60))
15995	     && mktime_test ((time_t) (60 * 60 * 24))))
15996	return 1;
15997
15998      for (j = 1; 0 < j; j *= 2)
15999	if (! bigtime_test (j))
16000	  return 1;
16001      if (! bigtime_test (j - 1))
16002	return 1;
16003    }
16004  return ! (irix_6_4_bug () && spring_forward_gap () && year_2050_test ());
16005}
16006_ACEOF
16007rm -f conftest$ac_exeext
16008if { (ac_try="$ac_link"
16009case "(($ac_try" in
16010  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16011  *) ac_try_echo=$ac_try;;
16012esac
16013eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16014  (eval "$ac_link") 2>&5
16015  ac_status=$?
16016  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16017  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16018  { (case "(($ac_try" in
16019  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16020  *) ac_try_echo=$ac_try;;
16021esac
16022eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16023  (eval "$ac_try") 2>&5
16024  ac_status=$?
16025  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16026  (exit $ac_status); }; }; then
16027  ac_cv_func_working_mktime=yes
16028else
16029  echo "$as_me: program exited with status $ac_status" >&5
16030echo "$as_me: failed program was:" >&5
16031sed 's/^/| /' conftest.$ac_ext >&5
16032
16033( exit $ac_status )
16034ac_cv_func_working_mktime=no
16035fi
16036rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16037fi
16038
16039
16040fi
16041{ echo "$as_me:$LINENO: result: $ac_cv_func_working_mktime" >&5
16042echo "${ECHO_T}$ac_cv_func_working_mktime" >&6; }
16043if test $ac_cv_func_working_mktime = no; then
16044  case " $LIBOBJS " in
16045  *" mktime.$ac_objext "* ) ;;
16046  *) LIBOBJS="$LIBOBJS mktime.$ac_objext"
16047 ;;
16048esac
16049
16050fi
16051
16052if test "$ac_cv_func_working_mktime" = no; then
16053
16054cat >>confdefs.h <<\_ACEOF
16055#define BROKEN_MKTIME 1
16056_ACEOF
16057
16058fi
16059
16060ac_have_func=no # yes means we've found a way to get the load average.
16061
16062# Make sure getloadavg.c is where it belongs, at configure-time.
16063test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
16064  { { echo "$as_me:$LINENO: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&5
16065echo "$as_me: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&2;}
16066   { (exit 1); exit 1; }; }
16067
16068ac_save_LIBS=$LIBS
16069
16070# Check for getloadavg, but be sure not to touch the cache variable.
16071({ echo "$as_me:$LINENO: checking for getloadavg" >&5
16072echo $ECHO_N "checking for getloadavg... $ECHO_C" >&6; }
16073if test "${ac_cv_func_getloadavg+set}" = set; then
16074  echo $ECHO_N "(cached) $ECHO_C" >&6
16075else
16076  cat >conftest.$ac_ext <<_ACEOF
16077/* confdefs.h.  */
16078_ACEOF
16079cat confdefs.h >>conftest.$ac_ext
16080cat >>conftest.$ac_ext <<_ACEOF
16081/* end confdefs.h.  */
16082/* Define getloadavg to an innocuous variant, in case <limits.h> declares getloadavg.
16083   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16084#define getloadavg innocuous_getloadavg
16085
16086/* System header to define __stub macros and hopefully few prototypes,
16087    which can conflict with char getloadavg (); below.
16088    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16089    <limits.h> exists even on freestanding compilers.  */
16090
16091#ifdef __STDC__
16092# include <limits.h>
16093#else
16094# include <assert.h>
16095#endif
16096
16097#undef getloadavg
16098
16099/* Override any GCC internal prototype to avoid an error.
16100   Use char because int might match the return type of a GCC
16101   builtin and then its argument prototype would still apply.  */
16102#ifdef __cplusplus
16103extern "C"
16104#endif
16105char getloadavg ();
16106/* The GNU C library defines this for functions which it implements
16107    to always fail with ENOSYS.  Some functions are actually named
16108    something starting with __ and the normal name is an alias.  */
16109#if defined __stub_getloadavg || defined __stub___getloadavg
16110choke me
16111#endif
16112
16113int
16114main ()
16115{
16116return getloadavg ();
16117  ;
16118  return 0;
16119}
16120_ACEOF
16121rm -f conftest.$ac_objext conftest$ac_exeext
16122if { (ac_try="$ac_link"
16123case "(($ac_try" in
16124  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16125  *) ac_try_echo=$ac_try;;
16126esac
16127eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16128  (eval "$ac_link") 2>conftest.er1
16129  ac_status=$?
16130  grep -v '^ *+' conftest.er1 >conftest.err
16131  rm -f conftest.er1
16132  cat conftest.err >&5
16133  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16134  (exit $ac_status); } && {
16135	 test -z "$ac_c_werror_flag" ||
16136	 test ! -s conftest.err
16137       } && test -s conftest$ac_exeext &&
16138       $as_test_x conftest$ac_exeext; then
16139  ac_cv_func_getloadavg=yes
16140else
16141  echo "$as_me: failed program was:" >&5
16142sed 's/^/| /' conftest.$ac_ext >&5
16143
16144	ac_cv_func_getloadavg=no
16145fi
16146
16147rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16148      conftest$ac_exeext conftest.$ac_ext
16149fi
16150{ echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg" >&5
16151echo "${ECHO_T}$ac_cv_func_getloadavg" >&6; }
16152if test $ac_cv_func_getloadavg = yes; then
16153  exit 0
16154else
16155  exit 1
16156fi
16157) && ac_have_func=yes
16158
16159# On HPUX9, an unprivileged user can get load averages through this function.
16160
16161for ac_func in pstat_getdynamic
16162do
16163as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16164{ echo "$as_me:$LINENO: checking for $ac_func" >&5
16165echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16166if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16167  echo $ECHO_N "(cached) $ECHO_C" >&6
16168else
16169  cat >conftest.$ac_ext <<_ACEOF
16170/* confdefs.h.  */
16171_ACEOF
16172cat confdefs.h >>conftest.$ac_ext
16173cat >>conftest.$ac_ext <<_ACEOF
16174/* end confdefs.h.  */
16175/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16176   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16177#define $ac_func innocuous_$ac_func
16178
16179/* System header to define __stub macros and hopefully few prototypes,
16180    which can conflict with char $ac_func (); below.
16181    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16182    <limits.h> exists even on freestanding compilers.  */
16183
16184#ifdef __STDC__
16185# include <limits.h>
16186#else
16187# include <assert.h>
16188#endif
16189
16190#undef $ac_func
16191
16192/* Override any GCC internal prototype to avoid an error.
16193   Use char because int might match the return type of a GCC
16194   builtin and then its argument prototype would still apply.  */
16195#ifdef __cplusplus
16196extern "C"
16197#endif
16198char $ac_func ();
16199/* The GNU C library defines this for functions which it implements
16200    to always fail with ENOSYS.  Some functions are actually named
16201    something starting with __ and the normal name is an alias.  */
16202#if defined __stub_$ac_func || defined __stub___$ac_func
16203choke me
16204#endif
16205
16206int
16207main ()
16208{
16209return $ac_func ();
16210  ;
16211  return 0;
16212}
16213_ACEOF
16214rm -f conftest.$ac_objext conftest$ac_exeext
16215if { (ac_try="$ac_link"
16216case "(($ac_try" in
16217  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16218  *) ac_try_echo=$ac_try;;
16219esac
16220eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16221  (eval "$ac_link") 2>conftest.er1
16222  ac_status=$?
16223  grep -v '^ *+' conftest.er1 >conftest.err
16224  rm -f conftest.er1
16225  cat conftest.err >&5
16226  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16227  (exit $ac_status); } && {
16228	 test -z "$ac_c_werror_flag" ||
16229	 test ! -s conftest.err
16230       } && test -s conftest$ac_exeext &&
16231       $as_test_x conftest$ac_exeext; then
16232  eval "$as_ac_var=yes"
16233else
16234  echo "$as_me: failed program was:" >&5
16235sed 's/^/| /' conftest.$ac_ext >&5
16236
16237	eval "$as_ac_var=no"
16238fi
16239
16240rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16241      conftest$ac_exeext conftest.$ac_ext
16242fi
16243ac_res=`eval echo '${'$as_ac_var'}'`
16244	       { echo "$as_me:$LINENO: result: $ac_res" >&5
16245echo "${ECHO_T}$ac_res" >&6; }
16246if test `eval echo '${'$as_ac_var'}'` = yes; then
16247  cat >>confdefs.h <<_ACEOF
16248#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16249_ACEOF
16250
16251fi
16252done
16253
16254
16255# Solaris has libkstat which does not require root.
16256
16257{ echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
16258echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6; }
16259if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
16260  echo $ECHO_N "(cached) $ECHO_C" >&6
16261else
16262  ac_check_lib_save_LIBS=$LIBS
16263LIBS="-lkstat  $LIBS"
16264cat >conftest.$ac_ext <<_ACEOF
16265/* confdefs.h.  */
16266_ACEOF
16267cat confdefs.h >>conftest.$ac_ext
16268cat >>conftest.$ac_ext <<_ACEOF
16269/* end confdefs.h.  */
16270
16271/* Override any GCC internal prototype to avoid an error.
16272   Use char because int might match the return type of a GCC
16273   builtin and then its argument prototype would still apply.  */
16274#ifdef __cplusplus
16275extern "C"
16276#endif
16277char kstat_open ();
16278int
16279main ()
16280{
16281return kstat_open ();
16282  ;
16283  return 0;
16284}
16285_ACEOF
16286rm -f conftest.$ac_objext conftest$ac_exeext
16287if { (ac_try="$ac_link"
16288case "(($ac_try" in
16289  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16290  *) ac_try_echo=$ac_try;;
16291esac
16292eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16293  (eval "$ac_link") 2>conftest.er1
16294  ac_status=$?
16295  grep -v '^ *+' conftest.er1 >conftest.err
16296  rm -f conftest.er1
16297  cat conftest.err >&5
16298  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16299  (exit $ac_status); } && {
16300	 test -z "$ac_c_werror_flag" ||
16301	 test ! -s conftest.err
16302       } && test -s conftest$ac_exeext &&
16303       $as_test_x conftest$ac_exeext; then
16304  ac_cv_lib_kstat_kstat_open=yes
16305else
16306  echo "$as_me: failed program was:" >&5
16307sed 's/^/| /' conftest.$ac_ext >&5
16308
16309	ac_cv_lib_kstat_kstat_open=no
16310fi
16311
16312rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16313      conftest$ac_exeext conftest.$ac_ext
16314LIBS=$ac_check_lib_save_LIBS
16315fi
16316{ echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
16317echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6; }
16318if test $ac_cv_lib_kstat_kstat_open = yes; then
16319  cat >>confdefs.h <<_ACEOF
16320#define HAVE_LIBKSTAT 1
16321_ACEOF
16322
16323  LIBS="-lkstat $LIBS"
16324
16325fi
16326
16327test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
16328
16329# Some systems with -lutil have (and need) -lkvm as well, some do not.
16330# On Solaris, -lkvm requires nlist from -lelf, so check that first
16331# to get the right answer into the cache.
16332# For kstat on solaris, we need libelf to force the definition of SVR4 below.
16333if test $ac_have_func = no; then
16334  { echo "$as_me:$LINENO: checking for elf_begin in -lelf" >&5
16335echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6; }
16336if test "${ac_cv_lib_elf_elf_begin+set}" = set; then
16337  echo $ECHO_N "(cached) $ECHO_C" >&6
16338else
16339  ac_check_lib_save_LIBS=$LIBS
16340LIBS="-lelf  $LIBS"
16341cat >conftest.$ac_ext <<_ACEOF
16342/* confdefs.h.  */
16343_ACEOF
16344cat confdefs.h >>conftest.$ac_ext
16345cat >>conftest.$ac_ext <<_ACEOF
16346/* end confdefs.h.  */
16347
16348/* Override any GCC internal prototype to avoid an error.
16349   Use char because int might match the return type of a GCC
16350   builtin and then its argument prototype would still apply.  */
16351#ifdef __cplusplus
16352extern "C"
16353#endif
16354char elf_begin ();
16355int
16356main ()
16357{
16358return elf_begin ();
16359  ;
16360  return 0;
16361}
16362_ACEOF
16363rm -f conftest.$ac_objext conftest$ac_exeext
16364if { (ac_try="$ac_link"
16365case "(($ac_try" in
16366  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16367  *) ac_try_echo=$ac_try;;
16368esac
16369eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16370  (eval "$ac_link") 2>conftest.er1
16371  ac_status=$?
16372  grep -v '^ *+' conftest.er1 >conftest.err
16373  rm -f conftest.er1
16374  cat conftest.err >&5
16375  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16376  (exit $ac_status); } && {
16377	 test -z "$ac_c_werror_flag" ||
16378	 test ! -s conftest.err
16379       } && test -s conftest$ac_exeext &&
16380       $as_test_x conftest$ac_exeext; then
16381  ac_cv_lib_elf_elf_begin=yes
16382else
16383  echo "$as_me: failed program was:" >&5
16384sed 's/^/| /' conftest.$ac_ext >&5
16385
16386	ac_cv_lib_elf_elf_begin=no
16387fi
16388
16389rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16390      conftest$ac_exeext conftest.$ac_ext
16391LIBS=$ac_check_lib_save_LIBS
16392fi
16393{ echo "$as_me:$LINENO: result: $ac_cv_lib_elf_elf_begin" >&5
16394echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6; }
16395if test $ac_cv_lib_elf_elf_begin = yes; then
16396  LIBS="-lelf $LIBS"
16397fi
16398
16399fi
16400if test $ac_have_func = no; then
16401  { echo "$as_me:$LINENO: checking for kvm_open in -lkvm" >&5
16402echo $ECHO_N "checking for kvm_open in -lkvm... $ECHO_C" >&6; }
16403if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then
16404  echo $ECHO_N "(cached) $ECHO_C" >&6
16405else
16406  ac_check_lib_save_LIBS=$LIBS
16407LIBS="-lkvm  $LIBS"
16408cat >conftest.$ac_ext <<_ACEOF
16409/* confdefs.h.  */
16410_ACEOF
16411cat confdefs.h >>conftest.$ac_ext
16412cat >>conftest.$ac_ext <<_ACEOF
16413/* end confdefs.h.  */
16414
16415/* Override any GCC internal prototype to avoid an error.
16416   Use char because int might match the return type of a GCC
16417   builtin and then its argument prototype would still apply.  */
16418#ifdef __cplusplus
16419extern "C"
16420#endif
16421char kvm_open ();
16422int
16423main ()
16424{
16425return kvm_open ();
16426  ;
16427  return 0;
16428}
16429_ACEOF
16430rm -f conftest.$ac_objext conftest$ac_exeext
16431if { (ac_try="$ac_link"
16432case "(($ac_try" in
16433  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16434  *) ac_try_echo=$ac_try;;
16435esac
16436eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16437  (eval "$ac_link") 2>conftest.er1
16438  ac_status=$?
16439  grep -v '^ *+' conftest.er1 >conftest.err
16440  rm -f conftest.er1
16441  cat conftest.err >&5
16442  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16443  (exit $ac_status); } && {
16444	 test -z "$ac_c_werror_flag" ||
16445	 test ! -s conftest.err
16446       } && test -s conftest$ac_exeext &&
16447       $as_test_x conftest$ac_exeext; then
16448  ac_cv_lib_kvm_kvm_open=yes
16449else
16450  echo "$as_me: failed program was:" >&5
16451sed 's/^/| /' conftest.$ac_ext >&5
16452
16453	ac_cv_lib_kvm_kvm_open=no
16454fi
16455
16456rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16457      conftest$ac_exeext conftest.$ac_ext
16458LIBS=$ac_check_lib_save_LIBS
16459fi
16460{ echo "$as_me:$LINENO: result: $ac_cv_lib_kvm_kvm_open" >&5
16461echo "${ECHO_T}$ac_cv_lib_kvm_kvm_open" >&6; }
16462if test $ac_cv_lib_kvm_kvm_open = yes; then
16463  LIBS="-lkvm $LIBS"
16464fi
16465
16466  # Check for the 4.4BSD definition of getloadavg.
16467  { echo "$as_me:$LINENO: checking for getloadavg in -lutil" >&5
16468echo $ECHO_N "checking for getloadavg in -lutil... $ECHO_C" >&6; }
16469if test "${ac_cv_lib_util_getloadavg+set}" = set; then
16470  echo $ECHO_N "(cached) $ECHO_C" >&6
16471else
16472  ac_check_lib_save_LIBS=$LIBS
16473LIBS="-lutil  $LIBS"
16474cat >conftest.$ac_ext <<_ACEOF
16475/* confdefs.h.  */
16476_ACEOF
16477cat confdefs.h >>conftest.$ac_ext
16478cat >>conftest.$ac_ext <<_ACEOF
16479/* end confdefs.h.  */
16480
16481/* Override any GCC internal prototype to avoid an error.
16482   Use char because int might match the return type of a GCC
16483   builtin and then its argument prototype would still apply.  */
16484#ifdef __cplusplus
16485extern "C"
16486#endif
16487char getloadavg ();
16488int
16489main ()
16490{
16491return getloadavg ();
16492  ;
16493  return 0;
16494}
16495_ACEOF
16496rm -f conftest.$ac_objext conftest$ac_exeext
16497if { (ac_try="$ac_link"
16498case "(($ac_try" in
16499  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16500  *) ac_try_echo=$ac_try;;
16501esac
16502eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16503  (eval "$ac_link") 2>conftest.er1
16504  ac_status=$?
16505  grep -v '^ *+' conftest.er1 >conftest.err
16506  rm -f conftest.er1
16507  cat conftest.err >&5
16508  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16509  (exit $ac_status); } && {
16510	 test -z "$ac_c_werror_flag" ||
16511	 test ! -s conftest.err
16512       } && test -s conftest$ac_exeext &&
16513       $as_test_x conftest$ac_exeext; then
16514  ac_cv_lib_util_getloadavg=yes
16515else
16516  echo "$as_me: failed program was:" >&5
16517sed 's/^/| /' conftest.$ac_ext >&5
16518
16519	ac_cv_lib_util_getloadavg=no
16520fi
16521
16522rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16523      conftest$ac_exeext conftest.$ac_ext
16524LIBS=$ac_check_lib_save_LIBS
16525fi
16526{ echo "$as_me:$LINENO: result: $ac_cv_lib_util_getloadavg" >&5
16527echo "${ECHO_T}$ac_cv_lib_util_getloadavg" >&6; }
16528if test $ac_cv_lib_util_getloadavg = yes; then
16529  LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
16530fi
16531
16532fi
16533
16534if test $ac_have_func = no; then
16535  # There is a commonly available library for RS/6000 AIX.
16536  # Since it is not a standard part of AIX, it might be installed locally.
16537  ac_getloadavg_LIBS=$LIBS
16538  LIBS="-L/usr/local/lib $LIBS"
16539  { echo "$as_me:$LINENO: checking for getloadavg in -lgetloadavg" >&5
16540echo $ECHO_N "checking for getloadavg in -lgetloadavg... $ECHO_C" >&6; }
16541if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then
16542  echo $ECHO_N "(cached) $ECHO_C" >&6
16543else
16544  ac_check_lib_save_LIBS=$LIBS
16545LIBS="-lgetloadavg  $LIBS"
16546cat >conftest.$ac_ext <<_ACEOF
16547/* confdefs.h.  */
16548_ACEOF
16549cat confdefs.h >>conftest.$ac_ext
16550cat >>conftest.$ac_ext <<_ACEOF
16551/* end confdefs.h.  */
16552
16553/* Override any GCC internal prototype to avoid an error.
16554   Use char because int might match the return type of a GCC
16555   builtin and then its argument prototype would still apply.  */
16556#ifdef __cplusplus
16557extern "C"
16558#endif
16559char getloadavg ();
16560int
16561main ()
16562{
16563return getloadavg ();
16564  ;
16565  return 0;
16566}
16567_ACEOF
16568rm -f conftest.$ac_objext conftest$ac_exeext
16569if { (ac_try="$ac_link"
16570case "(($ac_try" in
16571  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16572  *) ac_try_echo=$ac_try;;
16573esac
16574eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16575  (eval "$ac_link") 2>conftest.er1
16576  ac_status=$?
16577  grep -v '^ *+' conftest.er1 >conftest.err
16578  rm -f conftest.er1
16579  cat conftest.err >&5
16580  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16581  (exit $ac_status); } && {
16582	 test -z "$ac_c_werror_flag" ||
16583	 test ! -s conftest.err
16584       } && test -s conftest$ac_exeext &&
16585       $as_test_x conftest$ac_exeext; then
16586  ac_cv_lib_getloadavg_getloadavg=yes
16587else
16588  echo "$as_me: failed program was:" >&5
16589sed 's/^/| /' conftest.$ac_ext >&5
16590
16591	ac_cv_lib_getloadavg_getloadavg=no
16592fi
16593
16594rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16595      conftest$ac_exeext conftest.$ac_ext
16596LIBS=$ac_check_lib_save_LIBS
16597fi
16598{ echo "$as_me:$LINENO: result: $ac_cv_lib_getloadavg_getloadavg" >&5
16599echo "${ECHO_T}$ac_cv_lib_getloadavg_getloadavg" >&6; }
16600if test $ac_cv_lib_getloadavg_getloadavg = yes; then
16601  LIBS="-lgetloadavg $LIBS"
16602else
16603  LIBS=$ac_getloadavg_LIBS
16604fi
16605
16606fi
16607
16608# Make sure it is really in the library, if we think we found it,
16609# otherwise set up the replacement function.
16610
16611for ac_func in getloadavg
16612do
16613as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16614{ echo "$as_me:$LINENO: checking for $ac_func" >&5
16615echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16616if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16617  echo $ECHO_N "(cached) $ECHO_C" >&6
16618else
16619  cat >conftest.$ac_ext <<_ACEOF
16620/* confdefs.h.  */
16621_ACEOF
16622cat confdefs.h >>conftest.$ac_ext
16623cat >>conftest.$ac_ext <<_ACEOF
16624/* end confdefs.h.  */
16625/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16626   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16627#define $ac_func innocuous_$ac_func
16628
16629/* System header to define __stub macros and hopefully few prototypes,
16630    which can conflict with char $ac_func (); below.
16631    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16632    <limits.h> exists even on freestanding compilers.  */
16633
16634#ifdef __STDC__
16635# include <limits.h>
16636#else
16637# include <assert.h>
16638#endif
16639
16640#undef $ac_func
16641
16642/* Override any GCC internal prototype to avoid an error.
16643   Use char because int might match the return type of a GCC
16644   builtin and then its argument prototype would still apply.  */
16645#ifdef __cplusplus
16646extern "C"
16647#endif
16648char $ac_func ();
16649/* The GNU C library defines this for functions which it implements
16650    to always fail with ENOSYS.  Some functions are actually named
16651    something starting with __ and the normal name is an alias.  */
16652#if defined __stub_$ac_func || defined __stub___$ac_func
16653choke me
16654#endif
16655
16656int
16657main ()
16658{
16659return $ac_func ();
16660  ;
16661  return 0;
16662}
16663_ACEOF
16664rm -f conftest.$ac_objext conftest$ac_exeext
16665if { (ac_try="$ac_link"
16666case "(($ac_try" in
16667  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16668  *) ac_try_echo=$ac_try;;
16669esac
16670eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16671  (eval "$ac_link") 2>conftest.er1
16672  ac_status=$?
16673  grep -v '^ *+' conftest.er1 >conftest.err
16674  rm -f conftest.er1
16675  cat conftest.err >&5
16676  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16677  (exit $ac_status); } && {
16678	 test -z "$ac_c_werror_flag" ||
16679	 test ! -s conftest.err
16680       } && test -s conftest$ac_exeext &&
16681       $as_test_x conftest$ac_exeext; then
16682  eval "$as_ac_var=yes"
16683else
16684  echo "$as_me: failed program was:" >&5
16685sed 's/^/| /' conftest.$ac_ext >&5
16686
16687	eval "$as_ac_var=no"
16688fi
16689
16690rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16691      conftest$ac_exeext conftest.$ac_ext
16692fi
16693ac_res=`eval echo '${'$as_ac_var'}'`
16694	       { echo "$as_me:$LINENO: result: $ac_res" >&5
16695echo "${ECHO_T}$ac_res" >&6; }
16696if test `eval echo '${'$as_ac_var'}'` = yes; then
16697  cat >>confdefs.h <<_ACEOF
16698#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16699_ACEOF
16700
16701else
16702  case " $LIBOBJS " in
16703  *" getloadavg.$ac_objext "* ) ;;
16704  *) LIBOBJS="$LIBOBJS getloadavg.$ac_objext"
16705 ;;
16706esac
16707
16708
16709cat >>confdefs.h <<\_ACEOF
16710#define C_GETLOADAVG 1
16711_ACEOF
16712
16713# Figure out what our getloadavg.c needs.
16714ac_have_func=no
16715if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
16716  { echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
16717echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6; }
16718if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
16719  echo $ECHO_N "(cached) $ECHO_C" >&6
16720fi
16721{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
16722echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6; }
16723else
16724  # Is the header compilable?
16725{ echo "$as_me:$LINENO: checking sys/dg_sys_info.h usability" >&5
16726echo $ECHO_N "checking sys/dg_sys_info.h usability... $ECHO_C" >&6; }
16727cat >conftest.$ac_ext <<_ACEOF
16728/* confdefs.h.  */
16729_ACEOF
16730cat confdefs.h >>conftest.$ac_ext
16731cat >>conftest.$ac_ext <<_ACEOF
16732/* end confdefs.h.  */
16733$ac_includes_default
16734#include <sys/dg_sys_info.h>
16735_ACEOF
16736rm -f conftest.$ac_objext
16737if { (ac_try="$ac_compile"
16738case "(($ac_try" in
16739  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16740  *) ac_try_echo=$ac_try;;
16741esac
16742eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16743  (eval "$ac_compile") 2>conftest.er1
16744  ac_status=$?
16745  grep -v '^ *+' conftest.er1 >conftest.err
16746  rm -f conftest.er1
16747  cat conftest.err >&5
16748  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16749  (exit $ac_status); } && {
16750	 test -z "$ac_c_werror_flag" ||
16751	 test ! -s conftest.err
16752       } && test -s conftest.$ac_objext; then
16753  ac_header_compiler=yes
16754else
16755  echo "$as_me: failed program was:" >&5
16756sed 's/^/| /' conftest.$ac_ext >&5
16757
16758	ac_header_compiler=no
16759fi
16760
16761rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16762{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16763echo "${ECHO_T}$ac_header_compiler" >&6; }
16764
16765# Is the header present?
16766{ echo "$as_me:$LINENO: checking sys/dg_sys_info.h presence" >&5
16767echo $ECHO_N "checking sys/dg_sys_info.h presence... $ECHO_C" >&6; }
16768cat >conftest.$ac_ext <<_ACEOF
16769/* confdefs.h.  */
16770_ACEOF
16771cat confdefs.h >>conftest.$ac_ext
16772cat >>conftest.$ac_ext <<_ACEOF
16773/* end confdefs.h.  */
16774#include <sys/dg_sys_info.h>
16775_ACEOF
16776if { (ac_try="$ac_cpp conftest.$ac_ext"
16777case "(($ac_try" in
16778  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16779  *) ac_try_echo=$ac_try;;
16780esac
16781eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16782  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
16783  ac_status=$?
16784  grep -v '^ *+' conftest.er1 >conftest.err
16785  rm -f conftest.er1
16786  cat conftest.err >&5
16787  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16788  (exit $ac_status); } >/dev/null && {
16789	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
16790	 test ! -s conftest.err
16791       }; then
16792  ac_header_preproc=yes
16793else
16794  echo "$as_me: failed program was:" >&5
16795sed 's/^/| /' conftest.$ac_ext >&5
16796
16797  ac_header_preproc=no
16798fi
16799
16800rm -f conftest.err conftest.$ac_ext
16801{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16802echo "${ECHO_T}$ac_header_preproc" >&6; }
16803
16804# So?  What about this header?
16805case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16806  yes:no: )
16807    { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&5
16808echo "$as_me: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
16809    { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&5
16810echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&2;}
16811    ac_header_preproc=yes
16812    ;;
16813  no:yes:* )
16814    { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&5
16815echo "$as_me: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&2;}
16816    { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h:     check for missing prerequisite headers?" >&5
16817echo "$as_me: WARNING: sys/dg_sys_info.h:     check for missing prerequisite headers?" >&2;}
16818    { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&5
16819echo "$as_me: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&2;}
16820    { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h:     section \"Present But Cannot Be Compiled\"" >&5
16821echo "$as_me: WARNING: sys/dg_sys_info.h:     section \"Present But Cannot Be Compiled\"" >&2;}
16822    { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
16823echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
16824    { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&5
16825echo "$as_me: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&2;}
16826
16827    ;;
16828esac
16829{ echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
16830echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6; }
16831if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
16832  echo $ECHO_N "(cached) $ECHO_C" >&6
16833else
16834  ac_cv_header_sys_dg_sys_info_h=$ac_header_preproc
16835fi
16836{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
16837echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6; }
16838
16839fi
16840if test $ac_cv_header_sys_dg_sys_info_h = yes; then
16841  ac_have_func=yes
16842
16843cat >>confdefs.h <<\_ACEOF
16844#define DGUX 1
16845_ACEOF
16846
16847
16848{ echo "$as_me:$LINENO: checking for dg_sys_info in -ldgc" >&5
16849echo $ECHO_N "checking for dg_sys_info in -ldgc... $ECHO_C" >&6; }
16850if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then
16851  echo $ECHO_N "(cached) $ECHO_C" >&6
16852else
16853  ac_check_lib_save_LIBS=$LIBS
16854LIBS="-ldgc  $LIBS"
16855cat >conftest.$ac_ext <<_ACEOF
16856/* confdefs.h.  */
16857_ACEOF
16858cat confdefs.h >>conftest.$ac_ext
16859cat >>conftest.$ac_ext <<_ACEOF
16860/* end confdefs.h.  */
16861
16862/* Override any GCC internal prototype to avoid an error.
16863   Use char because int might match the return type of a GCC
16864   builtin and then its argument prototype would still apply.  */
16865#ifdef __cplusplus
16866extern "C"
16867#endif
16868char dg_sys_info ();
16869int
16870main ()
16871{
16872return dg_sys_info ();
16873  ;
16874  return 0;
16875}
16876_ACEOF
16877rm -f conftest.$ac_objext conftest$ac_exeext
16878if { (ac_try="$ac_link"
16879case "(($ac_try" in
16880  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16881  *) ac_try_echo=$ac_try;;
16882esac
16883eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16884  (eval "$ac_link") 2>conftest.er1
16885  ac_status=$?
16886  grep -v '^ *+' conftest.er1 >conftest.err
16887  rm -f conftest.er1
16888  cat conftest.err >&5
16889  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16890  (exit $ac_status); } && {
16891	 test -z "$ac_c_werror_flag" ||
16892	 test ! -s conftest.err
16893       } && test -s conftest$ac_exeext &&
16894       $as_test_x conftest$ac_exeext; then
16895  ac_cv_lib_dgc_dg_sys_info=yes
16896else
16897  echo "$as_me: failed program was:" >&5
16898sed 's/^/| /' conftest.$ac_ext >&5
16899
16900	ac_cv_lib_dgc_dg_sys_info=no
16901fi
16902
16903rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16904      conftest$ac_exeext conftest.$ac_ext
16905LIBS=$ac_check_lib_save_LIBS
16906fi
16907{ echo "$as_me:$LINENO: result: $ac_cv_lib_dgc_dg_sys_info" >&5
16908echo "${ECHO_T}$ac_cv_lib_dgc_dg_sys_info" >&6; }
16909if test $ac_cv_lib_dgc_dg_sys_info = yes; then
16910  cat >>confdefs.h <<_ACEOF
16911#define HAVE_LIBDGC 1
16912_ACEOF
16913
16914  LIBS="-ldgc $LIBS"
16915
16916fi
16917
16918fi
16919
16920
16921
16922if test "${ac_cv_header_locale_h+set}" = set; then
16923  { echo "$as_me:$LINENO: checking for locale.h" >&5
16924echo $ECHO_N "checking for locale.h... $ECHO_C" >&6; }
16925if test "${ac_cv_header_locale_h+set}" = set; then
16926  echo $ECHO_N "(cached) $ECHO_C" >&6
16927fi
16928{ echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
16929echo "${ECHO_T}$ac_cv_header_locale_h" >&6; }
16930else
16931  # Is the header compilable?
16932{ echo "$as_me:$LINENO: checking locale.h usability" >&5
16933echo $ECHO_N "checking locale.h usability... $ECHO_C" >&6; }
16934cat >conftest.$ac_ext <<_ACEOF
16935/* confdefs.h.  */
16936_ACEOF
16937cat confdefs.h >>conftest.$ac_ext
16938cat >>conftest.$ac_ext <<_ACEOF
16939/* end confdefs.h.  */
16940$ac_includes_default
16941#include <locale.h>
16942_ACEOF
16943rm -f conftest.$ac_objext
16944if { (ac_try="$ac_compile"
16945case "(($ac_try" in
16946  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16947  *) ac_try_echo=$ac_try;;
16948esac
16949eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16950  (eval "$ac_compile") 2>conftest.er1
16951  ac_status=$?
16952  grep -v '^ *+' conftest.er1 >conftest.err
16953  rm -f conftest.er1
16954  cat conftest.err >&5
16955  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16956  (exit $ac_status); } && {
16957	 test -z "$ac_c_werror_flag" ||
16958	 test ! -s conftest.err
16959       } && test -s conftest.$ac_objext; then
16960  ac_header_compiler=yes
16961else
16962  echo "$as_me: failed program was:" >&5
16963sed 's/^/| /' conftest.$ac_ext >&5
16964
16965	ac_header_compiler=no
16966fi
16967
16968rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16969{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16970echo "${ECHO_T}$ac_header_compiler" >&6; }
16971
16972# Is the header present?
16973{ echo "$as_me:$LINENO: checking locale.h presence" >&5
16974echo $ECHO_N "checking locale.h presence... $ECHO_C" >&6; }
16975cat >conftest.$ac_ext <<_ACEOF
16976/* confdefs.h.  */
16977_ACEOF
16978cat confdefs.h >>conftest.$ac_ext
16979cat >>conftest.$ac_ext <<_ACEOF
16980/* end confdefs.h.  */
16981#include <locale.h>
16982_ACEOF
16983if { (ac_try="$ac_cpp conftest.$ac_ext"
16984case "(($ac_try" in
16985  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16986  *) ac_try_echo=$ac_try;;
16987esac
16988eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16989  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
16990  ac_status=$?
16991  grep -v '^ *+' conftest.er1 >conftest.err
16992  rm -f conftest.er1
16993  cat conftest.err >&5
16994  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16995  (exit $ac_status); } >/dev/null && {
16996	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
16997	 test ! -s conftest.err
16998       }; then
16999  ac_header_preproc=yes
17000else
17001  echo "$as_me: failed program was:" >&5
17002sed 's/^/| /' conftest.$ac_ext >&5
17003
17004  ac_header_preproc=no
17005fi
17006
17007rm -f conftest.err conftest.$ac_ext
17008{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17009echo "${ECHO_T}$ac_header_preproc" >&6; }
17010
17011# So?  What about this header?
17012case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17013  yes:no: )
17014    { echo "$as_me:$LINENO: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&5
17015echo "$as_me: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
17016    { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the compiler's result" >&5
17017echo "$as_me: WARNING: locale.h: proceeding with the compiler's result" >&2;}
17018    ac_header_preproc=yes
17019    ;;
17020  no:yes:* )
17021    { echo "$as_me:$LINENO: WARNING: locale.h: present but cannot be compiled" >&5
17022echo "$as_me: WARNING: locale.h: present but cannot be compiled" >&2;}
17023    { echo "$as_me:$LINENO: WARNING: locale.h:     check for missing prerequisite headers?" >&5
17024echo "$as_me: WARNING: locale.h:     check for missing prerequisite headers?" >&2;}
17025    { echo "$as_me:$LINENO: WARNING: locale.h: see the Autoconf documentation" >&5
17026echo "$as_me: WARNING: locale.h: see the Autoconf documentation" >&2;}
17027    { echo "$as_me:$LINENO: WARNING: locale.h:     section \"Present But Cannot Be Compiled\"" >&5
17028echo "$as_me: WARNING: locale.h:     section \"Present But Cannot Be Compiled\"" >&2;}
17029    { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
17030echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
17031    { echo "$as_me:$LINENO: WARNING: locale.h: in the future, the compiler will take precedence" >&5
17032echo "$as_me: WARNING: locale.h: in the future, the compiler will take precedence" >&2;}
17033
17034    ;;
17035esac
17036{ echo "$as_me:$LINENO: checking for locale.h" >&5
17037echo $ECHO_N "checking for locale.h... $ECHO_C" >&6; }
17038if test "${ac_cv_header_locale_h+set}" = set; then
17039  echo $ECHO_N "(cached) $ECHO_C" >&6
17040else
17041  ac_cv_header_locale_h=$ac_header_preproc
17042fi
17043{ echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
17044echo "${ECHO_T}$ac_cv_header_locale_h" >&6; }
17045
17046fi
17047
17048
17049
17050for ac_func in setlocale
17051do
17052as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17053{ echo "$as_me:$LINENO: checking for $ac_func" >&5
17054echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17055if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17056  echo $ECHO_N "(cached) $ECHO_C" >&6
17057else
17058  cat >conftest.$ac_ext <<_ACEOF
17059/* confdefs.h.  */
17060_ACEOF
17061cat confdefs.h >>conftest.$ac_ext
17062cat >>conftest.$ac_ext <<_ACEOF
17063/* end confdefs.h.  */
17064/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17065   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17066#define $ac_func innocuous_$ac_func
17067
17068/* System header to define __stub macros and hopefully few prototypes,
17069    which can conflict with char $ac_func (); below.
17070    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17071    <limits.h> exists even on freestanding compilers.  */
17072
17073#ifdef __STDC__
17074# include <limits.h>
17075#else
17076# include <assert.h>
17077#endif
17078
17079#undef $ac_func
17080
17081/* Override any GCC internal prototype to avoid an error.
17082   Use char because int might match the return type of a GCC
17083   builtin and then its argument prototype would still apply.  */
17084#ifdef __cplusplus
17085extern "C"
17086#endif
17087char $ac_func ();
17088/* The GNU C library defines this for functions which it implements
17089    to always fail with ENOSYS.  Some functions are actually named
17090    something starting with __ and the normal name is an alias.  */
17091#if defined __stub_$ac_func || defined __stub___$ac_func
17092choke me
17093#endif
17094
17095int
17096main ()
17097{
17098return $ac_func ();
17099  ;
17100  return 0;
17101}
17102_ACEOF
17103rm -f conftest.$ac_objext conftest$ac_exeext
17104if { (ac_try="$ac_link"
17105case "(($ac_try" in
17106  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17107  *) ac_try_echo=$ac_try;;
17108esac
17109eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17110  (eval "$ac_link") 2>conftest.er1
17111  ac_status=$?
17112  grep -v '^ *+' conftest.er1 >conftest.err
17113  rm -f conftest.er1
17114  cat conftest.err >&5
17115  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17116  (exit $ac_status); } && {
17117	 test -z "$ac_c_werror_flag" ||
17118	 test ! -s conftest.err
17119       } && test -s conftest$ac_exeext &&
17120       $as_test_x conftest$ac_exeext; then
17121  eval "$as_ac_var=yes"
17122else
17123  echo "$as_me: failed program was:" >&5
17124sed 's/^/| /' conftest.$ac_ext >&5
17125
17126	eval "$as_ac_var=no"
17127fi
17128
17129rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17130      conftest$ac_exeext conftest.$ac_ext
17131fi
17132ac_res=`eval echo '${'$as_ac_var'}'`
17133	       { echo "$as_me:$LINENO: result: $ac_res" >&5
17134echo "${ECHO_T}$ac_res" >&6; }
17135if test `eval echo '${'$as_ac_var'}'` = yes; then
17136  cat >>confdefs.h <<_ACEOF
17137#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17138_ACEOF
17139
17140fi
17141done
17142
17143
17144# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
17145# uses stabs), but it is still SVR4.  We cannot check for <elf.h> because
17146# Irix 4.0.5F has the header but not the library.
17147if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
17148  ac_have_func=yes
17149
17150cat >>confdefs.h <<\_ACEOF
17151#define SVR4 1
17152_ACEOF
17153
17154fi
17155
17156if test $ac_have_func = no; then
17157  if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
17158  { echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
17159echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6; }
17160if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
17161  echo $ECHO_N "(cached) $ECHO_C" >&6
17162fi
17163{ echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
17164echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6; }
17165else
17166  # Is the header compilable?
17167{ echo "$as_me:$LINENO: checking inq_stats/cpustats.h usability" >&5
17168echo $ECHO_N "checking inq_stats/cpustats.h usability... $ECHO_C" >&6; }
17169cat >conftest.$ac_ext <<_ACEOF
17170/* confdefs.h.  */
17171_ACEOF
17172cat confdefs.h >>conftest.$ac_ext
17173cat >>conftest.$ac_ext <<_ACEOF
17174/* end confdefs.h.  */
17175$ac_includes_default
17176#include <inq_stats/cpustats.h>
17177_ACEOF
17178rm -f conftest.$ac_objext
17179if { (ac_try="$ac_compile"
17180case "(($ac_try" in
17181  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17182  *) ac_try_echo=$ac_try;;
17183esac
17184eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17185  (eval "$ac_compile") 2>conftest.er1
17186  ac_status=$?
17187  grep -v '^ *+' conftest.er1 >conftest.err
17188  rm -f conftest.er1
17189  cat conftest.err >&5
17190  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17191  (exit $ac_status); } && {
17192	 test -z "$ac_c_werror_flag" ||
17193	 test ! -s conftest.err
17194       } && test -s conftest.$ac_objext; then
17195  ac_header_compiler=yes
17196else
17197  echo "$as_me: failed program was:" >&5
17198sed 's/^/| /' conftest.$ac_ext >&5
17199
17200	ac_header_compiler=no
17201fi
17202
17203rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17204{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17205echo "${ECHO_T}$ac_header_compiler" >&6; }
17206
17207# Is the header present?
17208{ echo "$as_me:$LINENO: checking inq_stats/cpustats.h presence" >&5
17209echo $ECHO_N "checking inq_stats/cpustats.h presence... $ECHO_C" >&6; }
17210cat >conftest.$ac_ext <<_ACEOF
17211/* confdefs.h.  */
17212_ACEOF
17213cat confdefs.h >>conftest.$ac_ext
17214cat >>conftest.$ac_ext <<_ACEOF
17215/* end confdefs.h.  */
17216#include <inq_stats/cpustats.h>
17217_ACEOF
17218if { (ac_try="$ac_cpp conftest.$ac_ext"
17219case "(($ac_try" in
17220  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17221  *) ac_try_echo=$ac_try;;
17222esac
17223eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17224  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
17225  ac_status=$?
17226  grep -v '^ *+' conftest.er1 >conftest.err
17227  rm -f conftest.er1
17228  cat conftest.err >&5
17229  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17230  (exit $ac_status); } >/dev/null && {
17231	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
17232	 test ! -s conftest.err
17233       }; then
17234  ac_header_preproc=yes
17235else
17236  echo "$as_me: failed program was:" >&5
17237sed 's/^/| /' conftest.$ac_ext >&5
17238
17239  ac_header_preproc=no
17240fi
17241
17242rm -f conftest.err conftest.$ac_ext
17243{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17244echo "${ECHO_T}$ac_header_preproc" >&6; }
17245
17246# So?  What about this header?
17247case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17248  yes:no: )
17249    { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
17250echo "$as_me: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
17251    { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&5
17252echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&2;}
17253    ac_header_preproc=yes
17254    ;;
17255  no:yes:* )
17256    { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&5
17257echo "$as_me: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&2;}
17258    { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h:     check for missing prerequisite headers?" >&5
17259echo "$as_me: WARNING: inq_stats/cpustats.h:     check for missing prerequisite headers?" >&2;}
17260    { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&5
17261echo "$as_me: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&2;}
17262    { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h:     section \"Present But Cannot Be Compiled\"" >&5
17263echo "$as_me: WARNING: inq_stats/cpustats.h:     section \"Present But Cannot Be Compiled\"" >&2;}
17264    { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
17265echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
17266    { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&5
17267echo "$as_me: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&2;}
17268
17269    ;;
17270esac
17271{ echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
17272echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6; }
17273if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
17274  echo $ECHO_N "(cached) $ECHO_C" >&6
17275else
17276  ac_cv_header_inq_stats_cpustats_h=$ac_header_preproc
17277fi
17278{ echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
17279echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6; }
17280
17281fi
17282if test $ac_cv_header_inq_stats_cpustats_h = yes; then
17283  ac_have_func=yes
17284
17285cat >>confdefs.h <<\_ACEOF
17286#define UMAX 1
17287_ACEOF
17288
17289
17290cat >>confdefs.h <<\_ACEOF
17291#define UMAX4_3 1
17292_ACEOF
17293
17294fi
17295
17296
17297fi
17298
17299if test $ac_have_func = no; then
17300  if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
17301  { echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
17302echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6; }
17303if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
17304  echo $ECHO_N "(cached) $ECHO_C" >&6
17305fi
17306{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
17307echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6; }
17308else
17309  # Is the header compilable?
17310{ echo "$as_me:$LINENO: checking sys/cpustats.h usability" >&5
17311echo $ECHO_N "checking sys/cpustats.h usability... $ECHO_C" >&6; }
17312cat >conftest.$ac_ext <<_ACEOF
17313/* confdefs.h.  */
17314_ACEOF
17315cat confdefs.h >>conftest.$ac_ext
17316cat >>conftest.$ac_ext <<_ACEOF
17317/* end confdefs.h.  */
17318$ac_includes_default
17319#include <sys/cpustats.h>
17320_ACEOF
17321rm -f conftest.$ac_objext
17322if { (ac_try="$ac_compile"
17323case "(($ac_try" in
17324  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17325  *) ac_try_echo=$ac_try;;
17326esac
17327eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17328  (eval "$ac_compile") 2>conftest.er1
17329  ac_status=$?
17330  grep -v '^ *+' conftest.er1 >conftest.err
17331  rm -f conftest.er1
17332  cat conftest.err >&5
17333  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17334  (exit $ac_status); } && {
17335	 test -z "$ac_c_werror_flag" ||
17336	 test ! -s conftest.err
17337       } && test -s conftest.$ac_objext; then
17338  ac_header_compiler=yes
17339else
17340  echo "$as_me: failed program was:" >&5
17341sed 's/^/| /' conftest.$ac_ext >&5
17342
17343	ac_header_compiler=no
17344fi
17345
17346rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17347{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17348echo "${ECHO_T}$ac_header_compiler" >&6; }
17349
17350# Is the header present?
17351{ echo "$as_me:$LINENO: checking sys/cpustats.h presence" >&5
17352echo $ECHO_N "checking sys/cpustats.h presence... $ECHO_C" >&6; }
17353cat >conftest.$ac_ext <<_ACEOF
17354/* confdefs.h.  */
17355_ACEOF
17356cat confdefs.h >>conftest.$ac_ext
17357cat >>conftest.$ac_ext <<_ACEOF
17358/* end confdefs.h.  */
17359#include <sys/cpustats.h>
17360_ACEOF
17361if { (ac_try="$ac_cpp conftest.$ac_ext"
17362case "(($ac_try" in
17363  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17364  *) ac_try_echo=$ac_try;;
17365esac
17366eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17367  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
17368  ac_status=$?
17369  grep -v '^ *+' conftest.er1 >conftest.err
17370  rm -f conftest.er1
17371  cat conftest.err >&5
17372  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17373  (exit $ac_status); } >/dev/null && {
17374	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
17375	 test ! -s conftest.err
17376       }; then
17377  ac_header_preproc=yes
17378else
17379  echo "$as_me: failed program was:" >&5
17380sed 's/^/| /' conftest.$ac_ext >&5
17381
17382  ac_header_preproc=no
17383fi
17384
17385rm -f conftest.err conftest.$ac_ext
17386{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17387echo "${ECHO_T}$ac_header_preproc" >&6; }
17388
17389# So?  What about this header?
17390case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17391  yes:no: )
17392    { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
17393echo "$as_me: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
17394    { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&5
17395echo "$as_me: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&2;}
17396    ac_header_preproc=yes
17397    ;;
17398  no:yes:* )
17399    { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: present but cannot be compiled" >&5
17400echo "$as_me: WARNING: sys/cpustats.h: present but cannot be compiled" >&2;}
17401    { echo "$as_me:$LINENO: WARNING: sys/cpustats.h:     check for missing prerequisite headers?" >&5
17402echo "$as_me: WARNING: sys/cpustats.h:     check for missing prerequisite headers?" >&2;}
17403    { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: see the Autoconf documentation" >&5
17404echo "$as_me: WARNING: sys/cpustats.h: see the Autoconf documentation" >&2;}
17405    { echo "$as_me:$LINENO: WARNING: sys/cpustats.h:     section \"Present But Cannot Be Compiled\"" >&5
17406echo "$as_me: WARNING: sys/cpustats.h:     section \"Present But Cannot Be Compiled\"" >&2;}
17407    { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
17408echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
17409    { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&5
17410echo "$as_me: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&2;}
17411
17412    ;;
17413esac
17414{ echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
17415echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6; }
17416if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
17417  echo $ECHO_N "(cached) $ECHO_C" >&6
17418else
17419  ac_cv_header_sys_cpustats_h=$ac_header_preproc
17420fi
17421{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
17422echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6; }
17423
17424fi
17425if test $ac_cv_header_sys_cpustats_h = yes; then
17426  ac_have_func=yes; cat >>confdefs.h <<\_ACEOF
17427#define UMAX 1
17428_ACEOF
17429
17430fi
17431
17432
17433fi
17434
17435if test $ac_have_func = no; then
17436
17437for ac_header in mach/mach.h
17438do
17439as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17440if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
17441  { echo "$as_me:$LINENO: checking for $ac_header" >&5
17442echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
17443if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
17444  echo $ECHO_N "(cached) $ECHO_C" >&6
17445fi
17446ac_res=`eval echo '${'$as_ac_Header'}'`
17447	       { echo "$as_me:$LINENO: result: $ac_res" >&5
17448echo "${ECHO_T}$ac_res" >&6; }
17449else
17450  # Is the header compilable?
17451{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
17452echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
17453cat >conftest.$ac_ext <<_ACEOF
17454/* confdefs.h.  */
17455_ACEOF
17456cat confdefs.h >>conftest.$ac_ext
17457cat >>conftest.$ac_ext <<_ACEOF
17458/* end confdefs.h.  */
17459$ac_includes_default
17460#include <$ac_header>
17461_ACEOF
17462rm -f conftest.$ac_objext
17463if { (ac_try="$ac_compile"
17464case "(($ac_try" in
17465  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17466  *) ac_try_echo=$ac_try;;
17467esac
17468eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17469  (eval "$ac_compile") 2>conftest.er1
17470  ac_status=$?
17471  grep -v '^ *+' conftest.er1 >conftest.err
17472  rm -f conftest.er1
17473  cat conftest.err >&5
17474  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17475  (exit $ac_status); } && {
17476	 test -z "$ac_c_werror_flag" ||
17477	 test ! -s conftest.err
17478       } && test -s conftest.$ac_objext; then
17479  ac_header_compiler=yes
17480else
17481  echo "$as_me: failed program was:" >&5
17482sed 's/^/| /' conftest.$ac_ext >&5
17483
17484	ac_header_compiler=no
17485fi
17486
17487rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17488{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17489echo "${ECHO_T}$ac_header_compiler" >&6; }
17490
17491# Is the header present?
17492{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
17493echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
17494cat >conftest.$ac_ext <<_ACEOF
17495/* confdefs.h.  */
17496_ACEOF
17497cat confdefs.h >>conftest.$ac_ext
17498cat >>conftest.$ac_ext <<_ACEOF
17499/* end confdefs.h.  */
17500#include <$ac_header>
17501_ACEOF
17502if { (ac_try="$ac_cpp conftest.$ac_ext"
17503case "(($ac_try" in
17504  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17505  *) ac_try_echo=$ac_try;;
17506esac
17507eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17508  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
17509  ac_status=$?
17510  grep -v '^ *+' conftest.er1 >conftest.err
17511  rm -f conftest.er1
17512  cat conftest.err >&5
17513  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17514  (exit $ac_status); } >/dev/null && {
17515	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
17516	 test ! -s conftest.err
17517       }; then
17518  ac_header_preproc=yes
17519else
17520  echo "$as_me: failed program was:" >&5
17521sed 's/^/| /' conftest.$ac_ext >&5
17522
17523  ac_header_preproc=no
17524fi
17525
17526rm -f conftest.err conftest.$ac_ext
17527{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17528echo "${ECHO_T}$ac_header_preproc" >&6; }
17529
17530# So?  What about this header?
17531case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17532  yes:no: )
17533    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17534echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17535    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17536echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17537    ac_header_preproc=yes
17538    ;;
17539  no:yes:* )
17540    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17541echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17542    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
17543echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
17544    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17545echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17546    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
17547echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
17548    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17549echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17550    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17551echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17552
17553    ;;
17554esac
17555{ echo "$as_me:$LINENO: checking for $ac_header" >&5
17556echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
17557if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
17558  echo $ECHO_N "(cached) $ECHO_C" >&6
17559else
17560  eval "$as_ac_Header=\$ac_header_preproc"
17561fi
17562ac_res=`eval echo '${'$as_ac_Header'}'`
17563	       { echo "$as_me:$LINENO: result: $ac_res" >&5
17564echo "${ECHO_T}$ac_res" >&6; }
17565
17566fi
17567if test `eval echo '${'$as_ac_Header'}'` = yes; then
17568  cat >>confdefs.h <<_ACEOF
17569#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17570_ACEOF
17571
17572fi
17573
17574done
17575
17576fi
17577
17578
17579for ac_header in nlist.h
17580do
17581as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17582if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
17583  { echo "$as_me:$LINENO: checking for $ac_header" >&5
17584echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
17585if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
17586  echo $ECHO_N "(cached) $ECHO_C" >&6
17587fi
17588ac_res=`eval echo '${'$as_ac_Header'}'`
17589	       { echo "$as_me:$LINENO: result: $ac_res" >&5
17590echo "${ECHO_T}$ac_res" >&6; }
17591else
17592  # Is the header compilable?
17593{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
17594echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
17595cat >conftest.$ac_ext <<_ACEOF
17596/* confdefs.h.  */
17597_ACEOF
17598cat confdefs.h >>conftest.$ac_ext
17599cat >>conftest.$ac_ext <<_ACEOF
17600/* end confdefs.h.  */
17601$ac_includes_default
17602#include <$ac_header>
17603_ACEOF
17604rm -f conftest.$ac_objext
17605if { (ac_try="$ac_compile"
17606case "(($ac_try" in
17607  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17608  *) ac_try_echo=$ac_try;;
17609esac
17610eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17611  (eval "$ac_compile") 2>conftest.er1
17612  ac_status=$?
17613  grep -v '^ *+' conftest.er1 >conftest.err
17614  rm -f conftest.er1
17615  cat conftest.err >&5
17616  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17617  (exit $ac_status); } && {
17618	 test -z "$ac_c_werror_flag" ||
17619	 test ! -s conftest.err
17620       } && test -s conftest.$ac_objext; then
17621  ac_header_compiler=yes
17622else
17623  echo "$as_me: failed program was:" >&5
17624sed 's/^/| /' conftest.$ac_ext >&5
17625
17626	ac_header_compiler=no
17627fi
17628
17629rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17630{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17631echo "${ECHO_T}$ac_header_compiler" >&6; }
17632
17633# Is the header present?
17634{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
17635echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
17636cat >conftest.$ac_ext <<_ACEOF
17637/* confdefs.h.  */
17638_ACEOF
17639cat confdefs.h >>conftest.$ac_ext
17640cat >>conftest.$ac_ext <<_ACEOF
17641/* end confdefs.h.  */
17642#include <$ac_header>
17643_ACEOF
17644if { (ac_try="$ac_cpp conftest.$ac_ext"
17645case "(($ac_try" in
17646  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17647  *) ac_try_echo=$ac_try;;
17648esac
17649eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17650  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
17651  ac_status=$?
17652  grep -v '^ *+' conftest.er1 >conftest.err
17653  rm -f conftest.er1
17654  cat conftest.err >&5
17655  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17656  (exit $ac_status); } >/dev/null && {
17657	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
17658	 test ! -s conftest.err
17659       }; then
17660  ac_header_preproc=yes
17661else
17662  echo "$as_me: failed program was:" >&5
17663sed 's/^/| /' conftest.$ac_ext >&5
17664
17665  ac_header_preproc=no
17666fi
17667
17668rm -f conftest.err conftest.$ac_ext
17669{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17670echo "${ECHO_T}$ac_header_preproc" >&6; }
17671
17672# So?  What about this header?
17673case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17674  yes:no: )
17675    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17676echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17677    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17678echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17679    ac_header_preproc=yes
17680    ;;
17681  no:yes:* )
17682    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17683echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17684    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
17685echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
17686    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17687echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17688    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
17689echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
17690    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17691echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17692    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17693echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17694
17695    ;;
17696esac
17697{ echo "$as_me:$LINENO: checking for $ac_header" >&5
17698echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
17699if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
17700  echo $ECHO_N "(cached) $ECHO_C" >&6
17701else
17702  eval "$as_ac_Header=\$ac_header_preproc"
17703fi
17704ac_res=`eval echo '${'$as_ac_Header'}'`
17705	       { echo "$as_me:$LINENO: result: $ac_res" >&5
17706echo "${ECHO_T}$ac_res" >&6; }
17707
17708fi
17709if test `eval echo '${'$as_ac_Header'}'` = yes; then
17710  cat >>confdefs.h <<_ACEOF
17711#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17712_ACEOF
17713 { echo "$as_me:$LINENO: checking for struct nlist.n_un.n_name" >&5
17714echo $ECHO_N "checking for struct nlist.n_un.n_name... $ECHO_C" >&6; }
17715if test "${ac_cv_member_struct_nlist_n_un_n_name+set}" = set; then
17716  echo $ECHO_N "(cached) $ECHO_C" >&6
17717else
17718  cat >conftest.$ac_ext <<_ACEOF
17719/* confdefs.h.  */
17720_ACEOF
17721cat confdefs.h >>conftest.$ac_ext
17722cat >>conftest.$ac_ext <<_ACEOF
17723/* end confdefs.h.  */
17724#include <nlist.h>
17725
17726int
17727main ()
17728{
17729static struct nlist ac_aggr;
17730if (ac_aggr.n_un.n_name)
17731return 0;
17732  ;
17733  return 0;
17734}
17735_ACEOF
17736rm -f conftest.$ac_objext
17737if { (ac_try="$ac_compile"
17738case "(($ac_try" in
17739  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17740  *) ac_try_echo=$ac_try;;
17741esac
17742eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17743  (eval "$ac_compile") 2>conftest.er1
17744  ac_status=$?
17745  grep -v '^ *+' conftest.er1 >conftest.err
17746  rm -f conftest.er1
17747  cat conftest.err >&5
17748  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17749  (exit $ac_status); } && {
17750	 test -z "$ac_c_werror_flag" ||
17751	 test ! -s conftest.err
17752       } && test -s conftest.$ac_objext; then
17753  ac_cv_member_struct_nlist_n_un_n_name=yes
17754else
17755  echo "$as_me: failed program was:" >&5
17756sed 's/^/| /' conftest.$ac_ext >&5
17757
17758	cat >conftest.$ac_ext <<_ACEOF
17759/* confdefs.h.  */
17760_ACEOF
17761cat confdefs.h >>conftest.$ac_ext
17762cat >>conftest.$ac_ext <<_ACEOF
17763/* end confdefs.h.  */
17764#include <nlist.h>
17765
17766int
17767main ()
17768{
17769static struct nlist ac_aggr;
17770if (sizeof ac_aggr.n_un.n_name)
17771return 0;
17772  ;
17773  return 0;
17774}
17775_ACEOF
17776rm -f conftest.$ac_objext
17777if { (ac_try="$ac_compile"
17778case "(($ac_try" in
17779  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17780  *) ac_try_echo=$ac_try;;
17781esac
17782eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17783  (eval "$ac_compile") 2>conftest.er1
17784  ac_status=$?
17785  grep -v '^ *+' conftest.er1 >conftest.err
17786  rm -f conftest.er1
17787  cat conftest.err >&5
17788  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17789  (exit $ac_status); } && {
17790	 test -z "$ac_c_werror_flag" ||
17791	 test ! -s conftest.err
17792       } && test -s conftest.$ac_objext; then
17793  ac_cv_member_struct_nlist_n_un_n_name=yes
17794else
17795  echo "$as_me: failed program was:" >&5
17796sed 's/^/| /' conftest.$ac_ext >&5
17797
17798	ac_cv_member_struct_nlist_n_un_n_name=no
17799fi
17800
17801rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17802fi
17803
17804rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17805fi
17806{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_nlist_n_un_n_name" >&5
17807echo "${ECHO_T}$ac_cv_member_struct_nlist_n_un_n_name" >&6; }
17808if test $ac_cv_member_struct_nlist_n_un_n_name = yes; then
17809
17810cat >>confdefs.h <<_ACEOF
17811#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
17812_ACEOF
17813
17814
17815cat >>confdefs.h <<\_ACEOF
17816#define NLIST_NAME_UNION 1
17817_ACEOF
17818
17819fi
17820
17821
17822fi
17823
17824done
17825
17826fi
17827done
17828
17829
17830# Some definitions of getloadavg require that the program be installed setgid.
17831{ echo "$as_me:$LINENO: checking whether getloadavg requires setgid" >&5
17832echo $ECHO_N "checking whether getloadavg requires setgid... $ECHO_C" >&6; }
17833if test "${ac_cv_func_getloadavg_setgid+set}" = set; then
17834  echo $ECHO_N "(cached) $ECHO_C" >&6
17835else
17836  cat >conftest.$ac_ext <<_ACEOF
17837/* confdefs.h.  */
17838_ACEOF
17839cat confdefs.h >>conftest.$ac_ext
17840cat >>conftest.$ac_ext <<_ACEOF
17841/* end confdefs.h.  */
17842#include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
17843#ifdef LDAV_PRIVILEGED
17844Yowza Am I SETGID yet
17845#endif
17846_ACEOF
17847if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17848  $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then
17849  ac_cv_func_getloadavg_setgid=yes
17850else
17851  ac_cv_func_getloadavg_setgid=no
17852fi
17853rm -f conftest*
17854
17855fi
17856{ echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg_setgid" >&5
17857echo "${ECHO_T}$ac_cv_func_getloadavg_setgid" >&6; }
17858if test $ac_cv_func_getloadavg_setgid = yes; then
17859  NEED_SETGID=true
17860
17861cat >>confdefs.h <<\_ACEOF
17862#define GETLOADAVG_PRIVILEGED 1
17863_ACEOF
17864
17865else
17866  NEED_SETGID=false
17867fi
17868
17869if test $ac_cv_func_getloadavg_setgid = yes; then
17870  { echo "$as_me:$LINENO: checking group of /dev/kmem" >&5
17871echo $ECHO_N "checking group of /dev/kmem... $ECHO_C" >&6; }
17872if test "${ac_cv_group_kmem+set}" = set; then
17873  echo $ECHO_N "(cached) $ECHO_C" >&6
17874else
17875   # On Solaris, /dev/kmem is a symlink.  Get info on the real file.
17876  ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
17877  # If we got an error (system does not support symlinks), try without -L.
17878  test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
17879  ac_cv_group_kmem=`echo $ac_ls_output \
17880    | sed -ne 's/[	 ][	 ]*/ /g;
17881	       s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\)  *.*/\1/;
17882	       / /s/.* //;p;'`
17883
17884fi
17885{ echo "$as_me:$LINENO: result: $ac_cv_group_kmem" >&5
17886echo "${ECHO_T}$ac_cv_group_kmem" >&6; }
17887  KMEM_GROUP=$ac_cv_group_kmem
17888fi
17889if test "x$ac_save_LIBS" = x; then
17890  GETLOADAVG_LIBS=$LIBS
17891else
17892  GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$ac_save_LIBS!!"`
17893fi
17894LIBS=$ac_save_LIBS
17895
17896
17897
17898{ echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
17899echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6; }
17900if test "${ac_cv_sys_largefile_source+set}" = set; then
17901  echo $ECHO_N "(cached) $ECHO_C" >&6
17902else
17903  while :; do
17904  cat >conftest.$ac_ext <<_ACEOF
17905/* confdefs.h.  */
17906_ACEOF
17907cat confdefs.h >>conftest.$ac_ext
17908cat >>conftest.$ac_ext <<_ACEOF
17909/* end confdefs.h.  */
17910#include <stdio.h>
17911int
17912main ()
17913{
17914return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0);
17915  ;
17916  return 0;
17917}
17918_ACEOF
17919rm -f conftest.$ac_objext conftest$ac_exeext
17920if { (ac_try="$ac_link"
17921case "(($ac_try" in
17922  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17923  *) ac_try_echo=$ac_try;;
17924esac
17925eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17926  (eval "$ac_link") 2>conftest.er1
17927  ac_status=$?
17928  grep -v '^ *+' conftest.er1 >conftest.err
17929  rm -f conftest.er1
17930  cat conftest.err >&5
17931  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17932  (exit $ac_status); } && {
17933	 test -z "$ac_c_werror_flag" ||
17934	 test ! -s conftest.err
17935       } && test -s conftest$ac_exeext &&
17936       $as_test_x conftest$ac_exeext; then
17937  ac_cv_sys_largefile_source=no; break
17938else
17939  echo "$as_me: failed program was:" >&5
17940sed 's/^/| /' conftest.$ac_ext >&5
17941
17942
17943fi
17944
17945rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17946      conftest$ac_exeext conftest.$ac_ext
17947  cat >conftest.$ac_ext <<_ACEOF
17948/* confdefs.h.  */
17949_ACEOF
17950cat confdefs.h >>conftest.$ac_ext
17951cat >>conftest.$ac_ext <<_ACEOF
17952/* end confdefs.h.  */
17953#define _LARGEFILE_SOURCE 1
17954#include <stdio.h>
17955int
17956main ()
17957{
17958return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0);
17959  ;
17960  return 0;
17961}
17962_ACEOF
17963rm -f conftest.$ac_objext conftest$ac_exeext
17964if { (ac_try="$ac_link"
17965case "(($ac_try" in
17966  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17967  *) ac_try_echo=$ac_try;;
17968esac
17969eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17970  (eval "$ac_link") 2>conftest.er1
17971  ac_status=$?
17972  grep -v '^ *+' conftest.er1 >conftest.err
17973  rm -f conftest.er1
17974  cat conftest.err >&5
17975  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17976  (exit $ac_status); } && {
17977	 test -z "$ac_c_werror_flag" ||
17978	 test ! -s conftest.err
17979       } && test -s conftest$ac_exeext &&
17980       $as_test_x conftest$ac_exeext; then
17981  ac_cv_sys_largefile_source=1; break
17982else
17983  echo "$as_me: failed program was:" >&5
17984sed 's/^/| /' conftest.$ac_ext >&5
17985
17986
17987fi
17988
17989rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17990      conftest$ac_exeext conftest.$ac_ext
17991  ac_cv_sys_largefile_source=unknown
17992  break
17993done
17994fi
17995{ echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
17996echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6; }
17997case $ac_cv_sys_largefile_source in #(
17998  no | unknown) ;;
17999  *)
18000cat >>confdefs.h <<_ACEOF
18001#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
18002_ACEOF
18003;;
18004esac
18005rm -f conftest*
18006
18007# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
18008# in glibc 2.1.3, but that breaks too many other things.
18009# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
18010if test $ac_cv_sys_largefile_source != unknown; then
18011
18012cat >>confdefs.h <<\_ACEOF
18013#define HAVE_FSEEKO 1
18014_ACEOF
18015
18016fi
18017
18018
18019# Configure getopt.
18020# getopt.m4 serial 10
18021
18022# The getopt module assume you want GNU getopt, with getopt_long etc,
18023# rather than vanilla POSIX getopt.  This means your your code should
18024# always include <getopt.h> for the getopt prototypes.
18025
18026
18027
18028
18029
18030
18031
18032
18033
18034
18035
18036# Prerequisites of lib/getopt*.
18037
18038
18039
18040
18041  GETOPT_H=
18042
18043for ac_header in getopt.h
18044do
18045as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18046if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
18047  { echo "$as_me:$LINENO: checking for $ac_header" >&5
18048echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
18049if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
18050  echo $ECHO_N "(cached) $ECHO_C" >&6
18051fi
18052ac_res=`eval echo '${'$as_ac_Header'}'`
18053	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18054echo "${ECHO_T}$ac_res" >&6; }
18055else
18056  # Is the header compilable?
18057{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
18058echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
18059cat >conftest.$ac_ext <<_ACEOF
18060/* confdefs.h.  */
18061_ACEOF
18062cat confdefs.h >>conftest.$ac_ext
18063cat >>conftest.$ac_ext <<_ACEOF
18064/* end confdefs.h.  */
18065$ac_includes_default
18066#include <$ac_header>
18067_ACEOF
18068rm -f conftest.$ac_objext
18069if { (ac_try="$ac_compile"
18070case "(($ac_try" in
18071  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18072  *) ac_try_echo=$ac_try;;
18073esac
18074eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18075  (eval "$ac_compile") 2>conftest.er1
18076  ac_status=$?
18077  grep -v '^ *+' conftest.er1 >conftest.err
18078  rm -f conftest.er1
18079  cat conftest.err >&5
18080  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18081  (exit $ac_status); } && {
18082	 test -z "$ac_c_werror_flag" ||
18083	 test ! -s conftest.err
18084       } && test -s conftest.$ac_objext; then
18085  ac_header_compiler=yes
18086else
18087  echo "$as_me: failed program was:" >&5
18088sed 's/^/| /' conftest.$ac_ext >&5
18089
18090	ac_header_compiler=no
18091fi
18092
18093rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18094{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18095echo "${ECHO_T}$ac_header_compiler" >&6; }
18096
18097# Is the header present?
18098{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
18099echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
18100cat >conftest.$ac_ext <<_ACEOF
18101/* confdefs.h.  */
18102_ACEOF
18103cat confdefs.h >>conftest.$ac_ext
18104cat >>conftest.$ac_ext <<_ACEOF
18105/* end confdefs.h.  */
18106#include <$ac_header>
18107_ACEOF
18108if { (ac_try="$ac_cpp conftest.$ac_ext"
18109case "(($ac_try" in
18110  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18111  *) ac_try_echo=$ac_try;;
18112esac
18113eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18114  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
18115  ac_status=$?
18116  grep -v '^ *+' conftest.er1 >conftest.err
18117  rm -f conftest.er1
18118  cat conftest.err >&5
18119  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18120  (exit $ac_status); } >/dev/null && {
18121	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
18122	 test ! -s conftest.err
18123       }; then
18124  ac_header_preproc=yes
18125else
18126  echo "$as_me: failed program was:" >&5
18127sed 's/^/| /' conftest.$ac_ext >&5
18128
18129  ac_header_preproc=no
18130fi
18131
18132rm -f conftest.err conftest.$ac_ext
18133{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18134echo "${ECHO_T}$ac_header_preproc" >&6; }
18135
18136# So?  What about this header?
18137case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18138  yes:no: )
18139    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18140echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18141    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18142echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18143    ac_header_preproc=yes
18144    ;;
18145  no:yes:* )
18146    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18147echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18148    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18149echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18150    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18151echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18152    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18153echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18154    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18155echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18156    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18157echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18158
18159    ;;
18160esac
18161{ echo "$as_me:$LINENO: checking for $ac_header" >&5
18162echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
18163if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
18164  echo $ECHO_N "(cached) $ECHO_C" >&6
18165else
18166  eval "$as_ac_Header=\$ac_header_preproc"
18167fi
18168ac_res=`eval echo '${'$as_ac_Header'}'`
18169	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18170echo "${ECHO_T}$ac_res" >&6; }
18171
18172fi
18173if test `eval echo '${'$as_ac_Header'}'` = yes; then
18174  cat >>confdefs.h <<_ACEOF
18175#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18176_ACEOF
18177
18178else
18179  GETOPT_H=getopt.h
18180fi
18181
18182done
18183
18184  if test -z "$GETOPT_H"; then
18185
18186for ac_func in getopt_long_only
18187do
18188as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18189{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18190echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18191if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18192  echo $ECHO_N "(cached) $ECHO_C" >&6
18193else
18194  cat >conftest.$ac_ext <<_ACEOF
18195/* confdefs.h.  */
18196_ACEOF
18197cat confdefs.h >>conftest.$ac_ext
18198cat >>conftest.$ac_ext <<_ACEOF
18199/* end confdefs.h.  */
18200/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18201   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18202#define $ac_func innocuous_$ac_func
18203
18204/* System header to define __stub macros and hopefully few prototypes,
18205    which can conflict with char $ac_func (); below.
18206    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18207    <limits.h> exists even on freestanding compilers.  */
18208
18209#ifdef __STDC__
18210# include <limits.h>
18211#else
18212# include <assert.h>
18213#endif
18214
18215#undef $ac_func
18216
18217/* Override any GCC internal prototype to avoid an error.
18218   Use char because int might match the return type of a GCC
18219   builtin and then its argument prototype would still apply.  */
18220#ifdef __cplusplus
18221extern "C"
18222#endif
18223char $ac_func ();
18224/* The GNU C library defines this for functions which it implements
18225    to always fail with ENOSYS.  Some functions are actually named
18226    something starting with __ and the normal name is an alias.  */
18227#if defined __stub_$ac_func || defined __stub___$ac_func
18228choke me
18229#endif
18230
18231int
18232main ()
18233{
18234return $ac_func ();
18235  ;
18236  return 0;
18237}
18238_ACEOF
18239rm -f conftest.$ac_objext conftest$ac_exeext
18240if { (ac_try="$ac_link"
18241case "(($ac_try" in
18242  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18243  *) ac_try_echo=$ac_try;;
18244esac
18245eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18246  (eval "$ac_link") 2>conftest.er1
18247  ac_status=$?
18248  grep -v '^ *+' conftest.er1 >conftest.err
18249  rm -f conftest.er1
18250  cat conftest.err >&5
18251  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18252  (exit $ac_status); } && {
18253	 test -z "$ac_c_werror_flag" ||
18254	 test ! -s conftest.err
18255       } && test -s conftest$ac_exeext &&
18256       $as_test_x conftest$ac_exeext; then
18257  eval "$as_ac_var=yes"
18258else
18259  echo "$as_me: failed program was:" >&5
18260sed 's/^/| /' conftest.$ac_ext >&5
18261
18262	eval "$as_ac_var=no"
18263fi
18264
18265rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18266      conftest$ac_exeext conftest.$ac_ext
18267fi
18268ac_res=`eval echo '${'$as_ac_var'}'`
18269	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18270echo "${ECHO_T}$ac_res" >&6; }
18271if test `eval echo '${'$as_ac_var'}'` = yes; then
18272  cat >>confdefs.h <<_ACEOF
18273#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18274_ACEOF
18275
18276else
18277  GETOPT_H=getopt.h
18278fi
18279done
18280
18281  fi
18282
18283      if test -z "$GETOPT_H"; then
18284    { echo "$as_me:$LINENO: checking whether optreset is declared" >&5
18285echo $ECHO_N "checking whether optreset is declared... $ECHO_C" >&6; }
18286if test "${ac_cv_have_decl_optreset+set}" = set; then
18287  echo $ECHO_N "(cached) $ECHO_C" >&6
18288else
18289  cat >conftest.$ac_ext <<_ACEOF
18290/* confdefs.h.  */
18291_ACEOF
18292cat confdefs.h >>conftest.$ac_ext
18293cat >>conftest.$ac_ext <<_ACEOF
18294/* end confdefs.h.  */
18295#include <getopt.h>
18296
18297int
18298main ()
18299{
18300#ifndef optreset
18301  (void) optreset;
18302#endif
18303
18304  ;
18305  return 0;
18306}
18307_ACEOF
18308rm -f conftest.$ac_objext
18309if { (ac_try="$ac_compile"
18310case "(($ac_try" in
18311  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18312  *) ac_try_echo=$ac_try;;
18313esac
18314eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18315  (eval "$ac_compile") 2>conftest.er1
18316  ac_status=$?
18317  grep -v '^ *+' conftest.er1 >conftest.err
18318  rm -f conftest.er1
18319  cat conftest.err >&5
18320  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18321  (exit $ac_status); } && {
18322	 test -z "$ac_c_werror_flag" ||
18323	 test ! -s conftest.err
18324       } && test -s conftest.$ac_objext; then
18325  ac_cv_have_decl_optreset=yes
18326else
18327  echo "$as_me: failed program was:" >&5
18328sed 's/^/| /' conftest.$ac_ext >&5
18329
18330	ac_cv_have_decl_optreset=no
18331fi
18332
18333rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18334fi
18335{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_optreset" >&5
18336echo "${ECHO_T}$ac_cv_have_decl_optreset" >&6; }
18337if test $ac_cv_have_decl_optreset = yes; then
18338  GETOPT_H=getopt.h
18339fi
18340
18341  fi
18342
18343      if test -z "$GETOPT_H"; then
18344    { echo "$as_me:$LINENO: checking for working GNU getopt function" >&5
18345echo $ECHO_N "checking for working GNU getopt function... $ECHO_C" >&6; }
18346if test "${gl_cv_func_gnu_getopt+set}" = set; then
18347  echo $ECHO_N "(cached) $ECHO_C" >&6
18348else
18349  if test "$cross_compiling" = yes; then
18350  	 	 	 { echo "$as_me:$LINENO: checking whether getopt_clip is declared" >&5
18351echo $ECHO_N "checking whether getopt_clip is declared... $ECHO_C" >&6; }
18352if test "${ac_cv_have_decl_getopt_clip+set}" = set; then
18353  echo $ECHO_N "(cached) $ECHO_C" >&6
18354else
18355  cat >conftest.$ac_ext <<_ACEOF
18356/* confdefs.h.  */
18357_ACEOF
18358cat confdefs.h >>conftest.$ac_ext
18359cat >>conftest.$ac_ext <<_ACEOF
18360/* end confdefs.h.  */
18361#include <getopt.h>
18362
18363int
18364main ()
18365{
18366#ifndef getopt_clip
18367  (void) getopt_clip;
18368#endif
18369
18370  ;
18371  return 0;
18372}
18373_ACEOF
18374rm -f conftest.$ac_objext
18375if { (ac_try="$ac_compile"
18376case "(($ac_try" in
18377  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18378  *) ac_try_echo=$ac_try;;
18379esac
18380eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18381  (eval "$ac_compile") 2>conftest.er1
18382  ac_status=$?
18383  grep -v '^ *+' conftest.er1 >conftest.err
18384  rm -f conftest.er1
18385  cat conftest.err >&5
18386  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18387  (exit $ac_status); } && {
18388	 test -z "$ac_c_werror_flag" ||
18389	 test ! -s conftest.err
18390       } && test -s conftest.$ac_objext; then
18391  ac_cv_have_decl_getopt_clip=yes
18392else
18393  echo "$as_me: failed program was:" >&5
18394sed 's/^/| /' conftest.$ac_ext >&5
18395
18396	ac_cv_have_decl_getopt_clip=no
18397fi
18398
18399rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18400fi
18401{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_getopt_clip" >&5
18402echo "${ECHO_T}$ac_cv_have_decl_getopt_clip" >&6; }
18403if test $ac_cv_have_decl_getopt_clip = yes; then
18404  gl_cv_func_gnu_getopt=no
18405else
18406  gl_cv_func_gnu_getopt=yes
18407fi
18408
18409else
18410  cat >conftest.$ac_ext <<_ACEOF
18411/* confdefs.h.  */
18412_ACEOF
18413cat confdefs.h >>conftest.$ac_ext
18414cat >>conftest.$ac_ext <<_ACEOF
18415/* end confdefs.h.  */
18416#include <getopt.h>
18417int
18418main ()
18419{
18420
18421	     char *myargv[3];
18422	     myargv[0] = "conftest";
18423	     myargv[1] = "-+";
18424	     myargv[2] = 0;
18425	     return getopt (2, myargv, "+a") != '?';
18426
18427  ;
18428  return 0;
18429}
18430_ACEOF
18431rm -f conftest$ac_exeext
18432if { (ac_try="$ac_link"
18433case "(($ac_try" in
18434  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18435  *) ac_try_echo=$ac_try;;
18436esac
18437eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18438  (eval "$ac_link") 2>&5
18439  ac_status=$?
18440  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18441  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18442  { (case "(($ac_try" in
18443  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18444  *) ac_try_echo=$ac_try;;
18445esac
18446eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18447  (eval "$ac_try") 2>&5
18448  ac_status=$?
18449  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18450  (exit $ac_status); }; }; then
18451  gl_cv_func_gnu_getopt=yes
18452else
18453  echo "$as_me: program exited with status $ac_status" >&5
18454echo "$as_me: failed program was:" >&5
18455sed 's/^/| /' conftest.$ac_ext >&5
18456
18457( exit $ac_status )
18458gl_cv_func_gnu_getopt=no
18459fi
18460rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18461fi
18462
18463
18464fi
18465{ echo "$as_me:$LINENO: result: $gl_cv_func_gnu_getopt" >&5
18466echo "${ECHO_T}$gl_cv_func_gnu_getopt" >&6; }
18467    if test "$gl_cv_func_gnu_getopt" = "no"; then
18468      GETOPT_H=getopt.h
18469    fi
18470  fi
18471
18472
18473
18474  if test -n "$GETOPT_H"; then
18475
18476
18477  GETOPT_H=getopt.h
18478
18479cat >>confdefs.h <<\_ACEOF
18480#define __GETOPT_PREFIX rpl_
18481_ACEOF
18482
18483
18484
18485  :
18486  GETOPTOBJS='getopt.o getopt1.o'
18487
18488fi
18489
18490
18491
18492
18493{ echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5
18494echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6; }
18495if test "${ac_cv_func_getpgrp_void+set}" = set; then
18496  echo $ECHO_N "(cached) $ECHO_C" >&6
18497else
18498  # Use it with a single arg.
18499cat >conftest.$ac_ext <<_ACEOF
18500/* confdefs.h.  */
18501_ACEOF
18502cat confdefs.h >>conftest.$ac_ext
18503cat >>conftest.$ac_ext <<_ACEOF
18504/* end confdefs.h.  */
18505$ac_includes_default
18506int
18507main ()
18508{
18509getpgrp (0);
18510  ;
18511  return 0;
18512}
18513_ACEOF
18514rm -f conftest.$ac_objext
18515if { (ac_try="$ac_compile"
18516case "(($ac_try" in
18517  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18518  *) ac_try_echo=$ac_try;;
18519esac
18520eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18521  (eval "$ac_compile") 2>conftest.er1
18522  ac_status=$?
18523  grep -v '^ *+' conftest.er1 >conftest.err
18524  rm -f conftest.er1
18525  cat conftest.err >&5
18526  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18527  (exit $ac_status); } && {
18528	 test -z "$ac_c_werror_flag" ||
18529	 test ! -s conftest.err
18530       } && test -s conftest.$ac_objext; then
18531  ac_cv_func_getpgrp_void=no
18532else
18533  echo "$as_me: failed program was:" >&5
18534sed 's/^/| /' conftest.$ac_ext >&5
18535
18536	ac_cv_func_getpgrp_void=yes
18537fi
18538
18539rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18540
18541fi
18542{ echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5
18543echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6; }
18544if test $ac_cv_func_getpgrp_void = yes; then
18545
18546cat >>confdefs.h <<\_ACEOF
18547#define GETPGRP_VOID 1
18548_ACEOF
18549
18550fi
18551
18552
18553
18554for ac_func in strftime
18555do
18556as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18557{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18558echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18559if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18560  echo $ECHO_N "(cached) $ECHO_C" >&6
18561else
18562  cat >conftest.$ac_ext <<_ACEOF
18563/* confdefs.h.  */
18564_ACEOF
18565cat confdefs.h >>conftest.$ac_ext
18566cat >>conftest.$ac_ext <<_ACEOF
18567/* end confdefs.h.  */
18568/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18569   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18570#define $ac_func innocuous_$ac_func
18571
18572/* System header to define __stub macros and hopefully few prototypes,
18573    which can conflict with char $ac_func (); below.
18574    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18575    <limits.h> exists even on freestanding compilers.  */
18576
18577#ifdef __STDC__
18578# include <limits.h>
18579#else
18580# include <assert.h>
18581#endif
18582
18583#undef $ac_func
18584
18585/* Override any GCC internal prototype to avoid an error.
18586   Use char because int might match the return type of a GCC
18587   builtin and then its argument prototype would still apply.  */
18588#ifdef __cplusplus
18589extern "C"
18590#endif
18591char $ac_func ();
18592/* The GNU C library defines this for functions which it implements
18593    to always fail with ENOSYS.  Some functions are actually named
18594    something starting with __ and the normal name is an alias.  */
18595#if defined __stub_$ac_func || defined __stub___$ac_func
18596choke me
18597#endif
18598
18599int
18600main ()
18601{
18602return $ac_func ();
18603  ;
18604  return 0;
18605}
18606_ACEOF
18607rm -f conftest.$ac_objext conftest$ac_exeext
18608if { (ac_try="$ac_link"
18609case "(($ac_try" in
18610  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18611  *) ac_try_echo=$ac_try;;
18612esac
18613eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18614  (eval "$ac_link") 2>conftest.er1
18615  ac_status=$?
18616  grep -v '^ *+' conftest.er1 >conftest.err
18617  rm -f conftest.er1
18618  cat conftest.err >&5
18619  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18620  (exit $ac_status); } && {
18621	 test -z "$ac_c_werror_flag" ||
18622	 test ! -s conftest.err
18623       } && test -s conftest$ac_exeext &&
18624       $as_test_x conftest$ac_exeext; then
18625  eval "$as_ac_var=yes"
18626else
18627  echo "$as_me: failed program was:" >&5
18628sed 's/^/| /' conftest.$ac_ext >&5
18629
18630	eval "$as_ac_var=no"
18631fi
18632
18633rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18634      conftest$ac_exeext conftest.$ac_ext
18635fi
18636ac_res=`eval echo '${'$as_ac_var'}'`
18637	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18638echo "${ECHO_T}$ac_res" >&6; }
18639if test `eval echo '${'$as_ac_var'}'` = yes; then
18640  cat >>confdefs.h <<_ACEOF
18641#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18642_ACEOF
18643
18644else
18645  # strftime is in -lintl on SCO UNIX.
18646{ echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
18647echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6; }
18648if test "${ac_cv_lib_intl_strftime+set}" = set; then
18649  echo $ECHO_N "(cached) $ECHO_C" >&6
18650else
18651  ac_check_lib_save_LIBS=$LIBS
18652LIBS="-lintl  $LIBS"
18653cat >conftest.$ac_ext <<_ACEOF
18654/* confdefs.h.  */
18655_ACEOF
18656cat confdefs.h >>conftest.$ac_ext
18657cat >>conftest.$ac_ext <<_ACEOF
18658/* end confdefs.h.  */
18659
18660/* Override any GCC internal prototype to avoid an error.
18661   Use char because int might match the return type of a GCC
18662   builtin and then its argument prototype would still apply.  */
18663#ifdef __cplusplus
18664extern "C"
18665#endif
18666char strftime ();
18667int
18668main ()
18669{
18670return strftime ();
18671  ;
18672  return 0;
18673}
18674_ACEOF
18675rm -f conftest.$ac_objext conftest$ac_exeext
18676if { (ac_try="$ac_link"
18677case "(($ac_try" in
18678  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18679  *) ac_try_echo=$ac_try;;
18680esac
18681eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18682  (eval "$ac_link") 2>conftest.er1
18683  ac_status=$?
18684  grep -v '^ *+' conftest.er1 >conftest.err
18685  rm -f conftest.er1
18686  cat conftest.err >&5
18687  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18688  (exit $ac_status); } && {
18689	 test -z "$ac_c_werror_flag" ||
18690	 test ! -s conftest.err
18691       } && test -s conftest$ac_exeext &&
18692       $as_test_x conftest$ac_exeext; then
18693  ac_cv_lib_intl_strftime=yes
18694else
18695  echo "$as_me: failed program was:" >&5
18696sed 's/^/| /' conftest.$ac_ext >&5
18697
18698	ac_cv_lib_intl_strftime=no
18699fi
18700
18701rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18702      conftest$ac_exeext conftest.$ac_ext
18703LIBS=$ac_check_lib_save_LIBS
18704fi
18705{ echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
18706echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6; }
18707if test $ac_cv_lib_intl_strftime = yes; then
18708  cat >>confdefs.h <<\_ACEOF
18709#define HAVE_STRFTIME 1
18710_ACEOF
18711
18712LIBS="-lintl $LIBS"
18713fi
18714
18715fi
18716done
18717
18718
18719# UNIX98 PTYs.
18720
18721for ac_func in grantpt
18722do
18723as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18724{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18725echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18726if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18727  echo $ECHO_N "(cached) $ECHO_C" >&6
18728else
18729  cat >conftest.$ac_ext <<_ACEOF
18730/* confdefs.h.  */
18731_ACEOF
18732cat confdefs.h >>conftest.$ac_ext
18733cat >>conftest.$ac_ext <<_ACEOF
18734/* end confdefs.h.  */
18735/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18736   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18737#define $ac_func innocuous_$ac_func
18738
18739/* System header to define __stub macros and hopefully few prototypes,
18740    which can conflict with char $ac_func (); below.
18741    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18742    <limits.h> exists even on freestanding compilers.  */
18743
18744#ifdef __STDC__
18745# include <limits.h>
18746#else
18747# include <assert.h>
18748#endif
18749
18750#undef $ac_func
18751
18752/* Override any GCC internal prototype to avoid an error.
18753   Use char because int might match the return type of a GCC
18754   builtin and then its argument prototype would still apply.  */
18755#ifdef __cplusplus
18756extern "C"
18757#endif
18758char $ac_func ();
18759/* The GNU C library defines this for functions which it implements
18760    to always fail with ENOSYS.  Some functions are actually named
18761    something starting with __ and the normal name is an alias.  */
18762#if defined __stub_$ac_func || defined __stub___$ac_func
18763choke me
18764#endif
18765
18766int
18767main ()
18768{
18769return $ac_func ();
18770  ;
18771  return 0;
18772}
18773_ACEOF
18774rm -f conftest.$ac_objext conftest$ac_exeext
18775if { (ac_try="$ac_link"
18776case "(($ac_try" in
18777  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18778  *) ac_try_echo=$ac_try;;
18779esac
18780eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18781  (eval "$ac_link") 2>conftest.er1
18782  ac_status=$?
18783  grep -v '^ *+' conftest.er1 >conftest.err
18784  rm -f conftest.er1
18785  cat conftest.err >&5
18786  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18787  (exit $ac_status); } && {
18788	 test -z "$ac_c_werror_flag" ||
18789	 test ! -s conftest.err
18790       } && test -s conftest$ac_exeext &&
18791       $as_test_x conftest$ac_exeext; then
18792  eval "$as_ac_var=yes"
18793else
18794  echo "$as_me: failed program was:" >&5
18795sed 's/^/| /' conftest.$ac_ext >&5
18796
18797	eval "$as_ac_var=no"
18798fi
18799
18800rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18801      conftest$ac_exeext conftest.$ac_ext
18802fi
18803ac_res=`eval echo '${'$as_ac_var'}'`
18804	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18805echo "${ECHO_T}$ac_res" >&6; }
18806if test `eval echo '${'$as_ac_var'}'` = yes; then
18807  cat >>confdefs.h <<_ACEOF
18808#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18809_ACEOF
18810
18811fi
18812done
18813
18814
18815# PTY-related GNU extensions.
18816
18817for ac_func in getpt
18818do
18819as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18820{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18821echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18822if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18823  echo $ECHO_N "(cached) $ECHO_C" >&6
18824else
18825  cat >conftest.$ac_ext <<_ACEOF
18826/* confdefs.h.  */
18827_ACEOF
18828cat confdefs.h >>conftest.$ac_ext
18829cat >>conftest.$ac_ext <<_ACEOF
18830/* end confdefs.h.  */
18831/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18832   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18833#define $ac_func innocuous_$ac_func
18834
18835/* System header to define __stub macros and hopefully few prototypes,
18836    which can conflict with char $ac_func (); below.
18837    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18838    <limits.h> exists even on freestanding compilers.  */
18839
18840#ifdef __STDC__
18841# include <limits.h>
18842#else
18843# include <assert.h>
18844#endif
18845
18846#undef $ac_func
18847
18848/* Override any GCC internal prototype to avoid an error.
18849   Use char because int might match the return type of a GCC
18850   builtin and then its argument prototype would still apply.  */
18851#ifdef __cplusplus
18852extern "C"
18853#endif
18854char $ac_func ();
18855/* The GNU C library defines this for functions which it implements
18856    to always fail with ENOSYS.  Some functions are actually named
18857    something starting with __ and the normal name is an alias.  */
18858#if defined __stub_$ac_func || defined __stub___$ac_func
18859choke me
18860#endif
18861
18862int
18863main ()
18864{
18865return $ac_func ();
18866  ;
18867  return 0;
18868}
18869_ACEOF
18870rm -f conftest.$ac_objext conftest$ac_exeext
18871if { (ac_try="$ac_link"
18872case "(($ac_try" in
18873  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18874  *) ac_try_echo=$ac_try;;
18875esac
18876eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18877  (eval "$ac_link") 2>conftest.er1
18878  ac_status=$?
18879  grep -v '^ *+' conftest.er1 >conftest.err
18880  rm -f conftest.er1
18881  cat conftest.err >&5
18882  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18883  (exit $ac_status); } && {
18884	 test -z "$ac_c_werror_flag" ||
18885	 test ! -s conftest.err
18886       } && test -s conftest$ac_exeext &&
18887       $as_test_x conftest$ac_exeext; then
18888  eval "$as_ac_var=yes"
18889else
18890  echo "$as_me: failed program was:" >&5
18891sed 's/^/| /' conftest.$ac_ext >&5
18892
18893	eval "$as_ac_var=no"
18894fi
18895
18896rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18897      conftest$ac_exeext conftest.$ac_ext
18898fi
18899ac_res=`eval echo '${'$as_ac_var'}'`
18900	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18901echo "${ECHO_T}$ac_res" >&6; }
18902if test `eval echo '${'$as_ac_var'}'` = yes; then
18903  cat >>confdefs.h <<_ACEOF
18904#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18905_ACEOF
18906
18907fi
18908done
18909
18910
18911# Check this now, so that we will NOT find the above functions in ncurses.
18912# That is because we have not set up to link ncurses in lib-src.
18913# It's better to believe a function is not available
18914# than to expect to find it in ncurses.
18915
18916{ echo "$as_me:$LINENO: checking for tparm in -lncurses" >&5
18917echo $ECHO_N "checking for tparm in -lncurses... $ECHO_C" >&6; }
18918if test "${ac_cv_lib_ncurses_tparm+set}" = set; then
18919  echo $ECHO_N "(cached) $ECHO_C" >&6
18920else
18921  ac_check_lib_save_LIBS=$LIBS
18922LIBS="-lncurses  $LIBS"
18923cat >conftest.$ac_ext <<_ACEOF
18924/* confdefs.h.  */
18925_ACEOF
18926cat confdefs.h >>conftest.$ac_ext
18927cat >>conftest.$ac_ext <<_ACEOF
18928/* end confdefs.h.  */
18929
18930/* Override any GCC internal prototype to avoid an error.
18931   Use char because int might match the return type of a GCC
18932   builtin and then its argument prototype would still apply.  */
18933#ifdef __cplusplus
18934extern "C"
18935#endif
18936char tparm ();
18937int
18938main ()
18939{
18940return tparm ();
18941  ;
18942  return 0;
18943}
18944_ACEOF
18945rm -f conftest.$ac_objext conftest$ac_exeext
18946if { (ac_try="$ac_link"
18947case "(($ac_try" in
18948  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18949  *) ac_try_echo=$ac_try;;
18950esac
18951eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18952  (eval "$ac_link") 2>conftest.er1
18953  ac_status=$?
18954  grep -v '^ *+' conftest.er1 >conftest.err
18955  rm -f conftest.er1
18956  cat conftest.err >&5
18957  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18958  (exit $ac_status); } && {
18959	 test -z "$ac_c_werror_flag" ||
18960	 test ! -s conftest.err
18961       } && test -s conftest$ac_exeext &&
18962       $as_test_x conftest$ac_exeext; then
18963  ac_cv_lib_ncurses_tparm=yes
18964else
18965  echo "$as_me: failed program was:" >&5
18966sed 's/^/| /' conftest.$ac_ext >&5
18967
18968	ac_cv_lib_ncurses_tparm=no
18969fi
18970
18971rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18972      conftest$ac_exeext conftest.$ac_ext
18973LIBS=$ac_check_lib_save_LIBS
18974fi
18975{ echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_tparm" >&5
18976echo "${ECHO_T}$ac_cv_lib_ncurses_tparm" >&6; }
18977if test $ac_cv_lib_ncurses_tparm = yes; then
18978  cat >>confdefs.h <<_ACEOF
18979#define HAVE_LIBNCURSES 1
18980_ACEOF
18981
18982  LIBS="-lncurses $LIBS"
18983
18984fi
18985
18986
18987# Do we need the Hesiod library to provide the support routines?
18988if test "$with_hesiod" = yes ; then
18989  # Don't set $LIBS here -- see comments above.
18990  resolv=no
18991  { echo "$as_me:$LINENO: checking for res_send" >&5
18992echo $ECHO_N "checking for res_send... $ECHO_C" >&6; }
18993if test "${ac_cv_func_res_send+set}" = set; then
18994  echo $ECHO_N "(cached) $ECHO_C" >&6
18995else
18996  cat >conftest.$ac_ext <<_ACEOF
18997/* confdefs.h.  */
18998_ACEOF
18999cat confdefs.h >>conftest.$ac_ext
19000cat >>conftest.$ac_ext <<_ACEOF
19001/* end confdefs.h.  */
19002/* Define res_send to an innocuous variant, in case <limits.h> declares res_send.
19003   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19004#define res_send innocuous_res_send
19005
19006/* System header to define __stub macros and hopefully few prototypes,
19007    which can conflict with char res_send (); below.
19008    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19009    <limits.h> exists even on freestanding compilers.  */
19010
19011#ifdef __STDC__
19012# include <limits.h>
19013#else
19014# include <assert.h>
19015#endif
19016
19017#undef res_send
19018
19019/* Override any GCC internal prototype to avoid an error.
19020   Use char because int might match the return type of a GCC
19021   builtin and then its argument prototype would still apply.  */
19022#ifdef __cplusplus
19023extern "C"
19024#endif
19025char res_send ();
19026/* The GNU C library defines this for functions which it implements
19027    to always fail with ENOSYS.  Some functions are actually named
19028    something starting with __ and the normal name is an alias.  */
19029#if defined __stub_res_send || defined __stub___res_send
19030choke me
19031#endif
19032
19033int
19034main ()
19035{
19036return res_send ();
19037  ;
19038  return 0;
19039}
19040_ACEOF
19041rm -f conftest.$ac_objext conftest$ac_exeext
19042if { (ac_try="$ac_link"
19043case "(($ac_try" in
19044  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19045  *) ac_try_echo=$ac_try;;
19046esac
19047eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19048  (eval "$ac_link") 2>conftest.er1
19049  ac_status=$?
19050  grep -v '^ *+' conftest.er1 >conftest.err
19051  rm -f conftest.er1
19052  cat conftest.err >&5
19053  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19054  (exit $ac_status); } && {
19055	 test -z "$ac_c_werror_flag" ||
19056	 test ! -s conftest.err
19057       } && test -s conftest$ac_exeext &&
19058       $as_test_x conftest$ac_exeext; then
19059  ac_cv_func_res_send=yes
19060else
19061  echo "$as_me: failed program was:" >&5
19062sed 's/^/| /' conftest.$ac_ext >&5
19063
19064	ac_cv_func_res_send=no
19065fi
19066
19067rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19068      conftest$ac_exeext conftest.$ac_ext
19069fi
19070{ echo "$as_me:$LINENO: result: $ac_cv_func_res_send" >&5
19071echo "${ECHO_T}$ac_cv_func_res_send" >&6; }
19072if test $ac_cv_func_res_send = yes; then
19073  :
19074else
19075  { echo "$as_me:$LINENO: checking for __res_send" >&5
19076echo $ECHO_N "checking for __res_send... $ECHO_C" >&6; }
19077if test "${ac_cv_func___res_send+set}" = set; then
19078  echo $ECHO_N "(cached) $ECHO_C" >&6
19079else
19080  cat >conftest.$ac_ext <<_ACEOF
19081/* confdefs.h.  */
19082_ACEOF
19083cat confdefs.h >>conftest.$ac_ext
19084cat >>conftest.$ac_ext <<_ACEOF
19085/* end confdefs.h.  */
19086/* Define __res_send to an innocuous variant, in case <limits.h> declares __res_send.
19087   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19088#define __res_send innocuous___res_send
19089
19090/* System header to define __stub macros and hopefully few prototypes,
19091    which can conflict with char __res_send (); below.
19092    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19093    <limits.h> exists even on freestanding compilers.  */
19094
19095#ifdef __STDC__
19096# include <limits.h>
19097#else
19098# include <assert.h>
19099#endif
19100
19101#undef __res_send
19102
19103/* Override any GCC internal prototype to avoid an error.
19104   Use char because int might match the return type of a GCC
19105   builtin and then its argument prototype would still apply.  */
19106#ifdef __cplusplus
19107extern "C"
19108#endif
19109char __res_send ();
19110/* The GNU C library defines this for functions which it implements
19111    to always fail with ENOSYS.  Some functions are actually named
19112    something starting with __ and the normal name is an alias.  */
19113#if defined __stub___res_send || defined __stub_____res_send
19114choke me
19115#endif
19116
19117int
19118main ()
19119{
19120return __res_send ();
19121  ;
19122  return 0;
19123}
19124_ACEOF
19125rm -f conftest.$ac_objext conftest$ac_exeext
19126if { (ac_try="$ac_link"
19127case "(($ac_try" in
19128  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19129  *) ac_try_echo=$ac_try;;
19130esac
19131eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19132  (eval "$ac_link") 2>conftest.er1
19133  ac_status=$?
19134  grep -v '^ *+' conftest.er1 >conftest.err
19135  rm -f conftest.er1
19136  cat conftest.err >&5
19137  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19138  (exit $ac_status); } && {
19139	 test -z "$ac_c_werror_flag" ||
19140	 test ! -s conftest.err
19141       } && test -s conftest$ac_exeext &&
19142       $as_test_x conftest$ac_exeext; then
19143  ac_cv_func___res_send=yes
19144else
19145  echo "$as_me: failed program was:" >&5
19146sed 's/^/| /' conftest.$ac_ext >&5
19147
19148	ac_cv_func___res_send=no
19149fi
19150
19151rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19152      conftest$ac_exeext conftest.$ac_ext
19153fi
19154{ echo "$as_me:$LINENO: result: $ac_cv_func___res_send" >&5
19155echo "${ECHO_T}$ac_cv_func___res_send" >&6; }
19156if test $ac_cv_func___res_send = yes; then
19157  :
19158else
19159  { echo "$as_me:$LINENO: checking for res_send in -lresolv" >&5
19160echo $ECHO_N "checking for res_send in -lresolv... $ECHO_C" >&6; }
19161if test "${ac_cv_lib_resolv_res_send+set}" = set; then
19162  echo $ECHO_N "(cached) $ECHO_C" >&6
19163else
19164  ac_check_lib_save_LIBS=$LIBS
19165LIBS="-lresolv  $LIBS"
19166cat >conftest.$ac_ext <<_ACEOF
19167/* confdefs.h.  */
19168_ACEOF
19169cat confdefs.h >>conftest.$ac_ext
19170cat >>conftest.$ac_ext <<_ACEOF
19171/* end confdefs.h.  */
19172
19173/* Override any GCC internal prototype to avoid an error.
19174   Use char because int might match the return type of a GCC
19175   builtin and then its argument prototype would still apply.  */
19176#ifdef __cplusplus
19177extern "C"
19178#endif
19179char res_send ();
19180int
19181main ()
19182{
19183return res_send ();
19184  ;
19185  return 0;
19186}
19187_ACEOF
19188rm -f conftest.$ac_objext conftest$ac_exeext
19189if { (ac_try="$ac_link"
19190case "(($ac_try" in
19191  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19192  *) ac_try_echo=$ac_try;;
19193esac
19194eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19195  (eval "$ac_link") 2>conftest.er1
19196  ac_status=$?
19197  grep -v '^ *+' conftest.er1 >conftest.err
19198  rm -f conftest.er1
19199  cat conftest.err >&5
19200  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19201  (exit $ac_status); } && {
19202	 test -z "$ac_c_werror_flag" ||
19203	 test ! -s conftest.err
19204       } && test -s conftest$ac_exeext &&
19205       $as_test_x conftest$ac_exeext; then
19206  ac_cv_lib_resolv_res_send=yes
19207else
19208  echo "$as_me: failed program was:" >&5
19209sed 's/^/| /' conftest.$ac_ext >&5
19210
19211	ac_cv_lib_resolv_res_send=no
19212fi
19213
19214rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19215      conftest$ac_exeext conftest.$ac_ext
19216LIBS=$ac_check_lib_save_LIBS
19217fi
19218{ echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_send" >&5
19219echo "${ECHO_T}$ac_cv_lib_resolv_res_send" >&6; }
19220if test $ac_cv_lib_resolv_res_send = yes; then
19221  resolv=yes
19222else
19223  { echo "$as_me:$LINENO: checking for __res_send in -lresolv" >&5
19224echo $ECHO_N "checking for __res_send in -lresolv... $ECHO_C" >&6; }
19225if test "${ac_cv_lib_resolv___res_send+set}" = set; then
19226  echo $ECHO_N "(cached) $ECHO_C" >&6
19227else
19228  ac_check_lib_save_LIBS=$LIBS
19229LIBS="-lresolv  $LIBS"
19230cat >conftest.$ac_ext <<_ACEOF
19231/* confdefs.h.  */
19232_ACEOF
19233cat confdefs.h >>conftest.$ac_ext
19234cat >>conftest.$ac_ext <<_ACEOF
19235/* end confdefs.h.  */
19236
19237/* Override any GCC internal prototype to avoid an error.
19238   Use char because int might match the return type of a GCC
19239   builtin and then its argument prototype would still apply.  */
19240#ifdef __cplusplus
19241extern "C"
19242#endif
19243char __res_send ();
19244int
19245main ()
19246{
19247return __res_send ();
19248  ;
19249  return 0;
19250}
19251_ACEOF
19252rm -f conftest.$ac_objext conftest$ac_exeext
19253if { (ac_try="$ac_link"
19254case "(($ac_try" in
19255  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19256  *) ac_try_echo=$ac_try;;
19257esac
19258eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19259  (eval "$ac_link") 2>conftest.er1
19260  ac_status=$?
19261  grep -v '^ *+' conftest.er1 >conftest.err
19262  rm -f conftest.er1
19263  cat conftest.err >&5
19264  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19265  (exit $ac_status); } && {
19266	 test -z "$ac_c_werror_flag" ||
19267	 test ! -s conftest.err
19268       } && test -s conftest$ac_exeext &&
19269       $as_test_x conftest$ac_exeext; then
19270  ac_cv_lib_resolv___res_send=yes
19271else
19272  echo "$as_me: failed program was:" >&5
19273sed 's/^/| /' conftest.$ac_ext >&5
19274
19275	ac_cv_lib_resolv___res_send=no
19276fi
19277
19278rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19279      conftest$ac_exeext conftest.$ac_ext
19280LIBS=$ac_check_lib_save_LIBS
19281fi
19282{ echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_send" >&5
19283echo "${ECHO_T}$ac_cv_lib_resolv___res_send" >&6; }
19284if test $ac_cv_lib_resolv___res_send = yes; then
19285  resolv=yes
19286fi
19287
19288fi
19289
19290fi
19291
19292fi
19293
19294  if test "$resolv" = yes ; then
19295    RESOLVLIB=-lresolv
19296
19297cat >>confdefs.h <<\_ACEOF
19298#define HAVE_LIBRESOLV 1
19299_ACEOF
19300
19301  else
19302    RESOLVLIB=
19303  fi
19304  { echo "$as_me:$LINENO: checking for hes_getmailhost" >&5
19305echo $ECHO_N "checking for hes_getmailhost... $ECHO_C" >&6; }
19306if test "${ac_cv_func_hes_getmailhost+set}" = set; then
19307  echo $ECHO_N "(cached) $ECHO_C" >&6
19308else
19309  cat >conftest.$ac_ext <<_ACEOF
19310/* confdefs.h.  */
19311_ACEOF
19312cat confdefs.h >>conftest.$ac_ext
19313cat >>conftest.$ac_ext <<_ACEOF
19314/* end confdefs.h.  */
19315/* Define hes_getmailhost to an innocuous variant, in case <limits.h> declares hes_getmailhost.
19316   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19317#define hes_getmailhost innocuous_hes_getmailhost
19318
19319/* System header to define __stub macros and hopefully few prototypes,
19320    which can conflict with char hes_getmailhost (); below.
19321    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19322    <limits.h> exists even on freestanding compilers.  */
19323
19324#ifdef __STDC__
19325# include <limits.h>
19326#else
19327# include <assert.h>
19328#endif
19329
19330#undef hes_getmailhost
19331
19332/* Override any GCC internal prototype to avoid an error.
19333   Use char because int might match the return type of a GCC
19334   builtin and then its argument prototype would still apply.  */
19335#ifdef __cplusplus
19336extern "C"
19337#endif
19338char hes_getmailhost ();
19339/* The GNU C library defines this for functions which it implements
19340    to always fail with ENOSYS.  Some functions are actually named
19341    something starting with __ and the normal name is an alias.  */
19342#if defined __stub_hes_getmailhost || defined __stub___hes_getmailhost
19343choke me
19344#endif
19345
19346int
19347main ()
19348{
19349return hes_getmailhost ();
19350  ;
19351  return 0;
19352}
19353_ACEOF
19354rm -f conftest.$ac_objext conftest$ac_exeext
19355if { (ac_try="$ac_link"
19356case "(($ac_try" in
19357  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19358  *) ac_try_echo=$ac_try;;
19359esac
19360eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19361  (eval "$ac_link") 2>conftest.er1
19362  ac_status=$?
19363  grep -v '^ *+' conftest.er1 >conftest.err
19364  rm -f conftest.er1
19365  cat conftest.err >&5
19366  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19367  (exit $ac_status); } && {
19368	 test -z "$ac_c_werror_flag" ||
19369	 test ! -s conftest.err
19370       } && test -s conftest$ac_exeext &&
19371       $as_test_x conftest$ac_exeext; then
19372  ac_cv_func_hes_getmailhost=yes
19373else
19374  echo "$as_me: failed program was:" >&5
19375sed 's/^/| /' conftest.$ac_ext >&5
19376
19377	ac_cv_func_hes_getmailhost=no
19378fi
19379
19380rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19381      conftest$ac_exeext conftest.$ac_ext
19382fi
19383{ echo "$as_me:$LINENO: result: $ac_cv_func_hes_getmailhost" >&5
19384echo "${ECHO_T}$ac_cv_func_hes_getmailhost" >&6; }
19385if test $ac_cv_func_hes_getmailhost = yes; then
19386  :
19387else
19388  { echo "$as_me:$LINENO: checking for hes_getmailhost in -lhesiod" >&5
19389echo $ECHO_N "checking for hes_getmailhost in -lhesiod... $ECHO_C" >&6; }
19390if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then
19391  echo $ECHO_N "(cached) $ECHO_C" >&6
19392else
19393  ac_check_lib_save_LIBS=$LIBS
19394LIBS="-lhesiod $RESOLVLIB $LIBS"
19395cat >conftest.$ac_ext <<_ACEOF
19396/* confdefs.h.  */
19397_ACEOF
19398cat confdefs.h >>conftest.$ac_ext
19399cat >>conftest.$ac_ext <<_ACEOF
19400/* end confdefs.h.  */
19401
19402/* Override any GCC internal prototype to avoid an error.
19403   Use char because int might match the return type of a GCC
19404   builtin and then its argument prototype would still apply.  */
19405#ifdef __cplusplus
19406extern "C"
19407#endif
19408char hes_getmailhost ();
19409int
19410main ()
19411{
19412return hes_getmailhost ();
19413  ;
19414  return 0;
19415}
19416_ACEOF
19417rm -f conftest.$ac_objext conftest$ac_exeext
19418if { (ac_try="$ac_link"
19419case "(($ac_try" in
19420  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19421  *) ac_try_echo=$ac_try;;
19422esac
19423eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19424  (eval "$ac_link") 2>conftest.er1
19425  ac_status=$?
19426  grep -v '^ *+' conftest.er1 >conftest.err
19427  rm -f conftest.er1
19428  cat conftest.err >&5
19429  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19430  (exit $ac_status); } && {
19431	 test -z "$ac_c_werror_flag" ||
19432	 test ! -s conftest.err
19433       } && test -s conftest$ac_exeext &&
19434       $as_test_x conftest$ac_exeext; then
19435  ac_cv_lib_hesiod_hes_getmailhost=yes
19436else
19437  echo "$as_me: failed program was:" >&5
19438sed 's/^/| /' conftest.$ac_ext >&5
19439
19440	ac_cv_lib_hesiod_hes_getmailhost=no
19441fi
19442
19443rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19444      conftest$ac_exeext conftest.$ac_ext
19445LIBS=$ac_check_lib_save_LIBS
19446fi
19447{ echo "$as_me:$LINENO: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
19448echo "${ECHO_T}$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
19449if test $ac_cv_lib_hesiod_hes_getmailhost = yes; then
19450
19451cat >>confdefs.h <<\_ACEOF
19452#define HAVE_LIBHESIOD 1
19453_ACEOF
19454
19455else
19456  :
19457fi
19458
19459fi
19460
19461fi
19462
19463# These tell us which Kerberos-related libraries to use.
19464if test "${with_kerberos+set}" = set; then
19465
19466{ echo "$as_me:$LINENO: checking for com_err in -lcom_err" >&5
19467echo $ECHO_N "checking for com_err in -lcom_err... $ECHO_C" >&6; }
19468if test "${ac_cv_lib_com_err_com_err+set}" = set; then
19469  echo $ECHO_N "(cached) $ECHO_C" >&6
19470else
19471  ac_check_lib_save_LIBS=$LIBS
19472LIBS="-lcom_err  $LIBS"
19473cat >conftest.$ac_ext <<_ACEOF
19474/* confdefs.h.  */
19475_ACEOF
19476cat confdefs.h >>conftest.$ac_ext
19477cat >>conftest.$ac_ext <<_ACEOF
19478/* end confdefs.h.  */
19479
19480/* Override any GCC internal prototype to avoid an error.
19481   Use char because int might match the return type of a GCC
19482   builtin and then its argument prototype would still apply.  */
19483#ifdef __cplusplus
19484extern "C"
19485#endif
19486char com_err ();
19487int
19488main ()
19489{
19490return com_err ();
19491  ;
19492  return 0;
19493}
19494_ACEOF
19495rm -f conftest.$ac_objext conftest$ac_exeext
19496if { (ac_try="$ac_link"
19497case "(($ac_try" in
19498  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19499  *) ac_try_echo=$ac_try;;
19500esac
19501eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19502  (eval "$ac_link") 2>conftest.er1
19503  ac_status=$?
19504  grep -v '^ *+' conftest.er1 >conftest.err
19505  rm -f conftest.er1
19506  cat conftest.err >&5
19507  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19508  (exit $ac_status); } && {
19509	 test -z "$ac_c_werror_flag" ||
19510	 test ! -s conftest.err
19511       } && test -s conftest$ac_exeext &&
19512       $as_test_x conftest$ac_exeext; then
19513  ac_cv_lib_com_err_com_err=yes
19514else
19515  echo "$as_me: failed program was:" >&5
19516sed 's/^/| /' conftest.$ac_ext >&5
19517
19518	ac_cv_lib_com_err_com_err=no
19519fi
19520
19521rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19522      conftest$ac_exeext conftest.$ac_ext
19523LIBS=$ac_check_lib_save_LIBS
19524fi
19525{ echo "$as_me:$LINENO: result: $ac_cv_lib_com_err_com_err" >&5
19526echo "${ECHO_T}$ac_cv_lib_com_err_com_err" >&6; }
19527if test $ac_cv_lib_com_err_com_err = yes; then
19528  cat >>confdefs.h <<_ACEOF
19529#define HAVE_LIBCOM_ERR 1
19530_ACEOF
19531
19532  LIBS="-lcom_err $LIBS"
19533
19534fi
19535
19536
19537{ echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
19538echo $ECHO_N "checking for mit_des_cbc_encrypt in -lk5crypto... $ECHO_C" >&6; }
19539if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then
19540  echo $ECHO_N "(cached) $ECHO_C" >&6
19541else
19542  ac_check_lib_save_LIBS=$LIBS
19543LIBS="-lk5crypto  $LIBS"
19544cat >conftest.$ac_ext <<_ACEOF
19545/* confdefs.h.  */
19546_ACEOF
19547cat confdefs.h >>conftest.$ac_ext
19548cat >>conftest.$ac_ext <<_ACEOF
19549/* end confdefs.h.  */
19550
19551/* Override any GCC internal prototype to avoid an error.
19552   Use char because int might match the return type of a GCC
19553   builtin and then its argument prototype would still apply.  */
19554#ifdef __cplusplus
19555extern "C"
19556#endif
19557char mit_des_cbc_encrypt ();
19558int
19559main ()
19560{
19561return mit_des_cbc_encrypt ();
19562  ;
19563  return 0;
19564}
19565_ACEOF
19566rm -f conftest.$ac_objext conftest$ac_exeext
19567if { (ac_try="$ac_link"
19568case "(($ac_try" in
19569  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19570  *) ac_try_echo=$ac_try;;
19571esac
19572eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19573  (eval "$ac_link") 2>conftest.er1
19574  ac_status=$?
19575  grep -v '^ *+' conftest.er1 >conftest.err
19576  rm -f conftest.er1
19577  cat conftest.err >&5
19578  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19579  (exit $ac_status); } && {
19580	 test -z "$ac_c_werror_flag" ||
19581	 test ! -s conftest.err
19582       } && test -s conftest$ac_exeext &&
19583       $as_test_x conftest$ac_exeext; then
19584  ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
19585else
19586  echo "$as_me: failed program was:" >&5
19587sed 's/^/| /' conftest.$ac_ext >&5
19588
19589	ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
19590fi
19591
19592rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19593      conftest$ac_exeext conftest.$ac_ext
19594LIBS=$ac_check_lib_save_LIBS
19595fi
19596{ echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
19597echo "${ECHO_T}$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
19598if test $ac_cv_lib_k5crypto_mit_des_cbc_encrypt = yes; then
19599  cat >>confdefs.h <<_ACEOF
19600#define HAVE_LIBK5CRYPTO 1
19601_ACEOF
19602
19603  LIBS="-lk5crypto $LIBS"
19604
19605fi
19606
19607
19608{ echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lcrypto" >&5
19609echo $ECHO_N "checking for mit_des_cbc_encrypt in -lcrypto... $ECHO_C" >&6; }
19610if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then
19611  echo $ECHO_N "(cached) $ECHO_C" >&6
19612else
19613  ac_check_lib_save_LIBS=$LIBS
19614LIBS="-lcrypto  $LIBS"
19615cat >conftest.$ac_ext <<_ACEOF
19616/* confdefs.h.  */
19617_ACEOF
19618cat confdefs.h >>conftest.$ac_ext
19619cat >>conftest.$ac_ext <<_ACEOF
19620/* end confdefs.h.  */
19621
19622/* Override any GCC internal prototype to avoid an error.
19623   Use char because int might match the return type of a GCC
19624   builtin and then its argument prototype would still apply.  */
19625#ifdef __cplusplus
19626extern "C"
19627#endif
19628char mit_des_cbc_encrypt ();
19629int
19630main ()
19631{
19632return mit_des_cbc_encrypt ();
19633  ;
19634  return 0;
19635}
19636_ACEOF
19637rm -f conftest.$ac_objext conftest$ac_exeext
19638if { (ac_try="$ac_link"
19639case "(($ac_try" in
19640  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19641  *) ac_try_echo=$ac_try;;
19642esac
19643eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19644  (eval "$ac_link") 2>conftest.er1
19645  ac_status=$?
19646  grep -v '^ *+' conftest.er1 >conftest.err
19647  rm -f conftest.er1
19648  cat conftest.err >&5
19649  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650  (exit $ac_status); } && {
19651	 test -z "$ac_c_werror_flag" ||
19652	 test ! -s conftest.err
19653       } && test -s conftest$ac_exeext &&
19654       $as_test_x conftest$ac_exeext; then
19655  ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
19656else
19657  echo "$as_me: failed program was:" >&5
19658sed 's/^/| /' conftest.$ac_ext >&5
19659
19660	ac_cv_lib_crypto_mit_des_cbc_encrypt=no
19661fi
19662
19663rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19664      conftest$ac_exeext conftest.$ac_ext
19665LIBS=$ac_check_lib_save_LIBS
19666fi
19667{ echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
19668echo "${ECHO_T}$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
19669if test $ac_cv_lib_crypto_mit_des_cbc_encrypt = yes; then
19670  cat >>confdefs.h <<_ACEOF
19671#define HAVE_LIBCRYPTO 1
19672_ACEOF
19673
19674  LIBS="-lcrypto $LIBS"
19675
19676fi
19677
19678
19679{ echo "$as_me:$LINENO: checking for krb5_init_context in -lkrb5" >&5
19680echo $ECHO_N "checking for krb5_init_context in -lkrb5... $ECHO_C" >&6; }
19681if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then
19682  echo $ECHO_N "(cached) $ECHO_C" >&6
19683else
19684  ac_check_lib_save_LIBS=$LIBS
19685LIBS="-lkrb5  $LIBS"
19686cat >conftest.$ac_ext <<_ACEOF
19687/* confdefs.h.  */
19688_ACEOF
19689cat confdefs.h >>conftest.$ac_ext
19690cat >>conftest.$ac_ext <<_ACEOF
19691/* end confdefs.h.  */
19692
19693/* Override any GCC internal prototype to avoid an error.
19694   Use char because int might match the return type of a GCC
19695   builtin and then its argument prototype would still apply.  */
19696#ifdef __cplusplus
19697extern "C"
19698#endif
19699char krb5_init_context ();
19700int
19701main ()
19702{
19703return krb5_init_context ();
19704  ;
19705  return 0;
19706}
19707_ACEOF
19708rm -f conftest.$ac_objext conftest$ac_exeext
19709if { (ac_try="$ac_link"
19710case "(($ac_try" in
19711  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19712  *) ac_try_echo=$ac_try;;
19713esac
19714eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19715  (eval "$ac_link") 2>conftest.er1
19716  ac_status=$?
19717  grep -v '^ *+' conftest.er1 >conftest.err
19718  rm -f conftest.er1
19719  cat conftest.err >&5
19720  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19721  (exit $ac_status); } && {
19722	 test -z "$ac_c_werror_flag" ||
19723	 test ! -s conftest.err
19724       } && test -s conftest$ac_exeext &&
19725       $as_test_x conftest$ac_exeext; then
19726  ac_cv_lib_krb5_krb5_init_context=yes
19727else
19728  echo "$as_me: failed program was:" >&5
19729sed 's/^/| /' conftest.$ac_ext >&5
19730
19731	ac_cv_lib_krb5_krb5_init_context=no
19732fi
19733
19734rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19735      conftest$ac_exeext conftest.$ac_ext
19736LIBS=$ac_check_lib_save_LIBS
19737fi
19738{ echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_krb5_init_context" >&5
19739echo "${ECHO_T}$ac_cv_lib_krb5_krb5_init_context" >&6; }
19740if test $ac_cv_lib_krb5_krb5_init_context = yes; then
19741  cat >>confdefs.h <<_ACEOF
19742#define HAVE_LIBKRB5 1
19743_ACEOF
19744
19745  LIBS="-lkrb5 $LIBS"
19746
19747fi
19748
19749  if test "${with_kerberos5+set}" != set; then
19750
19751{ echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes425" >&5
19752echo $ECHO_N "checking for des_cbc_encrypt in -ldes425... $ECHO_C" >&6; }
19753if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then
19754  echo $ECHO_N "(cached) $ECHO_C" >&6
19755else
19756  ac_check_lib_save_LIBS=$LIBS
19757LIBS="-ldes425  $LIBS"
19758cat >conftest.$ac_ext <<_ACEOF
19759/* confdefs.h.  */
19760_ACEOF
19761cat confdefs.h >>conftest.$ac_ext
19762cat >>conftest.$ac_ext <<_ACEOF
19763/* end confdefs.h.  */
19764
19765/* Override any GCC internal prototype to avoid an error.
19766   Use char because int might match the return type of a GCC
19767   builtin and then its argument prototype would still apply.  */
19768#ifdef __cplusplus
19769extern "C"
19770#endif
19771char des_cbc_encrypt ();
19772int
19773main ()
19774{
19775return des_cbc_encrypt ();
19776  ;
19777  return 0;
19778}
19779_ACEOF
19780rm -f conftest.$ac_objext conftest$ac_exeext
19781if { (ac_try="$ac_link"
19782case "(($ac_try" in
19783  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19784  *) ac_try_echo=$ac_try;;
19785esac
19786eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19787  (eval "$ac_link") 2>conftest.er1
19788  ac_status=$?
19789  grep -v '^ *+' conftest.er1 >conftest.err
19790  rm -f conftest.er1
19791  cat conftest.err >&5
19792  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19793  (exit $ac_status); } && {
19794	 test -z "$ac_c_werror_flag" ||
19795	 test ! -s conftest.err
19796       } && test -s conftest$ac_exeext &&
19797       $as_test_x conftest$ac_exeext; then
19798  ac_cv_lib_des425_des_cbc_encrypt=yes
19799else
19800  echo "$as_me: failed program was:" >&5
19801sed 's/^/| /' conftest.$ac_ext >&5
19802
19803	ac_cv_lib_des425_des_cbc_encrypt=no
19804fi
19805
19806rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19807      conftest$ac_exeext conftest.$ac_ext
19808LIBS=$ac_check_lib_save_LIBS
19809fi
19810{ echo "$as_me:$LINENO: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
19811echo "${ECHO_T}$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
19812if test $ac_cv_lib_des425_des_cbc_encrypt = yes; then
19813  cat >>confdefs.h <<_ACEOF
19814#define HAVE_LIBDES425 1
19815_ACEOF
19816
19817  LIBS="-ldes425 $LIBS"
19818
19819else
19820
19821{ echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5
19822echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6; }
19823if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then
19824  echo $ECHO_N "(cached) $ECHO_C" >&6
19825else
19826  ac_check_lib_save_LIBS=$LIBS
19827LIBS="-ldes  $LIBS"
19828cat >conftest.$ac_ext <<_ACEOF
19829/* confdefs.h.  */
19830_ACEOF
19831cat confdefs.h >>conftest.$ac_ext
19832cat >>conftest.$ac_ext <<_ACEOF
19833/* end confdefs.h.  */
19834
19835/* Override any GCC internal prototype to avoid an error.
19836   Use char because int might match the return type of a GCC
19837   builtin and then its argument prototype would still apply.  */
19838#ifdef __cplusplus
19839extern "C"
19840#endif
19841char des_cbc_encrypt ();
19842int
19843main ()
19844{
19845return des_cbc_encrypt ();
19846  ;
19847  return 0;
19848}
19849_ACEOF
19850rm -f conftest.$ac_objext conftest$ac_exeext
19851if { (ac_try="$ac_link"
19852case "(($ac_try" in
19853  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19854  *) ac_try_echo=$ac_try;;
19855esac
19856eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19857  (eval "$ac_link") 2>conftest.er1
19858  ac_status=$?
19859  grep -v '^ *+' conftest.er1 >conftest.err
19860  rm -f conftest.er1
19861  cat conftest.err >&5
19862  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19863  (exit $ac_status); } && {
19864	 test -z "$ac_c_werror_flag" ||
19865	 test ! -s conftest.err
19866       } && test -s conftest$ac_exeext &&
19867       $as_test_x conftest$ac_exeext; then
19868  ac_cv_lib_des_des_cbc_encrypt=yes
19869else
19870  echo "$as_me: failed program was:" >&5
19871sed 's/^/| /' conftest.$ac_ext >&5
19872
19873	ac_cv_lib_des_des_cbc_encrypt=no
19874fi
19875
19876rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19877      conftest$ac_exeext conftest.$ac_ext
19878LIBS=$ac_check_lib_save_LIBS
19879fi
19880{ echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
19881echo "${ECHO_T}$ac_cv_lib_des_des_cbc_encrypt" >&6; }
19882if test $ac_cv_lib_des_des_cbc_encrypt = yes; then
19883  cat >>confdefs.h <<_ACEOF
19884#define HAVE_LIBDES 1
19885_ACEOF
19886
19887  LIBS="-ldes $LIBS"
19888
19889fi
19890
19891fi
19892
19893
19894{ echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb4" >&5
19895echo $ECHO_N "checking for krb_get_cred in -lkrb4... $ECHO_C" >&6; }
19896if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then
19897  echo $ECHO_N "(cached) $ECHO_C" >&6
19898else
19899  ac_check_lib_save_LIBS=$LIBS
19900LIBS="-lkrb4  $LIBS"
19901cat >conftest.$ac_ext <<_ACEOF
19902/* confdefs.h.  */
19903_ACEOF
19904cat confdefs.h >>conftest.$ac_ext
19905cat >>conftest.$ac_ext <<_ACEOF
19906/* end confdefs.h.  */
19907
19908/* Override any GCC internal prototype to avoid an error.
19909   Use char because int might match the return type of a GCC
19910   builtin and then its argument prototype would still apply.  */
19911#ifdef __cplusplus
19912extern "C"
19913#endif
19914char krb_get_cred ();
19915int
19916main ()
19917{
19918return krb_get_cred ();
19919  ;
19920  return 0;
19921}
19922_ACEOF
19923rm -f conftest.$ac_objext conftest$ac_exeext
19924if { (ac_try="$ac_link"
19925case "(($ac_try" in
19926  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19927  *) ac_try_echo=$ac_try;;
19928esac
19929eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19930  (eval "$ac_link") 2>conftest.er1
19931  ac_status=$?
19932  grep -v '^ *+' conftest.er1 >conftest.err
19933  rm -f conftest.er1
19934  cat conftest.err >&5
19935  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19936  (exit $ac_status); } && {
19937	 test -z "$ac_c_werror_flag" ||
19938	 test ! -s conftest.err
19939       } && test -s conftest$ac_exeext &&
19940       $as_test_x conftest$ac_exeext; then
19941  ac_cv_lib_krb4_krb_get_cred=yes
19942else
19943  echo "$as_me: failed program was:" >&5
19944sed 's/^/| /' conftest.$ac_ext >&5
19945
19946	ac_cv_lib_krb4_krb_get_cred=no
19947fi
19948
19949rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19950      conftest$ac_exeext conftest.$ac_ext
19951LIBS=$ac_check_lib_save_LIBS
19952fi
19953{ echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_krb_get_cred" >&5
19954echo "${ECHO_T}$ac_cv_lib_krb4_krb_get_cred" >&6; }
19955if test $ac_cv_lib_krb4_krb_get_cred = yes; then
19956  cat >>confdefs.h <<_ACEOF
19957#define HAVE_LIBKRB4 1
19958_ACEOF
19959
19960  LIBS="-lkrb4 $LIBS"
19961
19962else
19963
19964{ echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb" >&5
19965echo $ECHO_N "checking for krb_get_cred in -lkrb... $ECHO_C" >&6; }
19966if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then
19967  echo $ECHO_N "(cached) $ECHO_C" >&6
19968else
19969  ac_check_lib_save_LIBS=$LIBS
19970LIBS="-lkrb  $LIBS"
19971cat >conftest.$ac_ext <<_ACEOF
19972/* confdefs.h.  */
19973_ACEOF
19974cat confdefs.h >>conftest.$ac_ext
19975cat >>conftest.$ac_ext <<_ACEOF
19976/* end confdefs.h.  */
19977
19978/* Override any GCC internal prototype to avoid an error.
19979   Use char because int might match the return type of a GCC
19980   builtin and then its argument prototype would still apply.  */
19981#ifdef __cplusplus
19982extern "C"
19983#endif
19984char krb_get_cred ();
19985int
19986main ()
19987{
19988return krb_get_cred ();
19989  ;
19990  return 0;
19991}
19992_ACEOF
19993rm -f conftest.$ac_objext conftest$ac_exeext
19994if { (ac_try="$ac_link"
19995case "(($ac_try" in
19996  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19997  *) ac_try_echo=$ac_try;;
19998esac
19999eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20000  (eval "$ac_link") 2>conftest.er1
20001  ac_status=$?
20002  grep -v '^ *+' conftest.er1 >conftest.err
20003  rm -f conftest.er1
20004  cat conftest.err >&5
20005  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20006  (exit $ac_status); } && {
20007	 test -z "$ac_c_werror_flag" ||
20008	 test ! -s conftest.err
20009       } && test -s conftest$ac_exeext &&
20010       $as_test_x conftest$ac_exeext; then
20011  ac_cv_lib_krb_krb_get_cred=yes
20012else
20013  echo "$as_me: failed program was:" >&5
20014sed 's/^/| /' conftest.$ac_ext >&5
20015
20016	ac_cv_lib_krb_krb_get_cred=no
20017fi
20018
20019rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20020      conftest$ac_exeext conftest.$ac_ext
20021LIBS=$ac_check_lib_save_LIBS
20022fi
20023{ echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_get_cred" >&5
20024echo "${ECHO_T}$ac_cv_lib_krb_krb_get_cred" >&6; }
20025if test $ac_cv_lib_krb_krb_get_cred = yes; then
20026  cat >>confdefs.h <<_ACEOF
20027#define HAVE_LIBKRB 1
20028_ACEOF
20029
20030  LIBS="-lkrb $LIBS"
20031
20032fi
20033
20034fi
20035
20036  fi
20037
20038  if test "${with_kerberos5+set}" = set; then
20039
20040for ac_header in krb5.h
20041do
20042as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20043if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20044  { echo "$as_me:$LINENO: checking for $ac_header" >&5
20045echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20046if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20047  echo $ECHO_N "(cached) $ECHO_C" >&6
20048fi
20049ac_res=`eval echo '${'$as_ac_Header'}'`
20050	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20051echo "${ECHO_T}$ac_res" >&6; }
20052else
20053  # Is the header compilable?
20054{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
20055echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
20056cat >conftest.$ac_ext <<_ACEOF
20057/* confdefs.h.  */
20058_ACEOF
20059cat confdefs.h >>conftest.$ac_ext
20060cat >>conftest.$ac_ext <<_ACEOF
20061/* end confdefs.h.  */
20062$ac_includes_default
20063#include <$ac_header>
20064_ACEOF
20065rm -f conftest.$ac_objext
20066if { (ac_try="$ac_compile"
20067case "(($ac_try" in
20068  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20069  *) ac_try_echo=$ac_try;;
20070esac
20071eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20072  (eval "$ac_compile") 2>conftest.er1
20073  ac_status=$?
20074  grep -v '^ *+' conftest.er1 >conftest.err
20075  rm -f conftest.er1
20076  cat conftest.err >&5
20077  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20078  (exit $ac_status); } && {
20079	 test -z "$ac_c_werror_flag" ||
20080	 test ! -s conftest.err
20081       } && test -s conftest.$ac_objext; then
20082  ac_header_compiler=yes
20083else
20084  echo "$as_me: failed program was:" >&5
20085sed 's/^/| /' conftest.$ac_ext >&5
20086
20087	ac_header_compiler=no
20088fi
20089
20090rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20091{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20092echo "${ECHO_T}$ac_header_compiler" >&6; }
20093
20094# Is the header present?
20095{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
20096echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
20097cat >conftest.$ac_ext <<_ACEOF
20098/* confdefs.h.  */
20099_ACEOF
20100cat confdefs.h >>conftest.$ac_ext
20101cat >>conftest.$ac_ext <<_ACEOF
20102/* end confdefs.h.  */
20103#include <$ac_header>
20104_ACEOF
20105if { (ac_try="$ac_cpp conftest.$ac_ext"
20106case "(($ac_try" in
20107  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20108  *) ac_try_echo=$ac_try;;
20109esac
20110eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20111  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
20112  ac_status=$?
20113  grep -v '^ *+' conftest.er1 >conftest.err
20114  rm -f conftest.er1
20115  cat conftest.err >&5
20116  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20117  (exit $ac_status); } >/dev/null && {
20118	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
20119	 test ! -s conftest.err
20120       }; then
20121  ac_header_preproc=yes
20122else
20123  echo "$as_me: failed program was:" >&5
20124sed 's/^/| /' conftest.$ac_ext >&5
20125
20126  ac_header_preproc=no
20127fi
20128
20129rm -f conftest.err conftest.$ac_ext
20130{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20131echo "${ECHO_T}$ac_header_preproc" >&6; }
20132
20133# So?  What about this header?
20134case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20135  yes:no: )
20136    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20137echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20138    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20139echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20140    ac_header_preproc=yes
20141    ;;
20142  no:yes:* )
20143    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20144echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20145    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
20146echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
20147    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20148echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20149    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
20150echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
20151    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20152echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20153    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20154echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
20155
20156    ;;
20157esac
20158{ echo "$as_me:$LINENO: checking for $ac_header" >&5
20159echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20160if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20161  echo $ECHO_N "(cached) $ECHO_C" >&6
20162else
20163  eval "$as_ac_Header=\$ac_header_preproc"
20164fi
20165ac_res=`eval echo '${'$as_ac_Header'}'`
20166	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20167echo "${ECHO_T}$ac_res" >&6; }
20168
20169fi
20170if test `eval echo '${'$as_ac_Header'}'` = yes; then
20171  cat >>confdefs.h <<_ACEOF
20172#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20173_ACEOF
20174
20175fi
20176
20177done
20178
20179  else
20180
20181for ac_header in des.h
20182do
20183as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20184if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20185  { echo "$as_me:$LINENO: checking for $ac_header" >&5
20186echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20187if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20188  echo $ECHO_N "(cached) $ECHO_C" >&6
20189fi
20190ac_res=`eval echo '${'$as_ac_Header'}'`
20191	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20192echo "${ECHO_T}$ac_res" >&6; }
20193else
20194  # Is the header compilable?
20195{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
20196echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
20197cat >conftest.$ac_ext <<_ACEOF
20198/* confdefs.h.  */
20199_ACEOF
20200cat confdefs.h >>conftest.$ac_ext
20201cat >>conftest.$ac_ext <<_ACEOF
20202/* end confdefs.h.  */
20203$ac_includes_default
20204#include <$ac_header>
20205_ACEOF
20206rm -f conftest.$ac_objext
20207if { (ac_try="$ac_compile"
20208case "(($ac_try" in
20209  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20210  *) ac_try_echo=$ac_try;;
20211esac
20212eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20213  (eval "$ac_compile") 2>conftest.er1
20214  ac_status=$?
20215  grep -v '^ *+' conftest.er1 >conftest.err
20216  rm -f conftest.er1
20217  cat conftest.err >&5
20218  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20219  (exit $ac_status); } && {
20220	 test -z "$ac_c_werror_flag" ||
20221	 test ! -s conftest.err
20222       } && test -s conftest.$ac_objext; then
20223  ac_header_compiler=yes
20224else
20225  echo "$as_me: failed program was:" >&5
20226sed 's/^/| /' conftest.$ac_ext >&5
20227
20228	ac_header_compiler=no
20229fi
20230
20231rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20232{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20233echo "${ECHO_T}$ac_header_compiler" >&6; }
20234
20235# Is the header present?
20236{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
20237echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
20238cat >conftest.$ac_ext <<_ACEOF
20239/* confdefs.h.  */
20240_ACEOF
20241cat confdefs.h >>conftest.$ac_ext
20242cat >>conftest.$ac_ext <<_ACEOF
20243/* end confdefs.h.  */
20244#include <$ac_header>
20245_ACEOF
20246if { (ac_try="$ac_cpp conftest.$ac_ext"
20247case "(($ac_try" in
20248  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20249  *) ac_try_echo=$ac_try;;
20250esac
20251eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20252  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
20253  ac_status=$?
20254  grep -v '^ *+' conftest.er1 >conftest.err
20255  rm -f conftest.er1
20256  cat conftest.err >&5
20257  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20258  (exit $ac_status); } >/dev/null && {
20259	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
20260	 test ! -s conftest.err
20261       }; then
20262  ac_header_preproc=yes
20263else
20264  echo "$as_me: failed program was:" >&5
20265sed 's/^/| /' conftest.$ac_ext >&5
20266
20267  ac_header_preproc=no
20268fi
20269
20270rm -f conftest.err conftest.$ac_ext
20271{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20272echo "${ECHO_T}$ac_header_preproc" >&6; }
20273
20274# So?  What about this header?
20275case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20276  yes:no: )
20277    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20278echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20279    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20280echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20281    ac_header_preproc=yes
20282    ;;
20283  no:yes:* )
20284    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20285echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20286    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
20287echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
20288    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20289echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20290    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
20291echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
20292    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20293echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20294    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20295echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
20296
20297    ;;
20298esac
20299{ echo "$as_me:$LINENO: checking for $ac_header" >&5
20300echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20301if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20302  echo $ECHO_N "(cached) $ECHO_C" >&6
20303else
20304  eval "$as_ac_Header=\$ac_header_preproc"
20305fi
20306ac_res=`eval echo '${'$as_ac_Header'}'`
20307	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20308echo "${ECHO_T}$ac_res" >&6; }
20309
20310fi
20311if test `eval echo '${'$as_ac_Header'}'` = yes; then
20312  cat >>confdefs.h <<_ACEOF
20313#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20314_ACEOF
20315
20316else
20317
20318for ac_header in kerberosIV/des.h
20319do
20320as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20321if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20322  { echo "$as_me:$LINENO: checking for $ac_header" >&5
20323echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20324if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20325  echo $ECHO_N "(cached) $ECHO_C" >&6
20326fi
20327ac_res=`eval echo '${'$as_ac_Header'}'`
20328	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20329echo "${ECHO_T}$ac_res" >&6; }
20330else
20331  # Is the header compilable?
20332{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
20333echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
20334cat >conftest.$ac_ext <<_ACEOF
20335/* confdefs.h.  */
20336_ACEOF
20337cat confdefs.h >>conftest.$ac_ext
20338cat >>conftest.$ac_ext <<_ACEOF
20339/* end confdefs.h.  */
20340$ac_includes_default
20341#include <$ac_header>
20342_ACEOF
20343rm -f conftest.$ac_objext
20344if { (ac_try="$ac_compile"
20345case "(($ac_try" in
20346  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20347  *) ac_try_echo=$ac_try;;
20348esac
20349eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20350  (eval "$ac_compile") 2>conftest.er1
20351  ac_status=$?
20352  grep -v '^ *+' conftest.er1 >conftest.err
20353  rm -f conftest.er1
20354  cat conftest.err >&5
20355  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20356  (exit $ac_status); } && {
20357	 test -z "$ac_c_werror_flag" ||
20358	 test ! -s conftest.err
20359       } && test -s conftest.$ac_objext; then
20360  ac_header_compiler=yes
20361else
20362  echo "$as_me: failed program was:" >&5
20363sed 's/^/| /' conftest.$ac_ext >&5
20364
20365	ac_header_compiler=no
20366fi
20367
20368rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20369{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20370echo "${ECHO_T}$ac_header_compiler" >&6; }
20371
20372# Is the header present?
20373{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
20374echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
20375cat >conftest.$ac_ext <<_ACEOF
20376/* confdefs.h.  */
20377_ACEOF
20378cat confdefs.h >>conftest.$ac_ext
20379cat >>conftest.$ac_ext <<_ACEOF
20380/* end confdefs.h.  */
20381#include <$ac_header>
20382_ACEOF
20383if { (ac_try="$ac_cpp conftest.$ac_ext"
20384case "(($ac_try" in
20385  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20386  *) ac_try_echo=$ac_try;;
20387esac
20388eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20389  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
20390  ac_status=$?
20391  grep -v '^ *+' conftest.er1 >conftest.err
20392  rm -f conftest.er1
20393  cat conftest.err >&5
20394  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20395  (exit $ac_status); } >/dev/null && {
20396	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
20397	 test ! -s conftest.err
20398       }; then
20399  ac_header_preproc=yes
20400else
20401  echo "$as_me: failed program was:" >&5
20402sed 's/^/| /' conftest.$ac_ext >&5
20403
20404  ac_header_preproc=no
20405fi
20406
20407rm -f conftest.err conftest.$ac_ext
20408{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20409echo "${ECHO_T}$ac_header_preproc" >&6; }
20410
20411# So?  What about this header?
20412case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20413  yes:no: )
20414    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20415echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20416    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20417echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20418    ac_header_preproc=yes
20419    ;;
20420  no:yes:* )
20421    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20422echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20423    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
20424echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
20425    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20426echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20427    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
20428echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
20429    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20430echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20431    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20432echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
20433
20434    ;;
20435esac
20436{ echo "$as_me:$LINENO: checking for $ac_header" >&5
20437echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20438if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20439  echo $ECHO_N "(cached) $ECHO_C" >&6
20440else
20441  eval "$as_ac_Header=\$ac_header_preproc"
20442fi
20443ac_res=`eval echo '${'$as_ac_Header'}'`
20444	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20445echo "${ECHO_T}$ac_res" >&6; }
20446
20447fi
20448if test `eval echo '${'$as_ac_Header'}'` = yes; then
20449  cat >>confdefs.h <<_ACEOF
20450#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20451_ACEOF
20452
20453else
20454
20455for ac_header in kerberos/des.h
20456do
20457as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20458if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20459  { echo "$as_me:$LINENO: checking for $ac_header" >&5
20460echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20461if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20462  echo $ECHO_N "(cached) $ECHO_C" >&6
20463fi
20464ac_res=`eval echo '${'$as_ac_Header'}'`
20465	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20466echo "${ECHO_T}$ac_res" >&6; }
20467else
20468  # Is the header compilable?
20469{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
20470echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
20471cat >conftest.$ac_ext <<_ACEOF
20472/* confdefs.h.  */
20473_ACEOF
20474cat confdefs.h >>conftest.$ac_ext
20475cat >>conftest.$ac_ext <<_ACEOF
20476/* end confdefs.h.  */
20477$ac_includes_default
20478#include <$ac_header>
20479_ACEOF
20480rm -f conftest.$ac_objext
20481if { (ac_try="$ac_compile"
20482case "(($ac_try" in
20483  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20484  *) ac_try_echo=$ac_try;;
20485esac
20486eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20487  (eval "$ac_compile") 2>conftest.er1
20488  ac_status=$?
20489  grep -v '^ *+' conftest.er1 >conftest.err
20490  rm -f conftest.er1
20491  cat conftest.err >&5
20492  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20493  (exit $ac_status); } && {
20494	 test -z "$ac_c_werror_flag" ||
20495	 test ! -s conftest.err
20496       } && test -s conftest.$ac_objext; then
20497  ac_header_compiler=yes
20498else
20499  echo "$as_me: failed program was:" >&5
20500sed 's/^/| /' conftest.$ac_ext >&5
20501
20502	ac_header_compiler=no
20503fi
20504
20505rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20506{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20507echo "${ECHO_T}$ac_header_compiler" >&6; }
20508
20509# Is the header present?
20510{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
20511echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
20512cat >conftest.$ac_ext <<_ACEOF
20513/* confdefs.h.  */
20514_ACEOF
20515cat confdefs.h >>conftest.$ac_ext
20516cat >>conftest.$ac_ext <<_ACEOF
20517/* end confdefs.h.  */
20518#include <$ac_header>
20519_ACEOF
20520if { (ac_try="$ac_cpp conftest.$ac_ext"
20521case "(($ac_try" in
20522  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20523  *) ac_try_echo=$ac_try;;
20524esac
20525eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20526  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
20527  ac_status=$?
20528  grep -v '^ *+' conftest.er1 >conftest.err
20529  rm -f conftest.er1
20530  cat conftest.err >&5
20531  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20532  (exit $ac_status); } >/dev/null && {
20533	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
20534	 test ! -s conftest.err
20535       }; then
20536  ac_header_preproc=yes
20537else
20538  echo "$as_me: failed program was:" >&5
20539sed 's/^/| /' conftest.$ac_ext >&5
20540
20541  ac_header_preproc=no
20542fi
20543
20544rm -f conftest.err conftest.$ac_ext
20545{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20546echo "${ECHO_T}$ac_header_preproc" >&6; }
20547
20548# So?  What about this header?
20549case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20550  yes:no: )
20551    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20552echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20553    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20554echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20555    ac_header_preproc=yes
20556    ;;
20557  no:yes:* )
20558    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20559echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20560    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
20561echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
20562    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20563echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20564    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
20565echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
20566    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20567echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20568    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20569echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
20570
20571    ;;
20572esac
20573{ echo "$as_me:$LINENO: checking for $ac_header" >&5
20574echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20575if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20576  echo $ECHO_N "(cached) $ECHO_C" >&6
20577else
20578  eval "$as_ac_Header=\$ac_header_preproc"
20579fi
20580ac_res=`eval echo '${'$as_ac_Header'}'`
20581	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20582echo "${ECHO_T}$ac_res" >&6; }
20583
20584fi
20585if test `eval echo '${'$as_ac_Header'}'` = yes; then
20586  cat >>confdefs.h <<_ACEOF
20587#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20588_ACEOF
20589
20590fi
20591
20592done
20593
20594fi
20595
20596done
20597
20598fi
20599
20600done
20601
20602
20603for ac_header in krb.h
20604do
20605as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20606if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20607  { echo "$as_me:$LINENO: checking for $ac_header" >&5
20608echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20609if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20610  echo $ECHO_N "(cached) $ECHO_C" >&6
20611fi
20612ac_res=`eval echo '${'$as_ac_Header'}'`
20613	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20614echo "${ECHO_T}$ac_res" >&6; }
20615else
20616  # Is the header compilable?
20617{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
20618echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
20619cat >conftest.$ac_ext <<_ACEOF
20620/* confdefs.h.  */
20621_ACEOF
20622cat confdefs.h >>conftest.$ac_ext
20623cat >>conftest.$ac_ext <<_ACEOF
20624/* end confdefs.h.  */
20625$ac_includes_default
20626#include <$ac_header>
20627_ACEOF
20628rm -f conftest.$ac_objext
20629if { (ac_try="$ac_compile"
20630case "(($ac_try" in
20631  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20632  *) ac_try_echo=$ac_try;;
20633esac
20634eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20635  (eval "$ac_compile") 2>conftest.er1
20636  ac_status=$?
20637  grep -v '^ *+' conftest.er1 >conftest.err
20638  rm -f conftest.er1
20639  cat conftest.err >&5
20640  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20641  (exit $ac_status); } && {
20642	 test -z "$ac_c_werror_flag" ||
20643	 test ! -s conftest.err
20644       } && test -s conftest.$ac_objext; then
20645  ac_header_compiler=yes
20646else
20647  echo "$as_me: failed program was:" >&5
20648sed 's/^/| /' conftest.$ac_ext >&5
20649
20650	ac_header_compiler=no
20651fi
20652
20653rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20654{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20655echo "${ECHO_T}$ac_header_compiler" >&6; }
20656
20657# Is the header present?
20658{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
20659echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
20660cat >conftest.$ac_ext <<_ACEOF
20661/* confdefs.h.  */
20662_ACEOF
20663cat confdefs.h >>conftest.$ac_ext
20664cat >>conftest.$ac_ext <<_ACEOF
20665/* end confdefs.h.  */
20666#include <$ac_header>
20667_ACEOF
20668if { (ac_try="$ac_cpp conftest.$ac_ext"
20669case "(($ac_try" in
20670  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20671  *) ac_try_echo=$ac_try;;
20672esac
20673eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20674  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
20675  ac_status=$?
20676  grep -v '^ *+' conftest.er1 >conftest.err
20677  rm -f conftest.er1
20678  cat conftest.err >&5
20679  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20680  (exit $ac_status); } >/dev/null && {
20681	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
20682	 test ! -s conftest.err
20683       }; then
20684  ac_header_preproc=yes
20685else
20686  echo "$as_me: failed program was:" >&5
20687sed 's/^/| /' conftest.$ac_ext >&5
20688
20689  ac_header_preproc=no
20690fi
20691
20692rm -f conftest.err conftest.$ac_ext
20693{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20694echo "${ECHO_T}$ac_header_preproc" >&6; }
20695
20696# So?  What about this header?
20697case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20698  yes:no: )
20699    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20700echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20701    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20702echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20703    ac_header_preproc=yes
20704    ;;
20705  no:yes:* )
20706    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20707echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20708    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
20709echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
20710    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20711echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20712    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
20713echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
20714    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20715echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20716    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20717echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
20718
20719    ;;
20720esac
20721{ echo "$as_me:$LINENO: checking for $ac_header" >&5
20722echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20723if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20724  echo $ECHO_N "(cached) $ECHO_C" >&6
20725else
20726  eval "$as_ac_Header=\$ac_header_preproc"
20727fi
20728ac_res=`eval echo '${'$as_ac_Header'}'`
20729	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20730echo "${ECHO_T}$ac_res" >&6; }
20731
20732fi
20733if test `eval echo '${'$as_ac_Header'}'` = yes; then
20734  cat >>confdefs.h <<_ACEOF
20735#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20736_ACEOF
20737
20738else
20739
20740for ac_header in kerberosIV/krb.h
20741do
20742as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20743if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20744  { echo "$as_me:$LINENO: checking for $ac_header" >&5
20745echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20746if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20747  echo $ECHO_N "(cached) $ECHO_C" >&6
20748fi
20749ac_res=`eval echo '${'$as_ac_Header'}'`
20750	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20751echo "${ECHO_T}$ac_res" >&6; }
20752else
20753  # Is the header compilable?
20754{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
20755echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
20756cat >conftest.$ac_ext <<_ACEOF
20757/* confdefs.h.  */
20758_ACEOF
20759cat confdefs.h >>conftest.$ac_ext
20760cat >>conftest.$ac_ext <<_ACEOF
20761/* end confdefs.h.  */
20762$ac_includes_default
20763#include <$ac_header>
20764_ACEOF
20765rm -f conftest.$ac_objext
20766if { (ac_try="$ac_compile"
20767case "(($ac_try" in
20768  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20769  *) ac_try_echo=$ac_try;;
20770esac
20771eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20772  (eval "$ac_compile") 2>conftest.er1
20773  ac_status=$?
20774  grep -v '^ *+' conftest.er1 >conftest.err
20775  rm -f conftest.er1
20776  cat conftest.err >&5
20777  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20778  (exit $ac_status); } && {
20779	 test -z "$ac_c_werror_flag" ||
20780	 test ! -s conftest.err
20781       } && test -s conftest.$ac_objext; then
20782  ac_header_compiler=yes
20783else
20784  echo "$as_me: failed program was:" >&5
20785sed 's/^/| /' conftest.$ac_ext >&5
20786
20787	ac_header_compiler=no
20788fi
20789
20790rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20791{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20792echo "${ECHO_T}$ac_header_compiler" >&6; }
20793
20794# Is the header present?
20795{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
20796echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
20797cat >conftest.$ac_ext <<_ACEOF
20798/* confdefs.h.  */
20799_ACEOF
20800cat confdefs.h >>conftest.$ac_ext
20801cat >>conftest.$ac_ext <<_ACEOF
20802/* end confdefs.h.  */
20803#include <$ac_header>
20804_ACEOF
20805if { (ac_try="$ac_cpp conftest.$ac_ext"
20806case "(($ac_try" in
20807  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20808  *) ac_try_echo=$ac_try;;
20809esac
20810eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20811  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
20812  ac_status=$?
20813  grep -v '^ *+' conftest.er1 >conftest.err
20814  rm -f conftest.er1
20815  cat conftest.err >&5
20816  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20817  (exit $ac_status); } >/dev/null && {
20818	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
20819	 test ! -s conftest.err
20820       }; then
20821  ac_header_preproc=yes
20822else
20823  echo "$as_me: failed program was:" >&5
20824sed 's/^/| /' conftest.$ac_ext >&5
20825
20826  ac_header_preproc=no
20827fi
20828
20829rm -f conftest.err conftest.$ac_ext
20830{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20831echo "${ECHO_T}$ac_header_preproc" >&6; }
20832
20833# So?  What about this header?
20834case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20835  yes:no: )
20836    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20837echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20838    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20839echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20840    ac_header_preproc=yes
20841    ;;
20842  no:yes:* )
20843    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20844echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20845    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
20846echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
20847    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20848echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20849    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
20850echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
20851    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20852echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20853    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20854echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
20855
20856    ;;
20857esac
20858{ echo "$as_me:$LINENO: checking for $ac_header" >&5
20859echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20860if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20861  echo $ECHO_N "(cached) $ECHO_C" >&6
20862else
20863  eval "$as_ac_Header=\$ac_header_preproc"
20864fi
20865ac_res=`eval echo '${'$as_ac_Header'}'`
20866	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20867echo "${ECHO_T}$ac_res" >&6; }
20868
20869fi
20870if test `eval echo '${'$as_ac_Header'}'` = yes; then
20871  cat >>confdefs.h <<_ACEOF
20872#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20873_ACEOF
20874
20875else
20876
20877for ac_header in kerberos/krb.h
20878do
20879as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20880if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20881  { echo "$as_me:$LINENO: checking for $ac_header" >&5
20882echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20883if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20884  echo $ECHO_N "(cached) $ECHO_C" >&6
20885fi
20886ac_res=`eval echo '${'$as_ac_Header'}'`
20887	       { echo "$as_me:$LINENO: result: $ac_res" >&5
20888echo "${ECHO_T}$ac_res" >&6; }
20889else
20890  # Is the header compilable?
20891{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
20892echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
20893cat >conftest.$ac_ext <<_ACEOF
20894/* confdefs.h.  */
20895_ACEOF
20896cat confdefs.h >>conftest.$ac_ext
20897cat >>conftest.$ac_ext <<_ACEOF
20898/* end confdefs.h.  */
20899$ac_includes_default
20900#include <$ac_header>
20901_ACEOF
20902rm -f conftest.$ac_objext
20903if { (ac_try="$ac_compile"
20904case "(($ac_try" in
20905  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20906  *) ac_try_echo=$ac_try;;
20907esac
20908eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20909  (eval "$ac_compile") 2>conftest.er1
20910  ac_status=$?
20911  grep -v '^ *+' conftest.er1 >conftest.err
20912  rm -f conftest.er1
20913  cat conftest.err >&5
20914  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20915  (exit $ac_status); } && {
20916	 test -z "$ac_c_werror_flag" ||
20917	 test ! -s conftest.err
20918       } && test -s conftest.$ac_objext; then
20919  ac_header_compiler=yes
20920else
20921  echo "$as_me: failed program was:" >&5
20922sed 's/^/| /' conftest.$ac_ext >&5
20923
20924	ac_header_compiler=no
20925fi
20926
20927rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20928{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20929echo "${ECHO_T}$ac_header_compiler" >&6; }
20930
20931# Is the header present?
20932{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
20933echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
20934cat >conftest.$ac_ext <<_ACEOF
20935/* confdefs.h.  */
20936_ACEOF
20937cat confdefs.h >>conftest.$ac_ext
20938cat >>conftest.$ac_ext <<_ACEOF
20939/* end confdefs.h.  */
20940#include <$ac_header>
20941_ACEOF
20942if { (ac_try="$ac_cpp conftest.$ac_ext"
20943case "(($ac_try" in
20944  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20945  *) ac_try_echo=$ac_try;;
20946esac
20947eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20948  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
20949  ac_status=$?
20950  grep -v '^ *+' conftest.er1 >conftest.err
20951  rm -f conftest.er1
20952  cat conftest.err >&5
20953  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20954  (exit $ac_status); } >/dev/null && {
20955	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
20956	 test ! -s conftest.err
20957       }; then
20958  ac_header_preproc=yes
20959else
20960  echo "$as_me: failed program was:" >&5
20961sed 's/^/| /' conftest.$ac_ext >&5
20962
20963  ac_header_preproc=no
20964fi
20965
20966rm -f conftest.err conftest.$ac_ext
20967{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20968echo "${ECHO_T}$ac_header_preproc" >&6; }
20969
20970# So?  What about this header?
20971case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20972  yes:no: )
20973    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20974echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20975    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20976echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20977    ac_header_preproc=yes
20978    ;;
20979  no:yes:* )
20980    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20981echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20982    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
20983echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
20984    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20985echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20986    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
20987echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
20988    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20989echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20990    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20991echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
20992
20993    ;;
20994esac
20995{ echo "$as_me:$LINENO: checking for $ac_header" >&5
20996echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
20997if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
20998  echo $ECHO_N "(cached) $ECHO_C" >&6
20999else
21000  eval "$as_ac_Header=\$ac_header_preproc"
21001fi
21002ac_res=`eval echo '${'$as_ac_Header'}'`
21003	       { echo "$as_me:$LINENO: result: $ac_res" >&5
21004echo "${ECHO_T}$ac_res" >&6; }
21005
21006fi
21007if test `eval echo '${'$as_ac_Header'}'` = yes; then
21008  cat >>confdefs.h <<_ACEOF
21009#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
21010_ACEOF
21011
21012fi
21013
21014done
21015
21016fi
21017
21018done
21019
21020fi
21021
21022done
21023
21024  fi
21025
21026for ac_header in com_err.h
21027do
21028as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
21029if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
21030  { echo "$as_me:$LINENO: checking for $ac_header" >&5
21031echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
21032if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
21033  echo $ECHO_N "(cached) $ECHO_C" >&6
21034fi
21035ac_res=`eval echo '${'$as_ac_Header'}'`
21036	       { echo "$as_me:$LINENO: result: $ac_res" >&5
21037echo "${ECHO_T}$ac_res" >&6; }
21038else
21039  # Is the header compilable?
21040{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
21041echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
21042cat >conftest.$ac_ext <<_ACEOF
21043/* confdefs.h.  */
21044_ACEOF
21045cat confdefs.h >>conftest.$ac_ext
21046cat >>conftest.$ac_ext <<_ACEOF
21047/* end confdefs.h.  */
21048$ac_includes_default
21049#include <$ac_header>
21050_ACEOF
21051rm -f conftest.$ac_objext
21052if { (ac_try="$ac_compile"
21053case "(($ac_try" in
21054  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21055  *) ac_try_echo=$ac_try;;
21056esac
21057eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21058  (eval "$ac_compile") 2>conftest.er1
21059  ac_status=$?
21060  grep -v '^ *+' conftest.er1 >conftest.err
21061  rm -f conftest.er1
21062  cat conftest.err >&5
21063  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21064  (exit $ac_status); } && {
21065	 test -z "$ac_c_werror_flag" ||
21066	 test ! -s conftest.err
21067       } && test -s conftest.$ac_objext; then
21068  ac_header_compiler=yes
21069else
21070  echo "$as_me: failed program was:" >&5
21071sed 's/^/| /' conftest.$ac_ext >&5
21072
21073	ac_header_compiler=no
21074fi
21075
21076rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21077{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21078echo "${ECHO_T}$ac_header_compiler" >&6; }
21079
21080# Is the header present?
21081{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
21082echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
21083cat >conftest.$ac_ext <<_ACEOF
21084/* confdefs.h.  */
21085_ACEOF
21086cat confdefs.h >>conftest.$ac_ext
21087cat >>conftest.$ac_ext <<_ACEOF
21088/* end confdefs.h.  */
21089#include <$ac_header>
21090_ACEOF
21091if { (ac_try="$ac_cpp conftest.$ac_ext"
21092case "(($ac_try" in
21093  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21094  *) ac_try_echo=$ac_try;;
21095esac
21096eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21097  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
21098  ac_status=$?
21099  grep -v '^ *+' conftest.er1 >conftest.err
21100  rm -f conftest.er1
21101  cat conftest.err >&5
21102  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21103  (exit $ac_status); } >/dev/null && {
21104	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
21105	 test ! -s conftest.err
21106       }; then
21107  ac_header_preproc=yes
21108else
21109  echo "$as_me: failed program was:" >&5
21110sed 's/^/| /' conftest.$ac_ext >&5
21111
21112  ac_header_preproc=no
21113fi
21114
21115rm -f conftest.err conftest.$ac_ext
21116{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21117echo "${ECHO_T}$ac_header_preproc" >&6; }
21118
21119# So?  What about this header?
21120case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21121  yes:no: )
21122    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21123echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
21124    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
21125echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
21126    ac_header_preproc=yes
21127    ;;
21128  no:yes:* )
21129    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
21130echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
21131    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
21132echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
21133    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
21134echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
21135    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
21136echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
21137    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21138echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21139    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
21140echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
21141
21142    ;;
21143esac
21144{ echo "$as_me:$LINENO: checking for $ac_header" >&5
21145echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
21146if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
21147  echo $ECHO_N "(cached) $ECHO_C" >&6
21148else
21149  eval "$as_ac_Header=\$ac_header_preproc"
21150fi
21151ac_res=`eval echo '${'$as_ac_Header'}'`
21152	       { echo "$as_me:$LINENO: result: $ac_res" >&5
21153echo "${ECHO_T}$ac_res" >&6; }
21154
21155fi
21156if test `eval echo '${'$as_ac_Header'}'` = yes; then
21157  cat >>confdefs.h <<_ACEOF
21158#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
21159_ACEOF
21160
21161fi
21162
21163done
21164
21165fi
21166
21167# Solaris requires -lintl if you want strerror (which calls dgettext)
21168# to return localized messages.
21169
21170{ echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5
21171echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6; }
21172if test "${ac_cv_lib_intl_dgettext+set}" = set; then
21173  echo $ECHO_N "(cached) $ECHO_C" >&6
21174else
21175  ac_check_lib_save_LIBS=$LIBS
21176LIBS="-lintl  $LIBS"
21177cat >conftest.$ac_ext <<_ACEOF
21178/* confdefs.h.  */
21179_ACEOF
21180cat confdefs.h >>conftest.$ac_ext
21181cat >>conftest.$ac_ext <<_ACEOF
21182/* end confdefs.h.  */
21183
21184/* Override any GCC internal prototype to avoid an error.
21185   Use char because int might match the return type of a GCC
21186   builtin and then its argument prototype would still apply.  */
21187#ifdef __cplusplus
21188extern "C"
21189#endif
21190char dgettext ();
21191int
21192main ()
21193{
21194return dgettext ();
21195  ;
21196  return 0;
21197}
21198_ACEOF
21199rm -f conftest.$ac_objext conftest$ac_exeext
21200if { (ac_try="$ac_link"
21201case "(($ac_try" in
21202  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21203  *) ac_try_echo=$ac_try;;
21204esac
21205eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21206  (eval "$ac_link") 2>conftest.er1
21207  ac_status=$?
21208  grep -v '^ *+' conftest.er1 >conftest.err
21209  rm -f conftest.er1
21210  cat conftest.err >&5
21211  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21212  (exit $ac_status); } && {
21213	 test -z "$ac_c_werror_flag" ||
21214	 test ! -s conftest.err
21215       } && test -s conftest$ac_exeext &&
21216       $as_test_x conftest$ac_exeext; then
21217  ac_cv_lib_intl_dgettext=yes
21218else
21219  echo "$as_me: failed program was:" >&5
21220sed 's/^/| /' conftest.$ac_ext >&5
21221
21222	ac_cv_lib_intl_dgettext=no
21223fi
21224
21225rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21226      conftest$ac_exeext conftest.$ac_ext
21227LIBS=$ac_check_lib_save_LIBS
21228fi
21229{ echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5
21230echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6; }
21231if test $ac_cv_lib_intl_dgettext = yes; then
21232  cat >>confdefs.h <<_ACEOF
21233#define HAVE_LIBINTL 1
21234_ACEOF
21235
21236  LIBS="-lintl $LIBS"
21237
21238fi
21239
21240
21241{ echo "$as_me:$LINENO: checking whether localtime caches TZ" >&5
21242echo $ECHO_N "checking whether localtime caches TZ... $ECHO_C" >&6; }
21243if test "${emacs_cv_localtime_cache+set}" = set; then
21244  echo $ECHO_N "(cached) $ECHO_C" >&6
21245else
21246  if test x$ac_cv_func_tzset = xyes; then
21247if test "$cross_compiling" = yes; then
21248  # If we have tzset, assume the worst when cross-compiling.
21249emacs_cv_localtime_cache=yes
21250else
21251  cat >conftest.$ac_ext <<_ACEOF
21252/* confdefs.h.  */
21253_ACEOF
21254cat confdefs.h >>conftest.$ac_ext
21255cat >>conftest.$ac_ext <<_ACEOF
21256/* end confdefs.h.  */
21257#include <time.h>
21258extern char **environ;
21259unset_TZ ()
21260{
21261  char **from, **to;
21262  for (to = from = environ; (*to = *from); from++)
21263    if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
21264      to++;
21265}
21266char TZ_GMT0[] = "TZ=GMT0";
21267char TZ_PST8[] = "TZ=PST8";
21268main()
21269{
21270  time_t now = time ((time_t *) 0);
21271  int hour_GMT0, hour_unset;
21272  if (putenv (TZ_GMT0) != 0)
21273    exit (1);
21274  hour_GMT0 = localtime (&now)->tm_hour;
21275  unset_TZ ();
21276  hour_unset = localtime (&now)->tm_hour;
21277  if (putenv (TZ_PST8) != 0)
21278    exit (1);
21279  if (localtime (&now)->tm_hour == hour_GMT0)
21280    exit (1);
21281  unset_TZ ();
21282  if (localtime (&now)->tm_hour != hour_unset)
21283    exit (1);
21284  exit (0);
21285}
21286_ACEOF
21287rm -f conftest$ac_exeext
21288if { (ac_try="$ac_link"
21289case "(($ac_try" in
21290  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21291  *) ac_try_echo=$ac_try;;
21292esac
21293eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21294  (eval "$ac_link") 2>&5
21295  ac_status=$?
21296  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21297  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21298  { (case "(($ac_try" in
21299  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21300  *) ac_try_echo=$ac_try;;
21301esac
21302eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21303  (eval "$ac_try") 2>&5
21304  ac_status=$?
21305  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21306  (exit $ac_status); }; }; then
21307  emacs_cv_localtime_cache=no
21308else
21309  echo "$as_me: program exited with status $ac_status" >&5
21310echo "$as_me: failed program was:" >&5
21311sed 's/^/| /' conftest.$ac_ext >&5
21312
21313( exit $ac_status )
21314emacs_cv_localtime_cache=yes
21315fi
21316rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21317fi
21318
21319
21320else
21321	# If we lack tzset, report that localtime does not cache TZ,
21322	# since we can't invalidate the cache if we don't have tzset.
21323	emacs_cv_localtime_cache=no
21324fi
21325fi
21326{ echo "$as_me:$LINENO: result: $emacs_cv_localtime_cache" >&5
21327echo "${ECHO_T}$emacs_cv_localtime_cache" >&6; }
21328if test $emacs_cv_localtime_cache = yes; then
21329
21330cat >>confdefs.h <<\_ACEOF
21331#define LOCALTIME_CACHE 1
21332_ACEOF
21333
21334fi
21335
21336if test "x$HAVE_TIMEVAL" = xyes; then
21337
21338for ac_func in gettimeofday
21339do
21340as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21341{ echo "$as_me:$LINENO: checking for $ac_func" >&5
21342echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
21343if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21344  echo $ECHO_N "(cached) $ECHO_C" >&6
21345else
21346  cat >conftest.$ac_ext <<_ACEOF
21347/* confdefs.h.  */
21348_ACEOF
21349cat confdefs.h >>conftest.$ac_ext
21350cat >>conftest.$ac_ext <<_ACEOF
21351/* end confdefs.h.  */
21352/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21353   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21354#define $ac_func innocuous_$ac_func
21355
21356/* System header to define __stub macros and hopefully few prototypes,
21357    which can conflict with char $ac_func (); below.
21358    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21359    <limits.h> exists even on freestanding compilers.  */
21360
21361#ifdef __STDC__
21362# include <limits.h>
21363#else
21364# include <assert.h>
21365#endif
21366
21367#undef $ac_func
21368
21369/* Override any GCC internal prototype to avoid an error.
21370   Use char because int might match the return type of a GCC
21371   builtin and then its argument prototype would still apply.  */
21372#ifdef __cplusplus
21373extern "C"
21374#endif
21375char $ac_func ();
21376/* The GNU C library defines this for functions which it implements
21377    to always fail with ENOSYS.  Some functions are actually named
21378    something starting with __ and the normal name is an alias.  */
21379#if defined __stub_$ac_func || defined __stub___$ac_func
21380choke me
21381#endif
21382
21383int
21384main ()
21385{
21386return $ac_func ();
21387  ;
21388  return 0;
21389}
21390_ACEOF
21391rm -f conftest.$ac_objext conftest$ac_exeext
21392if { (ac_try="$ac_link"
21393case "(($ac_try" in
21394  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21395  *) ac_try_echo=$ac_try;;
21396esac
21397eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21398  (eval "$ac_link") 2>conftest.er1
21399  ac_status=$?
21400  grep -v '^ *+' conftest.er1 >conftest.err
21401  rm -f conftest.er1
21402  cat conftest.err >&5
21403  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21404  (exit $ac_status); } && {
21405	 test -z "$ac_c_werror_flag" ||
21406	 test ! -s conftest.err
21407       } && test -s conftest$ac_exeext &&
21408       $as_test_x conftest$ac_exeext; then
21409  eval "$as_ac_var=yes"
21410else
21411  echo "$as_me: failed program was:" >&5
21412sed 's/^/| /' conftest.$ac_ext >&5
21413
21414	eval "$as_ac_var=no"
21415fi
21416
21417rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21418      conftest$ac_exeext conftest.$ac_ext
21419fi
21420ac_res=`eval echo '${'$as_ac_var'}'`
21421	       { echo "$as_me:$LINENO: result: $ac_res" >&5
21422echo "${ECHO_T}$ac_res" >&6; }
21423if test `eval echo '${'$as_ac_var'}'` = yes; then
21424  cat >>confdefs.h <<_ACEOF
21425#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21426_ACEOF
21427
21428fi
21429done
21430
21431  if test $ac_cv_func_gettimeofday = yes; then
21432    { echo "$as_me:$LINENO: checking whether gettimeofday can accept two arguments" >&5
21433echo $ECHO_N "checking whether gettimeofday can accept two arguments... $ECHO_C" >&6; }
21434if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then
21435  echo $ECHO_N "(cached) $ECHO_C" >&6
21436else
21437  cat >conftest.$ac_ext <<_ACEOF
21438/* confdefs.h.  */
21439_ACEOF
21440cat confdefs.h >>conftest.$ac_ext
21441cat >>conftest.$ac_ext <<_ACEOF
21442/* end confdefs.h.  */
21443
21444#ifdef TIME_WITH_SYS_TIME
21445#include <sys/time.h>
21446#include <time.h>
21447#else
21448#ifdef HAVE_SYS_TIME_H
21449#include <sys/time.h>
21450#else
21451#include <time.h>
21452#endif
21453#endif
21454int
21455main ()
21456{
21457struct timeval time;
21458       gettimeofday (&time, 0);
21459  ;
21460  return 0;
21461}
21462_ACEOF
21463rm -f conftest.$ac_objext
21464if { (ac_try="$ac_compile"
21465case "(($ac_try" in
21466  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21467  *) ac_try_echo=$ac_try;;
21468esac
21469eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21470  (eval "$ac_compile") 2>conftest.er1
21471  ac_status=$?
21472  grep -v '^ *+' conftest.er1 >conftest.err
21473  rm -f conftest.er1
21474  cat conftest.err >&5
21475  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21476  (exit $ac_status); } && {
21477	 test -z "$ac_c_werror_flag" ||
21478	 test ! -s conftest.err
21479       } && test -s conftest.$ac_objext; then
21480  emacs_cv_gettimeofday_two_arguments=yes
21481else
21482  echo "$as_me: failed program was:" >&5
21483sed 's/^/| /' conftest.$ac_ext >&5
21484
21485	emacs_cv_gettimeofday_two_arguments=no
21486fi
21487
21488rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21489fi
21490{ echo "$as_me:$LINENO: result: $emacs_cv_gettimeofday_two_arguments" >&5
21491echo "${ECHO_T}$emacs_cv_gettimeofday_two_arguments" >&6; }
21492    if test $emacs_cv_gettimeofday_two_arguments = no; then
21493
21494cat >>confdefs.h <<\_ACEOF
21495#define GETTIMEOFDAY_ONE_ARGUMENT 1
21496_ACEOF
21497
21498    fi
21499  fi
21500fi
21501
21502ok_so_far=yes
21503{ echo "$as_me:$LINENO: checking for socket" >&5
21504echo $ECHO_N "checking for socket... $ECHO_C" >&6; }
21505if test "${ac_cv_func_socket+set}" = set; then
21506  echo $ECHO_N "(cached) $ECHO_C" >&6
21507else
21508  cat >conftest.$ac_ext <<_ACEOF
21509/* confdefs.h.  */
21510_ACEOF
21511cat confdefs.h >>conftest.$ac_ext
21512cat >>conftest.$ac_ext <<_ACEOF
21513/* end confdefs.h.  */
21514/* Define socket to an innocuous variant, in case <limits.h> declares socket.
21515   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21516#define socket innocuous_socket
21517
21518/* System header to define __stub macros and hopefully few prototypes,
21519    which can conflict with char socket (); below.
21520    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21521    <limits.h> exists even on freestanding compilers.  */
21522
21523#ifdef __STDC__
21524# include <limits.h>
21525#else
21526# include <assert.h>
21527#endif
21528
21529#undef socket
21530
21531/* Override any GCC internal prototype to avoid an error.
21532   Use char because int might match the return type of a GCC
21533   builtin and then its argument prototype would still apply.  */
21534#ifdef __cplusplus
21535extern "C"
21536#endif
21537char socket ();
21538/* The GNU C library defines this for functions which it implements
21539    to always fail with ENOSYS.  Some functions are actually named
21540    something starting with __ and the normal name is an alias.  */
21541#if defined __stub_socket || defined __stub___socket
21542choke me
21543#endif
21544
21545int
21546main ()
21547{
21548return socket ();
21549  ;
21550  return 0;
21551}
21552_ACEOF
21553rm -f conftest.$ac_objext conftest$ac_exeext
21554if { (ac_try="$ac_link"
21555case "(($ac_try" in
21556  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21557  *) ac_try_echo=$ac_try;;
21558esac
21559eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21560  (eval "$ac_link") 2>conftest.er1
21561  ac_status=$?
21562  grep -v '^ *+' conftest.er1 >conftest.err
21563  rm -f conftest.er1
21564  cat conftest.err >&5
21565  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21566  (exit $ac_status); } && {
21567	 test -z "$ac_c_werror_flag" ||
21568	 test ! -s conftest.err
21569       } && test -s conftest$ac_exeext &&
21570       $as_test_x conftest$ac_exeext; then
21571  ac_cv_func_socket=yes
21572else
21573  echo "$as_me: failed program was:" >&5
21574sed 's/^/| /' conftest.$ac_ext >&5
21575
21576	ac_cv_func_socket=no
21577fi
21578
21579rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21580      conftest$ac_exeext conftest.$ac_ext
21581fi
21582{ echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
21583echo "${ECHO_T}$ac_cv_func_socket" >&6; }
21584if test $ac_cv_func_socket = yes; then
21585  :
21586else
21587  ok_so_far=no
21588fi
21589
21590if test $ok_so_far = yes; then
21591  if test "${ac_cv_header_netinet_in_h+set}" = set; then
21592  { echo "$as_me:$LINENO: checking for netinet/in.h" >&5
21593echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6; }
21594if test "${ac_cv_header_netinet_in_h+set}" = set; then
21595  echo $ECHO_N "(cached) $ECHO_C" >&6
21596fi
21597{ echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
21598echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6; }
21599else
21600  # Is the header compilable?
21601{ echo "$as_me:$LINENO: checking netinet/in.h usability" >&5
21602echo $ECHO_N "checking netinet/in.h usability... $ECHO_C" >&6; }
21603cat >conftest.$ac_ext <<_ACEOF
21604/* confdefs.h.  */
21605_ACEOF
21606cat confdefs.h >>conftest.$ac_ext
21607cat >>conftest.$ac_ext <<_ACEOF
21608/* end confdefs.h.  */
21609$ac_includes_default
21610#include <netinet/in.h>
21611_ACEOF
21612rm -f conftest.$ac_objext
21613if { (ac_try="$ac_compile"
21614case "(($ac_try" in
21615  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21616  *) ac_try_echo=$ac_try;;
21617esac
21618eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21619  (eval "$ac_compile") 2>conftest.er1
21620  ac_status=$?
21621  grep -v '^ *+' conftest.er1 >conftest.err
21622  rm -f conftest.er1
21623  cat conftest.err >&5
21624  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21625  (exit $ac_status); } && {
21626	 test -z "$ac_c_werror_flag" ||
21627	 test ! -s conftest.err
21628       } && test -s conftest.$ac_objext; then
21629  ac_header_compiler=yes
21630else
21631  echo "$as_me: failed program was:" >&5
21632sed 's/^/| /' conftest.$ac_ext >&5
21633
21634	ac_header_compiler=no
21635fi
21636
21637rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21638{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21639echo "${ECHO_T}$ac_header_compiler" >&6; }
21640
21641# Is the header present?
21642{ echo "$as_me:$LINENO: checking netinet/in.h presence" >&5
21643echo $ECHO_N "checking netinet/in.h presence... $ECHO_C" >&6; }
21644cat >conftest.$ac_ext <<_ACEOF
21645/* confdefs.h.  */
21646_ACEOF
21647cat confdefs.h >>conftest.$ac_ext
21648cat >>conftest.$ac_ext <<_ACEOF
21649/* end confdefs.h.  */
21650#include <netinet/in.h>
21651_ACEOF
21652if { (ac_try="$ac_cpp conftest.$ac_ext"
21653case "(($ac_try" in
21654  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21655  *) ac_try_echo=$ac_try;;
21656esac
21657eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21658  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
21659  ac_status=$?
21660  grep -v '^ *+' conftest.er1 >conftest.err
21661  rm -f conftest.er1
21662  cat conftest.err >&5
21663  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21664  (exit $ac_status); } >/dev/null && {
21665	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
21666	 test ! -s conftest.err
21667       }; then
21668  ac_header_preproc=yes
21669else
21670  echo "$as_me: failed program was:" >&5
21671sed 's/^/| /' conftest.$ac_ext >&5
21672
21673  ac_header_preproc=no
21674fi
21675
21676rm -f conftest.err conftest.$ac_ext
21677{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21678echo "${ECHO_T}$ac_header_preproc" >&6; }
21679
21680# So?  What about this header?
21681case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21682  yes:no: )
21683    { echo "$as_me:$LINENO: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&5
21684echo "$as_me: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21685    { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the compiler's result" >&5
21686echo "$as_me: WARNING: netinet/in.h: proceeding with the compiler's result" >&2;}
21687    ac_header_preproc=yes
21688    ;;
21689  no:yes:* )
21690    { echo "$as_me:$LINENO: WARNING: netinet/in.h: present but cannot be compiled" >&5
21691echo "$as_me: WARNING: netinet/in.h: present but cannot be compiled" >&2;}
21692    { echo "$as_me:$LINENO: WARNING: netinet/in.h:     check for missing prerequisite headers?" >&5
21693echo "$as_me: WARNING: netinet/in.h:     check for missing prerequisite headers?" >&2;}
21694    { echo "$as_me:$LINENO: WARNING: netinet/in.h: see the Autoconf documentation" >&5
21695echo "$as_me: WARNING: netinet/in.h: see the Autoconf documentation" >&2;}
21696    { echo "$as_me:$LINENO: WARNING: netinet/in.h:     section \"Present But Cannot Be Compiled\"" >&5
21697echo "$as_me: WARNING: netinet/in.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21698    { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
21699echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
21700    { echo "$as_me:$LINENO: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&5
21701echo "$as_me: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&2;}
21702
21703    ;;
21704esac
21705{ echo "$as_me:$LINENO: checking for netinet/in.h" >&5
21706echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6; }
21707if test "${ac_cv_header_netinet_in_h+set}" = set; then
21708  echo $ECHO_N "(cached) $ECHO_C" >&6
21709else
21710  ac_cv_header_netinet_in_h=$ac_header_preproc
21711fi
21712{ echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
21713echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6; }
21714
21715fi
21716if test $ac_cv_header_netinet_in_h = yes; then
21717  :
21718else
21719  ok_so_far=no
21720fi
21721
21722
21723fi
21724if test $ok_so_far = yes; then
21725  if test "${ac_cv_header_arpa_inet_h+set}" = set; then
21726  { echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
21727echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6; }
21728if test "${ac_cv_header_arpa_inet_h+set}" = set; then
21729  echo $ECHO_N "(cached) $ECHO_C" >&6
21730fi
21731{ echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
21732echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6; }
21733else
21734  # Is the header compilable?
21735{ echo "$as_me:$LINENO: checking arpa/inet.h usability" >&5
21736echo $ECHO_N "checking arpa/inet.h usability... $ECHO_C" >&6; }
21737cat >conftest.$ac_ext <<_ACEOF
21738/* confdefs.h.  */
21739_ACEOF
21740cat confdefs.h >>conftest.$ac_ext
21741cat >>conftest.$ac_ext <<_ACEOF
21742/* end confdefs.h.  */
21743$ac_includes_default
21744#include <arpa/inet.h>
21745_ACEOF
21746rm -f conftest.$ac_objext
21747if { (ac_try="$ac_compile"
21748case "(($ac_try" in
21749  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21750  *) ac_try_echo=$ac_try;;
21751esac
21752eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21753  (eval "$ac_compile") 2>conftest.er1
21754  ac_status=$?
21755  grep -v '^ *+' conftest.er1 >conftest.err
21756  rm -f conftest.er1
21757  cat conftest.err >&5
21758  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21759  (exit $ac_status); } && {
21760	 test -z "$ac_c_werror_flag" ||
21761	 test ! -s conftest.err
21762       } && test -s conftest.$ac_objext; then
21763  ac_header_compiler=yes
21764else
21765  echo "$as_me: failed program was:" >&5
21766sed 's/^/| /' conftest.$ac_ext >&5
21767
21768	ac_header_compiler=no
21769fi
21770
21771rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21772{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21773echo "${ECHO_T}$ac_header_compiler" >&6; }
21774
21775# Is the header present?
21776{ echo "$as_me:$LINENO: checking arpa/inet.h presence" >&5
21777echo $ECHO_N "checking arpa/inet.h presence... $ECHO_C" >&6; }
21778cat >conftest.$ac_ext <<_ACEOF
21779/* confdefs.h.  */
21780_ACEOF
21781cat confdefs.h >>conftest.$ac_ext
21782cat >>conftest.$ac_ext <<_ACEOF
21783/* end confdefs.h.  */
21784#include <arpa/inet.h>
21785_ACEOF
21786if { (ac_try="$ac_cpp conftest.$ac_ext"
21787case "(($ac_try" in
21788  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21789  *) ac_try_echo=$ac_try;;
21790esac
21791eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21792  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
21793  ac_status=$?
21794  grep -v '^ *+' conftest.er1 >conftest.err
21795  rm -f conftest.er1
21796  cat conftest.err >&5
21797  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21798  (exit $ac_status); } >/dev/null && {
21799	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
21800	 test ! -s conftest.err
21801       }; then
21802  ac_header_preproc=yes
21803else
21804  echo "$as_me: failed program was:" >&5
21805sed 's/^/| /' conftest.$ac_ext >&5
21806
21807  ac_header_preproc=no
21808fi
21809
21810rm -f conftest.err conftest.$ac_ext
21811{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21812echo "${ECHO_T}$ac_header_preproc" >&6; }
21813
21814# So?  What about this header?
21815case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21816  yes:no: )
21817    { echo "$as_me:$LINENO: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&5
21818echo "$as_me: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21819    { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the compiler's result" >&5
21820echo "$as_me: WARNING: arpa/inet.h: proceeding with the compiler's result" >&2;}
21821    ac_header_preproc=yes
21822    ;;
21823  no:yes:* )
21824    { echo "$as_me:$LINENO: WARNING: arpa/inet.h: present but cannot be compiled" >&5
21825echo "$as_me: WARNING: arpa/inet.h: present but cannot be compiled" >&2;}
21826    { echo "$as_me:$LINENO: WARNING: arpa/inet.h:     check for missing prerequisite headers?" >&5
21827echo "$as_me: WARNING: arpa/inet.h:     check for missing prerequisite headers?" >&2;}
21828    { echo "$as_me:$LINENO: WARNING: arpa/inet.h: see the Autoconf documentation" >&5
21829echo "$as_me: WARNING: arpa/inet.h: see the Autoconf documentation" >&2;}
21830    { echo "$as_me:$LINENO: WARNING: arpa/inet.h:     section \"Present But Cannot Be Compiled\"" >&5
21831echo "$as_me: WARNING: arpa/inet.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21832    { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
21833echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
21834    { echo "$as_me:$LINENO: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&5
21835echo "$as_me: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&2;}
21836
21837    ;;
21838esac
21839{ echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
21840echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6; }
21841if test "${ac_cv_header_arpa_inet_h+set}" = set; then
21842  echo $ECHO_N "(cached) $ECHO_C" >&6
21843else
21844  ac_cv_header_arpa_inet_h=$ac_header_preproc
21845fi
21846{ echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
21847echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6; }
21848
21849fi
21850if test $ac_cv_header_arpa_inet_h = yes; then
21851  :
21852else
21853  ok_so_far=no
21854fi
21855
21856
21857fi
21858if test $ok_so_far = yes; then
21859
21860cat >>confdefs.h <<\_ACEOF
21861#define HAVE_INET_SOCKETS 1
21862_ACEOF
21863
21864fi
21865
21866
21867for ac_header in sys/ioctl.h
21868do
21869as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
21870if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
21871  { echo "$as_me:$LINENO: checking for $ac_header" >&5
21872echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
21873if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
21874  echo $ECHO_N "(cached) $ECHO_C" >&6
21875fi
21876ac_res=`eval echo '${'$as_ac_Header'}'`
21877	       { echo "$as_me:$LINENO: result: $ac_res" >&5
21878echo "${ECHO_T}$ac_res" >&6; }
21879else
21880  # Is the header compilable?
21881{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
21882echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
21883cat >conftest.$ac_ext <<_ACEOF
21884/* confdefs.h.  */
21885_ACEOF
21886cat confdefs.h >>conftest.$ac_ext
21887cat >>conftest.$ac_ext <<_ACEOF
21888/* end confdefs.h.  */
21889$ac_includes_default
21890#include <$ac_header>
21891_ACEOF
21892rm -f conftest.$ac_objext
21893if { (ac_try="$ac_compile"
21894case "(($ac_try" in
21895  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21896  *) ac_try_echo=$ac_try;;
21897esac
21898eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21899  (eval "$ac_compile") 2>conftest.er1
21900  ac_status=$?
21901  grep -v '^ *+' conftest.er1 >conftest.err
21902  rm -f conftest.er1
21903  cat conftest.err >&5
21904  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21905  (exit $ac_status); } && {
21906	 test -z "$ac_c_werror_flag" ||
21907	 test ! -s conftest.err
21908       } && test -s conftest.$ac_objext; then
21909  ac_header_compiler=yes
21910else
21911  echo "$as_me: failed program was:" >&5
21912sed 's/^/| /' conftest.$ac_ext >&5
21913
21914	ac_header_compiler=no
21915fi
21916
21917rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21918{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21919echo "${ECHO_T}$ac_header_compiler" >&6; }
21920
21921# Is the header present?
21922{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
21923echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
21924cat >conftest.$ac_ext <<_ACEOF
21925/* confdefs.h.  */
21926_ACEOF
21927cat confdefs.h >>conftest.$ac_ext
21928cat >>conftest.$ac_ext <<_ACEOF
21929/* end confdefs.h.  */
21930#include <$ac_header>
21931_ACEOF
21932if { (ac_try="$ac_cpp conftest.$ac_ext"
21933case "(($ac_try" in
21934  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21935  *) ac_try_echo=$ac_try;;
21936esac
21937eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21938  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
21939  ac_status=$?
21940  grep -v '^ *+' conftest.er1 >conftest.err
21941  rm -f conftest.er1
21942  cat conftest.err >&5
21943  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21944  (exit $ac_status); } >/dev/null && {
21945	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
21946	 test ! -s conftest.err
21947       }; then
21948  ac_header_preproc=yes
21949else
21950  echo "$as_me: failed program was:" >&5
21951sed 's/^/| /' conftest.$ac_ext >&5
21952
21953  ac_header_preproc=no
21954fi
21955
21956rm -f conftest.err conftest.$ac_ext
21957{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21958echo "${ECHO_T}$ac_header_preproc" >&6; }
21959
21960# So?  What about this header?
21961case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21962  yes:no: )
21963    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21964echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
21965    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
21966echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
21967    ac_header_preproc=yes
21968    ;;
21969  no:yes:* )
21970    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
21971echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
21972    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
21973echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
21974    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
21975echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
21976    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
21977echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
21978    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21979echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21980    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
21981echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
21982
21983    ;;
21984esac
21985{ echo "$as_me:$LINENO: checking for $ac_header" >&5
21986echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
21987if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
21988  echo $ECHO_N "(cached) $ECHO_C" >&6
21989else
21990  eval "$as_ac_Header=\$ac_header_preproc"
21991fi
21992ac_res=`eval echo '${'$as_ac_Header'}'`
21993	       { echo "$as_me:$LINENO: result: $ac_res" >&5
21994echo "${ECHO_T}$ac_res" >&6; }
21995
21996fi
21997if test `eval echo '${'$as_ac_Header'}'` = yes; then
21998  cat >>confdefs.h <<_ACEOF
21999#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
22000_ACEOF
22001
22002fi
22003
22004done
22005
22006
22007if test -f /usr/lpp/X11/bin/smt.exp; then
22008
22009cat >>confdefs.h <<\_ACEOF
22010#define HAVE_AIX_SMT_EXP 1
22011_ACEOF
22012
22013fi
22014
22015{ echo "$as_me:$LINENO: checking whether system supports dynamic ptys" >&5
22016echo $ECHO_N "checking whether system supports dynamic ptys... $ECHO_C" >&6; }
22017if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
22018  { echo "$as_me:$LINENO: result: yes" >&5
22019echo "${ECHO_T}yes" >&6; }
22020
22021cat >>confdefs.h <<\_ACEOF
22022#define HAVE_DEV_PTMX 1
22023_ACEOF
22024
22025else
22026  { echo "$as_me:$LINENO: result: no" >&5
22027echo "${ECHO_T}no" >&6; }
22028fi
22029
22030{ echo "$as_me:$LINENO: checking for pid_t" >&5
22031echo $ECHO_N "checking for pid_t... $ECHO_C" >&6; }
22032if test "${ac_cv_type_pid_t+set}" = set; then
22033  echo $ECHO_N "(cached) $ECHO_C" >&6
22034else
22035  cat >conftest.$ac_ext <<_ACEOF
22036/* confdefs.h.  */
22037_ACEOF
22038cat confdefs.h >>conftest.$ac_ext
22039cat >>conftest.$ac_ext <<_ACEOF
22040/* end confdefs.h.  */
22041$ac_includes_default
22042typedef pid_t ac__type_new_;
22043int
22044main ()
22045{
22046if ((ac__type_new_ *) 0)
22047  return 0;
22048if (sizeof (ac__type_new_))
22049  return 0;
22050  ;
22051  return 0;
22052}
22053_ACEOF
22054rm -f conftest.$ac_objext
22055if { (ac_try="$ac_compile"
22056case "(($ac_try" in
22057  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22058  *) ac_try_echo=$ac_try;;
22059esac
22060eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22061  (eval "$ac_compile") 2>conftest.er1
22062  ac_status=$?
22063  grep -v '^ *+' conftest.er1 >conftest.err
22064  rm -f conftest.er1
22065  cat conftest.err >&5
22066  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22067  (exit $ac_status); } && {
22068	 test -z "$ac_c_werror_flag" ||
22069	 test ! -s conftest.err
22070       } && test -s conftest.$ac_objext; then
22071  ac_cv_type_pid_t=yes
22072else
22073  echo "$as_me: failed program was:" >&5
22074sed 's/^/| /' conftest.$ac_ext >&5
22075
22076	ac_cv_type_pid_t=no
22077fi
22078
22079rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22080fi
22081{ echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
22082echo "${ECHO_T}$ac_cv_type_pid_t" >&6; }
22083if test $ac_cv_type_pid_t = yes; then
22084  :
22085else
22086
22087cat >>confdefs.h <<_ACEOF
22088#define pid_t int
22089_ACEOF
22090
22091fi
22092
22093
22094for ac_header in vfork.h
22095do
22096as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
22097if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
22098  { echo "$as_me:$LINENO: checking for $ac_header" >&5
22099echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
22100if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
22101  echo $ECHO_N "(cached) $ECHO_C" >&6
22102fi
22103ac_res=`eval echo '${'$as_ac_Header'}'`
22104	       { echo "$as_me:$LINENO: result: $ac_res" >&5
22105echo "${ECHO_T}$ac_res" >&6; }
22106else
22107  # Is the header compilable?
22108{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
22109echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
22110cat >conftest.$ac_ext <<_ACEOF
22111/* confdefs.h.  */
22112_ACEOF
22113cat confdefs.h >>conftest.$ac_ext
22114cat >>conftest.$ac_ext <<_ACEOF
22115/* end confdefs.h.  */
22116$ac_includes_default
22117#include <$ac_header>
22118_ACEOF
22119rm -f conftest.$ac_objext
22120if { (ac_try="$ac_compile"
22121case "(($ac_try" in
22122  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22123  *) ac_try_echo=$ac_try;;
22124esac
22125eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22126  (eval "$ac_compile") 2>conftest.er1
22127  ac_status=$?
22128  grep -v '^ *+' conftest.er1 >conftest.err
22129  rm -f conftest.er1
22130  cat conftest.err >&5
22131  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22132  (exit $ac_status); } && {
22133	 test -z "$ac_c_werror_flag" ||
22134	 test ! -s conftest.err
22135       } && test -s conftest.$ac_objext; then
22136  ac_header_compiler=yes
22137else
22138  echo "$as_me: failed program was:" >&5
22139sed 's/^/| /' conftest.$ac_ext >&5
22140
22141	ac_header_compiler=no
22142fi
22143
22144rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22145{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22146echo "${ECHO_T}$ac_header_compiler" >&6; }
22147
22148# Is the header present?
22149{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
22150echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
22151cat >conftest.$ac_ext <<_ACEOF
22152/* confdefs.h.  */
22153_ACEOF
22154cat confdefs.h >>conftest.$ac_ext
22155cat >>conftest.$ac_ext <<_ACEOF
22156/* end confdefs.h.  */
22157#include <$ac_header>
22158_ACEOF
22159if { (ac_try="$ac_cpp conftest.$ac_ext"
22160case "(($ac_try" in
22161  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22162  *) ac_try_echo=$ac_try;;
22163esac
22164eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22165  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
22166  ac_status=$?
22167  grep -v '^ *+' conftest.er1 >conftest.err
22168  rm -f conftest.er1
22169  cat conftest.err >&5
22170  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22171  (exit $ac_status); } >/dev/null && {
22172	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
22173	 test ! -s conftest.err
22174       }; then
22175  ac_header_preproc=yes
22176else
22177  echo "$as_me: failed program was:" >&5
22178sed 's/^/| /' conftest.$ac_ext >&5
22179
22180  ac_header_preproc=no
22181fi
22182
22183rm -f conftest.err conftest.$ac_ext
22184{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22185echo "${ECHO_T}$ac_header_preproc" >&6; }
22186
22187# So?  What about this header?
22188case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22189  yes:no: )
22190    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
22191echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
22192    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
22193echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
22194    ac_header_preproc=yes
22195    ;;
22196  no:yes:* )
22197    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
22198echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
22199    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
22200echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
22201    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
22202echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
22203    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
22204echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
22205    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22206echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22207    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
22208echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
22209
22210    ;;
22211esac
22212{ echo "$as_me:$LINENO: checking for $ac_header" >&5
22213echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
22214if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
22215  echo $ECHO_N "(cached) $ECHO_C" >&6
22216else
22217  eval "$as_ac_Header=\$ac_header_preproc"
22218fi
22219ac_res=`eval echo '${'$as_ac_Header'}'`
22220	       { echo "$as_me:$LINENO: result: $ac_res" >&5
22221echo "${ECHO_T}$ac_res" >&6; }
22222
22223fi
22224if test `eval echo '${'$as_ac_Header'}'` = yes; then
22225  cat >>confdefs.h <<_ACEOF
22226#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
22227_ACEOF
22228
22229fi
22230
22231done
22232
22233
22234
22235for ac_func in fork vfork
22236do
22237as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
22238{ echo "$as_me:$LINENO: checking for $ac_func" >&5
22239echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
22240if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22241  echo $ECHO_N "(cached) $ECHO_C" >&6
22242else
22243  cat >conftest.$ac_ext <<_ACEOF
22244/* confdefs.h.  */
22245_ACEOF
22246cat confdefs.h >>conftest.$ac_ext
22247cat >>conftest.$ac_ext <<_ACEOF
22248/* end confdefs.h.  */
22249/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22250   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22251#define $ac_func innocuous_$ac_func
22252
22253/* System header to define __stub macros and hopefully few prototypes,
22254    which can conflict with char $ac_func (); below.
22255    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22256    <limits.h> exists even on freestanding compilers.  */
22257
22258#ifdef __STDC__
22259# include <limits.h>
22260#else
22261# include <assert.h>
22262#endif
22263
22264#undef $ac_func
22265
22266/* Override any GCC internal prototype to avoid an error.
22267   Use char because int might match the return type of a GCC
22268   builtin and then its argument prototype would still apply.  */
22269#ifdef __cplusplus
22270extern "C"
22271#endif
22272char $ac_func ();
22273/* The GNU C library defines this for functions which it implements
22274    to always fail with ENOSYS.  Some functions are actually named
22275    something starting with __ and the normal name is an alias.  */
22276#if defined __stub_$ac_func || defined __stub___$ac_func
22277choke me
22278#endif
22279
22280int
22281main ()
22282{
22283return $ac_func ();
22284  ;
22285  return 0;
22286}
22287_ACEOF
22288rm -f conftest.$ac_objext conftest$ac_exeext
22289if { (ac_try="$ac_link"
22290case "(($ac_try" in
22291  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22292  *) ac_try_echo=$ac_try;;
22293esac
22294eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22295  (eval "$ac_link") 2>conftest.er1
22296  ac_status=$?
22297  grep -v '^ *+' conftest.er1 >conftest.err
22298  rm -f conftest.er1
22299  cat conftest.err >&5
22300  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22301  (exit $ac_status); } && {
22302	 test -z "$ac_c_werror_flag" ||
22303	 test ! -s conftest.err
22304       } && test -s conftest$ac_exeext &&
22305       $as_test_x conftest$ac_exeext; then
22306  eval "$as_ac_var=yes"
22307else
22308  echo "$as_me: failed program was:" >&5
22309sed 's/^/| /' conftest.$ac_ext >&5
22310
22311	eval "$as_ac_var=no"
22312fi
22313
22314rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22315      conftest$ac_exeext conftest.$ac_ext
22316fi
22317ac_res=`eval echo '${'$as_ac_var'}'`
22318	       { echo "$as_me:$LINENO: result: $ac_res" >&5
22319echo "${ECHO_T}$ac_res" >&6; }
22320if test `eval echo '${'$as_ac_var'}'` = yes; then
22321  cat >>confdefs.h <<_ACEOF
22322#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
22323_ACEOF
22324
22325fi
22326done
22327
22328if test "x$ac_cv_func_fork" = xyes; then
22329  { echo "$as_me:$LINENO: checking for working fork" >&5
22330echo $ECHO_N "checking for working fork... $ECHO_C" >&6; }
22331if test "${ac_cv_func_fork_works+set}" = set; then
22332  echo $ECHO_N "(cached) $ECHO_C" >&6
22333else
22334  if test "$cross_compiling" = yes; then
22335  ac_cv_func_fork_works=cross
22336else
22337  cat >conftest.$ac_ext <<_ACEOF
22338/* confdefs.h.  */
22339_ACEOF
22340cat confdefs.h >>conftest.$ac_ext
22341cat >>conftest.$ac_ext <<_ACEOF
22342/* end confdefs.h.  */
22343$ac_includes_default
22344int
22345main ()
22346{
22347
22348	  /* By Ruediger Kuhlmann. */
22349	  return fork () < 0;
22350
22351  ;
22352  return 0;
22353}
22354_ACEOF
22355rm -f conftest$ac_exeext
22356if { (ac_try="$ac_link"
22357case "(($ac_try" in
22358  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22359  *) ac_try_echo=$ac_try;;
22360esac
22361eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22362  (eval "$ac_link") 2>&5
22363  ac_status=$?
22364  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22365  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22366  { (case "(($ac_try" in
22367  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22368  *) ac_try_echo=$ac_try;;
22369esac
22370eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22371  (eval "$ac_try") 2>&5
22372  ac_status=$?
22373  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22374  (exit $ac_status); }; }; then
22375  ac_cv_func_fork_works=yes
22376else
22377  echo "$as_me: program exited with status $ac_status" >&5
22378echo "$as_me: failed program was:" >&5
22379sed 's/^/| /' conftest.$ac_ext >&5
22380
22381( exit $ac_status )
22382ac_cv_func_fork_works=no
22383fi
22384rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22385fi
22386
22387
22388fi
22389{ echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
22390echo "${ECHO_T}$ac_cv_func_fork_works" >&6; }
22391
22392else
22393  ac_cv_func_fork_works=$ac_cv_func_fork
22394fi
22395if test "x$ac_cv_func_fork_works" = xcross; then
22396  case $host in
22397    *-*-amigaos* | *-*-msdosdjgpp*)
22398      # Override, as these systems have only a dummy fork() stub
22399      ac_cv_func_fork_works=no
22400      ;;
22401    *)
22402      ac_cv_func_fork_works=yes
22403      ;;
22404  esac
22405  { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
22406echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
22407fi
22408ac_cv_func_vfork_works=$ac_cv_func_vfork
22409if test "x$ac_cv_func_vfork" = xyes; then
22410  { echo "$as_me:$LINENO: checking for working vfork" >&5
22411echo $ECHO_N "checking for working vfork... $ECHO_C" >&6; }
22412if test "${ac_cv_func_vfork_works+set}" = set; then
22413  echo $ECHO_N "(cached) $ECHO_C" >&6
22414else
22415  if test "$cross_compiling" = yes; then
22416  ac_cv_func_vfork_works=cross
22417else
22418  cat >conftest.$ac_ext <<_ACEOF
22419/* confdefs.h.  */
22420_ACEOF
22421cat confdefs.h >>conftest.$ac_ext
22422cat >>conftest.$ac_ext <<_ACEOF
22423/* end confdefs.h.  */
22424/* Thanks to Paul Eggert for this test.  */
22425$ac_includes_default
22426#include <sys/wait.h>
22427#ifdef HAVE_VFORK_H
22428# include <vfork.h>
22429#endif
22430/* On some sparc systems, changes by the child to local and incoming
22431   argument registers are propagated back to the parent.  The compiler
22432   is told about this with #include <vfork.h>, but some compilers
22433   (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
22434   static variable whose address is put into a register that is
22435   clobbered by the vfork.  */
22436static void
22437#ifdef __cplusplus
22438sparc_address_test (int arg)
22439# else
22440sparc_address_test (arg) int arg;
22441#endif
22442{
22443  static pid_t child;
22444  if (!child) {
22445    child = vfork ();
22446    if (child < 0) {
22447      perror ("vfork");
22448      _exit(2);
22449    }
22450    if (!child) {
22451      arg = getpid();
22452      write(-1, "", 0);
22453      _exit (arg);
22454    }
22455  }
22456}
22457
22458int
22459main ()
22460{
22461  pid_t parent = getpid ();
22462  pid_t child;
22463
22464  sparc_address_test (0);
22465
22466  child = vfork ();
22467
22468  if (child == 0) {
22469    /* Here is another test for sparc vfork register problems.  This
22470       test uses lots of local variables, at least as many local
22471       variables as main has allocated so far including compiler
22472       temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
22473       4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
22474       reuse the register of parent for one of the local variables,
22475       since it will think that parent can't possibly be used any more
22476       in this routine.  Assigning to the local variable will thus
22477       munge parent in the parent process.  */
22478    pid_t
22479      p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
22480      p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
22481    /* Convince the compiler that p..p7 are live; otherwise, it might
22482       use the same hardware register for all 8 local variables.  */
22483    if (p != p1 || p != p2 || p != p3 || p != p4
22484	|| p != p5 || p != p6 || p != p7)
22485      _exit(1);
22486
22487    /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
22488       from child file descriptors.  If the child closes a descriptor
22489       before it execs or exits, this munges the parent's descriptor
22490       as well.  Test for this by closing stdout in the child.  */
22491    _exit(close(fileno(stdout)) != 0);
22492  } else {
22493    int status;
22494    struct stat st;
22495
22496    while (wait(&status) != child)
22497      ;
22498    return (
22499	 /* Was there some problem with vforking?  */
22500	 child < 0
22501
22502	 /* Did the child fail?  (This shouldn't happen.)  */
22503	 || status
22504
22505	 /* Did the vfork/compiler bug occur?  */
22506	 || parent != getpid()
22507
22508	 /* Did the file descriptor bug occur?  */
22509	 || fstat(fileno(stdout), &st) != 0
22510	 );
22511  }
22512}
22513_ACEOF
22514rm -f conftest$ac_exeext
22515if { (ac_try="$ac_link"
22516case "(($ac_try" in
22517  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22518  *) ac_try_echo=$ac_try;;
22519esac
22520eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22521  (eval "$ac_link") 2>&5
22522  ac_status=$?
22523  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22524  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22525  { (case "(($ac_try" in
22526  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22527  *) ac_try_echo=$ac_try;;
22528esac
22529eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22530  (eval "$ac_try") 2>&5
22531  ac_status=$?
22532  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22533  (exit $ac_status); }; }; then
22534  ac_cv_func_vfork_works=yes
22535else
22536  echo "$as_me: program exited with status $ac_status" >&5
22537echo "$as_me: failed program was:" >&5
22538sed 's/^/| /' conftest.$ac_ext >&5
22539
22540( exit $ac_status )
22541ac_cv_func_vfork_works=no
22542fi
22543rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22544fi
22545
22546
22547fi
22548{ echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
22549echo "${ECHO_T}$ac_cv_func_vfork_works" >&6; }
22550
22551fi;
22552if test "x$ac_cv_func_fork_works" = xcross; then
22553  ac_cv_func_vfork_works=$ac_cv_func_vfork
22554  { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
22555echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
22556fi
22557
22558if test "x$ac_cv_func_vfork_works" = xyes; then
22559
22560cat >>confdefs.h <<\_ACEOF
22561#define HAVE_WORKING_VFORK 1
22562_ACEOF
22563
22564else
22565
22566cat >>confdefs.h <<\_ACEOF
22567#define vfork fork
22568_ACEOF
22569
22570fi
22571if test "x$ac_cv_func_fork_works" = xyes; then
22572
22573cat >>confdefs.h <<\_ACEOF
22574#define HAVE_WORKING_FORK 1
22575_ACEOF
22576
22577fi
22578
22579
22580{ echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
22581echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6; }
22582if test "${emacs_cv_langinfo_codeset+set}" = set; then
22583  echo $ECHO_N "(cached) $ECHO_C" >&6
22584else
22585  cat >conftest.$ac_ext <<_ACEOF
22586/* confdefs.h.  */
22587_ACEOF
22588cat confdefs.h >>conftest.$ac_ext
22589cat >>conftest.$ac_ext <<_ACEOF
22590/* end confdefs.h.  */
22591#include <langinfo.h>
22592int
22593main ()
22594{
22595char* cs = nl_langinfo(CODESET);
22596  ;
22597  return 0;
22598}
22599_ACEOF
22600rm -f conftest.$ac_objext conftest$ac_exeext
22601if { (ac_try="$ac_link"
22602case "(($ac_try" in
22603  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22604  *) ac_try_echo=$ac_try;;
22605esac
22606eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22607  (eval "$ac_link") 2>conftest.er1
22608  ac_status=$?
22609  grep -v '^ *+' conftest.er1 >conftest.err
22610  rm -f conftest.er1
22611  cat conftest.err >&5
22612  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22613  (exit $ac_status); } && {
22614	 test -z "$ac_c_werror_flag" ||
22615	 test ! -s conftest.err
22616       } && test -s conftest$ac_exeext &&
22617       $as_test_x conftest$ac_exeext; then
22618  emacs_cv_langinfo_codeset=yes
22619else
22620  echo "$as_me: failed program was:" >&5
22621sed 's/^/| /' conftest.$ac_ext >&5
22622
22623	emacs_cv_langinfo_codeset=no
22624fi
22625
22626rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22627      conftest$ac_exeext conftest.$ac_ext
22628
22629fi
22630{ echo "$as_me:$LINENO: result: $emacs_cv_langinfo_codeset" >&5
22631echo "${ECHO_T}$emacs_cv_langinfo_codeset" >&6; }
22632if test $emacs_cv_langinfo_codeset = yes; then
22633
22634cat >>confdefs.h <<\_ACEOF
22635#define HAVE_LANGINFO_CODESET 1
22636_ACEOF
22637
22638fi
22639
22640{ echo "$as_me:$LINENO: checking for size_t" >&5
22641echo $ECHO_N "checking for size_t... $ECHO_C" >&6; }
22642if test "${ac_cv_type_size_t+set}" = set; then
22643  echo $ECHO_N "(cached) $ECHO_C" >&6
22644else
22645  cat >conftest.$ac_ext <<_ACEOF
22646/* confdefs.h.  */
22647_ACEOF
22648cat confdefs.h >>conftest.$ac_ext
22649cat >>conftest.$ac_ext <<_ACEOF
22650/* end confdefs.h.  */
22651$ac_includes_default
22652typedef size_t ac__type_new_;
22653int
22654main ()
22655{
22656if ((ac__type_new_ *) 0)
22657  return 0;
22658if (sizeof (ac__type_new_))
22659  return 0;
22660  ;
22661  return 0;
22662}
22663_ACEOF
22664rm -f conftest.$ac_objext
22665if { (ac_try="$ac_compile"
22666case "(($ac_try" in
22667  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22668  *) ac_try_echo=$ac_try;;
22669esac
22670eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22671  (eval "$ac_compile") 2>conftest.er1
22672  ac_status=$?
22673  grep -v '^ *+' conftest.er1 >conftest.err
22674  rm -f conftest.er1
22675  cat conftest.err >&5
22676  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22677  (exit $ac_status); } && {
22678	 test -z "$ac_c_werror_flag" ||
22679	 test ! -s conftest.err
22680       } && test -s conftest.$ac_objext; then
22681  ac_cv_type_size_t=yes
22682else
22683  echo "$as_me: failed program was:" >&5
22684sed 's/^/| /' conftest.$ac_ext >&5
22685
22686	ac_cv_type_size_t=no
22687fi
22688
22689rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22690fi
22691{ echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
22692echo "${ECHO_T}$ac_cv_type_size_t" >&6; }
22693if test $ac_cv_type_size_t = yes; then
22694
22695cat >>confdefs.h <<_ACEOF
22696#define HAVE_SIZE_T 1
22697_ACEOF
22698
22699
22700fi
22701
22702
22703{ echo "$as_me:$LINENO: checking for mbstate_t" >&5
22704echo $ECHO_N "checking for mbstate_t... $ECHO_C" >&6; }
22705if test "${ac_cv_type_mbstate_t+set}" = set; then
22706  echo $ECHO_N "(cached) $ECHO_C" >&6
22707else
22708  cat >conftest.$ac_ext <<_ACEOF
22709/* confdefs.h.  */
22710_ACEOF
22711cat confdefs.h >>conftest.$ac_ext
22712cat >>conftest.$ac_ext <<_ACEOF
22713/* end confdefs.h.  */
22714$ac_includes_default
22715#	    include <wchar.h>
22716int
22717main ()
22718{
22719mbstate_t x; return sizeof x;
22720  ;
22721  return 0;
22722}
22723_ACEOF
22724rm -f conftest.$ac_objext
22725if { (ac_try="$ac_compile"
22726case "(($ac_try" in
22727  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22728  *) ac_try_echo=$ac_try;;
22729esac
22730eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22731  (eval "$ac_compile") 2>conftest.er1
22732  ac_status=$?
22733  grep -v '^ *+' conftest.er1 >conftest.err
22734  rm -f conftest.er1
22735  cat conftest.err >&5
22736  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22737  (exit $ac_status); } && {
22738	 test -z "$ac_c_werror_flag" ||
22739	 test ! -s conftest.err
22740       } && test -s conftest.$ac_objext; then
22741  ac_cv_type_mbstate_t=yes
22742else
22743  echo "$as_me: failed program was:" >&5
22744sed 's/^/| /' conftest.$ac_ext >&5
22745
22746	ac_cv_type_mbstate_t=no
22747fi
22748
22749rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22750fi
22751{ echo "$as_me:$LINENO: result: $ac_cv_type_mbstate_t" >&5
22752echo "${ECHO_T}$ac_cv_type_mbstate_t" >&6; }
22753   if test $ac_cv_type_mbstate_t = yes; then
22754
22755cat >>confdefs.h <<\_ACEOF
22756#define HAVE_MBSTATE_T 1
22757_ACEOF
22758
22759   else
22760
22761cat >>confdefs.h <<\_ACEOF
22762#define mbstate_t int
22763_ACEOF
22764
22765   fi
22766
22767{ echo "$as_me:$LINENO: checking for C restrict keyword" >&5
22768echo $ECHO_N "checking for C restrict keyword... $ECHO_C" >&6; }
22769if test "${emacs_cv_c_restrict+set}" = set; then
22770  echo $ECHO_N "(cached) $ECHO_C" >&6
22771else
22772  cat >conftest.$ac_ext <<_ACEOF
22773/* confdefs.h.  */
22774_ACEOF
22775cat confdefs.h >>conftest.$ac_ext
22776cat >>conftest.$ac_ext <<_ACEOF
22777/* end confdefs.h.  */
22778void fred (int *restrict x);
22779int
22780main ()
22781{
22782
22783  ;
22784  return 0;
22785}
22786_ACEOF
22787rm -f conftest.$ac_objext
22788if { (ac_try="$ac_compile"
22789case "(($ac_try" in
22790  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22791  *) ac_try_echo=$ac_try;;
22792esac
22793eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22794  (eval "$ac_compile") 2>conftest.er1
22795  ac_status=$?
22796  grep -v '^ *+' conftest.er1 >conftest.err
22797  rm -f conftest.er1
22798  cat conftest.err >&5
22799  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22800  (exit $ac_status); } && {
22801	 test -z "$ac_c_werror_flag" ||
22802	 test ! -s conftest.err
22803       } && test -s conftest.$ac_objext; then
22804  emacs_cv_c_restrict=yes
22805else
22806  echo "$as_me: failed program was:" >&5
22807sed 's/^/| /' conftest.$ac_ext >&5
22808
22809	cat >conftest.$ac_ext <<_ACEOF
22810/* confdefs.h.  */
22811_ACEOF
22812cat confdefs.h >>conftest.$ac_ext
22813cat >>conftest.$ac_ext <<_ACEOF
22814/* end confdefs.h.  */
22815void fred (int *__restrict x);
22816int
22817main ()
22818{
22819
22820  ;
22821  return 0;
22822}
22823_ACEOF
22824rm -f conftest.$ac_objext
22825if { (ac_try="$ac_compile"
22826case "(($ac_try" in
22827  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22828  *) ac_try_echo=$ac_try;;
22829esac
22830eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22831  (eval "$ac_compile") 2>conftest.er1
22832  ac_status=$?
22833  grep -v '^ *+' conftest.er1 >conftest.err
22834  rm -f conftest.er1
22835  cat conftest.err >&5
22836  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22837  (exit $ac_status); } && {
22838	 test -z "$ac_c_werror_flag" ||
22839	 test ! -s conftest.err
22840       } && test -s conftest.$ac_objext; then
22841  emacs_cv_c_restrict=__restrict
22842else
22843  echo "$as_me: failed program was:" >&5
22844sed 's/^/| /' conftest.$ac_ext >&5
22845
22846	emacs_cv_c_restrict=no
22847fi
22848
22849rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22850fi
22851
22852rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22853fi
22854{ echo "$as_me:$LINENO: result: $emacs_cv_c_restrict" >&5
22855echo "${ECHO_T}$emacs_cv_c_restrict" >&6; }
22856case "$emacs_cv_c_restrict" in
22857  yes) emacs_restrict=restrict;;
22858  no) emacs_restrict="";;
22859  *) emacs_restrict="$emacs_cv_c_restrict";;
22860esac
22861if test "$emacs_restrict" != __restrict; then
22862
22863cat >>confdefs.h <<_ACEOF
22864#define __restrict $emacs_restrict
22865_ACEOF
22866
22867fi
22868
22869{ echo "$as_me:$LINENO: checking for C restricted array declarations" >&5
22870echo $ECHO_N "checking for C restricted array declarations... $ECHO_C" >&6; }
22871if test "${emacs_cv_c_restrict_arr+set}" = set; then
22872  echo $ECHO_N "(cached) $ECHO_C" >&6
22873else
22874  cat >conftest.$ac_ext <<_ACEOF
22875/* confdefs.h.  */
22876_ACEOF
22877cat confdefs.h >>conftest.$ac_ext
22878cat >>conftest.$ac_ext <<_ACEOF
22879/* end confdefs.h.  */
22880void fred (int x[__restrict]);
22881int
22882main ()
22883{
22884
22885  ;
22886  return 0;
22887}
22888_ACEOF
22889rm -f conftest.$ac_objext
22890if { (ac_try="$ac_compile"
22891case "(($ac_try" in
22892  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22893  *) ac_try_echo=$ac_try;;
22894esac
22895eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22896  (eval "$ac_compile") 2>conftest.er1
22897  ac_status=$?
22898  grep -v '^ *+' conftest.er1 >conftest.err
22899  rm -f conftest.er1
22900  cat conftest.err >&5
22901  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22902  (exit $ac_status); } && {
22903	 test -z "$ac_c_werror_flag" ||
22904	 test ! -s conftest.err
22905       } && test -s conftest.$ac_objext; then
22906  emacs_cv_c_restrict_arr=yes
22907else
22908  echo "$as_me: failed program was:" >&5
22909sed 's/^/| /' conftest.$ac_ext >&5
22910
22911	emacs_cv_c_restrict_arr=no
22912fi
22913
22914rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22915fi
22916{ echo "$as_me:$LINENO: result: $emacs_cv_c_restrict_arr" >&5
22917echo "${ECHO_T}$emacs_cv_c_restrict_arr" >&6; }
22918if test "$emacs_cv_c_restrict_arr" = yes; then
22919
22920cat >>confdefs.h <<\_ACEOF
22921#define __restrict_arr __restrict
22922_ACEOF
22923
22924fi
22925
22926
22927
22928# Set up the CFLAGS for real compilation, so we can substitute it.
22929CFLAGS="$REAL_CFLAGS"
22930CPPFLAGS="$REAL_CPPFLAGS"
22931
22932#### Find out which version of Emacs this is.
22933version=`grep 'defconst[	 ]*emacs-version' ${srcdir}/lisp/version.el \
22934	 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
22935if test x"${version}" = x; then
22936  { { echo "$as_me:$LINENO: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&5
22937echo "$as_me: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&2;}
22938   { (exit 1); exit 1; }; }
22939fi
22940
22941### Specify what sort of things we'll be editing into Makefile and config.h.
22942### Use configuration here uncanonicalized to avoid exceeding size limits.
22943
22944
22945
22946
22947
22948
22949
22950
22951
22952
22953
22954
22955
22956
22957
22958
22959
22960
22961
22962
22963
22964
22965
22966
22967
22968
22969
22970
22971
22972
22973
22974
22975
22976
22977
22978cat >>confdefs.h <<_ACEOF
22979#define EMACS_CONFIGURATION "${canonical}"
22980_ACEOF
22981
22982
22983cat >>confdefs.h <<_ACEOF
22984#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
22985_ACEOF
22986
22987
22988cat >>confdefs.h <<_ACEOF
22989#define config_machfile "${machfile}"
22990_ACEOF
22991
22992
22993cat >>confdefs.h <<_ACEOF
22994#define config_opsysfile "${opsysfile}"
22995_ACEOF
22996
22997
22998cat >>confdefs.h <<_ACEOF
22999#define LD_SWITCH_X_SITE ${LD_SWITCH_X_SITE}
23000_ACEOF
23001
23002
23003cat >>confdefs.h <<_ACEOF
23004#define LD_SWITCH_X_SITE_AUX ${LD_SWITCH_X_SITE_AUX}
23005_ACEOF
23006
23007
23008cat >>confdefs.h <<_ACEOF
23009#define C_SWITCH_X_SITE ${C_SWITCH_X_SITE}
23010_ACEOF
23011
23012
23013cat >>confdefs.h <<_ACEOF
23014#define UNEXEC_SRC ${UNEXEC_SRC}
23015_ACEOF
23016
23017
23018if test "${HAVE_X_WINDOWS}" = "yes" ; then
23019
23020cat >>confdefs.h <<\_ACEOF
23021#define HAVE_X_WINDOWS 1
23022_ACEOF
23023
23024fi
23025if test "${USE_X_TOOLKIT}" != "none" ; then
23026
23027cat >>confdefs.h <<\_ACEOF
23028#define USE_X_TOOLKIT 1
23029_ACEOF
23030
23031fi
23032if test "${HAVE_X11}" = "yes" ; then
23033
23034cat >>confdefs.h <<\_ACEOF
23035#define HAVE_X11 1
23036_ACEOF
23037
23038fi
23039if test "${HAVE_XFREE386}" = "yes" ; then
23040
23041cat >>confdefs.h <<\_ACEOF
23042#define HAVE_XFREE386 1
23043_ACEOF
23044
23045fi
23046if test "${HAVE_MENUS}" = "yes" ; then
23047
23048cat >>confdefs.h <<\_ACEOF
23049#define HAVE_MENUS 1
23050_ACEOF
23051
23052fi
23053if test "${GNU_MALLOC}" = "yes" ; then
23054
23055cat >>confdefs.h <<\_ACEOF
23056#define GNU_MALLOC 1
23057_ACEOF
23058
23059fi
23060if test "${REL_ALLOC}" = "yes" ; then
23061
23062cat >>confdefs.h <<\_ACEOF
23063#define REL_ALLOC 1
23064_ACEOF
23065
23066fi
23067
23068
23069
23070
23071
23072#### Report on what we decided to do.
23073#### Report GTK as a toolkit, even if it doesn't use Xt.
23074#### It makes printing result more understandable as using GTK sets
23075#### toolkit_scroll_bars to yes by default.
23076if test "${HAVE_GTK}" = "yes"; then
23077  USE_X_TOOLKIT=GTK
23078fi
23079
23080echo "
23081Configured for \`${canonical}'.
23082
23083  Where should the build process find the source code?    ${srcdir}
23084  What operating system and machine description files should Emacs use?
23085        \`${opsysfile}' and \`${machfile}'
23086  What compiler should emacs be built with?               ${CC} ${CFLAGS}
23087  Should Emacs use the GNU version of malloc?             ${GNU_MALLOC}${GNU_MALLOC_reason}
23088  Should Emacs use a relocating allocator for buffers?    ${REL_ALLOC}
23089  Should Emacs use mmap(2) for buffer allocation?         $use_mmap_for_buffers
23090  What window system should Emacs use?                    ${window_system}
23091  What toolkit should Emacs use?                          ${USE_X_TOOLKIT}"
23092
23093if test -n "${x_includes}"; then
23094echo "  Where do we find X Windows header files?                ${x_includes}"
23095else
23096echo "  Where do we find X Windows header files?                Standard dirs"
23097fi
23098if test -n "${x_libraries}"; then
23099echo "  Where do we find X Windows libraries?                   ${x_libraries}"
23100else
23101echo "  Where do we find X Windows libraries?                   Standard dirs"
23102fi
23103
23104echo "  Does Emacs use -lXaw3d?                                 ${HAVE_XAW3D}"
23105echo "  Does Emacs use -lXpm?                                   ${HAVE_XPM}"
23106echo "  Does Emacs use -ljpeg?                                  ${HAVE_JPEG}"
23107echo "  Does Emacs use -ltiff?                                  ${HAVE_TIFF}"
23108echo "  Does Emacs use -lungif?                                 ${HAVE_GIF}"
23109echo "  Does Emacs use -lpng?                                   ${HAVE_PNG}"
23110echo "  Does Emacs use X toolkit scroll bars?                   ${USE_TOOLKIT_SCROLL_BARS}"
23111echo
23112
23113if test $USE_XASSERTS = yes; then
23114   echo "  Compiling with asserts turned on."
23115   CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
23116   echo
23117fi
23118
23119if test "$USE_X_TOOLKIT" = GTK; then
23120  case "$canonical" in
23121  *cygwin*)
23122    echo "There are known problems with Emacs and Gtk+ on cygwin, so you
23123  will probably get a crash on startup.  If this happens, please use another
23124  toolkit for Emacs.  See etc/PROBLEMS for more information."
23125  ;;
23126  esac
23127fi
23128
23129
23130
23131# Remove any trailing slashes in these variables.
23132test "${prefix}" != NONE &&
23133  prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
23134test "${exec_prefix}" != NONE &&
23135  exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
23136
23137## Check if the C preprocessor will convert `..' to `. .'.  If so, set
23138## CPP_NEED_TRADITIONAL to `yes' so that the code to generate Makefile
23139## from Makefile.c can correctly provide the arg `-traditional' to the
23140## C preprocessor.
23141
23142cat >conftest.$ac_ext <<_ACEOF
23143/* confdefs.h.  */
23144_ACEOF
23145cat confdefs.h >>conftest.$ac_ext
23146cat >>conftest.$ac_ext <<_ACEOF
23147/* end confdefs.h.  */
23148yes..yes
23149_ACEOF
23150if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23151  $EGREP "yes..yes" >/dev/null 2>&1; then
23152  CPP_NEED_TRADITIONAL=no
23153else
23154  CPP_NEED_TRADITIONAL=yes
23155fi
23156rm -f conftest*
23157
23158
23159ac_config_files="$ac_config_files Makefile lib-src/Makefile.c:lib-src/Makefile.in oldXMenu/Makefile man/Makefile lwlib/Makefile src/Makefile.c:src/Makefile.in lisp/Makefile lispref/Makefile lispintro/Makefile leim/Makefile"
23160
23161ac_config_commands="$ac_config_commands default"
23162
23163cat >confcache <<\_ACEOF
23164# This file is a shell script that caches the results of configure
23165# tests run on this system so they can be shared between configure
23166# scripts and configure runs, see configure's option --config-cache.
23167# It is not useful on other systems.  If it contains results you don't
23168# want to keep, you may remove or edit it.
23169#
23170# config.status only pays attention to the cache file if you give it
23171# the --recheck option to rerun configure.
23172#
23173# `ac_cv_env_foo' variables (set or unset) will be overridden when
23174# loading this file, other *unset* `ac_cv_foo' will be assigned the
23175# following values.
23176
23177_ACEOF
23178
23179# The following way of writing the cache mishandles newlines in values,
23180# but we know of no workaround that is simple, portable, and efficient.
23181# So, we kill variables containing newlines.
23182# Ultrix sh set writes to stderr and can't be redirected directly,
23183# and sets the high bit in the cache file unless we assign to the vars.
23184(
23185  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
23186    eval ac_val=\$$ac_var
23187    case $ac_val in #(
23188    *${as_nl}*)
23189      case $ac_var in #(
23190      *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
23191echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
23192      esac
23193      case $ac_var in #(
23194      _ | IFS | as_nl) ;; #(
23195      *) $as_unset $ac_var ;;
23196      esac ;;
23197    esac
23198  done
23199
23200  (set) 2>&1 |
23201    case $as_nl`(ac_space=' '; set) 2>&1` in #(
23202    *${as_nl}ac_space=\ *)
23203      # `set' does not quote correctly, so add quotes (double-quote
23204      # substitution turns \\\\ into \\, and sed turns \\ into \).
23205      sed -n \
23206	"s/'/'\\\\''/g;
23207	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
23208      ;; #(
23209    *)
23210      # `set' quotes correctly as required by POSIX, so do not add quotes.
23211      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
23212      ;;
23213    esac |
23214    sort
23215) |
23216  sed '
23217     /^ac_cv_env_/b end
23218     t clear
23219     :clear
23220     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
23221     t end
23222     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
23223     :end' >>confcache
23224if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
23225  if test -w "$cache_file"; then
23226    test "x$cache_file" != "x/dev/null" &&
23227      { echo "$as_me:$LINENO: updating cache $cache_file" >&5
23228echo "$as_me: updating cache $cache_file" >&6;}
23229    cat confcache >$cache_file
23230  else
23231    { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
23232echo "$as_me: not updating unwritable cache $cache_file" >&6;}
23233  fi
23234fi
23235rm -f confcache
23236
23237test "x$prefix" = xNONE && prefix=$ac_default_prefix
23238# Let make expand exec_prefix.
23239test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
23240
23241DEFS=-DHAVE_CONFIG_H
23242
23243ac_libobjs=
23244ac_ltlibobjs=
23245for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
23246  # 1. Remove the extension, and $U if already installed.
23247  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
23248  ac_i=`echo "$ac_i" | sed "$ac_script"`
23249  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
23250  #    will be set to the directory where LIBOBJS objects are built.
23251  ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
23252  ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
23253done
23254LIBOBJS=$ac_libobjs
23255
23256LTLIBOBJS=$ac_ltlibobjs
23257
23258
23259
23260: ${CONFIG_STATUS=./config.status}
23261ac_clean_files_save=$ac_clean_files
23262ac_clean_files="$ac_clean_files $CONFIG_STATUS"
23263{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
23264echo "$as_me: creating $CONFIG_STATUS" >&6;}
23265cat >$CONFIG_STATUS <<_ACEOF
23266#! $SHELL
23267# Generated by $as_me.
23268# Run this file to recreate the current configuration.
23269# Compiler output produced by configure, useful for debugging
23270# configure, is in config.log if it exists.
23271
23272debug=false
23273ac_cs_recheck=false
23274ac_cs_silent=false
23275SHELL=\${CONFIG_SHELL-$SHELL}
23276_ACEOF
23277
23278cat >>$CONFIG_STATUS <<\_ACEOF
23279## --------------------- ##
23280## M4sh Initialization.  ##
23281## --------------------- ##
23282
23283# Be more Bourne compatible
23284DUALCASE=1; export DUALCASE # for MKS sh
23285if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
23286  emulate sh
23287  NULLCMD=:
23288  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
23289  # is contrary to our usage.  Disable this feature.
23290  alias -g '${1+"$@"}'='"$@"'
23291  setopt NO_GLOB_SUBST
23292else
23293  case `(set -o) 2>/dev/null` in
23294  *posix*) set -o posix ;;
23295esac
23296
23297fi
23298
23299
23300
23301
23302# PATH needs CR
23303# Avoid depending upon Character Ranges.
23304as_cr_letters='abcdefghijklmnopqrstuvwxyz'
23305as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
23306as_cr_Letters=$as_cr_letters$as_cr_LETTERS
23307as_cr_digits='0123456789'
23308as_cr_alnum=$as_cr_Letters$as_cr_digits
23309
23310# The user is always right.
23311if test "${PATH_SEPARATOR+set}" != set; then
23312  echo "#! /bin/sh" >conf$$.sh
23313  echo  "exit 0"   >>conf$$.sh
23314  chmod +x conf$$.sh
23315  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
23316    PATH_SEPARATOR=';'
23317  else
23318    PATH_SEPARATOR=:
23319  fi
23320  rm -f conf$$.sh
23321fi
23322
23323# Support unset when possible.
23324if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
23325  as_unset=unset
23326else
23327  as_unset=false
23328fi
23329
23330
23331# IFS
23332# We need space, tab and new line, in precisely that order.  Quoting is
23333# there to prevent editors from complaining about space-tab.
23334# (If _AS_PATH_WALK were called with IFS unset, it would disable word
23335# splitting by setting IFS to empty value.)
23336as_nl='
23337'
23338IFS=" ""	$as_nl"
23339
23340# Find who we are.  Look in the path if we contain no directory separator.
23341case $0 in
23342  *[\\/]* ) as_myself=$0 ;;
23343  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23344for as_dir in $PATH
23345do
23346  IFS=$as_save_IFS
23347  test -z "$as_dir" && as_dir=.
23348  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
23349done
23350IFS=$as_save_IFS
23351
23352     ;;
23353esac
23354# We did not find ourselves, most probably we were run as `sh COMMAND'
23355# in which case we are not to be found in the path.
23356if test "x$as_myself" = x; then
23357  as_myself=$0
23358fi
23359if test ! -f "$as_myself"; then
23360  echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
23361  { (exit 1); exit 1; }
23362fi
23363
23364# Work around bugs in pre-3.0 UWIN ksh.
23365for as_var in ENV MAIL MAILPATH
23366do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
23367done
23368PS1='$ '
23369PS2='> '
23370PS4='+ '
23371
23372# NLS nuisances.
23373for as_var in \
23374  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
23375  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
23376  LC_TELEPHONE LC_TIME
23377do
23378  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
23379    eval $as_var=C; export $as_var
23380  else
23381    ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
23382  fi
23383done
23384
23385# Required to use basename.
23386if expr a : '\(a\)' >/dev/null 2>&1 &&
23387   test "X`expr 00001 : '.*\(...\)'`" = X001; then
23388  as_expr=expr
23389else
23390  as_expr=false
23391fi
23392
23393if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
23394  as_basename=basename
23395else
23396  as_basename=false
23397fi
23398
23399
23400# Name of the executable.
23401as_me=`$as_basename -- "$0" ||
23402$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
23403	 X"$0" : 'X\(//\)$' \| \
23404	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
23405echo X/"$0" |
23406    sed '/^.*\/\([^/][^/]*\)\/*$/{
23407	    s//\1/
23408	    q
23409	  }
23410	  /^X\/\(\/\/\)$/{
23411	    s//\1/
23412	    q
23413	  }
23414	  /^X\/\(\/\).*/{
23415	    s//\1/
23416	    q
23417	  }
23418	  s/.*/./; q'`
23419
23420# CDPATH.
23421$as_unset CDPATH
23422
23423
23424
23425  as_lineno_1=$LINENO
23426  as_lineno_2=$LINENO
23427  test "x$as_lineno_1" != "x$as_lineno_2" &&
23428  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
23429
23430  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
23431  # uniformly replaced by the line number.  The first 'sed' inserts a
23432  # line-number line after each line using $LINENO; the second 'sed'
23433  # does the real work.  The second script uses 'N' to pair each
23434  # line-number line with the line containing $LINENO, and appends
23435  # trailing '-' during substitution so that $LINENO is not a special
23436  # case at line end.
23437  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
23438  # scripts with optimization help from Paolo Bonzini.  Blame Lee
23439  # E. McMahon (1931-1989) for sed's syntax.  :-)
23440  sed -n '
23441    p
23442    /[$]LINENO/=
23443  ' <$as_myself |
23444    sed '
23445      s/[$]LINENO.*/&-/
23446      t lineno
23447      b
23448      :lineno
23449      N
23450      :loop
23451      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
23452      t loop
23453      s/-\n.*//
23454    ' >$as_me.lineno &&
23455  chmod +x "$as_me.lineno" ||
23456    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
23457   { (exit 1); exit 1; }; }
23458
23459  # Don't try to exec as it changes $[0], causing all sort of problems
23460  # (the dirname of $[0] is not the place where we might find the
23461  # original and so on.  Autoconf is especially sensitive to this).
23462  . "./$as_me.lineno"
23463  # Exit status is that of the last command.
23464  exit
23465}
23466
23467
23468if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
23469  as_dirname=dirname
23470else
23471  as_dirname=false
23472fi
23473
23474ECHO_C= ECHO_N= ECHO_T=
23475case `echo -n x` in
23476-n*)
23477  case `echo 'x\c'` in
23478  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
23479  *)   ECHO_C='\c';;
23480  esac;;
23481*)
23482  ECHO_N='-n';;
23483esac
23484
23485if expr a : '\(a\)' >/dev/null 2>&1 &&
23486   test "X`expr 00001 : '.*\(...\)'`" = X001; then
23487  as_expr=expr
23488else
23489  as_expr=false
23490fi
23491
23492rm -f conf$$ conf$$.exe conf$$.file
23493if test -d conf$$.dir; then
23494  rm -f conf$$.dir/conf$$.file
23495else
23496  rm -f conf$$.dir
23497  mkdir conf$$.dir
23498fi
23499echo >conf$$.file
23500if ln -s conf$$.file conf$$ 2>/dev/null; then
23501  as_ln_s='ln -s'
23502  # ... but there are two gotchas:
23503  # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
23504  # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
23505  # In both cases, we have to default to `cp -p'.
23506  ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
23507    as_ln_s='cp -p'
23508elif ln conf$$.file conf$$ 2>/dev/null; then
23509  as_ln_s=ln
23510else
23511  as_ln_s='cp -p'
23512fi
23513rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
23514rmdir conf$$.dir 2>/dev/null
23515
23516if mkdir -p . 2>/dev/null; then
23517  as_mkdir_p=:
23518else
23519  test -d ./-p && rmdir ./-p
23520  as_mkdir_p=false
23521fi
23522
23523if test -x / >/dev/null 2>&1; then
23524  as_test_x='test -x'
23525else
23526  if ls -dL / >/dev/null 2>&1; then
23527    as_ls_L_option=L
23528  else
23529    as_ls_L_option=
23530  fi
23531  as_test_x='
23532    eval sh -c '\''
23533      if test -d "$1"; then
23534        test -d "$1/.";
23535      else
23536	case $1 in
23537        -*)set "./$1";;
23538	esac;
23539	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
23540	???[sx]*):;;*)false;;esac;fi
23541    '\'' sh
23542  '
23543fi
23544as_executable_p=$as_test_x
23545
23546# Sed expression to map a string onto a valid CPP name.
23547as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
23548
23549# Sed expression to map a string onto a valid variable name.
23550as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
23551
23552
23553exec 6>&1
23554
23555# Save the log message, to keep $[0] and so on meaningful, and to
23556# report actual input values of CONFIG_FILES etc. instead of their
23557# values after options handling.
23558ac_log="
23559This file was extended by $as_me, which was
23560generated by GNU Autoconf 2.61.  Invocation command line was
23561
23562  CONFIG_FILES    = $CONFIG_FILES
23563  CONFIG_HEADERS  = $CONFIG_HEADERS
23564  CONFIG_LINKS    = $CONFIG_LINKS
23565  CONFIG_COMMANDS = $CONFIG_COMMANDS
23566  $ $0 $@
23567
23568on `(hostname || uname -n) 2>/dev/null | sed 1q`
23569"
23570
23571_ACEOF
23572
23573cat >>$CONFIG_STATUS <<_ACEOF
23574# Files that config.status was made for.
23575config_files="$ac_config_files"
23576config_headers="$ac_config_headers"
23577config_commands="$ac_config_commands"
23578
23579_ACEOF
23580
23581cat >>$CONFIG_STATUS <<\_ACEOF
23582ac_cs_usage="\
23583\`$as_me' instantiates files from templates according to the
23584current configuration.
23585
23586Usage: $0 [OPTIONS] [FILE]...
23587
23588  -h, --help       print this help, then exit
23589  -V, --version    print version number and configuration settings, then exit
23590  -q, --quiet      do not print progress messages
23591  -d, --debug      don't remove temporary files
23592      --recheck    update $as_me by reconfiguring in the same conditions
23593  --file=FILE[:TEMPLATE]
23594		   instantiate the configuration file FILE
23595  --header=FILE[:TEMPLATE]
23596		   instantiate the configuration header FILE
23597
23598Configuration files:
23599$config_files
23600
23601Configuration headers:
23602$config_headers
23603
23604Configuration commands:
23605$config_commands
23606
23607Report bugs to <bug-autoconf@gnu.org>."
23608
23609_ACEOF
23610cat >>$CONFIG_STATUS <<_ACEOF
23611ac_cs_version="\\
23612config.status
23613configured by $0, generated by GNU Autoconf 2.61,
23614  with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
23615
23616Copyright (C) 2006 Free Software Foundation, Inc.
23617This config.status script is free software; the Free Software Foundation
23618gives unlimited permission to copy, distribute and modify it."
23619
23620ac_pwd='$ac_pwd'
23621srcdir='$srcdir'
23622INSTALL='$INSTALL'
23623_ACEOF
23624
23625cat >>$CONFIG_STATUS <<\_ACEOF
23626# If no file are specified by the user, then we need to provide default
23627# value.  By we need to know if files were specified by the user.
23628ac_need_defaults=:
23629while test $# != 0
23630do
23631  case $1 in
23632  --*=*)
23633    ac_option=`expr "X$1" : 'X\([^=]*\)='`
23634    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
23635    ac_shift=:
23636    ;;
23637  *)
23638    ac_option=$1
23639    ac_optarg=$2
23640    ac_shift=shift
23641    ;;
23642  esac
23643
23644  case $ac_option in
23645  # Handling of the options.
23646  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
23647    ac_cs_recheck=: ;;
23648  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
23649    echo "$ac_cs_version"; exit ;;
23650  --debug | --debu | --deb | --de | --d | -d )
23651    debug=: ;;
23652  --file | --fil | --fi | --f )
23653    $ac_shift
23654    CONFIG_FILES="$CONFIG_FILES $ac_optarg"
23655    ac_need_defaults=false;;
23656  --header | --heade | --head | --hea )
23657    $ac_shift
23658    CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
23659    ac_need_defaults=false;;
23660  --he | --h)
23661    # Conflict between --help and --header
23662    { echo "$as_me: error: ambiguous option: $1
23663Try \`$0 --help' for more information." >&2
23664   { (exit 1); exit 1; }; };;
23665  --help | --hel | -h )
23666    echo "$ac_cs_usage"; exit ;;
23667  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
23668  | -silent | --silent | --silen | --sile | --sil | --si | --s)
23669    ac_cs_silent=: ;;
23670
23671  # This is an error.
23672  -*) { echo "$as_me: error: unrecognized option: $1
23673Try \`$0 --help' for more information." >&2
23674   { (exit 1); exit 1; }; } ;;
23675
23676  *) ac_config_targets="$ac_config_targets $1"
23677     ac_need_defaults=false ;;
23678
23679  esac
23680  shift
23681done
23682
23683ac_configure_extra_args=
23684
23685if $ac_cs_silent; then
23686  exec 6>/dev/null
23687  ac_configure_extra_args="$ac_configure_extra_args --silent"
23688fi
23689
23690_ACEOF
23691cat >>$CONFIG_STATUS <<_ACEOF
23692if \$ac_cs_recheck; then
23693  echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
23694  CONFIG_SHELL=$SHELL
23695  export CONFIG_SHELL
23696  exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
23697fi
23698
23699_ACEOF
23700cat >>$CONFIG_STATUS <<\_ACEOF
23701exec 5>>config.log
23702{
23703  echo
23704  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
23705## Running $as_me. ##
23706_ASBOX
23707  echo "$ac_log"
23708} >&5
23709
23710_ACEOF
23711cat >>$CONFIG_STATUS <<_ACEOF
23712#
23713# INIT-COMMANDS
23714#
23715GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPP_NEED_TRADITIONAL="$CPP_NEED_TRADITIONAL" CPPFLAGS="$CPPFLAGS"
23716
23717_ACEOF
23718
23719cat >>$CONFIG_STATUS <<\_ACEOF
23720
23721# Handling of arguments.
23722for ac_config_target in $ac_config_targets
23723do
23724  case $ac_config_target in
23725    "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
23726    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
23727    "lib-src/Makefile.c") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile.c:lib-src/Makefile.in" ;;
23728    "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
23729    "man/Makefile") CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
23730    "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
23731    "src/Makefile.c") CONFIG_FILES="$CONFIG_FILES src/Makefile.c:src/Makefile.in" ;;
23732    "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23733    "lispref/Makefile") CONFIG_FILES="$CONFIG_FILES lispref/Makefile" ;;
23734    "lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES lispintro/Makefile" ;;
23735    "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
23736    "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
23737
23738  *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
23739echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
23740   { (exit 1); exit 1; }; };;
23741  esac
23742done
23743
23744
23745# If the user did not use the arguments to specify the items to instantiate,
23746# then the envvar interface is used.  Set only those that are not.
23747# We use the long form for the default assignment because of an extremely
23748# bizarre bug on SunOS 4.1.3.
23749if $ac_need_defaults; then
23750  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23751  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23752  test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
23753fi
23754
23755# Have a temporary directory for convenience.  Make it in the build tree
23756# simply because there is no reason against having it here, and in addition,
23757# creating and moving files from /tmp can sometimes cause problems.
23758# Hook for its removal unless debugging.
23759# Note that there is a small window in which the directory will not be cleaned:
23760# after its creation but before its name has been assigned to `$tmp'.
23761$debug ||
23762{
23763  tmp=
23764  trap 'exit_status=$?
23765  { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
23766' 0
23767  trap '{ (exit 1); exit 1; }' 1 2 13 15
23768}
23769# Create a (secure) tmp directory for tmp files.
23770
23771{
23772  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
23773  test -n "$tmp" && test -d "$tmp"
23774}  ||
23775{
23776  tmp=./conf$$-$RANDOM
23777  (umask 077 && mkdir "$tmp")
23778} ||
23779{
23780   echo "$me: cannot create a temporary directory in ." >&2
23781   { (exit 1); exit 1; }
23782}
23783
23784#
23785# Set up the sed scripts for CONFIG_FILES section.
23786#
23787
23788# No need to generate the scripts if there are no CONFIG_FILES.
23789# This happens for instance when ./config.status config.h
23790if test -n "$CONFIG_FILES"; then
23791
23792_ACEOF
23793
23794
23795
23796ac_delim='%!_!# '
23797for ac_last_try in false false false false false :; do
23798  cat >conf$$subs.sed <<_ACEOF
23799SHELL!$SHELL$ac_delim
23800PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
23801PACKAGE_NAME!$PACKAGE_NAME$ac_delim
23802PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
23803PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
23804PACKAGE_STRING!$PACKAGE_STRING$ac_delim
23805PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
23806exec_prefix!$exec_prefix$ac_delim
23807prefix!$prefix$ac_delim
23808program_transform_name!$program_transform_name$ac_delim
23809bindir!$bindir$ac_delim
23810sbindir!$sbindir$ac_delim
23811libexecdir!$libexecdir$ac_delim
23812datarootdir!$datarootdir$ac_delim
23813datadir!$datadir$ac_delim
23814sysconfdir!$sysconfdir$ac_delim
23815sharedstatedir!$sharedstatedir$ac_delim
23816localstatedir!$localstatedir$ac_delim
23817includedir!$includedir$ac_delim
23818oldincludedir!$oldincludedir$ac_delim
23819docdir!$docdir$ac_delim
23820infodir!$infodir$ac_delim
23821htmldir!$htmldir$ac_delim
23822dvidir!$dvidir$ac_delim
23823pdfdir!$pdfdir$ac_delim
23824psdir!$psdir$ac_delim
23825libdir!$libdir$ac_delim
23826localedir!$localedir$ac_delim
23827mandir!$mandir$ac_delim
23828DEFS!$DEFS$ac_delim
23829ECHO_C!$ECHO_C$ac_delim
23830ECHO_N!$ECHO_N$ac_delim
23831ECHO_T!$ECHO_T$ac_delim
23832LIBS!$LIBS$ac_delim
23833build_alias!$build_alias$ac_delim
23834host_alias!$host_alias$ac_delim
23835target_alias!$target_alias$ac_delim
23836MAINT!$MAINT$ac_delim
23837build!$build$ac_delim
23838build_cpu!$build_cpu$ac_delim
23839build_vendor!$build_vendor$ac_delim
23840build_os!$build_os$ac_delim
23841host!$host$ac_delim
23842host_cpu!$host_cpu$ac_delim
23843host_vendor!$host_vendor$ac_delim
23844host_os!$host_os$ac_delim
23845CC!$CC$ac_delim
23846CFLAGS!$CFLAGS$ac_delim
23847LDFLAGS!$LDFLAGS$ac_delim
23848CPPFLAGS!$CPPFLAGS$ac_delim
23849ac_ct_CC!$ac_ct_CC$ac_delim
23850EXEEXT!$EXEEXT$ac_delim
23851OBJEXT!$OBJEXT$ac_delim
23852CPP!$CPP$ac_delim
23853GREP!$GREP$ac_delim
23854EGREP!$EGREP$ac_delim
23855LN_S!$LN_S$ac_delim
23856INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
23857INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
23858INSTALL_DATA!$INSTALL_DATA$ac_delim
23859RANLIB!$RANLIB$ac_delim
23860INSTALL_INFO!$INSTALL_INFO$ac_delim
23861GZIP_PROG!$GZIP_PROG$ac_delim
23862LIBSOUND!$LIBSOUND$ac_delim
23863PKG_CONFIG!$PKG_CONFIG$ac_delim
23864ALSA_CFLAGS!$ALSA_CFLAGS$ac_delim
23865ALSA_LIBS!$ALSA_LIBS$ac_delim
23866CFLAGS_SOUND!$CFLAGS_SOUND$ac_delim
23867SET_MAKE!$SET_MAKE$ac_delim
23868XMKMF!$XMKMF$ac_delim
23869GTK_CFLAGS!$GTK_CFLAGS$ac_delim
23870GTK_LIBS!$GTK_LIBS$ac_delim
23871XFT_CFLAGS!$XFT_CFLAGS$ac_delim
23872XFT_LIBS!$XFT_LIBS$ac_delim
23873ALLOCA!$ALLOCA$ac_delim
23874liblockfile!$liblockfile$ac_delim
23875LIBOBJS!$LIBOBJS$ac_delim
23876NEED_SETGID!$NEED_SETGID$ac_delim
23877KMEM_GROUP!$KMEM_GROUP$ac_delim
23878GETLOADAVG_LIBS!$GETLOADAVG_LIBS$ac_delim
23879GETOPT_H!$GETOPT_H$ac_delim
23880GETOPTOBJS!$GETOPTOBJS$ac_delim
23881version!$version$ac_delim
23882configuration!$configuration$ac_delim
23883canonical!$canonical$ac_delim
23884srcdir!$srcdir$ac_delim
23885lispdir!$lispdir$ac_delim
23886locallisppath!$locallisppath$ac_delim
23887lisppath!$lisppath$ac_delim
23888x_default_search_path!$x_default_search_path$ac_delim
23889etcdir!$etcdir$ac_delim
23890archlibdir!$archlibdir$ac_delim
23891bitmapdir!$bitmapdir$ac_delim
23892gamedir!$gamedir$ac_delim
23893gameuser!$gameuser$ac_delim
23894c_switch_system!$c_switch_system$ac_delim
23895c_switch_machine!$c_switch_machine$ac_delim
23896_ACEOF
23897
23898  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
23899    break
23900  elif $ac_last_try; then
23901    { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
23902echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
23903   { (exit 1); exit 1; }; }
23904  else
23905    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23906  fi
23907done
23908
23909ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
23910if test -n "$ac_eof"; then
23911  ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
23912  ac_eof=`expr $ac_eof + 1`
23913fi
23914
23915cat >>$CONFIG_STATUS <<_ACEOF
23916cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
23917/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23918_ACEOF
23919sed '
23920s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
23921s/^/s,@/; s/!/@,|#_!!_#|/
23922:n
23923t n
23924s/'"$ac_delim"'$/,g/; t
23925s/$/\\/; p
23926N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
23927' >>$CONFIG_STATUS <conf$$subs.sed
23928rm -f conf$$subs.sed
23929cat >>$CONFIG_STATUS <<_ACEOF
23930CEOF$ac_eof
23931_ACEOF
23932
23933
23934ac_delim='%!_!# '
23935for ac_last_try in false false false false false :; do
23936  cat >conf$$subs.sed <<_ACEOF
23937LD_SWITCH_X_SITE!$LD_SWITCH_X_SITE$ac_delim
23938LD_SWITCH_X_SITE_AUX!$LD_SWITCH_X_SITE_AUX$ac_delim
23939C_SWITCH_X_SITE!$C_SWITCH_X_SITE$ac_delim
23940X_TOOLKIT_TYPE!$X_TOOLKIT_TYPE$ac_delim
23941machfile!$machfile$ac_delim
23942opsysfile!$opsysfile$ac_delim
23943carbon_appdir!$carbon_appdir$ac_delim
23944LTLIBOBJS!$LTLIBOBJS$ac_delim
23945_ACEOF
23946
23947  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 8; then
23948    break
23949  elif $ac_last_try; then
23950    { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
23951echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
23952   { (exit 1); exit 1; }; }
23953  else
23954    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23955  fi
23956done
23957
23958ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
23959if test -n "$ac_eof"; then
23960  ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
23961  ac_eof=`expr $ac_eof + 1`
23962fi
23963
23964cat >>$CONFIG_STATUS <<_ACEOF
23965cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
23966/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
23967_ACEOF
23968sed '
23969s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
23970s/^/s,@/; s/!/@,|#_!!_#|/
23971:n
23972t n
23973s/'"$ac_delim"'$/,g/; t
23974s/$/\\/; p
23975N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
23976' >>$CONFIG_STATUS <conf$$subs.sed
23977rm -f conf$$subs.sed
23978cat >>$CONFIG_STATUS <<_ACEOF
23979:end
23980s/|#_!!_#|//g
23981CEOF$ac_eof
23982_ACEOF
23983
23984
23985# VPATH may cause trouble with some makes, so we remove $(srcdir),
23986# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
23987# trailing colons and then remove the whole line if VPATH becomes empty
23988# (actually we leave an empty line to preserve line numbers).
23989if test "x$srcdir" = x.; then
23990  ac_vpsub='/^[	 ]*VPATH[	 ]*=/{
23991s/:*\$(srcdir):*/:/
23992s/:*\${srcdir}:*/:/
23993s/:*@srcdir@:*/:/
23994s/^\([^=]*=[	 ]*\):*/\1/
23995s/:*$//
23996s/^[^=]*=[	 ]*$//
23997}'
23998fi
23999
24000cat >>$CONFIG_STATUS <<\_ACEOF
24001fi # test -n "$CONFIG_FILES"
24002
24003
24004for ac_tag in  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS
24005do
24006  case $ac_tag in
24007  :[FHLC]) ac_mode=$ac_tag; continue;;
24008  esac
24009  case $ac_mode$ac_tag in
24010  :[FHL]*:*);;
24011  :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
24012echo "$as_me: error: Invalid tag $ac_tag." >&2;}
24013   { (exit 1); exit 1; }; };;
24014  :[FH]-) ac_tag=-:-;;
24015  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
24016  esac
24017  ac_save_IFS=$IFS
24018  IFS=:
24019  set x $ac_tag
24020  IFS=$ac_save_IFS
24021  shift
24022  ac_file=$1
24023  shift
24024
24025  case $ac_mode in
24026  :L) ac_source=$1;;
24027  :[FH])
24028    ac_file_inputs=
24029    for ac_f
24030    do
24031      case $ac_f in
24032      -) ac_f="$tmp/stdin";;
24033      *) # Look for the file first in the build tree, then in the source tree
24034	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
24035	 # because $ac_f cannot contain `:'.
24036	 test -f "$ac_f" ||
24037	   case $ac_f in
24038	   [\\/$]*) false;;
24039	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
24040	   esac ||
24041	   { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
24042echo "$as_me: error: cannot find input file: $ac_f" >&2;}
24043   { (exit 1); exit 1; }; };;
24044      esac
24045      ac_file_inputs="$ac_file_inputs $ac_f"
24046    done
24047
24048    # Let's still pretend it is `configure' which instantiates (i.e., don't
24049    # use $as_me), people would be surprised to read:
24050    #    /* config.h.  Generated by config.status.  */
24051    configure_input="Generated from "`IFS=:
24052	  echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
24053    if test x"$ac_file" != x-; then
24054      configure_input="$ac_file.  $configure_input"
24055      { echo "$as_me:$LINENO: creating $ac_file" >&5
24056echo "$as_me: creating $ac_file" >&6;}
24057    fi
24058
24059    case $ac_tag in
24060    *:-:* | *:-) cat >"$tmp/stdin";;
24061    esac
24062    ;;
24063  esac
24064
24065  ac_dir=`$as_dirname -- "$ac_file" ||
24066$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24067	 X"$ac_file" : 'X\(//\)[^/]' \| \
24068	 X"$ac_file" : 'X\(//\)$' \| \
24069	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
24070echo X"$ac_file" |
24071    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24072	    s//\1/
24073	    q
24074	  }
24075	  /^X\(\/\/\)[^/].*/{
24076	    s//\1/
24077	    q
24078	  }
24079	  /^X\(\/\/\)$/{
24080	    s//\1/
24081	    q
24082	  }
24083	  /^X\(\/\).*/{
24084	    s//\1/
24085	    q
24086	  }
24087	  s/.*/./; q'`
24088  { as_dir="$ac_dir"
24089  case $as_dir in #(
24090  -*) as_dir=./$as_dir;;
24091  esac
24092  test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
24093    as_dirs=
24094    while :; do
24095      case $as_dir in #(
24096      *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
24097      *) as_qdir=$as_dir;;
24098      esac
24099      as_dirs="'$as_qdir' $as_dirs"
24100      as_dir=`$as_dirname -- "$as_dir" ||
24101$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24102	 X"$as_dir" : 'X\(//\)[^/]' \| \
24103	 X"$as_dir" : 'X\(//\)$' \| \
24104	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
24105echo X"$as_dir" |
24106    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24107	    s//\1/
24108	    q
24109	  }
24110	  /^X\(\/\/\)[^/].*/{
24111	    s//\1/
24112	    q
24113	  }
24114	  /^X\(\/\/\)$/{
24115	    s//\1/
24116	    q
24117	  }
24118	  /^X\(\/\).*/{
24119	    s//\1/
24120	    q
24121	  }
24122	  s/.*/./; q'`
24123      test -d "$as_dir" && break
24124    done
24125    test -z "$as_dirs" || eval "mkdir $as_dirs"
24126  } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
24127echo "$as_me: error: cannot create directory $as_dir" >&2;}
24128   { (exit 1); exit 1; }; }; }
24129  ac_builddir=.
24130
24131case "$ac_dir" in
24132.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
24133*)
24134  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
24135  # A ".." for each directory in $ac_dir_suffix.
24136  ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
24137  case $ac_top_builddir_sub in
24138  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
24139  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
24140  esac ;;
24141esac
24142ac_abs_top_builddir=$ac_pwd
24143ac_abs_builddir=$ac_pwd$ac_dir_suffix
24144# for backward compatibility:
24145ac_top_builddir=$ac_top_build_prefix
24146
24147case $srcdir in
24148  .)  # We are building in place.
24149    ac_srcdir=.
24150    ac_top_srcdir=$ac_top_builddir_sub
24151    ac_abs_top_srcdir=$ac_pwd ;;
24152  [\\/]* | ?:[\\/]* )  # Absolute name.
24153    ac_srcdir=$srcdir$ac_dir_suffix;
24154    ac_top_srcdir=$srcdir
24155    ac_abs_top_srcdir=$srcdir ;;
24156  *) # Relative name.
24157    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
24158    ac_top_srcdir=$ac_top_build_prefix$srcdir
24159    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
24160esac
24161ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
24162
24163
24164  case $ac_mode in
24165  :F)
24166  #
24167  # CONFIG_FILE
24168  #
24169
24170  case $INSTALL in
24171  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
24172  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
24173  esac
24174_ACEOF
24175
24176cat >>$CONFIG_STATUS <<\_ACEOF
24177# If the template does not know about datarootdir, expand it.
24178# FIXME: This hack should be removed a few years after 2.60.
24179ac_datarootdir_hack=; ac_datarootdir_seen=
24180
24181case `sed -n '/datarootdir/ {
24182  p
24183  q
24184}
24185/@datadir@/p
24186/@docdir@/p
24187/@infodir@/p
24188/@localedir@/p
24189/@mandir@/p
24190' $ac_file_inputs` in
24191*datarootdir*) ac_datarootdir_seen=yes;;
24192*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
24193  { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
24194echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
24195_ACEOF
24196cat >>$CONFIG_STATUS <<_ACEOF
24197  ac_datarootdir_hack='
24198  s&@datadir@&$datadir&g
24199  s&@docdir@&$docdir&g
24200  s&@infodir@&$infodir&g
24201  s&@localedir@&$localedir&g
24202  s&@mandir@&$mandir&g
24203    s&\\\${datarootdir}&$datarootdir&g' ;;
24204esac
24205_ACEOF
24206
24207# Neutralize VPATH when `$srcdir' = `.'.
24208# Shell code in configure.ac might set extrasub.
24209# FIXME: do we really want to maintain this feature?
24210cat >>$CONFIG_STATUS <<_ACEOF
24211  sed "$ac_vpsub
24212$extrasub
24213_ACEOF
24214cat >>$CONFIG_STATUS <<\_ACEOF
24215:t
24216/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
24217s&@configure_input@&$configure_input&;t t
24218s&@top_builddir@&$ac_top_builddir_sub&;t t
24219s&@srcdir@&$ac_srcdir&;t t
24220s&@abs_srcdir@&$ac_abs_srcdir&;t t
24221s&@top_srcdir@&$ac_top_srcdir&;t t
24222s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
24223s&@builddir@&$ac_builddir&;t t
24224s&@abs_builddir@&$ac_abs_builddir&;t t
24225s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
24226s&@INSTALL@&$ac_INSTALL&;t t
24227$ac_datarootdir_hack
24228" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
24229
24230test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
24231  { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
24232  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
24233  { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
24234which seems to be undefined.  Please make sure it is defined." >&5
24235echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
24236which seems to be undefined.  Please make sure it is defined." >&2;}
24237
24238  rm -f "$tmp/stdin"
24239  case $ac_file in
24240  -) cat "$tmp/out"; rm -f "$tmp/out";;
24241  *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
24242  esac
24243 ;;
24244  :H)
24245  #
24246  # CONFIG_HEADER
24247  #
24248_ACEOF
24249
24250# Transform confdefs.h into a sed script `conftest.defines', that
24251# substitutes the proper values into config.h.in to produce config.h.
24252rm -f conftest.defines conftest.tail
24253# First, append a space to every undef/define line, to ease matching.
24254echo 's/$/ /' >conftest.defines
24255# Then, protect against being on the right side of a sed subst, or in
24256# an unquoted here document, in config.status.  If some macros were
24257# called several times there might be several #defines for the same
24258# symbol, which is useless.  But do not sort them, since the last
24259# AC_DEFINE must be honored.
24260ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
24261# These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where
24262# NAME is the cpp macro being defined, VALUE is the value it is being given.
24263# PARAMS is the parameter list in the macro definition--in most cases, it's
24264# just an empty string.
24265ac_dA='s,^\\([	 #]*\\)[^	 ]*\\([	 ]*'
24266ac_dB='\\)[	 (].*,\\1define\\2'
24267ac_dC=' '
24268ac_dD=' ,'
24269
24270uniq confdefs.h |
24271  sed -n '
24272	t rset
24273	:rset
24274	s/^[	 ]*#[	 ]*define[	 ][	 ]*//
24275	t ok
24276	d
24277	:ok
24278	s/[\\&,]/\\&/g
24279	s/^\('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p
24280	s/^\('"$ac_word_re"'\)[	 ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p
24281  ' >>conftest.defines
24282
24283# Remove the space that was appended to ease matching.
24284# Then replace #undef with comments.  This is necessary, for
24285# example, in the case of _POSIX_SOURCE, which is predefined and required
24286# on some systems where configure will not decide to define it.
24287# (The regexp can be short, since the line contains either #define or #undef.)
24288echo 's/ $//
24289s,^[	 #]*u.*,/* & */,' >>conftest.defines
24290
24291# Break up conftest.defines:
24292ac_max_sed_lines=50
24293
24294# First sed command is:	 sed -f defines.sed $ac_file_inputs >"$tmp/out1"
24295# Second one is:	 sed -f defines.sed "$tmp/out1" >"$tmp/out2"
24296# Third one will be:	 sed -f defines.sed "$tmp/out2" >"$tmp/out1"
24297# et cetera.
24298ac_in='$ac_file_inputs'
24299ac_out='"$tmp/out1"'
24300ac_nxt='"$tmp/out2"'
24301
24302while :
24303do
24304  # Write a here document:
24305    cat >>$CONFIG_STATUS <<_ACEOF
24306    # First, check the format of the line:
24307    cat >"\$tmp/defines.sed" <<\\CEOF
24308/^[	 ]*#[	 ]*undef[	 ][	 ]*$ac_word_re[	 ]*\$/b def
24309/^[	 ]*#[	 ]*define[	 ][	 ]*$ac_word_re[(	 ]/b def
24310b
24311:def
24312_ACEOF
24313  sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS
24314  echo 'CEOF
24315    sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS
24316  ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in
24317  sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail
24318  grep . conftest.tail >/dev/null || break
24319  rm -f conftest.defines
24320  mv conftest.tail conftest.defines
24321done
24322rm -f conftest.defines conftest.tail
24323
24324echo "ac_result=$ac_in" >>$CONFIG_STATUS
24325cat >>$CONFIG_STATUS <<\_ACEOF
24326  if test x"$ac_file" != x-; then
24327    echo "/* $configure_input  */" >"$tmp/config.h"
24328    cat "$ac_result" >>"$tmp/config.h"
24329    if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then
24330      { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
24331echo "$as_me: $ac_file is unchanged" >&6;}
24332    else
24333      rm -f $ac_file
24334      mv "$tmp/config.h" $ac_file
24335    fi
24336  else
24337    echo "/* $configure_input  */"
24338    cat "$ac_result"
24339  fi
24340  rm -f "$tmp/out12"
24341 ;;
24342
24343  :C)  { echo "$as_me:$LINENO: executing $ac_file commands" >&5
24344echo "$as_me: executing $ac_file commands" >&6;}
24345 ;;
24346  esac
24347
24348
24349  case $ac_file$ac_mode in
24350    "default":C)
24351
24352### Make the necessary directories, if they don't exist.
24353for dir in etc lisp ; do
24354  test -d ${dir} || mkdir ${dir}
24355done
24356
24357# Build src/Makefile from ${srcdir}/src/Makefile.c
24358# and lib-src/Makefile from ${srcdir}/lib-src/Makefile.c
24359# This must be done after src/config.h is built, since we rely on that file.
24360
24361# Now get this: Some word that is part of the ${srcdir} directory name
24362# or the ${configuration} value might, just might, happen to be an
24363# identifier like `sun4' or `i386' or something, and be predefined by
24364# the C preprocessor to some helpful value like 1, or maybe the empty
24365# string.  Needless to say consequent macro substitutions are less
24366# than conducive to the makefile finding the correct directory.
24367undefs="`echo $top_srcdir $configuration $canonical |
24368sed -e 's/[^a-zA-Z0-9_]/ /g' -e 's/^/ /' -e 's/  *$//' \
24369    -e 's/  */ -U/g' -e 's/-U[0-9][^ ]*//g' \
24370`"
24371
24372echo creating src/epaths.h
24373${MAKE-make} epaths-force
24374
24375# As of 2000-11-19, newest development versions of GNU cpp preprocess
24376# `..' to `. .'  unless invoked with -traditional
24377
24378if test "x$GCC" = xyes && test "x$CPP_NEED_TRADITIONAL" = xyes; then
24379  CPPFLAGS="$CPPFLAGS -traditional"
24380fi
24381
24382echo creating lib-src/Makefile
24383( cd lib-src
24384  rm -f junk.c junk1.c junk2.c
24385  sed -e '/start of cpp stuff/q' \
24386      < Makefile.c > junk1.c
24387  sed -e '1,/start of cpp stuff/d'\
24388      -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
24389      < Makefile.c > junk.c
24390  $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
24391      sed -e 's/^ /	/' -e '/^#/d' -e '/^[ 	]*$/d' > junk2.c
24392  cat junk1.c junk2.c > Makefile.new
24393  rm -f junk.c junk1.c junk2.c
24394  chmod 444 Makefile.new
24395  mv -f Makefile.new Makefile
24396)
24397
24398echo creating src/Makefile
24399( cd src
24400  rm -f junk.c junk1.c junk2.c
24401  sed -e '/start of cpp stuff/q' \
24402      < Makefile.c > junk1.c
24403  sed -e '1,/start of cpp stuff/d'\
24404      -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
24405      < Makefile.c > junk.c
24406  $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
24407      sed -e 's/^ /	/' -e '/^#/d' -e '/^[ 	]*$/d' > junk2.c
24408  cat junk1.c junk2.c > Makefile.new
24409  rm -f junk.c junk1.c junk2.c
24410  chmod 444 Makefile.new
24411  mv -f Makefile.new Makefile
24412)
24413
24414if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
24415  echo creating src/.gdbinit
24416  echo source $srcdir/src/.gdbinit > src/.gdbinit
24417fi
24418
24419# This is how we know whether to re-run configure in certain cases.
24420touch src/config.stamp
24421
24422 ;;
24423
24424  esac
24425done # for ac_tag
24426
24427
24428{ (exit 0); exit 0; }
24429_ACEOF
24430chmod +x $CONFIG_STATUS
24431ac_clean_files=$ac_clean_files_save
24432
24433
24434# configure is writing to config.log, and then calls config.status.
24435# config.status does its own redirection, appending to config.log.
24436# Unfortunately, on DOS this fails, as config.log is still kept open
24437# by configure, so config.status won't be able to write to it; its
24438# output is simply discarded.  So we exec the FD to /dev/null,
24439# effectively closing config.log, so it can be properly (re)opened and
24440# appended to by config.status.  When coming back to configure, we
24441# need to make the FD available again.
24442if test "$no_create" != yes; then
24443  ac_cs_success=:
24444  ac_config_status_args=
24445  test "$silent" = yes &&
24446    ac_config_status_args="$ac_config_status_args --quiet"
24447  exec 5>/dev/null
24448  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
24449  exec 5>>config.log
24450  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24451  # would make configure fail if this is the last instruction.
24452  $ac_cs_success || { (exit 1); exit 1; }
24453fi
24454
24455
24456