1@%:@! /bin/sh
2@%:@ Guess values for system-dependent variables and create Makefiles.
3@%:@ Generated by GNU Autoconf 2.59.
4@%:@
5@%:@ Copyright (C) 2003 Free Software Foundation, Inc.
6@%:@ This configure script is free software; the Free Software Foundation
7@%:@ gives unlimited permission to copy, distribute and modify it.
8## --------------------- ##
9## M4sh Initialization.  ##
10## --------------------- ##
11
12# Be Bourne compatible
13if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14  emulate sh
15  NULLCMD=:
16  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
17  # is contrary to our usage.  Disable this feature.
18  alias -g '${1+"$@"}'='"$@"'
19elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
20  set -o posix
21fi
22DUALCASE=1; export DUALCASE # for MKS sh
23
24# Support unset when possible.
25if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
26  as_unset=unset
27else
28  as_unset=false
29fi
30
31
32# Work around bugs in pre-3.0 UWIN ksh.
33$as_unset ENV MAIL MAILPATH
34PS1='$ '
35PS2='> '
36PS4='+ '
37
38# NLS nuisances.
39for as_var in \
40  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
41  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
42  LC_TELEPHONE LC_TIME
43do
44  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
45    eval $as_var=C; export $as_var
46  else
47    $as_unset $as_var
48  fi
49done
50
51# Required to use basename.
52if expr a : '\(a\)' >/dev/null 2>&1; then
53  as_expr=expr
54else
55  as_expr=false
56fi
57
58if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
59  as_basename=basename
60else
61  as_basename=false
62fi
63
64
65# Name of the executable.
66as_me=`$as_basename "$0" ||
67$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
68	 X"$0" : 'X\(//\)$' \| \
69	 X"$0" : 'X\(/\)$' \| \
70	 .     : '\(.\)' 2>/dev/null ||
71echo X/"$0" |
72    sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
73  	  /^X\/\(\/\/\)$/{ s//\1/; q; }
74  	  /^X\/\(\/\).*/{ s//\1/; q; }
75  	  s/.*/./; q'`
76
77
78# PATH needs CR, and LINENO needs CR and PATH.
79# Avoid depending upon Character Ranges.
80as_cr_letters='abcdefghijklmnopqrstuvwxyz'
81as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
82as_cr_Letters=$as_cr_letters$as_cr_LETTERS
83as_cr_digits='0123456789'
84as_cr_alnum=$as_cr_Letters$as_cr_digits
85
86# The user is always right.
87if test "${PATH_SEPARATOR+set}" != set; then
88  echo "#! /bin/sh" >conf$$.sh
89  echo  "exit 0"   >>conf$$.sh
90  chmod +x conf$$.sh
91  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
92    PATH_SEPARATOR=';'
93  else
94    PATH_SEPARATOR=:
95  fi
96  rm -f conf$$.sh
97fi
98
99
100  as_lineno_1=$LINENO
101  as_lineno_2=$LINENO
102  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
103  test "x$as_lineno_1" != "x$as_lineno_2" &&
104  test "x$as_lineno_3"  = "x$as_lineno_2"  || {
105  # Find who we are.  Look in the path if we contain no path at all
106  # relative or not.
107  case $0 in
108    *[\\/]* ) as_myself=$0 ;;
109    *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
110for as_dir in $PATH
111do
112  IFS=$as_save_IFS
113  test -z "$as_dir" && as_dir=.
114  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
115done
116
117       ;;
118  esac
119  # We did not find ourselves, most probably we were run as `sh COMMAND'
120  # in which case we are not to be found in the path.
121  if test "x$as_myself" = x; then
122    as_myself=$0
123  fi
124  if test ! -f "$as_myself"; then
125    { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
126   { (exit 1); exit 1; }; }
127  fi
128  case $CONFIG_SHELL in
129  '')
130    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
131for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
132do
133  IFS=$as_save_IFS
134  test -z "$as_dir" && as_dir=.
135  for as_base in sh bash ksh sh5; do
136	 case $as_dir in
137	 /*)
138	   if ("$as_dir/$as_base" -c '
139  as_lineno_1=$LINENO
140  as_lineno_2=$LINENO
141  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
142  test "x$as_lineno_1" != "x$as_lineno_2" &&
143  test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
144	     $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
145	     $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
146	     CONFIG_SHELL=$as_dir/$as_base
147	     export CONFIG_SHELL
148	     exec "$CONFIG_SHELL" "$0" ${1+"$@"}
149	   fi;;
150	 esac
151       done
152done
153;;
154  esac
155
156  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
157  # uniformly replaced by the line number.  The first 'sed' inserts a
158  # line-number line before each line; the second 'sed' does the real
159  # work.  The second script uses 'N' to pair each line-number line
160  # with the numbered line, and appends trailing '-' during
161  # substitution so that $LINENO is not a special case at line end.
162  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
163  # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
164  sed '=' <$as_myself |
165    sed '
166      N
167      s,$,-,
168      : loop
169      s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
170      t loop
171      s,-$,,
172      s,^['$as_cr_digits']*\n,,
173    ' >$as_me.lineno &&
174  chmod +x $as_me.lineno ||
175    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
176   { (exit 1); exit 1; }; }
177
178  # Don't try to exec as it changes $[0], causing all sort of problems
179  # (the dirname of $[0] is not the place where we might find the
180  # original and so on.  Autoconf is especially sensible to this).
181  . ./$as_me.lineno
182  # Exit status is that of the last command.
183  exit
184}
185
186
187case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
188  *c*,-n*) ECHO_N= ECHO_C='
189' ECHO_T='	' ;;
190  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
191  *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
192esac
193
194if expr a : '\(a\)' >/dev/null 2>&1; then
195  as_expr=expr
196else
197  as_expr=false
198fi
199
200rm -f conf$$ conf$$.exe conf$$.file
201echo >conf$$.file
202if ln -s conf$$.file conf$$ 2>/dev/null; then
203  # We could just check for DJGPP; but this test a) works b) is more generic
204  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
205  if test -f conf$$.exe; then
206    # Don't use ln at all; we don't have any links
207    as_ln_s='cp -p'
208  else
209    as_ln_s='ln -s'
210  fi
211elif ln conf$$.file conf$$ 2>/dev/null; then
212  as_ln_s=ln
213else
214  as_ln_s='cp -p'
215fi
216rm -f conf$$ conf$$.exe conf$$.file
217
218if mkdir -p . 2>/dev/null; then
219  as_mkdir_p=:
220else
221  test -d ./-p && rmdir ./-p
222  as_mkdir_p=false
223fi
224
225as_executable_p="test -f"
226
227# Sed expression to map a string onto a valid CPP name.
228as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
229
230# Sed expression to map a string onto a valid variable name.
231as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
232
233
234# IFS
235# We need space, tab and new line, in precisely that order.
236as_nl='
237'
238IFS=" 	$as_nl"
239
240# CDPATH.
241$as_unset CDPATH
242
243
244# Name of the host.
245# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
246# so uname gets run too.
247ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
248
249exec 6>&1
250
251#
252# Initializations.
253#
254ac_default_prefix=/usr/local
255ac_config_libobj_dir=.
256cross_compiling=no
257subdirs=
258MFLAGS=
259MAKEFLAGS=
260SHELL=${CONFIG_SHELL-/bin/sh}
261
262# Maximum number of lines to put in a shell here document.
263# This variable seems obsolete.  It should probably be removed, and
264# only ac_max_sed_lines should be used.
265: ${ac_max_here_lines=38}
266
267# Identity of this package.
268PACKAGE_NAME=
269PACKAGE_TARNAME=
270PACKAGE_VERSION=
271PACKAGE_STRING=
272PACKAGE_BUGREPORT=
273
274ac_unique_file="main.cc"
275ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO SET_MAKE CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CXX CXXFLAGS ac_ct_CXX CPP X_CFLAGS X_PRE_LIBS X_LIBS X_EXTRA_LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os SDL_CONFIG SDL_CFLAGS SDL_LIBS LIB@&t@OBJS LTLIBOBJS'
276ac_subst_files=''
277
278# Initialize some variables set by options.
279ac_init_help=
280ac_init_version=false
281# The variables have the same names as the options, with
282# dashes changed to underlines.
283cache_file=/dev/null
284exec_prefix=NONE
285no_create=
286no_recursion=
287prefix=NONE
288program_prefix=NONE
289program_suffix=NONE
290program_transform_name=s,x,x,
291silent=
292site=
293srcdir=
294verbose=
295x_includes=NONE
296x_libraries=NONE
297
298# Installation directory options.
299# These are left unexpanded so users can "make install exec_prefix=/foo"
300# and all the variables that are supposed to be based on exec_prefix
301# by default will actually change.
302# Use braces instead of parens because sh, perl, etc. also accept them.
303bindir='${exec_prefix}/bin'
304sbindir='${exec_prefix}/sbin'
305libexecdir='${exec_prefix}/libexec'
306datadir='${prefix}/share'
307sysconfdir='${prefix}/etc'
308sharedstatedir='${prefix}/com'
309localstatedir='${prefix}/var'
310libdir='${exec_prefix}/lib'
311includedir='${prefix}/include'
312oldincludedir='/usr/include'
313infodir='${prefix}/info'
314mandir='${prefix}/man'
315
316ac_prev=
317for ac_option
318do
319  # If the previous option needs an argument, assign it.
320  if test -n "$ac_prev"; then
321    eval "$ac_prev=\$ac_option"
322    ac_prev=
323    continue
324  fi
325
326  ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
327
328  # Accept the important Cygnus configure options, so we can diagnose typos.
329
330  case $ac_option in
331
332  -bindir | --bindir | --bindi | --bind | --bin | --bi)
333    ac_prev=bindir ;;
334  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
335    bindir=$ac_optarg ;;
336
337  -build | --build | --buil | --bui | --bu)
338    ac_prev=build_alias ;;
339  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
340    build_alias=$ac_optarg ;;
341
342  -cache-file | --cache-file | --cache-fil | --cache-fi \
343  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
344    ac_prev=cache_file ;;
345  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
346  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
347    cache_file=$ac_optarg ;;
348
349  --config-cache | -C)
350    cache_file=config.cache ;;
351
352  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
353    ac_prev=datadir ;;
354  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
355  | --da=*)
356    datadir=$ac_optarg ;;
357
358  -disable-* | --disable-*)
359    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
360    # Reject names that are not valid shell variable names.
361    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
362      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
363   { (exit 1); exit 1; }; }
364    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
365    eval "enable_$ac_feature=no" ;;
366
367  -enable-* | --enable-*)
368    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
369    # Reject names that are not valid shell variable names.
370    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
371      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
372   { (exit 1); exit 1; }; }
373    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
374    case $ac_option in
375      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
376      *) ac_optarg=yes ;;
377    esac
378    eval "enable_$ac_feature='$ac_optarg'" ;;
379
380  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
381  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
382  | --exec | --exe | --ex)
383    ac_prev=exec_prefix ;;
384  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
385  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
386  | --exec=* | --exe=* | --ex=*)
387    exec_prefix=$ac_optarg ;;
388
389  -gas | --gas | --ga | --g)
390    # Obsolete; use --with-gas.
391    with_gas=yes ;;
392
393  -help | --help | --hel | --he | -h)
394    ac_init_help=long ;;
395  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
396    ac_init_help=recursive ;;
397  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
398    ac_init_help=short ;;
399
400  -host | --host | --hos | --ho)
401    ac_prev=host_alias ;;
402  -host=* | --host=* | --hos=* | --ho=*)
403    host_alias=$ac_optarg ;;
404
405  -includedir | --includedir | --includedi | --included | --include \
406  | --includ | --inclu | --incl | --inc)
407    ac_prev=includedir ;;
408  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
409  | --includ=* | --inclu=* | --incl=* | --inc=*)
410    includedir=$ac_optarg ;;
411
412  -infodir | --infodir | --infodi | --infod | --info | --inf)
413    ac_prev=infodir ;;
414  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
415    infodir=$ac_optarg ;;
416
417  -libdir | --libdir | --libdi | --libd)
418    ac_prev=libdir ;;
419  -libdir=* | --libdir=* | --libdi=* | --libd=*)
420    libdir=$ac_optarg ;;
421
422  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
423  | --libexe | --libex | --libe)
424    ac_prev=libexecdir ;;
425  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
426  | --libexe=* | --libex=* | --libe=*)
427    libexecdir=$ac_optarg ;;
428
429  -localstatedir | --localstatedir | --localstatedi | --localstated \
430  | --localstate | --localstat | --localsta | --localst \
431  | --locals | --local | --loca | --loc | --lo)
432    ac_prev=localstatedir ;;
433  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
434  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
435  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
436    localstatedir=$ac_optarg ;;
437
438  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
439    ac_prev=mandir ;;
440  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
441    mandir=$ac_optarg ;;
442
443  -nfp | --nfp | --nf)
444    # Obsolete; use --without-fp.
445    with_fp=no ;;
446
447  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
448  | --no-cr | --no-c | -n)
449    no_create=yes ;;
450
451  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
452  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
453    no_recursion=yes ;;
454
455  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
456  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
457  | --oldin | --oldi | --old | --ol | --o)
458    ac_prev=oldincludedir ;;
459  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
460  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
461  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
462    oldincludedir=$ac_optarg ;;
463
464  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
465    ac_prev=prefix ;;
466  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
467    prefix=$ac_optarg ;;
468
469  -program-prefix | --program-prefix | --program-prefi | --program-pref \
470  | --program-pre | --program-pr | --program-p)
471    ac_prev=program_prefix ;;
472  -program-prefix=* | --program-prefix=* | --program-prefi=* \
473  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
474    program_prefix=$ac_optarg ;;
475
476  -program-suffix | --program-suffix | --program-suffi | --program-suff \
477  | --program-suf | --program-su | --program-s)
478    ac_prev=program_suffix ;;
479  -program-suffix=* | --program-suffix=* | --program-suffi=* \
480  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
481    program_suffix=$ac_optarg ;;
482
483  -program-transform-name | --program-transform-name \
484  | --program-transform-nam | --program-transform-na \
485  | --program-transform-n | --program-transform- \
486  | --program-transform | --program-transfor \
487  | --program-transfo | --program-transf \
488  | --program-trans | --program-tran \
489  | --progr-tra | --program-tr | --program-t)
490    ac_prev=program_transform_name ;;
491  -program-transform-name=* | --program-transform-name=* \
492  | --program-transform-nam=* | --program-transform-na=* \
493  | --program-transform-n=* | --program-transform-=* \
494  | --program-transform=* | --program-transfor=* \
495  | --program-transfo=* | --program-transf=* \
496  | --program-trans=* | --program-tran=* \
497  | --progr-tra=* | --program-tr=* | --program-t=*)
498    program_transform_name=$ac_optarg ;;
499
500  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
501  | -silent | --silent | --silen | --sile | --sil)
502    silent=yes ;;
503
504  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
505    ac_prev=sbindir ;;
506  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
507  | --sbi=* | --sb=*)
508    sbindir=$ac_optarg ;;
509
510  -sharedstatedir | --sharedstatedir | --sharedstatedi \
511  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
512  | --sharedst | --shareds | --shared | --share | --shar \
513  | --sha | --sh)
514    ac_prev=sharedstatedir ;;
515  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
516  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
517  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
518  | --sha=* | --sh=*)
519    sharedstatedir=$ac_optarg ;;
520
521  -site | --site | --sit)
522    ac_prev=site ;;
523  -site=* | --site=* | --sit=*)
524    site=$ac_optarg ;;
525
526  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
527    ac_prev=srcdir ;;
528  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
529    srcdir=$ac_optarg ;;
530
531  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
532  | --syscon | --sysco | --sysc | --sys | --sy)
533    ac_prev=sysconfdir ;;
534  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
535  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
536    sysconfdir=$ac_optarg ;;
537
538  -target | --target | --targe | --targ | --tar | --ta | --t)
539    ac_prev=target_alias ;;
540  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
541    target_alias=$ac_optarg ;;
542
543  -v | -verbose | --verbose | --verbos | --verbo | --verb)
544    verbose=yes ;;
545
546  -version | --version | --versio | --versi | --vers | -V)
547    ac_init_version=: ;;
548
549  -with-* | --with-*)
550    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
551    # Reject names that are not valid shell variable names.
552    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
553      { echo "$as_me: error: invalid package name: $ac_package" >&2
554   { (exit 1); exit 1; }; }
555    ac_package=`echo $ac_package| sed 's/-/_/g'`
556    case $ac_option in
557      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
558      *) ac_optarg=yes ;;
559    esac
560    eval "with_$ac_package='$ac_optarg'" ;;
561
562  -without-* | --without-*)
563    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
564    # Reject names that are not valid shell variable names.
565    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
566      { echo "$as_me: error: invalid package name: $ac_package" >&2
567   { (exit 1); exit 1; }; }
568    ac_package=`echo $ac_package | sed 's/-/_/g'`
569    eval "with_$ac_package=no" ;;
570
571  --x)
572    # Obsolete; use --with-x.
573    with_x=yes ;;
574
575  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
576  | --x-incl | --x-inc | --x-in | --x-i)
577    ac_prev=x_includes ;;
578  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
579  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
580    x_includes=$ac_optarg ;;
581
582  -x-libraries | --x-libraries | --x-librarie | --x-librari \
583  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
584    ac_prev=x_libraries ;;
585  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
586  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
587    x_libraries=$ac_optarg ;;
588
589  -*) { echo "$as_me: error: unrecognized option: $ac_option
590Try \`$0 --help' for more information." >&2
591   { (exit 1); exit 1; }; }
592    ;;
593
594  *=*)
595    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
596    # Reject names that are not valid shell variable names.
597    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
598      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
599   { (exit 1); exit 1; }; }
600    ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
601    eval "$ac_envvar='$ac_optarg'"
602    export $ac_envvar ;;
603
604  *)
605    # FIXME: should be removed in autoconf 3.0.
606    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
607    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
608      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
609    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
610    ;;
611
612  esac
613done
614
615if test -n "$ac_prev"; then
616  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
617  { echo "$as_me: error: missing argument to $ac_option" >&2
618   { (exit 1); exit 1; }; }
619fi
620
621# Be sure to have absolute paths.
622for ac_var in exec_prefix prefix
623do
624  eval ac_val=$`echo $ac_var`
625  case $ac_val in
626    [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
627    *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
628   { (exit 1); exit 1; }; };;
629  esac
630done
631
632# Be sure to have absolute paths.
633for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
634	      localstatedir libdir includedir oldincludedir infodir mandir
635do
636  eval ac_val=$`echo $ac_var`
637  case $ac_val in
638    [\\/$]* | ?:[\\/]* ) ;;
639    *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
640   { (exit 1); exit 1; }; };;
641  esac
642done
643
644# There might be people who depend on the old broken behavior: `$host'
645# used to hold the argument of --host etc.
646# FIXME: To remove some day.
647build=$build_alias
648host=$host_alias
649target=$target_alias
650
651# FIXME: To remove some day.
652if test "x$host_alias" != x; then
653  if test "x$build_alias" = x; then
654    cross_compiling=maybe
655    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
656    If a cross compiler is detected then cross compile mode will be used." >&2
657  elif test "x$build_alias" != "x$host_alias"; then
658    cross_compiling=yes
659  fi
660fi
661
662ac_tool_prefix=
663test -n "$host_alias" && ac_tool_prefix=$host_alias-
664
665test "$silent" = yes && exec 6>/dev/null
666
667
668# Find the source files, if location was not specified.
669if test -z "$srcdir"; then
670  ac_srcdir_defaulted=yes
671  # Try the directory containing this script, then its parent.
672  ac_confdir=`(dirname "$0") 2>/dev/null ||
673$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
674	 X"$0" : 'X\(//\)[^/]' \| \
675	 X"$0" : 'X\(//\)$' \| \
676	 X"$0" : 'X\(/\)' \| \
677	 .     : '\(.\)' 2>/dev/null ||
678echo X"$0" |
679    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
680  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
681  	  /^X\(\/\/\)$/{ s//\1/; q; }
682  	  /^X\(\/\).*/{ s//\1/; q; }
683  	  s/.*/./; q'`
684  srcdir=$ac_confdir
685  if test ! -r $srcdir/$ac_unique_file; then
686    srcdir=..
687  fi
688else
689  ac_srcdir_defaulted=no
690fi
691if test ! -r $srcdir/$ac_unique_file; then
692  if test "$ac_srcdir_defaulted" = yes; then
693    { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
694   { (exit 1); exit 1; }; }
695  else
696    { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
697   { (exit 1); exit 1; }; }
698  fi
699fi
700(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
701  { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
702   { (exit 1); exit 1; }; }
703srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
704ac_env_build_alias_set=${build_alias+set}
705ac_env_build_alias_value=$build_alias
706ac_cv_env_build_alias_set=${build_alias+set}
707ac_cv_env_build_alias_value=$build_alias
708ac_env_host_alias_set=${host_alias+set}
709ac_env_host_alias_value=$host_alias
710ac_cv_env_host_alias_set=${host_alias+set}
711ac_cv_env_host_alias_value=$host_alias
712ac_env_target_alias_set=${target_alias+set}
713ac_env_target_alias_value=$target_alias
714ac_cv_env_target_alias_set=${target_alias+set}
715ac_cv_env_target_alias_value=$target_alias
716ac_env_CC_set=${CC+set}
717ac_env_CC_value=$CC
718ac_cv_env_CC_set=${CC+set}
719ac_cv_env_CC_value=$CC
720ac_env_CFLAGS_set=${CFLAGS+set}
721ac_env_CFLAGS_value=$CFLAGS
722ac_cv_env_CFLAGS_set=${CFLAGS+set}
723ac_cv_env_CFLAGS_value=$CFLAGS
724ac_env_LDFLAGS_set=${LDFLAGS+set}
725ac_env_LDFLAGS_value=$LDFLAGS
726ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
727ac_cv_env_LDFLAGS_value=$LDFLAGS
728ac_env_CPPFLAGS_set=${CPPFLAGS+set}
729ac_env_CPPFLAGS_value=$CPPFLAGS
730ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
731ac_cv_env_CPPFLAGS_value=$CPPFLAGS
732ac_env_CXX_set=${CXX+set}
733ac_env_CXX_value=$CXX
734ac_cv_env_CXX_set=${CXX+set}
735ac_cv_env_CXX_value=$CXX
736ac_env_CXXFLAGS_set=${CXXFLAGS+set}
737ac_env_CXXFLAGS_value=$CXXFLAGS
738ac_cv_env_CXXFLAGS_set=${CXXFLAGS+set}
739ac_cv_env_CXXFLAGS_value=$CXXFLAGS
740ac_env_CPP_set=${CPP+set}
741ac_env_CPP_value=$CPP
742ac_cv_env_CPP_set=${CPP+set}
743ac_cv_env_CPP_value=$CPP
744
745#
746# Report the --help message.
747#
748if test "$ac_init_help" = "long"; then
749  # Omit some internal or obsolete options to make the list less imposing.
750  # This message is too long to be a string in the A/UX 3.1 sh.
751  cat <<_ACEOF
752\`configure' configures this package to adapt to many kinds of systems.
753
754Usage: $0 [OPTION]... [VAR=VALUE]...
755
756To assign environment variables (e.g., CC, CFLAGS...), specify them as
757VAR=VALUE.  See below for descriptions of some of the useful variables.
758
759Defaults for the options are specified in brackets.
760
761Configuration:
762  -h, --help              display this help and exit
763      --help=short        display options specific to this package
764      --help=recursive    display the short help of all the included packages
765  -V, --version           display version information and exit
766  -q, --quiet, --silent   do not print \`checking...' messages
767      --cache-file=FILE   cache test results in FILE [disabled]
768  -C, --config-cache      alias for \`--cache-file=config.cache'
769  -n, --no-create         do not create output files
770      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
771
772_ACEOF
773
774  cat <<_ACEOF
775Installation directories:
776  --prefix=PREFIX         install architecture-independent files in PREFIX
777			  [$ac_default_prefix]
778  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
779			  [PREFIX]
780
781By default, \`make install' will install all the files in
782\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
783an installation prefix other than \`$ac_default_prefix' using \`--prefix',
784for instance \`--prefix=\$HOME'.
785
786For better control, use the options below.
787
788Fine tuning of the installation directories:
789  --bindir=DIR           user executables [EPREFIX/bin]
790  --sbindir=DIR          system admin executables [EPREFIX/sbin]
791  --libexecdir=DIR       program executables [EPREFIX/libexec]
792  --datadir=DIR          read-only architecture-independent data [PREFIX/share]
793  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
794  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
795  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
796  --libdir=DIR           object code libraries [EPREFIX/lib]
797  --includedir=DIR       C header files [PREFIX/include]
798  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
799  --infodir=DIR          info documentation [PREFIX/info]
800  --mandir=DIR           man documentation [PREFIX/man]
801_ACEOF
802
803  cat <<\_ACEOF
804
805Program names:
806  --program-prefix=PREFIX            prepend PREFIX to installed program names
807  --program-suffix=SUFFIX            append SUFFIX to installed program names
808  --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
809
810X features:
811  --x-includes=DIR    X include files are in DIR
812  --x-libraries=DIR   X library files are in DIR
813
814System types:
815  --build=BUILD     configure for building on BUILD [guessed]
816  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
817  --target=TARGET   configure for building compilers for TARGET [HOST]
818_ACEOF
819fi
820
821if test -n "$ac_init_help"; then
822
823  cat <<\_ACEOF
824
825Optional Features:
826  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
827  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
828  --disable-sdltest       Do not try to compile and run a test SDL program
829
830Optional Packages:
831  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
832  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
833  --with-x                use the X Window System
834  --with-sdl-prefix=PFX   Prefix where SDL is installed (optional)
835  --with-sdl-exec-prefix=PFX Exec prefix where SDL is installed (optional)
836
837Some influential environment variables:
838  CC          C compiler command
839  CFLAGS      C compiler flags
840  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
841              nonstandard directory <lib dir>
842  CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
843              headers in a nonstandard directory <include dir>
844  CXX         C++ compiler command
845  CXXFLAGS    C++ compiler flags
846  CPP         C preprocessor
847
848Use these variables to override the choices made by `configure' or to help
849it to find libraries and programs with nonstandard names/locations.
850
851_ACEOF
852fi
853
854if test "$ac_init_help" = "recursive"; then
855  # If there are subdirs, report their specific --help.
856  ac_popdir=`pwd`
857  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
858    test -d $ac_dir || continue
859    ac_builddir=.
860
861if test "$ac_dir" != .; then
862  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
863  # A "../" for each directory in $ac_dir_suffix.
864  ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
865else
866  ac_dir_suffix= ac_top_builddir=
867fi
868
869case $srcdir in
870  .)  # No --srcdir option.  We are building in place.
871    ac_srcdir=.
872    if test -z "$ac_top_builddir"; then
873       ac_top_srcdir=.
874    else
875       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
876    fi ;;
877  [\\/]* | ?:[\\/]* )  # Absolute path.
878    ac_srcdir=$srcdir$ac_dir_suffix;
879    ac_top_srcdir=$srcdir ;;
880  *) # Relative path.
881    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
882    ac_top_srcdir=$ac_top_builddir$srcdir ;;
883esac
884
885# Do not use `cd foo && pwd` to compute absolute paths, because
886# the directories may not exist.
887case `pwd` in
888.) ac_abs_builddir="$ac_dir";;
889*)
890  case "$ac_dir" in
891  .) ac_abs_builddir=`pwd`;;
892  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
893  *) ac_abs_builddir=`pwd`/"$ac_dir";;
894  esac;;
895esac
896case $ac_abs_builddir in
897.) ac_abs_top_builddir=${ac_top_builddir}.;;
898*)
899  case ${ac_top_builddir}. in
900  .) ac_abs_top_builddir=$ac_abs_builddir;;
901  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
902  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
903  esac;;
904esac
905case $ac_abs_builddir in
906.) ac_abs_srcdir=$ac_srcdir;;
907*)
908  case $ac_srcdir in
909  .) ac_abs_srcdir=$ac_abs_builddir;;
910  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
911  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
912  esac;;
913esac
914case $ac_abs_builddir in
915.) ac_abs_top_srcdir=$ac_top_srcdir;;
916*)
917  case $ac_top_srcdir in
918  .) ac_abs_top_srcdir=$ac_abs_builddir;;
919  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
920  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
921  esac;;
922esac
923
924    cd $ac_dir
925    # Check for guested configure; otherwise get Cygnus style configure.
926    if test -f $ac_srcdir/configure.gnu; then
927      echo
928      $SHELL $ac_srcdir/configure.gnu  --help=recursive
929    elif test -f $ac_srcdir/configure; then
930      echo
931      $SHELL $ac_srcdir/configure  --help=recursive
932    elif test -f $ac_srcdir/configure.ac ||
933	   test -f $ac_srcdir/configure.in; then
934      echo
935      $ac_configure --help
936    else
937      echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
938    fi
939    cd "$ac_popdir"
940  done
941fi
942
943test -n "$ac_init_help" && exit 0
944if $ac_init_version; then
945  cat <<\_ACEOF
946
947Copyright (C) 2003 Free Software Foundation, Inc.
948This configure script is free software; the Free Software Foundation
949gives unlimited permission to copy, distribute and modify it.
950_ACEOF
951  exit 0
952fi
953exec 5>config.log
954cat >&5 <<_ACEOF
955This file contains any messages produced by compilers while
956running configure, to aid debugging if configure makes a mistake.
957
958It was created by $as_me, which was
959generated by GNU Autoconf 2.59.  Invocation command line was
960
961  $ $0 $@
962
963_ACEOF
964{
965cat <<_ASUNAME
966@%:@@%:@ --------- @%:@@%:@
967@%:@@%:@ Platform. @%:@@%:@
968@%:@@%:@ --------- @%:@@%:@
969
970hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
971uname -m = `(uname -m) 2>/dev/null || echo unknown`
972uname -r = `(uname -r) 2>/dev/null || echo unknown`
973uname -s = `(uname -s) 2>/dev/null || echo unknown`
974uname -v = `(uname -v) 2>/dev/null || echo unknown`
975
976/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
977/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
978
979/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
980/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
981/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
982hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
983/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
984/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
985/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
986
987_ASUNAME
988
989as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
990for as_dir in $PATH
991do
992  IFS=$as_save_IFS
993  test -z "$as_dir" && as_dir=.
994  echo "PATH: $as_dir"
995done
996
997} >&5
998
999cat >&5 <<_ACEOF
1000
1001
1002@%:@@%:@ ----------- @%:@@%:@
1003@%:@@%:@ Core tests. @%:@@%:@
1004@%:@@%:@ ----------- @%:@@%:@
1005
1006_ACEOF
1007
1008
1009# Keep a trace of the command line.
1010# Strip out --no-create and --no-recursion so they do not pile up.
1011# Strip out --silent because we don't want to record it for future runs.
1012# Also quote any args containing shell meta-characters.
1013# Make two passes to allow for proper duplicate-argument suppression.
1014ac_configure_args=
1015ac_configure_args0=
1016ac_configure_args1=
1017ac_sep=
1018ac_must_keep_next=false
1019for ac_pass in 1 2
1020do
1021  for ac_arg
1022  do
1023    case $ac_arg in
1024    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1025    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1026    | -silent | --silent | --silen | --sile | --sil)
1027      continue ;;
1028    *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1029      ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1030    esac
1031    case $ac_pass in
1032    1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1033    2)
1034      ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1035      if test $ac_must_keep_next = true; then
1036	ac_must_keep_next=false # Got value, back to normal.
1037      else
1038	case $ac_arg in
1039	  *=* | --config-cache | -C | -disable-* | --disable-* \
1040	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1041	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1042	  | -with-* | --with-* | -without-* | --without-* | --x)
1043	    case "$ac_configure_args0 " in
1044	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1045	    esac
1046	    ;;
1047	  -* ) ac_must_keep_next=true ;;
1048	esac
1049      fi
1050      ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1051      # Get rid of the leading space.
1052      ac_sep=" "
1053      ;;
1054    esac
1055  done
1056done
1057$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1058$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1059
1060# When interrupted or exit'd, cleanup temporary files, and complete
1061# config.log.  We remove comments because anyway the quotes in there
1062# would cause problems or look ugly.
1063# WARNING: Be sure not to use single quotes in there, as some shells,
1064# such as our DU 5.0 friend, will then `close' the trap.
1065trap 'exit_status=$?
1066  # Save into config.log some information that might help in debugging.
1067  {
1068    echo
1069
1070    cat <<\_ASBOX
1071@%:@@%:@ ---------------- @%:@@%:@
1072@%:@@%:@ Cache variables. @%:@@%:@
1073@%:@@%:@ ---------------- @%:@@%:@
1074_ASBOX
1075    echo
1076    # The following way of writing the cache mishandles newlines in values,
1077{
1078  (set) 2>&1 |
1079    case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1080    *ac_space=\ *)
1081      sed -n \
1082	"s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1083	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1084      ;;
1085    *)
1086      sed -n \
1087	"s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1088      ;;
1089    esac;
1090}
1091    echo
1092
1093    cat <<\_ASBOX
1094@%:@@%:@ ----------------- @%:@@%:@
1095@%:@@%:@ Output variables. @%:@@%:@
1096@%:@@%:@ ----------------- @%:@@%:@
1097_ASBOX
1098    echo
1099    for ac_var in $ac_subst_vars
1100    do
1101      eval ac_val=$`echo $ac_var`
1102      echo "$ac_var='"'"'$ac_val'"'"'"
1103    done | sort
1104    echo
1105
1106    if test -n "$ac_subst_files"; then
1107      cat <<\_ASBOX
1108@%:@@%:@ ------------- @%:@@%:@
1109@%:@@%:@ Output files. @%:@@%:@
1110@%:@@%:@ ------------- @%:@@%:@
1111_ASBOX
1112      echo
1113      for ac_var in $ac_subst_files
1114      do
1115	eval ac_val=$`echo $ac_var`
1116	echo "$ac_var='"'"'$ac_val'"'"'"
1117      done | sort
1118      echo
1119    fi
1120
1121    if test -s confdefs.h; then
1122      cat <<\_ASBOX
1123@%:@@%:@ ----------- @%:@@%:@
1124@%:@@%:@ confdefs.h. @%:@@%:@
1125@%:@@%:@ ----------- @%:@@%:@
1126_ASBOX
1127      echo
1128      sed "/^$/d" confdefs.h | sort
1129      echo
1130    fi
1131    test "$ac_signal" != 0 &&
1132      echo "$as_me: caught signal $ac_signal"
1133    echo "$as_me: exit $exit_status"
1134  } >&5
1135  rm -f core *.core &&
1136  rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1137    exit $exit_status
1138     ' 0
1139for ac_signal in 1 2 13 15; do
1140  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1141done
1142ac_signal=0
1143
1144# confdefs.h avoids OS command line length limits that DEFS can exceed.
1145rm -rf conftest* confdefs.h
1146# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1147echo >confdefs.h
1148
1149# Predefined preprocessor variables.
1150
1151cat >>confdefs.h <<_ACEOF
1152@%:@define PACKAGE_NAME "$PACKAGE_NAME"
1153_ACEOF
1154
1155
1156cat >>confdefs.h <<_ACEOF
1157@%:@define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1158_ACEOF
1159
1160
1161cat >>confdefs.h <<_ACEOF
1162@%:@define PACKAGE_VERSION "$PACKAGE_VERSION"
1163_ACEOF
1164
1165
1166cat >>confdefs.h <<_ACEOF
1167@%:@define PACKAGE_STRING "$PACKAGE_STRING"
1168_ACEOF
1169
1170
1171cat >>confdefs.h <<_ACEOF
1172@%:@define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1173_ACEOF
1174
1175
1176# Let the site file select an alternate cache file if it wants to.
1177# Prefer explicitly selected file to automatically selected ones.
1178if test -z "$CONFIG_SITE"; then
1179  if test "x$prefix" != xNONE; then
1180    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1181  else
1182    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1183  fi
1184fi
1185for ac_site_file in $CONFIG_SITE; do
1186  if test -r "$ac_site_file"; then
1187    { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1188echo "$as_me: loading site script $ac_site_file" >&6;}
1189    sed 's/^/| /' "$ac_site_file" >&5
1190    . "$ac_site_file"
1191  fi
1192done
1193
1194if test -r "$cache_file"; then
1195  # Some versions of bash will fail to source /dev/null (special
1196  # files actually), so we avoid doing that.
1197  if test -f "$cache_file"; then
1198    { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1199echo "$as_me: loading cache $cache_file" >&6;}
1200    case $cache_file in
1201      [\\/]* | ?:[\\/]* ) . $cache_file;;
1202      *)                      . ./$cache_file;;
1203    esac
1204  fi
1205else
1206  { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1207echo "$as_me: creating cache $cache_file" >&6;}
1208  >$cache_file
1209fi
1210
1211# Check that the precious variables saved in the cache have kept the same
1212# value.
1213ac_cache_corrupted=false
1214for ac_var in `(set) 2>&1 |
1215	       sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1216  eval ac_old_set=\$ac_cv_env_${ac_var}_set
1217  eval ac_new_set=\$ac_env_${ac_var}_set
1218  eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1219  eval ac_new_val="\$ac_env_${ac_var}_value"
1220  case $ac_old_set,$ac_new_set in
1221    set,)
1222      { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1223echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1224      ac_cache_corrupted=: ;;
1225    ,set)
1226      { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1227echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1228      ac_cache_corrupted=: ;;
1229    ,);;
1230    *)
1231      if test "x$ac_old_val" != "x$ac_new_val"; then
1232	{ echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1233echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1234	{ echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1235echo "$as_me:   former value:  $ac_old_val" >&2;}
1236	{ echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1237echo "$as_me:   current value: $ac_new_val" >&2;}
1238	ac_cache_corrupted=:
1239      fi;;
1240  esac
1241  # Pass precious variables to config.status.
1242  if test "$ac_new_set" = set; then
1243    case $ac_new_val in
1244    *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1245      ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1246    *) ac_arg=$ac_var=$ac_new_val ;;
1247    esac
1248    case " $ac_configure_args " in
1249      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1250      *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1251    esac
1252  fi
1253done
1254if $ac_cache_corrupted; then
1255  { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1256echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1257  { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1258echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1259   { (exit 1); exit 1; }; }
1260fi
1261
1262ac_ext=c
1263ac_cpp='$CPP $CPPFLAGS'
1264ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1265ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1266ac_compiler_gnu=$ac_cv_c_compiler_gnu
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286am__api_version="1.4"
1287ac_aux_dir=
1288for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1289  if test -f $ac_dir/install-sh; then
1290    ac_aux_dir=$ac_dir
1291    ac_install_sh="$ac_aux_dir/install-sh -c"
1292    break
1293  elif test -f $ac_dir/install.sh; then
1294    ac_aux_dir=$ac_dir
1295    ac_install_sh="$ac_aux_dir/install.sh -c"
1296    break
1297  elif test -f $ac_dir/shtool; then
1298    ac_aux_dir=$ac_dir
1299    ac_install_sh="$ac_aux_dir/shtool install -c"
1300    break
1301  fi
1302done
1303if test -z "$ac_aux_dir"; then
1304  { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1305echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1306   { (exit 1); exit 1; }; }
1307fi
1308ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1309ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1310ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1311
1312# Find a good install program.  We prefer a C program (faster),
1313# so one script is as good as another.  But avoid the broken or
1314# incompatible versions:
1315# SysV /etc/install, /usr/sbin/install
1316# SunOS /usr/etc/install
1317# IRIX /sbin/install
1318# AIX /bin/install
1319# AmigaOS /C/install, which installs bootblocks on floppy discs
1320# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1321# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1322# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1323# OS/2's system install, which has a completely different semantic
1324# ./install, which can be erroneously created by make from ./install.sh.
1325echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
1326echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
1327if test -z "$INSTALL"; then
1328if test "${ac_cv_path_install+set}" = set; then
1329  echo $ECHO_N "(cached) $ECHO_C" >&6
1330else
1331  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1332for as_dir in $PATH
1333do
1334  IFS=$as_save_IFS
1335  test -z "$as_dir" && as_dir=.
1336  # Account for people who put trailing slashes in PATH elements.
1337case $as_dir/ in
1338  ./ | .// | /cC/* | \
1339  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
1340  ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
1341  /usr/ucb/* ) ;;
1342  *)
1343    # OSF1 and SCO ODT 3.0 have their own names for install.
1344    # Don't use installbsd from OSF since it installs stuff as root
1345    # by default.
1346    for ac_prog in ginstall scoinst install; do
1347      for ac_exec_ext in '' $ac_executable_extensions; do
1348	if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
1349	  if test $ac_prog = install &&
1350	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1351	    # AIX install.  It has an incompatible calling convention.
1352	    :
1353	  elif test $ac_prog = install &&
1354	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1355	    # program-specific install script used by HP pwplus--don't use.
1356	    :
1357	  else
1358	    ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
1359	    break 3
1360	  fi
1361	fi
1362      done
1363    done
1364    ;;
1365esac
1366done
1367
1368
1369fi
1370  if test "${ac_cv_path_install+set}" = set; then
1371    INSTALL=$ac_cv_path_install
1372  else
1373    # As a last resort, use the slow shell script.  We don't cache a
1374    # path for INSTALL within a source directory, because that will
1375    # break other packages using the cache if that directory is
1376    # removed, or if the path is relative.
1377    INSTALL=$ac_install_sh
1378  fi
1379fi
1380echo "$as_me:$LINENO: result: $INSTALL" >&5
1381echo "${ECHO_T}$INSTALL" >&6
1382
1383# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1384# It thinks the first close brace ends the variable substitution.
1385test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1386
1387test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
1388
1389test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1390
1391echo "$as_me:$LINENO: checking whether build environment is sane" >&5
1392echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6
1393# Just in case
1394sleep 1
1395echo timestamp > conftestfile
1396# Do `set' in a subshell so we don't clobber the current shell's
1397# arguments.  Must try -L first in case configure is actually a
1398# symlink; some systems play weird games with the mod time of symlinks
1399# (eg FreeBSD returns the mod time of the symlink's containing
1400# directory).
1401if (
1402   set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
1403   if test "$*" = "X"; then
1404      # -L didn't work.
1405      set X `ls -t $srcdir/configure conftestfile`
1406   fi
1407   if test "$*" != "X $srcdir/configure conftestfile" \
1408      && test "$*" != "X conftestfile $srcdir/configure"; then
1409
1410      # If neither matched, then we have a broken ls.  This can happen
1411      # if, for instance, CONFIG_SHELL is bash and it inherits a
1412      # broken ls alias from the environment.  This has actually
1413      # happened.  Such a system could not be considered "sane".
1414      { { echo "$as_me:$LINENO: error: ls -t appears to fail.  Make sure there is not a broken
1415alias in your environment" >&5
1416echo "$as_me: error: ls -t appears to fail.  Make sure there is not a broken
1417alias in your environment" >&2;}
1418   { (exit 1); exit 1; }; }
1419   fi
1420
1421   test "$2" = conftestfile
1422   )
1423then
1424   # Ok.
1425   :
1426else
1427   { { echo "$as_me:$LINENO: error: newly created file is older than distributed files!
1428Check your system clock" >&5
1429echo "$as_me: error: newly created file is older than distributed files!
1430Check your system clock" >&2;}
1431   { (exit 1); exit 1; }; }
1432fi
1433rm -f conftest*
1434echo "$as_me:$LINENO: result: yes" >&5
1435echo "${ECHO_T}yes" >&6
1436test "$program_prefix" != NONE &&
1437  program_transform_name="s,^,$program_prefix,;$program_transform_name"
1438# Use a double $ so make ignores it.
1439test "$program_suffix" != NONE &&
1440  program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1441# Double any \ or $.  echo might interpret backslashes.
1442# By default was `s,x,x', remove it if useless.
1443cat <<\_ACEOF >conftest.sed
1444s/[\\$]/&&/g;s/;s,x,x,$//
1445_ACEOF
1446program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1447rm conftest.sed
1448
1449echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
1450echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
1451set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
1452if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1453  echo $ECHO_N "(cached) $ECHO_C" >&6
1454else
1455  cat >conftest.make <<\_ACEOF
1456all:
1457	@echo 'ac_maketemp="$(MAKE)"'
1458_ACEOF
1459# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1460eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1461if test -n "$ac_maketemp"; then
1462  eval ac_cv_prog_make_${ac_make}_set=yes
1463else
1464  eval ac_cv_prog_make_${ac_make}_set=no
1465fi
1466rm -f conftest.make
1467fi
1468if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1469  echo "$as_me:$LINENO: result: yes" >&5
1470echo "${ECHO_T}yes" >&6
1471  SET_MAKE=
1472else
1473  echo "$as_me:$LINENO: result: no" >&5
1474echo "${ECHO_T}no" >&6
1475  SET_MAKE="MAKE=${MAKE-make}"
1476fi
1477
1478
1479PACKAGE=synaesthesia
1480
1481VERSION=2.4
1482
1483if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
1484  { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
1485echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
1486   { (exit 1); exit 1; }; }
1487fi
1488
1489cat >>confdefs.h <<_ACEOF
1490@%:@define PACKAGE "$PACKAGE"
1491_ACEOF
1492
1493
1494cat >>confdefs.h <<_ACEOF
1495@%:@define VERSION "$VERSION"
1496_ACEOF
1497
1498
1499
1500missing_dir=`cd $ac_aux_dir && pwd`
1501echo "$as_me:$LINENO: checking for working aclocal-${am__api_version}" >&5
1502echo $ECHO_N "checking for working aclocal-${am__api_version}... $ECHO_C" >&6
1503# Run test in a subshell; some versions of sh will print an error if
1504# an executable is not found, even if stderr is redirected.
1505# Redirect stdin to placate older versions of autoconf.  Sigh.
1506if (aclocal-${am__api_version} --version) < /dev/null > /dev/null 2>&1; then
1507   ACLOCAL=aclocal-${am__api_version}
1508   echo "$as_me:$LINENO: result: found" >&5
1509echo "${ECHO_T}found" >&6
1510else
1511   ACLOCAL="$missing_dir/missing aclocal-${am__api_version}"
1512   echo "$as_me:$LINENO: result: missing" >&5
1513echo "${ECHO_T}missing" >&6
1514fi
1515
1516echo "$as_me:$LINENO: checking for working autoconf" >&5
1517echo $ECHO_N "checking for working autoconf... $ECHO_C" >&6
1518# Run test in a subshell; some versions of sh will print an error if
1519# an executable is not found, even if stderr is redirected.
1520# Redirect stdin to placate older versions of autoconf.  Sigh.
1521if (autoconf --version) < /dev/null > /dev/null 2>&1; then
1522   AUTOCONF=autoconf
1523   echo "$as_me:$LINENO: result: found" >&5
1524echo "${ECHO_T}found" >&6
1525else
1526   AUTOCONF="$missing_dir/missing autoconf"
1527   echo "$as_me:$LINENO: result: missing" >&5
1528echo "${ECHO_T}missing" >&6
1529fi
1530
1531echo "$as_me:$LINENO: checking for working automake-${am__api_version}" >&5
1532echo $ECHO_N "checking for working automake-${am__api_version}... $ECHO_C" >&6
1533# Run test in a subshell; some versions of sh will print an error if
1534# an executable is not found, even if stderr is redirected.
1535# Redirect stdin to placate older versions of autoconf.  Sigh.
1536if (automake-${am__api_version} --version) < /dev/null > /dev/null 2>&1; then
1537   AUTOMAKE=automake-${am__api_version}
1538   echo "$as_me:$LINENO: result: found" >&5
1539echo "${ECHO_T}found" >&6
1540else
1541   AUTOMAKE="$missing_dir/missing automake-${am__api_version}"
1542   echo "$as_me:$LINENO: result: missing" >&5
1543echo "${ECHO_T}missing" >&6
1544fi
1545
1546echo "$as_me:$LINENO: checking for working autoheader" >&5
1547echo $ECHO_N "checking for working autoheader... $ECHO_C" >&6
1548# Run test in a subshell; some versions of sh will print an error if
1549# an executable is not found, even if stderr is redirected.
1550# Redirect stdin to placate older versions of autoconf.  Sigh.
1551if (autoheader --version) < /dev/null > /dev/null 2>&1; then
1552   AUTOHEADER=autoheader
1553   echo "$as_me:$LINENO: result: found" >&5
1554echo "${ECHO_T}found" >&6
1555else
1556   AUTOHEADER="$missing_dir/missing autoheader"
1557   echo "$as_me:$LINENO: result: missing" >&5
1558echo "${ECHO_T}missing" >&6
1559fi
1560
1561echo "$as_me:$LINENO: checking for working makeinfo" >&5
1562echo $ECHO_N "checking for working makeinfo... $ECHO_C" >&6
1563# Run test in a subshell; some versions of sh will print an error if
1564# an executable is not found, even if stderr is redirected.
1565# Redirect stdin to placate older versions of autoconf.  Sigh.
1566if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
1567   MAKEINFO=makeinfo
1568   echo "$as_me:$LINENO: result: found" >&5
1569echo "${ECHO_T}found" >&6
1570else
1571   MAKEINFO="$missing_dir/missing makeinfo"
1572   echo "$as_me:$LINENO: result: missing" >&5
1573echo "${ECHO_T}missing" >&6
1574fi
1575
1576
1577
1578          ac_config_headers="$ac_config_headers config.h"
1579
1580          ac_config_commands="$ac_config_commands default-1"
1581
1582
1583CXXFLAGS="-O4"
1584CFLAGS="-O4"
1585
1586ac_ext=c
1587ac_cpp='$CPP $CPPFLAGS'
1588ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1589ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1590ac_compiler_gnu=$ac_cv_c_compiler_gnu
1591if test -n "$ac_tool_prefix"; then
1592  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1593set dummy ${ac_tool_prefix}gcc; ac_word=$2
1594echo "$as_me:$LINENO: checking for $ac_word" >&5
1595echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1596if test "${ac_cv_prog_CC+set}" = set; then
1597  echo $ECHO_N "(cached) $ECHO_C" >&6
1598else
1599  if test -n "$CC"; then
1600  ac_cv_prog_CC="$CC" # Let the user override the test.
1601else
1602as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1603for as_dir in $PATH
1604do
1605  IFS=$as_save_IFS
1606  test -z "$as_dir" && as_dir=.
1607  for ac_exec_ext in '' $ac_executable_extensions; do
1608  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1609    ac_cv_prog_CC="${ac_tool_prefix}gcc"
1610    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1611    break 2
1612  fi
1613done
1614done
1615
1616fi
1617fi
1618CC=$ac_cv_prog_CC
1619if test -n "$CC"; then
1620  echo "$as_me:$LINENO: result: $CC" >&5
1621echo "${ECHO_T}$CC" >&6
1622else
1623  echo "$as_me:$LINENO: result: no" >&5
1624echo "${ECHO_T}no" >&6
1625fi
1626
1627fi
1628if test -z "$ac_cv_prog_CC"; then
1629  ac_ct_CC=$CC
1630  # Extract the first word of "gcc", so it can be a program name with args.
1631set dummy gcc; ac_word=$2
1632echo "$as_me:$LINENO: checking for $ac_word" >&5
1633echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1634if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1635  echo $ECHO_N "(cached) $ECHO_C" >&6
1636else
1637  if test -n "$ac_ct_CC"; then
1638  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1639else
1640as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1641for as_dir in $PATH
1642do
1643  IFS=$as_save_IFS
1644  test -z "$as_dir" && as_dir=.
1645  for ac_exec_ext in '' $ac_executable_extensions; do
1646  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1647    ac_cv_prog_ac_ct_CC="gcc"
1648    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1649    break 2
1650  fi
1651done
1652done
1653
1654fi
1655fi
1656ac_ct_CC=$ac_cv_prog_ac_ct_CC
1657if test -n "$ac_ct_CC"; then
1658  echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1659echo "${ECHO_T}$ac_ct_CC" >&6
1660else
1661  echo "$as_me:$LINENO: result: no" >&5
1662echo "${ECHO_T}no" >&6
1663fi
1664
1665  CC=$ac_ct_CC
1666else
1667  CC="$ac_cv_prog_CC"
1668fi
1669
1670if test -z "$CC"; then
1671  if test -n "$ac_tool_prefix"; then
1672  # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1673set dummy ${ac_tool_prefix}cc; ac_word=$2
1674echo "$as_me:$LINENO: checking for $ac_word" >&5
1675echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1676if test "${ac_cv_prog_CC+set}" = set; then
1677  echo $ECHO_N "(cached) $ECHO_C" >&6
1678else
1679  if test -n "$CC"; then
1680  ac_cv_prog_CC="$CC" # Let the user override the test.
1681else
1682as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1683for as_dir in $PATH
1684do
1685  IFS=$as_save_IFS
1686  test -z "$as_dir" && as_dir=.
1687  for ac_exec_ext in '' $ac_executable_extensions; do
1688  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1689    ac_cv_prog_CC="${ac_tool_prefix}cc"
1690    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1691    break 2
1692  fi
1693done
1694done
1695
1696fi
1697fi
1698CC=$ac_cv_prog_CC
1699if test -n "$CC"; then
1700  echo "$as_me:$LINENO: result: $CC" >&5
1701echo "${ECHO_T}$CC" >&6
1702else
1703  echo "$as_me:$LINENO: result: no" >&5
1704echo "${ECHO_T}no" >&6
1705fi
1706
1707fi
1708if test -z "$ac_cv_prog_CC"; then
1709  ac_ct_CC=$CC
1710  # Extract the first word of "cc", so it can be a program name with args.
1711set dummy cc; ac_word=$2
1712echo "$as_me:$LINENO: checking for $ac_word" >&5
1713echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1714if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1715  echo $ECHO_N "(cached) $ECHO_C" >&6
1716else
1717  if test -n "$ac_ct_CC"; then
1718  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1719else
1720as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1721for as_dir in $PATH
1722do
1723  IFS=$as_save_IFS
1724  test -z "$as_dir" && as_dir=.
1725  for ac_exec_ext in '' $ac_executable_extensions; do
1726  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1727    ac_cv_prog_ac_ct_CC="cc"
1728    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1729    break 2
1730  fi
1731done
1732done
1733
1734fi
1735fi
1736ac_ct_CC=$ac_cv_prog_ac_ct_CC
1737if test -n "$ac_ct_CC"; then
1738  echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1739echo "${ECHO_T}$ac_ct_CC" >&6
1740else
1741  echo "$as_me:$LINENO: result: no" >&5
1742echo "${ECHO_T}no" >&6
1743fi
1744
1745  CC=$ac_ct_CC
1746else
1747  CC="$ac_cv_prog_CC"
1748fi
1749
1750fi
1751if test -z "$CC"; then
1752  # Extract the first word of "cc", so it can be a program name with args.
1753set dummy cc; ac_word=$2
1754echo "$as_me:$LINENO: checking for $ac_word" >&5
1755echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1756if test "${ac_cv_prog_CC+set}" = set; then
1757  echo $ECHO_N "(cached) $ECHO_C" >&6
1758else
1759  if test -n "$CC"; then
1760  ac_cv_prog_CC="$CC" # Let the user override the test.
1761else
1762  ac_prog_rejected=no
1763as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1764for as_dir in $PATH
1765do
1766  IFS=$as_save_IFS
1767  test -z "$as_dir" && as_dir=.
1768  for ac_exec_ext in '' $ac_executable_extensions; do
1769  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1770    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
1771       ac_prog_rejected=yes
1772       continue
1773     fi
1774    ac_cv_prog_CC="cc"
1775    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1776    break 2
1777  fi
1778done
1779done
1780
1781if test $ac_prog_rejected = yes; then
1782  # We found a bogon in the path, so make sure we never use it.
1783  set dummy $ac_cv_prog_CC
1784  shift
1785  if test $@%:@ != 0; then
1786    # We chose a different compiler from the bogus one.
1787    # However, it has the same basename, so the bogon will be chosen
1788    # first if we set CC to just the basename; use the full file name.
1789    shift
1790    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
1791  fi
1792fi
1793fi
1794fi
1795CC=$ac_cv_prog_CC
1796if test -n "$CC"; then
1797  echo "$as_me:$LINENO: result: $CC" >&5
1798echo "${ECHO_T}$CC" >&6
1799else
1800  echo "$as_me:$LINENO: result: no" >&5
1801echo "${ECHO_T}no" >&6
1802fi
1803
1804fi
1805if test -z "$CC"; then
1806  if test -n "$ac_tool_prefix"; then
1807  for ac_prog in cl
1808  do
1809    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1810set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1811echo "$as_me:$LINENO: checking for $ac_word" >&5
1812echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1813if test "${ac_cv_prog_CC+set}" = set; then
1814  echo $ECHO_N "(cached) $ECHO_C" >&6
1815else
1816  if test -n "$CC"; then
1817  ac_cv_prog_CC="$CC" # Let the user override the test.
1818else
1819as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1820for as_dir in $PATH
1821do
1822  IFS=$as_save_IFS
1823  test -z "$as_dir" && as_dir=.
1824  for ac_exec_ext in '' $ac_executable_extensions; do
1825  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1826    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1827    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1828    break 2
1829  fi
1830done
1831done
1832
1833fi
1834fi
1835CC=$ac_cv_prog_CC
1836if test -n "$CC"; then
1837  echo "$as_me:$LINENO: result: $CC" >&5
1838echo "${ECHO_T}$CC" >&6
1839else
1840  echo "$as_me:$LINENO: result: no" >&5
1841echo "${ECHO_T}no" >&6
1842fi
1843
1844    test -n "$CC" && break
1845  done
1846fi
1847if test -z "$CC"; then
1848  ac_ct_CC=$CC
1849  for ac_prog in cl
1850do
1851  # Extract the first word of "$ac_prog", so it can be a program name with args.
1852set dummy $ac_prog; ac_word=$2
1853echo "$as_me:$LINENO: checking for $ac_word" >&5
1854echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1855if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1856  echo $ECHO_N "(cached) $ECHO_C" >&6
1857else
1858  if test -n "$ac_ct_CC"; then
1859  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1860else
1861as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1862for as_dir in $PATH
1863do
1864  IFS=$as_save_IFS
1865  test -z "$as_dir" && as_dir=.
1866  for ac_exec_ext in '' $ac_executable_extensions; do
1867  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1868    ac_cv_prog_ac_ct_CC="$ac_prog"
1869    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1870    break 2
1871  fi
1872done
1873done
1874
1875fi
1876fi
1877ac_ct_CC=$ac_cv_prog_ac_ct_CC
1878if test -n "$ac_ct_CC"; then
1879  echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1880echo "${ECHO_T}$ac_ct_CC" >&6
1881else
1882  echo "$as_me:$LINENO: result: no" >&5
1883echo "${ECHO_T}no" >&6
1884fi
1885
1886  test -n "$ac_ct_CC" && break
1887done
1888
1889  CC=$ac_ct_CC
1890fi
1891
1892fi
1893
1894
1895test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
1896See \`config.log' for more details." >&5
1897echo "$as_me: error: no acceptable C compiler found in \$PATH
1898See \`config.log' for more details." >&2;}
1899   { (exit 1); exit 1; }; }
1900
1901# Provide some information about the compiler.
1902echo "$as_me:$LINENO:" \
1903     "checking for C compiler version" >&5
1904ac_compiler=`set X $ac_compile; echo $2`
1905{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
1906  (eval $ac_compiler --version </dev/null >&5) 2>&5
1907  ac_status=$?
1908  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1909  (exit $ac_status); }
1910{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
1911  (eval $ac_compiler -v </dev/null >&5) 2>&5
1912  ac_status=$?
1913  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1914  (exit $ac_status); }
1915{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
1916  (eval $ac_compiler -V </dev/null >&5) 2>&5
1917  ac_status=$?
1918  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1919  (exit $ac_status); }
1920
1921cat >conftest.$ac_ext <<_ACEOF
1922/* confdefs.h.  */
1923_ACEOF
1924cat confdefs.h >>conftest.$ac_ext
1925cat >>conftest.$ac_ext <<_ACEOF
1926/* end confdefs.h.  */
1927
1928int
1929main ()
1930{
1931
1932  ;
1933  return 0;
1934}
1935_ACEOF
1936ac_clean_files_save=$ac_clean_files
1937ac_clean_files="$ac_clean_files a.out a.exe b.out"
1938# Try to create an executable without -o first, disregard a.out.
1939# It will help us diagnose broken compilers, and finding out an intuition
1940# of exeext.
1941echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
1942echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
1943ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1944if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1945  (eval $ac_link_default) 2>&5
1946  ac_status=$?
1947  echo "$as_me:$LINENO: \$? = $ac_status" >&5
1948  (exit $ac_status); }; then
1949  # Find the output, starting from the most likely.  This scheme is
1950# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1951# resort.
1952
1953# Be careful to initialize this variable, since it used to be cached.
1954# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
1955ac_cv_exeext=
1956# b.out is created by i960 compilers.
1957for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
1958do
1959  test -f "$ac_file" || continue
1960  case $ac_file in
1961    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
1962	;;
1963    conftest.$ac_ext )
1964	# This is the source file.
1965	;;
1966    [ab].out )
1967	# We found the default executable, but exeext='' is most
1968	# certainly right.
1969	break;;
1970    *.* )
1971	ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1972	# FIXME: I believe we export ac_cv_exeext for Libtool,
1973	# but it would be cool to find out if it's true.  Does anybody
1974	# maintain Libtool? --akim.
1975	export ac_cv_exeext
1976	break;;
1977    * )
1978	break;;
1979  esac
1980done
1981else
1982  echo "$as_me: failed program was:" >&5
1983sed 's/^/| /' conftest.$ac_ext >&5
1984
1985{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
1986See \`config.log' for more details." >&5
1987echo "$as_me: error: C compiler cannot create executables
1988See \`config.log' for more details." >&2;}
1989   { (exit 77); exit 77; }; }
1990fi
1991
1992ac_exeext=$ac_cv_exeext
1993echo "$as_me:$LINENO: result: $ac_file" >&5
1994echo "${ECHO_T}$ac_file" >&6
1995
1996# Check the compiler produces executables we can run.  If not, either
1997# the compiler is broken, or we cross compile.
1998echo "$as_me:$LINENO: checking whether the C compiler works" >&5
1999echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2000# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2001# If not cross compiling, check that we can run a simple program.
2002if test "$cross_compiling" != yes; then
2003  if { ac_try='./$ac_file'
2004  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2005  (eval $ac_try) 2>&5
2006  ac_status=$?
2007  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2008  (exit $ac_status); }; }; then
2009    cross_compiling=no
2010  else
2011    if test "$cross_compiling" = maybe; then
2012	cross_compiling=yes
2013    else
2014	{ { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2015If you meant to cross compile, use \`--host'.
2016See \`config.log' for more details." >&5
2017echo "$as_me: error: cannot run C compiled programs.
2018If you meant to cross compile, use \`--host'.
2019See \`config.log' for more details." >&2;}
2020   { (exit 1); exit 1; }; }
2021    fi
2022  fi
2023fi
2024echo "$as_me:$LINENO: result: yes" >&5
2025echo "${ECHO_T}yes" >&6
2026
2027rm -f a.out a.exe conftest$ac_cv_exeext b.out
2028ac_clean_files=$ac_clean_files_save
2029# Check the compiler produces executables we can run.  If not, either
2030# the compiler is broken, or we cross compile.
2031echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2032echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2033echo "$as_me:$LINENO: result: $cross_compiling" >&5
2034echo "${ECHO_T}$cross_compiling" >&6
2035
2036echo "$as_me:$LINENO: checking for suffix of executables" >&5
2037echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2038if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2039  (eval $ac_link) 2>&5
2040  ac_status=$?
2041  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2042  (exit $ac_status); }; then
2043  # If both `conftest.exe' and `conftest' are `present' (well, observable)
2044# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
2045# work properly (i.e., refer to `conftest.exe'), while it won't with
2046# `rm'.
2047for ac_file in conftest.exe conftest conftest.*; do
2048  test -f "$ac_file" || continue
2049  case $ac_file in
2050    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
2051    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2052	  export ac_cv_exeext
2053	  break;;
2054    * ) break;;
2055  esac
2056done
2057else
2058  { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
2059See \`config.log' for more details." >&5
2060echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
2061See \`config.log' for more details." >&2;}
2062   { (exit 1); exit 1; }; }
2063fi
2064
2065rm -f conftest$ac_cv_exeext
2066echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2067echo "${ECHO_T}$ac_cv_exeext" >&6
2068
2069rm -f conftest.$ac_ext
2070EXEEXT=$ac_cv_exeext
2071ac_exeext=$EXEEXT
2072echo "$as_me:$LINENO: checking for suffix of object files" >&5
2073echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2074if test "${ac_cv_objext+set}" = set; then
2075  echo $ECHO_N "(cached) $ECHO_C" >&6
2076else
2077  cat >conftest.$ac_ext <<_ACEOF
2078/* confdefs.h.  */
2079_ACEOF
2080cat confdefs.h >>conftest.$ac_ext
2081cat >>conftest.$ac_ext <<_ACEOF
2082/* end confdefs.h.  */
2083
2084int
2085main ()
2086{
2087
2088  ;
2089  return 0;
2090}
2091_ACEOF
2092rm -f conftest.o conftest.obj
2093if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2094  (eval $ac_compile) 2>&5
2095  ac_status=$?
2096  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2097  (exit $ac_status); }; then
2098  for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2099  case $ac_file in
2100    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
2101    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2102       break;;
2103  esac
2104done
2105else
2106  echo "$as_me: failed program was:" >&5
2107sed 's/^/| /' conftest.$ac_ext >&5
2108
2109{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
2110See \`config.log' for more details." >&5
2111echo "$as_me: error: cannot compute suffix of object files: cannot compile
2112See \`config.log' for more details." >&2;}
2113   { (exit 1); exit 1; }; }
2114fi
2115
2116rm -f conftest.$ac_cv_objext conftest.$ac_ext
2117fi
2118echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2119echo "${ECHO_T}$ac_cv_objext" >&6
2120OBJEXT=$ac_cv_objext
2121ac_objext=$OBJEXT
2122echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2123echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2124if test "${ac_cv_c_compiler_gnu+set}" = set; then
2125  echo $ECHO_N "(cached) $ECHO_C" >&6
2126else
2127  cat >conftest.$ac_ext <<_ACEOF
2128/* confdefs.h.  */
2129_ACEOF
2130cat confdefs.h >>conftest.$ac_ext
2131cat >>conftest.$ac_ext <<_ACEOF
2132/* end confdefs.h.  */
2133
2134int
2135main ()
2136{
2137#ifndef __GNUC__
2138       choke me
2139#endif
2140
2141  ;
2142  return 0;
2143}
2144_ACEOF
2145rm -f conftest.$ac_objext
2146if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2147  (eval $ac_compile) 2>conftest.er1
2148  ac_status=$?
2149  grep -v '^ *+' conftest.er1 >conftest.err
2150  rm -f conftest.er1
2151  cat conftest.err >&5
2152  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2153  (exit $ac_status); } &&
2154	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
2155  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2156  (eval $ac_try) 2>&5
2157  ac_status=$?
2158  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2159  (exit $ac_status); }; } &&
2160	 { ac_try='test -s conftest.$ac_objext'
2161  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2162  (eval $ac_try) 2>&5
2163  ac_status=$?
2164  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2165  (exit $ac_status); }; }; then
2166  ac_compiler_gnu=yes
2167else
2168  echo "$as_me: failed program was:" >&5
2169sed 's/^/| /' conftest.$ac_ext >&5
2170
2171ac_compiler_gnu=no
2172fi
2173rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2174ac_cv_c_compiler_gnu=$ac_compiler_gnu
2175
2176fi
2177echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2178echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2179GCC=`test $ac_compiler_gnu = yes && echo yes`
2180ac_test_CFLAGS=${CFLAGS+set}
2181ac_save_CFLAGS=$CFLAGS
2182CFLAGS="-g"
2183echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2184echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2185if test "${ac_cv_prog_cc_g+set}" = set; then
2186  echo $ECHO_N "(cached) $ECHO_C" >&6
2187else
2188  cat >conftest.$ac_ext <<_ACEOF
2189/* confdefs.h.  */
2190_ACEOF
2191cat confdefs.h >>conftest.$ac_ext
2192cat >>conftest.$ac_ext <<_ACEOF
2193/* end confdefs.h.  */
2194
2195int
2196main ()
2197{
2198
2199  ;
2200  return 0;
2201}
2202_ACEOF
2203rm -f conftest.$ac_objext
2204if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2205  (eval $ac_compile) 2>conftest.er1
2206  ac_status=$?
2207  grep -v '^ *+' conftest.er1 >conftest.err
2208  rm -f conftest.er1
2209  cat conftest.err >&5
2210  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2211  (exit $ac_status); } &&
2212	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
2213  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2214  (eval $ac_try) 2>&5
2215  ac_status=$?
2216  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2217  (exit $ac_status); }; } &&
2218	 { ac_try='test -s conftest.$ac_objext'
2219  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2220  (eval $ac_try) 2>&5
2221  ac_status=$?
2222  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2223  (exit $ac_status); }; }; then
2224  ac_cv_prog_cc_g=yes
2225else
2226  echo "$as_me: failed program was:" >&5
2227sed 's/^/| /' conftest.$ac_ext >&5
2228
2229ac_cv_prog_cc_g=no
2230fi
2231rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2232fi
2233echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2234echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2235if test "$ac_test_CFLAGS" = set; then
2236  CFLAGS=$ac_save_CFLAGS
2237elif test $ac_cv_prog_cc_g = yes; then
2238  if test "$GCC" = yes; then
2239    CFLAGS="-g -O2"
2240  else
2241    CFLAGS="-g"
2242  fi
2243else
2244  if test "$GCC" = yes; then
2245    CFLAGS="-O2"
2246  else
2247    CFLAGS=
2248  fi
2249fi
2250echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
2251echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2252if test "${ac_cv_prog_cc_stdc+set}" = set; then
2253  echo $ECHO_N "(cached) $ECHO_C" >&6
2254else
2255  ac_cv_prog_cc_stdc=no
2256ac_save_CC=$CC
2257cat >conftest.$ac_ext <<_ACEOF
2258/* confdefs.h.  */
2259_ACEOF
2260cat confdefs.h >>conftest.$ac_ext
2261cat >>conftest.$ac_ext <<_ACEOF
2262/* end confdefs.h.  */
2263#include <stdarg.h>
2264#include <stdio.h>
2265#include <sys/types.h>
2266#include <sys/stat.h>
2267/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2268struct buf { int x; };
2269FILE * (*rcsopen) (struct buf *, struct stat *, int);
2270static char *e (p, i)
2271     char **p;
2272     int i;
2273{
2274  return p[i];
2275}
2276static char *f (char * (*g) (char **, int), char **p, ...)
2277{
2278  char *s;
2279  va_list v;
2280  va_start (v,p);
2281  s = g (p, va_arg (v,int));
2282  va_end (v);
2283  return s;
2284}
2285
2286/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
2287   function prototypes and stuff, but not '\xHH' hex character constants.
2288   These don't provoke an error unfortunately, instead are silently treated
2289   as 'x'.  The following induces an error, until -std1 is added to get
2290   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
2291   array size at least.  It's necessary to write '\x00'==0 to get something
2292   that's true only with -std1.  */
2293int osf4_cc_array ['\x00' == 0 ? 1 : -1];
2294
2295int test (int i, double x);
2296struct s1 {int (*f) (int a);};
2297struct s2 {int (*f) (double a);};
2298int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2299int argc;
2300char **argv;
2301int
2302main ()
2303{
2304return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2305  ;
2306  return 0;
2307}
2308_ACEOF
2309# Don't try gcc -ansi; that turns off useful extensions and
2310# breaks some systems' header files.
2311# AIX			-qlanglvl=ansi
2312# Ultrix and OSF/1	-std1
2313# HP-UX 10.20 and later	-Ae
2314# HP-UX older versions	-Aa -D_HPUX_SOURCE
2315# SVR4			-Xc -D__EXTENSIONS__
2316for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2317do
2318  CC="$ac_save_CC $ac_arg"
2319  rm -f conftest.$ac_objext
2320if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2321  (eval $ac_compile) 2>conftest.er1
2322  ac_status=$?
2323  grep -v '^ *+' conftest.er1 >conftest.err
2324  rm -f conftest.er1
2325  cat conftest.err >&5
2326  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2327  (exit $ac_status); } &&
2328	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
2329  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2330  (eval $ac_try) 2>&5
2331  ac_status=$?
2332  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2333  (exit $ac_status); }; } &&
2334	 { ac_try='test -s conftest.$ac_objext'
2335  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2336  (eval $ac_try) 2>&5
2337  ac_status=$?
2338  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2339  (exit $ac_status); }; }; then
2340  ac_cv_prog_cc_stdc=$ac_arg
2341break
2342else
2343  echo "$as_me: failed program was:" >&5
2344sed 's/^/| /' conftest.$ac_ext >&5
2345
2346fi
2347rm -f conftest.err conftest.$ac_objext
2348done
2349rm -f conftest.$ac_ext conftest.$ac_objext
2350CC=$ac_save_CC
2351
2352fi
2353
2354case "x$ac_cv_prog_cc_stdc" in
2355  x|xno)
2356    echo "$as_me:$LINENO: result: none needed" >&5
2357echo "${ECHO_T}none needed" >&6 ;;
2358  *)
2359    echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2360echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2361    CC="$CC $ac_cv_prog_cc_stdc" ;;
2362esac
2363
2364# Some people use a C++ compiler to compile C.  Since we use `exit',
2365# in C++ we need to declare it.  In case someone uses the same compiler
2366# for both compiling C and C++ we need to have the C++ compiler decide
2367# the declaration of exit, since it's the most demanding environment.
2368cat >conftest.$ac_ext <<_ACEOF
2369@%:@ifndef __cplusplus
2370  choke me
2371@%:@endif
2372_ACEOF
2373rm -f conftest.$ac_objext
2374if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2375  (eval $ac_compile) 2>conftest.er1
2376  ac_status=$?
2377  grep -v '^ *+' conftest.er1 >conftest.err
2378  rm -f conftest.er1
2379  cat conftest.err >&5
2380  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2381  (exit $ac_status); } &&
2382	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
2383  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2384  (eval $ac_try) 2>&5
2385  ac_status=$?
2386  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2387  (exit $ac_status); }; } &&
2388	 { ac_try='test -s conftest.$ac_objext'
2389  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2390  (eval $ac_try) 2>&5
2391  ac_status=$?
2392  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2393  (exit $ac_status); }; }; then
2394  for ac_declaration in \
2395   '' \
2396   'extern "C" void std::exit (int) throw (); using std::exit;' \
2397   'extern "C" void std::exit (int); using std::exit;' \
2398   'extern "C" void exit (int) throw ();' \
2399   'extern "C" void exit (int);' \
2400   'void exit (int);'
2401do
2402  cat >conftest.$ac_ext <<_ACEOF
2403/* confdefs.h.  */
2404_ACEOF
2405cat confdefs.h >>conftest.$ac_ext
2406cat >>conftest.$ac_ext <<_ACEOF
2407/* end confdefs.h.  */
2408$ac_declaration
2409@%:@include <stdlib.h>
2410int
2411main ()
2412{
2413exit (42);
2414  ;
2415  return 0;
2416}
2417_ACEOF
2418rm -f conftest.$ac_objext
2419if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2420  (eval $ac_compile) 2>conftest.er1
2421  ac_status=$?
2422  grep -v '^ *+' conftest.er1 >conftest.err
2423  rm -f conftest.er1
2424  cat conftest.err >&5
2425  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2426  (exit $ac_status); } &&
2427	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
2428  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2429  (eval $ac_try) 2>&5
2430  ac_status=$?
2431  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2432  (exit $ac_status); }; } &&
2433	 { ac_try='test -s conftest.$ac_objext'
2434  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2435  (eval $ac_try) 2>&5
2436  ac_status=$?
2437  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2438  (exit $ac_status); }; }; then
2439  :
2440else
2441  echo "$as_me: failed program was:" >&5
2442sed 's/^/| /' conftest.$ac_ext >&5
2443
2444continue
2445fi
2446rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2447  cat >conftest.$ac_ext <<_ACEOF
2448/* confdefs.h.  */
2449_ACEOF
2450cat confdefs.h >>conftest.$ac_ext
2451cat >>conftest.$ac_ext <<_ACEOF
2452/* end confdefs.h.  */
2453$ac_declaration
2454int
2455main ()
2456{
2457exit (42);
2458  ;
2459  return 0;
2460}
2461_ACEOF
2462rm -f conftest.$ac_objext
2463if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2464  (eval $ac_compile) 2>conftest.er1
2465  ac_status=$?
2466  grep -v '^ *+' conftest.er1 >conftest.err
2467  rm -f conftest.er1
2468  cat conftest.err >&5
2469  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2470  (exit $ac_status); } &&
2471	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
2472  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2473  (eval $ac_try) 2>&5
2474  ac_status=$?
2475  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2476  (exit $ac_status); }; } &&
2477	 { ac_try='test -s conftest.$ac_objext'
2478  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2479  (eval $ac_try) 2>&5
2480  ac_status=$?
2481  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2482  (exit $ac_status); }; }; then
2483  break
2484else
2485  echo "$as_me: failed program was:" >&5
2486sed 's/^/| /' conftest.$ac_ext >&5
2487
2488fi
2489rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2490done
2491rm -f conftest*
2492if test -n "$ac_declaration"; then
2493  echo '#ifdef __cplusplus' >>confdefs.h
2494  echo $ac_declaration      >>confdefs.h
2495  echo '#endif'             >>confdefs.h
2496fi
2497
2498else
2499  echo "$as_me: failed program was:" >&5
2500sed 's/^/| /' conftest.$ac_ext >&5
2501
2502fi
2503rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2504ac_ext=c
2505ac_cpp='$CPP $CPPFLAGS'
2506ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2507ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2508ac_compiler_gnu=$ac_cv_c_compiler_gnu
2509
2510ac_ext=cc
2511ac_cpp='$CXXCPP $CPPFLAGS'
2512ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2513ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2514ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
2515if test -n "$ac_tool_prefix"; then
2516  for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
2517  do
2518    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2519set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2520echo "$as_me:$LINENO: checking for $ac_word" >&5
2521echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2522if test "${ac_cv_prog_CXX+set}" = set; then
2523  echo $ECHO_N "(cached) $ECHO_C" >&6
2524else
2525  if test -n "$CXX"; then
2526  ac_cv_prog_CXX="$CXX" # Let the user override the test.
2527else
2528as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2529for as_dir in $PATH
2530do
2531  IFS=$as_save_IFS
2532  test -z "$as_dir" && as_dir=.
2533  for ac_exec_ext in '' $ac_executable_extensions; do
2534  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2535    ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
2536    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2537    break 2
2538  fi
2539done
2540done
2541
2542fi
2543fi
2544CXX=$ac_cv_prog_CXX
2545if test -n "$CXX"; then
2546  echo "$as_me:$LINENO: result: $CXX" >&5
2547echo "${ECHO_T}$CXX" >&6
2548else
2549  echo "$as_me:$LINENO: result: no" >&5
2550echo "${ECHO_T}no" >&6
2551fi
2552
2553    test -n "$CXX" && break
2554  done
2555fi
2556if test -z "$CXX"; then
2557  ac_ct_CXX=$CXX
2558  for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
2559do
2560  # Extract the first word of "$ac_prog", so it can be a program name with args.
2561set dummy $ac_prog; ac_word=$2
2562echo "$as_me:$LINENO: checking for $ac_word" >&5
2563echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2564if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then
2565  echo $ECHO_N "(cached) $ECHO_C" >&6
2566else
2567  if test -n "$ac_ct_CXX"; then
2568  ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
2569else
2570as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2571for as_dir in $PATH
2572do
2573  IFS=$as_save_IFS
2574  test -z "$as_dir" && as_dir=.
2575  for ac_exec_ext in '' $ac_executable_extensions; do
2576  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2577    ac_cv_prog_ac_ct_CXX="$ac_prog"
2578    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2579    break 2
2580  fi
2581done
2582done
2583
2584fi
2585fi
2586ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
2587if test -n "$ac_ct_CXX"; then
2588  echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
2589echo "${ECHO_T}$ac_ct_CXX" >&6
2590else
2591  echo "$as_me:$LINENO: result: no" >&5
2592echo "${ECHO_T}no" >&6
2593fi
2594
2595  test -n "$ac_ct_CXX" && break
2596done
2597test -n "$ac_ct_CXX" || ac_ct_CXX="g++"
2598
2599  CXX=$ac_ct_CXX
2600fi
2601
2602
2603# Provide some information about the compiler.
2604echo "$as_me:$LINENO:" \
2605     "checking for C++ compiler version" >&5
2606ac_compiler=`set X $ac_compile; echo $2`
2607{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
2608  (eval $ac_compiler --version </dev/null >&5) 2>&5
2609  ac_status=$?
2610  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2611  (exit $ac_status); }
2612{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
2613  (eval $ac_compiler -v </dev/null >&5) 2>&5
2614  ac_status=$?
2615  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2616  (exit $ac_status); }
2617{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
2618  (eval $ac_compiler -V </dev/null >&5) 2>&5
2619  ac_status=$?
2620  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2621  (exit $ac_status); }
2622
2623echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5
2624echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6
2625if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
2626  echo $ECHO_N "(cached) $ECHO_C" >&6
2627else
2628  cat >conftest.$ac_ext <<_ACEOF
2629/* confdefs.h.  */
2630_ACEOF
2631cat confdefs.h >>conftest.$ac_ext
2632cat >>conftest.$ac_ext <<_ACEOF
2633/* end confdefs.h.  */
2634
2635int
2636main ()
2637{
2638#ifndef __GNUC__
2639       choke me
2640#endif
2641
2642  ;
2643  return 0;
2644}
2645_ACEOF
2646rm -f conftest.$ac_objext
2647if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2648  (eval $ac_compile) 2>conftest.er1
2649  ac_status=$?
2650  grep -v '^ *+' conftest.er1 >conftest.err
2651  rm -f conftest.er1
2652  cat conftest.err >&5
2653  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2654  (exit $ac_status); } &&
2655	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
2656  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2657  (eval $ac_try) 2>&5
2658  ac_status=$?
2659  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2660  (exit $ac_status); }; } &&
2661	 { ac_try='test -s conftest.$ac_objext'
2662  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2663  (eval $ac_try) 2>&5
2664  ac_status=$?
2665  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2666  (exit $ac_status); }; }; then
2667  ac_compiler_gnu=yes
2668else
2669  echo "$as_me: failed program was:" >&5
2670sed 's/^/| /' conftest.$ac_ext >&5
2671
2672ac_compiler_gnu=no
2673fi
2674rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2675ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
2676
2677fi
2678echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
2679echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6
2680GXX=`test $ac_compiler_gnu = yes && echo yes`
2681ac_test_CXXFLAGS=${CXXFLAGS+set}
2682ac_save_CXXFLAGS=$CXXFLAGS
2683CXXFLAGS="-g"
2684echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
2685echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6
2686if test "${ac_cv_prog_cxx_g+set}" = set; then
2687  echo $ECHO_N "(cached) $ECHO_C" >&6
2688else
2689  cat >conftest.$ac_ext <<_ACEOF
2690/* confdefs.h.  */
2691_ACEOF
2692cat confdefs.h >>conftest.$ac_ext
2693cat >>conftest.$ac_ext <<_ACEOF
2694/* end confdefs.h.  */
2695
2696int
2697main ()
2698{
2699
2700  ;
2701  return 0;
2702}
2703_ACEOF
2704rm -f conftest.$ac_objext
2705if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2706  (eval $ac_compile) 2>conftest.er1
2707  ac_status=$?
2708  grep -v '^ *+' conftest.er1 >conftest.err
2709  rm -f conftest.er1
2710  cat conftest.err >&5
2711  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2712  (exit $ac_status); } &&
2713	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
2714  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2715  (eval $ac_try) 2>&5
2716  ac_status=$?
2717  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2718  (exit $ac_status); }; } &&
2719	 { ac_try='test -s conftest.$ac_objext'
2720  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2721  (eval $ac_try) 2>&5
2722  ac_status=$?
2723  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2724  (exit $ac_status); }; }; then
2725  ac_cv_prog_cxx_g=yes
2726else
2727  echo "$as_me: failed program was:" >&5
2728sed 's/^/| /' conftest.$ac_ext >&5
2729
2730ac_cv_prog_cxx_g=no
2731fi
2732rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2733fi
2734echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
2735echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6
2736if test "$ac_test_CXXFLAGS" = set; then
2737  CXXFLAGS=$ac_save_CXXFLAGS
2738elif test $ac_cv_prog_cxx_g = yes; then
2739  if test "$GXX" = yes; then
2740    CXXFLAGS="-g -O2"
2741  else
2742    CXXFLAGS="-g"
2743  fi
2744else
2745  if test "$GXX" = yes; then
2746    CXXFLAGS="-O2"
2747  else
2748    CXXFLAGS=
2749  fi
2750fi
2751for ac_declaration in \
2752   '' \
2753   'extern "C" void std::exit (int) throw (); using std::exit;' \
2754   'extern "C" void std::exit (int); using std::exit;' \
2755   'extern "C" void exit (int) throw ();' \
2756   'extern "C" void exit (int);' \
2757   'void exit (int);'
2758do
2759  cat >conftest.$ac_ext <<_ACEOF
2760/* confdefs.h.  */
2761_ACEOF
2762cat confdefs.h >>conftest.$ac_ext
2763cat >>conftest.$ac_ext <<_ACEOF
2764/* end confdefs.h.  */
2765$ac_declaration
2766@%:@include <stdlib.h>
2767int
2768main ()
2769{
2770exit (42);
2771  ;
2772  return 0;
2773}
2774_ACEOF
2775rm -f conftest.$ac_objext
2776if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2777  (eval $ac_compile) 2>conftest.er1
2778  ac_status=$?
2779  grep -v '^ *+' conftest.er1 >conftest.err
2780  rm -f conftest.er1
2781  cat conftest.err >&5
2782  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2783  (exit $ac_status); } &&
2784	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
2785  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2786  (eval $ac_try) 2>&5
2787  ac_status=$?
2788  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2789  (exit $ac_status); }; } &&
2790	 { ac_try='test -s conftest.$ac_objext'
2791  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2792  (eval $ac_try) 2>&5
2793  ac_status=$?
2794  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2795  (exit $ac_status); }; }; then
2796  :
2797else
2798  echo "$as_me: failed program was:" >&5
2799sed 's/^/| /' conftest.$ac_ext >&5
2800
2801continue
2802fi
2803rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2804  cat >conftest.$ac_ext <<_ACEOF
2805/* confdefs.h.  */
2806_ACEOF
2807cat confdefs.h >>conftest.$ac_ext
2808cat >>conftest.$ac_ext <<_ACEOF
2809/* end confdefs.h.  */
2810$ac_declaration
2811int
2812main ()
2813{
2814exit (42);
2815  ;
2816  return 0;
2817}
2818_ACEOF
2819rm -f conftest.$ac_objext
2820if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2821  (eval $ac_compile) 2>conftest.er1
2822  ac_status=$?
2823  grep -v '^ *+' conftest.er1 >conftest.err
2824  rm -f conftest.er1
2825  cat conftest.err >&5
2826  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2827  (exit $ac_status); } &&
2828	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
2829  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2830  (eval $ac_try) 2>&5
2831  ac_status=$?
2832  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2833  (exit $ac_status); }; } &&
2834	 { ac_try='test -s conftest.$ac_objext'
2835  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2836  (eval $ac_try) 2>&5
2837  ac_status=$?
2838  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2839  (exit $ac_status); }; }; then
2840  break
2841else
2842  echo "$as_me: failed program was:" >&5
2843sed 's/^/| /' conftest.$ac_ext >&5
2844
2845fi
2846rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2847done
2848rm -f conftest*
2849if test -n "$ac_declaration"; then
2850  echo '#ifdef __cplusplus' >>confdefs.h
2851  echo $ac_declaration      >>confdefs.h
2852  echo '#endif'             >>confdefs.h
2853fi
2854
2855ac_ext=c
2856ac_cpp='$CPP $CPPFLAGS'
2857ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2858ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2859ac_compiler_gnu=$ac_cv_c_compiler_gnu
2860
2861# Find a good install program.  We prefer a C program (faster),
2862# so one script is as good as another.  But avoid the broken or
2863# incompatible versions:
2864# SysV /etc/install, /usr/sbin/install
2865# SunOS /usr/etc/install
2866# IRIX /sbin/install
2867# AIX /bin/install
2868# AmigaOS /C/install, which installs bootblocks on floppy discs
2869# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2870# AFS /usr/afsws/bin/install, which mishandles nonexistent args
2871# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2872# OS/2's system install, which has a completely different semantic
2873# ./install, which can be erroneously created by make from ./install.sh.
2874echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
2875echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
2876if test -z "$INSTALL"; then
2877if test "${ac_cv_path_install+set}" = set; then
2878  echo $ECHO_N "(cached) $ECHO_C" >&6
2879else
2880  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2881for as_dir in $PATH
2882do
2883  IFS=$as_save_IFS
2884  test -z "$as_dir" && as_dir=.
2885  # Account for people who put trailing slashes in PATH elements.
2886case $as_dir/ in
2887  ./ | .// | /cC/* | \
2888  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
2889  ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
2890  /usr/ucb/* ) ;;
2891  *)
2892    # OSF1 and SCO ODT 3.0 have their own names for install.
2893    # Don't use installbsd from OSF since it installs stuff as root
2894    # by default.
2895    for ac_prog in ginstall scoinst install; do
2896      for ac_exec_ext in '' $ac_executable_extensions; do
2897	if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
2898	  if test $ac_prog = install &&
2899	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2900	    # AIX install.  It has an incompatible calling convention.
2901	    :
2902	  elif test $ac_prog = install &&
2903	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2904	    # program-specific install script used by HP pwplus--don't use.
2905	    :
2906	  else
2907	    ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
2908	    break 3
2909	  fi
2910	fi
2911      done
2912    done
2913    ;;
2914esac
2915done
2916
2917
2918fi
2919  if test "${ac_cv_path_install+set}" = set; then
2920    INSTALL=$ac_cv_path_install
2921  else
2922    # As a last resort, use the slow shell script.  We don't cache a
2923    # path for INSTALL within a source directory, because that will
2924    # break other packages using the cache if that directory is
2925    # removed, or if the path is relative.
2926    INSTALL=$ac_install_sh
2927  fi
2928fi
2929echo "$as_me:$LINENO: result: $INSTALL" >&5
2930echo "${ECHO_T}$INSTALL" >&6
2931
2932# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2933# It thinks the first close brace ends the variable substitution.
2934test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2935
2936test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2937
2938test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2939
2940
2941
2942ac_ext=c
2943ac_cpp='$CPP $CPPFLAGS'
2944ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2945ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2946ac_compiler_gnu=$ac_cv_c_compiler_gnu
2947echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2948echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2949# On Suns, sometimes $CPP names a directory.
2950if test -n "$CPP" && test -d "$CPP"; then
2951  CPP=
2952fi
2953if test -z "$CPP"; then
2954  if test "${ac_cv_prog_CPP+set}" = set; then
2955  echo $ECHO_N "(cached) $ECHO_C" >&6
2956else
2957      # Double quotes because CPP needs to be expanded
2958    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2959    do
2960      ac_preproc_ok=false
2961for ac_c_preproc_warn_flag in '' yes
2962do
2963  # Use a header file that comes with gcc, so configuring glibc
2964  # with a fresh cross-compiler works.
2965  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2966  # <limits.h> exists even on freestanding compilers.
2967  # On the NeXT, cc -E runs the code through the compiler's parser,
2968  # not just through cpp. "Syntax error" is here to catch this case.
2969  cat >conftest.$ac_ext <<_ACEOF
2970/* confdefs.h.  */
2971_ACEOF
2972cat confdefs.h >>conftest.$ac_ext
2973cat >>conftest.$ac_ext <<_ACEOF
2974/* end confdefs.h.  */
2975@%:@ifdef __STDC__
2976@%:@ include <limits.h>
2977@%:@else
2978@%:@ include <assert.h>
2979@%:@endif
2980		     Syntax error
2981_ACEOF
2982if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2983  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2984  ac_status=$?
2985  grep -v '^ *+' conftest.er1 >conftest.err
2986  rm -f conftest.er1
2987  cat conftest.err >&5
2988  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2989  (exit $ac_status); } >/dev/null; then
2990  if test -s conftest.err; then
2991    ac_cpp_err=$ac_c_preproc_warn_flag
2992    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2993  else
2994    ac_cpp_err=
2995  fi
2996else
2997  ac_cpp_err=yes
2998fi
2999if test -z "$ac_cpp_err"; then
3000  :
3001else
3002  echo "$as_me: failed program was:" >&5
3003sed 's/^/| /' conftest.$ac_ext >&5
3004
3005  # Broken: fails on valid input.
3006continue
3007fi
3008rm -f conftest.err conftest.$ac_ext
3009
3010  # OK, works on sane cases.  Now check whether non-existent headers
3011  # can be detected and how.
3012  cat >conftest.$ac_ext <<_ACEOF
3013/* confdefs.h.  */
3014_ACEOF
3015cat confdefs.h >>conftest.$ac_ext
3016cat >>conftest.$ac_ext <<_ACEOF
3017/* end confdefs.h.  */
3018@%:@include <ac_nonexistent.h>
3019_ACEOF
3020if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3021  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3022  ac_status=$?
3023  grep -v '^ *+' conftest.er1 >conftest.err
3024  rm -f conftest.er1
3025  cat conftest.err >&5
3026  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3027  (exit $ac_status); } >/dev/null; then
3028  if test -s conftest.err; then
3029    ac_cpp_err=$ac_c_preproc_warn_flag
3030    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3031  else
3032    ac_cpp_err=
3033  fi
3034else
3035  ac_cpp_err=yes
3036fi
3037if test -z "$ac_cpp_err"; then
3038  # Broken: success on invalid input.
3039continue
3040else
3041  echo "$as_me: failed program was:" >&5
3042sed 's/^/| /' conftest.$ac_ext >&5
3043
3044  # Passes both tests.
3045ac_preproc_ok=:
3046break
3047fi
3048rm -f conftest.err conftest.$ac_ext
3049
3050done
3051# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3052rm -f conftest.err conftest.$ac_ext
3053if $ac_preproc_ok; then
3054  break
3055fi
3056
3057    done
3058    ac_cv_prog_CPP=$CPP
3059
3060fi
3061  CPP=$ac_cv_prog_CPP
3062else
3063  ac_cv_prog_CPP=$CPP
3064fi
3065echo "$as_me:$LINENO: result: $CPP" >&5
3066echo "${ECHO_T}$CPP" >&6
3067ac_preproc_ok=false
3068for ac_c_preproc_warn_flag in '' yes
3069do
3070  # Use a header file that comes with gcc, so configuring glibc
3071  # with a fresh cross-compiler works.
3072  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3073  # <limits.h> exists even on freestanding compilers.
3074  # On the NeXT, cc -E runs the code through the compiler's parser,
3075  # not just through cpp. "Syntax error" is here to catch this case.
3076  cat >conftest.$ac_ext <<_ACEOF
3077/* confdefs.h.  */
3078_ACEOF
3079cat confdefs.h >>conftest.$ac_ext
3080cat >>conftest.$ac_ext <<_ACEOF
3081/* end confdefs.h.  */
3082@%:@ifdef __STDC__
3083@%:@ include <limits.h>
3084@%:@else
3085@%:@ include <assert.h>
3086@%:@endif
3087		     Syntax error
3088_ACEOF
3089if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3090  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3091  ac_status=$?
3092  grep -v '^ *+' conftest.er1 >conftest.err
3093  rm -f conftest.er1
3094  cat conftest.err >&5
3095  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3096  (exit $ac_status); } >/dev/null; then
3097  if test -s conftest.err; then
3098    ac_cpp_err=$ac_c_preproc_warn_flag
3099    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3100  else
3101    ac_cpp_err=
3102  fi
3103else
3104  ac_cpp_err=yes
3105fi
3106if test -z "$ac_cpp_err"; then
3107  :
3108else
3109  echo "$as_me: failed program was:" >&5
3110sed 's/^/| /' conftest.$ac_ext >&5
3111
3112  # Broken: fails on valid input.
3113continue
3114fi
3115rm -f conftest.err conftest.$ac_ext
3116
3117  # OK, works on sane cases.  Now check whether non-existent headers
3118  # can be detected and how.
3119  cat >conftest.$ac_ext <<_ACEOF
3120/* confdefs.h.  */
3121_ACEOF
3122cat confdefs.h >>conftest.$ac_ext
3123cat >>conftest.$ac_ext <<_ACEOF
3124/* end confdefs.h.  */
3125@%:@include <ac_nonexistent.h>
3126_ACEOF
3127if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3128  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3129  ac_status=$?
3130  grep -v '^ *+' conftest.er1 >conftest.err
3131  rm -f conftest.er1
3132  cat conftest.err >&5
3133  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3134  (exit $ac_status); } >/dev/null; then
3135  if test -s conftest.err; then
3136    ac_cpp_err=$ac_c_preproc_warn_flag
3137    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3138  else
3139    ac_cpp_err=
3140  fi
3141else
3142  ac_cpp_err=yes
3143fi
3144if test -z "$ac_cpp_err"; then
3145  # Broken: success on invalid input.
3146continue
3147else
3148  echo "$as_me: failed program was:" >&5
3149sed 's/^/| /' conftest.$ac_ext >&5
3150
3151  # Passes both tests.
3152ac_preproc_ok=:
3153break
3154fi
3155rm -f conftest.err conftest.$ac_ext
3156
3157done
3158# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3159rm -f conftest.err conftest.$ac_ext
3160if $ac_preproc_ok; then
3161  :
3162else
3163  { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3164See \`config.log' for more details." >&5
3165echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3166See \`config.log' for more details." >&2;}
3167   { (exit 1); exit 1; }; }
3168fi
3169
3170ac_ext=c
3171ac_cpp='$CPP $CPPFLAGS'
3172ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3173ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3174ac_compiler_gnu=$ac_cv_c_compiler_gnu
3175
3176
3177
3178if test "x$ac_path_x_has_been_run" != xyes; then
3179  echo "$as_me:$LINENO: checking for X" >&5
3180echo $ECHO_N "checking for X... $ECHO_C" >&6
3181
3182ac_path_x_has_been_run=yes
3183
3184# Check whether --with-x or --without-x was given.
3185if test "${with_x+set}" = set; then
3186  withval="$with_x"
3187
3188fi;
3189# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
3190if test "x$with_x" = xno; then
3191  # The user explicitly disabled X.
3192  have_x=disabled
3193else
3194  if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
3195    # Both variables are already set.
3196    have_x=yes
3197  else
3198    if test "${ac_cv_have_x+set}" = set; then
3199  echo $ECHO_N "(cached) $ECHO_C" >&6
3200else
3201  # One or both of the vars are not set, and there is no cached value.
3202ac_x_includes=no ac_x_libraries=no
3203rm -fr conftest.dir
3204if mkdir conftest.dir; then
3205  cd conftest.dir
3206  # Make sure to not put "make" in the Imakefile rules, since we grep it out.
3207  cat >Imakefile <<'_ACEOF'
3208acfindx:
3209	@echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
3210_ACEOF
3211  if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
3212    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3213    eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
3214    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
3215    for ac_extension in a so sl; do
3216      if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
3217	 test -f $ac_im_libdir/libX11.$ac_extension; then
3218	ac_im_usrlibdir=$ac_im_libdir; break
3219      fi
3220    done
3221    # Screen out bogus values from the imake configuration.  They are
3222    # bogus both because they are the default anyway, and because
3223    # using them would break gcc on systems where it needs fixed includes.
3224    case $ac_im_incroot in
3225	/usr/include) ;;
3226	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
3227    esac
3228    case $ac_im_usrlibdir in
3229	/usr/lib | /lib) ;;
3230	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
3231    esac
3232  fi
3233  cd ..
3234  rm -fr conftest.dir
3235fi
3236
3237# Standard set of common directories for X headers.
3238# Check X11 before X11Rn because it is often a symlink to the current release.
3239ac_x_header_dirs='
3240/usr/X11/include
3241/usr/X11R6/include
3242/usr/X11R5/include
3243/usr/X11R4/include
3244
3245/usr/include/X11
3246/usr/include/X11R6
3247/usr/include/X11R5
3248/usr/include/X11R4
3249
3250/usr/local/X11/include
3251/usr/local/X11R6/include
3252/usr/local/X11R5/include
3253/usr/local/X11R4/include
3254
3255/usr/local/include/X11
3256/usr/local/include/X11R6
3257/usr/local/include/X11R5
3258/usr/local/include/X11R4
3259
3260/usr/X386/include
3261/usr/x386/include
3262/usr/XFree86/include/X11
3263
3264/usr/include
3265/usr/local/include
3266/usr/unsupported/include
3267/usr/athena/include
3268/usr/local/x11r5/include
3269/usr/lpp/Xamples/include
3270
3271/usr/openwin/include
3272/usr/openwin/share/include'
3273
3274if test "$ac_x_includes" = no; then
3275  # Guess where to find include files, by looking for a specified header file.
3276  # First, try using that file with no special directory specified.
3277  cat >conftest.$ac_ext <<_ACEOF
3278/* confdefs.h.  */
3279_ACEOF
3280cat confdefs.h >>conftest.$ac_ext
3281cat >>conftest.$ac_ext <<_ACEOF
3282/* end confdefs.h.  */
3283@%:@include <X11/Xlib.h>
3284_ACEOF
3285if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3286  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3287  ac_status=$?
3288  grep -v '^ *+' conftest.er1 >conftest.err
3289  rm -f conftest.er1
3290  cat conftest.err >&5
3291  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3292  (exit $ac_status); } >/dev/null; then
3293  if test -s conftest.err; then
3294    ac_cpp_err=$ac_c_preproc_warn_flag
3295    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3296  else
3297    ac_cpp_err=
3298  fi
3299else
3300  ac_cpp_err=yes
3301fi
3302if test -z "$ac_cpp_err"; then
3303  # We can compile using X headers with no special include directory.
3304ac_x_includes=
3305else
3306  echo "$as_me: failed program was:" >&5
3307sed 's/^/| /' conftest.$ac_ext >&5
3308
3309  for ac_dir in $ac_x_header_dirs; do
3310  if test -r "$ac_dir/X11/Xlib.h"; then
3311    ac_x_includes=$ac_dir
3312    break
3313  fi
3314done
3315fi
3316rm -f conftest.err conftest.$ac_ext
3317fi # $ac_x_includes = no
3318
3319if test "$ac_x_libraries" = no; then
3320  # Check for the libraries.
3321  # See if we find them without any special options.
3322  # Don't add to $LIBS permanently.
3323  ac_save_LIBS=$LIBS
3324  LIBS="-lX11 $LIBS"
3325  cat >conftest.$ac_ext <<_ACEOF
3326/* confdefs.h.  */
3327_ACEOF
3328cat confdefs.h >>conftest.$ac_ext
3329cat >>conftest.$ac_ext <<_ACEOF
3330/* end confdefs.h.  */
3331@%:@include <X11/Xlib.h>
3332int
3333main ()
3334{
3335XrmInitialize ()
3336  ;
3337  return 0;
3338}
3339_ACEOF
3340rm -f conftest.$ac_objext conftest$ac_exeext
3341if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3342  (eval $ac_link) 2>conftest.er1
3343  ac_status=$?
3344  grep -v '^ *+' conftest.er1 >conftest.err
3345  rm -f conftest.er1
3346  cat conftest.err >&5
3347  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3348  (exit $ac_status); } &&
3349	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
3350  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3351  (eval $ac_try) 2>&5
3352  ac_status=$?
3353  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3354  (exit $ac_status); }; } &&
3355	 { ac_try='test -s conftest$ac_exeext'
3356  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3357  (eval $ac_try) 2>&5
3358  ac_status=$?
3359  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3360  (exit $ac_status); }; }; then
3361  LIBS=$ac_save_LIBS
3362# We can link X programs with no special library path.
3363ac_x_libraries=
3364else
3365  echo "$as_me: failed program was:" >&5
3366sed 's/^/| /' conftest.$ac_ext >&5
3367
3368LIBS=$ac_save_LIBS
3369for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
3370do
3371  # Don't even attempt the hair of trying to link an X program!
3372  for ac_extension in a so sl; do
3373    if test -r $ac_dir/libX11.$ac_extension; then
3374      ac_x_libraries=$ac_dir
3375      break 2
3376    fi
3377  done
3378done
3379fi
3380rm -f conftest.err conftest.$ac_objext \
3381      conftest$ac_exeext conftest.$ac_ext
3382fi # $ac_x_libraries = no
3383
3384if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
3385  # Didn't find X anywhere.  Cache the known absence of X.
3386  ac_cv_have_x="have_x=no"
3387else
3388  # Record where we found X for the cache.
3389  ac_cv_have_x="have_x=yes \
3390		ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
3391fi
3392fi
3393
3394  fi
3395  eval "$ac_cv_have_x"
3396fi # $with_x != no
3397
3398if test "$have_x" != yes; then
3399  echo "$as_me:$LINENO: result: $have_x" >&5
3400echo "${ECHO_T}$have_x" >&6
3401  no_x=yes
3402else
3403  # If each of the values was on the command line, it overrides each guess.
3404  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
3405  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
3406  # Update the cache value to reflect the command line values.
3407  ac_cv_have_x="have_x=yes \
3408		ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
3409  # It might be that x_includes is empty (headers are found in the
3410  # standard search path. Then output the corresponding message
3411  ac_out_x_includes=$x_includes
3412  test "x$x_includes" = x && ac_out_x_includes="in standard search path"
3413  echo "$as_me:$LINENO: result: libraries $x_libraries, headers $ac_out_x_includes" >&5
3414echo "${ECHO_T}libraries $x_libraries, headers $ac_out_x_includes" >&6
3415fi
3416
3417fi
3418if test "$no_x" = yes; then
3419  # Not all programs may use this symbol, but it does not hurt to define it.
3420
3421cat >>confdefs.h <<\_ACEOF
3422@%:@define X_DISPLAY_MISSING 1
3423_ACEOF
3424
3425  X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
3426else
3427  if test -n "$x_includes"; then
3428    X_CFLAGS="$X_CFLAGS -I$x_includes"
3429  fi
3430
3431  # It would also be nice to do this for all -L options, not just this one.
3432  if test -n "$x_libraries"; then
3433    X_LIBS="$X_LIBS -L$x_libraries"
3434    # For Solaris; some versions of Sun CC require a space after -R and
3435    # others require no space.  Words are not sufficient . . . .
3436    case `(uname -sr) 2>/dev/null` in
3437    "SunOS 5"*)
3438      echo "$as_me:$LINENO: checking whether -R must be followed by a space" >&5
3439echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
3440      ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
3441      cat >conftest.$ac_ext <<_ACEOF
3442/* confdefs.h.  */
3443_ACEOF
3444cat confdefs.h >>conftest.$ac_ext
3445cat >>conftest.$ac_ext <<_ACEOF
3446/* end confdefs.h.  */
3447
3448int
3449main ()
3450{
3451
3452  ;
3453  return 0;
3454}
3455_ACEOF
3456rm -f conftest.$ac_objext conftest$ac_exeext
3457if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3458  (eval $ac_link) 2>conftest.er1
3459  ac_status=$?
3460  grep -v '^ *+' conftest.er1 >conftest.err
3461  rm -f conftest.er1
3462  cat conftest.err >&5
3463  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3464  (exit $ac_status); } &&
3465	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
3466  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3467  (eval $ac_try) 2>&5
3468  ac_status=$?
3469  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3470  (exit $ac_status); }; } &&
3471	 { ac_try='test -s conftest$ac_exeext'
3472  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3473  (eval $ac_try) 2>&5
3474  ac_status=$?
3475  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3476  (exit $ac_status); }; }; then
3477  ac_R_nospace=yes
3478else
3479  echo "$as_me: failed program was:" >&5
3480sed 's/^/| /' conftest.$ac_ext >&5
3481
3482ac_R_nospace=no
3483fi
3484rm -f conftest.err conftest.$ac_objext \
3485      conftest$ac_exeext conftest.$ac_ext
3486      if test $ac_R_nospace = yes; then
3487	echo "$as_me:$LINENO: result: no" >&5
3488echo "${ECHO_T}no" >&6
3489	X_LIBS="$X_LIBS -R$x_libraries"
3490      else
3491	LIBS="$ac_xsave_LIBS -R $x_libraries"
3492	cat >conftest.$ac_ext <<_ACEOF
3493/* confdefs.h.  */
3494_ACEOF
3495cat confdefs.h >>conftest.$ac_ext
3496cat >>conftest.$ac_ext <<_ACEOF
3497/* end confdefs.h.  */
3498
3499int
3500main ()
3501{
3502
3503  ;
3504  return 0;
3505}
3506_ACEOF
3507rm -f conftest.$ac_objext conftest$ac_exeext
3508if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3509  (eval $ac_link) 2>conftest.er1
3510  ac_status=$?
3511  grep -v '^ *+' conftest.er1 >conftest.err
3512  rm -f conftest.er1
3513  cat conftest.err >&5
3514  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3515  (exit $ac_status); } &&
3516	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
3517  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3518  (eval $ac_try) 2>&5
3519  ac_status=$?
3520  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3521  (exit $ac_status); }; } &&
3522	 { ac_try='test -s conftest$ac_exeext'
3523  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3524  (eval $ac_try) 2>&5
3525  ac_status=$?
3526  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3527  (exit $ac_status); }; }; then
3528  ac_R_space=yes
3529else
3530  echo "$as_me: failed program was:" >&5
3531sed 's/^/| /' conftest.$ac_ext >&5
3532
3533ac_R_space=no
3534fi
3535rm -f conftest.err conftest.$ac_objext \
3536      conftest$ac_exeext conftest.$ac_ext
3537	if test $ac_R_space = yes; then
3538	  echo "$as_me:$LINENO: result: yes" >&5
3539echo "${ECHO_T}yes" >&6
3540	  X_LIBS="$X_LIBS -R $x_libraries"
3541	else
3542	  echo "$as_me:$LINENO: result: neither works" >&5
3543echo "${ECHO_T}neither works" >&6
3544	fi
3545      fi
3546      LIBS=$ac_xsave_LIBS
3547    esac
3548  fi
3549
3550  # Check for system-dependent libraries X programs must link with.
3551  # Do this before checking for the system-independent R6 libraries
3552  # (-lICE), since we may need -lsocket or whatever for X linking.
3553
3554  if test "$ISC" = yes; then
3555    X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
3556  else
3557    # Martyn Johnson says this is needed for Ultrix, if the X
3558    # libraries were built with DECnet support.  And Karl Berry says
3559    # the Alpha needs dnet_stub (dnet does not exist).
3560    ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
3561    cat >conftest.$ac_ext <<_ACEOF
3562/* confdefs.h.  */
3563_ACEOF
3564cat confdefs.h >>conftest.$ac_ext
3565cat >>conftest.$ac_ext <<_ACEOF
3566/* end confdefs.h.  */
3567
3568/* Override any gcc2 internal prototype to avoid an error.  */
3569#ifdef __cplusplus
3570extern "C"
3571#endif
3572/* We use char because int might match the return type of a gcc2
3573   builtin and then its argument prototype would still apply.  */
3574char XOpenDisplay ();
3575int
3576main ()
3577{
3578XOpenDisplay ();
3579  ;
3580  return 0;
3581}
3582_ACEOF
3583rm -f conftest.$ac_objext conftest$ac_exeext
3584if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3585  (eval $ac_link) 2>conftest.er1
3586  ac_status=$?
3587  grep -v '^ *+' conftest.er1 >conftest.err
3588  rm -f conftest.er1
3589  cat conftest.err >&5
3590  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3591  (exit $ac_status); } &&
3592	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
3593  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3594  (eval $ac_try) 2>&5
3595  ac_status=$?
3596  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3597  (exit $ac_status); }; } &&
3598	 { ac_try='test -s conftest$ac_exeext'
3599  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3600  (eval $ac_try) 2>&5
3601  ac_status=$?
3602  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3603  (exit $ac_status); }; }; then
3604  :
3605else
3606  echo "$as_me: failed program was:" >&5
3607sed 's/^/| /' conftest.$ac_ext >&5
3608
3609echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet" >&5
3610echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
3611if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
3612  echo $ECHO_N "(cached) $ECHO_C" >&6
3613else
3614  ac_check_lib_save_LIBS=$LIBS
3615LIBS="-ldnet  $LIBS"
3616cat >conftest.$ac_ext <<_ACEOF
3617/* confdefs.h.  */
3618_ACEOF
3619cat confdefs.h >>conftest.$ac_ext
3620cat >>conftest.$ac_ext <<_ACEOF
3621/* end confdefs.h.  */
3622
3623/* Override any gcc2 internal prototype to avoid an error.  */
3624#ifdef __cplusplus
3625extern "C"
3626#endif
3627/* We use char because int might match the return type of a gcc2
3628   builtin and then its argument prototype would still apply.  */
3629char dnet_ntoa ();
3630int
3631main ()
3632{
3633dnet_ntoa ();
3634  ;
3635  return 0;
3636}
3637_ACEOF
3638rm -f conftest.$ac_objext conftest$ac_exeext
3639if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3640  (eval $ac_link) 2>conftest.er1
3641  ac_status=$?
3642  grep -v '^ *+' conftest.er1 >conftest.err
3643  rm -f conftest.er1
3644  cat conftest.err >&5
3645  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3646  (exit $ac_status); } &&
3647	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
3648  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3649  (eval $ac_try) 2>&5
3650  ac_status=$?
3651  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3652  (exit $ac_status); }; } &&
3653	 { ac_try='test -s conftest$ac_exeext'
3654  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3655  (eval $ac_try) 2>&5
3656  ac_status=$?
3657  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3658  (exit $ac_status); }; }; then
3659  ac_cv_lib_dnet_dnet_ntoa=yes
3660else
3661  echo "$as_me: failed program was:" >&5
3662sed 's/^/| /' conftest.$ac_ext >&5
3663
3664ac_cv_lib_dnet_dnet_ntoa=no
3665fi
3666rm -f conftest.err conftest.$ac_objext \
3667      conftest$ac_exeext conftest.$ac_ext
3668LIBS=$ac_check_lib_save_LIBS
3669fi
3670echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
3671echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
3672if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
3673  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
3674fi
3675
3676    if test $ac_cv_lib_dnet_dnet_ntoa = no; then
3677      echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet_stub" >&5
3678echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
3679if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
3680  echo $ECHO_N "(cached) $ECHO_C" >&6
3681else
3682  ac_check_lib_save_LIBS=$LIBS
3683LIBS="-ldnet_stub  $LIBS"
3684cat >conftest.$ac_ext <<_ACEOF
3685/* confdefs.h.  */
3686_ACEOF
3687cat confdefs.h >>conftest.$ac_ext
3688cat >>conftest.$ac_ext <<_ACEOF
3689/* end confdefs.h.  */
3690
3691/* Override any gcc2 internal prototype to avoid an error.  */
3692#ifdef __cplusplus
3693extern "C"
3694#endif
3695/* We use char because int might match the return type of a gcc2
3696   builtin and then its argument prototype would still apply.  */
3697char dnet_ntoa ();
3698int
3699main ()
3700{
3701dnet_ntoa ();
3702  ;
3703  return 0;
3704}
3705_ACEOF
3706rm -f conftest.$ac_objext conftest$ac_exeext
3707if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3708  (eval $ac_link) 2>conftest.er1
3709  ac_status=$?
3710  grep -v '^ *+' conftest.er1 >conftest.err
3711  rm -f conftest.er1
3712  cat conftest.err >&5
3713  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3714  (exit $ac_status); } &&
3715	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
3716  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3717  (eval $ac_try) 2>&5
3718  ac_status=$?
3719  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3720  (exit $ac_status); }; } &&
3721	 { ac_try='test -s conftest$ac_exeext'
3722  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3723  (eval $ac_try) 2>&5
3724  ac_status=$?
3725  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3726  (exit $ac_status); }; }; then
3727  ac_cv_lib_dnet_stub_dnet_ntoa=yes
3728else
3729  echo "$as_me: failed program was:" >&5
3730sed 's/^/| /' conftest.$ac_ext >&5
3731
3732ac_cv_lib_dnet_stub_dnet_ntoa=no
3733fi
3734rm -f conftest.err conftest.$ac_objext \
3735      conftest$ac_exeext conftest.$ac_ext
3736LIBS=$ac_check_lib_save_LIBS
3737fi
3738echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
3739echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
3740if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
3741  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
3742fi
3743
3744    fi
3745fi
3746rm -f conftest.err conftest.$ac_objext \
3747      conftest$ac_exeext conftest.$ac_ext
3748    LIBS="$ac_xsave_LIBS"
3749
3750    # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
3751    # to get the SysV transport functions.
3752    # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
3753    # needs -lnsl.
3754    # The nsl library prevents programs from opening the X display
3755    # on Irix 5.2, according to T.E. Dickey.
3756    # The functions gethostbyname, getservbyname, and inet_addr are
3757    # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
3758    echo "$as_me:$LINENO: checking for gethostbyname" >&5
3759echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
3760if test "${ac_cv_func_gethostbyname+set}" = set; then
3761  echo $ECHO_N "(cached) $ECHO_C" >&6
3762else
3763  cat >conftest.$ac_ext <<_ACEOF
3764/* confdefs.h.  */
3765_ACEOF
3766cat confdefs.h >>conftest.$ac_ext
3767cat >>conftest.$ac_ext <<_ACEOF
3768/* end confdefs.h.  */
3769/* Define gethostbyname to an innocuous variant, in case <limits.h> declares gethostbyname.
3770   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
3771#define gethostbyname innocuous_gethostbyname
3772
3773/* System header to define __stub macros and hopefully few prototypes,
3774    which can conflict with char gethostbyname (); below.
3775    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3776    <limits.h> exists even on freestanding compilers.  */
3777
3778#ifdef __STDC__
3779# include <limits.h>
3780#else
3781# include <assert.h>
3782#endif
3783
3784#undef gethostbyname
3785
3786/* Override any gcc2 internal prototype to avoid an error.  */
3787#ifdef __cplusplus
3788extern "C"
3789{
3790#endif
3791/* We use char because int might match the return type of a gcc2
3792   builtin and then its argument prototype would still apply.  */
3793char gethostbyname ();
3794/* The GNU C library defines this for functions which it implements
3795    to always fail with ENOSYS.  Some functions are actually named
3796    something starting with __ and the normal name is an alias.  */
3797#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
3798choke me
3799#else
3800char (*f) () = gethostbyname;
3801#endif
3802#ifdef __cplusplus
3803}
3804#endif
3805
3806int
3807main ()
3808{
3809return f != gethostbyname;
3810  ;
3811  return 0;
3812}
3813_ACEOF
3814rm -f conftest.$ac_objext conftest$ac_exeext
3815if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3816  (eval $ac_link) 2>conftest.er1
3817  ac_status=$?
3818  grep -v '^ *+' conftest.er1 >conftest.err
3819  rm -f conftest.er1
3820  cat conftest.err >&5
3821  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3822  (exit $ac_status); } &&
3823	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
3824  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3825  (eval $ac_try) 2>&5
3826  ac_status=$?
3827  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3828  (exit $ac_status); }; } &&
3829	 { ac_try='test -s conftest$ac_exeext'
3830  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3831  (eval $ac_try) 2>&5
3832  ac_status=$?
3833  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3834  (exit $ac_status); }; }; then
3835  ac_cv_func_gethostbyname=yes
3836else
3837  echo "$as_me: failed program was:" >&5
3838sed 's/^/| /' conftest.$ac_ext >&5
3839
3840ac_cv_func_gethostbyname=no
3841fi
3842rm -f conftest.err conftest.$ac_objext \
3843      conftest$ac_exeext conftest.$ac_ext
3844fi
3845echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname" >&5
3846echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
3847
3848    if test $ac_cv_func_gethostbyname = no; then
3849      echo "$as_me:$LINENO: checking for gethostbyname in -lnsl" >&5
3850echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
3851if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
3852  echo $ECHO_N "(cached) $ECHO_C" >&6
3853else
3854  ac_check_lib_save_LIBS=$LIBS
3855LIBS="-lnsl  $LIBS"
3856cat >conftest.$ac_ext <<_ACEOF
3857/* confdefs.h.  */
3858_ACEOF
3859cat confdefs.h >>conftest.$ac_ext
3860cat >>conftest.$ac_ext <<_ACEOF
3861/* end confdefs.h.  */
3862
3863/* Override any gcc2 internal prototype to avoid an error.  */
3864#ifdef __cplusplus
3865extern "C"
3866#endif
3867/* We use char because int might match the return type of a gcc2
3868   builtin and then its argument prototype would still apply.  */
3869char gethostbyname ();
3870int
3871main ()
3872{
3873gethostbyname ();
3874  ;
3875  return 0;
3876}
3877_ACEOF
3878rm -f conftest.$ac_objext conftest$ac_exeext
3879if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3880  (eval $ac_link) 2>conftest.er1
3881  ac_status=$?
3882  grep -v '^ *+' conftest.er1 >conftest.err
3883  rm -f conftest.er1
3884  cat conftest.err >&5
3885  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3886  (exit $ac_status); } &&
3887	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
3888  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3889  (eval $ac_try) 2>&5
3890  ac_status=$?
3891  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3892  (exit $ac_status); }; } &&
3893	 { ac_try='test -s conftest$ac_exeext'
3894  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3895  (eval $ac_try) 2>&5
3896  ac_status=$?
3897  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3898  (exit $ac_status); }; }; then
3899  ac_cv_lib_nsl_gethostbyname=yes
3900else
3901  echo "$as_me: failed program was:" >&5
3902sed 's/^/| /' conftest.$ac_ext >&5
3903
3904ac_cv_lib_nsl_gethostbyname=no
3905fi
3906rm -f conftest.err conftest.$ac_objext \
3907      conftest$ac_exeext conftest.$ac_ext
3908LIBS=$ac_check_lib_save_LIBS
3909fi
3910echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_gethostbyname" >&5
3911echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
3912if test $ac_cv_lib_nsl_gethostbyname = yes; then
3913  X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
3914fi
3915
3916      if test $ac_cv_lib_nsl_gethostbyname = no; then
3917	echo "$as_me:$LINENO: checking for gethostbyname in -lbsd" >&5
3918echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
3919if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
3920  echo $ECHO_N "(cached) $ECHO_C" >&6
3921else
3922  ac_check_lib_save_LIBS=$LIBS
3923LIBS="-lbsd  $LIBS"
3924cat >conftest.$ac_ext <<_ACEOF
3925/* confdefs.h.  */
3926_ACEOF
3927cat confdefs.h >>conftest.$ac_ext
3928cat >>conftest.$ac_ext <<_ACEOF
3929/* end confdefs.h.  */
3930
3931/* Override any gcc2 internal prototype to avoid an error.  */
3932#ifdef __cplusplus
3933extern "C"
3934#endif
3935/* We use char because int might match the return type of a gcc2
3936   builtin and then its argument prototype would still apply.  */
3937char gethostbyname ();
3938int
3939main ()
3940{
3941gethostbyname ();
3942  ;
3943  return 0;
3944}
3945_ACEOF
3946rm -f conftest.$ac_objext conftest$ac_exeext
3947if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3948  (eval $ac_link) 2>conftest.er1
3949  ac_status=$?
3950  grep -v '^ *+' conftest.er1 >conftest.err
3951  rm -f conftest.er1
3952  cat conftest.err >&5
3953  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3954  (exit $ac_status); } &&
3955	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
3956  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3957  (eval $ac_try) 2>&5
3958  ac_status=$?
3959  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3960  (exit $ac_status); }; } &&
3961	 { ac_try='test -s conftest$ac_exeext'
3962  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3963  (eval $ac_try) 2>&5
3964  ac_status=$?
3965  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3966  (exit $ac_status); }; }; then
3967  ac_cv_lib_bsd_gethostbyname=yes
3968else
3969  echo "$as_me: failed program was:" >&5
3970sed 's/^/| /' conftest.$ac_ext >&5
3971
3972ac_cv_lib_bsd_gethostbyname=no
3973fi
3974rm -f conftest.err conftest.$ac_objext \
3975      conftest$ac_exeext conftest.$ac_ext
3976LIBS=$ac_check_lib_save_LIBS
3977fi
3978echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_gethostbyname" >&5
3979echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
3980if test $ac_cv_lib_bsd_gethostbyname = yes; then
3981  X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
3982fi
3983
3984      fi
3985    fi
3986
3987    # lieder@skyler.mavd.honeywell.com says without -lsocket,
3988    # socket/setsockopt and other routines are undefined under SCO ODT
3989    # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
3990    # on later versions), says Simon Leinen: it contains gethostby*
3991    # variants that don't use the name server (or something).  -lsocket
3992    # must be given before -lnsl if both are needed.  We assume that
3993    # if connect needs -lnsl, so does gethostbyname.
3994    echo "$as_me:$LINENO: checking for connect" >&5
3995echo $ECHO_N "checking for connect... $ECHO_C" >&6
3996if test "${ac_cv_func_connect+set}" = set; then
3997  echo $ECHO_N "(cached) $ECHO_C" >&6
3998else
3999  cat >conftest.$ac_ext <<_ACEOF
4000/* confdefs.h.  */
4001_ACEOF
4002cat confdefs.h >>conftest.$ac_ext
4003cat >>conftest.$ac_ext <<_ACEOF
4004/* end confdefs.h.  */
4005/* Define connect to an innocuous variant, in case <limits.h> declares connect.
4006   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
4007#define connect innocuous_connect
4008
4009/* System header to define __stub macros and hopefully few prototypes,
4010    which can conflict with char connect (); below.
4011    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4012    <limits.h> exists even on freestanding compilers.  */
4013
4014#ifdef __STDC__
4015# include <limits.h>
4016#else
4017# include <assert.h>
4018#endif
4019
4020#undef connect
4021
4022/* Override any gcc2 internal prototype to avoid an error.  */
4023#ifdef __cplusplus
4024extern "C"
4025{
4026#endif
4027/* We use char because int might match the return type of a gcc2
4028   builtin and then its argument prototype would still apply.  */
4029char connect ();
4030/* The GNU C library defines this for functions which it implements
4031    to always fail with ENOSYS.  Some functions are actually named
4032    something starting with __ and the normal name is an alias.  */
4033#if defined (__stub_connect) || defined (__stub___connect)
4034choke me
4035#else
4036char (*f) () = connect;
4037#endif
4038#ifdef __cplusplus
4039}
4040#endif
4041
4042int
4043main ()
4044{
4045return f != connect;
4046  ;
4047  return 0;
4048}
4049_ACEOF
4050rm -f conftest.$ac_objext conftest$ac_exeext
4051if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4052  (eval $ac_link) 2>conftest.er1
4053  ac_status=$?
4054  grep -v '^ *+' conftest.er1 >conftest.err
4055  rm -f conftest.er1
4056  cat conftest.err >&5
4057  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4058  (exit $ac_status); } &&
4059	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
4060  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4061  (eval $ac_try) 2>&5
4062  ac_status=$?
4063  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4064  (exit $ac_status); }; } &&
4065	 { ac_try='test -s conftest$ac_exeext'
4066  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4067  (eval $ac_try) 2>&5
4068  ac_status=$?
4069  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4070  (exit $ac_status); }; }; then
4071  ac_cv_func_connect=yes
4072else
4073  echo "$as_me: failed program was:" >&5
4074sed 's/^/| /' conftest.$ac_ext >&5
4075
4076ac_cv_func_connect=no
4077fi
4078rm -f conftest.err conftest.$ac_objext \
4079      conftest$ac_exeext conftest.$ac_ext
4080fi
4081echo "$as_me:$LINENO: result: $ac_cv_func_connect" >&5
4082echo "${ECHO_T}$ac_cv_func_connect" >&6
4083
4084    if test $ac_cv_func_connect = no; then
4085      echo "$as_me:$LINENO: checking for connect in -lsocket" >&5
4086echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
4087if test "${ac_cv_lib_socket_connect+set}" = set; then
4088  echo $ECHO_N "(cached) $ECHO_C" >&6
4089else
4090  ac_check_lib_save_LIBS=$LIBS
4091LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
4092cat >conftest.$ac_ext <<_ACEOF
4093/* confdefs.h.  */
4094_ACEOF
4095cat confdefs.h >>conftest.$ac_ext
4096cat >>conftest.$ac_ext <<_ACEOF
4097/* end confdefs.h.  */
4098
4099/* Override any gcc2 internal prototype to avoid an error.  */
4100#ifdef __cplusplus
4101extern "C"
4102#endif
4103/* We use char because int might match the return type of a gcc2
4104   builtin and then its argument prototype would still apply.  */
4105char connect ();
4106int
4107main ()
4108{
4109connect ();
4110  ;
4111  return 0;
4112}
4113_ACEOF
4114rm -f conftest.$ac_objext conftest$ac_exeext
4115if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4116  (eval $ac_link) 2>conftest.er1
4117  ac_status=$?
4118  grep -v '^ *+' conftest.er1 >conftest.err
4119  rm -f conftest.er1
4120  cat conftest.err >&5
4121  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4122  (exit $ac_status); } &&
4123	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
4124  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4125  (eval $ac_try) 2>&5
4126  ac_status=$?
4127  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4128  (exit $ac_status); }; } &&
4129	 { ac_try='test -s conftest$ac_exeext'
4130  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4131  (eval $ac_try) 2>&5
4132  ac_status=$?
4133  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4134  (exit $ac_status); }; }; then
4135  ac_cv_lib_socket_connect=yes
4136else
4137  echo "$as_me: failed program was:" >&5
4138sed 's/^/| /' conftest.$ac_ext >&5
4139
4140ac_cv_lib_socket_connect=no
4141fi
4142rm -f conftest.err conftest.$ac_objext \
4143      conftest$ac_exeext conftest.$ac_ext
4144LIBS=$ac_check_lib_save_LIBS
4145fi
4146echo "$as_me:$LINENO: result: $ac_cv_lib_socket_connect" >&5
4147echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
4148if test $ac_cv_lib_socket_connect = yes; then
4149  X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
4150fi
4151
4152    fi
4153
4154    # Guillermo Gomez says -lposix is necessary on A/UX.
4155    echo "$as_me:$LINENO: checking for remove" >&5
4156echo $ECHO_N "checking for remove... $ECHO_C" >&6
4157if test "${ac_cv_func_remove+set}" = set; then
4158  echo $ECHO_N "(cached) $ECHO_C" >&6
4159else
4160  cat >conftest.$ac_ext <<_ACEOF
4161/* confdefs.h.  */
4162_ACEOF
4163cat confdefs.h >>conftest.$ac_ext
4164cat >>conftest.$ac_ext <<_ACEOF
4165/* end confdefs.h.  */
4166/* Define remove to an innocuous variant, in case <limits.h> declares remove.
4167   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
4168#define remove innocuous_remove
4169
4170/* System header to define __stub macros and hopefully few prototypes,
4171    which can conflict with char remove (); below.
4172    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4173    <limits.h> exists even on freestanding compilers.  */
4174
4175#ifdef __STDC__
4176# include <limits.h>
4177#else
4178# include <assert.h>
4179#endif
4180
4181#undef remove
4182
4183/* Override any gcc2 internal prototype to avoid an error.  */
4184#ifdef __cplusplus
4185extern "C"
4186{
4187#endif
4188/* We use char because int might match the return type of a gcc2
4189   builtin and then its argument prototype would still apply.  */
4190char remove ();
4191/* The GNU C library defines this for functions which it implements
4192    to always fail with ENOSYS.  Some functions are actually named
4193    something starting with __ and the normal name is an alias.  */
4194#if defined (__stub_remove) || defined (__stub___remove)
4195choke me
4196#else
4197char (*f) () = remove;
4198#endif
4199#ifdef __cplusplus
4200}
4201#endif
4202
4203int
4204main ()
4205{
4206return f != remove;
4207  ;
4208  return 0;
4209}
4210_ACEOF
4211rm -f conftest.$ac_objext conftest$ac_exeext
4212if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4213  (eval $ac_link) 2>conftest.er1
4214  ac_status=$?
4215  grep -v '^ *+' conftest.er1 >conftest.err
4216  rm -f conftest.er1
4217  cat conftest.err >&5
4218  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4219  (exit $ac_status); } &&
4220	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
4221  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4222  (eval $ac_try) 2>&5
4223  ac_status=$?
4224  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4225  (exit $ac_status); }; } &&
4226	 { ac_try='test -s conftest$ac_exeext'
4227  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4228  (eval $ac_try) 2>&5
4229  ac_status=$?
4230  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4231  (exit $ac_status); }; }; then
4232  ac_cv_func_remove=yes
4233else
4234  echo "$as_me: failed program was:" >&5
4235sed 's/^/| /' conftest.$ac_ext >&5
4236
4237ac_cv_func_remove=no
4238fi
4239rm -f conftest.err conftest.$ac_objext \
4240      conftest$ac_exeext conftest.$ac_ext
4241fi
4242echo "$as_me:$LINENO: result: $ac_cv_func_remove" >&5
4243echo "${ECHO_T}$ac_cv_func_remove" >&6
4244
4245    if test $ac_cv_func_remove = no; then
4246      echo "$as_me:$LINENO: checking for remove in -lposix" >&5
4247echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
4248if test "${ac_cv_lib_posix_remove+set}" = set; then
4249  echo $ECHO_N "(cached) $ECHO_C" >&6
4250else
4251  ac_check_lib_save_LIBS=$LIBS
4252LIBS="-lposix  $LIBS"
4253cat >conftest.$ac_ext <<_ACEOF
4254/* confdefs.h.  */
4255_ACEOF
4256cat confdefs.h >>conftest.$ac_ext
4257cat >>conftest.$ac_ext <<_ACEOF
4258/* end confdefs.h.  */
4259
4260/* Override any gcc2 internal prototype to avoid an error.  */
4261#ifdef __cplusplus
4262extern "C"
4263#endif
4264/* We use char because int might match the return type of a gcc2
4265   builtin and then its argument prototype would still apply.  */
4266char remove ();
4267int
4268main ()
4269{
4270remove ();
4271  ;
4272  return 0;
4273}
4274_ACEOF
4275rm -f conftest.$ac_objext conftest$ac_exeext
4276if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4277  (eval $ac_link) 2>conftest.er1
4278  ac_status=$?
4279  grep -v '^ *+' conftest.er1 >conftest.err
4280  rm -f conftest.er1
4281  cat conftest.err >&5
4282  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4283  (exit $ac_status); } &&
4284	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
4285  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4286  (eval $ac_try) 2>&5
4287  ac_status=$?
4288  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4289  (exit $ac_status); }; } &&
4290	 { ac_try='test -s conftest$ac_exeext'
4291  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4292  (eval $ac_try) 2>&5
4293  ac_status=$?
4294  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4295  (exit $ac_status); }; }; then
4296  ac_cv_lib_posix_remove=yes
4297else
4298  echo "$as_me: failed program was:" >&5
4299sed 's/^/| /' conftest.$ac_ext >&5
4300
4301ac_cv_lib_posix_remove=no
4302fi
4303rm -f conftest.err conftest.$ac_objext \
4304      conftest$ac_exeext conftest.$ac_ext
4305LIBS=$ac_check_lib_save_LIBS
4306fi
4307echo "$as_me:$LINENO: result: $ac_cv_lib_posix_remove" >&5
4308echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
4309if test $ac_cv_lib_posix_remove = yes; then
4310  X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
4311fi
4312
4313    fi
4314
4315    # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
4316    echo "$as_me:$LINENO: checking for shmat" >&5
4317echo $ECHO_N "checking for shmat... $ECHO_C" >&6
4318if test "${ac_cv_func_shmat+set}" = set; then
4319  echo $ECHO_N "(cached) $ECHO_C" >&6
4320else
4321  cat >conftest.$ac_ext <<_ACEOF
4322/* confdefs.h.  */
4323_ACEOF
4324cat confdefs.h >>conftest.$ac_ext
4325cat >>conftest.$ac_ext <<_ACEOF
4326/* end confdefs.h.  */
4327/* Define shmat to an innocuous variant, in case <limits.h> declares shmat.
4328   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
4329#define shmat innocuous_shmat
4330
4331/* System header to define __stub macros and hopefully few prototypes,
4332    which can conflict with char shmat (); below.
4333    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4334    <limits.h> exists even on freestanding compilers.  */
4335
4336#ifdef __STDC__
4337# include <limits.h>
4338#else
4339# include <assert.h>
4340#endif
4341
4342#undef shmat
4343
4344/* Override any gcc2 internal prototype to avoid an error.  */
4345#ifdef __cplusplus
4346extern "C"
4347{
4348#endif
4349/* We use char because int might match the return type of a gcc2
4350   builtin and then its argument prototype would still apply.  */
4351char shmat ();
4352/* The GNU C library defines this for functions which it implements
4353    to always fail with ENOSYS.  Some functions are actually named
4354    something starting with __ and the normal name is an alias.  */
4355#if defined (__stub_shmat) || defined (__stub___shmat)
4356choke me
4357#else
4358char (*f) () = shmat;
4359#endif
4360#ifdef __cplusplus
4361}
4362#endif
4363
4364int
4365main ()
4366{
4367return f != shmat;
4368  ;
4369  return 0;
4370}
4371_ACEOF
4372rm -f conftest.$ac_objext conftest$ac_exeext
4373if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4374  (eval $ac_link) 2>conftest.er1
4375  ac_status=$?
4376  grep -v '^ *+' conftest.er1 >conftest.err
4377  rm -f conftest.er1
4378  cat conftest.err >&5
4379  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4380  (exit $ac_status); } &&
4381	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
4382  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4383  (eval $ac_try) 2>&5
4384  ac_status=$?
4385  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4386  (exit $ac_status); }; } &&
4387	 { ac_try='test -s conftest$ac_exeext'
4388  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4389  (eval $ac_try) 2>&5
4390  ac_status=$?
4391  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4392  (exit $ac_status); }; }; then
4393  ac_cv_func_shmat=yes
4394else
4395  echo "$as_me: failed program was:" >&5
4396sed 's/^/| /' conftest.$ac_ext >&5
4397
4398ac_cv_func_shmat=no
4399fi
4400rm -f conftest.err conftest.$ac_objext \
4401      conftest$ac_exeext conftest.$ac_ext
4402fi
4403echo "$as_me:$LINENO: result: $ac_cv_func_shmat" >&5
4404echo "${ECHO_T}$ac_cv_func_shmat" >&6
4405
4406    if test $ac_cv_func_shmat = no; then
4407      echo "$as_me:$LINENO: checking for shmat in -lipc" >&5
4408echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
4409if test "${ac_cv_lib_ipc_shmat+set}" = set; then
4410  echo $ECHO_N "(cached) $ECHO_C" >&6
4411else
4412  ac_check_lib_save_LIBS=$LIBS
4413LIBS="-lipc  $LIBS"
4414cat >conftest.$ac_ext <<_ACEOF
4415/* confdefs.h.  */
4416_ACEOF
4417cat confdefs.h >>conftest.$ac_ext
4418cat >>conftest.$ac_ext <<_ACEOF
4419/* end confdefs.h.  */
4420
4421/* Override any gcc2 internal prototype to avoid an error.  */
4422#ifdef __cplusplus
4423extern "C"
4424#endif
4425/* We use char because int might match the return type of a gcc2
4426   builtin and then its argument prototype would still apply.  */
4427char shmat ();
4428int
4429main ()
4430{
4431shmat ();
4432  ;
4433  return 0;
4434}
4435_ACEOF
4436rm -f conftest.$ac_objext conftest$ac_exeext
4437if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4438  (eval $ac_link) 2>conftest.er1
4439  ac_status=$?
4440  grep -v '^ *+' conftest.er1 >conftest.err
4441  rm -f conftest.er1
4442  cat conftest.err >&5
4443  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4444  (exit $ac_status); } &&
4445	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
4446  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4447  (eval $ac_try) 2>&5
4448  ac_status=$?
4449  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4450  (exit $ac_status); }; } &&
4451	 { ac_try='test -s conftest$ac_exeext'
4452  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4453  (eval $ac_try) 2>&5
4454  ac_status=$?
4455  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4456  (exit $ac_status); }; }; then
4457  ac_cv_lib_ipc_shmat=yes
4458else
4459  echo "$as_me: failed program was:" >&5
4460sed 's/^/| /' conftest.$ac_ext >&5
4461
4462ac_cv_lib_ipc_shmat=no
4463fi
4464rm -f conftest.err conftest.$ac_objext \
4465      conftest$ac_exeext conftest.$ac_ext
4466LIBS=$ac_check_lib_save_LIBS
4467fi
4468echo "$as_me:$LINENO: result: $ac_cv_lib_ipc_shmat" >&5
4469echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
4470if test $ac_cv_lib_ipc_shmat = yes; then
4471  X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
4472fi
4473
4474    fi
4475  fi
4476
4477  # Check for libraries that X11R6 Xt/Xaw programs need.
4478  ac_save_LDFLAGS=$LDFLAGS
4479  test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
4480  # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
4481  # check for ICE first), but we must link in the order -lSM -lICE or
4482  # we get undefined symbols.  So assume we have SM if we have ICE.
4483  # These have to be linked with before -lX11, unlike the other
4484  # libraries we check for below, so use a different variable.
4485  # John Interrante, Karl Berry
4486  echo "$as_me:$LINENO: checking for IceConnectionNumber in -lICE" >&5
4487echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
4488if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
4489  echo $ECHO_N "(cached) $ECHO_C" >&6
4490else
4491  ac_check_lib_save_LIBS=$LIBS
4492LIBS="-lICE $X_EXTRA_LIBS $LIBS"
4493cat >conftest.$ac_ext <<_ACEOF
4494/* confdefs.h.  */
4495_ACEOF
4496cat confdefs.h >>conftest.$ac_ext
4497cat >>conftest.$ac_ext <<_ACEOF
4498/* end confdefs.h.  */
4499
4500/* Override any gcc2 internal prototype to avoid an error.  */
4501#ifdef __cplusplus
4502extern "C"
4503#endif
4504/* We use char because int might match the return type of a gcc2
4505   builtin and then its argument prototype would still apply.  */
4506char IceConnectionNumber ();
4507int
4508main ()
4509{
4510IceConnectionNumber ();
4511  ;
4512  return 0;
4513}
4514_ACEOF
4515rm -f conftest.$ac_objext conftest$ac_exeext
4516if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4517  (eval $ac_link) 2>conftest.er1
4518  ac_status=$?
4519  grep -v '^ *+' conftest.er1 >conftest.err
4520  rm -f conftest.er1
4521  cat conftest.err >&5
4522  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4523  (exit $ac_status); } &&
4524	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
4525  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4526  (eval $ac_try) 2>&5
4527  ac_status=$?
4528  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4529  (exit $ac_status); }; } &&
4530	 { ac_try='test -s conftest$ac_exeext'
4531  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4532  (eval $ac_try) 2>&5
4533  ac_status=$?
4534  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4535  (exit $ac_status); }; }; then
4536  ac_cv_lib_ICE_IceConnectionNumber=yes
4537else
4538  echo "$as_me: failed program was:" >&5
4539sed 's/^/| /' conftest.$ac_ext >&5
4540
4541ac_cv_lib_ICE_IceConnectionNumber=no
4542fi
4543rm -f conftest.err conftest.$ac_objext \
4544      conftest$ac_exeext conftest.$ac_ext
4545LIBS=$ac_check_lib_save_LIBS
4546fi
4547echo "$as_me:$LINENO: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
4548echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
4549if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
4550  X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
4551fi
4552
4553  LDFLAGS=$ac_save_LDFLAGS
4554
4555fi
4556
4557if test "x$no_x" != xyes ; then
4558  CFLAGS="$CFLAGS $X_CFLAGS"
4559  CXXFLAGS="$CXXFLAGS $X_CFLAGS"
4560  LIBS="$LIBS $X_PRE_LIBS $X_LIBS $X_EXTRA_LIBS -lX11"
4561fi
4562
4563
4564echo "$as_me:$LINENO: checking for vga_init in -lvga" >&5
4565echo $ECHO_N "checking for vga_init in -lvga... $ECHO_C" >&6
4566if test "${ac_cv_lib_vga_vga_init+set}" = set; then
4567  echo $ECHO_N "(cached) $ECHO_C" >&6
4568else
4569  ac_check_lib_save_LIBS=$LIBS
4570LIBS="-lvga  $LIBS"
4571cat >conftest.$ac_ext <<_ACEOF
4572/* confdefs.h.  */
4573_ACEOF
4574cat confdefs.h >>conftest.$ac_ext
4575cat >>conftest.$ac_ext <<_ACEOF
4576/* end confdefs.h.  */
4577
4578/* Override any gcc2 internal prototype to avoid an error.  */
4579#ifdef __cplusplus
4580extern "C"
4581#endif
4582/* We use char because int might match the return type of a gcc2
4583   builtin and then its argument prototype would still apply.  */
4584char vga_init ();
4585int
4586main ()
4587{
4588vga_init ();
4589  ;
4590  return 0;
4591}
4592_ACEOF
4593rm -f conftest.$ac_objext conftest$ac_exeext
4594if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4595  (eval $ac_link) 2>conftest.er1
4596  ac_status=$?
4597  grep -v '^ *+' conftest.er1 >conftest.err
4598  rm -f conftest.er1
4599  cat conftest.err >&5
4600  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4601  (exit $ac_status); } &&
4602	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
4603  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4604  (eval $ac_try) 2>&5
4605  ac_status=$?
4606  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4607  (exit $ac_status); }; } &&
4608	 { ac_try='test -s conftest$ac_exeext'
4609  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4610  (eval $ac_try) 2>&5
4611  ac_status=$?
4612  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4613  (exit $ac_status); }; }; then
4614  ac_cv_lib_vga_vga_init=yes
4615else
4616  echo "$as_me: failed program was:" >&5
4617sed 's/^/| /' conftest.$ac_ext >&5
4618
4619ac_cv_lib_vga_vga_init=no
4620fi
4621rm -f conftest.err conftest.$ac_objext \
4622      conftest$ac_exeext conftest.$ac_ext
4623LIBS=$ac_check_lib_save_LIBS
4624fi
4625echo "$as_me:$LINENO: result: $ac_cv_lib_vga_vga_init" >&5
4626echo "${ECHO_T}$ac_cv_lib_vga_vga_init" >&6
4627if test $ac_cv_lib_vga_vga_init = yes; then
4628  cat >>confdefs.h <<_ACEOF
4629@%:@define HAVE_LIBVGA 1
4630_ACEOF
4631
4632  LIBS="-lvga $LIBS"
4633
4634fi
4635
4636
4637SDL_VERSION=1.2.0
4638# Make sure we can run config.sub.
4639$ac_config_sub sun4 >/dev/null 2>&1 ||
4640  { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
4641echo "$as_me: error: cannot run $ac_config_sub" >&2;}
4642   { (exit 1); exit 1; }; }
4643
4644echo "$as_me:$LINENO: checking build system type" >&5
4645echo $ECHO_N "checking build system type... $ECHO_C" >&6
4646if test "${ac_cv_build+set}" = set; then
4647  echo $ECHO_N "(cached) $ECHO_C" >&6
4648else
4649  ac_cv_build_alias=$build_alias
4650test -z "$ac_cv_build_alias" &&
4651  ac_cv_build_alias=`$ac_config_guess`
4652test -z "$ac_cv_build_alias" &&
4653  { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
4654echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
4655   { (exit 1); exit 1; }; }
4656ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
4657  { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
4658echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
4659   { (exit 1); exit 1; }; }
4660
4661fi
4662echo "$as_me:$LINENO: result: $ac_cv_build" >&5
4663echo "${ECHO_T}$ac_cv_build" >&6
4664build=$ac_cv_build
4665build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
4666build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
4667build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
4668
4669
4670echo "$as_me:$LINENO: checking host system type" >&5
4671echo $ECHO_N "checking host system type... $ECHO_C" >&6
4672if test "${ac_cv_host+set}" = set; then
4673  echo $ECHO_N "(cached) $ECHO_C" >&6
4674else
4675  ac_cv_host_alias=$host_alias
4676test -z "$ac_cv_host_alias" &&
4677  ac_cv_host_alias=$ac_cv_build_alias
4678ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
4679  { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
4680echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
4681   { (exit 1); exit 1; }; }
4682
4683fi
4684echo "$as_me:$LINENO: result: $ac_cv_host" >&5
4685echo "${ECHO_T}$ac_cv_host" >&6
4686host=$ac_cv_host
4687host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
4688host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
4689host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
4690
4691
4692echo "$as_me:$LINENO: checking target system type" >&5
4693echo $ECHO_N "checking target system type... $ECHO_C" >&6
4694if test "${ac_cv_target+set}" = set; then
4695  echo $ECHO_N "(cached) $ECHO_C" >&6
4696else
4697  ac_cv_target_alias=$target_alias
4698test "x$ac_cv_target_alias" = "x" &&
4699  ac_cv_target_alias=$ac_cv_host_alias
4700ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
4701  { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
4702echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
4703   { (exit 1); exit 1; }; }
4704
4705fi
4706echo "$as_me:$LINENO: result: $ac_cv_target" >&5
4707echo "${ECHO_T}$ac_cv_target" >&6
4708target=$ac_cv_target
4709target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
4710target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
4711target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
4712
4713
4714# The aliases save the names the user supplied, while $host etc.
4715# will get canonicalized.
4716test -n "$target_alias" &&
4717  test "$program_prefix$program_suffix$program_transform_name" = \
4718    NONENONEs,x,x, &&
4719  program_prefix=${target_alias}-
4720
4721# Check whether --with-sdl-prefix or --without-sdl-prefix was given.
4722if test "${with_sdl_prefix+set}" = set; then
4723  withval="$with_sdl_prefix"
4724  sdl_prefix="$withval"
4725else
4726  sdl_prefix=""
4727fi;
4728
4729# Check whether --with-sdl-exec-prefix or --without-sdl-exec-prefix was given.
4730if test "${with_sdl_exec_prefix+set}" = set; then
4731  withval="$with_sdl_exec_prefix"
4732  sdl_exec_prefix="$withval"
4733else
4734  sdl_exec_prefix=""
4735fi;
4736# Check whether --enable-sdltest or --disable-sdltest was given.
4737if test "${enable_sdltest+set}" = set; then
4738  enableval="$enable_sdltest"
4739
4740else
4741  enable_sdltest=yes
4742fi;
4743
4744  if test x$sdl_exec_prefix != x ; then
4745     sdl_args="$sdl_args --exec-prefix=$sdl_exec_prefix"
4746     if test x${SDL_CONFIG+set} != xset ; then
4747        SDL_CONFIG=$sdl_exec_prefix/bin/sdl-config
4748     fi
4749  fi
4750  if test x$sdl_prefix != x ; then
4751     sdl_args="$sdl_args --prefix=$sdl_prefix"
4752     if test x${SDL_CONFIG+set} != xset ; then
4753        SDL_CONFIG=$sdl_prefix/bin/sdl-config
4754     fi
4755  fi
4756
4757
4758  PATH="$prefix/bin:$prefix/usr/bin:$PATH"
4759  # Extract the first word of "sdl-config", so it can be a program name with args.
4760set dummy sdl-config; ac_word=$2
4761echo "$as_me:$LINENO: checking for $ac_word" >&5
4762echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4763if test "${ac_cv_path_SDL_CONFIG+set}" = set; then
4764  echo $ECHO_N "(cached) $ECHO_C" >&6
4765else
4766  case $SDL_CONFIG in
4767  [\\/]* | ?:[\\/]*)
4768  ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a path.
4769  ;;
4770  *)
4771  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4772for as_dir in $PATH
4773do
4774  IFS=$as_save_IFS
4775  test -z "$as_dir" && as_dir=.
4776  for ac_exec_ext in '' $ac_executable_extensions; do
4777  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4778    ac_cv_path_SDL_CONFIG="$as_dir/$ac_word$ac_exec_ext"
4779    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4780    break 2
4781  fi
4782done
4783done
4784
4785  test -z "$ac_cv_path_SDL_CONFIG" && ac_cv_path_SDL_CONFIG="no"
4786  ;;
4787esac
4788fi
4789SDL_CONFIG=$ac_cv_path_SDL_CONFIG
4790
4791if test -n "$SDL_CONFIG"; then
4792  echo "$as_me:$LINENO: result: $SDL_CONFIG" >&5
4793echo "${ECHO_T}$SDL_CONFIG" >&6
4794else
4795  echo "$as_me:$LINENO: result: no" >&5
4796echo "${ECHO_T}no" >&6
4797fi
4798
4799  min_sdl_version=$SDL_VERSION
4800  echo "$as_me:$LINENO: checking for SDL - version >= $min_sdl_version" >&5
4801echo $ECHO_N "checking for SDL - version >= $min_sdl_version... $ECHO_C" >&6
4802  no_sdl=""
4803  if test "$SDL_CONFIG" = "no" ; then
4804    no_sdl=yes
4805  else
4806    SDL_CFLAGS=`$SDL_CONFIG $sdlconf_args --cflags`
4807    SDL_LIBS=`$SDL_CONFIG $sdlconf_args --libs`
4808
4809    sdl_major_version=`$SDL_CONFIG $sdl_args --version | \
4810           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'`
4811    sdl_minor_version=`$SDL_CONFIG $sdl_args --version | \
4812           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'`
4813    sdl_micro_version=`$SDL_CONFIG $sdl_config_args --version | \
4814           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'`
4815    if test "x$enable_sdltest" = "xyes" ; then
4816      ac_save_CFLAGS="$CFLAGS"
4817      ac_save_LIBS="$LIBS"
4818      CFLAGS="$CFLAGS $SDL_CFLAGS"
4819      LIBS="$LIBS $SDL_LIBS"
4820      rm -f conf.sdltest
4821      if test "$cross_compiling" = yes; then
4822  echo $ac_n "cross compiling; assumed OK... $ac_c"
4823else
4824  cat >conftest.$ac_ext <<_ACEOF
4825/* confdefs.h.  */
4826_ACEOF
4827cat confdefs.h >>conftest.$ac_ext
4828cat >>conftest.$ac_ext <<_ACEOF
4829/* end confdefs.h.  */
4830
4831#include <stdio.h>
4832#include <stdlib.h>
4833#include <string.h>
4834#include "SDL.h"
4835
4836char*
4837my_strdup (char *str)
4838{
4839  char *new_str;
4840
4841  if (str)
4842    {
4843      new_str = (char *)malloc ((strlen (str) + 1) * sizeof(char));
4844      strcpy (new_str, str);
4845    }
4846  else
4847    new_str = NULL;
4848
4849  return new_str;
4850}
4851
4852int main (int argc, char *argv[])
4853{
4854  int major, minor, micro;
4855  char *tmp_version;
4856
4857  /* This hangs on some systems (?)
4858  system ("touch conf.sdltest");
4859  */
4860  { FILE *fp = fopen("conf.sdltest", "a"); if ( fp ) fclose(fp); }
4861
4862  /* HP/UX 9 (%@#!) writes to sscanf strings */
4863  tmp_version = my_strdup("$min_sdl_version");
4864  if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
4865     printf("%s, bad version string\n", "$min_sdl_version");
4866     exit(1);
4867   }
4868
4869   if (($sdl_major_version > major) ||
4870      (($sdl_major_version == major) && ($sdl_minor_version > minor)) ||
4871      (($sdl_major_version == major) && ($sdl_minor_version == minor) && ($sdl_micro_version >= micro)))
4872    {
4873      return 0;
4874    }
4875  else
4876    {
4877      printf("\n*** 'sdl-config --version' returned %d.%d.%d, but the minimum version\n", $sdl_major_version, $sdl_minor_version, $sdl_micro_version);
4878      printf("*** of SDL required is %d.%d.%d. If sdl-config is correct, then it is\n", major, minor, micro);
4879      printf("*** best to upgrade to the required version.\n");
4880      printf("*** If sdl-config was wrong, set the environment variable SDL_CONFIG\n");
4881      printf("*** to point to the correct copy of sdl-config, and remove the file\n");
4882      printf("*** config.cache before re-running configure\n");
4883      return 1;
4884    }
4885}
4886
4887
4888_ACEOF
4889rm -f conftest$ac_exeext
4890if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4891  (eval $ac_link) 2>&5
4892  ac_status=$?
4893  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4894  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4895  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4896  (eval $ac_try) 2>&5
4897  ac_status=$?
4898  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4899  (exit $ac_status); }; }; then
4900  :
4901else
4902  echo "$as_me: program exited with status $ac_status" >&5
4903echo "$as_me: failed program was:" >&5
4904sed 's/^/| /' conftest.$ac_ext >&5
4905
4906( exit $ac_status )
4907no_sdl=yes
4908fi
4909rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4910fi
4911       CFLAGS="$ac_save_CFLAGS"
4912       LIBS="$ac_save_LIBS"
4913     fi
4914  fi
4915  if test "x$no_sdl" = x ; then
4916     echo "$as_me:$LINENO: result: yes" >&5
4917echo "${ECHO_T}yes" >&6
4918     cat >>confdefs.h <<\_ACEOF
4919@%:@define HAVE_SDL 1
4920_ACEOF
4921
4922  else
4923     echo "$as_me:$LINENO: result: no" >&5
4924echo "${ECHO_T}no" >&6
4925     if test "$SDL_CONFIG" = "no" ; then
4926       echo "*** The sdl-config script installed by SDL could not be found"
4927       echo "*** If SDL was installed in PREFIX, make sure PREFIX/bin is in"
4928       echo "*** your path, or set the SDL_CONFIG environment variable to the"
4929       echo "*** full path to sdl-config."
4930     else
4931       if test -f conf.sdltest ; then
4932        :
4933       else
4934          echo "*** Could not run SDL test program, checking why..."
4935          CFLAGS="$CFLAGS $SDL_CFLAGS"
4936          LIBS="$LIBS $SDL_LIBS"
4937          cat >conftest.$ac_ext <<_ACEOF
4938/* confdefs.h.  */
4939_ACEOF
4940cat confdefs.h >>conftest.$ac_ext
4941cat >>conftest.$ac_ext <<_ACEOF
4942/* end confdefs.h.  */
4943
4944#include <stdio.h>
4945#include "SDL.h"
4946
4947int main(int argc, char *argv[])
4948{ return 0; }
4949#undef  main
4950#define main K_and_R_C_main
4951
4952int
4953main ()
4954{
4955 return 0;
4956  ;
4957  return 0;
4958}
4959_ACEOF
4960rm -f conftest.$ac_objext conftest$ac_exeext
4961if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4962  (eval $ac_link) 2>conftest.er1
4963  ac_status=$?
4964  grep -v '^ *+' conftest.er1 >conftest.err
4965  rm -f conftest.er1
4966  cat conftest.err >&5
4967  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4968  (exit $ac_status); } &&
4969	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
4970  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4971  (eval $ac_try) 2>&5
4972  ac_status=$?
4973  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4974  (exit $ac_status); }; } &&
4975	 { ac_try='test -s conftest$ac_exeext'
4976  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4977  (eval $ac_try) 2>&5
4978  ac_status=$?
4979  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4980  (exit $ac_status); }; }; then
4981   echo "*** The test program compiled, but did not run. This usually means"
4982          echo "*** that the run-time linker is not finding SDL or finding the wrong"
4983          echo "*** version of SDL. If it is not finding SDL, you'll need to set your"
4984          echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
4985          echo "*** to the installed location  Also, make sure you have run ldconfig if that"
4986          echo "*** is required on your system"
4987	  echo "***"
4988          echo "*** If you have an old version installed, it is best to remove it, although"
4989          echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
4990else
4991  echo "$as_me: failed program was:" >&5
4992sed 's/^/| /' conftest.$ac_ext >&5
4993
4994 echo "*** The test program failed to compile or link. See the file config.log for the"
4995          echo "*** exact error that occured. This usually means SDL was incorrectly installed"
4996          echo "*** or that you have moved SDL since it was installed. In the latter case, you"
4997          echo "*** may want to edit the sdl-config script: $SDL_CONFIG"
4998fi
4999rm -f conftest.err conftest.$ac_objext \
5000      conftest$ac_exeext conftest.$ac_ext
5001          CFLAGS="$ac_save_CFLAGS"
5002          LIBS="$ac_save_LIBS"
5003       fi
5004     fi
5005     SDL_CFLAGS=""
5006     SDL_LIBS=""
5007     :
5008
5009  fi
5010
5011
5012  rm -f conf.sdltest
5013
5014CFLAGS="$CFLAGS $SDL_CFLAGS"
5015CXXFLAGS="$CXXFLAGS $SDL_CFLAGS"
5016LIBS="$LIBS $SDL_LIBS"
5017
5018
5019echo "$as_me:$LINENO: checking for esd_record_stream_fallback in -lesd" >&5
5020echo $ECHO_N "checking for esd_record_stream_fallback in -lesd... $ECHO_C" >&6
5021if test "${ac_cv_lib_esd_esd_record_stream_fallback+set}" = set; then
5022  echo $ECHO_N "(cached) $ECHO_C" >&6
5023else
5024  ac_check_lib_save_LIBS=$LIBS
5025LIBS="-lesd  $LIBS"
5026cat >conftest.$ac_ext <<_ACEOF
5027/* confdefs.h.  */
5028_ACEOF
5029cat confdefs.h >>conftest.$ac_ext
5030cat >>conftest.$ac_ext <<_ACEOF
5031/* end confdefs.h.  */
5032
5033/* Override any gcc2 internal prototype to avoid an error.  */
5034#ifdef __cplusplus
5035extern "C"
5036#endif
5037/* We use char because int might match the return type of a gcc2
5038   builtin and then its argument prototype would still apply.  */
5039char esd_record_stream_fallback ();
5040int
5041main ()
5042{
5043esd_record_stream_fallback ();
5044  ;
5045  return 0;
5046}
5047_ACEOF
5048rm -f conftest.$ac_objext conftest$ac_exeext
5049if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5050  (eval $ac_link) 2>conftest.er1
5051  ac_status=$?
5052  grep -v '^ *+' conftest.er1 >conftest.err
5053  rm -f conftest.er1
5054  cat conftest.err >&5
5055  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5056  (exit $ac_status); } &&
5057	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
5058  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5059  (eval $ac_try) 2>&5
5060  ac_status=$?
5061  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5062  (exit $ac_status); }; } &&
5063	 { ac_try='test -s conftest$ac_exeext'
5064  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5065  (eval $ac_try) 2>&5
5066  ac_status=$?
5067  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5068  (exit $ac_status); }; }; then
5069  ac_cv_lib_esd_esd_record_stream_fallback=yes
5070else
5071  echo "$as_me: failed program was:" >&5
5072sed 's/^/| /' conftest.$ac_ext >&5
5073
5074ac_cv_lib_esd_esd_record_stream_fallback=no
5075fi
5076rm -f conftest.err conftest.$ac_objext \
5077      conftest$ac_exeext conftest.$ac_ext
5078LIBS=$ac_check_lib_save_LIBS
5079fi
5080echo "$as_me:$LINENO: result: $ac_cv_lib_esd_esd_record_stream_fallback" >&5
5081echo "${ECHO_T}$ac_cv_lib_esd_esd_record_stream_fallback" >&6
5082if test $ac_cv_lib_esd_esd_record_stream_fallback = yes; then
5083  cat >>confdefs.h <<_ACEOF
5084@%:@define HAVE_LIBESD 1
5085_ACEOF
5086
5087  LIBS="-lesd $LIBS"
5088
5089fi
5090
5091
5092          ac_config_files="$ac_config_files Makefile"
5093cat >confcache <<\_ACEOF
5094# This file is a shell script that caches the results of configure
5095# tests run on this system so they can be shared between configure
5096# scripts and configure runs, see configure's option --config-cache.
5097# It is not useful on other systems.  If it contains results you don't
5098# want to keep, you may remove or edit it.
5099#
5100# config.status only pays attention to the cache file if you give it
5101# the --recheck option to rerun configure.
5102#
5103# `ac_cv_env_foo' variables (set or unset) will be overridden when
5104# loading this file, other *unset* `ac_cv_foo' will be assigned the
5105# following values.
5106
5107_ACEOF
5108
5109# The following way of writing the cache mishandles newlines in values,
5110# but we know of no workaround that is simple, portable, and efficient.
5111# So, don't put newlines in cache variables' values.
5112# Ultrix sh set writes to stderr and can't be redirected directly,
5113# and sets the high bit in the cache file unless we assign to the vars.
5114{
5115  (set) 2>&1 |
5116    case `(ac_space=' '; set | grep ac_space) 2>&1` in
5117    *ac_space=\ *)
5118      # `set' does not quote correctly, so add quotes (double-quote
5119      # substitution turns \\\\ into \\, and sed turns \\ into \).
5120      sed -n \
5121	"s/'/'\\\\''/g;
5122	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
5123      ;;
5124    *)
5125      # `set' quotes correctly as required by POSIX, so do not add quotes.
5126      sed -n \
5127	"s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
5128      ;;
5129    esac;
5130} |
5131  sed '
5132     t clear
5133     : clear
5134     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
5135     t end
5136     /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
5137     : end' >>confcache
5138if diff $cache_file confcache >/dev/null 2>&1; then :; else
5139  if test -w $cache_file; then
5140    test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
5141    cat confcache >$cache_file
5142  else
5143    echo "not updating unwritable cache $cache_file"
5144  fi
5145fi
5146rm -f confcache
5147
5148test "x$prefix" = xNONE && prefix=$ac_default_prefix
5149# Let make expand exec_prefix.
5150test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5151
5152# VPATH may cause trouble with some makes, so we remove $(srcdir),
5153# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
5154# trailing colons and then remove the whole line if VPATH becomes empty
5155# (actually we leave an empty line to preserve line numbers).
5156if test "x$srcdir" = x.; then
5157  ac_vpsub='/^[	 ]*VPATH[	 ]*=/{
5158s/:*\$(srcdir):*/:/;
5159s/:*\${srcdir}:*/:/;
5160s/:*@srcdir@:*/:/;
5161s/^\([^=]*=[	 ]*\):*/\1/;
5162s/:*$//;
5163s/^[^=]*=[	 ]*$//;
5164}'
5165fi
5166
5167DEFS=-DHAVE_CONFIG_H
5168
5169ac_libobjs=
5170ac_ltlibobjs=
5171for ac_i in : $LIB@&t@OBJS; do test "x$ac_i" = x: && continue
5172  # 1. Remove the extension, and $U if already installed.
5173  ac_i=`echo "$ac_i" |
5174	 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
5175  # 2. Add them.
5176  ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
5177  ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
5178done
5179LIB@&t@OBJS=$ac_libobjs
5180
5181LTLIBOBJS=$ac_ltlibobjs
5182
5183
5184
5185: ${CONFIG_STATUS=./config.status}
5186ac_clean_files_save=$ac_clean_files
5187ac_clean_files="$ac_clean_files $CONFIG_STATUS"
5188{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
5189echo "$as_me: creating $CONFIG_STATUS" >&6;}
5190cat >$CONFIG_STATUS <<_ACEOF
5191#! $SHELL
5192# Generated by $as_me.
5193# Run this file to recreate the current configuration.
5194# Compiler output produced by configure, useful for debugging
5195# configure, is in config.log if it exists.
5196
5197debug=false
5198ac_cs_recheck=false
5199ac_cs_silent=false
5200SHELL=\${CONFIG_SHELL-$SHELL}
5201_ACEOF
5202
5203cat >>$CONFIG_STATUS <<\_ACEOF
5204## --------------------- ##
5205## M4sh Initialization.  ##
5206## --------------------- ##
5207
5208# Be Bourne compatible
5209if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
5210  emulate sh
5211  NULLCMD=:
5212  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
5213  # is contrary to our usage.  Disable this feature.
5214  alias -g '${1+"$@"}'='"$@"'
5215elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
5216  set -o posix
5217fi
5218DUALCASE=1; export DUALCASE # for MKS sh
5219
5220# Support unset when possible.
5221if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
5222  as_unset=unset
5223else
5224  as_unset=false
5225fi
5226
5227
5228# Work around bugs in pre-3.0 UWIN ksh.
5229$as_unset ENV MAIL MAILPATH
5230PS1='$ '
5231PS2='> '
5232PS4='+ '
5233
5234# NLS nuisances.
5235for as_var in \
5236  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
5237  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
5238  LC_TELEPHONE LC_TIME
5239do
5240  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
5241    eval $as_var=C; export $as_var
5242  else
5243    $as_unset $as_var
5244  fi
5245done
5246
5247# Required to use basename.
5248if expr a : '\(a\)' >/dev/null 2>&1; then
5249  as_expr=expr
5250else
5251  as_expr=false
5252fi
5253
5254if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
5255  as_basename=basename
5256else
5257  as_basename=false
5258fi
5259
5260
5261# Name of the executable.
5262as_me=`$as_basename "$0" ||
5263$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
5264	 X"$0" : 'X\(//\)$' \| \
5265	 X"$0" : 'X\(/\)$' \| \
5266	 .     : '\(.\)' 2>/dev/null ||
5267echo X/"$0" |
5268    sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
5269  	  /^X\/\(\/\/\)$/{ s//\1/; q; }
5270  	  /^X\/\(\/\).*/{ s//\1/; q; }
5271  	  s/.*/./; q'`
5272
5273
5274# PATH needs CR, and LINENO needs CR and PATH.
5275# Avoid depending upon Character Ranges.
5276as_cr_letters='abcdefghijklmnopqrstuvwxyz'
5277as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
5278as_cr_Letters=$as_cr_letters$as_cr_LETTERS
5279as_cr_digits='0123456789'
5280as_cr_alnum=$as_cr_Letters$as_cr_digits
5281
5282# The user is always right.
5283if test "${PATH_SEPARATOR+set}" != set; then
5284  echo "#! /bin/sh" >conf$$.sh
5285  echo  "exit 0"   >>conf$$.sh
5286  chmod +x conf$$.sh
5287  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
5288    PATH_SEPARATOR=';'
5289  else
5290    PATH_SEPARATOR=:
5291  fi
5292  rm -f conf$$.sh
5293fi
5294
5295
5296  as_lineno_1=$LINENO
5297  as_lineno_2=$LINENO
5298  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
5299  test "x$as_lineno_1" != "x$as_lineno_2" &&
5300  test "x$as_lineno_3"  = "x$as_lineno_2"  || {
5301  # Find who we are.  Look in the path if we contain no path at all
5302  # relative or not.
5303  case $0 in
5304    *[\\/]* ) as_myself=$0 ;;
5305    *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5306for as_dir in $PATH
5307do
5308  IFS=$as_save_IFS
5309  test -z "$as_dir" && as_dir=.
5310  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
5311done
5312
5313       ;;
5314  esac
5315  # We did not find ourselves, most probably we were run as `sh COMMAND'
5316  # in which case we are not to be found in the path.
5317  if test "x$as_myself" = x; then
5318    as_myself=$0
5319  fi
5320  if test ! -f "$as_myself"; then
5321    { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
5322echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
5323   { (exit 1); exit 1; }; }
5324  fi
5325  case $CONFIG_SHELL in
5326  '')
5327    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5328for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
5329do
5330  IFS=$as_save_IFS
5331  test -z "$as_dir" && as_dir=.
5332  for as_base in sh bash ksh sh5; do
5333	 case $as_dir in
5334	 /*)
5335	   if ("$as_dir/$as_base" -c '
5336  as_lineno_1=$LINENO
5337  as_lineno_2=$LINENO
5338  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
5339  test "x$as_lineno_1" != "x$as_lineno_2" &&
5340  test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
5341	     $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
5342	     $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
5343	     CONFIG_SHELL=$as_dir/$as_base
5344	     export CONFIG_SHELL
5345	     exec "$CONFIG_SHELL" "$0" ${1+"$@"}
5346	   fi;;
5347	 esac
5348       done
5349done
5350;;
5351  esac
5352
5353  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
5354  # uniformly replaced by the line number.  The first 'sed' inserts a
5355  # line-number line before each line; the second 'sed' does the real
5356  # work.  The second script uses 'N' to pair each line-number line
5357  # with the numbered line, and appends trailing '-' during
5358  # substitution so that $LINENO is not a special case at line end.
5359  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
5360  # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
5361  sed '=' <$as_myself |
5362    sed '
5363      N
5364      s,$,-,
5365      : loop
5366      s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
5367      t loop
5368      s,-$,,
5369      s,^['$as_cr_digits']*\n,,
5370    ' >$as_me.lineno &&
5371  chmod +x $as_me.lineno ||
5372    { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
5373echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
5374   { (exit 1); exit 1; }; }
5375
5376  # Don't try to exec as it changes $[0], causing all sort of problems
5377  # (the dirname of $[0] is not the place where we might find the
5378  # original and so on.  Autoconf is especially sensible to this).
5379  . ./$as_me.lineno
5380  # Exit status is that of the last command.
5381  exit
5382}
5383
5384
5385case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
5386  *c*,-n*) ECHO_N= ECHO_C='
5387' ECHO_T='	' ;;
5388  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
5389  *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
5390esac
5391
5392if expr a : '\(a\)' >/dev/null 2>&1; then
5393  as_expr=expr
5394else
5395  as_expr=false
5396fi
5397
5398rm -f conf$$ conf$$.exe conf$$.file
5399echo >conf$$.file
5400if ln -s conf$$.file conf$$ 2>/dev/null; then
5401  # We could just check for DJGPP; but this test a) works b) is more generic
5402  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
5403  if test -f conf$$.exe; then
5404    # Don't use ln at all; we don't have any links
5405    as_ln_s='cp -p'
5406  else
5407    as_ln_s='ln -s'
5408  fi
5409elif ln conf$$.file conf$$ 2>/dev/null; then
5410  as_ln_s=ln
5411else
5412  as_ln_s='cp -p'
5413fi
5414rm -f conf$$ conf$$.exe conf$$.file
5415
5416if mkdir -p . 2>/dev/null; then
5417  as_mkdir_p=:
5418else
5419  test -d ./-p && rmdir ./-p
5420  as_mkdir_p=false
5421fi
5422
5423as_executable_p="test -f"
5424
5425# Sed expression to map a string onto a valid CPP name.
5426as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
5427
5428# Sed expression to map a string onto a valid variable name.
5429as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
5430
5431
5432# IFS
5433# We need space, tab and new line, in precisely that order.
5434as_nl='
5435'
5436IFS=" 	$as_nl"
5437
5438# CDPATH.
5439$as_unset CDPATH
5440
5441exec 6>&1
5442
5443# Open the log real soon, to keep \$[0] and so on meaningful, and to
5444# report actual input values of CONFIG_FILES etc. instead of their
5445# values after options handling.  Logging --version etc. is OK.
5446exec 5>>config.log
5447{
5448  echo
5449  sed 'h;s/./-/g;s/^.../@%:@@%:@ /;s/...$/ @%:@@%:@/;p;x;p;x' <<_ASBOX
5450@%:@@%:@ Running $as_me. @%:@@%:@
5451_ASBOX
5452} >&5
5453cat >&5 <<_CSEOF
5454
5455This file was extended by $as_me, which was
5456generated by GNU Autoconf 2.59.  Invocation command line was
5457
5458  CONFIG_FILES    = $CONFIG_FILES
5459  CONFIG_HEADERS  = $CONFIG_HEADERS
5460  CONFIG_LINKS    = $CONFIG_LINKS
5461  CONFIG_COMMANDS = $CONFIG_COMMANDS
5462  $ $0 $@
5463
5464_CSEOF
5465echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
5466echo >&5
5467_ACEOF
5468
5469# Files that config.status was made for.
5470if test -n "$ac_config_files"; then
5471  echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
5472fi
5473
5474if test -n "$ac_config_headers"; then
5475  echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
5476fi
5477
5478if test -n "$ac_config_links"; then
5479  echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
5480fi
5481
5482if test -n "$ac_config_commands"; then
5483  echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
5484fi
5485
5486cat >>$CONFIG_STATUS <<\_ACEOF
5487
5488ac_cs_usage="\
5489\`$as_me' instantiates files from templates according to the
5490current configuration.
5491
5492Usage: $0 [OPTIONS] [FILE]...
5493
5494  -h, --help       print this help, then exit
5495  -V, --version    print version number, then exit
5496  -q, --quiet      do not print progress messages
5497  -d, --debug      don't remove temporary files
5498      --recheck    update $as_me by reconfiguring in the same conditions
5499  --file=FILE[:TEMPLATE]
5500		   instantiate the configuration file FILE
5501  --header=FILE[:TEMPLATE]
5502		   instantiate the configuration header FILE
5503
5504Configuration files:
5505$config_files
5506
5507Configuration headers:
5508$config_headers
5509
5510Configuration commands:
5511$config_commands
5512
5513Report bugs to <bug-autoconf@gnu.org>."
5514_ACEOF
5515
5516cat >>$CONFIG_STATUS <<_ACEOF
5517ac_cs_version="\\
5518config.status
5519configured by $0, generated by GNU Autoconf 2.59,
5520  with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
5521
5522Copyright (C) 2003 Free Software Foundation, Inc.
5523This config.status script is free software; the Free Software Foundation
5524gives unlimited permission to copy, distribute and modify it."
5525srcdir=$srcdir
5526INSTALL="$INSTALL"
5527_ACEOF
5528
5529cat >>$CONFIG_STATUS <<\_ACEOF
5530# If no file are specified by the user, then we need to provide default
5531# value.  By we need to know if files were specified by the user.
5532ac_need_defaults=:
5533while test $# != 0
5534do
5535  case $1 in
5536  --*=*)
5537    ac_option=`expr "x$1" : 'x\([^=]*\)='`
5538    ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
5539    ac_shift=:
5540    ;;
5541  -*)
5542    ac_option=$1
5543    ac_optarg=$2
5544    ac_shift=shift
5545    ;;
5546  *) # This is not an option, so the user has probably given explicit
5547     # arguments.
5548     ac_option=$1
5549     ac_need_defaults=false;;
5550  esac
5551
5552  case $ac_option in
5553  # Handling of the options.
5554_ACEOF
5555cat >>$CONFIG_STATUS <<\_ACEOF
5556  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
5557    ac_cs_recheck=: ;;
5558  --version | --vers* | -V )
5559    echo "$ac_cs_version"; exit 0 ;;
5560  --he | --h)
5561    # Conflict between --help and --header
5562    { { echo "$as_me:$LINENO: error: ambiguous option: $1
5563Try \`$0 --help' for more information." >&5
5564echo "$as_me: error: ambiguous option: $1
5565Try \`$0 --help' for more information." >&2;}
5566   { (exit 1); exit 1; }; };;
5567  --help | --hel | -h )
5568    echo "$ac_cs_usage"; exit 0 ;;
5569  --debug | --d* | -d )
5570    debug=: ;;
5571  --file | --fil | --fi | --f )
5572    $ac_shift
5573    CONFIG_FILES="$CONFIG_FILES $ac_optarg"
5574    ac_need_defaults=false;;
5575  --header | --heade | --head | --hea )
5576    $ac_shift
5577    CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
5578    ac_need_defaults=false;;
5579  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
5580  | -silent | --silent | --silen | --sile | --sil | --si | --s)
5581    ac_cs_silent=: ;;
5582
5583  # This is an error.
5584  -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
5585Try \`$0 --help' for more information." >&5
5586echo "$as_me: error: unrecognized option: $1
5587Try \`$0 --help' for more information." >&2;}
5588   { (exit 1); exit 1; }; } ;;
5589
5590  *) ac_config_targets="$ac_config_targets $1" ;;
5591
5592  esac
5593  shift
5594done
5595
5596ac_configure_extra_args=
5597
5598if $ac_cs_silent; then
5599  exec 6>/dev/null
5600  ac_configure_extra_args="$ac_configure_extra_args --silent"
5601fi
5602
5603_ACEOF
5604cat >>$CONFIG_STATUS <<_ACEOF
5605if \$ac_cs_recheck; then
5606  echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
5607  exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
5608fi
5609
5610_ACEOF
5611
5612cat >>$CONFIG_STATUS <<_ACEOF
5613#
5614# INIT-COMMANDS section.
5615#
5616
5617
5618
5619_ACEOF
5620
5621
5622
5623cat >>$CONFIG_STATUS <<\_ACEOF
5624for ac_config_target in $ac_config_targets
5625do
5626  case "$ac_config_target" in
5627  # Handling of arguments.
5628  "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
5629  "default-1" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
5630  "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
5631  *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
5632echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
5633   { (exit 1); exit 1; }; };;
5634  esac
5635done
5636
5637# If the user did not use the arguments to specify the items to instantiate,
5638# then the envvar interface is used.  Set only those that are not.
5639# We use the long form for the default assignment because of an extremely
5640# bizarre bug on SunOS 4.1.3.
5641if $ac_need_defaults; then
5642  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
5643  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
5644  test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
5645fi
5646
5647# Have a temporary directory for convenience.  Make it in the build tree
5648# simply because there is no reason to put it here, and in addition,
5649# creating and moving files from /tmp can sometimes cause problems.
5650# Create a temporary directory, and hook for its removal unless debugging.
5651$debug ||
5652{
5653  trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
5654  trap '{ (exit 1); exit 1; }' 1 2 13 15
5655}
5656
5657# Create a (secure) tmp directory for tmp files.
5658
5659{
5660  tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
5661  test -n "$tmp" && test -d "$tmp"
5662}  ||
5663{
5664  tmp=./confstat$$-$RANDOM
5665  (umask 077 && mkdir $tmp)
5666} ||
5667{
5668   echo "$me: cannot create a temporary directory in ." >&2
5669   { (exit 1); exit 1; }
5670}
5671
5672_ACEOF
5673
5674cat >>$CONFIG_STATUS <<_ACEOF
5675
5676#
5677# CONFIG_FILES section.
5678#
5679
5680# No need to generate the scripts if there are no CONFIG_FILES.
5681# This happens for instance when ./config.status config.h
5682if test -n "\$CONFIG_FILES"; then
5683  # Protect against being on the right side of a sed subst in config.status.
5684  sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
5685   s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
5686s,@SHELL@,$SHELL,;t t
5687s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
5688s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
5689s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
5690s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
5691s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
5692s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
5693s,@exec_prefix@,$exec_prefix,;t t
5694s,@prefix@,$prefix,;t t
5695s,@program_transform_name@,$program_transform_name,;t t
5696s,@bindir@,$bindir,;t t
5697s,@sbindir@,$sbindir,;t t
5698s,@libexecdir@,$libexecdir,;t t
5699s,@datadir@,$datadir,;t t
5700s,@sysconfdir@,$sysconfdir,;t t
5701s,@sharedstatedir@,$sharedstatedir,;t t
5702s,@localstatedir@,$localstatedir,;t t
5703s,@libdir@,$libdir,;t t
5704s,@includedir@,$includedir,;t t
5705s,@oldincludedir@,$oldincludedir,;t t
5706s,@infodir@,$infodir,;t t
5707s,@mandir@,$mandir,;t t
5708s,@build_alias@,$build_alias,;t t
5709s,@host_alias@,$host_alias,;t t
5710s,@target_alias@,$target_alias,;t t
5711s,@DEFS@,$DEFS,;t t
5712s,@ECHO_C@,$ECHO_C,;t t
5713s,@ECHO_N@,$ECHO_N,;t t
5714s,@ECHO_T@,$ECHO_T,;t t
5715s,@LIBS@,$LIBS,;t t
5716s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
5717s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
5718s,@INSTALL_DATA@,$INSTALL_DATA,;t t
5719s,@PACKAGE@,$PACKAGE,;t t
5720s,@VERSION@,$VERSION,;t t
5721s,@ACLOCAL@,$ACLOCAL,;t t
5722s,@AUTOCONF@,$AUTOCONF,;t t
5723s,@AUTOMAKE@,$AUTOMAKE,;t t
5724s,@AUTOHEADER@,$AUTOHEADER,;t t
5725s,@MAKEINFO@,$MAKEINFO,;t t
5726s,@SET_MAKE@,$SET_MAKE,;t t
5727s,@CC@,$CC,;t t
5728s,@CFLAGS@,$CFLAGS,;t t
5729s,@LDFLAGS@,$LDFLAGS,;t t
5730s,@CPPFLAGS@,$CPPFLAGS,;t t
5731s,@ac_ct_CC@,$ac_ct_CC,;t t
5732s,@EXEEXT@,$EXEEXT,;t t
5733s,@OBJEXT@,$OBJEXT,;t t
5734s,@CXX@,$CXX,;t t
5735s,@CXXFLAGS@,$CXXFLAGS,;t t
5736s,@ac_ct_CXX@,$ac_ct_CXX,;t t
5737s,@CPP@,$CPP,;t t
5738s,@X_CFLAGS@,$X_CFLAGS,;t t
5739s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
5740s,@X_LIBS@,$X_LIBS,;t t
5741s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
5742s,@build@,$build,;t t
5743s,@build_cpu@,$build_cpu,;t t
5744s,@build_vendor@,$build_vendor,;t t
5745s,@build_os@,$build_os,;t t
5746s,@host@,$host,;t t
5747s,@host_cpu@,$host_cpu,;t t
5748s,@host_vendor@,$host_vendor,;t t
5749s,@host_os@,$host_os,;t t
5750s,@target@,$target,;t t
5751s,@target_cpu@,$target_cpu,;t t
5752s,@target_vendor@,$target_vendor,;t t
5753s,@target_os@,$target_os,;t t
5754s,@SDL_CONFIG@,$SDL_CONFIG,;t t
5755s,@SDL_CFLAGS@,$SDL_CFLAGS,;t t
5756s,@SDL_LIBS@,$SDL_LIBS,;t t
5757s,@LIB@&t@OBJS@,$LIB@&t@OBJS,;t t
5758s,@LTLIBOBJS@,$LTLIBOBJS,;t t
5759CEOF
5760
5761_ACEOF
5762
5763  cat >>$CONFIG_STATUS <<\_ACEOF
5764  # Split the substitutions into bite-sized pieces for seds with
5765  # small command number limits, like on Digital OSF/1 and HP-UX.
5766  ac_max_sed_lines=48
5767  ac_sed_frag=1 # Number of current file.
5768  ac_beg=1 # First line for current file.
5769  ac_end=$ac_max_sed_lines # Line after last line for current file.
5770  ac_more_lines=:
5771  ac_sed_cmds=
5772  while $ac_more_lines; do
5773    if test $ac_beg -gt 1; then
5774      sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
5775    else
5776      sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
5777    fi
5778    if test ! -s $tmp/subs.frag; then
5779      ac_more_lines=false
5780    else
5781      # The purpose of the label and of the branching condition is to
5782      # speed up the sed processing (if there are no `@' at all, there
5783      # is no need to browse any of the substitutions).
5784      # These are the two extra sed commands mentioned above.
5785      (echo ':t
5786  /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
5787      if test -z "$ac_sed_cmds"; then
5788	ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
5789      else
5790	ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
5791      fi
5792      ac_sed_frag=`expr $ac_sed_frag + 1`
5793      ac_beg=$ac_end
5794      ac_end=`expr $ac_end + $ac_max_sed_lines`
5795    fi
5796  done
5797  if test -z "$ac_sed_cmds"; then
5798    ac_sed_cmds=cat
5799  fi
5800fi # test -n "$CONFIG_FILES"
5801
5802_ACEOF
5803cat >>$CONFIG_STATUS <<\_ACEOF
5804for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
5805  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5806  case $ac_file in
5807  - | *:- | *:-:* ) # input from stdin
5808	cat >$tmp/stdin
5809	ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5810	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5811  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
5812	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
5813  * )   ac_file_in=$ac_file.in ;;
5814  esac
5815
5816  # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
5817  ac_dir=`(dirname "$ac_file") 2>/dev/null ||
5818$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
5819	 X"$ac_file" : 'X\(//\)[^/]' \| \
5820	 X"$ac_file" : 'X\(//\)$' \| \
5821	 X"$ac_file" : 'X\(/\)' \| \
5822	 .     : '\(.\)' 2>/dev/null ||
5823echo X"$ac_file" |
5824    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
5825  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
5826  	  /^X\(\/\/\)$/{ s//\1/; q; }
5827  	  /^X\(\/\).*/{ s//\1/; q; }
5828  	  s/.*/./; q'`
5829  { if $as_mkdir_p; then
5830    mkdir -p "$ac_dir"
5831  else
5832    as_dir="$ac_dir"
5833    as_dirs=
5834    while test ! -d "$as_dir"; do
5835      as_dirs="$as_dir $as_dirs"
5836      as_dir=`(dirname "$as_dir") 2>/dev/null ||
5837$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
5838	 X"$as_dir" : 'X\(//\)[^/]' \| \
5839	 X"$as_dir" : 'X\(//\)$' \| \
5840	 X"$as_dir" : 'X\(/\)' \| \
5841	 .     : '\(.\)' 2>/dev/null ||
5842echo X"$as_dir" |
5843    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
5844  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
5845  	  /^X\(\/\/\)$/{ s//\1/; q; }
5846  	  /^X\(\/\).*/{ s//\1/; q; }
5847  	  s/.*/./; q'`
5848    done
5849    test ! -n "$as_dirs" || mkdir $as_dirs
5850  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
5851echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
5852   { (exit 1); exit 1; }; }; }
5853
5854  ac_builddir=.
5855
5856if test "$ac_dir" != .; then
5857  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
5858  # A "../" for each directory in $ac_dir_suffix.
5859  ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
5860else
5861  ac_dir_suffix= ac_top_builddir=
5862fi
5863
5864case $srcdir in
5865  .)  # No --srcdir option.  We are building in place.
5866    ac_srcdir=.
5867    if test -z "$ac_top_builddir"; then
5868       ac_top_srcdir=.
5869    else
5870       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
5871    fi ;;
5872  [\\/]* | ?:[\\/]* )  # Absolute path.
5873    ac_srcdir=$srcdir$ac_dir_suffix;
5874    ac_top_srcdir=$srcdir ;;
5875  *) # Relative path.
5876    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
5877    ac_top_srcdir=$ac_top_builddir$srcdir ;;
5878esac
5879
5880# Do not use `cd foo && pwd` to compute absolute paths, because
5881# the directories may not exist.
5882case `pwd` in
5883.) ac_abs_builddir="$ac_dir";;
5884*)
5885  case "$ac_dir" in
5886  .) ac_abs_builddir=`pwd`;;
5887  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
5888  *) ac_abs_builddir=`pwd`/"$ac_dir";;
5889  esac;;
5890esac
5891case $ac_abs_builddir in
5892.) ac_abs_top_builddir=${ac_top_builddir}.;;
5893*)
5894  case ${ac_top_builddir}. in
5895  .) ac_abs_top_builddir=$ac_abs_builddir;;
5896  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
5897  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
5898  esac;;
5899esac
5900case $ac_abs_builddir in
5901.) ac_abs_srcdir=$ac_srcdir;;
5902*)
5903  case $ac_srcdir in
5904  .) ac_abs_srcdir=$ac_abs_builddir;;
5905  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
5906  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
5907  esac;;
5908esac
5909case $ac_abs_builddir in
5910.) ac_abs_top_srcdir=$ac_top_srcdir;;
5911*)
5912  case $ac_top_srcdir in
5913  .) ac_abs_top_srcdir=$ac_abs_builddir;;
5914  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
5915  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
5916  esac;;
5917esac
5918
5919
5920  case $INSTALL in
5921  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
5922  *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
5923  esac
5924
5925  # Let's still pretend it is `configure' which instantiates (i.e., don't
5926  # use $as_me), people would be surprised to read:
5927  #    /* config.h.  Generated by config.status.  */
5928  if test x"$ac_file" = x-; then
5929    configure_input=
5930  else
5931    configure_input="$ac_file.  "
5932  fi
5933  configure_input=$configure_input"Generated from `echo $ac_file_in |
5934				     sed 's,.*/,,'` by configure."
5935
5936  # First look for the input files in the build tree, otherwise in the
5937  # src tree.
5938  ac_file_inputs=`IFS=:
5939    for f in $ac_file_in; do
5940      case $f in
5941      -) echo $tmp/stdin ;;
5942      [\\/$]*)
5943	 # Absolute (can't be DOS-style, as IFS=:)
5944	 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
5945echo "$as_me: error: cannot find input file: $f" >&2;}
5946   { (exit 1); exit 1; }; }
5947	 echo "$f";;
5948      *) # Relative
5949	 if test -f "$f"; then
5950	   # Build tree
5951	   echo "$f"
5952	 elif test -f "$srcdir/$f"; then
5953	   # Source tree
5954	   echo "$srcdir/$f"
5955	 else
5956	   # /dev/null tree
5957	   { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
5958echo "$as_me: error: cannot find input file: $f" >&2;}
5959   { (exit 1); exit 1; }; }
5960	 fi;;
5961      esac
5962    done` || { (exit 1); exit 1; }
5963
5964  if test x"$ac_file" != x-; then
5965    { echo "$as_me:$LINENO: creating $ac_file" >&5
5966echo "$as_me: creating $ac_file" >&6;}
5967    rm -f "$ac_file"
5968  fi
5969_ACEOF
5970cat >>$CONFIG_STATUS <<_ACEOF
5971  sed "$ac_vpsub
5972$extrasub
5973_ACEOF
5974cat >>$CONFIG_STATUS <<\_ACEOF
5975:t
5976/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
5977s,@configure_input@,$configure_input,;t t
5978s,@srcdir@,$ac_srcdir,;t t
5979s,@abs_srcdir@,$ac_abs_srcdir,;t t
5980s,@top_srcdir@,$ac_top_srcdir,;t t
5981s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
5982s,@builddir@,$ac_builddir,;t t
5983s,@abs_builddir@,$ac_abs_builddir,;t t
5984s,@top_builddir@,$ac_top_builddir,;t t
5985s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
5986s,@INSTALL@,$ac_INSTALL,;t t
5987" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
5988  rm -f $tmp/stdin
5989  if test x"$ac_file" != x-; then
5990    mv $tmp/out $ac_file
5991  else
5992    cat $tmp/out
5993    rm -f $tmp/out
5994  fi
5995
5996done
5997_ACEOF
5998cat >>$CONFIG_STATUS <<\_ACEOF
5999
6000#
6001# CONFIG_HEADER section.
6002#
6003
6004# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
6005# NAME is the cpp macro being defined and VALUE is the value it is being given.
6006#
6007# ac_d sets the value in "#define NAME VALUE" lines.
6008ac_dA='s,^\([	 ]*\)#\([	 ]*define[	 ][	 ]*\)'
6009ac_dB='[	 ].*$,\1#\2'
6010ac_dC=' '
6011ac_dD=',;t'
6012# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
6013ac_uA='s,^\([	 ]*\)#\([	 ]*\)undef\([	 ][	 ]*\)'
6014ac_uB='$,\1#\2define\3'
6015ac_uC=' '
6016ac_uD=',;t'
6017
6018for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
6019  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6020  case $ac_file in
6021  - | *:- | *:-:* ) # input from stdin
6022	cat >$tmp/stdin
6023	ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
6024	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6025  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
6026	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
6027  * )   ac_file_in=$ac_file.in ;;
6028  esac
6029
6030  test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
6031echo "$as_me: creating $ac_file" >&6;}
6032
6033  # First look for the input files in the build tree, otherwise in the
6034  # src tree.
6035  ac_file_inputs=`IFS=:
6036    for f in $ac_file_in; do
6037      case $f in
6038      -) echo $tmp/stdin ;;
6039      [\\/$]*)
6040	 # Absolute (can't be DOS-style, as IFS=:)
6041	 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6042echo "$as_me: error: cannot find input file: $f" >&2;}
6043   { (exit 1); exit 1; }; }
6044	 # Do quote $f, to prevent DOS paths from being IFS'd.
6045	 echo "$f";;
6046      *) # Relative
6047	 if test -f "$f"; then
6048	   # Build tree
6049	   echo "$f"
6050	 elif test -f "$srcdir/$f"; then
6051	   # Source tree
6052	   echo "$srcdir/$f"
6053	 else
6054	   # /dev/null tree
6055	   { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
6056echo "$as_me: error: cannot find input file: $f" >&2;}
6057   { (exit 1); exit 1; }; }
6058	 fi;;
6059      esac
6060    done` || { (exit 1); exit 1; }
6061  # Remove the trailing spaces.
6062  sed 's/[	 ]*$//' $ac_file_inputs >$tmp/in
6063
6064_ACEOF
6065
6066# Transform confdefs.h into two sed scripts, `conftest.defines' and
6067# `conftest.undefs', that substitutes the proper values into
6068# config.h.in to produce config.h.  The first handles `#define'
6069# templates, and the second `#undef' templates.
6070# And first: Protect against being on the right side of a sed subst in
6071# config.status.  Protect against being in an unquoted here document
6072# in config.status.
6073rm -f conftest.defines conftest.undefs
6074# Using a here document instead of a string reduces the quoting nightmare.
6075# Putting comments in sed scripts is not portable.
6076#
6077# `end' is used to avoid that the second main sed command (meant for
6078# 0-ary CPP macros) applies to n-ary macro definitions.
6079# See the Autoconf documentation for `clear'.
6080cat >confdef2sed.sed <<\_ACEOF
6081s/[\\&,]/\\&/g
6082s,[\\$`],\\&,g
6083t clear
6084: clear
6085s,^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 (][^	 (]*\)\(([^)]*)\)[	 ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
6086t end
6087s,^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 ][^	 ]*\)[	 ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
6088: end
6089_ACEOF
6090# If some macros were called several times there might be several times
6091# the same #defines, which is useless.  Nevertheless, we may not want to
6092# sort them, since we want the *last* AC-DEFINE to be honored.
6093uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
6094sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
6095rm -f confdef2sed.sed
6096
6097# This sed command replaces #undef with comments.  This is necessary, for
6098# example, in the case of _POSIX_SOURCE, which is predefined and required
6099# on some systems where configure will not decide to define it.
6100cat >>conftest.undefs <<\_ACEOF
6101s,^[	 ]*#[	 ]*undef[	 ][	 ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
6102_ACEOF
6103
6104# Break up conftest.defines because some shells have a limit on the size
6105# of here documents, and old seds have small limits too (100 cmds).
6106echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
6107echo '  if grep "^[	 ]*#[	 ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
6108echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
6109echo '  :' >>$CONFIG_STATUS
6110rm -f conftest.tail
6111while grep . conftest.defines >/dev/null
6112do
6113  # Write a limited-size here document to $tmp/defines.sed.
6114  echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
6115  # Speed up: don't consider the non `#define' lines.
6116  echo '/^[	 ]*#[	 ]*define/!b' >>$CONFIG_STATUS
6117  # Work around the forget-to-reset-the-flag bug.
6118  echo 't clr' >>$CONFIG_STATUS
6119  echo ': clr' >>$CONFIG_STATUS
6120  sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
6121  echo 'CEOF
6122  sed -f $tmp/defines.sed $tmp/in >$tmp/out
6123  rm -f $tmp/in
6124  mv $tmp/out $tmp/in
6125' >>$CONFIG_STATUS
6126  sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
6127  rm -f conftest.defines
6128  mv conftest.tail conftest.defines
6129done
6130rm -f conftest.defines
6131echo '  fi # grep' >>$CONFIG_STATUS
6132echo >>$CONFIG_STATUS
6133
6134# Break up conftest.undefs because some shells have a limit on the size
6135# of here documents, and old seds have small limits too (100 cmds).
6136echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
6137rm -f conftest.tail
6138while grep . conftest.undefs >/dev/null
6139do
6140  # Write a limited-size here document to $tmp/undefs.sed.
6141  echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
6142  # Speed up: don't consider the non `#undef'
6143  echo '/^[	 ]*#[	 ]*undef/!b' >>$CONFIG_STATUS
6144  # Work around the forget-to-reset-the-flag bug.
6145  echo 't clr' >>$CONFIG_STATUS
6146  echo ': clr' >>$CONFIG_STATUS
6147  sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
6148  echo 'CEOF
6149  sed -f $tmp/undefs.sed $tmp/in >$tmp/out
6150  rm -f $tmp/in
6151  mv $tmp/out $tmp/in
6152' >>$CONFIG_STATUS
6153  sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
6154  rm -f conftest.undefs
6155  mv conftest.tail conftest.undefs
6156done
6157rm -f conftest.undefs
6158
6159cat >>$CONFIG_STATUS <<\_ACEOF
6160  # Let's still pretend it is `configure' which instantiates (i.e., don't
6161  # use $as_me), people would be surprised to read:
6162  #    /* config.h.  Generated by config.status.  */
6163  if test x"$ac_file" = x-; then
6164    echo "/* Generated by configure.  */" >$tmp/config.h
6165  else
6166    echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
6167  fi
6168  cat $tmp/in >>$tmp/config.h
6169  rm -f $tmp/in
6170  if test x"$ac_file" != x-; then
6171    if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
6172      { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
6173echo "$as_me: $ac_file is unchanged" >&6;}
6174    else
6175      ac_dir=`(dirname "$ac_file") 2>/dev/null ||
6176$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
6177	 X"$ac_file" : 'X\(//\)[^/]' \| \
6178	 X"$ac_file" : 'X\(//\)$' \| \
6179	 X"$ac_file" : 'X\(/\)' \| \
6180	 .     : '\(.\)' 2>/dev/null ||
6181echo X"$ac_file" |
6182    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
6183  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
6184  	  /^X\(\/\/\)$/{ s//\1/; q; }
6185  	  /^X\(\/\).*/{ s//\1/; q; }
6186  	  s/.*/./; q'`
6187      { if $as_mkdir_p; then
6188    mkdir -p "$ac_dir"
6189  else
6190    as_dir="$ac_dir"
6191    as_dirs=
6192    while test ! -d "$as_dir"; do
6193      as_dirs="$as_dir $as_dirs"
6194      as_dir=`(dirname "$as_dir") 2>/dev/null ||
6195$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
6196	 X"$as_dir" : 'X\(//\)[^/]' \| \
6197	 X"$as_dir" : 'X\(//\)$' \| \
6198	 X"$as_dir" : 'X\(/\)' \| \
6199	 .     : '\(.\)' 2>/dev/null ||
6200echo X"$as_dir" |
6201    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
6202  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
6203  	  /^X\(\/\/\)$/{ s//\1/; q; }
6204  	  /^X\(\/\).*/{ s//\1/; q; }
6205  	  s/.*/./; q'`
6206    done
6207    test ! -n "$as_dirs" || mkdir $as_dirs
6208  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
6209echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
6210   { (exit 1); exit 1; }; }; }
6211
6212      rm -f $ac_file
6213      mv $tmp/config.h $ac_file
6214    fi
6215  else
6216    cat $tmp/config.h
6217    rm -f $tmp/config.h
6218  fi
6219done
6220_ACEOF
6221cat >>$CONFIG_STATUS <<\_ACEOF
6222
6223#
6224# CONFIG_COMMANDS section.
6225#
6226for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
6227  ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
6228  ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
6229  ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
6230$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
6231	 X"$ac_dest" : 'X\(//\)[^/]' \| \
6232	 X"$ac_dest" : 'X\(//\)$' \| \
6233	 X"$ac_dest" : 'X\(/\)' \| \
6234	 .     : '\(.\)' 2>/dev/null ||
6235echo X"$ac_dest" |
6236    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
6237  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
6238  	  /^X\(\/\/\)$/{ s//\1/; q; }
6239  	  /^X\(\/\).*/{ s//\1/; q; }
6240  	  s/.*/./; q'`
6241  { if $as_mkdir_p; then
6242    mkdir -p "$ac_dir"
6243  else
6244    as_dir="$ac_dir"
6245    as_dirs=
6246    while test ! -d "$as_dir"; do
6247      as_dirs="$as_dir $as_dirs"
6248      as_dir=`(dirname "$as_dir") 2>/dev/null ||
6249$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
6250	 X"$as_dir" : 'X\(//\)[^/]' \| \
6251	 X"$as_dir" : 'X\(//\)$' \| \
6252	 X"$as_dir" : 'X\(/\)' \| \
6253	 .     : '\(.\)' 2>/dev/null ||
6254echo X"$as_dir" |
6255    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
6256  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
6257  	  /^X\(\/\/\)$/{ s//\1/; q; }
6258  	  /^X\(\/\).*/{ s//\1/; q; }
6259  	  s/.*/./; q'`
6260    done
6261    test ! -n "$as_dirs" || mkdir $as_dirs
6262  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
6263echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
6264   { (exit 1); exit 1; }; }; }
6265
6266  ac_builddir=.
6267
6268if test "$ac_dir" != .; then
6269  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
6270  # A "../" for each directory in $ac_dir_suffix.
6271  ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
6272else
6273  ac_dir_suffix= ac_top_builddir=
6274fi
6275
6276case $srcdir in
6277  .)  # No --srcdir option.  We are building in place.
6278    ac_srcdir=.
6279    if test -z "$ac_top_builddir"; then
6280       ac_top_srcdir=.
6281    else
6282       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
6283    fi ;;
6284  [\\/]* | ?:[\\/]* )  # Absolute path.
6285    ac_srcdir=$srcdir$ac_dir_suffix;
6286    ac_top_srcdir=$srcdir ;;
6287  *) # Relative path.
6288    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
6289    ac_top_srcdir=$ac_top_builddir$srcdir ;;
6290esac
6291
6292# Do not use `cd foo && pwd` to compute absolute paths, because
6293# the directories may not exist.
6294case `pwd` in
6295.) ac_abs_builddir="$ac_dir";;
6296*)
6297  case "$ac_dir" in
6298  .) ac_abs_builddir=`pwd`;;
6299  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
6300  *) ac_abs_builddir=`pwd`/"$ac_dir";;
6301  esac;;
6302esac
6303case $ac_abs_builddir in
6304.) ac_abs_top_builddir=${ac_top_builddir}.;;
6305*)
6306  case ${ac_top_builddir}. in
6307  .) ac_abs_top_builddir=$ac_abs_builddir;;
6308  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
6309  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
6310  esac;;
6311esac
6312case $ac_abs_builddir in
6313.) ac_abs_srcdir=$ac_srcdir;;
6314*)
6315  case $ac_srcdir in
6316  .) ac_abs_srcdir=$ac_abs_builddir;;
6317  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
6318  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
6319  esac;;
6320esac
6321case $ac_abs_builddir in
6322.) ac_abs_top_srcdir=$ac_top_srcdir;;
6323*)
6324  case $ac_top_srcdir in
6325  .) ac_abs_top_srcdir=$ac_abs_builddir;;
6326  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
6327  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
6328  esac;;
6329esac
6330
6331
6332  { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
6333echo "$as_me: executing $ac_dest commands" >&6;}
6334  case $ac_dest in
6335    default-1 ) test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h ;;
6336  esac
6337done
6338_ACEOF
6339
6340cat >>$CONFIG_STATUS <<\_ACEOF
6341
6342{ (exit 0); exit 0; }
6343_ACEOF
6344chmod +x $CONFIG_STATUS
6345ac_clean_files=$ac_clean_files_save
6346
6347
6348# configure is writing to config.log, and then calls config.status.
6349# config.status does its own redirection, appending to config.log.
6350# Unfortunately, on DOS this fails, as config.log is still kept open
6351# by configure, so config.status won't be able to write to it; its
6352# output is simply discarded.  So we exec the FD to /dev/null,
6353# effectively closing config.log, so it can be properly (re)opened and
6354# appended to by config.status.  When coming back to configure, we
6355# need to make the FD available again.
6356if test "$no_create" != yes; then
6357  ac_cs_success=:
6358  ac_config_status_args=
6359  test "$silent" = yes &&
6360    ac_config_status_args="$ac_config_status_args --quiet"
6361  exec 5>/dev/null
6362  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
6363  exec 5>>config.log
6364  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
6365  # would make configure fail if this is the last instruction.
6366  $ac_cs_success || { (exit 1); exit 1; }
6367fi
6368
6369